Skip to main content
GET
cURL
How the server goes from page_url to a fragment, and from a fragment to a card: resolution and card selection.

Authorizations

X-API-Key
string
header
required

The publisher's API key, kept out of the request URL. Whitespace around the value is trimmed.

Headers

X-Agent-UA
string

Preferred agent User-Agent reporting channel. A trimmed non-empty value takes precedence over agent_ua and User-Agent. Reporting only: it does not affect card selection.

X-DS-Record-Id
string<uuid>

The caller's own id for the page being served (the edge library sends its page record id, a UUIDv7). Kept with the delivery, lowercased, when it has the shape of a UUID (any version); any other value is ignored, never an error. It does not affect authentication, selection or the response. Caller-supplied: it is not unique.

User-Agent
string

Fallback reporting value when neither X-Agent-UA nor agent_ua yields a non-empty value. It does not gate serving, affect card selection, or cause a Vary response header.

Query Parameters

partner_id
string
required

Publisher account id. The API key must belong to this account (403 otherwise). An absent or empty value answers 400.

Minimum string length: 1
page_url
string
required

The page being served. Its host finds the account's site; its path (the query string and the hash are not used) finds the fragment; its page key (normalised host + path) seeds the card choice. A value without a scheme (host/path) is read as https. An absent or empty value answers 400. Once the HEAD and parameter checks pass, a value over 2,048 characters, or one that is not an http(s) URL with a dotted host, answers 204 before authentication, without any database read.

format
string
default:html

Response representation. The exact value json returns the card payload as JSON; both returns JSON containing the card payload and rendered HTML. Omission, html, and every other value return HTML, so the request value is intentionally not modeled as a closed enum.

agent_ua
string

Agent User-Agent for reporting only. A trimmed, non-empty X-Agent-UA header takes precedence; otherwise this value is trimmed, and an empty result falls through to User-Agent.

Response

A card is returned when the API key is valid for partner_id, page_url resolves to a fragment of the account (routing rule or site default) that is not paused, selection finds an eligible card, and the selected stored payload parses and passes validation. Body per format: format=json returns CardPayload; format=both returns CardAndHtml; every other format value returns rendered HTML. X-ABC-Resolution says how the fragment was resolved.

The response is of type string.