Guides
Guides

Overview

Overview

Mudrex Futures API gives programmatic control over your Mudrex trading account. You can transfer funds between your spot and futures wallets, list tradeable instruments, set leverage/margin type for each asset, place and manage orders, track open positions, and retrieve fee histories.

All endpoints are versioned under https://trade.mudrex.com/fapi/v1 Requests require an X-Authentication header carrying your API secret Responses are JSON encoded Numeric values are strings to preserve precision.

Specifications

  • Host: https://trade.mudrex.com
  • Base path: /fapi/v1
  • Example: https://trade.mudrex.com/fapi/v1/<resource>
  • Headers
    • Authentication header: X-Authentication: your-secret-key required with every request.
    • Content-Type header: Content-Type: application/json required with POST/PATCH/DELETE requests that send a body.
  • Rate limits

Resources

ResourcePurpose
WalletFetch spot wallet balances; move funds between spot and futures.
FuturesFetch futures wallet balance, available transfer amount, and transaction history.
AssetsList all futures instruments with sorting/pagination; retrieve full metadata for a specific asset.
LeverageGet or set leverage and margin type (isolated) for a specific asset.
OrdersCreate new orders (market or limit), list open orders, fetch order history, retrieve single orders, amend/cancel orders.
PositionsView open positions, set/edit stop‑loss and take‑profit, reverse or partially close positions, fetch position history.
FeesRetrieve your trading and funding fee history.

Check out the Quickstart guide to follow a complete trading workflow.

Margin currency: USDT and INR

Futures can be traded with USDT (default) or INR as the margin currency. The contracts are the same USDT-quoted linear perpetuals (e.g. BTCUSDT, SOMIUSDT) in both cases — only the wallet the margin is drawn from and the currency in which PnL and fees are realized changes. Existing USDT integrations are unaffected: when no currency is specified, requests behave exactly as before.

Selecting the currency

Request typeWhere the currency goesExample
GET (spot wallet)Query parameter currency?currency=INR
GET (all other endpoints)Query parameter trade_currency?trade_currency=INR
POST / PATCH / DELETEBody field trade_currency"trade_currency": "INR"
OmittedDefaults to USDT

Supported values are USDT and INR. Any other value returns 400 with Invalid trade currency.

The spot wallet read is the exception. GET /wallet/funds uses currency (e.g. ?currency=INR). Passing trade_currency=INR on the spot endpoint returns 200 OK with all-zero balances — always use ?currency=INR for the INR spot wallet. Every other endpoint uses trade_currency.

Transfers (per currency)

FlowEndpoint
USDT spot ↔ USDT futuresPOST /wallet/futures/transfer
INR spot ↔ INR futuresPOST /futures/transfers/inr

INR transfers do not go through /wallet/futures/transfer. Cross-currency transfers (INR ↔ USDT) are not supported via API.

Currency model

  • Contracts are USDT-quoted (BTCUSDT, SOMIUSDT, …); asset listing and detail are unchanged for both currencies.
  • Order price, entry price, and liquidation price are in USDT.
  • Quantity is in the base asset (e.g. BTC).
  • Margin, PnL, fees, and wallet balances are in the wallet/position currency.
  • For INR trades the FX rate (INR/USDT) is returned as hedge_rate (orders) and entry_hedge_rate / exit_hedge_rate (positions).

List endpoints

List endpoints (orders, order history, positions, position history, fee history, transactions) return one currency per call — they never mix USDT and INR. They default to USDT; pass trade_currency explicitly for INR. Each returned item carries a trade_currency tag.