Skip to main content

Module parse

Module parse 

Source
Expand description

Parsing utilities for the Derive adapter.

Constants§

DERIVE_POST_ONLY_CROSS_MARKET_ERROR_CODE
JSON-RPC error code returned when a post-only order crosses the market.

Functions§

derive_order_side_to_nautilus
Maps a Derive order side back to Nautilus.
derive_order_type_to_nautilus
Maps a Derive order type back to Nautilus.
derive_order_type_to_nautilus_for_order
Maps a Derive trigger order record back to the Nautilus order type.
derive_rejection_due_post_only
Returns whether a Derive rejection means a post-only order crossed the market.
derive_status_to_nautilus
Maps a Derive order status to the Nautilus equivalent, given the current filled quantity.
derive_tif_to_nautilus
Maps a Derive TIF back to Nautilus.
derive_trigger_price_type_to_nautilus
Maps a Derive trigger price source back to Nautilus.
deserialize_derive_decimal
Deserializes a Derive decimal, rounding fractional scales above 28 digits.
deserialize_optional_derive_decimal
Deserializes an optional Derive decimal, rounding fractional scales above 28 digits.
format_instrument_id
Converts a Derive venue symbol to a Nautilus instrument ID.
format_venue_symbol
Converts a Nautilus Derive instrument ID back to the venue symbol.
order_side_to_derive
Maps a Nautilus order side to the Derive direction string.
order_type_to_derive
Maps a Nautilus order type to the Derive order type string.
parse_derive_instrument_any
Parses a Derive instrument definition into a Nautilus instrument.
time_in_force_to_derive
Maps a Nautilus time-in-force flag to the Derive TIF.
trigger_order_type_to_derive
Maps a supported Nautilus trigger order type to the child Derive order type.
trigger_price_type_to_derive
Maps Nautilus trigger price source to Derive.
trigger_type_to_derive
Maps a Nautilus trigger order type to Derive’s stop-loss/take-profit flag.