AI agent exchange API key safety: a permissions checklist for bots and agents
API key safety checklist › AI agents
Why AI agents need tighter keys than ordinary bots
A classic trading bot runs code someone wrote in advance. An AI agent built on a large language model chooses its next action from the text in front of it, and some of that text (a web page, a document, a message) can contain instructions it was never meant to obey. The OWASP Top 10 for LLM Applications 2025 lists this as LLM01 Prompt Injection.
The damage depends on what the agent is allowed to do. OWASP's LLM06 Excessive Agency names three root causes: excessive functionality, excessive permissions and excessive autonomy. On an exchange, those map directly to the API key: which endpoints the agent can reach, which permissions the key has, and whether anyone checks an order before it is sent.
Which permissions for which job
| What the agent does | Key permissions | Leave off |
|---|---|---|
| Portfolio summaries, tax reports, dashboards | Read only | Trade, withdrawals, transfers |
| Signals or alerts, you place the trades | Read only (or no key at all) | Trade, withdrawals, transfers |
| Places spot orders | Read + spot trade | Futures, margin, withdrawals, transfers |
| Runs a futures strategy | Read + futures trade for that product | Withdrawals, transfers, products it doesn't use |
| Moves funds or withdraws | Don't give this to an agent | Withdrawals stay off |
The exact switch names differ by exchange. The bot API permissions guide lists them for Binance, Bybit, Bitget and CoinZoom, each sourced to the exchange's own docs.
10-point checklist before you connect an agent
- One key per agent. Name it after the agent so you know what breaks when you delete it.
- Least permissions. Use the table above. Start read-only and add trade only when the agent really places orders.
- Withdrawals off. Transfers off too, unless you have a specific reason.
- IP allowlist. If the agent runs on a server with fixed IPs, bind the key to them. Exchanges treat unbound keys more strictly: on Binance an IP restriction is required before withdrawals can be enabled, and Bybit invalidates keys without a bound IP after 90 days.
- Secret out of the prompt. Store it in the platform's secret storage or an environment variable. Never put it in the system instructions, a chat, a shared document or a code repository.
- Never paste keys into a chat. Treat anything pasted into a chat window as possibly stored or visible to others. More on that in is it safe to give my API key to Claude or an AI trading bot?
- Limit the money at risk. If your exchange offers sub-accounts, run the agent in one that holds only what you are prepared to lose.
- Hard limits outside the model. Maximum order size, allowed pairs and a daily loss stop belong in code or settings the agent can't talk its way around.
- Human approval for big moves. Require your confirmation for large or unusual orders, as OWASP recommends for high-impact actions.
- Logs and a kill switch. Keep a record of every order the agent sends, check it regularly, and know where Delete is for the key.
Red flags in AI trading agents and tools
- It asks for withdrawal permission to "work properly".
- It asks you to paste the API secret or your 2FA code into a chat or DM.
- You can't restrict which pairs it trades or how large its orders are.
- It promises fixed or guaranteed returns.
Full list: crypto trading bot scam red flags.
Related
- Crypto trading bot API key safety checklist
- What API key permissions does a crypto trading bot need?
- OKX API key deleted after 14 days
- Connecting CoinZoom for Quantaira? CoinZoom setup guide
Sources
- OWASP Top 10 for LLM Applications 2025: LLM06 Excessive Agency
- OWASP Top 10 for LLM Applications 2025: LLM01 Prompt Injection
- Binance: How to create API keys
- Bybit API docs: create API key
Education only. This page never asks for your API keys, passwords or codes, and you should never share them with anyone. Not financial advice. Facts last checked 2026-11-21 against the linked sources.