Class: SnapDeploy::Provider::Heroku::API::OauthAuthorization
- Inherits:
-
Object
- Object
- SnapDeploy::Provider::Heroku::API::OauthAuthorization
- Defined in:
- lib/snap_deploy/provider/heroku/api.rb
Overview
OAuth authorizations represent clients that a Heroku user has authorized to automate, customize or extend their usage of the platform. For more information please refer to the [Heroku OAuth documentation](devcenter.heroku.com/articles/oauth)
Instance Method Summary collapse
-
#create(body) ⇒ Object
Create a new OAuth authorization.
-
#delete(oauth_authorization_id) ⇒ Object
Delete OAuth authorization.
-
#info(oauth_authorization_id) ⇒ Object
Info for an OAuth authorization.
-
#initialize(client) ⇒ OauthAuthorization
constructor
A new instance of OauthAuthorization.
-
#list ⇒ Object
List OAuth authorizations.
-
#regenerate(oauth_authorization_id) ⇒ Object
Regenerate OAuth tokens.
Constructor Details
#initialize(client) ⇒ OauthAuthorization
Returns a new instance of OauthAuthorization.
1030 1031 1032 |
# File 'lib/snap_deploy/provider/heroku/api.rb', line 1030 def initialize(client) @client = client end |
Instance Method Details
#create(body) ⇒ Object
Create a new OAuth authorization.
1037 1038 1039 |
# File 'lib/snap_deploy/provider/heroku/api.rb', line 1037 def create(body) @client..create(body) end |
#delete(oauth_authorization_id) ⇒ Object
Delete OAuth authorization.
1044 1045 1046 |
# File 'lib/snap_deploy/provider/heroku/api.rb', line 1044 def delete() @client..delete() end |
#info(oauth_authorization_id) ⇒ Object
Info for an OAuth authorization.
1051 1052 1053 |
# File 'lib/snap_deploy/provider/heroku/api.rb', line 1051 def info() @client..info() end |
#list ⇒ Object
List OAuth authorizations.
1056 1057 1058 |
# File 'lib/snap_deploy/provider/heroku/api.rb', line 1056 def list() @client..list() end |
#regenerate(oauth_authorization_id) ⇒ Object
Regenerate OAuth tokens. This endpoint is only available to direct authorizations or privileged OAuth clients.
1063 1064 1065 |
# File 'lib/snap_deploy/provider/heroku/api.rb', line 1063 def regenerate() @client..regenerate() end |