curl --request POST \
--url https://futures.kraken.com/derivatives/api/v3/assignmentprogram/add \
--header 'APIKey: <api-key>' \
--header 'Authent: <api-key>'import requests
url = "https://futures.kraken.com/derivatives/api/v3/assignmentprogram/add"
headers = {
"APIKey": "<api-key>",
"Authent": "<api-key>"
}
response = requests.post(url, headers=headers)
print(response.text)const options = {method: 'POST', headers: {APIKey: '<api-key>', Authent: '<api-key>'}};
fetch('https://futures.kraken.com/derivatives/api/v3/assignmentprogram/add', 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/assignmentprogram/add"
req, _ := http.NewRequest("POST", 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))
}{
"id": 123,
"participant": {
"contractType": "flex",
"contract": "PF_BTCUSD",
"maxPosition": 10,
"maxSize": 10,
"acceptLong": true,
"acceptShort": true,
"timeFrame": "WEEKDAYS",
"enabled": true
},
"result": "success",
"serverTime": "2020-08-27T17:03:33.196Z"
}Add assignment preference
This endpoint adds an assignment program preference
curl --request POST \
--url https://futures.kraken.com/derivatives/api/v3/assignmentprogram/add \
--header 'APIKey: <api-key>' \
--header 'Authent: <api-key>'import requests
url = "https://futures.kraken.com/derivatives/api/v3/assignmentprogram/add"
headers = {
"APIKey": "<api-key>",
"Authent": "<api-key>"
}
response = requests.post(url, headers=headers)
print(response.text)const options = {method: 'POST', headers: {APIKey: '<api-key>', Authent: '<api-key>'}};
fetch('https://futures.kraken.com/derivatives/api/v3/assignmentprogram/add', 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/assignmentprogram/add"
req, _ := http.NewRequest("POST", 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))
}{
"id": 123,
"participant": {
"contractType": "flex",
"contract": "PF_BTCUSD",
"maxPosition": 10,
"maxSize": 10,
"acceptLong": true,
"acceptShort": true,
"timeFrame": "WEEKDAYS",
"enabled": true
},
"result": "success",
"serverTime": "2020-08-27T17:03:33.196Z"
}Authorizations
General API key with at least read-only access
Authentication string
Query Parameters
Type of contract for the assignment program preference. Options can be found in the 'accounts' structure in the Get Wallets /accounts response
A specific contract for this assignment program preference. Required for "flex" contracts if base/quote currencies are not included.
The maximum size for an assignment
The maximum position
Accept to take long positions
Accept to take short positions
When is the program preference valid
WEEKDAYS, WEEKEND, ALL enabled assignment
If creating a currency pair level assignment participant, this specifies the base currency.
Must be specified alongside the quote currency.
If creating a currency pair level assignment participant, this specifies the quote currency.
Must be specified alongside the base currency.
Specify max open position notional for wallet type
The minimum profitability per assignment for long positions, in integer basis points.
Participants with a lower minimum receive assignments first. If omitted, the platform
default applies.
The minimum profitability per assignment for short positions, in integer basis points.
Participants with a lower minimum receive assignments first. If omitted, the platform
default applies.
Response
- Success Response
- Errors
Show child attributes
Show child attributes
{
"contractType": "flex",
"contract": "PF_BTCUSD",
"maxPosition": 10,
"maxSize": 10,
"acceptLong": true,
"acceptShort": true,
"timeFrame": "WEEKDAYS",
"enabled": true
}
success "success"
Server time in Coordinated Universal Time (UTC)
"2020-08-27T17:03:33.196Z"
Was this page helpful?