Class: API::WhatCounts::Service
- Inherits:
-
Object
- Object
- API::WhatCounts::Service
- Includes:
- Base
- Defined in:
- lib/whatcounts/base.rb
Instance Attribute Summary collapse
-
#api_message_response ⇒ Object
Returns the value of attribute api_message_response.
Instance Method Summary collapse
Instance Attribute Details
#api_message_response ⇒ Object
Returns the value of attribute api_message_response.
11 12 13 |
# File 'lib/whatcounts/base.rb', line 11 def end |
Instance Method Details
#send_one_off_message(message) ⇒ Object
13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 |
# File 'lib/whatcounts/base.rb', line 13 def () = API::WhatCounts::OneOffMessageRequest.new # assemble the data in a hash for the POST .set_data() # make the call, parse the response response = API::WhatCounts::OneOffMessageResponse.new( ssl_post(.url, .data) ) self. = response return response rescue Exception => err log_error(err, 'send_one_off_message()') # raise a generic error for the caller raise ServiceError end |