Class: Supabase::Auth::Types::AuthMFAVerifyResponse
- Inherits:
-
Struct
- Object
- Struct
- Supabase::Auth::Types::AuthMFAVerifyResponse
- Defined in:
- lib/supabase/auth/types.rb
Overview
MFA Verify response (matches Python: access_token, token_type, expires_in, refresh_token, user)
Instance Attribute Summary collapse
-
#access_token ⇒ Object
Returns the value of attribute access_token.
-
#expires_in ⇒ Object
Returns the value of attribute expires_in.
-
#refresh_token ⇒ Object
Returns the value of attribute refresh_token.
-
#token_type ⇒ Object
Returns the value of attribute token_type.
-
#user ⇒ Object
Returns the value of attribute user.
Class Method Summary collapse
Instance Attribute Details
#access_token ⇒ Object
Returns the value of attribute access_token
337 338 339 |
# File 'lib/supabase/auth/types.rb', line 337 def access_token @access_token end |
#expires_in ⇒ Object
Returns the value of attribute expires_in
337 338 339 |
# File 'lib/supabase/auth/types.rb', line 337 def expires_in @expires_in end |
#refresh_token ⇒ Object
Returns the value of attribute refresh_token
337 338 339 |
# File 'lib/supabase/auth/types.rb', line 337 def refresh_token @refresh_token end |
#token_type ⇒ Object
Returns the value of attribute token_type
337 338 339 |
# File 'lib/supabase/auth/types.rb', line 337 def token_type @token_type end |
#user ⇒ Object
Returns the value of attribute user
337 338 339 |
# File 'lib/supabase/auth/types.rb', line 337 def user @user end |
Class Method Details
.from_hash(hash) ⇒ Object
345 346 347 348 349 350 351 352 353 354 355 |
# File 'lib/supabase/auth/types.rb', line 345 def self.from_hash(hash) return nil if hash.nil? new( access_token: hash["access_token"] || hash[:access_token], token_type: hash["token_type"] || hash[:token_type], expires_in: hash["expires_in"] || hash[:expires_in], refresh_token: hash["refresh_token"] || hash[:refresh_token], user: User.from_hash(hash["user"] || hash[:user]) ) end |