Skip to content

Authentication and API keys

Every request, to the REST API, the MCP server or the account stream, carries your key:

Authorization: Bearer ppk_...

A key is ppk_ followed by 40 letters and digits. The scheme Bearer is case-insensitive. A missing, malformed, unknown or revoked key gets 401 API_KEY_INVALID.

In your trader space: Profile, under Sessions and security, the API keys panel. Name the key, choose its scope, confirm. The key is shown once: we keep only its SHA-256 hash and its first 8 characters (the prefix you see in the list, ppk_xxxxxxxx…), never the key itself.

  • Up to 5 active keys per trader (a sixth: 409 API_KEYS_MAX). Revoked keys do not count.
  • The list shows each key’s name, prefix, scope, creation and last use.
Scope Made with Opens
read the default every read: accounts, risk, terms, positions, orders, executions, payout requests, markets and quotes, and the account stream
trade Allow trading ticked and confirmed the reads, plus the order routes: place, modify and cancel orders, close, reverse and protect positions, set leverage

A key never changes its scope: make a new key for another one. A write with a read key gets 403 API_KEY_READ_ONLY and nothing is done.

No key, of any scope, ever requests a payout, changes a payout address, buys anything, changes your profile, opens a funded account or touches your own guard rails and pause: those stay in the trader space. The API answers 405 there.

If you signed in with a contract wallet (a Safe, for example), each key you make remembers that sign-in. Before every order sent with the key, and at least every five minutes otherwise, the API asks your wallet’s contract whether it still accepts that sign-in, as it does for your session in the terminal. If it no longer does (an owner was removed), the key is revoked at once and the call answers 401 API_KEY_INVALID with detail.reason CONTRACT_WALLET_REVOKED. If the wallet’s network cannot answer, the call is a 503 SIWE_RPC_UNAVAILABLE: nothing was done and the key is kept, so send the same request again later with the same Idempotency-Key.

Revoke in the panel stops a key at once: its next call is a 401, and an account stream it opened closes within seconds (code 4401). “Sign out everywhere” revokes every key of yours too.

  • Treat it like a password: it opens your accounts, and a trade key trades them.
  • Prefer a read key for anything that only reads (a dashboard, a spreadsheet, an assistant you only question).
  • Keep it in an environment variable or your tool’s secret store. A key written in a configuration file (such as ~/.cursor/mcp.json) is stored there in plain text: keep the file private, out of any repository.
  • Send it only to https://app.proofperps.com. The API answers no browser on another site: it reads no session cookie and gives no CORS header, so a page cannot call it with your session.
  • Never put a key in an address (a query string): logs and proxies keep addresses. The account stream takes the key in its header too.
  • Exposed? Revoke it and make a new one.