Class: MAP::SecurityToken::Service
- Inherits:
-
Common::Client::Base
- Object
- Common::Client::Base
- MAP::SecurityToken::Service
- Defined in:
- lib/map/security_token/service.rb
Instance Method Summary collapse
Methods inherited from Common::Client::Base
configuration, #raise_backend_exception
Methods included from SentryLogging
#log_exception_to_sentry, #log_message_to_sentry, #non_nil_hash?, #normalize_level, #rails_logger
Instance Method Details
#token(application:, icn:) ⇒ Object
11 12 13 14 15 16 17 18 19 20 |
# File 'lib/map/security_token/service.rb', line 11 def token(application:, icn:) response = perform(:post, config.token_path, token_params(application, icn), { 'Content-Type' => 'application/x-www-form-urlencoded' }) Rails.logger.info("#{config.logging_prefix} token success, application: #{application}, icn: #{icn}") parse_response(response, application, icn) rescue Common::Client::Errors::ClientError => e parse_and_raise_error(e, icn, application) end |