Class: Pago::V2026_04::Models::SubscriptionSeatsUpdatedMetadata
- Inherits:
-
Model
- Object
- Model
- Pago::V2026_04::Models::SubscriptionSeatsUpdatedMetadata
show all
- Defined in:
- lib/pago/v2026_04/models.rb,
sig/pago/v2026_04/generated.rbs
Constant Summary
collapse
- JSON_KEYS =
{
subscription_id: "subscription_id",
old_seats: "old_seats",
new_seats: "new_seats",
proration_behavior: "proration_behavior"
}.freeze
- REQUIRED_KEYS =
["subscription_id", "old_seats", "new_seats", "proration_behavior"].freeze
Instance Attribute Summary collapse
Class Method Summary
collapse
Instance Method Summary
collapse
Methods inherited from Model
#==, #[], #field_set?, #hash, #inspect, json_keys, required_json_keys, #to_json, #to_json_hash, wrap_raw
Constructor Details
#initialize(subscription_id:, old_seats:, new_seats:, proration_behavior:) ⇒ SubscriptionSeatsUpdatedMetadata
Returns a new instance of SubscriptionSeatsUpdatedMetadata.
42413
42414
42415
42416
42417
42418
42419
42420
42421
42422
42423
42424
|
# File 'lib/pago/v2026_04/models.rb', line 42413
def initialize(
subscription_id:,
old_seats:,
new_seats:,
proration_behavior:
)
super()
assign(:subscription_id, subscription_id)
assign(:old_seats, old_seats)
assign(:new_seats, new_seats)
assign(:proration_behavior, proration_behavior)
end
|
Instance Attribute Details
#new_seats ⇒ Integer
42408
42409
42410
|
# File 'lib/pago/v2026_04/models.rb', line 42408
def new_seats
@new_seats
end
|
#old_seats ⇒ Integer
42405
42406
42407
|
# File 'lib/pago/v2026_04/models.rb', line 42405
def old_seats
@old_seats
end
|
#proration_behavior ⇒ String
42411
42412
42413
|
# File 'lib/pago/v2026_04/models.rb', line 42411
def proration_behavior
@proration_behavior
end
|
#subscription_id ⇒ String
42402
42403
42404
|
# File 'lib/pago/v2026_04/models.rb', line 42402
def subscription_id
@subscription_id
end
|
Class Method Details
42428
42429
42430
42431
42432
42433
42434
42435
42436
42437
42438
42439
42440
42441
42442
|
# File 'lib/pago/v2026_04/models.rb', line 42428
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(
subscription_id: (data.key?("subscription_id") ? data["subscription_id"] : ::Pago::UNSET),
old_seats: (data.key?("old_seats") ? data["old_seats"] : ::Pago::UNSET),
new_seats: (data.key?("new_seats") ? data["new_seats"] : ::Pago::UNSET),
proration_behavior: (data.key?("proration_behavior") ? data["proration_behavior"] : ::Pago::UNSET)
),
data
)
end
|