Class: Webhookdb::Oauth::Tokens

Inherits:
TypedStruct show all
Defined in:
lib/webhookdb/oauth.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from TypedStruct

#[], #_apply, #_defaults, #as_json, #change

Constructor Details

#initialize(**kwargs) ⇒ Tokens

Returns a new instance of Tokens.



7
8
9
10
11
# File 'lib/webhookdb/oauth.rb', line 7

def initialize(**kwargs)
  super
  self.typecheck!(:access_token, String)
  self.typecheck!(:refresh_token, String, nullable: true)
end

Instance Attribute Details

#access_tokenObject (readonly)

Returns the value of attribute access_token.



5
6
7
# File 'lib/webhookdb/oauth.rb', line 5

def access_token
  @access_token
end

#refresh_tokenObject (readonly)

Returns the value of attribute refresh_token.



5
6
7
# File 'lib/webhookdb/oauth.rb', line 5

def refresh_token
  @refresh_token
end