Versions in this module Expand all Collapse all v2 v2.0.1 Jun 7, 2026 Changes in this version + type APIResponse struct + Data T + Error string + Success bool + func DecodeResponseStrict[T any](resp *http.Response) (*APIResponse[T], error) + func DecodeResponse[T any](resp *http.Response) (*APIResponse[T], error) + type Client struct + func New(cfg *types.Config) (*Client, error) + func NewFromConfig() (*Client, error) + func NewFromConfigUnauthenticated() (*Client, error) + func NewUnauthenticated(cfg *types.Config) (*Client, error) + func (c *Client) Delete(ctx context.Context, path string) (*http.Response, error) + func (c *Client) DoJSON(ctx context.Context, method, path string, body any, out any) error + func (c *Client) DoPaginated(ctx context.Context, method, path string, body any, out any) error + func (c *Client) DoRaw(ctx context.Context, method, path string, body any) ([]byte, error) + func (c *Client) EnvID() string + func (c *Client) EnvPath(path string) string + func (c *Client) Get(ctx context.Context, path string) (*http.Response, error) + func (c *Client) Post(ctx context.Context, path string, body any) (*http.Response, error) + func (c *Client) Put(ctx context.Context, path string, body any) (*http.Response, error) + func (c *Client) Request(ctx context.Context, method, path string, body any) (*http.Response, error) + func (c *Client) RequestRaw(ctx context.Context, method, path string, body io.Reader, ...) (*http.Response, error) + func (c *Client) SetEnvironment(envID string) + func (c *Client) SetRetryPolicy(maxAttempts int, baseBackoff, maxBackoff time.Duration) + func (c *Client) SetTimeout(timeout time.Duration) + func (c *Client) TestConnection(ctx context.Context) error + type PaginatedResponse struct + Items []T + Pagination struct{ ... } + func DecodePaginatedResponseStrict[T any](resp *http.Response) (*PaginatedResponse[T], error) + func DecodePaginatedResponse[T any](resp *http.Response) (*PaginatedResponse[T], error) Other modules containing this package github.com/getarcaneapp/arcane/cli