Go client library for accessing the GitHub API v3
Agent Success
Agent success rate when using this tile
65%
Improvement
Agent success rate improvement when using this tile compared to baseline
1.14x
Baseline
Agent success rate without this tile
57%
Creates a preconfigured GitHub REST client that targets either public GitHub or a GitHub Enterprise host, injects authentication, and builds REST and upload requests with consistent headers.
@generates
type ClientConfig struct {
APIBaseURL string
UploadBaseURL string
Token string
UserAgent string
APIVersion string
HTTPClient *http.Client
}
type Client struct {
RESTBaseURL *url.URL
UploadBaseURL *url.URL
HTTPClient *http.Client
UserAgent string
APIVersion string
}
// BootstrapGitHubClient builds a REST client configured for public GitHub or the supplied enterprise hosts.
func BootstrapGitHubClient(cfg ClientConfig) (*Client, error)
// NewRESTRequest builds an HTTP request rooted at the REST base URL and applies auth/user-agent/version headers.
func (c *Client) NewRESTRequest(method, relativePath string, body interface{}) (*http.Request, error)
// NewUploadRequest builds an HTTP request rooted at the upload base URL and applies auth/user-agent/version headers.
func (c *Client) NewUploadRequest(method, relativePath string, body interface{}) (*http.Request, error)Typed GitHub REST v3 client used to construct authenticated REST and upload requests against public and enterprise hosts.
tessl i tessl/golang-github-com-google-go-github@79.0.1docs
evals
scenario-1
scenario-2
scenario-3
scenario-4
scenario-5
scenario-6
scenario-7
scenario-8
scenario-9
scenario-10