Class: Pago::V2026_04::Models::CustomerPortalMember

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

Overview

A member of the customer's team as seen in the customer portal.

Constant Summary collapse

JSON_KEYS =

Returns:

  • (Hash[Symbol, String])
{
  created_at: "created_at",
  modified_at: "modified_at",
  id: "id",
  email: "email",
  name: "name",
  role: "role"
}.freeze
REQUIRED_KEYS =

Returns:

  • (Array[String])
["created_at", "modified_at", "id", "email", "name", "role"].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(created_at:, modified_at:, id:, email:, name:, role:) ⇒ CustomerPortalMember

Returns a new instance of CustomerPortalMember.

Parameters:

  • created_at: (String)
  • modified_at: (String, nil)
  • id: (String)
  • email: (String)
  • name: (String, nil)
  • role: (String)


19007
19008
19009
19010
19011
19012
19013
19014
19015
19016
19017
19018
19019
19020
19021
19022
# File 'lib/pago/v2026_04/models.rb', line 19007

def initialize(
  created_at:,
  modified_at:,
  id:,
  email:,
  name:,
  role:
)
  super()
  assign(:created_at, created_at)
  assign(:modified_at, modified_at)
  assign(:id, id)
  assign(:email, email)
  assign(:name, name)
  assign(:role, role)
end

Instance Attribute Details

#created_atString (readonly)

Creation timestamp of the object.

Returns:

  • (String)


18986
18987
18988
# File 'lib/pago/v2026_04/models.rb', line 18986

def created_at
  @created_at
end

#emailString (readonly)

The email address of the member.

Returns:

  • (String)


18998
18999
19000
# File 'lib/pago/v2026_04/models.rb', line 18998

def email
  @email
end

#idString (readonly)

The ID of the object.

Returns:

  • (String)


18994
18995
18996
# File 'lib/pago/v2026_04/models.rb', line 18994

def id
  @id
end

#modified_atString? (readonly)

Last modification timestamp of the object.

Returns:

  • (String, nil)


18990
18991
18992
# File 'lib/pago/v2026_04/models.rb', line 18990

def modified_at
  @modified_at
end

#nameString? (readonly)

The name of the member.

Returns:

  • (String, nil)


19002
19003
19004
# File 'lib/pago/v2026_04/models.rb', line 19002

def name
  @name
end

#roleString (readonly)

Returns:

  • (String)


19005
19006
19007
# File 'lib/pago/v2026_04/models.rb', line 19005

def role
  @role
end

Class Method Details

.from_json(data) ⇒ CustomerPortalMember?

Parameters:

  • data (Hash, String, nil)

Returns:



19026
19027
19028
19029
19030
19031
19032
19033
19034
19035
19036
19037
19038
19039
19040
19041
19042
# File 'lib/pago/v2026_04/models.rb', line 19026

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