stylehub.cloud

API documentation

Reading a manual

On this page

One request returns the whole manual: every published section in the order of the page, every block inside it, and the anchor each one carries so a link built from the answer lands where the page lands.

Request

Endpoint
GET https://stylehub.cloud/api/v1/manuals/{slug}.json

The slug

acme
The brand's subdomain, for its primary manual: the one at https://acme.stylehub.cloud.
acme.guidelines
Brand and manual, for any other manual of the brand: the one at https://acme.stylehub.cloud/guidelines.
guidelines
A manual's own subdomain, when it has one: the one at https://guidelines.stylehub.cloud.

On a brand's own host or a custom domain the same path answers, and the host names the brand. The dashboard prints the exact address of every manual under API (opens in a new tab). A slug that names no published manual answers 404; a manual past its end date answers 410. See Errors.

Headers

Authorization
Bearer and a token, for a private or password protected manual. See Tokens and authentication.
If-None-Match
The ETag of the answer you already have. An unchanged manual answers 304 with no body. See Caching.

Example

GET acme.json
curl -sS https://stylehub.cloud/api/v1/manuals/acme.json \
  -H "Accept: application/json" | jq '.title, .sections[].title'

Response

JSON
{
  "id": "cm2...",
  "slug": "acme",
  "title": "Acme brand manual",
  "description": "",
  "url": "https://acme.stylehub.cloud",
  "visibility": "public",
  "updatedAt": "2026-09-03T10:12:00.000Z",
  "expiresAt": null,
  "sections": [
    {
      "id": "cm2...",
      "anchor": "colors",
      "url": "https://acme.stylehub.cloud#colors",
      "title": "Colors",
      "content": {},
      "blocks": [
        {
          "id": "b1",
          "anchor": "color",
          "url": "https://acme.stylehub.cloud#color",
          "type": "COLORS",
          "label": "Color",
          "content": { "colors": [{ "name": "Forest", "hex": "#0f5132" }] }
        }
      ]
    }
  ]
}

The manual

FieldTypeMeaning
idstringThe manual's id. Stable for its whole life.
slugstringThe manual's own slug, as saved in its settings.
titlestringThe title.
descriptionstringThe meta description from the SEO settings, or an empty string.
urlstringThe public address of the manual.
visibilitystringpublic, unlisted, private or password.
updatedAtstringWhen the manual last changed, as an ISO 8601 date in UTC.
expiresAtstring or nullThe end date, if the manual has one. After it the address answers 410.
sectionsarrayThe published sections, in the order of the page.

A section

FieldTypeMeaning
idstringThe section's id.
anchorstringThe anchor the page gives it. Made once and kept when the title changes.
urlstringThe manual's address with the anchor, so it opens at this section.
titlestringThe heading.
contentobjectWhat the section holds beside its blocks, such as an intro. Often empty.
blocksarrayThe blocks, in order.

A block

FieldTypeMeaning
idstringThe block's id.
anchorstringIts anchor on the page.
urlstringThe manual's address with the anchor.
typestringThe kind of block, as a constant such as COLORS, LOGO or TEXT.
labelstringThe kind's name as the product shows it, such as Color.
contentobjectWhat the block stores. Its shape depends on the kind.

Rich text is HTML. What each kind of block stores is described, kind by kind, in Every block, and what it holds; the JSON carries the same fields the editor offers. A section saved before blocks existed is served as one block of the section's kind, at the section's own anchor.

What is not in the answer

  • Sections kept off the page.
  • Blocks marked internal, and blocks with nothing in them.
  • Changes still waiting for review. A manual that reviews changes before publishing is served as its approved version, the same one the page shows.
  • Comments, history, and anything else that is not on the published page.

Anchors are for linking

Each url in the answer is the page opened at that section or block. A guideline quoted somewhere else can link straight to the block it came from, and the link keeps working when the title is edited: the anchor is made once, on the first save, and then kept.

Headers on the answer

ETag
A fingerprint of the answer. Send it back as If-None-Match.
Cache-Control
A minute for a public or unlisted manual read with no token; no caching when a token was sent.
X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Reset
Where you stand. See Rate limits.

Something the API does that this page does not say? Write to hello@stylehub.cloud with the request and the answer you got.

Reading a manual - API - Stylehub