API Reference
Complete REST API documentation for accessing your content
Content Type API
For each Content-Type you create, the following endpoints are automatically generated. All endpoints require Bearer token authentication.
GET
/v1/:pluralNameGet a list of documents
Retrieve all published documents from a content-type. Only returns published content if draft/publish is enabled.
GET
/v1/:pluralName/:documentIdGet a document
Retrieve a specific published document by ID. Only returns the document if it's published (when draft/publish is enabled).
POST
/v1/:pluralNameCreate a document
Create a new document in the content-type. The document will be created with the data provided in the request body.
PUT
/v1/:pluralName/:documentIdUpdate a document
Update an existing document by ID. Only the fields provided in the request body will be updated.
DELETE
/v1/:pluralName/:documentIdDelete a document
Delete a document by ID. This action is permanent and cannot be undone.
📌 Important Notes
- •Authentication Required: All endpoints require Bearer token authentication. Include your project API key in the Authorization header.
- •Plural Names: Always use the plural name of your content-type in the URL (e.g., "articles" not "article", "restaurants" not "restaurant"). You can find this in the Content-Type Builder.
- •Media URLs: Media fields are automatically transformed to full CDN URLs in the response.
Example Response
{
"data": [
{
"_id": "507f1f77bcf86cd799439011",
"title": "Getting Started with Meshbase",
"slug": "getting-started-with-meshbase",
"content": "Meshbase is a modern headless CMS...",
"author": "John Doe",
"status": "published",
"publishedAt": "2024-01-15T10:30:00Z",
"createdAt": "2024-01-15T10:30:00Z",
"updatedAt": "2024-01-15T10:30:00Z"
}
],
"meta": {
"pagination": {
"total": 42,
"limit": 100,
"skip": 0,
"hasMore": false
}
}
}