j7tracker

Buy API

POST /submit with type buy_token — buy an existing coin with a SOL amount.

POST {base}/submit with "type": "buy_token". Solana platforms and pons; the buyer is the wallet in api_key.

Required fields

FieldTypeNotes
typestringbuy_token
session_idstringJWT, or Authorization: Bearer
api_keystringEncrypted key — Solana, or EVM for pons
mint_addressstringToken mint / contract
sol_amountnumberAmount to spend in SOL (ETH on pons). lamports (integer) takes priority; buy_amount is an alias

Optional fields

FieldTypeNotes
modestringOmit or auto (default): the server reads the mint on-chain and picks the venue — pump curve / PumpSwap, LaunchLab (bonk / ray / stonk), Bags DBC, or the migrated Raydium / Meteora pool. Explicit pump, bonk, ray, usd1, stonk, bags, pons skip that read and build straight from the request
creator_walletstringOnly with an explicit mode: the creator pubkey (from /token/coin-config/:mint). Resolved on-chain when absent
quote_mintstringOnly with an explicit mode on a quoted coin (USDC / PUMP / stock pump, USD1 / stock bonk, StonkFun pair): the quote CA. Auto mode reads it off the pool. quote_token: "usdc" is the legacy label
config_keystringOnly with mode: "bags": the coin's DBC config key
slippage_bpsintegerSwap-leg slippage, default 200 (500 on pons)
mayhem_modebooleanMayhem path for pump
bonkers_mode, locked_modebooleanLaunchLab pool selectors
bribe_fee_solnumberRelay tip in SOL
request_idstringEchoed back on success / error

Quoted coins (stock / USDC / USD1 pairs) are bought in one transaction: SOL → quote through the quote's pool route, then the venue's buy leg. batch_buy_token (buys: [{ sol_amount, api_key }], max 10) takes the same fields.

{
  "type": "buy_token",
  "session_id": "<jwt>",
  "api_key": "<encrypted_solana_key>",
  "mint_address": "MintAddressHere",
  "sol_amount": 0.1
}

Success response

{
  "type": "buy_success",
  "signature": "...",
  "mint_address": "...",
  "sol_amount": 0.1,
  "lamports": 100000000,
  "wallet_address": "...",
  "mode": "pump"
}

Errors are { "type": "buy_error", "error": "…" }; a 0 amount, an EVM mode other than pons, or a mode that is not a Solana launchpad (Buys not supported for … mode) are rejected.

On this page