Retrieve a Post Category
Returns the details of a specified Post Category, including related posts. You can use either the category slug or ID. This endpoint is only available in Spree 5.2 or later.
GET
Retrieve a Post Category
Documentation Index
Fetch the complete documentation index at: /docs/llms.txt
Use this file to discover all available pages before exploring further.
Returns the details of a specified Post Category, including related posts. You can use either the category slug or ID. This endpoint is only available in Spree 5.2 or later.
const options = {method: 'GET'};
fetch('https://demo.spreecommerce.org/api/v2/storefront/post_categories/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request GET \
--url https://demo.spreecommerce.org/api/v2/storefront/post_categories/{id}{
"data": {
"id": "3",
"type": "post_category",
"attributes": {
"title": "News",
"slug": "news",
"created_at": "2025-08-11T20:58:24.375Z",
"updated_at": "2025-08-11T20:58:24.375Z",
"description": null
},
"relationships": {
"posts": {
"data": [
{
"id": "1",
"type": "post"
}
]
}
}
}
}{
"error": "The resource you were looking for could not be found."
}Was this page helpful?
const options = {method: 'GET'};
fetch('https://demo.spreecommerce.org/api/v2/storefront/post_categories/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request GET \
--url https://demo.spreecommerce.org/api/v2/storefront/post_categories/{id}{
"data": {
"id": "3",
"type": "post_category",
"attributes": {
"title": "News",
"slug": "news",
"created_at": "2025-08-11T20:58:24.375Z",
"updated_at": "2025-08-11T20:58:24.375Z",
"description": null
},
"relationships": {
"posts": {
"data": [
{
"id": "1",
"type": "post"
}
]
}
}
}
}{
"error": "The resource you were looking for could not be found."
}