Stock OHLCV bars by ticker and date range, any interval
polygon.aggs.rangeOHLCV bars for a ticker at any granularity (minute to year) over a date range — Polygon's workhorse endpoint
- Price
- Price pendingAt provider cost
- Success rate
- —No success-rate data yetLast 30 days · 0 calls
- Latency p50
- ——
- Last verified
- Aug 15, 2026Verified working
GEThttps://toolswitch.dev/v1/tools/polygon.aggs.range?to=2026-08-14&from=2026-08-01&limit=5&ticker=AAPL×pan=day&multiplier=1PreviewTry onlineComing soonProvider docs ↗
- Uses platform quota
- Synchronous response
- Reads public data
Parameters
| Parameter | Type | Required | Description | Example |
|---|---|---|---|---|
| Query parameters | ||||
to | string | Required | path parameter — YYYY-MM-DD | 2026-08-14 |
from | string | Required | path parameter — YYYY-MM-DD | 2026-08-01 |
sort | string | Optional | asc | desc | |
limit | integer | Optional | max 50000 | 5 |
ticker | string | Required | path parameter | AAPL |
adjusted | boolean | Optional | ||
timespan | string | Required | path parameter — minute | hour | day | week | month | quarter | year | day |
multiplier | integer | Required | path parameter — bar size multiplier | 1 |
- Query parameters
tostringRequiredpath parameter — YYYY-MM-DD
Example:
2026-08-14fromstringRequiredpath parameter — YYYY-MM-DD
Example:
2026-08-01sortstringOptionalasc | desc
limitintegerOptionalmax 50000
Example:
5tickerstringRequiredpath parameter
Example:
AAPLadjustedbooleanOptionaltimespanstringRequiredpath parameter — minute | hour | day | week | month | quarter | year
Example:
daymultiplierintegerRequiredpath parameter — bar size multiplier
Example:
1
Code samples
Replace $TOOLSWITCH_KEY with the key you created in the console.
Preview
curl -X GET 'https://toolswitch.dev/v1/tools/polygon.aggs.range?to=2026-08-14&from=2026-08-01&limit=5&ticker=AAPL×pan=day&multiplier=1' \
-H "X-Toolswitch-Key: $TOOLSWITCH_KEY"import os
import requests
response = requests.request(
"GET",
"https://toolswitch.dev/v1/tools/polygon.aggs.range?to=2026-08-14&from=2026-08-01&limit=5&ticker=AAPL×pan=day&multiplier=1",
headers={"X-Toolswitch-Key": os.environ["TOOLSWITCH_KEY"]},
)
response.raise_for_status()
print(response.text)const response = await fetch("https://toolswitch.dev/v1/tools/polygon.aggs.range?to=2026-08-14&from=2026-08-01&limit=5&ticker=AAPL×pan=day&multiplier=1", {
method: "GET",
headers: {
"X-Toolswitch-Key": process.env.TOOLSWITCH_KEY ?? "",
},
});
if (!response.ok) throw new Error(`Request failed: ${response.status}`);
console.log(await response.text());This gateway API is in preview; its URL and authentication may change. The example parameters are sample data.