Content API
Content items have three fixed fields: title, body, and status. All other fields are stored in metadata(JSON), shaped by the content type's custom fields.
/api/content?site_id=SITE_IDInternalList content items. Supports filtering, pagination, and dynamic metadata queries.
Query Parameters
| Param | Type | Required | Description |
|---|---|---|---|
| site_id | string | Yes | The site UUID |
| content_type_id | string | No | Filter by content type |
| status | string | No | "published" or "draft" |
| limit | number | No | Max results (default 50, max 100) |
| offset | number | No | Skip N results (for pagination) |
| meta.* | string | No | Filter by any metadata field (see below) |
Dynamic Metadata Filters
Use meta.FIELD_SLUG=value to filter by any custom field in metadata. Works for both array fields (tags, multiselect) and scalar fields (text, select).
# Blog posts with tag "devlog" curl "multi-site-manager.vercel.app/api/content?site_id=SITE_ID&meta.tags=devlog" # Posts by a specific author curl "multi-site-manager.vercel.app/api/content?site_id=SITE_ID&meta.author=JhonaMath" # Easy recipes, published only, limit 5 curl "multi-site-manager.vercel.app/api/content?site_id=SITE_ID&meta.difficulty=easy&status=published&limit=5" # Combine: blog posts with tag "gamejam" by "JhonaMath" curl "multi-site-manager.vercel.app/api/content?site_id=SITE_ID&content_type_id=TYPE_ID&meta.tags=gamejam&meta.author=JhonaMath"
/api/contentInternalCreate a content item. Custom field values go in metadata.
Request Body
| Param | Type | Required | Description |
|---|---|---|---|
| site_id | string | Yes | The site UUID |
| content_type_id | string | No | Content type UUID |
| title | string | Yes | Content title |
| slug | string | No | URL-friendly identifier |
| body | string | No | Content body (markdown) |
| metadata | object | No | Custom field values (e.g. { "tags": ["devlog"], "author": "JhonaMath" }) |
| status | string | No | "draft" (default) or "published" |
curl -X POST multi-site-manager.vercel.app/api/content \
-H "Content-Type: application/json" \
-d '{
"site_id": "SITE_ID",
"content_type_id": "BLOG_TYPE_ID",
"title": "My First Post",
"slug": "my-first-post",
"body": "# Welcome\nThis is my first post.",
"metadata": {
"excerpt": "A short intro to my blog",
"cover-image": "https://example.com/img.jpg",
"author": "JhonaMath",
"tags": ["devlog", "gamejam"],
"read-time": "5 min"
},
"status": "published"
}'/api/content/:contentIdInternalGet a single content item with its content type and metadata.
/api/content/:contentIdInternalUpdate a content item. Only send fields you want to change.
Request Body
| Param | Type | Required | Description |
|---|---|---|---|
| title | string | No | Updated title |
| slug | string | No | Updated slug |
| body | string | No | Updated body |
| metadata | object | No | Updated custom fields |
| status | string | No | "draft" or "published" |
| content_type_id | string | No | Change content type |
/api/content/:contentIdInternalDelete a content item.