Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // UserAgent lets the API know where the call is being made from. // It's overridden from the root command so that we can set the version. UserAgent = "github.com/exercism/cli" // DefaultHTTPClient configures a timeout to use by default. DefaultHTTPClient = &http.Client{Timeout: 10 * time.Second} )
Functions ¶
This section is empty.
Types ¶
type Client ¶
Client is an http client that is configured for Exercism.
func (*Client) Do ¶
Do performs an http.Request and optionally parses the response body into the given interface.
func (*Client) IsPingable ¶
IsPingable calls the API /ping to determine whether the API can be reached.
func (*Client) NewRequest ¶
NewRequest returns an http.Request with information for the Exercism API.
func (*Client) TokenIsValid ¶
TokenIsValid calls the API to determine whether the token is valid.
Click to show internal directories.
Click to hide internal directories.