Class: Dodopayments::Models::ProductEntitlementSummary

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

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:, integration_config:, integration_type:, name:, description: nil) ⇒ Object

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

Summary of an entitlement attached to a product.

‘integration_config` uses [`IntegrationConfigResponse`] (NOT the persisted [`IntegrationConfig`]) so digital_files entitlements embed the resolved `digital_files` object — matching what `GET /entitlements/#id` returns. All other variants pass through unchanged via `#[serde(untagged)]`.



# File 'lib/dodopayments/models/product_entitlement_summary.rb', line 35

Instance Attribute Details

#descriptionString?

Returns:

  • (String, nil)


33
# File 'lib/dodopayments/models/product_entitlement_summary.rb', line 33

optional :description, String, nil?: true

#idString

Returns:

  • (String)


9
# File 'lib/dodopayments/models/product_entitlement_summary.rb', line 9

required :id, String

#integration_configDodopayments::Models::IntegrationConfigResponse::GitHubConfig, ...

Public-facing variant of [‘IntegrationConfig`]. Mirrors every variant shape on the wire EXCEPT `DigitalFiles`, which is replaced with a hydrated `digital_files` object (resolved download URLs etc.). The persisted JSONB stays ID-only via [`IntegrationConfig`]; this enum is response-only.



18
# File 'lib/dodopayments/models/product_entitlement_summary.rb', line 18

required :integration_config, union: -> { Dodopayments::IntegrationConfigResponse }

#integration_typeSymbol, Dodopayments::Models::EntitlementIntegrationType



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

required :integration_type, enum: -> { Dodopayments::EntitlementIntegrationType }

#nameString

Returns:

  • (String)


28
# File 'lib/dodopayments/models/product_entitlement_summary.rb', line 28

required :name, String