For information on changes for our US clients, please visit our Support Center article.

Zoeken
Calls and Returns (REST API)

Calls


To access the API‘s endpoints, HTTP calls need to be sent to the following URL.
https://futures.kraken.com/derivatives/api/v3
For calls of private endpoints, the following HTTP headers must be provided: apiKey and
authent. Including the nonce in the request is optional.
Example
The following shows an example for the inclusion of HTTP headers in Java. For full
working examples in different programming languages, see Section Sample Implementations. String url = "https://futures.kraken.com/derivatives/api/v3/sendOrder";
URL obj = new URL(url);
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
...
con.setRequestProperty("APIKey", apiKey);
con.setRequestProperty("Authent", authent); where apiKey and authent are determined as described earlier.

Calls of endpoints that do not change the state of the server should be submitted with requestType
= GET and with postData being submitted in the URL. Calls of endpoints that do change the state of the server should be submitted with requestType = POST and with postData being submitted in the URL. Section 4 details for each endpoint which requestType should be used.

Returns


The API’s returns are in JSON format. If the call was successful, the return includes the requested
information or feedback on the requested action. See Section Error! Reference source not found. for a description of returns for each endpoint.
If a call was successful, the result key in the root structure will have the value success.
For calls of private endpoints, the following HTTP headers must be provided: apiKey and
authent.
Example
The following shows the return of a successful call of the sendorder endpoint.
{
"result":"success",
"serverTime":"2016-02-25T09:45:53.818Z",
"sendStatus":{
"receivedTime":"2016-02-25T09:45:53.601Z",
"status":"placed",
"order_id":"c18f0c17-9971-40e6-8e5b10df05d422f0"
}
}

Note that if a call comes back with result equal to success, this merely means that the request has
been received and assessed successfully. It does not necessarily mean that the desired operation has been performed. Details on the operation’s status are returned in a status key, where applicable.
Example
The following shows the return of a successful call of the sendorder endpoint where the desired operation was not performed. {
"result":"success",
"serverTime":"2016-02-25T09:45:53.818Z",
"sendStatus":{
"receivedTime":"2016-02-25T09:45:53.601Z",
"status":"insufficientAvailableFunds"
}
}