Class: Pago::V2026_04::Models::OAuth2ClientPublic

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])
{
  created_at: "created_at",
  modified_at: "modified_at",
  client_id: "client_id",
  client_name: "client_name",
  client_uri: "client_uri",
  logo_uri: "logo_uri",
  tos_uri: "tos_uri",
  policy_uri: "policy_uri"
}.freeze
REQUIRED_KEYS =

Returns:

  • (Array[String])
["created_at", "modified_at", "client_id", "client_name", "client_uri", "logo_uri", "tos_uri", "policy_uri"].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:, client_id:, client_name:, client_uri:, logo_uri:, tos_uri:, policy_uri:) ⇒ OAuth2ClientPublic

Returns a new instance of OAuth2ClientPublic.

Parameters:

  • created_at: (String)
  • modified_at: (String, nil)
  • client_id: (String)
  • client_name: (String, nil)
  • client_uri: (String, nil)
  • logo_uri: (String, nil)
  • tos_uri: (String, nil)
  • policy_uri: (String, nil)


31764
31765
31766
31767
31768
31769
31770
31771
31772
31773
31774
31775
31776
31777
31778
31779
31780
31781
31782
31783
# File 'lib/pago/v2026_04/models.rb', line 31764

def initialize(
  created_at:,
  modified_at:,
  client_id:,
  client_name:,
  client_uri:,
  logo_uri:,
  tos_uri:,
  policy_uri:
)
  super()
  assign(:created_at, created_at)
  assign(:modified_at, modified_at)
  assign(:client_id, client_id)
  assign(:client_name, client_name)
  assign(:client_uri, client_uri)
  assign(:logo_uri, logo_uri)
  assign(:tos_uri, tos_uri)
  assign(:policy_uri, policy_uri)
end

Instance Attribute Details

#client_idString (readonly)

Returns:

  • (String)


31747
31748
31749
# File 'lib/pago/v2026_04/models.rb', line 31747

def client_id
  @client_id
end

#client_nameString? (readonly)

Returns:

  • (String, nil)


31750
31751
31752
# File 'lib/pago/v2026_04/models.rb', line 31750

def client_name
  @client_name
end

#client_uriString? (readonly)

Returns:

  • (String, nil)


31753
31754
31755
# File 'lib/pago/v2026_04/models.rb', line 31753

def client_uri
  @client_uri
end

#created_atString (readonly)

Creation timestamp of the object.

Returns:

  • (String)


31740
31741
31742
# File 'lib/pago/v2026_04/models.rb', line 31740

def created_at
  @created_at
end

#logo_uriString? (readonly)

Returns:

  • (String, nil)


31756
31757
31758
# File 'lib/pago/v2026_04/models.rb', line 31756

def logo_uri
  @logo_uri
end

#modified_atString? (readonly)

Last modification timestamp of the object.

Returns:

  • (String, nil)


31744
31745
31746
# File 'lib/pago/v2026_04/models.rb', line 31744

def modified_at
  @modified_at
end

#policy_uriString? (readonly)

Returns:

  • (String, nil)


31762
31763
31764
# File 'lib/pago/v2026_04/models.rb', line 31762

def policy_uri
  @policy_uri
end

#tos_uriString? (readonly)

Returns:

  • (String, nil)


31759
31760
31761
# File 'lib/pago/v2026_04/models.rb', line 31759

def tos_uri
  @tos_uri
end

Class Method Details

.from_json(data) ⇒ OAuth2ClientPublic?

Parameters:

  • data (Hash, String, nil)

Returns:



31787
31788
31789
31790
31791
31792
31793
31794
31795
31796
31797
31798
31799
31800
31801
31802
31803
31804
31805
# File 'lib/pago/v2026_04/models.rb', line 31787

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),
      client_id: (data.key?("client_id") ? data["client_id"] : ::Pago::UNSET),
      client_name: (data.key?("client_name") ? data["client_name"] : ::Pago::UNSET),
      client_uri: (data.key?("client_uri") ? data["client_uri"] : ::Pago::UNSET),
      logo_uri: (data.key?("logo_uri") ? data["logo_uri"] : ::Pago::UNSET),
      tos_uri: (data.key?("tos_uri") ? data["tos_uri"] : ::Pago::UNSET),
      policy_uri: (data.key?("policy_uri") ? data["policy_uri"] : ::Pago::UNSET)
    ),
    data
  )
end