Basic Structure of shopwave API

All API calls and HTTP methods require passing query parameters in headers including authorisation headers and API version information.

We do not allow query string in URL for any of our HTTP methods.

Global input headers

Authorization header is a mandatory parameter that has to be passed for almost every single call that you make to shopwave® API. To get an access token you must follow our Auth documentation

Authorization: <token_type> <access_token>

API version is not mandatory, but in order to get the latest API we would recommend you to send the specific version number on all API calls. You can do so by passing in request header:

x-accept-version: <recommended_latest_version_number_in_decimal>

Currently shopwave API only serves content in JSON format. Your application needs to accept JSON. It is not mandatory to pass the below parameter. But for log purpose we recommend you to pass it to us.

accept: application/json

Request Pattern

In order to maintain clean URL endpoints, you can pass GET query parameters through request headers with shopwave API. This can be done by simply passing key, value pair of request query parameters.

key: value

For POST request we allow multiple object in the same call it can be mixture of CREATE or UPDATE. There is of course limit for how many objects you can pass in one POST call. Currently the number is 200 and this number could change.


Response Pattern

For all shopwave API responses you will get back a set of response headers. Most important once are listed below

statusCode: <statuscode_response>
date: <shopwave_server_javascript_datetime_format>
content-length: <total_response_json_length>
x-api-version: <shopwave_api_version_server_processed_request>

Most of our API response JSON object follow a certain pattern. The following JSON explains what you can expect in our response.

All our APIs contain clear and pinpoint messages to help you debug quickly. Shopwave server side execution millisecond is provided for you to measure performance. executionTime_milliSeconds is excluding network latency.

//The main object for the endpoint called.
//API processing information
//Important API error, success and query execution information for easy debugging
//Collection of success message object
//Unique success message id
//Unique text code
//Title of the message.
//Details of the status code and message
//Very specific message
//Unique object reference where the success message is associated
//Collection of error message object which follows the same pattern as success message
//Code base version, Note: this is not shopwave API version.
//Execution time in milliseconds at shopwave server side.

You can have a look at our All errors and All success page to understand what type of error messages you might get.