What is the Decibel TypeScript SDK?
The SDK provides a clean, typed interface to interact with Decibel on Aptos:Both
DecibelReadDex and DecibelWriteDex require a Node API token for authentication. Without one, all requests return 401 Unauthorized: anonymous requests are not allowed. Get yours from Geomi before starting.More SDKs coming soon. Rust SDK is in development. For other languages, use the REST API or WebSocket API directly.
- Read operations:
DecibelReadDex- query markets, depth, prices, trades, positions, orders, Trading Accounts, vaults. - Write operations:
DecibelWriteDex- place/cancel orders, manage positions and Trading Accounts, vault operations, delegation.
Installation
Install the SDK and required peer dependencies for Node or browser
environments.
Read SDK
Market data, account state, orders, positions, and historical data.
Write SDK
Trading, position management, TP/SL, TWAP, Trading Accounts, and vault
transactions.
Quick start
Read: market and account data
Write: submit transactions
When to use which
- Use
DecibelReadDexwhen you need market data, order/position history, or account state. No private keys required. - Use
DecibelWriteDexfor on-chain actions and trading. In browsers, avoid embedding private keys; prefer session keys or a wallet and passaccountOverridefor specific calls.
Related
- Configuration and network presets:
MAINNET_CONFIG,TESTNET_CONFIG,LOCAL_CONFIG,DOCKER_CONFIG,NAMED_CONFIGS - See REST and WebSocket topics in Quick Start for direct API access.

