Skip to main content
POST
/
order
Update leverage settings
curl -X POST https://exchange-api.bulk.trade/api/v1/order \
  -H "Content-Type: application/json" \
  -d '{"actions":[{"updateUserSettings":{"m":{"BTC-USD":5.0,"ETH-USD":3.0}}}],"nonce":1704067200000,"account":"FuueqefENiGEW6uMqZQgmwjzgpnb85EgUcZa5Em4PQh7","signer":"FuueqefENiGEW6uMqZQgmwjzgpnb85EgUcZa5Em4PQh7","signature":"5JXWgp1fW6px2Gjhw6YHhQ4..."}'
{
  "status": "ok",
  "response": {
    "type": "order",
    "data": {
      "statuses": []
    }
  }
}
Leverage settings are updated via the unified POST /order endpoint. Send a transaction with an updateUserSettings action in the actions array.

Transaction Envelope

Every request to POST /order has this shape:
{
  "actions": [Action, ...],
  "nonce": 1704067200000,
  "account": "base58_pubkey",
  "signer": "base58_pubkey",
  "signature": "base58_signature"
}
For user settings, the action is a single updateUserSettings object.

Settings Fields

Max Leverage (m)

Object mapping symbol to maximum leverage (1.0–50.0). Cannot exceed the market’s configured maximum.
FieldTypeDescription
mobjectMap of symbol -> max_leverage (e.g. {"BTC-USD": 5.0, "ETH-USD": 3.0}).
Constraints:
  • Leverage is clamped between 1.0 and 50.0
  • Cannot exceed the market’s configured maximum leverage
  • Lower leverage reduces liquidation risk

Request Example

{
  "actions": [
    {"updateUserSettings": {"m": {"BTC-USD": 5.0, "ETH-USD": 3.0}}}
  ],
  "nonce": 1704067200000,
  "account": "FuueqefENiGEW6uMqZQgmwjzgpnb85EgUcZa5Em4PQh7",
  "signer": "FuueqefENiGEW6uMqZQgmwjzgpnb85EgUcZa5Em4PQh7",
  "signature": "5JXWgp1fW6px2Gjhw6YHhQ4wEqb6FqMam6m4yg4uRcCksH9WxSv9dVjizGfD4StGtv1z9gR71unZY6tQ6dNDdJ3K"
}

Response

Same OrderResponse format as other actions. For update user settings, success returns an empty or applied status; settings are applied to the account.
{
  "status": "ok",
  "response": {
    "type": "order",
    "data": {
      "statuses": []
    }
  }
}

Before You Start

See the Transaction Signing guide for how to sign your requests.Nonce: Use a unique value (e.g. timestamp in nanoseconds): BigInt(Date.now()) * 1_000_000n

Body

application/json

Transaction with a single updateUserSettings action

actions
Update user settings (updateUserSettings) · object[]
required

Must contain exactly one updateUserSettings action

nonce
integer<int64>
required

Unique nonce (e.g. nanoseconds)

account
string
required

Account public key (base58)

signer
string
required

Signer public key (base58)

signature
string
required

Ed25519 signature (base58)

Response

200 - application/json

Settings applied

status
enum<string>
Available options:
ok,
error
response
object