Set leverage settings
curl --request PUT \
--url https://futures.kraken.com/derivatives/api/v3/leveragepreferences \
--header 'APIKey: <api-key>' \
--header 'Authent: <api-key>'import requests
url = "https://futures.kraken.com/derivatives/api/v3/leveragepreferences"
headers = {
"APIKey": "<api-key>",
"Authent": "<api-key>"
}
response = requests.put(url, headers=headers)
print(response.text)const options = {method: 'PUT', headers: {APIKey: '<api-key>', Authent: '<api-key>'}};
fetch('https://futures.kraken.com/derivatives/api/v3/leveragepreferences', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://futures.kraken.com/derivatives/api/v3/leveragepreferences"
req, _ := http.NewRequest("PUT", url, nil)
req.Header.Add("APIKey", "<api-key>")
req.Header.Add("Authent", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"result": "success",
"serverTime": "2022-06-28T14:48:58.711Z"
}Multi-Collateral
Set leverage settings
Sets a contract’s margin mode, either “isolated” or “cross” margin.
When specifying a max leverage, the contract’s margin mode will be isolated.
Calling this endpoint can result in the following error codes:
- 87: Contract does not exist
- 88: Contract not a multi-collateral futures contract
- 41: Would cause liquidation
PUT
/
leveragepreferences
Set leverage settings
curl --request PUT \
--url https://futures.kraken.com/derivatives/api/v3/leveragepreferences \
--header 'APIKey: <api-key>' \
--header 'Authent: <api-key>'import requests
url = "https://futures.kraken.com/derivatives/api/v3/leveragepreferences"
headers = {
"APIKey": "<api-key>",
"Authent": "<api-key>"
}
response = requests.put(url, headers=headers)
print(response.text)const options = {method: 'PUT', headers: {APIKey: '<api-key>', Authent: '<api-key>'}};
fetch('https://futures.kraken.com/derivatives/api/v3/leveragepreferences', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://futures.kraken.com/derivatives/api/v3/leveragepreferences"
req, _ := http.NewRequest("PUT", url, nil)
req.Header.Add("APIKey", "<api-key>")
req.Header.Add("Authent", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"result": "success",
"serverTime": "2022-06-28T14:48:58.711Z"
}Authorizations
General API key with full access
Authentication string
Query Parameters
Symbol for the leverage preference.
Max leverage to set.
When present, the symbol's margin mode will be set to "isolated". When missing, the symbol's margin mode will be set to "cross".
Was this page helpful?