Class: Pago::V2026_04::Models::CustomerSubscriptionResume

Inherits:
Model
  • Object
show all
Defined in:
lib/pago/v2026_04/models.rb,
sig/pago/v2026_04/generated.rbs

Constant Summary collapse

JSON_KEYS =

Returns:

  • (Hash[Symbol, String])
{
  resume: "resume"
}.freeze
REQUIRED_KEYS =

Returns:

  • (Array[String])
["resume"].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(resume:) ⇒ CustomerSubscriptionResume

Returns a new instance of CustomerSubscriptionResume.

Parameters:

  • resume: (Boolean)


21449
21450
21451
21452
21453
21454
# File 'lib/pago/v2026_04/models.rb', line 21449

def initialize(
  resume:
)
  super()
  assign(:resume, resume)
end

Instance Attribute Details

#resumeBoolean (readonly)

Resume a paused subscription immediately, starting a new billing period and charging the customer.

Returns:

  • (Boolean)


21447
21448
21449
# File 'lib/pago/v2026_04/models.rb', line 21447

def resume
  @resume
end

Class Method Details

.from_json(data) ⇒ CustomerSubscriptionResume?

Parameters:

  • data (Hash, String, nil)

Returns:



21458
21459
21460
21461
21462
21463
21464
21465
21466
21467
21468
21469
# File 'lib/pago/v2026_04/models.rb', line 21458

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(
      resume: (data.key?("resume") ? data["resume"] : ::Pago::UNSET)
    ),
    data
  )
end