Context
The recent NQ/NDXP options workflow required raw IBKR scripts to discover exact contracts. The current shared BrokerClient intentionally covers basic account and market-data reads, while option commands bypass it through the full Schwab client. The installed IBKR option model is OSI/equity-option oriented and does not carry enough identity for futures options or alternate index trading classes.
Examples that must be represented without symbol heuristics:
- NQ futures options:
assetClass=FOP, trading class such as QN3, exchange, multiplier 20.
- NDX vs NDXP: same underlying family but different trading class and settlement behavior.
- Broker conids are useful for immediate API calls but must not become the durable domain identity.
Goal
Introduce capability-specific derivative contracts and extend the IBKR client boundary so the CLI can resolve equity options, index options, and futures options consistently.
Proposed model
A normalized derivative identity should include at least:
- asset class (
OPT or FOP)
- underlying
- expiration
- strike
- right
- trading class
- exchange
- multiplier
- settlement/exercise metadata when available
- optional broker-scoped contract reference
Keep durable semantic identity separate from IBKR conids/OCC encoding.
Prefer capability interfaces such as DerivativeDiscoveryClient over adding every optional operation to the existing shared BrokerClient.
Scope
- Define normalized derivative request, contract, expiry, quote, and data-availability types.
- Generalize
@huskly/ibkr-client discovery beyond OSI/OPT assumptions.
- Support the stateful IBKR security-definition discovery flow for
OPT and FOP.
- Resolve exact trading class, exchange, multiplier, and broker contract reference.
- Normalize missing, delayed, frozen, and unavailable market data.
- Add an adapter/capability resolver in this repository.
- Document which fields are durable and which are broker-local.
- Do not add live order submission in this issue.
Acceptance criteria
Non-goals
- Spread payoff calculations.
- What-If/order preview.
- Live order submission.
- Generic raw IBKR request access from the CLI.
Context
The recent NQ/NDXP options workflow required raw IBKR scripts to discover exact contracts. The current shared
BrokerClientintentionally covers basic account and market-data reads, while option commands bypass it through the full Schwab client. The installed IBKR option model is OSI/equity-option oriented and does not carry enough identity for futures options or alternate index trading classes.Examples that must be represented without symbol heuristics:
assetClass=FOP, trading class such asQN3, exchange, multiplier 20.Goal
Introduce capability-specific derivative contracts and extend the IBKR client boundary so the CLI can resolve equity options, index options, and futures options consistently.
Proposed model
A normalized derivative identity should include at least:
OPTorFOP)Keep durable semantic identity separate from IBKR conids/OCC encoding.
Prefer capability interfaces such as
DerivativeDiscoveryClientover adding every optional operation to the existing sharedBrokerClient.Scope
@huskly/ibkr-clientdiscovery beyond OSI/OPTassumptions.OPTandFOP.Acceptance criteria
anyand compile under the repository's strict settings.Non-goals