calendar / wire operation
Trading sessions & option expirations
totalfinance.calendar.sessions
Trading days, holidays, and half days for an exchange calendar over a date range (≤ ~13 months), plus option expirations (weekly Fridays / monthly OPEX / quarterly, shifted off holidays from the calendar data) when `expirationKind` is set, and the next expiry after the range start. NYSE/CBOE one-off closure coverage begins 2001-01-01; earlier ranges carry a diagnostic. Rules project other dates, not future emergency closures.
| Pack / profiles | calendar / default, full |
|---|---|
| Default discovery | Included |
| Required capabilities | None |
| Effects / authorization | none / none |
| Cost / cancellation | small / Do not assume inline interruption |
| Handle-eligible inputs | None |
| Idempotency | not-applicable |
Input schema
{
"type": "object",
"properties": {
"calendar": {
"type": "string",
"enum": [
"NYSE",
"CBOE",
"crypto24x7"
],
"description": "Exchange calendar"
},
"from": {
"type": "string",
"description": "Range start (ISO YYYY-MM-DD, inclusive)"
},
"to": {
"type": "string",
"description": "Range end (ISO YYYY-MM-DD, inclusive)"
},
"expirationKind": {
"type": "string",
"enum": [
"weekly",
"monthly",
"quarterly"
],
"description": "Also return option expirations of this kind (holiday-shifted)"
}
},
"additionalProperties": false,
"required": [
"calendar",
"from",
"to"
]
}Output schema
{
"type": "object",
"properties": {
"tradingDays": {
"type": "array",
"items": {
"type": "string"
}
},
"holidays": {
"type": "array",
"items": {
"type": "string"
}
},
"halfDays": {
"type": "array",
"items": {
"type": "string"
}
},
"expirations": {
"type": "array",
"items": {
"type": "string"
}
},
"nextExpiry": {
"type": "string"
},
"calendar": {
"type": "object",
"description": "name/version/timezone and documented closure-data coverage"
},
"diagnostics": {
"type": "object",
"description": "Warnings when the range crosses the historical coverage floor"
}
},
"required": [
"tradingDays",
"holidays",
"halfDays",
"calendar"
]
}