This page is a tour of each surface. Deeper API references live in the REST API and GraphQL API tabs.
REST
Endpoint shape:x-api-key header:
- Backend services pulling content for SSR.
- Cron jobs syncing content to other systems.
- Bulk operations (import/migrate/archive).
GraphQL
Endpoint:- Web apps that need to fetch only the fields they render.
- Mobile apps that want to batch related queries.
- Any client where reducing roundtrips matters.
Native SDKs
The iOS and Android SDKs wrap this GraphQL API with a local cache and BindJS rendering. On iOS,MetabindClient exposes async fetchers — fetchContent(id:) for a single entry and fetchContents(typeId:limit:) for a list — plus streamContent(id:) and subscribeToContent(id:) for cache-then-network and live streams. The Android SDK exposes coroutine and Flow equivalents through ComponentRepository.
For installation, configuration, and rendering, see the Mobile SDKs:
iOS SDK
MetabindContent — fetch and render content with SwiftUI.Android SDK
metabind-content-android — fetch and render content with Compose.Choosing draft or production
REST and GraphQL requests made with an API key return published content only; neither has a draft flag. To read draft content, create a preview link and pass its token to the GraphQLpreview query:
Caching
Caching is on by default at the CDN edge for published content. Cache keys include the project, content type, query parameters, and locale. Invalidation:- Automatic. Publishing or unpublishing an entry invalidates that entry’s cached responses within seconds.
Pagination
Both APIs use cursors:- REST.
?limit=10&lastKey=<lastKey>— passpagination.lastKeyfrom the previous response to get the next page. - GraphQL.
cursorandlimitarguments; responses includepagination { cursor hasMore }.
cursor and limit arguments; pass the returned cursor to get the next page.
Filtering
REST supports filter parameters per content type. GraphQL exposes typed filter inputs:Resolved content
Content can be returned resolved, with its compiled code and the package data needed to render it. Avoids round trips for client rendering:/content/resolved endpoint with similar behavior.
When to use which
A few rules of thumb:- Native mobile app? Use the iOS/Android SDK. They handle caching, offline, and pair cleanly with BindJS.
- Web app? Use GraphQL. Flexible queries, single-request data fetching, subscriptions for live updates.
- Backend service? REST. Simple, well-cached, works with any HTTP client.
- MCP App? Use a Data Tool that calls REST or GraphQL. The Data Tool pattern abstracts content fetching behind an AI-callable surface.
Related
REST API
Full REST reference.
GraphQL API
Schema, queries, subscriptions.
Mobile SDKs
iOS and Android client libraries.
AI content creation
AI-driven content workflows.