Method: Fedex::Request::Shipment#process_request
- Defined in:
- lib/fedex/request/shipment.rb
#process_request ⇒ Object
Sends post request to Fedex web service and parse the response. A label file is created with the label at the specified location. The parsed Fedex response is available in #response_details e.g. response_details[:completed_package_details][:tracking_number]
24 25 26 27 28 29 30 31 32 33 |
# File 'lib/fedex/request/shipment.rb', line 24 def process_request api_response = self.class.post api_url, :body => build_xml puts api_response if @debug response = parse_response(api_response) if success?(response) success_response(api_response, response) else failure_response(api_response, response) end end |