Versions in this module Expand all Collapse all v1 v1.0.0 Nov 20, 2026 Changes in this version + const Version + var ErrAuthentication = errors.New("axioapi: authentication failed") + var ErrInsufficientCredits = errors.New("axioapi: insufficient credits") + var ErrNotFound = errors.New("axioapi: not found") + var ErrRateLimit = errors.New("axioapi: rate limited") + var ErrValidation = errors.New("axioapi: validation failed") + type APIError struct + Body json.RawMessage + Code string + Fields map[string][]string + Message string + RequestID string + RetryAfter float64 + Status int + func (e *APIError) Error() string + func (e *APIError) Is(target error) bool + type Client struct + func New(apiKey string, opts ...Option) (*Client, error) + func (c *Client) Call(ctx context.Context, operation string, params Params) (json.RawMessage, error) + func (c *Client) CallBinary(ctx context.Context, operation string, params Params) ([]byte, error) + func (c *Client) CallInto(ctx context.Context, operation string, params Params, out any) error + func (c *Client) Group(name string) *Group + func (c *Client) Operations() map[string]Operation + func (c *Client) Request(ctx context.Context, method, path string, query url.Values, body any) (*Response, error) + func (c *Client) Resolve(group, name string) (string, bool) + type ConnectionError struct + Message string + func (e *ConnectionError) Error() string + type Group struct + func (g *Group) Call(ctx context.Context, operation string, params Params) (json.RawMessage, error) + func (g *Group) CallBinary(ctx context.Context, operation string, params Params) ([]byte, error) + type Operation struct + Binary bool + Body []string + Cost *float64 + Key string + Method string + Path string + PathParams []string + Query []string + Summary string + type Option func(*Client) + func WithBaseURL(u string) Option + func WithHTTPClient(h *http.Client) Option + func WithMaxRetries(n int) Option + func WithSleep(f func(context.Context, time.Duration) error) Option + func WithUserAgent(ua string) Option + type Params map[string]any + type Response struct + Bytes []byte + Data json.RawMessage + Envelope json.RawMessage + Header http.Header + Status int