Class: Pago::V2026_04::Models::SeatClaimInfo

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

Overview

Read-only information about a seat claim invitation. Safe for email scanners - no side effects when fetched.

Constant Summary collapse

JSON_KEYS =

Returns:

  • (Hash[Symbol, String])
{
  product_name: "product_name",
  product_id: "product_id",
  organization_name: "organization_name",
  organization_slug: "organization_slug",
  customer_email: "customer_email",
  can_claim: "can_claim"
}.freeze
REQUIRED_KEYS =

Returns:

  • (Array[String])
["product_name", "product_id", "organization_name", "organization_slug", "customer_email", "can_claim"].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(product_name:, product_id:, organization_name:, organization_slug:, customer_email:, can_claim:) ⇒ SeatClaimInfo

Returns a new instance of SeatClaimInfo.

Parameters:

  • product_name: (String)
  • product_id: (String)
  • organization_name: (String)
  • organization_slug: (String)
  • customer_email: (String)
  • can_claim: (Boolean)


39156
39157
39158
39159
39160
39161
39162
39163
39164
39165
39166
39167
39168
39169
39170
39171
# File 'lib/pago/v2026_04/models.rb', line 39156

def initialize(
  product_name:,
  product_id:,
  organization_name:,
  organization_slug:,
  customer_email:,
  can_claim:
)
  super()
  assign(:product_name, product_name)
  assign(:product_id, product_id)
  assign(:organization_name, organization_name)
  assign(:organization_slug, organization_slug)
  assign(:customer_email, customer_email)
  assign(:can_claim, can_claim)
end

Instance Attribute Details

#can_claimBoolean (readonly)

Whether the seat can be claimed

Returns:

  • (Boolean)


39154
39155
39156
# File 'lib/pago/v2026_04/models.rb', line 39154

def can_claim
  @can_claim
end

#customer_emailString (readonly)

Email of the customer assigned to this seat

Returns:

  • (String)


39150
39151
39152
# File 'lib/pago/v2026_04/models.rb', line 39150

def customer_email
  @customer_email
end

#organization_nameString (readonly)

Name of the organization

Returns:

  • (String)


39142
39143
39144
# File 'lib/pago/v2026_04/models.rb', line 39142

def organization_name
  @organization_name
end

#organization_slugString (readonly)

Slug of the organization

Returns:

  • (String)


39146
39147
39148
# File 'lib/pago/v2026_04/models.rb', line 39146

def organization_slug
  @organization_slug
end

#product_idString (readonly)

ID of the product

Returns:

  • (String)


39138
39139
39140
# File 'lib/pago/v2026_04/models.rb', line 39138

def product_id
  @product_id
end

#product_nameString (readonly)

Name of the product

Returns:

  • (String)


39134
39135
39136
# File 'lib/pago/v2026_04/models.rb', line 39134

def product_name
  @product_name
end

Class Method Details

.from_json(data) ⇒ SeatClaimInfo?

Parameters:

  • data (Hash, String, nil)

Returns:



39175
39176
39177
39178
39179
39180
39181
39182
39183
39184
39185
39186
39187
39188
39189
39190
39191
# File 'lib/pago/v2026_04/models.rb', line 39175

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(
      product_name: (data.key?("product_name") ? data["product_name"] : ::Pago::UNSET),
      product_id: (data.key?("product_id") ? data["product_id"] : ::Pago::UNSET),
      organization_name: (data.key?("organization_name") ? data["organization_name"] : ::Pago::UNSET),
      organization_slug: (data.key?("organization_slug") ? data["organization_slug"] : ::Pago::UNSET),
      customer_email: (data.key?("customer_email") ? data["customer_email"] : ::Pago::UNSET),
      can_claim: (data.key?("can_claim") ? data["can_claim"] : ::Pago::UNSET)
    ),
    data
  )
end