Historical bars (single symbol)

The historical stock bars API provides aggregates for the stock symbol between the specified dates.

Path Params
string
required

The symbol to query.

Query Params
string
required

The timeframe represented by each bar in aggregation. You can use any of the following values:

  • [1-59]Min or [1-59]T, e.g. 5Min or 5T creates 5-minute aggregations
  • [1-23]Hour or [1-23]H, e.g. 12Hour or 12H creates 12-hour aggregations
  • 1Day or 1D creates 1-day aggregations
  • 1Week or 1W creates 1-week aggregations
  • [1,2,3,4,6,12]Month or [1,2,3,4,6,12]M, e.g. 3Month or 3M creates 3-month aggregations
date-time

The inclusive start of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the beginning of the current day, but at least 15 minutes ago if the user doesn't have real-time access for the feed.

date-time

The inclusive end of the interval. Format: RFC-3339 or YYYY-MM-DD. Default: the current time if the user has a real-time access for the feed, otherwise 15 minutes before the current time.

integer
1 to 10000
Defaults to 1000

The maximum number of data points to return in the response page. The API may return less, even if there are more available data points in the requested interval. Always check the next_page_token for more pages. The limit applies to the total number of data points, not per symbol!

string
Defaults to raw

Specifies the adjustments for the bars.

  • raw: no adjustments
  • split: adjust price and volume for forward and reverse stock splits
  • dividend: adjust price for cash dividends
  • spin-off: adjust price for spin-offs
  • all: apply all above adjustments

You can combine multiple adjustments by separating them with a comma, e.g. split,spin-off.

string

The as-of date of the queried stock symbol(s). Format: YYYY-MM-DD. Default: current day.

This date is used to identify the underlying entity of the provided symbol(s), so that name changes for this entity can be found. Data for past symbol(s) is returned if the query date range spans the name change.

The special value of "-" means symbol mapping is skipped. Data is returned based on the symbol alone without looking up previous names. The same happens if the queried symbol is not found on the given asof date.

Example: FB was renamed to META in 2022-06-09. Querying META with an asof date after 2022-06-09 will also yield FB data. The data for the FB ticker will be labeled as META because they are considered the same underlying entity as of 2022-06-09. Querying FB with an asof date after 2022-06-09 will only return data with the FB ticker, not with META. But with an asof date before 2022-06-09, META will also be returned (as FB).

string
enum
Defaults to sip

The source feed of the data.

  • sip: all US exchanges
  • iex: Investors EXchange
  • boats: Blue Ocean ATS, overnight US trading data
  • otc: over-the-counter exchanges
Allowed:
string

The currency of all prices in ISO 4217 format. Default: USD.

string

The pagination token from which to continue. The value to pass here is returned in specific requests when more data is available, usually because of a response result limit.

string
enum
Defaults to asc

Sort data in ascending or descending order.

Allowed:
Responses

401

Authentication headers are missing or invalid. Make sure you authenticate your request with a valid API key.

403

The requested resource is forbidden.

500

Internal server error. We recommend retrying these later. If the issue persists, please contact us on Slack or on the Community Forum.

Language
Credentials
URL
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json
*/*