Accent

The web API

Entity routes, the composition verb, and JSON delivery.


Everything the admin does rides an HTTP API you can call yourself. Three lanes matter most; the full route census with permissions lives in Route census & permissions and the request/response shapes in Web API reference.

Entity routes

Per-entity CRUD under /api/cms/sites/:siteId/… — pages, records, content types, templates, layouts, fields, taxonomies. Notes that matter:

  • Template PUT (/templates/:templateId) accepts { title, html, metadataFields? }; mark the page-body region with data-accent-content on an element (legacy <%- content %> shells keep working). The file is mirrored to the site's internal render root.
  • Binding writes are plain writes — a region-less template is legal static output, and nothing warns or blocks.
  • Writes validate ids against the slug contract and reject loudly; nothing is silently normalized on the API lane.

The composition verb (zones)

Machine-lane page composition addresses named zones, never positions:

POST /api/cms/sites/:siteId/assets/:assetId/embeds
     { zone, position, partial/type ref, data }
PUT  …/embeds/:instanceId          — update a placed instance
POST …/embeds/:instanceId/promote  — promote inline content to a reference

Zones are the regions described in chapter 4: the Page-content slot answers to primary; authored regions answer to their data-zone id. This is the lane agents and importers use — including Mark.

JSON delivery

Content leaves as data, Contentful-style: single-record JSON per asset, plus a collection/query endpoint over a site's assets (filter by type, parent, branch; sort; paginate). Pair with the publish pipeline's expose flags to make a site a headless source.

Deep records

Web API reference, Route census & permissions, Composition API design record ("Verb 1 design: named targets, not positions").