Class: PlatformAPI::OauthToken

Inherits:
Object
  • Object
show all
Defined in:
lib/platform-api/client.rb

Overview

OAuth tokens provide access for authorized clients to act on behalf of a Heroku user to automate, customize or extend their usage of the platform. For more information please refer to the Heroku OAuth documentation

Instance Method Summary collapse

Constructor Details

#initialize(client) ⇒ OauthToken

Returns a new instance of OauthToken.



3357
3358
3359
# File 'lib/platform-api/client.rb', line 3357

def initialize(client)
  @client = client
end

Instance Method Details

#create(body = {}) ⇒ Object



3369
3370
3371
# File 'lib/platform-api/client.rb', line 3369

def create(body = {})
  @client.oauth_token.create(body)
end

#delete(oauth_token_id) ⇒ Object



3381
3382
3383
# File 'lib/platform-api/client.rb', line 3381

def delete(oauth_token_id)
  @client.oauth_token.delete(oauth_token_id)
end