WSH corporate events
get_wsh_eventsRetrieve corporate events from Wall Street Horizon—earnings, dividends, splits, meetings—for contracts, portfolios, or watchlists, filtered by date range and event type.
Instructions
List Wall Street Horizon corporate events: earnings dates, dividends, splits, meetings.
Also shareholder and board meetings, conferences and more (get_wsh_metadata lists
the event types). Give a contract, event_types, a raw filter_json, or
fill_portfolio/fill_watchlist; narrow by start_date/end_date. Returns at most `limit`
events (default 50, max 100); each event is the JSON object WSH sends (event type
tag, dates, company, details), and `request` shows what was asked of IBKR.
truncated=true means more events may exist: narrow the dates to page through them.
The WSH metadata is requested automatically first, as IBKR requires. Needs a Wall
Street Horizon corporate event data subscription (paid) on the IBKR login; without
it IBKR answers with an ib_api_error.
Errors: not_found (no events match: widen the dates or check event_types),
invalid_request (unknown event type, bad filter_json, dates in the wrong order,
nothing to ask for), account_not_allowed (fill_portfolio on a login with accounts
outside the allowlist).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | Maximum number of items to return. Omit for the tool's default; larger values are capped. The result's truncated flag says whether more were available. | |
| contract | No | The company (usually a stock). Alone it returns all its event types; add event_types to narrow them. | |
| end_date | No | Last day to include (YYYY-MM-DD). | |
| start_date | No | First day to include (YYYY-MM-DD). | |
| event_types | No | WSH event type tags from get_wsh_metadata, e.g. wshe_ed (earnings date), wshe_bod (board meeting). | |
| filter_json | No | A raw WSH filter: a JSON object (or its text), e.g. {"watchlist": ["8314"], "wshe_ed": "true"}. Overrides contract and event_types; dates, fill flags and limit still apply. | |
| fill_portfolio | No | Also include the instruments held in the login's portfolio (WSH fillPortfolio). Refused when the login has accounts outside this server's allowlist. | |
| fill_watchlist | No | Also include the login's watchlist instruments (WSH fillWatchlist). | |
| fill_competitors | No | Also include the competitors of the selected companies (WSH fillCompetitors); not enough on its own. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| notes | No | Remarks about how the arguments were used. | |
| total | Yes | How many events IBKR returned, before the limit. | |
| events | Yes | One object per event, as WSH describes it (event type tag, dates, company and event-specific data). Missing numbers are null. | |
| request | Yes | What was asked of IBKR. | |
| contract | No | The instrument asked about, if any. | |
| truncated | No | True when the result was cut to the limit. |