Documentation ¶
Index ¶
- Constants
- Variables
- func GetApiKeyFromEnv() string
- func GetApiResponseBody(url, accessToken string, isRetryable func(*http.Response) bool) ([]byte, error)
- func GetApiServerFromEnv() string
- func IsErrorRetryable(err error) bool
- func MakeApiRequestWithRetry(client *http.Client, req *http.Request, ...)
- type OAuthCredentials
- type StockApi
Constants ¶
View Source
const ( ApiKeyEnvName = "STOCKER_API_KEY" ApiServerEnvName = "STOCKER_API_SERVER" DefaultClientTimeout = time.Second * 4 DefaultRequestBackoffDelay = time.Millisecond * 125 DefaultRequestBackoffLimit = time.Second DefaultRequestRetryLimit = 10 )
Variables ¶
Functions ¶
func GetApiKeyFromEnv ¶
func GetApiKeyFromEnv() string
func GetApiResponseBody ¶ added in v1.3.0
func GetApiServerFromEnv ¶
func GetApiServerFromEnv() string
func IsErrorRetryable ¶
Types ¶
type OAuthCredentials ¶
Click to show internal directories.
Click to hide internal directories.