Safety model
How CryptoContext keeps your funds in your account, and what protects each order and position.
The protection lives on our servers, not in the AI. A prompt cannot turn it off.
Your funds never leave your exchange account
- We never hold your funds. There is no code that withdraws, transfers or fetches deposit addresses, and calls of that kind are blocked at the exchange-library level.
- An API key that can withdraw or transfer is rejected when you connect it. Every key is checked again daily, and a connection whose key gains that ability is disabled at once.
- Keys are stored encrypted (envelope encryption), and only the service that talks to the exchange can decrypt them. They are never shown again, logged or returned by any tool.
- Restrict the key to our IP addresses (shown on the connect page) so it is useless anywhere else.
Every order is checked first
- Preview by default. Trading tools are dry runs unless
dry_run: falseis passed. In paper mode (set_mode), every trading tool is forced to preview for the session. - Limits. Your connection's leverage cap and maximum order size apply to every order, and an order whose liquidation price would come before its stop is refused.
- Trade universe. Optionally, only symbols in your watchlist can be traded; candidate symbols are shadow-only.
- Idempotency. A repeated request within the idempotency window does not place a second order, and you can pass your own
idempotency_key.
Every position is protected, and you can see how
Each stop, take-profit, trailing stop and ratchet reports its protection mode:
| Mode | Meaning |
|---|---|
native | Held by the exchange as a resting order. It triggers even if CryptoContext is offline. |
worker | The exchange cannot hold this order type, so our worker watches the price and acts. It depends on our service and the exchange being reachable. |
none | No stop. The dashboard shows this in red. |
Order expiries report expiry_mode the same way.
Guards for bad days
- Equity guard. Blocks new exposure after a daily drawdown or below an equity floor, and can flatten positions. Closing and reducing are never blocked.
- Prop-firm rules and a news guard for blackout windows around high-impact events.
- Heartbeat. A dead-man's switch for agents: if an agent stops checking in, its stops tighten or its positions close.
- Kill switch. We can pause new exposure for one account or the whole platform; reads, closes and protection keep working.
Everything is on record
The audit log in the dashboard lists every command that reached your account, including previews and refused ones. The journal records what your agents decided and why, and the platform writes its own entries for automatic actions such as stop moves and guard breaches.