Class: OmniAuth::Strategies::Sabia
- Inherits:
-
OAuth2
- Object
- OAuth2
- OmniAuth::Strategies::Sabia
- Defined in:
- lib/omniauth/strategies/sabia.rb
Instance Method Summary collapse
Instance Method Details
#authorize_params ⇒ Object
14 15 16 17 18 19 20 |
# File 'lib/omniauth/strategies/sabia.rb', line 14 def super.tap do |params| if request.params['scope'] params['scope'.to_sym] = request.params['scope'] end end end |
#callback_url ⇒ Object
43 44 45 |
# File 'lib/omniauth/strategies/sabia.rb', line 43 def callback_url full_host + script_name + callback_path end |
#raw_info ⇒ Object
37 38 39 40 41 |
# File 'lib/omniauth/strategies/sabia.rb', line 37 def raw_info @raw_info ||= access_token.post('/api/perfil/dados/', :headers => {'Content-Type' => 'application/x-www-form-urlencoded'}, :body => {scope: 'cpf email dados_publicos cnes receita_federal'}).parsed end |