| Send | Permission | Community scope |
|---|---|---|
Authorization: Bearer <apiKey> | store | Community scope is derived from the key; do not send a community identifier. |
{pathParameter} and use the query parameters documented below.meta.code = CATEGORY_RETRIEVED{
"meta": {
"status": "success",
"statusCode": 200,
"code": "CATEGORY_RETRIEVED"
},
"message": "Get Store category by ID successfully",
"data": {
"_id": "cat_agent_01",
"name": "Agent Test Rewards",
"displayOrder": 10
}
}meta.code, never message text.| HTTP | Machine code | What the caller should do | Retry? |
|---|---|---|---|
| 400 | VALIDATION_FAILED | Repair the path ID. | No, fix first |
| 401 | AUTH_API_KEY_REQUIRED | Add the Authorization header. | No, fix first |
| 401 | AUTH_API_KEY_INVALID | Replace or rotate the key. | No, fix first |
| 401 | AUTH_API_KEY_VALIDATION_FAILED | Authentication could not be completed. | Yes, with backoff |
| 403 | AUTH_PERMISSION_REQUIRED | Request the store permission; no resource data is returned. | No, fix first |
| 404 | STORE_RESOURCE_NOT_FOUND | Refresh the category list. | After refreshing the ID |
| 502 | STORE_DEPENDENCY_UNAVAILABLE | Retry after a short backoff; the Store dependency is unavailable. | Yes, with backoff |
| 500 | INTERNAL_ERROR | Retry with exponential backoff and the same request context, then escalate. | Yes, with backoff |
defaultPurchaseStatusID is the effective status: a non-null stored category override wins; otherwise the active community new_purchase default is returned; it is null when neither exists.categoryPermission[].permission exposes roles, tags, users, combination, and isSelectAll only. Internal permission identifiers are never returned.fields projection may omit these response properties.curl --location 'https://sgtr-api.returning.ai/v1/categories/cat_agent_01?fields=name%2CdisplayOrder' \
--header 'Authorization: Bearer XXXXXX'{
"meta": {
"status": "success",
"statusCode": 200,
"code": "CATEGORY_RETRIEVED"
},
"message": "Get Store category by ID successfully",
"data": {
"_id": "cat_agent_01",
"name": "Agent Test Rewards",
"displayOrder": 10,
"defaultPurchaseStatusID": "650906d314a3e564c56f3450",
"categoryPermission": [
{
"isEnabled": true,
"type": "user",
"permission": {
"roles": [
"VIP Member"
],
"tags": [
"Early Access"
],
"users": [
"alex"
],
"combination": [
{
"type": "role",
"values": [
"VIP Member"
]
}
],
"isSelectAll": false
}
}
]
}
}