Skip to content

pavel-snyk/snyk-sdk-go

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

43 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Snyk SDK for Go

Build Go Report Card GoDoc Release

Disclaimer: this SDK is currently in technical preview and not ready for production usage. This means some aspects of its design and implementation are not yet considered stable.

snyk-sdk-go is the (un)official Snyk SDK for the Go programming language.

Installation

# X.Y.Z is the version you need
go get github.com/pavel-snyk/snyk-sdk-go@vX.Y.Z

# for non Go modules usage or latest version
go get github.com/pavel-snyk/snyk-sdk-go

Usage

import "github.com/pavel-snyk/snyk-sdk-go"

Create a new Snyk client, then use the exposed services to access different parts of the Snyk API.

Authentication

To use the SDK, you must get your API token from Snyk. You can find your token in your General Account Settings on https://snyk.io/account/ after you register with Snyk and log in. See Authentication for API.

client := snyk.NewClient("your-api-token")