Articles API
The Articles API provides read-only access to your published articles — blog posts, news items, and any long-form content managed through Adapto CMS.
Endpoints Overview
| Method | Endpoint | Description |
|---|---|---|
GET | /public/articles | List articles (paginated) |
GET | /public/articles/preview | List article previews (lightweight) |
GET | /public/articles/{article_id} | Get article by ID |
GET | /public/articles/by-slug/{slug} | Get article by slug |
GET | /public/articles/{article_id}/translations | Get all translations of an article |
List Articles
GET /public/articlesReturns a paginated list of articles. Supports filtering, sorting, and pagination.
Query Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
status | string | No | Filter by status: draft, published, archived |
category | string | No | Filter by category ID |
tag | string | No | Filter by tag |
keyword | string | No | Search in title and content |
language | string | No | Filter by language code (e.g. en) |
field | string | No | Sort field |
order | string | No | Sort order: asc or desc |
page | integer | No | Page number (default: 1) |
limit | integer | No | Items per page (default: 20) |
Example Request
curl -X GET "https://api.adaptocms.com/public/articles?language=en&status=published&limit=5" \
-H "x-api-key: YOUR_API_KEY"Example Response
{
"items": [
{
"id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"title": "Getting Started with Adapto CMS",
"content": "<p>Welcome to Adapto CMS...</p>",
"slug": "getting-started-with-adapto-cms",
"author": "Editorial Team",
"source": {
"type": "internal",
"name": "Dashboard"
},
"categories": ["cat-id-1", "cat-id-2"],
"tags": ["tutorial", "beginner"],
"summary": "A comprehensive guide to getting started.",
"language": "en",
"status": "published",
"created_at": "2026-01-15T10:30:00",
"updated_at": "2026-02-01T14:20:00",
"published_at": "2026-01-20T09:00:00",
"media_objects_placements": [],
"custom_fields": {},
"translation_of_id": null,
"file_urls": null
}
],
"total": 42,
"page": 1,
"limit": 5,
"pages": 9
}List Articles Preview
GET /public/articles/previewReturns a lightweight paginated list of articles without the content, custom_fields, file_urls, or media_objects_placements fields. Ideal for article listings, sitemaps, and navigation where you don't need the full body.
Accepts the same query parameters as GET /public/articles.
Example Request
curl -X GET "https://api.adaptocms.com/public/articles/preview?language=en&limit=10" \
-H "x-api-key: YOUR_API_KEY"Example Response
{
"items": [
{
"id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"title": "Getting Started with Adapto CMS",
"slug": "getting-started-with-adapto-cms",
"author": "Editorial Team",
"source": {"type": "internal", "name": "Dashboard"},
"categories": ["cat-id-1"],
"tags": ["tutorial"],
"summary": "A comprehensive guide to getting started.",
"language": "en",
"status": "published",
"created_at": "2026-01-15T10:30:00",
"updated_at": "2026-02-01T14:20:00",
"published_at": "2026-01-20T09:00:00",
"translation_of_id": null
}
],
"total": 42,
"page": 1,
"limit": 10,
"pages": 5
}Get Article by ID
GET /public/articles/{article_id}Retrieve a single article by its unique ID.
Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
article_id | string (UUID) | Yes | The unique identifier of the article |
Example Request
curl -X GET "https://api.adaptocms.com/public/articles/a1b2c3d4-e5f6-7890-abcd-ef1234567890" \
-H "x-api-key: YOUR_API_KEY"Example Response
Returns a single ArticleResponseModel object (see Data Models).
Get Article by Slug
GET /public/articles/by-slug/{slug}Retrieve a single article by its URL-friendly slug. This is typically used for routing in front-end applications.
Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
slug | string | Yes | The URL-friendly slug of the article |
Example Request
curl -X GET "https://api.adaptocms.com/public/articles/by-slug/getting-started-with-adapto-cms" \
-H "x-api-key: YOUR_API_KEY"Get Article Translations
GET /public/articles/{article_id}/translationsRetrieve all translations of a given article. Returns an array of ArticleResponseModel objects, one per language.
Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
article_id | string (UUID) | Yes | The ID of the source article |
Example Request
curl -X GET "https://api.adaptocms.com/public/articles/a1b2c3d4-e5f6-7890-abcd-ef1234567890/translations" \
-H "x-api-key: YOUR_API_KEY"Example Response
[
{
"id": "f1e2d3c4-b5a6-7890-abcd-ef0987654321",
"title": "Premiers pas avec Adapto CMS",
"content": "<p>Bienvenue sur Adapto CMS...</p>",
"slug": "premiers-pas-avec-adapto-cms",
"author": "Équipe éditoriale",
"language": "fr",
"status": "published",
"translation_of_id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
...
}
]Use Case: Language Switcher
Use this endpoint to build a language switcher in your front-end. Fetch the translations of the current article and render links to each available language:
// JavaScript example
const translations = await fetch(
`https://api.adaptocms.com/public/articles/${articleId}/translations`,
{ headers: { 'x-api-key': API_KEY } }
).then(r => r.json());
// Build language links
const languageLinks = translations.map(t => ({
language: t.language,
slug: t.slug,
title: t.title
}));