Skip to content

Latest commit

 

History

History
32 lines (22 loc) · 1.22 KB

README.md

File metadata and controls

32 lines (22 loc) · 1.22 KB

slab-go

GoDoc Test Status Go Report Card

slab-go is a Go client library for accessing the slab.com API.

The slab.com API being in development, this SDK is going to change over time to try and follow upstream changes.

Usage

The import to use is:

import "github.com/VEVO/slab-go/slab"

General rule is to first contruct a client which will give you access to the different parts of the API.

Note that to connect you will need to provide the API access token that the slab support team will provide you.

slabToken := os.Getenv("SLAB_TOKEN")
client := slab.NewClient(&http.Client{Timeout: 10 * time.Second}, slabToken)
o, err := c.Organization.Get()
if err != nil {
    panic(err)
}

Usage examples can be found in the examples folder of this repository.