Class: Pago::V2026_04::Models::OAuth2ClientConfiguration

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])
{
  redirect_uris: "redirect_uris",
  token_endpoint_auth_method: "token_endpoint_auth_method",
  grant_types: "grant_types",
  response_types: "response_types",
  scope: "scope",
  client_name: "client_name",
  client_uri: "client_uri",
  logo_uri: "logo_uri",
  tos_uri: "tos_uri",
  policy_uri: "policy_uri",
  default_sub_type: "default_sub_type"
}.freeze
REQUIRED_KEYS =

Returns:

  • (Array[String])
["redirect_uris", "client_name"].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(redirect_uris:, token_endpoint_auth_method: ::Pago::UNSET, grant_types: ::Pago::UNSET, response_types: ::Pago::UNSET, scope: ::Pago::UNSET, client_name:, client_uri: ::Pago::UNSET, logo_uri: ::Pago::UNSET, tos_uri: ::Pago::UNSET, policy_uri: ::Pago::UNSET, default_sub_type: ::Pago::UNSET) ⇒ OAuth2ClientConfiguration

Returns a new instance of OAuth2ClientConfiguration.

Parameters:

  • redirect_uris: (Array[String])
  • token_endpoint_auth_method: (String, nil) (defaults to: ::Pago::UNSET)
  • grant_types: (Array[untyped], nil) (defaults to: ::Pago::UNSET)
  • response_types: (Array[String], nil) (defaults to: ::Pago::UNSET)
  • scope: (String, nil) (defaults to: ::Pago::UNSET)
  • client_name: (String)
  • client_uri: (String, nil) (defaults to: ::Pago::UNSET)
  • logo_uri: (String, nil) (defaults to: ::Pago::UNSET)
  • tos_uri: (String, nil) (defaults to: ::Pago::UNSET)
  • policy_uri: (String, nil) (defaults to: ::Pago::UNSET)
  • default_sub_type: (String, nil) (defaults to: ::Pago::UNSET)


31563
31564
31565
31566
31567
31568
31569
31570
31571
31572
31573
31574
31575
31576
31577
31578
31579
31580
31581
31582
31583
31584
31585
31586
31587
31588
# File 'lib/pago/v2026_04/models.rb', line 31563

def initialize(
  redirect_uris:,
  token_endpoint_auth_method: ::Pago::UNSET,
  grant_types: ::Pago::UNSET,
  response_types: ::Pago::UNSET,
  scope: ::Pago::UNSET,
  client_name:,
  client_uri: ::Pago::UNSET,
  logo_uri: ::Pago::UNSET,
  tos_uri: ::Pago::UNSET,
  policy_uri: ::Pago::UNSET,
  default_sub_type: ::Pago::UNSET
)
  super()
  assign(:redirect_uris, redirect_uris)
  assign(:token_endpoint_auth_method, token_endpoint_auth_method)
  assign(:grant_types, grant_types)
  assign(:response_types, response_types)
  assign(:scope, scope)
  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)
  assign(:default_sub_type, default_sub_type)
end

Instance Attribute Details

#client_nameString (readonly)

Returns:

  • (String)


31546
31547
31548
# File 'lib/pago/v2026_04/models.rb', line 31546

def client_name
  @client_name
end

#client_uriString? (readonly)

Returns:

  • (String, nil)


31549
31550
31551
# File 'lib/pago/v2026_04/models.rb', line 31549

def client_uri
  @client_uri
end

#default_sub_typeString (readonly)

Returns:

  • (String)


31561
31562
31563
# File 'lib/pago/v2026_04/models.rb', line 31561

def default_sub_type
  @default_sub_type
end

#grant_typesArray<String> (readonly)

Returns:

  • (Array<String>)


31537
31538
31539
# File 'lib/pago/v2026_04/models.rb', line 31537

def grant_types
  @grant_types
end

#logo_uriString? (readonly)

Returns:

  • (String, nil)


31552
31553
31554
# File 'lib/pago/v2026_04/models.rb', line 31552

def logo_uri
  @logo_uri
end

#policy_uriString? (readonly)

Returns:

  • (String, nil)


31558
31559
31560
# File 'lib/pago/v2026_04/models.rb', line 31558

def policy_uri
  @policy_uri
end

#redirect_urisArray<String> (readonly)

Returns:

  • (Array<String>)


31531
31532
31533
# File 'lib/pago/v2026_04/models.rb', line 31531

def redirect_uris
  @redirect_uris
end

#response_typesArray<String> (readonly)

Returns:

  • (Array<String>)


31540
31541
31542
# File 'lib/pago/v2026_04/models.rb', line 31540

def response_types
  @response_types
end

#scopeString (readonly)

Returns:

  • (String)


31543
31544
31545
# File 'lib/pago/v2026_04/models.rb', line 31543

def scope
  @scope
end

#token_endpoint_auth_methodString (readonly)

Returns:

  • (String)


31534
31535
31536
# File 'lib/pago/v2026_04/models.rb', line 31534

def token_endpoint_auth_method
  @token_endpoint_auth_method
end

#tos_uriString? (readonly)

Returns:

  • (String, nil)


31555
31556
31557
# File 'lib/pago/v2026_04/models.rb', line 31555

def tos_uri
  @tos_uri
end

Class Method Details

.from_json(data) ⇒ OAuth2ClientConfiguration?

Parameters:

  • data (Hash, String, nil)

Returns:



31592
31593
31594
31595
31596
31597
31598
31599
31600
31601
31602
31603
31604
31605
31606
31607
31608
31609
31610
31611
31612
31613
# File 'lib/pago/v2026_04/models.rb', line 31592

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(
      redirect_uris: (data.key?("redirect_uris") ? data["redirect_uris"] : ::Pago::UNSET),
      token_endpoint_auth_method: (data.key?("token_endpoint_auth_method") ? data["token_endpoint_auth_method"] : ::Pago::UNSET),
      grant_types: (data.key?("grant_types") ? data["grant_types"] : ::Pago::UNSET),
      response_types: (data.key?("response_types") ? data["response_types"] : ::Pago::UNSET),
      scope: (data.key?("scope") ? data["scope"] : ::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),
      default_sub_type: (data.key?("default_sub_type") ? data["default_sub_type"] : ::Pago::UNSET)
    ),
    data
  )
end