Skip to content
UNHEDGED / DOCS

Search documentation

Browse docs or start typing to find a topic

↑ ↓ to navigate Enter to open Esc to close

Documentation

Back to app

Authentication

Send a bearer token in the Authorization header to access your account or trade. The public market feed is open to everyone.

Manage API keys

Set up a key

  1. Create the key

    Connect your wallet and verify your email. In Account → API Keys, name the key for your integration.

  2. Choose permissions

    Select the scopes for the endpoints you’ll call.

    Get Balance
    balance:read
    Place Order
    order:place

    Withdrawals require balance:withdraw. View all scopes.

  3. Save the full key

    You can copy the full key only when you create it. Store it in your server’s secret store and set UNHEDGED_API_KEY from that value. If you lose it, create a replacement and revoke the old key.

Get Current User

GET /api/v1/users/me

Verify your key with this read-only profile request. It requires user:read.

Request sample · cURL
api=https://api.unhedged.gg
curl --include \
  -H "Authorization: Bearer $UNHEDGED_API_KEY" \
  "$api/api/v1/users/me"

Check the response

200 OK
Your key works. The response includes your account ID and username.
401 Unauthorized
Check that the environment variable holds the full key, including ak_, and that the key is active and unexpired.
403 Forbidden
Check for the user:read scope. If the key has an IP allowlist, confirm it includes your server’s outgoing IP.