Skip to main content
The anny API follows the JSON-API v1.1 specification. This guide covers the conventions you need to know when making requests.

Content Type

Write operations use the JSON-API media type:
Standard application/json is not accepted for POST and PATCH operations. For GET requests, the API also accepts:
Some read-oriented and UI-oriented endpoints return normalized application/json payloads instead of JSON-API resources. Webhook deliveries are always sent as application/json.

Resource Objects

Every API response wraps data in a JSON-API resource object:
Collection responses return "data": [...] as an array.

Common Headers

Tenant Context

Admin API requests require an organization context. Pass it as a query parameter:
The backend resolves the active organization from:
  1. The tenant claim in the JWT (if present), or
  2. The o query parameter
For explicit control, always include ?o={organization_id}.
Use the include parameter to sideload related resources in a single request, avoiding N+1 round-trips:
Nested relationships use dot notation. The response adds an included array:
Each resource type defines its own set of allowed include paths. Requesting an unsupported path returns a 400 error.

Sparse Fieldsets

Request only the attributes you need to reduce payload size:
This returns only the listed attributes for each resource type.

Filtering

Filter collections using the filter query parameter.

Simple Filters

Multiple Values

Repeat the filter key with [] to pass multiple values as an OR condition:

Date Range Filters

Range filters use nested from and to keys:
Full-text search across indexed fields:

Custom Field Filters

Filter by custom field values using the field’s UUID:
Each custom field filter entry requires:
Available filters vary per resource. Requesting an unsupported filter returns a 400 error.

Sorting

Sort results with the sort parameter. Prefix with - for descending:
Multiple sort fields are comma-separated:
Each resource type defines its allowed sort parameters. The default sort varies per resource.

Pagination

The API uses offset-based pagination:

Response Metadata

Paginated responses include navigation links:

Creating and Updating Resources


Error Responses

Errors follow the JSON-API error format:

Common Status Codes


Combining Parameters

All query parameters can be combined in a single request: