Class: WhopSDK::Models::Affiliates::OverrideListResponse

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/whop_sdk/models/affiliates/override_list_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(id:, applies_to_payments:, applies_to_products:, checkout_direct_link:, commission_type:, commission_value:, override_type:, plan_id:, product_direct_link:, product_id:, revenue_basis:, total_referral_earnings_usd:) ⇒ Object

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

A commission configuration for an affiliate, defining payout terms for a specific plan or revenue share

Parameters:

  • id (String)

    The unique identifier for the affiliate override.

  • applies_to_payments (Symbol, WhopSDK::Models::Affiliates::AffiliateAppliesToPayments, nil)

    Whether the affiliate commission applies to the first payment or all payments

  • applies_to_products (Symbol, WhopSDK::Models::Affiliates::AffiliateAppliesToProducts, nil)

    Whether a rev-share override applies to a single product or all products

  • checkout_direct_link (String, nil)

    The checkout direct link for referrals (standard overrides only).

  • commission_type (Symbol, WhopSDK::Models::Affiliates::AffiliatePayoutTypes)

    The type of commission (percentage or flat_fee).

  • commission_value (Float)

    The commission amount. A percentage (1-100) when commission_type is percentage,

  • override_type (Symbol, WhopSDK::Models::Affiliates::AffiliateOverrideRoles)

    The type of override (standard or rev_share).

  • plan_id (String, nil)

    The plan ID (for standard overrides).

  • product_direct_link (String, nil)

    The product page direct link for referrals (standard overrides only).

  • product_id (String, nil)

    The product ID (for rev-share overrides).

  • revenue_basis (Symbol, WhopSDK::Models::Affiliates::AffiliateRevenueBases, nil)

    The calculation method for affiliate rev-share percentages

  • total_referral_earnings_usd (Float)

    The total earnings paid to this affiliate for referrals to this specific plan, i



# File 'lib/whop_sdk/models/affiliates/override_list_response.rb', line 90

Instance Attribute Details

#applies_to_paymentsSymbol, ...

Whether the affiliate commission applies to the first payment or all payments



18
19
20
21
22
# File 'lib/whop_sdk/models/affiliates/override_list_response.rb', line 18

required :applies_to_payments,
enum: -> {
  WhopSDK::Affiliates::AffiliateAppliesToPayments
},
nil?: true

#applies_to_productsSymbol, ...

Whether a rev-share override applies to a single product or all products



28
29
30
31
32
# File 'lib/whop_sdk/models/affiliates/override_list_response.rb', line 28

required :applies_to_products,
enum: -> {
  WhopSDK::Affiliates::AffiliateAppliesToProducts
},
nil?: true

The checkout direct link for referrals (standard overrides only).

Returns:

  • (String, nil)


38
# File 'lib/whop_sdk/models/affiliates/override_list_response.rb', line 38

required :checkout_direct_link, String, nil?: true

#commission_typeSymbol, WhopSDK::Models::Affiliates::AffiliatePayoutTypes

The type of commission (percentage or flat_fee).



44
# File 'lib/whop_sdk/models/affiliates/override_list_response.rb', line 44

required :commission_type, enum: -> { WhopSDK::Affiliates::AffiliatePayoutTypes }

#commission_valueFloat

The commission amount. A percentage (1-100) when commission_type is percentage, or a dollar amount when flat_fee.

Returns:

  • (Float)


51
# File 'lib/whop_sdk/models/affiliates/override_list_response.rb', line 51

required :commission_value, Float

#idString

The unique identifier for the affiliate override.

Returns:

  • (String)


12
# File 'lib/whop_sdk/models/affiliates/override_list_response.rb', line 12

required :id, String

#override_typeSymbol, WhopSDK::Models::Affiliates::AffiliateOverrideRoles

The type of override (standard or rev_share).



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

required :override_type, enum: -> { WhopSDK::Affiliates::AffiliateOverrideRoles }

#plan_idString?

The plan ID (for standard overrides).

Returns:

  • (String, nil)


63
# File 'lib/whop_sdk/models/affiliates/override_list_response.rb', line 63

required :plan_id, String, nil?: true

The product page direct link for referrals (standard overrides only).

Returns:

  • (String, nil)


69
# File 'lib/whop_sdk/models/affiliates/override_list_response.rb', line 69

required :product_direct_link, String, nil?: true

#product_idString?

The product ID (for rev-share overrides).

Returns:

  • (String, nil)


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

required :product_id, String, nil?: true

#revenue_basisSymbol, ...

The calculation method for affiliate rev-share percentages



81
# File 'lib/whop_sdk/models/affiliates/override_list_response.rb', line 81

required :revenue_basis, enum: -> { WhopSDK::Affiliates::AffiliateRevenueBases }, nil?: true

#total_referral_earnings_usdFloat

The total earnings paid to this affiliate for referrals to this specific plan, in USD.

Returns:

  • (Float)


88
# File 'lib/whop_sdk/models/affiliates/override_list_response.rb', line 88

required :total_referral_earnings_usd, Float