WebSocket Endpoint
All WebSocket connections can be established using the following endpoint:Authentication
The Benzinga WebSocket API requires bearer authentication. When initiating a WebSocket connection, include your API token in the connection URL as a query parameter in the following format: you must include your API token in thetoken query param in the format token: <token>.
Refer to the Authentication page for more information on obtaining and managing your API token.
Subscribing to Streams
Once connected, you can subscribe to specific data streams based on your requirements, such as stock quotes, trade data, or news updates. Each subscription requires a unique identifier and specific parameters depending on the data type.Example Subscription Message
To subscribe to a live stock quote stream, send a JSON message formatted as follows:Rate Limiting
Please note that the Benzinga API has rate limits to prevent abuse and ensure service stability. Only 1 connection per API token is allowed at a time. If you exceed the rate limit, you will receive an error response.We hope this guide helps you get started with the Benzinga APIs. If you have any questions, please don’t hesitate to reach out to our support team.