The ShopOnTarget API provides detailed information in case of an error. Hereby, the HTTP status code provides a general error classification while the body provides an error code in addition to an error description. The possible error codes and descriptions are listed below.
HTTP Response | Error Code | Description | Since Version |
---|---|---|---|
404 (NOT FOUND) | 0 | The API requires a valid core. | 1.0 |
404 (NOT FOUND) | 1 | The API requires a valid user name. | 1.0 |
403 (FORBIDDEN) | 2 | No valid API hash for the core given. | 1.0 |
400 (BAD REQUEST) | 3 | No product number for product identification provided. | 1.0 |
404 (NOT FOUND) | 4 | No valid product number for product identification provided. | 1.0 |
409 (CONFLICT) | 5 | Provided product number is already in use. Provide a unique one. | 1.0 |
400 (BAD REQUEST) | 6 | Product meta information (ID, version) is stored automatically. Remove it from the request. | 1.0 |
500 (INTERNAL SERVER ERROR) | 7 | The product was not storable. Please contact the administrator. | 1.0 |
400 (BAD REQUEST) | 8 | You have entered an invalid query offset. | 1.0 |
400 (BAD REQUEST) | 9 | You have entered an invalid query length. | 1.0 |
400 (BAD REQUEST) | 10 | You have deselected term and product suggestions. | 1.0 |
400 (BAD REQUEST) | 11 | The product is not in an expected format. Please verify the provided data. | 1.0 |
400 (BAD REQUEST) | 12 | The query you have provided is not accepted. Please provide a valid query. | 1.0 |
402 (PAYMENT REQUIRED) | 13 | The number of monthly requests exceeded the payed amount of requests. Please contact the system administrator. | 1.0 |
400 (BAD REQUEST) | 14 | No Synset ID was provided. | 1.1 |
400 (BAD REQUEST) | 15 | The provided SYNSET ID is not valid. | 1.1 |
400 (BAD REQUEST) | 16 | The provided SYNSET data is not valid. | 1.1 |
500 (INTERNAL SERVER ERROR) | 17 | The provided SYNSET cannot be stored. | 1.1 |
500 (INTERNAL SERVER ERROR) | 18 | The provided SYNSET cannot be deleted. | 1.1 |
400 (BAD REQUEST) | 19 | The provided facet definition is invalid. | 1.1 |
400 (BAD REQUEST) | 20 | The provided filter definition is invalid. | 1.1 |
404 (NOT FOUND) | 21 | The provided schema ID is no valid schema ID or it is not accessible for the user. | 2.0 |
400 (BAD REQUEST) | 22 | The provided schema data is not in the expected format. Please verify the provided data. | 2.0 |
400 (BAD REQUEST) | 23 | No schema name was provided. Please provide a representing name. | 2.0 |
400 (BAD REQUEST) | 24 | No schema description was provided. Please provide a describing description. | 2.0 |
500 (INTERNAL SERVER ERROR) | 25 | The schema was not storable. Please contact the administrator. | 2.0 |
400 (BAD REQUEST) | 26 | The provided schema is a public schema. It can only be changed by the creator. | 2.0 |
400 (BAD REQUEST) | 27 | The provided schema is a public schema. It can only be deleted by the creator. | 2.0 |
400 (BAD REQUEST) | 28 | The schema cannot be deleted. It is still in use. | 2.0 |
404 (NOT FOUND) | 29 | No valid document URI provided. | 2.0 |
409 (CONFLICT) | 30 | Provided document URI is already in use. Provide a unique one. | 2.0 |
500 (INTERNAL SERVER ERROR) | 31 | The document was not storable. Please contact the administrator. | 2.0 |
400 (BAD REQUEST) | 32 | The document is not in an expected format. Please verify the provided data. | 2.0 |
400 (BAD REQUEST) | 33 | The provided field name is invalid. | 2.0 |
400 (BAD REQUEST) | 34 | The provided core user data is invalid. | 2.0 |
500 (INTERNAL SERVER ERROR) | 35 | The provided core user was not storable. Please contact the administrator. | 2.0 |
500 (INTERNAL SERVER ERROR) | 36 | The provided CoreUser(s) cannot be deleted. | 2.0 |
400 (BAD REQUEST) | 37 | The provided core data is invalid. | 2.0 |
500 (INTERNAL SERVER ERROR) | 38 | The provided core was not storable. Please contact the administrator. | 2.0 |
500 (INTERNAL SERVER ERROR) | 39 | The provided core(s) cannot be deleted. | 2.0 |
400 (BAD REQUEST) | 40 | The provided username is already in use. | 2.0 |
500 (INTERNAL SERVER ERROR) | 41 | The search failed due to an internal error. Please contact the administrator. | 2.0 |
400 (BAD REQUEST) | 42 | The provided core name is already in use by the given user. | 2.0 |
400 (BAD REQUEST) | 43 | The provided sorting definition is invalid. | 2.1 |
500 (INTERNAL SERVER ERROR) | 44 | The provided statistics data cannot be stored. | 2.1 |
400 (BAD REQUEST) | 45 | The provided statistics data is not valid. | 2.1 |
400 (BAD REQUEST) | 46 | The provided schema field type is invalid. | 2.1 |
400 (BAD REQUEST) | 47 | The provided group field is invalid | 2.1 |
200 | - | The operation was successful, the body response depends on the request itself. |
Example response body in JSON format:
{
"code": 1,
"description": "The API requires a valid user name."
}
In case there is an additional information about the error (e.g. a missing field name), there is an additional information provided:
{
"code": 1,
"description": "The provided product is not in the expected format",
"additionalInformation": "'productAvailability' has to be not null"
}