Agentic tradingCryptoRiskDevelopers

How AI agents trade crypto in 2026

AI agents trade crypto through a single API in 2026, using scoped keys, dollar sizing, and non-custodial controls that keep funds under owner control.

By the Felix team13 min read
Key takeaways
  • 01An AI trading agent connects to crypto markets through the same API it uses for stocks, perps, and options, normalizing order sizing into plain US dollars.
  • 02Funds remain in a wallet the owner controls, because the agent can spend within scoped limits but cannot withdraw to itself or any address the owner has not approved.
  • 03Every live trading key requires explicit owner authorization, and paper trading exists so the agent can be tested without risking real capital.
  • 04Developers set guardrails including budget caps, position limits, and kill switches, because automated trading can lose money, including the entire balance.
  • 05MCP tools and REST endpoints let the agent read market data and submit orders, but the exact schema and paths are documented separately and should be checked before going live.

In 2026, an AI agent trades crypto by calling a single API with one key that also reaches stocks, perps, options, and prediction markets. The agent specifies orders in plain US dollars, and the infrastructure translates that into the correct contract size and venue format. Funds stay in a wallet the owner controls, and the agent can only spend within preapproved limits. This setup means the agent can act quickly without ever taking custody of the money.

How does the API normalize crypto orders?

Crypto markets have historically forced developers to think in native units, decimals, and varying contract specifications. Each venue uses different minimum order sizes, tick increments, and precision rules. A developer building against multiple venues used to maintain separate libraries just to handle the arithmetic of converting a human readable trade idea into a machine valid payload. In 2026, the agent does not need to calculate how many satoshis or token units equal a desired position. Instead, the developer sends an order sized in US dollars, and the API handles the conversion to the precise amount required by the underlying venue. This abstraction applies across the five supported market types, so an agent moving from a perps venue to a spot crypto venue uses the same mental model and the same parameter shape.

Normalization also removes the need to maintain separate integrations for each venue. One API key covers the agent's access, and the routing layer determines which venue receives the order based on the symbol and market type. The developer still chooses the asset and the direction, but the system manages the formatting, minimum order sizes, and price tick increments. This reduces the surface area for bugs caused by mismatched precision, which have historically been a common source of unintended position sizes. It also means that an agent built for one asset can be redirected to another with minimal code changes, because the interface remains constant even when the underlying venue changes.

This is especially useful for an LLM agent. Large language models are not inherently good at precise arithmetic or at tracking decimal place rules that differ across venues. By accepting a simple dollar amount, the API removes a class of errors that could arise from the agent miscalculating a token quantity. The developer can prompt the agent with instructions like allocate two hundred dollars to bitcoin, and the agent does not need to know the current price or the lot size to construct a valid order.

Symbol mapping is another hidden complexity that the API handles. The same asset might be listed under different ticker formats across venues. The agent only needs to know a canonical symbol, and the routing layer resolves the exact contract identifier. This means the developer does not need to maintain a mapping table or update it when a venue changes its ticker convention. The abstraction holds as long as the asset is supported, and the developer can query the docs to see the current symbol list.

What keeps the owner's funds safe?

Non-custodial design is the default, not an add-on. The owner's funds sit in a wallet that the owner controls through standard key management. The trading agent receives a scoped key that allows it to place orders and manage positions, but the permissions explicitly exclude withdrawals. The agent cannot send funds to itself, and it cannot send funds to any address that the owner has not preapproved. This means that even if the agent's logic is compromised, the capital cannot be drained through a withdrawal transaction.

The owner approves withdrawal addresses during setup, and those addresses are stored outside the agent's reach. If the agent needs to rebalance or exit to a stable position, it can trade within the permitted markets, but it cannot move base currency off the platform. The model is described in the guide to live trading without losing custody, which explains why custody separation matters for automated systems. The agent's key is also scoped by market type and budget, so a key authorized only for crypto cannot accidentally route an order into a stock or options venue. This containment prevents category errors that might otherwise arise from a misinterpreted prompt.

If the owner suspects the agent is behaving erratically, the key can be revoked instantly without moving funds. Because the wallet remains under owner control, rotating keys does not require a withdrawal or a transfer. The owner simply generates a new scoped key with different limits, or disables the old one entirely. This is a sharp contrast to custodial models where disabling access might require support tickets or cooling off periods.

The pre-approval list is small by design. Most owners include only their own cold wallet or a bank linked address. If the agent needs to move to stable assets, it does so by trading into a stablecoin on the platform, not by sending funds elsewhere. This keeps the liquidity inside the system and prevents a compromised agent from laundering value through a chain of external transfers. The owner remains the final authority for every address that can receive funds.

How do safety controls limit downside?

Automation does not remove risk. An agent can lose money, including the entire allocated balance, if the market moves against it or if its strategy is flawed. To contain this, the platform provides guardrails that act independently of the agent's reasoning. A budget cap sets the maximum US dollar amount the agent can deploy. A position limit prevents the agent from concentrating too heavily in a single asset. These are hard ceilings enforced by the infrastructure, not suggestions that the agent may ignore.

Beyond sizing limits, an owner can define an exit plan that triggers when a drawdown threshold is breached. There is also a panic switch that flattens all positions and revokes the agent's key in a single action. These controls are important because an LLM agent may interpret news or price action in ways that a human would not, and it can act faster than a person can intervene. The article on how to set guardrails for a trading agent explains the configuration, and the checklist for building an automated exit plan covers the practical steps for defining drawdown rules and take profit logic.

Developers should treat these controls as the primary safety system, not as backup. The agent's reasoning is secondary to the hard limits. If the agent attempts to exceed a budget cap or open a position beyond the allowed size, the API rejects the order before it reaches the market. This fail safe behavior protects the owner from both market risk and logic errors in the agent's prompt or tool chain.

An exit plan can combine multiple conditions. For example, it might flatten a position if the price drops ten percent in a single hour, or if the daily loss exceeds the budget cap. These rules run on the platform side, so they execute even if the agent's server is slow or if the LLM is generating a response. The separation of strategy from safety is intentional. The agent proposes, but the infrastructure disposes.

Position limits work alongside budget caps. A cap might allow one thousand dollars in total exposure, while a position limit restricts any single asset to three hundred dollars. This forces diversification, or at least prevents the agent from going all in on a single speculative token. The limits are enforced at the API level, so the agent receives a clear error if it tries to exceed them. This feedback can also be used in the prompt design, so the agent learns that certain orders are structurally blocked.

How is an agent different from a traditional trading bot?

A traditional trading bot follows a deterministic script. It checks for a signal, evaluates a fixed rule, and executes. An AI agent, by contrast, uses an LLM or similar reasoning layer to interpret context, adjust its plan, and decide whether to trade. This means the agent can read unstructured data, reason about market conditions in plain language, and choose from a broader set of actions. The flexibility is useful, but it also introduces unpredictability that a rigid bot does not have.

The difference in architecture matters for risk management. A bot that malfunctions usually repeats the same error in a loop. An agent that misinterprets a prompt or overfits to recent price action may generate novel, unexpected orders. That is why the same API supports both modes, but the safety layer is especially important for agents. The owner should treat the agent's reasoning as a source of variance, not as a guarantee of correct behavior.

For example, suppose a bot is programmed to buy when a moving average crosses above a threshold. It will do exactly that, every time. An agent given a prompt to trade a breakout might interpret the word breakout differently depending on the surrounding context, the recent conversation history, or the exact phrasing of the prompt. This variability is the point of using an agent, but it also means the owner cannot predict every order in advance. The guardrails exist precisely because the agent's output is generative rather than deterministic.

Observability also differs. A bot logs the same variables every cycle, which makes debugging straightforward. An agent may produce different reasoning traces for each decision, so the owner needs audit logs that capture not just the order but the context that led to it. Without those logs, it is hard to know whether a losing trade was caused by bad reasoning, bad data, or a misinterpreted prompt. The platform provides structured logs for this purpose, but the developer must still review them.

What does testing and going live look like?

Before an agent handles real capital, it runs in paper trading mode. Paper trading uses live market data and simulates fills, but no actual money moves. This lets the developer observe how the agent sizes positions, handles volatility, and respects the guardrails. The agent can place orders, see simulated results, and iterate on its strategy or prompt engineering without financial consequences. This phase is essential, because an agent that behaves well in backtests may still act differently when connected to real time feeds and MCP tools.

The transition to live trading is not automatic. When the developer is ready, they must explicitly authorize a live key, which activates the real spending permissions. This authorization step requires the owner to confirm the key scope, the budget cap, and the approved markets. Once live, the agent operates within the same guardrails it faced in paper mode, but now the losses are real. That is why the authorization step is deliberately manual; the owner must confirm that the strategy, the limits, and the kill switch are all configured correctly.

Agents connect through MCP tools in editors like Claude or Cursor, or through direct REST calls. The MCP layer translates the agent's intent into structured API requests, while the REST path offers a more traditional integration for custom stacks. In both cases, the connection uses the same scoped key and the same normalization layer. The developer chooses the interface that fits their workflow, but the safety model remains identical regardless of how the agent connects.

MCP connections carry their own risk considerations. Because the agent runs inside an editor or a local environment, the developer must ensure that the MCP server configuration does not expose the key to other tools or plugins. The scoped key limits the damage if the environment is compromised, but best practice still means storing the key in a secure credential store rather than in a prompt or a chat history. The docs cover the recommended setup for both Claude and Cursor integrations.

The authorization interface shows a summary of the exact permissions being granted. The owner sees the market types, the maximum budget, the allowed symbols, and the withdrawal addresses. Nothing is hidden behind a generic confirm button. This transparency is important because it forces a deliberate review of the agent's reach. Once authorized, the key becomes active immediately, but the owner can pause or revoke it at any time without penalty.

How do perpetual futures fit into crypto agent trading?

Perpetual futures are included in the same API as spot crypto, but they carry additional mechanics such as funding rates and margin requirements. The agent does not need to understand the underlying math, because the API still accepts orders in US dollars and manages the conversion. However, the developer must configure leverage limits separately, and the agent can still be liquidated if the market moves against its position. This is a real risk, and the agent will not automatically know when to stop.

Because perps can amplify both gains and losses, the safety controls are especially important here. A kill switch that flattens a perp position can prevent a small drawdown from becoming a total loss. Developers should also be careful about how the agent interprets margin. An LLM might confuse notional exposure with account balance if the prompt is not precise, or it might open a position that looks small in dollar terms but carries high leverage. The article on how AI agents mishandle perpetual futures and how to prevent it offers a deeper look at these specific failure modes.

Suppose an agent is allowed to trade five hundred dollars in notional value. In a spot market, that is a five hundred dollar position. In a perp market with ten times leverage, the same notional value controls a five thousand dollar exposure. The agent may not infer this distinction from the prompt alone. The developer must set leverage caps at the API level, not rely on the agent to self limit. This is a common oversight when moving an agent from spot testing to perps live trading, and it is one of the reasons the authorization step includes a review of leverage settings.

Funding rates add another variable that the agent may not account for. A perp position that remains open for hours or days accrues funding payments that can erode profits or deepen losses. The API reports funding costs, but the agent's prompt must explicitly instruct it to consider holding costs. Many developers overlook this when designing prompts, assuming that the dollar based abstraction hides all secondary mechanics. It does not. The developer still needs to understand the instrument and to communicate that context to the agent.

Liquidation is the most severe risk in leveraged perp trading. If the agent's position moves against it and the margin balance falls below the maintenance requirement, the venue will close the position automatically. The agent may not recognize this in time to exit gracefully. A hard stop loss configured at the API level can close the position before liquidation, preserving some capital and avoiding the additional fees that liquidation often triggers. This is why many developers pair perp trading with aggressive drawdown limits.

Frequently asked questions

Can the AI agent withdraw my crypto to its own wallet?

No. The agent operates with a scoped key that explicitly excludes withdrawal permissions. Funds remain in your wallet, and the agent can only trade within the markets and budgets you have authorized. Even if the agent is compromised, it cannot move funds to an unapproved address.

Does the agent need to know how to size orders in native token units?

No. You send orders in plain US dollars, and the API translates the amount into the correct size for the specific venue and asset. This applies to spot crypto, perpetual futures, and the other supported market types. The developer does not need to handle decimal precision or contract math manually.

What happens if the agent starts losing money quickly?

The platform enforces the guardrails you set before going live, such as budget caps and position limits. If losses hit your predefined drawdown threshold, an automated exit plan can close positions. You can also press the kill switch to flatten everything and revoke the agent's key immediately.

Can I test the agent without risking real capital?

Yes. Paper trading uses live market data and simulates fills without moving real money. You can observe how the agent behaves under realistic conditions before you authorize a live trading key. Authorization is a separate, explicit step that requires owner confirmation.

Is an AI agent safer than a traditional trading bot?

Neither is inherently safer. A bot repeats deterministic rules, while an agent can make novel decisions based on context, which introduces different failure modes. The safety comes from the guardrails, scoped keys, and kill switches that wrap the automation, not from the agent's reasoning itself.

How many markets can one agent trade at once?

One API key covers stocks, crypto, perpetual futures, options, and prediction markets. The agent can trade across these market types as long as each position stays within your configured limits. You do not need separate integrations or keys for each venue.

Give your agent a key.

One key to trade stocks, crypto, perps, options, and prediction markets. Live after owner authorization.

Keep reading

Not a brokerage, exchange, or investment adviser. Not investment advice. Trading involves risk, including total loss.