Documentation ¶
Overview ¶
Package github is a mini-library for querying the GitHub v3 API that takes care of authentication (with tokens only) and pagination.
Index ¶
Constants ¶
View Source
const DefaultBaseURL = "https://api.github.com"
View Source
const VERSION = "0.8.0"
Variables ¶
View Source
var VERBOSITY = 0
Set to values > 0 to control verbosity, for debugging.
Functions ¶
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client collects a few options that can be set when contacting the GitHub API, such as authorization tokens. Methods called on Client will supply these options when calling the API.
func (Client) Get ¶
Get fetches uri (relative URL) from the GitHub API and unmarshals the response into v. It takes care of pagination transparantly.
func (Client) NewRequest ¶ added in v0.8.0
func (Client) SetBaseURL ¶ added in v0.8.0
SetBaseURL updates the client's base URL, if baseurl is a non-empty value.
Click to show internal directories.
Click to hide internal directories.