Account and history
Equity, positions, orders, trade history and P&L.
get_account_info
Equity (single definition: wallet + unrealized PnL), free/used margin, margin ratio, spot balances valued in USDT, account mode. Responses on a simulated connection carry mode:"simulated". Available on every tier.
Capability: read · read-only · REST: POST /v1/tools/get_account_info
No parameters.
Example request:
{}get_positions
Open positions with stable position_uid, entry, size_usdt, unrealized PnL, R multiple, liquidation price, funding paid, and protection modes (native|worker|none) for stop/take-profit/trailing/ratchet. Responses on a simulated connection carry mode:"simulated". Available on every tier.
Capability: read · read-only · REST: POST /v1/tools/get_positions
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
symbol | string | no | — |
Example request:
{}get_orders
Open and trigger orders; always echoes expires_at and expiry_mode (native|worker). Responses on a simulated connection carry mode:"simulated". Available on every tier.
Capability: read · read-only · REST: POST /v1/tools/get_orders
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
symbol | string | no | — |
Example request:
{}get_trade_history
Closed positions (position-level rows) with realized PnL net of fees and funding, R multiple and exit reason; include_fills for fills (fills_order:"chronological"; each fill reports amount_base, size_usdt = amount_base * price, and contracts for swaps). Available on every tier.
Capability: read · read-only · REST: POST /v1/tools/get_trade_history
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
from | string | no | — | |
to | string | no | — | |
symbol | string | no | — | |
limit | integer | no | 100 | |
include_fills | boolean | no | false | |
position_uid | string | no | — |
Example request:
{}get_trade_stats
Win rate, profit factor, expectancy, avg R, drawdown — counts positions, not fills. Requires the analytics capability (Pro and above).
Capability: analytics · read-only · REST: POST /v1/tools/get_trade_stats
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
from | string | no | — | |
to | string | no | — | |
symbol | string | no | — | |
market_type | spot | swap | no | — |
Example request:
{}get_pnl_by_symbol
Net PnL per symbol with components {trading, fees, funding}. Requires the analytics capability (Pro and above).
Capability: analytics · read-only · REST: POST /v1/tools/get_pnl_by_symbol
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
from | string | no | — | |
to | string | no | — |
Example request:
{}get_pnl_by_time
Net PnL per day/week/month with components. Requires the analytics capability (Pro and above).
Capability: analytics · read-only · REST: POST /v1/tools/get_pnl_by_time
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
from | string | no | — | |
to | string | no | — | |
bucket | day | week | month | no | "day" |
Example request:
{}get_funding_payments
Funding payments received/paid per position. Requires the analytics capability (Pro and above).
Capability: analytics · read-only · REST: POST /v1/tools/get_funding_payments
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
from | string | no | — | |
to | string | no | — | |
symbol | string | no | — |
Example request:
{}