Skip to main content
GET
/
api
/
categories
List Categories
curl --request GET \
  --url https://api.example.com/api/categories
{
  "categories": [
    {
      "_id": "507f1f77bcf86cd799439011",
      "name": "Technology",
      "slug": "technology",
      "description": "Articles about technology and innovation",
      "createdAt": "2024-01-15T10:30:00.000Z"
    },
    {
      "_id": "507f1f77bcf86cd799439012",
      "name": "Travel",
      "slug": "travel",
      "description": "Travel guides and tips",
      "createdAt": "2024-01-16T14:20:00.000Z"
    }
  ]
}

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/PhemiT/vaniykeempire-api/llms.txt

Use this file to discover all available pages before exploring further.

Retrieves all categories sorted alphabetically by name. This endpoint is publicly accessible and does not require authentication.

Request

No request body or parameters required.

Headers

No authentication required.

Response

categories
array
Array of category objects
{
  "categories": [
    {
      "_id": "507f1f77bcf86cd799439011",
      "name": "Technology",
      "slug": "technology",
      "description": "Articles about technology and innovation",
      "createdAt": "2024-01-15T10:30:00.000Z"
    },
    {
      "_id": "507f1f77bcf86cd799439012",
      "name": "Travel",
      "slug": "travel",
      "description": "Travel guides and tips",
      "createdAt": "2024-01-16T14:20:00.000Z"
    }
  ]
}

Error Responses

error
string
Error message describing what went wrong

500 - Internal Server Error

{
  "error": "Database connection failed"
}

Example Request

curl https://api.vaniyk-empire.com/api/categories

Build docs developers (and LLMs) love