Response messages

Response headers

Exception on Product.addImages call

Below restrictions does not apply to Product.addImages call. This call is not verbose and instead of array (containing status, message and code) it will return only true or false for each corresponding request key.

SC ignores all the headers in the response message.

Response message

JSON serialised response message MUST contain following fields:

[ 
   { 
      "api":1,
      "result":[ 
         { 
            "status":"success",
            ...
         },
      ],
      "id":1
   }
]
[  
   {  
      "api":1,
      "result":[  
         {  
            "status":"failure",
            "error":{  
               "message":"Config ID not found. Product probably doesn't exist",
               "code":404,
               "trace":"#0 \/shop\/www\/ht\/Source.php(257): ... {main}"
            }
         },
         {  
            "status":"failure",
            "error":{  
               "message":"Config ID not found. Product probably doesn't exist",
               "code":404,
               "trace":"#0 Zend_Application->run()\n#17 {main}"
            }
         }
      ],
      "id":1
   }
]

Response fields:

Field name

Type

Value

Description

api

integer

1

API version, always 1

result

array

[…]

Response data array

status

string

"success", "failure"

Mandatory field, which has to be either "success", either "failure"

id

integer

1

Response Id, which should match the Id in the request message

As status is the mandatory field in a result response array, other fields depends on the API call and will be described in the specific API call details page respectively.

Failure response has unified standard (unless mentioned differently in API details page).

Failure response fields:

Field

Type

Value

Description

message

string

"Error Message"

Failure description

code

integer

404

Contains endpoint system standard error code

trace

string

"…/CatalogCompound.php(344):current('30.00')"

Error trace string

Error Messages/Codes

SC does not interpret error messages, codes or traces; it only logs them into the log file. It does not mean, that the consumer implementor should not care about the failure reasons, quite opposite, as this might help to detect issues!

All fields are required.