Index Membership As-Of a Date
get_index_membership_asofDetermine historical index membership for a stock on a specific date, returning present, uncertain, absent, or out of coverage for point-in-time universe construction and survivorship-bias-aware backtests.
Instructions
Was a stock a constituent of an index on a specific historical date? Returns a FOUR-STATE answer, never a bare yes/no: present (proven in range), uncertain (inside an unobserved bracket around a join/leave — plausible but NOT proven), absent (proven not a member, within coverage), or out_of_coverage (outside the observed window — we cannot answer). USE THIS for any 'was X in the Nifty 50/500 on ' question, and for point-in-time universe construction or survivorship-bias-aware backtests. Do NOT infer historical membership from today's constituent list — that is exactly the survivorship bias this tool exists to avoid. REPORT UNCERTAINTY HONESTLY: treat uncertain and out_of_coverage as NOT tradeable signal and say so; never silently collapse either into absent. The response states its own meta.coverage window plus meta.freshness.lag_days — trust answers only up to coverage.answerable_through.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| date | No | As-of date, YYYY-MM-DD. Defaults to today (IST) when omitted. | |
| index | No | REQUIRED. Index name, e.g. "Nifty 50", "Nifty 500", "Nifty Midcap 150". | |
| symbol | No | REQUIRED. The stock symbol, e.g. "TRENT". | |
| ticker | No | Alias for `symbol`. | |
| identifier | No | Alias for `symbol`. |