# Alpaca listen

Independent and unofficial. Not affiliated with or endorsed by any broker or platform named here. Educational only: nothing here is advice, and nothing here recommends a broker or a trade.

This is the markdown version of https://openbrokerapi.com/brokers/alpaca/messages/listen, written from the same records as that page.

Risk warning: CFDs and spread bets are complex instruments and come with a high risk of losing money rapidly due to leverage. You can lose money on these products, and each provider publishes its own loss figure under FCA rules. You should consider whether you understand how they work and whether you can afford to take the high risk of losing your money. Automated and API trading can amplify losses through bugs, connectivity failures and runaway orders.

Asks the account stream to send a named stream, trade_updates being the one the page documents. Each listen message replaces the whole set: send every stream you still want, or an empty list to stop.

- Message: `listen`
- Interface: Alpaca WebSocket streams
- Group: Account events
- Status: verified. Source: [docs.alpaca.markets](https://docs.alpaca.markets/us/docs/websocket-streaming.md), checked 2026-11-30.

This is a message of the Alpaca WebSocket streams, not an HTTP endpoint. It has no method and no path: it is sent as JSON, or as MessagePack where the client asks for it, over an open WebSocket connection. It is in no OpenAPI file on this site and the request builder does not list it.

Note: Sent before auth succeeds, it is answered with an authorization message carrying status unauthorized and action listen.

## The message

- Name: `listen`
- Direction: Request, sent by the client
- Carried by: WebSocket. Alpaca's page says the stream speaks JSON or MessagePack, the latter when the client sends the header Content-Type: application/msgpack, and that trade_updates from the paper address arrives in binary frames.
- Paper account stream: `wss://paper-api.alpaca.markets/stream`
- Live account stream: `wss://api.alpaca.markets/stream`
- Answered by: [trade_updates](https://openbrokerapi.com/brokers/alpaca/messages/trade-updates)

## Fields

- `action` (type string, required or not: not stated): Names the message: listen.
- `data.streams` (type array of strings, required or not: not stated): The streams to receive. trade_updates is the one the page documents. An empty list stops every stream.

## What arrives

`listening`: An acknowledgement with stream listening and the streams now active. A stream that is not available is left out of the list.

- `stream` (type string, required or not: not stated): listening.
- `data.streams` (type array of strings, required or not: not stated): The streams the connection is now receiving.

## Sample

Written by this site from the fields recorded on this page. It has not been run against a terminal, a server or an account, and the values in it are placeholders. No credential is typed into it: where a field holds one, the placeholder says where it comes from. Nothing is entered on this site.

```json
{
  "action": "listen",
  "data": {
    "streams": ["trade_updates"]
  }
}
```

## Limits that apply at Alpaca

- client_order_id length: 128 characters
  - Scope: POST /v2/orders and PATCH /v2/orders/{order_id}
  - Status: verified. Source: [docs.alpaca.markets](https://docs.alpaca.markets/openapi/trading-api.json), checked 2026-11-30.
  - Note: From the CreateOrderRequest and PatchOrderRequest schemas.
- Crypto order size: 200,000 US dollars notional per order
  - Scope: Crypto spot orders, buy or sell
  - Status: verified. Source: [docs.alpaca.markets](https://docs.alpaca.markets/us/docs/crypto-trading.md), checked 2026-11-30.
  - Note: The Crypto Spot Trading page: each order is limited to 200,000 US dollars in notional value.
- Market data historical API, Basic plan: 200 requests per minute
  - Scope: Market Data API historical calls, Basic (free) plan
  - Status: verified. Source: [docs.alpaca.markets](https://docs.alpaca.markets/us/docs/about-market-data-api.md), checked 2026-11-30.
  - Note: The About Market Data API page: Historical API limit of 200 calls per minute on Basic, with IEX real time data and stock history since 2016 limited to data 15 minutes old.
- Market data points per page: 10,000 data points per page
  - Scope: Market Data API historical bars, trades and quotes, counted across all symbols
  - Status: verified. Source: [docs.alpaca.markets](https://docs.alpaca.markets/openapi/market-data-api.json), checked 2026-11-30.
  - Note: The limit query parameter: default 1000, maximum 10000, counted across every symbol in the request. Pages continue with next_page_token.
- Market data historical API, Algo Trader Plus: 10,000 requests per minute
  - Scope: Market Data API historical calls, Algo Trader Plus plan (99 US dollars a month)
  - Status: verified. Source: [docs.alpaca.markets](https://docs.alpaca.markets/us/docs/about-market-data-api.md), checked 2026-11-30.
  - Note: The About Market Data API page: Historical API limit of 10,000 calls per minute on Algo Trader Plus.
- GTC order age: 90 days
  - Scope: Orders with time in force gtc
  - Status: verified. Source: [docs.alpaca.markets](https://docs.alpaca.markets/us/docs/orders-at-alpaca.md), checked 2026-11-30.
  - Note: The Placing Orders page: GTC orders are cancelled automatically 90 days after creation, the date shown in expires_at, by a job that runs at 4:15 pm ET.
- Trading API request rate: HTTP 429 above the limit, with X-RateLimit-Limit, X-RateLimit-Remaining and X-RateLimit-Reset headers on replies; no figure on the pages opened
  - Scope: Trading API, per account
  - Status: verified. Source: [docs.alpaca.markets](https://docs.alpaca.markets/openapi/trading-api.json), checked 2026-11-30.
  - Note: The Trading API OpenAPI document gives the 429 reply and the three headers. None of the Trading API pages opened on 30 Nov 2026 prints a number, so this site records none.
- Market data WebSocket authentication timeout: 10 seconds
  - Scope: Market data WebSocket, from connecting to the auth message
  - Status: verified. Source: [docs.alpaca.markets](https://docs.alpaca.markets/us/docs/streaming-market-data.md), checked 2026-11-30.
  - Note: Error 404 auth timeout where no auth message arrives in time.
- Market data WebSocket connections: Depends on the subscription; 1 for many subscriptions and with none. A second connection is answered with error 406 connection limit exceeded
  - Scope: Market data WebSocket, per account
  - Status: verified. Source: [docs.alpaca.markets](https://docs.alpaca.markets/us/docs/streaming-market-data.md), checked 2026-11-30.
  - Note: The WebSocket Stream page gives no table of figures by plan.
- Market data WebSocket symbols, Basic plan: 30 symbol subscriptions
  - Scope: Market data WebSocket, US equities, Basic (free) plan; Algo Trader Plus is unlimited
  - Status: verified. Source: [docs.alpaca.markets](https://docs.alpaca.markets/us/docs/about-market-data-api.md), checked 2026-11-30.
  - Note: The About Market Data API page: up to 30 WebSocket symbol subscriptions on Basic for equities, unlimited on Algo Trader Plus; for options 200 quote subscriptions on Basic and 1,000 on Algo Trader Plus. Over the limit the stream answers error 405.

## Related Alpaca messages: Account events

- [trade_updates](https://openbrokerapi.com/brokers/alpaca/messages/trade-updates): One message per order event on the account: the event name, the whole order object as the REST API returns it, and for fills the price, quantity and resulting position.

## More on Alpaca

- [All Alpaca messages](https://openbrokerapi.com/brokers/alpaca/messages): 9 documented here, grouped by what they do.
- [Subscribe to a stream: the call at each API](https://openbrokerapi.com/endpoints/streaming-subscribe): The same job at every broker and platform API recorded here, HTTP or not.
- [Alpaca API quickstart](https://openbrokerapi.com/brokers/alpaca/quickstart)
- [All Alpaca error codes](https://openbrokerapi.com/errors/alpaca)
- [Alpaca API page](https://openbrokerapi.com/brokers/alpaca): The full record: access, authentication, limits and the source for each.

## Licence and how to cite

The records behind this page are all rights reserved. This file is the page itself, at its own address, in another format. It is not part of the CC BY 4.0 downloads listed at https://openbrokerapi.com/data. Quote from it with a link to the page.

Cite as: Alpaca listen. Broker API Hub, https://openbrokerapi.com/brokers/alpaca/messages/listen, newest check 2026-11-30.

Where you rely on a single figure, cite the source and the checked date printed beside it as well. Where this page and a broker's own documentation differ, the documentation wins.
