Skip to main content

1. Get live prices (no auth required)

Public market data works without an account. Fetch the current buy/sell price for every tradeable asset:
The returned prices are indicative — for a binding price, request a swap estimate (step 4).

2. Create an API key

Private endpoints need an API key:
  1. Log in to the Digital Surge app.
  2. Go to Account Settings → API Keys.
  3. Choose Read Only (portfolio access) or Read & Write (can also trade and withdraw).
  4. Confirm with your two-factor code, then copy the key immediately — it is shown only once.
See Authentication for details and key-safety guidance.

3. Read your balances

Send the key as a Bearer token:
All monetary amounts are returned as strings — parse them with a decimal type, never a float. See Conventions.

4. Quote a swap

Swaps are how you trade on Digital Surge: AUD → crypto is a buy, crypto → AUD is a sell. Always estimate first — the estimate is your binding quote:
The response includes estimated_price_exact and the fees you’d pay.

5. Execute the swap

This places a real order with real funds.
Pass the same parameters plus expected_price from the estimate — if the market moves beyond tolerance, the swap is rejected instead of filling at a worse price:
The response returns the swap id with status: "processing". Poll GET /api/private/swaps/{id}/ about once per second (up to ~10 seconds) until the status becomes processed.

Next steps

API Reference

Withdrawals, recurring buys, price triggers, transaction history, and more.

Connect an AI agent

Skip the code entirely — let Claude or another agent use your account via MCP.