Catalog API Documentation
Browse endpoints, parameters, and live request examples.
GET
/sockets/{socket_id}/cart/{external_user_id}/metadata
Get cart metadata
Retrieve the custom metadata associated with a cart. Metadata can be used to store arbitrary key-value pairs for custom business logic or tracking purposes.
Cart
Parameters
socket_id
required
path
(integer)
Socket/catalog identifier
external_user_id
required
path
(string)
External user identifier
Responses
200
Cart metadata retrieved successfully
Cart with no metadata
{
"cart_version": "550e8400-e29b-41d4-a716-446655440010",
"metadata": {}
}
Cart with custom metadata
{
"cart_version": "550e8400-e29b-41d4-a716-446655440010",
"metadata": {
"approval_status": "pending",
"cost_center": "WEf333-001",
"manager_id": "2938749823670",
"project_code": "PROJ-2024-001"
}
}
Response Schema
Type:
object
Required fields:
metadata
cart_version
Properties:
cart_version
required
metadata
required
401
Unauthorized - Invalid or missing authentication
Example Response
{
"error_code": "UNAUTHORIZED",
"message": "Invalid or missing authentication token",
"success": false,
"timestamp": "2023-12-01T15:30:45.123Z"
}
Response Schema
Schema Reference:
Standard error response format
Type:
object
Required fields:
success
message
timestamp
error_code
Properties:
error_code
required
message
required
success
required
timestamp
required
403
Forbidden
Example Response
{
"error_code": "FORBIDDEN",
"message": "Access denied",
"success": false,
"timestamp": "2023-12-01T15:30:45.123Z"
}
Response Schema
Schema Reference:
Standard error response format
Type:
object
Required fields:
success
message
timestamp
error_code
Properties:
error_code
required
message
required
success
required
timestamp
required
404
Socket or cart not found
Cart does not exist
{
"error_code": "CART_NOT_FOUND",
"message": "Cart not found for the specified user",
"success": false,
"timestamp": "2023-12-01T15:30:45.123Z"
}
Socket not found
{
"error_code": "NOT_FOUND",
"message": "The requested resource was not found.",
"success": false,
"timestamp": "2023-12-01T15:30:45.123Z"
}
Response Schema
Schema Reference:
Error response when requested resource is not found
Type:
object
Required fields:
success
message
timestamp
error_code
Properties:
error_code
required
message
required
success
required
timestamp
required