Basker Docs

Response format

Response shapes for list, record, write, and error requests

Partners API responses use JSON. The shape depends on whether an endpoint returns a collection, one record, or an operation result.

List responses

Collection GET endpoints return a docs array with pagination metadata:

{
  "docs": [
    { "id": "000000000000000000000007", "title": "Moonlit Echoes" }
  ],
  "totalDocs": 47,
  "limit": 10,
  "totalPages": 5,
  "page": 1,
  "pagingCounter": 1,
  "hasPrevPage": false,
  "hasNextPage": true,
  "prevPage": null,
  "nextPage": 2
}

totalDocs is the total matching the request's filters, not the number on the current page. When pagination=false, pagination fields may be absent.

Record responses

A single-record GET returns the record directly, rather than wrapping it in docs:

{
  "id": "000000000000000000000007",
  "title": "Moonlit Echoes",
  "slug": "moonlit-echoes"
}

The exact fields depend on the resource, API version, and requested field selection.

Write responses

RequestSuccess statusResponse
POST201Created record
PATCH or PUT200Updated record
DELETE200Deleted record
Dedicated mutation200Mutation summary and/or updated record, as documented by that endpoint

Standard writes accept the same response-shaping query controls as record reads. Dedicated block, theme-setting, and bulk operations have endpoint-specific result shapes in the API reference.

Normalized record data

The Partners API turns CMS records into an integration-friendly shape before returning them:

  • Rich-text fields can include an _html companion field.
  • Relationship wrappers become plain records, arrays, or IDs according to depth and populate.
  • Block fields are flattened under each block's value.
  • Configured attributes are exposed under attributes.custom.
  • Internal tenancy, locking, rendering, and private integration fields are removed, including nested occurrences.

Treat the Partners API response, not an admin or internal API response, as the contract for your integration.

Error responses

A typical error includes a category, message, and request identifier:

{
  "error": "Unauthorized",
  "message": "Valid API key required",
  "requestId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890"
}

Validation errors can also include an errors array with field-level details. Some errors raised before request context is established may omit requestId. Log the status, body, and request identifier when asking Basker support to investigate.

See Errors for status-specific guidance.

On this page