Class: WhopSDK::Models::Payment::Plan

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/whop_sdk/models/payment.rb,
sig/whop_sdk/models/payment.rbs

Overview

See Also:

  • WhopSDK::Models::Payment#plan

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

#initializeObject



648
# File 'sig/whop_sdk/models/payment.rbs', line 648

def initialize: (

Instance Attribute Details

#idString

The unique identifier for the plan.

Parameters:

  • value (String)

Returns:

  • (String)


914
# File 'lib/whop_sdk/models/payment.rb', line 914

required :id, String

#internal_notesString?

A personal description or notes section for the business.

Parameters:

  • value (String, nil)

Returns:

  • (String, nil)


920
# File 'lib/whop_sdk/models/payment.rb', line 920

required :internal_notes, String, nil?: true

#metadataHash{Symbol=>Object}?

Custom key-value pairs stored on the plan. Included in webhook payloads for payment and membership events. Max 50 keys, 100 chars per key, 500 chars per string value.

Parameters:

  • value (::Hash[Symbol, top], nil)

Returns:

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


928
# File 'lib/whop_sdk/models/payment.rb', line 928

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

Instance Method Details

#to_hash{

Returns:

  • ({)


654
# File 'sig/whop_sdk/models/payment.rbs', line 654

def to_hash: -> {