Class: Privy::Models::WalletActionSwapCreatedWebhookPayload

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/privy/models/wallet_action_swap_created_webhook_payload.rb

Defined Under Namespace

Modules: Status, Type

Instance Attribute Summary collapse

Class Method 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(action_type:, caip2:, input_amount:, input_token:, output_token:, status:, type:, wallet_action_id:, wallet_id:) ⇒ Object

Payload for the wallet_action.swap.created webhook event.

Parameters:



# File 'lib/privy/models/wallet_action_swap_created_webhook_payload.rb', line 60

Instance Attribute Details

#action_typeSymbol, Privy::Models::WalletActionType

Type of wallet action

Returns:



10
# File 'lib/privy/models/wallet_action_swap_created_webhook_payload.rb', line 10

required :action_type, enum: -> { Privy::WalletActionType }

#caip2String

Chain identifier.

Returns:

  • (String)


16
# File 'lib/privy/models/wallet_action_swap_created_webhook_payload.rb', line 16

required :caip2, String

#input_amountString?

Amount of input token in base units. Populated after on-chain confirmation.

Returns:

  • (String, nil)


22
# File 'lib/privy/models/wallet_action_swap_created_webhook_payload.rb', line 22

required :input_amount, String, nil?: true

#input_tokenString

Token address being sold.

Returns:

  • (String)


28
# File 'lib/privy/models/wallet_action_swap_created_webhook_payload.rb', line 28

required :input_token, String

#output_tokenString

Token address being bought.

Returns:

  • (String)


34
# File 'lib/privy/models/wallet_action_swap_created_webhook_payload.rb', line 34

required :output_token, String

#statusSymbol, Privy::Models::WalletActionSwapCreatedWebhookPayload::Status

The status of the wallet action.



40
# File 'lib/privy/models/wallet_action_swap_created_webhook_payload.rb', line 40

required :status, enum: -> { Privy::WalletActionSwapCreatedWebhookPayload::Status }

#typeSymbol, Privy::Models::WalletActionSwapCreatedWebhookPayload::Type

The type of webhook event.



46
# File 'lib/privy/models/wallet_action_swap_created_webhook_payload.rb', line 46

required :type, enum: -> { Privy::WalletActionSwapCreatedWebhookPayload::Type }

#wallet_action_idString

The ID of the wallet action.

Returns:

  • (String)


52
# File 'lib/privy/models/wallet_action_swap_created_webhook_payload.rb', line 52

required :wallet_action_id, String

#wallet_idString

The ID of the wallet involved in the action.

Returns:

  • (String)


58
# File 'lib/privy/models/wallet_action_swap_created_webhook_payload.rb', line 58

required :wallet_id, String

Class Method Details

.valuesArray<Symbol>

Returns:

  • (Array<Symbol>)


# File 'lib/privy/models/wallet_action_swap_created_webhook_payload.rb', line 89