v1

latestOpenAPI 3.0.02026-07-1752017.1 KB

Get posts

Returns a list of posts with at least one content in the published status.

get/api/v1/posts

Query parameters

languagestring

Primary Key (UUID)

Example:a8c4891c-6bc0-4f58-81c6-5e89bb572d4c

Lowercase language code

Response

Example response

{
  "posts": [
    {
      "id": "a8c4891c-6bc0-4f58-81c6-5e89bb572d4c",
      "contents": [
        {
          "id": "a8c4891c-6bc0-4f58-81c6-5e89bb572d4c",
          "slug": "my-first-post",
          "title": "This is a title",
          "subtitle": "This is a subtitle",
          "body": "This is a body",
          "bodyHtml": "<p>This is a body</p>",
          "status": "published",
          "language": "en-us",
          "version": 1,
          "coverUrl": "https://your-subdomain.collections.dev/assets/a8c4891c-6bc0-4f58-81c6-5e89bb572d4c",
          "metaTitle": "This is a meta title",
          "metaDescription": "This is a meta description",
          "publishedAt": "2023-09-29T00:53:20.604Z",
          "author": {
            "id": "a8c4891c-6bc0-4f58-81c6-5e89bb572d4c",
            "name": "John Doe",
            "avatarUrl": "https://your-subdomain.collections.dev/assets/a8c4891c-6bc0-4f58-81c6-5e89bb572d4c",
            "bio": "This is a bio",
            "bioUrl": "https://john-doe.com",
            "employer": "John Doe Inc."
          }
        }
      ]
    }
  ]
}
All 5 operations