Sell API
POST /submit with type sell_token — sell a % of a wallet's balance.
POST {base}/submit with "type": "sell_token". Sells are a percentage of the wallet's balance. The signer is always the wallet in api_key.
Required fields
| Field | Type | Notes |
|---|---|---|
type | string | sell_token |
session_id | string | JWT, or Authorization: Bearer |
api_key | string | Encrypted key — Solana, or EVM for stroid / pons |
mint_address | string | Token mint, or 0x… contract on EVM. Alias token_address |
basis_points | integer | 1–10000 = 0.01%–100% (2500 = 25%). EVM also accepts sell_percent 1–100 |
Optional fields
| Field | Type | Notes |
|---|---|---|
mode | string | Omit or auto (default): the server detects the launchpad, creator and quote on-chain. Explicit pump, bonk, ray, bags, stonk skip that read; stroid, pons for EVM |
quote_mint | string | Only with an explicit mode on a quoted coin (USDC / stock pump, USD1 / stock bonk, StonkFun pair): the quote CA the deploy used (quote_token: "usdc" is the legacy label). Auto mode reads it off the curve |
creator_wallet | string | Only with an explicit mode: the creator pubkey. Resolved on-chain when absent |
config_key | string | Only with mode: "bags": the DBC config key from the deploy |
mayhem_mode | boolean | Mayhem path for pump |
priority_fee_sol, bribe_fee_sol | number | Priority fee / relay tip in SOL |
gas_gwei | number | stroid only — flat gas override |
{
"type": "sell_token",
"session_id": "<jwt>",
"api_key": "<encrypted_solana_key>",
"mint_address": "MintAddressHere",
"basis_points": 10000
}Success response
{
"type": "sell_success",
"signature": "...",
"mint_address": "...",
"basis_points": 10000,
"wallet_address": "...",
"mode": "pump"
}EVM sells add tx_hash, amount_sold, eth_received_net, gas_paid_eth. Stock-quoted sells sweep the received stock back to SOL / ETH in the same flow.
Batch sell (several wallets, one request)
"type": "batch_sell_token" sells the same mint from up to 16 wallets in one call. Solana only. Each wallet gets its own independent transaction (the exact transaction sell_token would build for it), and all of them ship in a single Astralane sendBatch (MEV-protected, HelloMoon fallback), so every wallet lands in the same slot. Legs are not atomic — one wallet with no balance never fails the others.
sells: [{ api_key, basis_points, token_account? }] replaces api_key / basis_points; every other field above (mode, quote_mint, creator_wallet, config_key, mayhem_mode, priority_fee_sol, bribe_fee_sol) applies to the whole batch.
{
"type": "batch_sell_token",
"session_id": "<jwt>",
"mint_address": "MintAddressHere",
"sells": [
{ "api_key": "<encrypted_solana_key_1>", "basis_points": 10000 },
{ "api_key": "<encrypted_solana_key_2>", "basis_points": 5000 }
]
}{
"type": "batch_sell_success",
"mint_address": "...",
"mode": "pump",
"provider": "Astralane",
"results": [
{ "index": 1, "wallet": "...", "basis_points": 10000, "signature": "..." },
{ "index": 2, "wallet": "...", "basis_points": 5000, "signature": "..." }
],
"landed": 2,
"failed": 0
}Signatures are known at accept time (deterministic per signed transaction); a leg can still fail on-chain. When the request is refused as a whole (a bad key, an unbuildable leg, both providers down) the answer is one batch_sell_error with error and the wallets it was for.
Common errors
| Error | Cause |
|---|---|
sell_error — Unauthorized | Bad or wrong-chain api_key |
sell_error — unsupported mode | bnb and clanker sells are not available through /submit |
| 504 | No final answer within 30 s; last_status carries the last progress message |