Class: Kpm::AuthToken
- Inherits:
-
OpenAPI::AuthToken
- Object
- OpenAPI::AuthToken
- Kpm::AuthToken
- Defined in:
- lib/kpm/auth_token.rb
Instance Method Summary collapse
-
#initialize ⇒ AuthToken
constructor
A new instance of AuthToken.
- #new_auth_token ⇒ Object
Constructor Details
#initialize ⇒ AuthToken
Returns a new instance of AuthToken.
4 5 6 7 8 |
# File 'lib/kpm/auth_token.rb', line 4 def initialize super ({"expires_in" => 3600, "header" => "Authorization", "header_format" => "%s"}) end |
Instance Method Details
#new_auth_token ⇒ Object
10 11 12 13 14 |
# File 'lib/kpm/auth_token.rb', line 10 def new_auth_token() # auth_response = Kpm.auth(body: {user: {email: Kpm.user, password: Kpm.password}}.to_json) # auth_response.authentication_token update({"token" => "no-token-required-yet"}) end |