Collections
List all collections
AuthorizationBearer <token>
In: header
Query Parameters
help_center_idinteger
ID of the help center
starting_after?string|null
Cursor for pagination of top-level collections (only needed for subsequent pages)
per_page?integer|null
Number of top-level collections per page (1-100, default 30)
Default
30Range
1 <= value <= 100collection_id?integer
When provided, returns only the direct child collections under this parent collection (paginated).
When omitted, returns collections based on the is_root parameter.
is_root?boolean
Controls which collections are returned when collection_id is not provided.
true — returns only root-level collections (flat list, no sub-collections).
false (default) — returns root collections each with their direct child collections nested inside a sub_collections array.
Default
falseResponse Body
application/json
application/json
application/json
application/json
application/json
curl -X GET "https://app.sparrowdesk.com/v1/collections?help_center_id=994"{
"data": [
{
"id": 1201,
"name": "Getting started",
"description": "Everything you need to get up and running.",
"icon": "📘",
"slug": "getting-started",
"level": 1,
"help_center_id": 994,
"brand_id": 1,
"parent_collection_id": null,
"root_collection_id": null,
"parent_collection": {
"id": 1200,
"name": "Support",
"slug": "support"
},
"root_collection": {
"id": 1200,
"name": "Support",
"slug": "support"
},
"position": "a4",
"subcollections_count": 2,
"articles_count": 10,
"published_articles_count": 8,
"is_last_level_sub_collection": false,
"created_at": 0,
"updated_at": 0,
"sub_collections": [
{}
]
}
],
"pages": {
"per_page": 30,
"next_cursor": "string",
"next_url": "string"
},
"total_count": 3
}{
"error": {
"message": "Invalid cursor"
}
}{
"error": {
"message": "Missing required scope or product feature is not enabled for this account."
}
}{
"error": {
"message": "Invalid help_center_id"
}
}{
"error": {
"message": "An unexpected error occurred while loading collections."
}
}