Skip to main content

private/change-account-settings

POST 

/private/change-account-settings

Change account level settings regarding STP and other properties.

Request

Body

required
    id int64required

    Request id (echoed in response)

    method stringrequired

    Must be "private/change-account-settings"

    api_key stringrequired

    Your API key (only required for private REST)

    sig stringrequired

    HMAC-SHA256 signature in hex (only required for private REST)

    nonce int64required

    Current timestamp in milliseconds, e.g. "1771761038000".

    params objectrequired
    stp_scope StpScope (string)

    Possible values: [M, S, D]

    Self-trade prevention scope. Used in private/change-account-settings (params) and private/get-account-settings (result).

    • ➖ M: Matches Master or Sub a/c
    • ➖ S: Matches Sub a/c only
    • ➖ D: reset all STP fields to default (stp_inst and stp_id in same request are ignored).
    stp_inst StpInst (string)

    Possible values: [M, T, B]

    Self-trade prevention instruction. Used in private/change-account-settings (params) and private/get-account-settings (result). Mandatory if stp_scope is set.

    • ➖ M: Cancel Maker
    • ➖ T: Cancel Taker
    • ➖ B: Cancel Both Maker and Taker
    stp_id string

    Optional. 0 to 32767. If stp_scope and stp_inst not specified, REJECT. If stp_scope specified, default 0.

    leverage int32

    Maximum leverage for the account. When account effective leverage exceeds this, further risk-increasing orders are rejected.

Success.
Schema
    id int64

    Echoed request id

    method string

    Method invoked

    code int32

    0 = success; non-zero indicates error (reason code).

    result object
    Present when code === 0; no result block per docs.
    object
    message string

    Present when code !== 0.

    original string

    Present when code !== 0.