Docs
Launch App

Pangolin Overview

Introduction to Pangolin
Audits
Tokens & Governance
Official Links & Communities
Become a Partner
Support
Roadmap
Privacy Policy & Legal Notices

Guides

Swapping Tokens
Providing Liquidity
Managing Liquidity Positions
Withdrawing Liquidity
Earning Rewards
Understanding SAR

Developers

Contracts & Integration Reference
APIs
Bug Bounty
Token Listing
Create A Multisig
Honeycomb↗

PangoPerps

API fundamentals
Public Info API
User API
Registration
Key Management
Account/User Info
Account Notifications
Account Config
Delegate Signer
Sub-account
Trading API
PangoPerpsUser API

Account Config

Read and update leverage, margin mode, and maintenance settings.

#Account Config

These endpoints read and update leverage, default margin mode, isolated-position margin, and maintenance order-cancellation preferences.

#Authentication headers for private endpoints

Private operations require orderly-timestamp, orderly-account-id, orderly-key, and orderly-signature. Each is a string; the timestamp is in milliseconds and the signature is generated for the signed request. The public leverage configuration endpoints below do not require these private headers.

#Get Leverage Setting

GET /v1/client/leverage
Mainnet: GET https://api.orderly.org/v1/client/leverage\\ Testnet: GET https://testnet-api.orderly.org/v1/client/leverage\\ Rate limit: 1 request per second per IP address.

Required query parameter: symbol (string). Optional margin_mode (enum string): CROSS or ISOLATED; defaults to CROSS.

HTTP 200 returns success, server timestamp, and data with symbol (string), margin_mode (CROSS or ISOLATED), and leverage (integer).

#Get All Leverage Settings

GET /v1/client/leverages
Mainnet: GET https://api.orderly.org/v1/client/leverages\\ Testnet: GET https://testnet-api.orderly.org/v1/client/leverages

No query or path parameters. HTTP 200 returns success, server timestamp, and data.rows, an array of records with symbol (string), margin_mode (CROSS or ISOLATED), and leverage (integer).

#Update Leverage Setting

POST /v1/client/leverages
Mainnet: POST https://api.orderly.org/v1/client/leverages\\ Testnet: POST https://testnet-api.orderly.org/v1/client/leverages\\ Rate limit: 5 requests per 60 seconds per user.

Submit application/json. Required leverage (integer from 1 through 100). Optional symbol (string) selects one-symbol mode; omit it for batch mode. Optional margin_mode is CROSS or ISOLATED and defaults to CROSS.

In single-symbol mode, the chosen symbol is updated. In batch mode, the requested leverage is applied per symbol as min(requested_leverage, symbol_max_leverage). Cross-margin changes are checked together: all eligible cross symbols update or none do. For isolated margin, a symbol is updated only if it has no active isolated position or pending order; eligible isolated symbols can still update when other isolated symbols cannot.

Validation checks that leverage is in range, that the position notional is supported, and that sufficient margin is available. The documented notional bound is max_notional = (1 / (symbol_leverage * imr_factor)) ^ (1 / 0.8); the maximum symbol leverage is rounded down to an integer from min(1 / (imr_factor * notional ^ 0.8), 1 / base_imr).

HTTP 200 returns success, timestamp, and data with symbol (string), margin_mode, and leverage (integer).

#Get Margin Modes

GET /v1/client/margin_modes
Mainnet: GET https://api.orderly.org/v1/client/margin\\_modes\\ Testnet: GET https://testnet-api.orderly.org/v1/client/margin\\_modes\\ Rate limit: 10 requests per second per user.

No query or path parameters. HTTP 200 returns required data.rows; each row has required symbol (string) and default_margin_mode (CROSS or ISOLATED). The response also contains success and server timestamp.

#Update Margin Mode

POST /v1/client/margin_mode
Mainnet: POST https://api.orderly.org/v1/client/margin\\_mode\\ Testnet: POST https://testnet-api.orderly.org/v1/client/margin\\_mode\\ Rate limit: 10 requests per second per user.

Submit application/json with required symbol (string) and default_margin_mode (CROSS or ISOLATED). A symbol can switch modes only when it has no open position or pending orders under its current mode. HTTP 200 returns success and server timestamp.

#Add or Reduce Position Margin

POST /v1/position_margin
Mainnet: POST https://api.orderly.org/v1/position\\_margin\\ Testnet: POST https://testnet-api.orderly.org/v1/position\\_margin\\ Rate limit: 10 requests per second per user.

This operation requires trading scope and an open isolated-margin position for the selected symbol. Submit application/json with symbol (string, required), amount (string, required), and type (required enum: ADD or REDUCE). ADD transfers available balance into the position and lowers its liquidation price; REDUCE returns allocated margin to available balance and raises the liquidation price. HTTP 200 returns success and server timestamp.

#Get Max Leverage Setting

GET /v1/public/leverage
Mainnet: GET https://api.orderly.org/v1/public/leverage\\ Testnet: GET https://testnet-api.orderly.org/v1/public/leverage\\ Rate limit: 10 requests per second per IP address.

No query or path parameters. HTTP 200 returns success, server timestamp, and data.max_futures_leverage (string).

#Get Leverage Configuration

GET /v1/public/config
Mainnet: GET https://api.orderly.org/v1/public/config\\ Testnet: GET https://testnet-api.orderly.org/v1/public/config\\ Rate limit: 10 requests per second per IP address.

No query or path parameters. HTTP 200 returns required data.available_futures_leverage (string, comma-separated supported values), success, and server timestamp.

#Configure Auto-Cancel During Maintenance

POST /v1/client/maintenance_config
Mainnet: POST https://api.orderly.org/v1/client/maintenance\\_config\\ Testnet: POST https://testnet-api.orderly.org/v1/client/maintenance\\_config\\ Rate limit: 10 requests per 60 seconds.

Submit application/json with required maintenance_cancel_order_flag (boolean). If true, pending orders are canceled automatically during maintenance. HTTP 200 returns success, required data.success_alter (string), and server timestamp.

PreviousAccount NotificationsNext Delegate Signer

On this page

  • Account Config
  • Authentication headers for private endpoints
  • Get Leverage Setting
  • Get All Leverage Settings
  • Update Leverage Setting
  • Get Margin Modes
  • Update Margin Mode
  • Add or Reduce Position Margin
  • Get Max Leverage Setting
  • Get Leverage Configuration
  • Configure Auto-Cancel During Maintenance

Try it on Pangolin

Everything in these docs is live in the app.

SwapLiquidityStakePerps

Need help?

DiscordTelegramX