Authors
List authors
Get a paginated list of authors with post counts
Authorization
ApiKeyAuth AuthorizationBearer <token>
API key for V2 endpoints. Use format: Bearer {your_api_key}. Get your key from the AstraCMS dashboard.
In: header
Query Parameters
limit?string
Number of authors per page
Default
"10"page?string
Page number for pagination
Default
"1"include?string
Related resources to include (e.g., posts)
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
curl -X GET "https://api.astracms.dev/v2/authors"{
"authors": [
{
"id": "clx1a2b3c4d5e6f7g8h9i",
"name": "John Doe",
"image": "https://example.com/avatar.jpg",
"slug": "john-doe",
"bio": "Tech writer and developer",
"role": "Senior Developer",
"socials": [
{
"url": "https://twitter.com/johndoe",
"platform": "twitter"
}
],
"count": {
"posts": 25
}
}
],
"pagination": {
"limit": 10,
"currentPage": 1,
"nextPage": 2,
"previousPage": null,
"totalPages": 5,
"totalItems": 48
}
}{
"error": "Bad Request",
"details": null,
"message": "Additional error context"
}{
"error": "Unauthorized",
"message": "Missing or invalid API key"
}{
"error": "Forbidden",
"message": "Insufficient permissions for this resource"
}{
"error": "Too Many Requests",
"message": "Rate limit exceeded. Please try again later.",
"retryAfter": 60
}{
"error": "Bad Request",
"details": null,
"message": "Additional error context"
}Last updated on