Predict Product Data
const url = 'https://api.vviinn.com/product/120857/predicted-attributes';const options = { method: 'POST', headers: {Authorization: 'Basic <credentials>', 'Content-Type': 'application/json'}, body: '{"attributes":["example"]}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.vviinn.com/product/120857/predicted-attributes \ --header 'Authorization: Basic <credentials>' \ --header 'Content-Type: application/json' \ --data '{ "attributes": [ "example" ] }'This endpoint predicts the fields of a single product, already existing in your product catalog. In addition to the fields of the products, the response also contains information about the product’s images.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Example
120857Request Bodyrequired
Section titled “Request Bodyrequired”object
Examplegenerated
{ "attributes": [ "example" ]}Responses
Section titled “Responses”OK
object
The id of the product to which the predictions belong
Each object represents a field of the product with its predicted value
This object contains a prediction for an attribute
object
The attribute’s name
The attribute’s known value (according to the product catalog)
The attribute’s predicted value
The value that was confirmed by a user
Each object represents an image of the product with its predicted fields
object
The url that identifies the image
Each object represents an attribute of the image with its predicted value
This object contains a prediction for an attribute
object
The attribute’s name
The attribute’s known value (according to the product catalog)
The attribute’s predicted value
The value that was confirmed by a user
Example
{ "id": "0010020000VR", "attributes": [ { "name": "color", "value": "red", "prediction": "orange", "confirmed": "peach" } ], "images": [ { "url": "https://www.example.org/image.jpg", "attributes": [ { "name": "color", "value": "red", "prediction": "orange", "confirmed": "peach" } ] } ]}Generic Error
object
Example
{ "message": "Generic Error"}Authentication Error
Example
{ "message": "Authentication Error"}Authorization Error
Example
{ "message": "Authorization Error"}Generic Error
object
Example
{ "message": "Generic Error"}Generic Error
object
Example
{ "message": "Generic Error"}Generic Error
object
Example
{ "message": "Generic Error"}