Class: Supabase::Auth::Types::OAuthClient

Inherits:
Struct
  • Object
show all
Defined in:
lib/supabase/auth/types.rb

Overview

OAuth 2.1 server: client object returned by admin OAuth endpoints.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Attribute Details

#client_idObject

Returns the value of attribute client_id

Returns:

  • (Object)

    the current value of client_id



441
442
443
# File 'lib/supabase/auth/types.rb', line 441

def client_id
  @client_id
end

#client_nameObject

Returns the value of attribute client_name

Returns:

  • (Object)

    the current value of client_name



441
442
443
# File 'lib/supabase/auth/types.rb', line 441

def client_name
  @client_name
end

#client_secretObject

Returns the value of attribute client_secret

Returns:

  • (Object)

    the current value of client_secret



441
442
443
# File 'lib/supabase/auth/types.rb', line 441

def client_secret
  @client_secret
end

#client_typeObject

Returns the value of attribute client_type

Returns:

  • (Object)

    the current value of client_type



441
442
443
# File 'lib/supabase/auth/types.rb', line 441

def client_type
  @client_type
end

#client_uriObject

Returns the value of attribute client_uri

Returns:

  • (Object)

    the current value of client_uri



441
442
443
# File 'lib/supabase/auth/types.rb', line 441

def client_uri
  @client_uri
end

#created_atObject

Returns the value of attribute created_at

Returns:

  • (Object)

    the current value of created_at



441
442
443
# File 'lib/supabase/auth/types.rb', line 441

def created_at
  @created_at
end

#grant_typesObject

Returns the value of attribute grant_types

Returns:

  • (Object)

    the current value of grant_types



441
442
443
# File 'lib/supabase/auth/types.rb', line 441

def grant_types
  @grant_types
end

#logo_uriObject

Returns the value of attribute logo_uri

Returns:

  • (Object)

    the current value of logo_uri



441
442
443
# File 'lib/supabase/auth/types.rb', line 441

def logo_uri
  @logo_uri
end

#redirect_urisObject

Returns the value of attribute redirect_uris

Returns:

  • (Object)

    the current value of redirect_uris



441
442
443
# File 'lib/supabase/auth/types.rb', line 441

def redirect_uris
  @redirect_uris
end

#registration_typeObject

Returns the value of attribute registration_type

Returns:

  • (Object)

    the current value of registration_type



441
442
443
# File 'lib/supabase/auth/types.rb', line 441

def registration_type
  @registration_type
end

#response_typesObject

Returns the value of attribute response_types

Returns:

  • (Object)

    the current value of response_types



441
442
443
# File 'lib/supabase/auth/types.rb', line 441

def response_types
  @response_types
end

#scopeObject

Returns the value of attribute scope

Returns:

  • (Object)

    the current value of scope



441
442
443
# File 'lib/supabase/auth/types.rb', line 441

def scope
  @scope
end

#token_endpoint_auth_methodObject

Returns the value of attribute token_endpoint_auth_method

Returns:

  • (Object)

    the current value of token_endpoint_auth_method



441
442
443
# File 'lib/supabase/auth/types.rb', line 441

def token_endpoint_auth_method
  @token_endpoint_auth_method
end

#updated_atObject

Returns the value of attribute updated_at

Returns:

  • (Object)

    the current value of updated_at



441
442
443
# File 'lib/supabase/auth/types.rb', line 441

def updated_at
  @updated_at
end

Class Method Details

.from_hash(hash) ⇒ Object



458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
# File 'lib/supabase/auth/types.rb', line 458

def self.from_hash(hash)
  return nil if hash.nil?

  new(
    client_id: hash["client_id"] || hash[:client_id],
    client_name: hash["client_name"] || hash[:client_name],
    client_secret: hash["client_secret"] || hash[:client_secret],
    client_type: hash["client_type"] || hash[:client_type],
    token_endpoint_auth_method: hash["token_endpoint_auth_method"] || hash[:token_endpoint_auth_method],
    registration_type: hash["registration_type"] || hash[:registration_type],
    client_uri: hash["client_uri"] || hash[:client_uri],
    logo_uri: hash["logo_uri"] || hash[:logo_uri],
    redirect_uris: hash["redirect_uris"] || hash[:redirect_uris] || [],
    grant_types: hash["grant_types"] || hash[:grant_types] || [],
    response_types: hash["response_types"] || hash[:response_types] || [],
    scope: hash["scope"] || hash[:scope],
    created_at: hash["created_at"] || hash[:created_at],
    updated_at: hash["updated_at"] || hash[:updated_at]
  )
end