> ## Documentation Index
> Fetch the complete documentation index at: https://docs.anthid.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Alpaca API vs Anthid: which one should you build on?

> Alpaca is a broker and Anthid connects to it, so the real question is whether to write against Alpaca directly or run your strategy through Anthid

This question comes up a lot, and the honest answer starts with a correction: Alpaca and Anthid are not competitors. Alpaca is a broker. Anthid is managed trading infrastructure that connects to brokers, and [Alpaca is one of them](/pages/brokers/alpaca). So the real question is whether you should write code against Alpaca's API directly or run your strategy through Anthid with Alpaca behind it.

## What Alpaca gives you

Credit where it is due: Alpaca has one of the friendliest broker APIs around. You get commission free trading in stocks, options, and crypto, fractional shares, a free paper trading environment, websocket streams for live data, and official SDKs in the major languages. If you want a single brokerage account with a clean API, Alpaca is a fine choice, which is exactly why Anthid supports it.

<Note>
  Those are Alpaca's own capabilities. Anthid's intent API is equities oriented today: four order types, the time-in-force values in [Supported Time In Force](/pages/brokers/supported-time-in-force), and the routes in [Supported Destinations](/pages/brokers/supported-destinations). If your strategy depends on an Alpaca capability outside that surface, check the matrices before you plan around it.
</Note>

## What direct integration leaves on your plate

The Alpaca API gives you the ability to place orders. It does not manage them for you. Once your strategy is live, you own the loop that watches every order: catching rejections, retrying failed submissions, handling websocket disconnects without losing fill events, and reconciling your local state against the broker when they disagree. You also own your risk logic. If you want a daily loss cap or a position limit, you write it, test it, and hope it fires before the damage is done.

There is a quieter cost too. Every line of that code is shaped around Alpaca's formats, Alpaca's error codes, and Alpaca's order lifecycle. The day you want a second broker, almost none of it transfers.

## Where Anthid fits

Anthid sits between your strategy and the broker. Instead of raw orders, you describe the outcome you want as an [intent](/pages/concepts/intents), and Anthid handles retries, failures, reconciliation, and each broker's quirks on your behalf. Broker events arrive in one normalized stream and land in a [durable historical ledger](/api-reference/ledger/overview), so your records survive disconnects and disputes. [Risk controls](/pages/controls/overview) run in the platform before an order ever leaves: trading windows and order size limits enforced up front rather than checked after the fact.

<Warning>
  Maximum daily loss and maximum position size can be configured today, but they are stored rather than enforced: the pre-trade evaluation checks order size alone. Keep those checks in your own application until [Controls Overview](/pages/controls/overview) says otherwise.
</Warning>

The platform runs at 99.99% uptime with median order acknowledgement of 42ms. With a direct integration, those numbers are yours to earn and yours to defend at 3am.

<Note>
  Those numbers describe how the platform has been running, not a commitment. Both connected broker integrations are in beta, and a broker integration carries no service level commitment. See [Service levels](/pages/brokers/overview#service-levels).
</Note>

## The lock in question

Building directly on Alpaca ties your codebase to Alpaca. That is not a criticism of Alpaca; it is true of any direct broker integration. With Anthid, Alpaca and Lightspeed are both connected today, [more are on the roadmap](/pages/community/roadmap), and moving to or adding one is a config change instead of a rewrite. Your strategy code does not know or care which broker filled the order.

<Note>
  What carries across both brokers today: the four intent order types, `DAY`, and `SMART` routing. What does not: `GOOD_TILL_CANCEL`, `IMMEDIATE_OR_CANCEL`, and the auction instructions are Alpaca only, and the direct exchange routes are Lightspeed only. Anthid rejects an unsupported combination rather than routing it, so a strategy that leans on Alpaca-only values needs those values reviewed before it points at a second broker.
</Note>

## So which should you pick?

If you are certain you will only ever trade through Alpaca, you enjoy writing operational plumbing, and you have the time to maintain it forever, a direct integration works. Plenty of people start there. But if your goal is a strategy that ships this week, survives bad networks and broker outages, and is not welded to a single brokerage, put Anthid in front of Alpaca and let it absorb the operational work.

You do not have to guess. Anthid has a free tier with paper trading, no credit card and no sales call, so you can run the same strategy both ways and see which version of your life you prefer.

<Card title="Alpaca integration" icon="plug" href="/pages/brokers/alpaca" horizontal>
  What the Alpaca integration supports today, and what is still coming.
</Card>
