Alpaca
communityCommission-free stock and crypto trading API for building trading apps and algorithms.
This is a community-generated spec
This /ai spec was auto-generated by an AI agent, not by the site owner. It may be incomplete or inaccurate.
GET
https://api.alpaca.markets/v2/accountGet account
Returns
id, status, currency, buying_power, cash, portfolio_value, equity, last_equity, long_market_value, short_market_valueGET
https://api.alpaca.markets/v2/positionsGet positions
Returns
positions[] with asset_id, symbol, qty, avg_entry_price, current_price, market_value, unrealized_pl, unrealized_plpc, sidePOST
https://api.alpaca.markets/v2/ordersCreate order
Parameters
qtyquantity (numberrequiredsidebuy|sell (stringrequiredtypemarket|limit|stop|stop_limit (stringrequiredsymbolticker (stringrequiredlimit_priceprice (numberoptionaltime_in_forceday|gtc|ioc|fok (stringrequiredReturns
id, symbol, qty, side, type, status, filled_qty, filled_avg_price, created_at