Class: EVSS::Letters::Service
- Inherits:
-
Service
- Object
- Common::Client::Base
- Service
- EVSS::Letters::Service
- Defined in:
- lib/evss/letters/service.rb
Overview
Proxy Service for Letters Caseflow.
Constant Summary collapse
- INVALID_ADDRESS_ERROR =
'letterDestination.addressLine1.invalid'
Constants inherited from Service
Instance Attribute Summary
Attributes inherited from Service
Instance Method Summary collapse
-
#get_letter_beneficiary ⇒ EVSS::Letters::BeneficiaryResponse
Returns benefit and service information for a user.
-
#get_letters ⇒ EVSS::Letters::LettersResponse
Returns letters for a user.
Methods inherited from Service
#headers, #initialize, #perform, service_is_up?
Methods included from Common::Client::Concerns::Monitoring
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
Constructor Details
This class inherits a constructor from EVSS::Service
Instance Method Details
#get_letter_beneficiary ⇒ EVSS::Letters::BeneficiaryResponse
Returns benefit and service information for a user.
an array of military service objects
47 48 49 50 51 52 |
# File 'lib/evss/letters/service.rb', line 47 def get_letter_beneficiary with_monitoring_and_error_handling do raw_response = perform(:get, 'letterBeneficiary') EVSS::Letters::BeneficiaryResponse.new(raw_response.status, raw_response) end end |
#get_letters ⇒ EVSS::Letters::LettersResponse
Returns letters for a user.
array of letter objects
32 33 34 35 36 37 38 39 |
# File 'lib/evss/letters/service.rb', line 32 def get_letters with_monitoring do raw_response = perform(:get, '') EVSS::Letters::LettersResponse.new(raw_response.status, raw_response) end rescue => e handle_error(e) end |