Fetch bar data for a given symbol and period
The symbol to fetch bar data for
The time period for the bar data
Required for SINCE_PURCHASE. YYYY-MM-DD
| Name | Type | Required | Description |
|---|---|---|---|
| symbol | string | Yes | The symbol to fetch bar data for |
| period | stringDAYWEEKMONTHQUARTERHALF_YEARYEARFIVE_YEARSYTDSINCE_PURCHASE | Yes | The time period for the bar data |
| purchaseDate | string | No | Required for SINCE_PURCHASE. YYYY-MM-DD |
No request body defined
Successful response with bar data
No response body defined
{
"symbol": "string",
"period": "string",
"totalExpectedBars": 123,
"previousClosePrice": "string",
"totalGainLoss": "string",
"totalGainLossPercentage": "string",
"preMarket": {
"expectedBars": 123,
"bars": [
{
"timestamp": "string",
"open": "string",
"close": "string",
"high": "string",
"low": "string",
"value": "string",
"volume": 123,
"gainAmount": "string",
"gainPercentage": "string"
}
]
},
"regularMarket": {
"expectedBars": 123,
"bars": [
{
"timestamp": "string",
"open": "string",
"close": "string",
"high": "string",
"low": "string",
"value": "string",
"volume": 123,
"gainAmount": "string",
"gainPercentage": "string"
}
]
},
"afterMarket": {
"expectedBars": 123,
"bars": [
{
"timestamp": "string",
"open": "string",
"close": "string",
"high": "string",
"low": "string",
"value": "string",
"volume": 123,
"gainAmount": "string",
"gainPercentage": "string"
}
]
},
"lastTradingSessionClose": {
"close": "string",
"closeDate": "string",
"change": "string",
"percentChange": "string"
},
"regularSessionClosingData": {
"timestamp": "string",
"price": "string"
},
"lastRegularTradingSessionClose": {
"close": "string",
"closeDate": "string",
"change": "string",
"percentChange": "string"
}
}