コード例 #1
0
 /**
  * Get Bill Of Lading
  * Retrieves the PDF-formatted BOL data for a partnered LTL shipment.
  *     This PDF data will be ZIP'd and then it will be encoded as a Base64 string, and a
  *     MD5 hash is included with the response to validate the BOL data which will be encoded as Base64.
  *
  * @param mixed $request array of parameters for FBAInboundServiceMWS_Model_GetBillOfLading request or FBAInboundServiceMWS_Model_GetBillOfLading object itself
  * @see FBAInboundServiceMWS_Model_GetBillOfLadingRequest
  * @return FBAInboundServiceMWS_Model_GetBillOfLadingResponse
  *
  * @throws FbaInbound_Exception
  */
 public function getBillOfLading($request)
 {
     if (!$request instanceof Model\FBAInboundServiceMWS_Model_GetBillOfLadingRequest) {
         //require_once (dirname(__FILE__) . '/Model/GetBillOfLadingRequest.php');
         $request = new FBAInboundServiceMWS_Model_GetBillOfLadingRequest($request);
     }
     $parameters = $request->toQueryParameterArray();
     $parameters['Action'] = 'GetBillOfLading';
     $httpResponse = $this->_invoke($parameters);
     //require_once (dirname(__FILE__) . '/Model/GetBillOfLadingResponse.php');
     $response = Model\FBAInboundServiceMWS_Model_GetBillOfLadingResponse::fromXML($httpResponse['ResponseBody']);
     $response->setResponseHeaderMetadata($httpResponse['ResponseHeaderMetadata']);
     return $response;
 }
コード例 #2
0
ファイル: Client.php プロジェクト: stephlanj/mws
 /**
  * Get Bill Of Lading
  * Retrieves the PDF-formatted BOL data for a partnered LTL shipment.
  *     This PDF data will be ZIP'd and then it will be encoded as a Base64 string, and a
  *     MD5 hash is included with the response to validate the BOL data which will be encoded as Base64.
  *
  * @param mixed $request array of parameters for FBAInboundServiceMWS_Model_GetBillOfLading request or FBAInboundServiceMWS_Model_GetBillOfLading object itself
  * @see FBAInboundServiceMWS_Model_GetBillOfLadingRequest
  * @return FBAInboundServiceMWS_Model_GetBillOfLadingResponse
  *
  * @throws FBAInboundServiceMWS_Exception
  */
 public function getBillOfLading($request)
 {
     if (!$request instanceof FBAInboundServiceMWS_Model_GetBillOfLadingRequest) {
         $request = new FBAInboundServiceMWS_Model_GetBillOfLadingRequest($request);
     }
     $parameters = $request->toQueryParameterArray();
     $parameters['Action'] = 'GetBillOfLading';
     $httpResponse = $this->_invoke($parameters);
     $response = FBAInboundServiceMWS_Model_GetBillOfLadingResponse::fromXML($httpResponse['ResponseBody']);
     $response->setResponseHeaderMetadata($httpResponse['ResponseHeaderMetadata']);
     return $response;
 }