我使用 EXPRESS 服务向 Fedex Webservices 发送 XML 请求以创建 COD 标签。以下 XML 请求适用于 GROUND 服务,但不适用于 EXPRESS。我得到以下信息,这是调试信息。封装级别到底在哪里?
确认发货时出错:2245(快递发货的包裹级别无法指定 COD)
--------------------------------------------------
Debug Information
--------------------------------------------------
debugMode = 1
--------------------------------------------------
XML Sent
--------------------------------------------------
<ns:ProcessShipmentRequest xmlns:ns="http://fedex.com/ws/ship/v10" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://fedex.com/ws/ship/v10 ShipService v10.xsd">
<ns:WebAuthenticationDetail>
<ns:UserCredential>
<ns:Key>XXXX</ns:Key>
<ns:Password>XXXX</ns:Password>
</ns:UserCredential>
</ns:WebAuthenticationDetail>
<ns:ClientDetail>
<ns:AccountNumber>XXXX</ns:AccountNumber>
<ns:MeterNumber>XXXX</ns:MeterNumber>
</ns:ClientDetail>
<ns:TransactionDetail>
<ns:CustomerTransactionId>CreatePendingRequest</ns:CustomerTransactionId>
</ns:TransactionDetail>
<ns:Version>
<ns:ServiceId>ship</ns:ServiceId>
<ns:Major>10</ns:Major>
<ns:Intermediate>0</ns:Intermediate>
<ns:Minor>0</ns:Minor>
</ns:Version>
<ns:RequestedShipment>
<ns:ShipTimestamp>2012-11-13T18:59:09-07:00</ns:ShipTimestamp>
<ns:DropoffType>REGULAR_PICKUP</ns:DropoffType>
<ns:ServiceType>STANDARD_OVERNIGHT</ns:ServiceType>
<ns:PackagingType>YOUR_PACKAGING</ns:PackagingType>
<ns:Shipper>
<ns:Contact>
<ns:PersonName>John Doe</ns:PersonName>
<ns:CompanyName>Company</ns:CompanyName>
<ns:PhoneNumber>1123456789</ns:PhoneNumber>
</ns:Contact>
<ns:Address>
<ns:StreetLines>1234 Street Name</ns:StreetLines>
<ns:City>City</ns:City>
<ns:StateOrProvinceCode>FL</ns:StateOrProvinceCode>
<ns:PostalCode>12345</ns:PostalCode>
<ns:CountryCode>US</ns:CountryCode>
</ns:Address>
</ns:Shipper>
<ns:Recipient>
<ns:Contact>
<ns:PersonName>NAME</ns:PersonName>
<ns:CompanyName>COMPANY</ns:CompanyName>
<ns:PhoneNumber>0123456789</ns:PhoneNumber>
</ns:Contact>
<ns:Address>
<ns:StreetLines>STE</ns:StreetLines>
<ns:City>CITY NAME</ns:City>
<ns:StateOrProvinceCode>FL</ns:StateOrProvinceCode>
<ns:PostalCode>12345</ns:PostalCode>
<ns:CountryCode>US</ns:CountryCode>
</ns:Address>
</ns:Recipient>
<ns:ShippingChargesPayment>
<ns:PaymentType>SENDER</ns:PaymentType>
<ns:Payor>
<ns:AccountNumber>XXXX</ns:AccountNumber>
<ns:CountryCode>US</ns:CountryCode>
</ns:Payor>
</ns:ShippingChargesPayment>
<ns:SpecialServicesRequested>
</ns:SpecialServicesRequested>
<ns:LabelSpecification>
<ns:LabelFormatType>COMMON2D</ns:LabelFormatType>
<ns:ImageType>PNG</ns:ImageType>
<ns:LabelStockType>PAPER_8.5X11_TOP_HALF_LABEL</ns:LabelStockType>
</ns:LabelSpecification>
<ns:RateRequestTypes>LIST</ns:RateRequestTypes>
<ns:PackageCount>1</ns:PackageCount>
<ns:RequestedPackageLineItems>
<ns:Weight>
<ns:Units>LB</ns:Units>
<ns:Value>1</ns:Value>
</ns:Weight>
<ns:Dimensions>
<ns:Length>5</ns:Length>
<ns:Width>5</ns:Width>
<ns:Height>5</ns:Height>
<ns:Units>IN</ns:Units>
</ns:Dimensions>
<ns:SpecialServicesRequested>
<ns:SpecialServiceTypes>COD</ns:SpecialServiceTypes>
<ns:CodDetail>
<ns:CodCollectionAmount>
<ns:Currency>USD</ns:Currency>
<ns:Amount>115.00</ns:Amount>
</ns:CodCollectionAmount>
<ns:CollectionType>CASH</ns:CollectionType>
<ns:ReferenceIndicator>TRACKING</ns:ReferenceIndicator>
</ns:CodDetail>
</ns:SpecialServicesRequested>
</ns:RequestedPackageLineItems>
</ns:RequestedShipment>
</ns:ProcessShipmentRequest>
--------------------------------------------------
XML Response
--------------------------------------------------
<?xml version="1.0" encoding="UTF-8"?>
<v10:ProcessShipmentReply xmlns:v10="http://fedex.com/ws/ship/v10"><v10:HighestSeverity xmlns:env="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">ERROR</v10:HighestSeverity><v10:Notifications xmlns:env="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><v10:Severity>ERROR</v10:Severity><v10:Source>ship</v10:Source><v10:Code>2245</v10:Code><v10:Message>COD can not be specified at package level for Express Shipments</v10:Message><v10:LocalizedMessage>COD can not be specified at package level for Express Shipments</v10:LocalizedMessage></v10:Notifications><ns:TransactionDetail xmlns:ns="http://fedex.com/ws/ship/v10" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><ns:CustomerTransactionId>CreatePendingRequest</ns:CustomerTransactionId></ns:TransactionDetail><ns:Version xmlns:ns="http://fedex.com/ws/ship/v10" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><ns:ServiceId>ship</ns:ServiceId><ns:Major>10</ns:Major><ns:Intermediate>0</ns:Intermediate><ns:Minor>0</ns:Minor></ns:Version></v10:ProcessShipmentReply>
--------------------------------------------------
PHP Information
--------------------------------------------------
5.3.18
--------------------------------------------------
cURL Return Information
--------------------------------------------------
HTTP/1.1 100 Continue
HTTP/1.1 200 OK
Date: Wed, 14 Nov 2012 01:59:02 GMT
Server: Apache/2.2
Content-Length: 1167
x-wily-servlet: Clear appServerIp=204.135.252.191&agentName=ESB-servicebus-1&servletName=HttpTransportServlet&servletResponseTime=119&agentHost=qje20222&agentProcess=WebLogic
X-Powered-By: Servlet/2.5 JSP/2.1
x-wily-info: Clear guid=FCA41585CC87FCBF0C2A8683C9B05C6A
Vary: Accept-Encoding
Content-Type: text/xml; charset=utf-8
<?xml version="1.0" encoding="UTF-8"?>
<v10:ProcessShipmentReply xmlns:v10="http://fedex.com/ws/ship/v10"><v10:HighestSeverity xmlns:env="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">ERROR</v10:HighestSeverity><v10:Notifications xmlns:env="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><v10:Severity>ERROR</v10:Severity><v10:Source>ship</v10:Source><v10:Code>2245</v10:Code><v10:Message>COD can not be specified at package level for Express Shipments</v10:Message><v10:LocalizedMessage>COD can not be specified at package level for Express Shipments</v10:LocalizedMessage></v10:Notifications><ns:TransactionDetail xmlns:ns="http://fedex.com/ws/ship/v10" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><ns:CustomerTransactionId>CreatePendingRequest</ns:CustomerTransactionId></ns:TransactionDetail><ns:Version xmlns:ns="http://fedex.com/ws/ship/v10" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><ns:ServiceId>ship</ns:ServiceId><ns:Major>10</ns:Major><ns:Intermediate>0</ns:Intermediate><ns:Minor>0</ns:Minor></ns:Version></v10:ProcessShipmentReply>