Category predictor
Contents
→Get a Category prediction
↳Mandatory parameter
↳Response fields
Get a Category prediction
Make a GET request with a product title (in english) to predict one article at a time, recognize the category_id and the required attributes to list a product. Keep in mind that the answer will be made up of a list of predictions from the provided title, the first being the one with the highest prediction accuracy.
Mandatory parameter
q: the title of the product to be predicted, must be completely in english language.
Request:
curl -H 'Authorization: Bearer $ACCESS_TOKEN' -X GET https://api.mercadolibre.com/marketplace/domain_discovery/search?q=$Q
Example:
curl -H 'Authorization: Bearer $ACCESS_TOKEN' -X GET https://api.mercadolibre.com/marketplace/domain_discovery/search?q=iphone%2064gb
Response:
[
{
domain_id: "CBT-CELLPHONES",
domain_name: "Cellphones",
category_id: "CBT1055",
category_name: "Cell Phones and Smartphones",
attributes: [
{
id: "BRAND",
name: "Brand",
value_id: "9344",
value_name: "Apple"
},
{
id: "LINE",
name: "Line",
value_id: "58993",
value_name: "iPhone"
},
{
id: "MODEL",
name: "Model",
value_id: "14608",
value_name: "iPhone"
}
]
}
]
Response fields
domain_id: ID of the predicted domain.
domain_name: name of the predicted domain.
category_id: ID of the predicted category.
category_name: name of the predicted category.
attributes: list of attributes for the predicted category.