Models

class intents.models.TokenResponse(**data)[source]

Bases: BaseModel

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

model_config: ClassVar[ConfigDict] = {'alias_generator': <function to_camel>, 'populate_by_name': True, 'validate_by_alias': True, 'validate_by_name': True}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

asset_id: str
decimals: int
blockchain: str
symbol: str
price: float
price_updated_at: datetime
contract_address: str | None
class intents.models.AppFee(**data)[source]

Bases: BaseModel

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

model_config: ClassVar[ConfigDict] = {'alias_generator': <function to_camel>, 'populate_by_name': True, 'validate_by_alias': True, 'validate_by_name': True}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

recipient: str
fee: int
class intents.models.QuoteRequest(**data)[source]

Bases: BaseModel

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

model_config: ClassVar[ConfigDict] = {'alias_generator': <function to_camel>, 'populate_by_name': True, 'validate_by_alias': True, 'validate_by_name': True}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

dry: bool
swap_type: SwapType | str
slippage_tolerance: int
origin_asset: str
deposit_type: DepositType | str
destination_asset: str
amount: str
refund_to: str
refund_type: RefundType | str
recipient: str
recipient_type: RecipientType | str
deadline: datetime
deposit_mode: DepositMode | str
connected_wallets: list[str] | None
session_id: str | None
virtual_chain_recipient: str | None
virtual_chain_refund_recipient: str | None
custom_recipient_msg: str | None
referral: str | None
quote_waiting_time_ms: int
app_fees: list[AppFee] | None
to_api_dict()[source]
Return type:

dict

class intents.models.Quote(**data)[source]

Bases: BaseModel

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

model_config: ClassVar[ConfigDict] = {'alias_generator': <function to_camel>, 'populate_by_name': True, 'validate_by_alias': True, 'validate_by_name': True}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

amount_in: str
amount_in_formatted: str
amount_in_usd: str
min_amount_in: str
max_amount_in: str | None
amount_out: str
amount_out_formatted: str
amount_out_usd: str
min_amount_out: str
time_estimate: int
deposit_address: str | None
deposit_memo: str | None
deadline: datetime | None
time_when_inactive: datetime | None
virtual_chain_recipient: str | None
virtual_chain_refund_recipient: str | None
custom_recipient_msg: str | None
refund_fee: str | None
class intents.models.QuoteResponse(**data)[source]

Bases: BaseModel

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

model_config: ClassVar[ConfigDict] = {'alias_generator': <function to_camel>, 'populate_by_name': True, 'validate_by_alias': True, 'validate_by_name': True}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

correlation_id: str | None
timestamp: datetime
signature: str
quote_request: QuoteRequest
quote: Quote
class intents.models.TransactionDetails(**data)[source]

Bases: BaseModel

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

model_config: ClassVar[ConfigDict] = {'alias_generator': <function to_camel>, 'populate_by_name': True, 'validate_by_alias': True, 'validate_by_name': True}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

hash: str
explorer_url: str
class intents.models.SwapDetails(**data)[source]

Bases: BaseModel

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

model_config: ClassVar[ConfigDict] = {'alias_generator': <function to_camel>, 'populate_by_name': True, 'validate_by_alias': True, 'validate_by_name': True}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

intent_hashes: list[str]
near_tx_hashes: list[str]
origin_chain_tx_hashes: list[TransactionDetails]
destination_chain_tx_hashes: list[TransactionDetails]
amount_in: str | None
amount_in_formatted: str | None
amount_in_usd: str | None
amount_out: str | None
amount_out_formatted: str | None
amount_out_usd: str | None
slippage: int | None
refunded_amount: str | None
refunded_amount_formatted: str | None
refunded_amount_usd: str | None
refund_reason: str | None
deposited_amount: str | None
deposited_amount_formatted: str | None
deposited_amount_usd: str | None
referral: str | None
class intents.models.ExecutionStatusResponse(**data)[source]

Bases: BaseModel

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

model_config: ClassVar[ConfigDict] = {'alias_generator': <function to_camel>, 'populate_by_name': True, 'validate_by_alias': True, 'validate_by_name': True}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

correlation_id: str
quote_response: QuoteResponse
status: SwapStatus
updated_at: datetime
swap_details: SwapDetails
class intents.models.AnyInputWithdrawal(**data)[source]

Bases: BaseModel

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

model_config: ClassVar[ConfigDict] = {'alias_generator': <function to_camel>, 'populate_by_name': True, 'validate_by_alias': True, 'validate_by_name': True}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

status: str
amount_out_formatted: str
amount_out_usd: str
amount_out: str
withdraw_fee_formatted: str
withdraw_fee: str
withdraw_fee_usd: str
timestamp: str
hash: str
class intents.models.AnyInputWithdrawalsResponse(**data)[source]

Bases: BaseModel

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

model_config: ClassVar[ConfigDict] = {'alias_generator': <function to_camel>, 'populate_by_name': True, 'validate_by_alias': True, 'validate_by_name': True}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

asset: str
recipient: str
affiliate_recipient: str
withdrawals: AnyInputWithdrawal | None
class intents.models.SubmitDepositRequest(**data)[source]

Bases: BaseModel

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

model_config: ClassVar[ConfigDict] = {'alias_generator': <function to_camel>, 'populate_by_name': True, 'validate_by_alias': True, 'validate_by_name': True}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

tx_hash: str
deposit_address: str
near_sender_account: str | None
memo: str | None
to_api_dict()[source]
Return type:

dict

class intents.models.SubmitDepositResponse(**data)[source]

Bases: BaseModel

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

model_config: ClassVar[ConfigDict] = {'alias_generator': <function to_camel>, 'populate_by_name': True, 'validate_by_alias': True, 'validate_by_name': True}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

correlation_id: str
quote_response: QuoteResponse
status: SwapStatus
updated_at: datetime
swap_details: SwapDetails