> For the complete documentation index, see [llms.txt](https://docs.overflowcms.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.overflowcms.com/api-reference/overview.md).

# Overview

## API Reference

The public surface OverflowCMS exposes to a Webflow site: a read-only JSON API and the `embed.js` script that consumes it. Everything here is served by one Worker at:

```
https://cdn.overflowcms.com
```

This is the same host for every site — what scopes a request to *your* content is the public token in the URL (see Authentication).

### What's public vs. not

This API only ever serves **published** content — drafts, scheduled-but-not-due items, and unpublished collections are never reachable through it, regardless of token. There is no write access on this API at all; authoring happens through the dashboard (backed by a separate, session-authenticated admin API that isn't part of this public surface).

### Response conventions

* JSON everywhere, `Content-Type: application/json`.
* CORS is wide open (`*`) on every `/v1/*` route — this is public data by definition, meant to be fetched from any origin.
* List responses are shaped `{ items, page, limit, total, totalPages }`.
* Single-item responses are shaped `{ item }`.
* Errors are shaped `{ error: { code, message } }` — see Errors.
* List responses are edge-cached (`Cache-Control: public, s-maxage=31536000`) and invalidated automatically on publish/unpublish — you don't need to cache-bust anything client-side.

<table data-view="cards"><thead><tr><th></th><th></th><th></th><th data-hidden data-card-target data-type="content-ref"></th></tr></thead><tbody><tr><td><h4><i class="fa-key">:key:</i></h4></td><td><strong>Authentication</strong></td><td>The public token model — what it is, where to find it, what it grants.</td><td></td></tr><tr><td><h4><i class="fa-list">:list:</i></h4></td><td><strong>Collections &#x26; Items</strong></td><td>The two read endpoints, full query grammar, and response shapes.</td><td></td></tr><tr><td><h4><i class="fa-code">:code:</i></h4></td><td><strong>Embed Script Reference</strong></td><td>Every data-oc-* attribute and the two DOM events the script dispatches.</td><td></td></tr><tr><td><h4><i class="fa-database">:database:</i></h4></td><td><strong>Field Types &#x26; Data Shapes</strong></td><td>Exactly what JSON shape each of the 9 field types serializes to.</td><td></td></tr></tbody></table>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.overflowcms.com/api-reference/overview.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
