AstraCMS
Tags

Get a single tag

Get a single tag by slug or ID, optionally including related posts

GET
/v1/{workspaceId}/tags/{identifier}

Path Parameters

workspaceId*string

Workspace identifier

identifier*string

Tag slug or ID

Query Parameters

limit?string

Number of posts per page when including posts

Default"10"
page?string

Page number for pagination when including posts

Default"1"
include?string

Related resources to include (e.g., posts)

Response Body

application/json

application/json

application/json

application/json

curl -X GET "https://api.astracms.dev/v1/my-workspace/tags/javascript"
{
  "id": "clx3y5a7c9e1g3i5k7m9o",
  "name": "JavaScript",
  "slug": "javascript",
  "description": "JavaScript programming",
  "count": {
    "posts": 42
  }
}
{
  "error": "string",
  "details": null,
  "message": "string"
}
{
  "error": "string",
  "details": null,
  "message": "string"
}
{
  "error": "string",
  "details": null,
  "message": "string"
}

Last updated on