Request payload
The request payload is a JSON object that contains the credentials, data and function to call for the request. The credentials are used to authenticate the request, the data is used to send the actual data for the request and function is used to call the correct function on the server side.
Credentials
Property | Required | Type | Description |
---|---|---|---|
id | true | int | The store ID from Qvickly. |
hash | true | string | Hash key using the HMAC method with SHA-512. This is used for verifying that the request is correct and fom a valid server. Key - Qvickly key. Argument Data - array as json encoded string. |
version | false | string | Version of the Qvickly API. Latest version is at the time of writing 2.5.0. Please consult technical support for latest version if you need to use this. Not mandatory, but helps when debugging in logs. |
client | false | string | A unique name to identify client and version of client. Can be set by a plugin developer. |
language | true | string | This is the language of the api, this will decide what language we will return for example error messages. Language codes used according to ISO 639-1, Currently supported sv, en. |
serverdata | false | string | Web shop server data. For example user agent of the customer browser. Very useful for debugging. |
time | false | decimal | Time when request was submitted. Time format is “PHP microtime”, which is seconds since the Unix Epoch (00000 January 1, 1970 GMT). If used, then logs will show “client time”, which is the time it takes for the request to reach Qvickly servers. Good for debugging of delays. |
test | false | boolean | If test mode, a real credit check will not be made. Default is false. |
key The secret key from Qvickly. Is being used for generating the hash key.
Generate hash key
For more examples on how to generate the hash key in different languages, see Creating hash.
Data
The data in the payload can be different depending on which method is being called. See the documentation for each method for more information.
Read about the different data types and limitations in languages here.
Function
Please see Functions for more information about the different functions.