Collections
Collections group related products for a merchant. Collection responses include the collection details, images, and products that belong to the collection.
Collections group related products for a merchant. Collection responses include the collection details, images, and products that belong to the collection.
List Collections
GET /v1/collections
Returns paginated collections for the authenticated token's merchant.
Query Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
page | number | 1 | Page number to return. |
perPage | number | 100 | Number of collections per page. |
search | string | none | Searches collection name, handle, and description. |
Example
const response = await fetch(
'https://api.shopquery.ai/v1/collections?search=summer&page=1&perPage=20',
{
headers: {
Authorization: `Bearer ${accessToken}`,
Accept: 'application/json'
}
}
)
const collections = await response.json()
import axios from 'axios'
const { data: collections } = await axios.get(
'https://api.shopquery.ai/v1/collections',
{
params: {
search: 'summer',
page: 1,
perPage: 20
},
headers: {
Authorization: `Bearer ${accessToken}`,
Accept: 'application/json'
}
}
)
Response
{
"meta": {
"total": 1,
"perPage": 20,
"currentPage": 1,
"lastPage": 1,
"firstPage": 1,
"firstPageUrl": "/v1/collections?page=1",
"lastPageUrl": "/v1/collections?page=1",
"nextPageUrl": null,
"previousPageUrl": null
},
"data": [
{
"id": "col_abc123",
"name": "Summer Picks",
"handle": "summer-picks",
"description": "Warm weather favourites.",
"status": "published",
"images": [],
"products": [
{
"id": "prd_abc123",
"handle": "classic-shirt",
"quantity": 24,
"price": 29.99,
"currency": "USD",
"status": "published",
"featured": false,
"hidePrice": false,
"title": "Classic Shirt",
"images": []
}
],
"createdAt": "2026-05-13T10:00:00.000+00:00",
"updatedAt": "2026-05-13T10:00:00.000+00:00"
}
]
}