Class: Pago::V2026_04::Models::CustomerOrganization
- Defined in:
- lib/pago/v2026_04/models.rb,
sig/pago/v2026_04/generated.rbs
Constant Summary collapse
- JSON_KEYS =
{ created_at: "created_at", modified_at: "modified_at", id: "id", name: "name", slug: "slug", avatar_url: "avatar_url", proration_behavior: "proration_behavior", allow_customer_updates: "allow_customer_updates", customer_portal_settings: "customer_portal_settings", organization_features: "organization_features" }.freeze
- REQUIRED_KEYS =
["created_at", "modified_at", "id", "name", "slug", "avatar_url", "proration_behavior", "allow_customer_updates", "customer_portal_settings"].freeze
Instance Attribute Summary collapse
-
#allow_customer_updates ⇒ Boolean
readonly
Whether customers can update their subscriptions from the customer portal.
-
#avatar_url ⇒ String?
readonly
Avatar URL shown in checkout, customer portal, emails etc.
-
#created_at ⇒ String
readonly
Creation timestamp of the object.
- #customer_portal_settings ⇒ Models::OrganizationCustomerPortalSettings readonly
-
#id ⇒ String
readonly
The ID of the object.
-
#modified_at ⇒ String?
readonly
Last modification timestamp of the object.
-
#name ⇒ String
readonly
Organization name shown in checkout, customer portal, emails etc.
- #organization_features ⇒ Models::CustomerOrganizationFeatureSettings readonly
- #proration_behavior ⇒ String readonly
-
#slug ⇒ String
readonly
Unique organization slug in checkout, customer portal and credit card statements.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(created_at:, modified_at:, id:, name:, slug:, avatar_url:, proration_behavior:, allow_customer_updates:, customer_portal_settings:, organization_features: ::Pago::UNSET) ⇒ CustomerOrganization
constructor
A new instance of CustomerOrganization.
Methods inherited from Model
#==, #[], #field_set?, #hash, #inspect, json_keys, required_json_keys, #to_json, #to_json_hash, wrap_raw
Constructor Details
#initialize(created_at:, modified_at:, id:, name:, slug:, avatar_url:, proration_behavior:, allow_customer_updates:, customer_portal_settings:, organization_features: ::Pago::UNSET) ⇒ CustomerOrganization
Returns a new instance of CustomerOrganization.
18310 18311 18312 18313 18314 18315 18316 18317 18318 18319 18320 18321 18322 18323 18324 18325 18326 18327 18328 18329 18330 18331 18332 18333 |
# File 'lib/pago/v2026_04/models.rb', line 18310 def initialize( created_at:, modified_at:, id:, name:, slug:, avatar_url:, proration_behavior:, allow_customer_updates:, customer_portal_settings:, organization_features: ::Pago::UNSET ) super() assign(:created_at, created_at) assign(:modified_at, modified_at) assign(:id, id) assign(:name, name) assign(:slug, slug) assign(:avatar_url, avatar_url) assign(:proration_behavior, proration_behavior) assign(:allow_customer_updates, allow_customer_updates) assign(:customer_portal_settings, customer_portal_settings) assign(:organization_features, organization_features) end |
Instance Attribute Details
#allow_customer_updates ⇒ Boolean (readonly)
Whether customers can update their subscriptions from the customer portal.
18302 18303 18304 |
# File 'lib/pago/v2026_04/models.rb', line 18302 def allow_customer_updates @allow_customer_updates end |
#avatar_url ⇒ String? (readonly)
Avatar URL shown in checkout, customer portal, emails etc.
18295 18296 18297 |
# File 'lib/pago/v2026_04/models.rb', line 18295 def avatar_url @avatar_url end |
#created_at ⇒ String (readonly)
Creation timestamp of the object.
18275 18276 18277 |
# File 'lib/pago/v2026_04/models.rb', line 18275 def created_at @created_at end |
#customer_portal_settings ⇒ Models::OrganizationCustomerPortalSettings (readonly)
18305 18306 18307 |
# File 'lib/pago/v2026_04/models.rb', line 18305 def customer_portal_settings @customer_portal_settings end |
#id ⇒ String (readonly)
The ID of the object.
18283 18284 18285 |
# File 'lib/pago/v2026_04/models.rb', line 18283 def id @id end |
#modified_at ⇒ String? (readonly)
Last modification timestamp of the object.
18279 18280 18281 |
# File 'lib/pago/v2026_04/models.rb', line 18279 def modified_at @modified_at end |
#name ⇒ String (readonly)
Organization name shown in checkout, customer portal, emails etc.
18287 18288 18289 |
# File 'lib/pago/v2026_04/models.rb', line 18287 def name @name end |
#organization_features ⇒ Models::CustomerOrganizationFeatureSettings (readonly)
18308 18309 18310 |
# File 'lib/pago/v2026_04/models.rb', line 18308 def organization_features @organization_features end |
#proration_behavior ⇒ String (readonly)
18298 18299 18300 |
# File 'lib/pago/v2026_04/models.rb', line 18298 def proration_behavior @proration_behavior end |
#slug ⇒ String (readonly)
Unique organization slug in checkout, customer portal and credit card statements.
18291 18292 18293 |
# File 'lib/pago/v2026_04/models.rb', line 18291 def slug @slug end |
Class Method Details
.from_json(data) ⇒ CustomerOrganization?
18337 18338 18339 18340 18341 18342 18343 18344 18345 18346 18347 18348 18349 18350 18351 18352 18353 18354 18355 18356 18357 |
# File 'lib/pago/v2026_04/models.rb', line 18337 def self.from_json(data) data = ::JSON.parse(data) if data.is_a?(String) data = ::Pago::Serde.object(data) return nil if data.nil? wrap_raw( new( created_at: (data.key?("created_at") ? data["created_at"] : ::Pago::UNSET), modified_at: (data.key?("modified_at") ? data["modified_at"] : ::Pago::UNSET), id: (data.key?("id") ? data["id"] : ::Pago::UNSET), name: (data.key?("name") ? data["name"] : ::Pago::UNSET), slug: (data.key?("slug") ? data["slug"] : ::Pago::UNSET), avatar_url: (data.key?("avatar_url") ? data["avatar_url"] : ::Pago::UNSET), proration_behavior: (data.key?("proration_behavior") ? data["proration_behavior"] : ::Pago::UNSET), allow_customer_updates: (data.key?("allow_customer_updates") ? data["allow_customer_updates"] : ::Pago::UNSET), customer_portal_settings: (data.key?("customer_portal_settings") ? Models::OrganizationCustomerPortalSettings.from_json(data["customer_portal_settings"]) : ::Pago::UNSET), organization_features: (data.key?("organization_features") ? Models::CustomerOrganizationFeatureSettings.from_json(data["organization_features"]) : ::Pago::UNSET) ), data ) end |