GET
/v2/aggs/ticker/{stocksTicker}/prev
Stocks Previous Day Bar (OHLC)
Previous trading day OHLC for a stock ticker.
Endpoint Details
| HTTP Method |
GET |
| Path |
/v2/aggs/ticker/{stocksTicker}/prev |
| Version |
v2 |
| Minimum Plan |
free |
Path Parameters
| Parameter |
Required |
Description |
Example |
stocksTicker |
Required |
The stock ticker symbol (e.g., AAPL, MSFT) |
AAPL |
Query Parameters
| Parameter |
Type |
Required |
Description |
api_key |
string |
Required |
Your API key for authentication |
adjusted |
boolean |
Optional
|
Whether aggregates are adjusted for splits (default: true) |
sort |
string |
Optional
|
Sort order (asc or desc, default: asc) |
limit |
integer |
Optional
|
Maximum number of results (default: 5000, max: 50000) |
Example Request
curl "https://mail.tradeiqai.com/api/v2/aggs/ticker/AAPL/prev?api_key=YOUR_API_KEY"
Note: Replace YOUR_API_KEY with your actual API key.
Response Attributes
| Attribute |
Type |
Description |
ok | boolean | Indicates if the request was successful (e.g., 1) |
data | object | Response data object |
data.status | string | Response status (typically "OK") (e.g., OK) |
data.results | array | Array of 1 items |
| Array items contain: |
data.results[].T | string | String value (e.g., AAPL) |
data.results[].v | integer | Integer (e.g., 25900599) |
data.results[].vw | double | Floating point number (e.g., 340.5982) |
data.results[].o | double | Floating point number (e.g., 338.215) |
data.results[].c | double | Floating point number (e.g., 340.97) |
data.results[].h | double | Floating point number (e.g., 342.63) |
data.results[].l | double | Floating point number (e.g., 337.6) |
data.results[].t | integer | Integer (e.g., 1791835200000) |
data.results[].n | integer | Integer (e.g., 622508) |
Example Response
{
"ok": true,
"data": {
"status": "OK",
"ticker": "AAPL",
"adjusted": true,
"results": [
{
"T": "AAPL",
"v": 25900599,
"vw": 340.5982000000000198269844986498355865478515625,
"o": 338.21499999999997498889570124447345733642578125,
"c": 340.970000000000027284841053187847137451171875,
"h": 342.6299999999999954525264911353588104248046875,
"l": 337.6000000000000227373675443232059478759765625,
"t": 1791835200000,
"n": 622508
}
]
}
}