Skip to main content

Sending Authenticated Requests

To place orders and perform trading operations, you need to sign transactions with your private key and broadcast them on-chain. Decibel uses on-chain transactions that are signed with your private key and submitted to the Aptos blockchain.

Generate an API Key

First, generate an API key from the Decibel platform:
  1. Visit https://app.decibel.trade/api
  2. Connect your wallet
  3. Click “Create API Wallet” to generate a new API key
  4. Copy and securely store your API key
API Key Security: Your API key is used to authenticate requests to Decibel’s services. Keep it secure and never share it publicly. The API key is used alongside your private key to sign and submit transactions.

How Authenticated Requests Work

Authenticated requests in Decibel follow this general workflow:
  1. Transaction Building: Build an Aptos transaction calling the appropriate Move function with your parameters
  2. Signing: Your private key signs the transaction, creating a cryptographic signature
  3. Submission: The signed transaction is submitted directly to the Aptos blockchain
  4. Confirmation: Wait for the transaction to be confirmed on-chain and extract relevant information from transaction events
Gas Fees: By default, you need APT in your account for transaction gas fees. To remove this requirement, set up Geomi Gas Station to sponsor gas fees on behalf of your users.
Private Key Security: Never expose your private key in client-side code or commit it to version control. Use environment variables or secure key management systems. Your private key has full control over your account and funds.

Transaction Documentation

For detailed information on how to build and submit specific transactions, see the following documentation:

Account Management

Order Management

Position Management

Vault Operations

Builder Fee

Advanced Topics

For more advanced transaction building techniques, see: