All endpoints

DocsAPIAccount

POST/brands/apply

Apply a brand version to sites

Checks every named site first (text stays readable, the highlight works there, the ad partner framework's stricter contrast where it applies).

Auth header

Authorization: Bearer tsk_live_…

The key needsbanner:write

Request body

  • brandIdstringrequired
  • versionintegeroptional

    Omitted: the brand's newest version.

  • siteIdsarray of stringrequired
  • modestringrequired

    all: nothing changes unless every site passes. partial: apply where it passes.

    One of all, partial

  • keepSiteChangesbooleanoptional

    Keep what each site changed from its version. Default true.

  • dryRunbooleanoptional

    Run every check and report; change nothing. Default false.

Example request

curl -X POST "https://app.tagsentry.ai/api/v1/brands/apply" \  -H "Authorization: Bearer tsk_live_…" \  -H "Content-Type: application/json" \  -d '{"brandId":"3f6c1b8e-2d4a-4c7e-9a51-0b8f2e6d7c10","version":1,"siteIds":["3f6c1b8e-2d4a-4c7e-9a51-0b8f2e6d7c10"],"mode":"all","keepSiteChanges":false,"dryRun":false}'

Response 200

  • brandIdstringrequired
  • brandNamestringrequired
  • versionnumberrequired
  • modestringrequired

    One of all, partial

  • dryRunbooleanrequired
  • appliednumberrequired

    Sites updated (or, on a dry run, that would be).

  • keptnumberrequired

    Sites left exactly as they were.

  • resultsarray of objectrequired
  • results[].siteIdstringrequired
  • results[].domainstring | nullrequired
  • results[].outcomestringrequired

    One of applied, would_apply, blocked, held, already, not_configured, not_found, failed

  • results[].fromnumber | nullrequired
  • results[].checksobject | nullrequired
  • results[].checks.okbooleanrequired

    True when every check passes.

  • results[].checks.reasonstring | nullrequired

    The first failing check, in one sentence.

  • results[].checks.checksarray of objectrequired
  • results[].checks.checks[].idstringrequired

    One of readable, highlight, tcf

  • results[].checks.checks[].okbooleanrequired
  • results[].checks.checks[].sentencestringrequired
  • results[].keptChangesarray of stringrequired
  • results[].messagestring | nullrequired

Example response

{  "brandId": "3f6c1b8e-2d4a-4c7e-9a51-0b8f2e6d7c10",  "brandName": "…",  "version": 0,  "mode": "all",  "dryRun": false,  "applied": 0,  "kept": 0,  "results": [    {      "siteId": "3f6c1b8e-2d4a-4c7e-9a51-0b8f2e6d7c10",      "domain": "silverpine.example",      "outcome": "applied",      "from": 0,      "checks": {        "ok": false,        "reason": "…",        "checks": [          {            "id": "readable",            "ok": false,            "sentence": "…"          }        ]      },      "keptChanges": [        "…"      ],      "message": "…"    }  ]}
More about this endpoint

mode: all changes nothing unless every site passes; mode: partial updates the passing sites and leaves each failing one as it was, with the reason. Send dryRun: true first: it reports and changes nothing.

Each updated site is PUBLISHED: visitors there get the new look on their next page, and the site's history names this key.

Errors400 · 401 · 403 · 404 · 429 · 500
  • 400The request did not validate against this operation's schema.
  • 401Missing, malformed, unknown, revoked or expired API key. These are deliberately indistinguishable in the response: distinguishing them would confirm to a caller that a token was once real.
  • 403The key authenticated but does not carry the scope(s) this operation requires, or (`domain_not_verified`) the site's domain is not verified, so its consent records are not released.
  • 404No such resource on this account. A site id belonging to a DIFFERENT account answers 404, never 403: a 403 would confirm the id exists somewhere.
  • 429A rate limit or quota was exceeded. The body names WHICH one.
  • 500Something failed on our side. The requestId in the body is what to quote.

Every error has the same body: { error: { code, message, requestId } }.

From the OpenAPI document, version 2026-08-26. Raw OpenAPI