nqs_sdk.bindings.protocols.cex.cex_transactions module

class nqs_sdk.bindings.protocols.cex.cex_transactions.RebalanceTransaction(token0, token1, weight0, weight1, current_price)[source]

Bases: Transaction

__init__(token0, token1, weight0, weight1, current_price)[source]
token0: str
token1: str
weight0: Decimal
weight1: Decimal
execution_price: Decimal
to_tx_request(protocol, source, sender, order=0.0)[source]
Return type:

TxRequest

class nqs_sdk.bindings.protocols.cex.cex_transactions.OpenMarginPositionTransaction(token, direction, amount, collateral, collateral_amount, execution_price, token_id)[source]

Bases: Transaction

__init__(token, direction, amount, collateral, collateral_amount, execution_price, token_id)[source]
token: str
direction: bool
amount: Decimal
collateral: str
collateral_amount: Decimal
token_id: str
to_tx_request(protocol, source, sender, order=0.0)[source]
Return type:

TxRequest

class nqs_sdk.bindings.protocols.cex.cex_transactions.CheckMarginPositionTransaction(current_prices, maintenance_fees)[source]

Bases: Transaction

__init__(current_prices, maintenance_fees)[source]
current_prices: list[Decimal]
maintenance_fees: dict[str, Decimal]
to_tx_request(protocol, source, sender, order=0.0)[source]
Return type:

TxRequest

class nqs_sdk.bindings.protocols.cex.cex_transactions.CloseMarginPositionTransaction(token_id, execution_price, price_history)[source]

Bases: Transaction

__init__(token_id, execution_price, price_history)[source]
token_id: str
execution_price: Decimal
to_tx_request(protocol, source, sender, order=0.0)[source]
Return type:

TxRequest

class nqs_sdk.bindings.protocols.cex.cex_transactions.AddMarginCollateralTransaction(token_id, amount)[source]

Bases: Transaction

__init__(token_id, amount)[source]
token_id: str
amount: Decimal
to_tx_request(protocol, source, sender, order=0.0)[source]
Return type:

TxRequest

class nqs_sdk.bindings.protocols.cex.cex_transactions.ExchangeTransaction(token0, token1, direction, amount, execution_price)[source]

Bases: Transaction

__init__(token0, token1, direction, amount, execution_price)[source]
token0: str
token1: str
direction: bool
amount: Decimal
execution_price: Decimal
to_tx_request(protocol, source, sender, order=0.0)[source]
Return type:

TxRequest