Classify products synchronously
Classify one product and return its result without persisting product data.
Use this endpoint to classify exactly one product through the AI Classifier and return the classification result immediately. The product data and classification result are not persisted.
Endpoint
POST /public-api/categorize/sync
Classifies exactly one product through the AI Classifier and returns the classification result without persisting product data.
Authentication
All requests require a valid bearer token in the Authorization header.
Authorization: Bearer {ACCESS_TOKEN}Request
{
"uniqueIdentifierType": "GTIN",
"enableQC": false,
"products": [
{
"productUniqueId": "1234567890123",
"productTitle": "Wireless Mouse",
"productDescription": "Ergonomic wireless mouse for laptop use.",
"identifiers": {
"SKU": "WM-101"
}
}
]
}| Property | Type | Required | Description |
|---|---|---|---|
uniqueIdentifierType | string | Yes | The client's configured unique record identifier type. |
enableQC | Boolean | No | Whether the AI Classifier should evaluate qualifying conditions. Default is false. |
products | array | Yes | Must contain exactly one product. |
Exactly one product is required. If you submit more than one product, the request returns
400 Bad Request.
Example
curl --request POST \
--url https://smartcategorization.vertexcloud.com/public-api/categorize/sync \
--header "Authorization: Bearer {ACCESS_TOKEN}" \
--header "Content-Type: application/json" \
--data '{
"uniqueIdentifierType": "GTIN",
"enableQC": false,
"products": [
{
"productUniqueId": "1234567890123",
"productTitle": "Wireless Mouse",
"productDescription": "Ergonomic wireless mouse for laptop use."
}
]
}'Response
[
{
"product_unique_id": "1234567890123",
"product_title": "Wireless Mouse",
"product_description": "Ergonomic wireless mouse for laptop use.",
"category_id": "12345",
"Category": "Computer Accessories",
"confidence": "High",
"status": "approved",
"used_existing_mapping": false
}
]Errors
| Status | Description |
|---|---|
400 Bad Request | The request is invalid. Common reasons include missing uniqueIdentifierType, missing products, or more than one product. |
401 Unauthorized | The bearer token is missing, expired, or invalid. |
500 Internal Server Error | The classifier or service encountered an unexpected error. |
504 Gateway Timeout | The classifier did not respond within the configured timeout. |
Updated 18 days ago
Did this page help you?
