Connect Alpaca to your AI agent
Stock and crypto trading platform with commission-free trading, real-time market data, and algorithmic trading capabilities
We set up the connection using your own Alpaca account, with keys you control, and keep it running. Your agent picks it up and starts doing the work.
What your agent can do in Alpaca
Each one is a real action the agent can take on its own, the same things a person clicking around Alpaca could do. Read-only by default; write actions are confirmed against your policy.
- Add Asset to Watchlist Adds a symbol to an existing watchlist in the authenticated account. Use when you need to track a new security in an existing watchlist. This action appends the specified symbol to the end of the watchlist's asset list.…
- Add Asset to Watchlist by Name Add an asset to a watchlist by name. Use when you need to add a symbol to a specific watchlist identified by its name. If a watchlist with the specified name does not exist, it will be created automatically and the symb…
- Create Watchlist Creates a new watchlist for the authenticated account. Use this action when you need to: - Create a new watchlist to track specific securities - Set up initial symbols for a watchlist at creation time - Organize tracked…
- Create Watchlist Create a new watchlist for the authenticated account. Use when you need to create a watchlist to track specific securities. The name must contain only alphanumeric characters (no spaces or special characters).
- Delete All Open Positions Liquidates all open positions by closing them at market price. This action is irreversible and will permanently close all positions in the account. Use when you need to quickly exit all positions, such as before closing…
- Delete All Orders for Account Attempts to cancel all open orders for a specified trading account. A response will be provided for each order that is attempted to be cancelled. This action is irreversible for individual orders that are successfully c…
- Delete Unsubscribe Account Delete a rebalancing subscription to unsubscribe an account. This action permanently removes the specified subscription. Use when you need to unsubscribe an account from rebalancing services. This action is irreversible…
- Delete Watchlist By ID Delete a watchlist by its unique identifier. Use when you need to remove an entire watchlist that is no longer needed. This action is irreversible once executed — the watchlist and all its contents cannot be recovered.…
- Get Account Retrieves account information for the authenticated Alpaca account. Use this action when you need to check account status, available buying power, cash balance, equity, margin information, day trade count, or other acco…
- Get Account Activities Retrieves account activities for the authenticated Alpaca account. Use this action when you need to retrieve transaction history, dividend payments, interest payments, fees, transfers, or other account-related activitie…
- Get Account Activities V2 Retrieves account activities of one type for the authenticated Alpaca account using the v2 API. Use this action when you need to retrieve transaction history, dividend payments, interest payments, fees, transfers, or or…
- Get Account Activities By Activity Type Retrieves account activities of a specific type for the authenticated Alpaca account. Use when you need to filter account activities by a specific type such as trade fills, dividends, interest payments, fees, or transfe…
- Get Account Configurations Retrieves the current trading account configuration settings for the authenticated Alpaca account. Use this action when you need to check the current trading account settings such as day-trading margin call (DTMC) check…
- Get Account Portfolio History Retrieves the portfolio history statistics for an Alpaca trading account. Portfolio history provides a time series of equity values, profit/loss metrics, and other performance data over a specified time period. Use when…
- Get Account Portfolio History Retrieves the portfolio history statistics for a trading account. Portfolio history provides a time series of equity values, profit/loss metrics, and optionally cashflow data over a specified time period. Use when you n…
- Get All Account Positions Bulk fetches all open positions for the authenticated account. Use when you need to retrieve all current positions, monitor overall portfolio holdings, or check unrealized P&L across the entire account. This action does…
- Get All Open Positions Retrieves all open positions for the authenticated Alpaca trading account. Use this action when you need to retrieve all current positions, monitor portfolio holdings, or check unrealized P&L across the entire account.…
- Get All Orders Retrieves all orders for an account based on specified filter criteria. Returns a list of orders with their current status, filled quantity, prices, and any nested legs for complex orders. Use when you need to query his…
- Get Historical Crypto US Bars Retrieves historical OHLCV (Open, High, Low, Close, Volume) bars for crypto symbols in a specific US location. Use this action when you need to analyze historical price movements and trading activity for cryptocurrency…
- Get Crypto Bars for Multiple Symbols Retrieves OHLCV (Open, High, Low, Close, Volume) bars for multiple crypto symbols. Use this action when you need to: - Get historical price data for multiple crypto symbols - Analyze price trends over a specific timefra…
- Get Stock Bars for Multiple Symbols Retrieves OHLCV (Open, High, Low, Close, Volume) bars for multiple stock symbols. Use this action when you need to: - Get historical price data for multiple stock symbols - Analyze price trends over a specific timeframe…
- Get Historical Bars for Stock Symbol Retrieves historical OHLCV (Open, High, Low, Close, Volume) bars for a single stock symbol. Use this action when you need to analyze historical price movements and trading activity for a specific stock ticker over a giv…
- Get Historical Stock Bars Retrieves historical OHLCV (Open, High, Low, Close, Volume) bars for a single stock symbol. Use this action when you need to analyze historical price movements and trading activity for a specific stock ticker over a giv…
- Get Calendar Retrieves market calendar information for trading days from the Alpaca Trading API. Use this action when you need to: - Get market open and close times for specific dates - Check trading session times - Verify market op…
- Get Clock Retrieves the current market clock information from the Alpaca Trading API. Use this action when you need to: - Check if the market is currently open - Determine when the next market open or close will occur - Plan trad…
- Get Stock Conditions Retrieves the mapping of condition codes to their names from Alpaca Markets API for the specified type (trade or quote conditions) and tape. Use this action when you need to: - Decode condition codes from stock market d…
- Get Crypto Latest Quotes Retrieves the latest bid and ask prices for specified crypto symbols at a specific location. Use when you need real-time quote data for cryptocurrency trading, such as checking current market prices before placing order…
- Get Crypto Perp Latest Bars Retrieves the latest OHLCV (Open, High, Low, Close, Volume) bars for crypto perpetual futures symbols. Use this action when you need real-time or near real-time price data for crypto perpetual futures contracts for a sp…
- Get Crypto Perp Latest Orderbooks Retrieves the latest bid and ask orderbook data for specified crypto perpetual futures symbols. Use when you need real-time orderbook data for crypto perpetual futures trading, such as checking current market depth befo…
- Get Crypto Perp Latest Pricing Retrieves the latest pricing data for specified crypto perpetual futures symbols. Use when you need real-time pricing data for crypto perpetual futures trading, such as checking current market prices, index prices, mark…
- Get Crypto Perp Latest Quotes Retrieves the latest bid and ask prices for specified crypto perpetual futures symbols for a specific location. Use when you need real-time quote data for crypto perpetual futures trading, such as checking current marke…
- Get Crypto Perp Latest Trades Retrieves the latest trade data for specified crypto perpetual futures symbols. Use when you need real-time trade data for crypto perpetual futures trading, such as monitoring recent trades, analyzing price movements, o…
- Get Crypto Perps Global Latest Bars Retrieves the latest OHLCV (Open, High, Low, Close, Volume) bars for crypto perpetual futures symbols. Use this action when you need real-time or near real-time price data for crypto perpetual futures contracts. Returns…
- Get Crypto Perps Global Latest Pricing Returns the latest pricing data for crypto perpetual futures symbols. Use this action when you need to retrieve current market data for crypto perpetual futures contracts including mark price, index price, open interest…
- Get Crypto Perps Global Latest Quotes Retrieves the latest bid and ask prices for specified crypto perpetual futures symbols. Use when you need real-time quote data for crypto perpetual futures trading, such as checking current market prices before placing…
- Get Crypto Perps Global Latest Trades Retrieves the latest trade data for specified crypto perpetual futures symbols. Use when you need real-time trade data for crypto perpetual futures trading, such as monitoring recent trades, analyzing price movements, o…
- Get Crypto Snapshots Retrieves snapshots (latest trade, latest quote, minute bar, daily bar, and previous daily bar) for multiple cryptocurrency symbols in a specific location. Use this action when you need comprehensive real-time market da…
- Get Crypto US Latest Bars Retrieves the latest OHLCV (Open, High, Low, Close, Volume) bars for US crypto symbols. Use this action when you need real-time or near real-time price data for multiple crypto trading pairs. Returns the most recent bar…
- Get Crypto US Latest Orderbooks Retrieves the latest bid and ask orderbook data for specified crypto symbols in the US market. Use when you need real-time orderbook data for cryptocurrency trading in the US market, such as checking current market dept…
- Get Crypto US Latest Quotes Retrieves the latest bid and ask prices for specified crypto symbols in the US location. Use when you need real-time quote data for cryptocurrency trading in the US market, such as checking current market prices before…
- Get Crypto US Latest Trades Retrieves the latest trade data for specified crypto symbols in the US location. Use when you need real-time trade data for cryptocurrency trading, such as monitoring recent trades, analyzing price movements, or trackin…
- Get Crypto US Historical Quotes Retrieves historical quote data (bid/ask prices) for specified crypto symbols on US exchanges. Returns quotes sorted by symbol first, then by timestamp. Use when you need: - Historical bid/ask price data for cryptocurre…
- Get Crypto US Snapshots Retrieves snapshots (latest trade, latest quote, minute bar, daily bar, and previous daily bar) for multiple cryptocurrency symbols in the US market location. Use this action when you need comprehensive real-time market…
- Get Crypto US Trades Retrieves historical trade data for specified US crypto symbols. Use when you need to: - Get historical trade data for US crypto symbols at once - Analyze trading volume and price movements over time - Build datasets fo…
- Get Exchanges Retrieves a list of supported stock exchanges with their short codes and full names from the Alpaca Market Data API. Use this action when you need to: - Get the mapping between exchange codes and full names - Understand…
- Get Latest Bar for Stock Symbol Retrieves the latest OHLCV (Open, High, Low, Close, Volume) bar for a single stock symbol. Use this action when you need real-time or near real-time price bar data for a specific stock trading symbol. This is useful for…
- Get Latest Bars For Crypto Symbol Retrieves the latest OHLCV (Open, High, Low, Close, Volume) bar data for a crypto symbol. Use this action when you need real-time or near real-time price data for a specific cryptocurrency pair. Returns the most recent…
- Get Latest Bars for Crypto Symbols Retrieves the latest OHLCV (Open, High, Low, Close, Volume) bars for multiple crypto symbols. Use this action when you need real-time or near real-time price bar data for multiple cryptocurrency pairs simultaneously. Th…
- Get Latest Bars for Multiple Stock Symbols Retrieves the latest OHLCV (Open, High, Low, Close, Volume) bars for multiple stock symbols. Use this action when you need real-time or near real-time price bar data for multiple stock trading symbols simultaneously. Th…
- Get Crypto Latest Orderbooks Retrieves the latest bid and ask orderbook data for specified crypto symbols. Use when you need real-time orderbook data for cryptocurrency trading, such as checking current market depth before placing orders or analyzi…
- Get Crypto Latest Quote Retrieves the latest bid and ask prices for a specified crypto symbol. Use when you need real-time quote data for a specific cryptocurrency, such as checking current market prices before placing an order or monitoring p…
- Get Latest Quote for Stock Symbol Retrieves the latest NBBO (National Best Bid and Offer) quote for a single stock symbol. Use this action when you need real-time or near real-time bid and ask prices for a specific stock trading symbol. This is useful f…
- Get Crypto Latest Quotes Retrieves the latest bid and ask prices for specified crypto symbols. Use when you need real-time quote data for cryptocurrency trading, such as checking current market prices before placing orders or monitoring price m…
- Get Latest Quotes for Multiple Stock Symbols Retrieves the latest NBBO (National Best Bid and Offer) quotes for multiple stock symbols. Use this action when you need real-time or near real-time bid and ask prices for multiple stock trading symbols simultaneously.…
- Get Latest Trade for Stock Symbol Retrieves the latest trade data for a single stock symbol. Use this action when you need the most recent trade information for a specific stock ticker, such as checking current market price and volume before placing an…
- Get Latest Crypto Trades Retrieves the latest trade data for specified crypto symbols. Use when you need real-time trade data for cryptocurrency trading, such as monitoring recent trades, analyzing price movements, or tracking trading volume.
- Get Latest Trades for Multiple Stock Symbols Retrieves the latest trade data for multiple stock symbols. Use this action when you need real-time or near real-time trade data for multiple stock trading symbols simultaneously. This is useful for dashboards, trade mo…
- Get Market Calendar Retrieves market calendar information for a specific exchange from the Alpaca Trading API. Use this action when you need to: - Get market open and close times for a specific exchange (NYSE, NASDAQ, etc.) - Check trading…
- Get Meta Exchanges Retrieves a list of all US stock exchanges and their identifying information from the Alpaca Market Data API. Use this action when you need to: - Get details about available stock exchanges for order routing - Understan…
- Get Most Active Stocks Retrieves the most active stocks by trading volume or trade count. Use this action when you need to: - Fetch top traded stocks for the current period - Monitor market liquidity and activity - Build trading signals based…
- Get News Retrieves news articles for specified crypto symbols from the Alpaca Market Data API. Use this action when you need to: - Fetch the latest news for crypto assets (BTCUSD, ETHUSD, etc.) - Monitor news sentiment for tradi…
- Get Open Position Fetches a single open position by symbol or asset ID. Use when you need to retrieve detailed information about a specific position, including cost basis, shares traded, market value, and unrealized P&L. This action is u…
- Get Options Historical Bars Retrieves historical OHLCV (Open, High, Low, Close, Volume) bars for options contracts. Use this action when you need to analyze historical price movements and trading activity for specific option contracts over a given…
- Get Option Chain Retrieves the option chain for a specific underlying symbol including quotes and greeks for all available strikes and expirations. Use this action when you need comprehensive option market data for a specific underlying…
- Get Option Contract Get an option contract by its symbol or unique identifier. Use this action when you need to retrieve detailed information about a specific option contract. You can query by either the contract's OCC symbol (e.g., 'AAPL2…
- Get Option Latest Quotes Retrieves the latest bid and ask prices for specified option symbols. Use when you need real-time quote data for options trading, such as checking current market prices before placing orders or monitoring price movement…
- Get Options Meta Conditions Retrieves the mapping of condition codes to their names from Alpaca Markets API for the specified tick type (trade or quote conditions). Use this action when you need to: - Decode condition codes from options market dat…
- Get Option Contracts Retrieve option contracts from Alpaca Markets API (BETA). Use this action when you need to: - Search for option contracts by underlying symbol - Filter contracts by expiration date, strike price, type (call/put), or sty…
- Get Options Latest Trades Retrieves the latest trade for each requested option contract symbol. Use this action when you need to: - Get the most recent trade price and size for specific option contracts - Check the last traded time for option sy…
- Get Options Meta Conditions Trade Retrieves the mapping of trade condition codes to their names from Alpaca Markets API. Use this action when you need to: - Decode trade condition codes from options market data - Get the list of all valid trade conditio…
- Get Options Snapshots Retrieves snapshots (latest trade, latest quote, minute bar, daily bar, and previous daily bar) for multiple option contract symbols. Use this action when you need comprehensive real-time market data for option contract…
- Get Options Snapshots by Underlying Symbol Retrieves the option chain snapshot data for a specific underlying symbol. This endpoint provides the latest trade, quote, and greeks data for all option contracts associated with an underlying symbol. It returns snapsh…
- Get Options Historical Trades Retrieves historical trade data for option contracts. Use this action when you need to: - Analyze historical trade activity for option contracts - Review past trades for specific option symbols - Calculate volume patter…
- Get PDT Status Retrieves the Pattern Day Trader (PDT) status for a specified Alpaca trading account. Use when you need to check if an account is flagged as a PDT, monitor PDT call counts, or verify day trading buying power status for…
- List account positions Lists all open positions for a specified trading account. Use when you need to retrieve current positions, monitor portfolio holdings, or check unrealized P&L for an account.
- Get Quotes for Multiple Stock Symbols Retrieves historical quote (bid/ask) data for multiple stock symbols. Use this action when you need historical quote data including bid and ask prices for multiple stock trading symbols. This is useful for trading analy…
- Get Quotes for Stock Symbol Retrieves historical NBBO (National Best Bid and Offer) quotes for a specific stock symbol. Use this action when you need historical quote data for a single stock symbol, such as for analysis, backtesting trading strate…
- Get Stock Snapshot for Symbol Retrieves a snapshot (latest trade, latest quote, minute bar, daily bar, and previous daily bar) for a single stock symbol. Use this action when you need comprehensive real-time market data for a single stock symbol, su…
- Get Crypto Snapshots Retrieves snapshots (latest trade, latest quote, minute bar, daily bar, and previous daily bar) for multiple cryptocurrency symbols. Use this action when you need comprehensive real-time market data for multiple crypto…
- Get Stock Snapshots for Multiple Symbols Retrieves snapshots (latest trade, latest quote, minute bar, daily bar, and previous daily bar) for multiple stock symbols. Use this action when you need comprehensive real-time market data for multiple stock symbols, s…
- Get Specific Announcement Retrieves a specific corporate action announcement by its unique identifier. Use this action when you need to fetch detailed information about a corporate action such as dividends, stock splits, mergers, spinoffs, or ot…
- Get Stock Auctions Retrieves historical auction data for specified stock symbols. Use this action when you need to: - Analyze opening and closing auction prices for stocks - Study pre-market and post-market auction behavior - Understand a…
- Get Stock Auctions for Symbol Retrieves historical auction (opening/closing print) data for a single stock symbol. Use this action when you need to analyze auction-related price and volume data for a specific stock ticker. This is useful for: - Unde…
- Get Stocks Meta Conditions Trade Retrieves the mapping of trade condition codes to their names from Alpaca Markets API. Use this action when you need to: - Decode trade condition codes from stock market data - Get the list of all valid trade condition…
- Get Subscription Retrieves a rebalancing subscription by its unique ID. Returns complete subscription details including the associated account ID, portfolio ID, creation timestamp, and last rebalancing timestamp. Use when you need to fe…
- Get Top Movers By Market Type Retrieves the top market movers (gainers and losers) for a specified market type. Use this action when you need to: - Fetch top gainers and losers for stock market analysis - Get cryptocurrency movers for crypto trading…
- Get Trades for Multiple Crypto Symbols Retrieves historical trade data for specified crypto symbols. Use when you need to: - Get historical trade data for multiple crypto symbols at once - Analyze trading volume and price movements over time - Build datasets…
- Get Trades for Multiple Stock Symbols Retrieves historical trade data for multiple stock symbols. Use this action when you need: - Historical trade data for multiple stock symbols at once - Analyze trading volume and price movements over time - Build datase…
- Get Historical Trades for Stock Symbol Retrieves historical trade data for a single stock symbol. Use this action when you need to analyze historical trade data for a specific stock ticker, such as reviewing price movements, trading volume patterns, or tick…
- Get Watchlist By ID Retrieves a single watchlist by its unique identifier. Use when you need to view the details of a specific watchlist, including its name, associated assets, and timestamps. This endpoint provides direct access to a watc…
- Get Watchlist By Name Retrieves a specific watchlist by its name. Use when you need to find a particular watchlist without knowing its ID, such as when managing watchlists for display or modification. Returns the watchlist details including…
- Get Watchlists Retrieves all watchlists associated with the authenticated account. Use this action when you need to: - View all watchlists for an account - Find a specific watchlist by name - Check what symbols are being tracked befor…
- Update Account Configurations Update the trading account configuration settings for the authenticated account. Use when you need to modify account-level trading settings such as day-trading buying power checks, fractional trading permissions, margin…
- Remove Asset From Watchlist Removes a symbol from an existing watchlist in Alpaca. Use this action when you need to delete a ticker symbol from a watchlist that is no longer being tracked. The action returns the updated watchlist after the symbol…
- Remove Symbol From Watchlist Tool to remove a symbol from an existing watchlist in Alpaca. Use when you need to delete a ticker symbol from a watchlist that is no longer being tracked. This action is irreversible - once a symbol is removed from a w…
- Update Trading Configurations Updates trading account configurations for an Alpaca trading account. Use when you need to modify account-level trading settings such as day-trading buying power checks, trade confirmation email preferences, or trading…
- Update Watchlist By ID Updates an existing watchlist by its unique identifier. Use when you need to modify the name or symbols in a watchlist using its ID rather than name. This action allows partial updates - you can update just the name, ju…
- Update Watchlist By Name Updates an existing watchlist by its name. Use when you need to modify the symbols in a watchlist or rename it. The action allows partial updates - you can provide only symbols to update the watchlist contents, only a n…
- Update Watchlist By Name (v2) Updates an existing watchlist by its name. Use when you need to modify the symbols in a watchlist or rename it. The action allows partial updates - you can provide only symbols to update the watchlist contents, only a n…
- Upload Account CIP Information Upload CIP (Customer Identification Program) information for an account to complete identity verification. Use when you need to submit identity information for a new Alpaca trading account as part of the account onboard…
How we connect it
- 1
Connect your account
You create a key in Alpaca, a key you create and control, and paste it in once. It lives in a secrets store on your server, not with us.
- 2
Set the guardrails
Read-only by default. You choose which write actions the agent may take, and anything outside that policy gets confirmed with you first.
- 3
We keep it running
Health checks on every connection, updates handled for you, and we watch the first week of activity to make sure the work lands.
FAQ
Alpaca questions, answered.
Ready to put Alpaca to work?
Tell us what your team runs on. We set up the connection, secure it, and your agent takes it from there.
All product names, logos, and brands are property of their respective owners; used for identification only. ZeroToClaw is not affiliated with or endorsed by Alpaca.