Class: WhopSDK::Models::SwapCreateParams
- Inherits:
-
Internal::Type::BaseModel
- Object
- Internal::Type::BaseModel
- WhopSDK::Models::SwapCreateParams
- Extended by:
- Internal::Type::RequestParameters::Converter
- Includes:
- Internal::Type::RequestParameters
- Defined in:
- lib/whop_sdk/models/swap_create_params.rb,
sig/whop_sdk/models/swap_create_params.rbs
Overview
Defined Under Namespace
Instance Attribute Summary collapse
-
#account_id ⇒ String
Business or user account ID (biz* / user*).
-
#amount ⇒ String
Source token amount.
-
#from_chain ⇒ String, ...
Source chain name or chain ID.
-
#from_token ⇒ String
Source token contract address or ticker symbol, such as "USDT".
-
#slippage_bps ⇒ Integer?
Maximum slippage tolerance in basis points.
-
#to_chain ⇒ String, ...
Destination chain name or chain ID.
-
#to_token ⇒ String
Destination token contract address or ticker symbol, such as "XAUT".
Attributes included from Internal::Type::RequestParameters
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(account_id:, amount:, from_token:, to_token:, from_chain: nil, slippage_bps: nil, to_chain: nil, request_options: {}) ⇒ Object
constructor
Some parameter documentations has been truncated, see SwapCreateParams for more details.
- #to_hash ⇒ {
Methods included from Internal::Type::RequestParameters::Converter
Methods included from Internal::Type::RequestParameters
Methods inherited from Internal::Type::BaseModel
==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml
Methods included from Internal::Type::Converter
#coerce, coerce, #dump, dump, #inspect, inspect, meta_info, new_coerce_state, type_info
Methods included from Internal::Util::SorbetRuntimeSupport
#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type
Constructor Details
#initialize(account_id:, amount:, from_token:, to_token:, from_chain: nil, slippage_bps: nil, to_chain: nil, request_options: {}) ⇒ Object
Some parameter documentations has been truncated, see WhopSDK::Models::SwapCreateParams for more details.
|
|
# File 'lib/whop_sdk/models/swap_create_params.rb', line 54
|
Instance Attribute Details
#account_id ⇒ String
Business or user account ID (biz* / user*).
14 |
# File 'lib/whop_sdk/models/swap_create_params.rb', line 14 required :account_id, String |
#amount ⇒ String
Source token amount.
20 |
# File 'lib/whop_sdk/models/swap_create_params.rb', line 20 required :amount, String |
#from_chain ⇒ String, ...
Source chain name or chain ID. Defaults to the source token's chain when omitted.
39 |
# File 'lib/whop_sdk/models/swap_create_params.rb', line 39 optional :from_chain, union: -> { WhopSDK::SwapCreateParams::FromChain }, nil?: true |
#from_token ⇒ String
Source token contract address or ticker symbol, such as "USDT".
26 |
# File 'lib/whop_sdk/models/swap_create_params.rb', line 26 required :from_token, String |
#slippage_bps ⇒ Integer?
Maximum slippage tolerance in basis points.
45 |
# File 'lib/whop_sdk/models/swap_create_params.rb', line 45 optional :slippage_bps, Integer, nil?: true |
#to_chain ⇒ String, ...
Destination chain name or chain ID. Defaults to the destination token's chain when omitted.
52 |
# File 'lib/whop_sdk/models/swap_create_params.rb', line 52 optional :to_chain, union: -> { WhopSDK::SwapCreateParams::ToChain }, nil?: true |
#to_token ⇒ String
Destination token contract address or ticker symbol, such as "XAUT".
32 |
# File 'lib/whop_sdk/models/swap_create_params.rb', line 32 required :to_token, String |
Class Method Details
.variants ⇒ Array(String, Integer)
|
|
# File 'lib/whop_sdk/models/swap_create_params.rb', line 83
|
Instance Method Details
#to_hash ⇒ {
44 |
# File 'sig/whop_sdk/models/swap_create_params.rbs', line 44
def to_hash: -> {
|