Class: WhopSDK::Models::TransferCreateParams

Inherits:
Internal::Type::BaseModel show all
Extended by:
Internal::Type::RequestParameters::Converter
Includes:
Internal::Type::RequestParameters
Defined in:
lib/whop_sdk/models/transfer_create_params.rb

Overview

Instance Attribute Summary collapse

Attributes included from Internal::Type::RequestParameters

#request_options

Instance Method Summary collapse

Methods included from Internal::Type::RequestParameters::Converter

dump_request

Methods included from Internal::Type::RequestParameters

included

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:, currency:, destination_id:, origin_id:, idempotence_key: nil, metadata: nil, notes: nil, request_options: {}) ⇒ Object

Some parameter documentations has been truncated, see WhopSDK::Models::TransferCreateParams for more details.

Parameters:

  • amount (Float)

    The amount to transfer in the specified currency. For example, 25.00 for $25.00

  • currency (Symbol, WhopSDK::Models::Currency)

    The currency of the transfer amount, such as ‘usd’.

  • destination_id (String)

    The identifier of the account receiving the funds. Accepts a user ID (‘user_xxx’

  • origin_id (String)

    The identifier of the account sending the funds. Accepts a user ID (‘user_xxx’),

  • idempotence_key (String, nil) (defaults to: nil)

    A unique key to prevent duplicate transfers. Use a UUID or similar unique string

  • metadata (Hash{Symbol=>Object}, nil) (defaults to: nil)

    A JSON object of custom metadata to attach to the transfer for tracking purposes

  • notes (String, nil) (defaults to: nil)

    A short note describing the transfer, up to 50 characters.

  • request_options (WhopSDK::RequestOptions, Hash{Symbol=>Object}) (defaults to: {})


# File 'lib/whop_sdk/models/transfer_create_params.rb', line 57

Instance Attribute Details

#amountFloat

The amount to transfer in the specified currency. For example, 25.00 for $25.00 USD.

Returns:

  • (Float)


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

required :amount, Float

#currencySymbol, WhopSDK::Models::Currency

The currency of the transfer amount, such as ‘usd’.

Returns:



21
# File 'lib/whop_sdk/models/transfer_create_params.rb', line 21

required :currency, enum: -> { WhopSDK::Currency }

#destination_idString

The identifier of the account receiving the funds. Accepts a user ID (‘user_xxx’), company ID (‘biz_xxx’), or ledger account ID (‘ldgr_xxx’).

Returns:

  • (String)


28
# File 'lib/whop_sdk/models/transfer_create_params.rb', line 28

required :destination_id, String

#idempotence_keyString?

A unique key to prevent duplicate transfers. Use a UUID or similar unique string.

Returns:

  • (String, nil)


42
# File 'lib/whop_sdk/models/transfer_create_params.rb', line 42

optional :idempotence_key, String, nil?: true

#metadataHash{Symbol=>Object}?

A JSON object of custom metadata to attach to the transfer for tracking purposes.

Returns:

  • (Hash{Symbol=>Object}, nil)


49
# File 'lib/whop_sdk/models/transfer_create_params.rb', line 49

optional :metadata, WhopSDK::Internal::Type::HashOf[WhopSDK::Internal::Type::Unknown], nil?: true

#notesString?

A short note describing the transfer, up to 50 characters.

Returns:

  • (String, nil)


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

optional :notes, String, nil?: true

#origin_idString

The identifier of the account sending the funds. Accepts a user ID (‘user_xxx’), company ID (‘biz_xxx’), or ledger account ID (‘ldgr_xxx’).

Returns:

  • (String)


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

required :origin_id, String