Class: Dodopayments::Models::SubscriptionCreateResponse

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/dodopayments/models/subscription_create_response.rb

Overview

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(addons: , customer: , metadata: , payment_id: , recurring_pre_tax_amount: , subscription_id: , client_secret: nil, discount_id: nil, expires_on: nil, payment_link: nil) ⇒ Object

Some parameter documentations has been truncated, see Dodopayments::Models::SubscriptionCreateResponse for more details.

Parameters:

  • addons (Array<Dodopayments::Models::AddonCartResponseItem>) (defaults to: )

    Addons associated with this subscription

  • customer (Dodopayments::Models::CustomerLimitedDetails) (defaults to: )

    Customer details associated with this subscription

  • metadata (Hash{Symbol=>String}) (defaults to: )

    Additional metadata associated with the subscription

  • payment_id (String) (defaults to: )

    First payment id for the subscription

  • recurring_pre_tax_amount (Integer) (defaults to: )

    Tax will be added to the amount and charged to the customer on each billing cycl

  • subscription_id (String) (defaults to: )

    Unique identifier for the subscription

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

    Client secret used to load Dodo checkout SDK

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

    The discount id if discount is applied

  • expires_on (Time, nil) (defaults to: nil)

    Expiry timestamp of the payment link

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

    URL to checkout page



# File 'lib/dodopayments/models/subscription_create_response.rb', line 69

Instance Attribute Details

#addonsArray<Dodopayments::Models::AddonCartResponseItem>

Addons associated with this subscription



11
# File 'lib/dodopayments/models/subscription_create_response.rb', line 11

required :addons, -> { Dodopayments::Internal::Type::ArrayOf[Dodopayments::AddonCartResponseItem] }

#client_secretString?

Client secret used to load Dodo checkout SDK NOTE : Dodo checkout SDK will be coming soon

Returns:

  • (String, nil)


49
# File 'lib/dodopayments/models/subscription_create_response.rb', line 49

optional :client_secret, String, nil?: true

#customerDodopayments::Models::CustomerLimitedDetails

Customer details associated with this subscription



17
# File 'lib/dodopayments/models/subscription_create_response.rb', line 17

required :customer, -> { Dodopayments::CustomerLimitedDetails }

#discount_idString?

The discount id if discount is applied

Returns:

  • (String, nil)


55
# File 'lib/dodopayments/models/subscription_create_response.rb', line 55

optional :discount_id, String, nil?: true

#expires_onTime?

Expiry timestamp of the payment link

Returns:

  • (Time, nil)


61
# File 'lib/dodopayments/models/subscription_create_response.rb', line 61

optional :expires_on, Time, nil?: true

#metadataHash{Symbol=>String}

Additional metadata associated with the subscription

Returns:

  • (Hash{Symbol=>String})


23
# File 'lib/dodopayments/models/subscription_create_response.rb', line 23

required :metadata, Dodopayments::Internal::Type::HashOf[String]

#payment_idString

First payment id for the subscription

Returns:

  • (String)


29
# File 'lib/dodopayments/models/subscription_create_response.rb', line 29

required :payment_id, String

URL to checkout page

Returns:

  • (String, nil)


67
# File 'lib/dodopayments/models/subscription_create_response.rb', line 67

optional :payment_link, String, nil?: true

#recurring_pre_tax_amountInteger

Tax will be added to the amount and charged to the customer on each billing cycle

Returns:

  • (Integer)


36
# File 'lib/dodopayments/models/subscription_create_response.rb', line 36

required :recurring_pre_tax_amount, Integer

#subscription_idString

Unique identifier for the subscription

Returns:

  • (String)


42
# File 'lib/dodopayments/models/subscription_create_response.rb', line 42

required :subscription_id, String