RFQOperations
RFQOperations¶
Info
Access via client.rfq property.
High-level RFQ management operations.
Initialize order operations.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
subaccount
|
Subaccount
|
Subaccount instance providing access to auth, config, and APIs |
required |
Functions¶
cancel_batch_quotes
¶
cancel_batch_quotes(
*,
label: Optional[str] = None,
nonce: Optional[int] = None,
quote_id: Optional[str] = None,
rfq_id: Optional[str] = None
) -> PrivateCancelBatchQuotesResultSchema
Cancels quotes given optional filters. If no filters are provided, all quotes by the subaccount are cancelled.
All filters are combined using AND logic, so mutually exclusive filters will
result in no quotes being cancelled.
cancel_batch_rfqs
¶
cancel_batch_rfqs(
*,
label: Optional[str] = None,
nonce: Optional[int] = None,
rfq_id: Optional[str] = None
) -> PrivateCancelBatchRfqsResultSchema
Cancels RFQs given optional filters.
If no filters are provided, all RFQs for the subaccount are cancelled.
All filters are combined using AND logic, so mutually exclusive filters will
result in no RFQs being cancelled.
cancel_quote
¶
cancel_quote(
quote_id: str,
) -> PrivateCancelQuoteResultSchema
Cancels an open quote.
execute_quote
¶
execute_quote(
*,
direction: Direction,
legs: list[LegPricedSchema],
quote_id: str,
rfq_id: str,
max_fee: Decimal = Decimal("1000"),
label: str = "",
signature_expiry_sec: Optional[int] = None,
nonce: Optional[int] = None
) -> PrivateExecuteQuoteResultSchema
Executes a quote.
get_best_quote
¶
get_best_quote(
legs: list[LegUnpricedSchema],
direction: Direction = buy,
rfq_id: Optional[str] = None,
label: str = "",
counterparties: Optional[list[str]] = None,
max_total_cost: Optional[Decimal] = None,
min_total_cost: Optional[Decimal] = None,
partial_fill_step: Decimal = Decimal("1"),
) -> PrivateRfqGetBestQuoteResultSchema
Performs a "dry run" on an RFQ, returning the estimated fee and whether the trade is expected to pass.
Should any exception be raised in the process of evaluating the trade, a standard RPC error will be returned with the error details.
get_quotes
¶
get_quotes(
*,
from_timestamp: int = 0,
page: int = 1,
page_size: int = 100,
quote_id: Optional[str] = None,
rfq_id: Optional[str] = None,
status: Optional[Status] = None,
to_timestamp: int = UINT64_MAX
) -> PrivateGetQuotesResultSchema
Retrieves a list of quotes matching filter criteria.
Market makers can use this to get their open quotes, quote history, etc.
get_rfqs
¶
get_rfqs(
*,
page: int = 1,
page_size: int = 100,
rfq_id: Optional[str] = None,
status: Optional[Status] = None,
from_timestamp: int = 0,
to_timestamp: int = UINT64_MAX
) -> PrivateGetRfqsResultSchema
Retrieves a list of RFQs matching filter criteria.
Takers can use this to get their open RFQs, RFQ history, etc.
poll_quotes
¶
poll_quotes(
*,
from_timestamp: int = 0,
page: int = 1,
page_size: int = 100,
quote_id: Optional[str] = None,
rfq_id: Optional[str] = None,
status: Optional[Status] = None,
to_timestamp: int = UINT64_MAX
) -> PrivatePollQuotesResultSchema
Retrieves a list of quotes matching filter criteria.
Takers can use this to poll open quotes that they can fill against their open RFQs.
poll_rfqs
¶
poll_rfqs(
*,
from_timestamp: int = 0,
page: int = 1,
page_size: int = 100,
rfq_id: Optional[str] = None,
rfq_subaccount_id: Optional[int] = None,
status: Optional[Status] = None,
to_timestamp: int = UINT64_MAX
) -> PrivatePollRfqsResultSchema
Retrieves a list of RFQs matching filter criteria.
Market makers can use this to poll RFQs directed to them.
send_quote
¶
send_quote(
*,
direction: Direction,
legs: list[LegPricedSchema],
rfq_id: str,
max_fee: Decimal = Decimal("1000"),
signature_expiry_sec: Optional[int] = None,
nonce: Optional[int] = None,
label: str = "",
mmp: bool = False
) -> PrivateSendQuoteResultSchema
Sends a quote in response to an RFQ request.
The legs supplied in the parameters must exactly match those in the RFQ.
send_rfq
¶
send_rfq(
*,
legs: list[LegUnpricedSchema],
counterparties: Optional[list[str]] = None,
label: str = "",
max_total_cost: Optional[Decimal] = None,
min_total_cost: Optional[Decimal] = None,
partial_fill_step: Decimal = Decimal("1")
) -> PrivateSendRfqResultSchema
Requests two-sided quotes from participating market makers.