Class: Supabase::Auth::Types::AMREntry

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

Overview

Authentication method reference entry (matches Python AMREntry)

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Attribute Details

#methodObject

Returns the value of attribute method

Returns:

  • (Object)

    the current value of method



19
20
21
# File 'lib/supabase/auth/types.rb', line 19

def method
  @method
end

#timestampObject

Returns the value of attribute timestamp

Returns:

  • (Object)

    the current value of timestamp



19
20
21
# File 'lib/supabase/auth/types.rb', line 19

def timestamp
  @timestamp
end

Class Method Details

.from_hash(hash) ⇒ Object



24
25
26
27
28
29
30
31
# File 'lib/supabase/auth/types.rb', line 24

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

  new(
    method: hash["method"] || hash[:method],
    timestamp: hash["timestamp"] || hash[:timestamp]
  )
end