Class: WhopSDK::Models::SwapCreateQuoteResponse

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/whop_sdk/models/swap_create_quote_response.rb

Overview

Defined Under Namespace

Modules: Object

Instance Attribute Summary collapse

Instance Method Summary collapse

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(amount_in:, amount_out:, fee_bps:, from_token:, metadata:, object:, rate:, to_token:, amount_out_min: nil, bridge_fee: nil, estimated_duration_seconds: nil, from_address: nil, requires_token_approval: nil, to_address: nil) ⇒ Object

Parameters:

  • amount_in (String)
  • amount_out (String)
  • fee_bps (Integer)
  • from_token (Hash{Symbol=>Object})
  • metadata (Hash{Symbol=>Object})
  • object (Symbol, WhopSDK::Models::SwapCreateQuoteResponse::Object)
  • rate (String)
  • to_token (Hash{Symbol=>Object})
  • amount_out_min (String) (defaults to: nil)
  • bridge_fee (String, nil) (defaults to: nil)
  • estimated_duration_seconds (Integer, nil) (defaults to: nil)
  • from_address (String, nil) (defaults to: nil)
  • requires_token_approval (Boolean, nil) (defaults to: nil)
  • to_address (String, nil) (defaults to: nil)


# File 'lib/whop_sdk/models/swap_create_quote_response.rb', line 77

Instance Attribute Details

#amount_inString

Returns:

  • (String)


10
# File 'lib/whop_sdk/models/swap_create_quote_response.rb', line 10

required :amount_in, String

#amount_outString

Returns:

  • (String)


15
# File 'lib/whop_sdk/models/swap_create_quote_response.rb', line 15

required :amount_out, String

#amount_out_minString?

Returns:

  • (String, nil)


50
# File 'lib/whop_sdk/models/swap_create_quote_response.rb', line 50

optional :amount_out_min, String

#bridge_feeString?

Returns:

  • (String, nil)


55
# File 'lib/whop_sdk/models/swap_create_quote_response.rb', line 55

optional :bridge_fee, String, nil?: true

#estimated_duration_secondsInteger?

Returns:

  • (Integer, nil)


60
# File 'lib/whop_sdk/models/swap_create_quote_response.rb', line 60

optional :estimated_duration_seconds, Integer, nil?: true

#fee_bpsInteger

Returns:

  • (Integer)


20
# File 'lib/whop_sdk/models/swap_create_quote_response.rb', line 20

required :fee_bps, Integer

#from_addressString?

Returns:

  • (String, nil)


65
# File 'lib/whop_sdk/models/swap_create_quote_response.rb', line 65

optional :from_address, String, nil?: true

#from_tokenHash{Symbol=>Object}

Returns:



25
# File 'lib/whop_sdk/models/swap_create_quote_response.rb', line 25

required :from_token, WhopSDK::Internal::Type::HashOf[WhopSDK::Internal::Type::Unknown]

#metadataHash{Symbol=>Object}

Returns:



30
# File 'lib/whop_sdk/models/swap_create_quote_response.rb', line 30

required :metadata, WhopSDK::Internal::Type::HashOf[WhopSDK::Internal::Type::Unknown]

#objectSymbol, WhopSDK::Models::SwapCreateQuoteResponse::Object



35
# File 'lib/whop_sdk/models/swap_create_quote_response.rb', line 35

required :object, enum: -> { WhopSDK::Models::SwapCreateQuoteResponse::Object }

#rateString

Returns:

  • (String)


40
# File 'lib/whop_sdk/models/swap_create_quote_response.rb', line 40

required :rate, String

#requires_token_approvalBoolean?

Returns:

  • (Boolean, nil)


70
# File 'lib/whop_sdk/models/swap_create_quote_response.rb', line 70

optional :requires_token_approval, WhopSDK::Internal::Type::Boolean, nil?: true

#to_addressString?

Returns:

  • (String, nil)


75
# File 'lib/whop_sdk/models/swap_create_quote_response.rb', line 75

optional :to_address, String, nil?: true

#to_tokenHash{Symbol=>Object}

Returns:



45
# File 'lib/whop_sdk/models/swap_create_quote_response.rb', line 45

required :to_token, WhopSDK::Internal::Type::HashOf[WhopSDK::Internal::Type::Unknown]