Skip to main content

ib_contract_to_instrument_id_simple

Function ib_contract_to_instrument_id_simple 

Source
pub fn ib_contract_to_instrument_id_simple(
    contract: &Contract,
) -> Result<InstrumentId>
Expand description

Convert an IB Contract to an InstrumentId (simple version using contract fields).

This is a convenience wrapper that uses simplified symbology by default. For more accurate mapping, use the instrument provider which has contract details.

ยงErrors

Returns an error if the instrument ID cannot be constructed.