Class: Cb::Requests::CoverLetter::Update

Inherits:
Base
  • Object
show all
Defined in:
lib/cb/requests/cover_letter/update.rb

Instance Attribute Summary

Attributes inherited from Base

#args

Instance Method Summary collapse

Methods inherited from Base

#base_uri, #headers, #initialize, #query

Constructor Details

This class inherits a constructor from Cb::Requests::Base

Instance Method Details

#bodyObject



25
26
27
28
29
30
31
32
33
34
35
36
# File 'lib/cb/requests/cover_letter/update.rb', line 25

def body
  <<-eos
    <Request>
      <DeveloperKey>#{ Cb.configuration.dev_key }</DeveloperKey>
      <ExternalID>#{ args[:external_id] }</ExternalID>
      <ExternalUserID>#{ args[:external_user_id] }</ExternalUserID>
      <CoverLetterTitle>#{ args[:cover_letter_title] }</CoverLetterTitle>
      <Text>#{ args[:text] }</Text>
      <Test>#{ args[:test] || false }</Test>
    </Request>
  eos
end

#endpoint_uriObject



17
18
19
# File 'lib/cb/requests/cover_letter/update.rb', line 17

def endpoint_uri
  Cb.configuration.uri_cover_letter_update
end

#http_methodObject



21
22
23
# File 'lib/cb/requests/cover_letter/update.rb', line 21

def http_method
  :post
end