Skip to main content

Filtering lists

List endpoints share one query mini-language: append an operator to a filterable field in square brackets. A bare field means exact match.
A field sent more than once (?status=a&status=b) is rejected - pass multiple values with [in] instead. A query holds at most 16 conditions, a list at most 50 values, and a value at most 256 characters.
sort: comma-separated fields, minus prefix for descending: sort=-created_at,name. Each endpoint’s description lists its sortable fields. Page size and cursors are covered under Pagination.
Filtering, sorting or searching on an undeclared field returns invalid_request with one entry per violation in the errors array. The queryable surface of every endpoint is exactly its documented parameter list, nothing more.

Paginating lists

List responses are cursor-paginated. Every list carries a page block. Walk forward by passing end_cursor as after, backward by passing start_cursor as before:
The page block
  • Cursors are opaque. Never parse or construct one, and their internal structure changes without notice.
  • A cursor is only valid for the same listing (same sort) that minted it. Anything else returns invalid_request.
  • after and before cannot be combined.
  • Paging is position-based, not offset-based: page 100 costs the same as page 1, and rows created between requests never shift your window.
  • limit is 1-100, default 25. Both cursors are null on an empty page.

Expanding responses

Many objects let you request related resources inline instead of making a second call, using the expand[] query parameter. Unexpanded responses keep the payload small. Each expansion is loaded only when you ask for it.
Requesting a property that is not expandable on that endpoint returns an invalid_request error naming the offending path in its errors array, expandable properties are a fixed, per-endpoint list, always documented on the endpoint’s page.

Example: company with its account

GET /v1/companies/{id}?expand[]=account embeds the full account beside the account_id it would otherwise return alone.
array of strings
Relations to embed in the response. Not requested, the property is absent.
Expanded response