Module: Slack::Web::Api::Endpoints::Oauth
- Included in:
- Slack::Web::Api::Endpoints
- Defined in:
- lib/slack/web/api/endpoints/oauth.rb
Instance Method Summary collapse
-
#oauth_access(options = {}) ⇒ Object
Exchanges a temporary OAuth verifier code for an access token.
-
#oauth_token(options = {}) ⇒ Object
Exchanges a temporary OAuth verifier code for a workspace token.
Instance Method Details
#oauth_access(options = {}) ⇒ Object
Exchanges a temporary OAuth verifier code for an access token.
24 25 26 |
# File 'lib/slack/web/api/endpoints/oauth.rb', line 24 def oauth_access( = {}) post('oauth.access', ) end |
#oauth_token(options = {}) ⇒ Object
Exchanges a temporary OAuth verifier code for a workspace token.
43 44 45 46 47 48 |
# File 'lib/slack/web/api/endpoints/oauth.rb', line 43 def oauth_token( = {}) throw ArgumentError.new('Required arguments :client_id missing') if [:client_id].nil? throw ArgumentError.new('Required arguments :client_secret missing') if [:client_secret].nil? throw ArgumentError.new('Required arguments :code missing') if [:code].nil? post('oauth.token', ) end |