Service type takes precedence over carrier codes; service type used to rate error

StackOverflow https://stackoverflow.com/questions/11899747

  •  25-06-2021
  •  | 
  •  

Question

I try to receive shipping price from fedex so I send to Fedex (https://wsbeta.fedex.com:443/web-services/rate) request which looks like follows (It is serialized to xml object):

<?xml version=\"1.0\" encoding=\"utf-16\"?>
<RateRequest xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\">
  <WebAuthenticationDetail xmlns=\"http://fedex.com/ws/rate/v10\">
    <UserCredential>
      <Key>some key</Key>
      <Password>some password</Password>
    </UserCredential>
  </WebAuthenticationDetail>
  <ClientDetail xmlns=\"http://fedex.com/ws/rate/v10\">
    <AccountNumber>some account number</AccountNumber>
    <MeterNumber>some meter number</MeterNumber>
  </ClientDetail>
  <TransactionDetail xmlns=\"http://fedex.com/ws/rate/v10\">
    <CustomerTransactionId>some CustomerTransactionId</CustomerTransactionId>
  </TransactionDetail>
  <Version xmlns=\"http://fedex.com/ws/rate/v10\">
    <ServiceId>crs</ServiceId>
    <Major>10</Major>
    <Intermediate>0</Intermediate>
    <Minor>0</Minor>
  </Version>
  <ReturnTransitAndCommit xmlns=\"http://fedex.com/ws/rate/v10\">true</ReturnTransitAndCommit>
  <CarrierCodes xmlns=\"http://fedex.com/ws/rate/v10\">FDXE</CarrierCodes>
  <RequestedShipment xmlns=\"http://fedex.com/ws/rate/v10\">
    <ShipTimestamp>2012-08-10T11:42:00.2669059+02:00</ShipTimestamp>
    <ServiceType>GROUND_HOME_DELIVERY</ServiceType>
    <PackagingType>YOUR_PACKAGING</PackagingType>
    <TotalInsuredValue>
      <Currency>USD</Currency>
    </TotalInsuredValue>
    <Shipper>
      <Address>
        <City>San Francisco</City>
        <StateOrProvinceCode>CA</StateOrProvinceCode>
        <PostalCode>94129</PostalCode>
        <CountryCode>US</CountryCode>
      </Address>
    </Shipper>
    <Recipient>
      <Address>
        <StreetLines>S</StreetLines>
        <StreetLines>s</StreetLines>
        <City>New York</City>
        <StateOrProvinceCode>NY</StateOrProvinceCode>
        <PostalCode>10001</PostalCode>
        <CountryCode>US</CountryCode>
        <Residential>true</Residential>
      </Address>
    </Recipient>
    <ShippingChargesPayment />
    <RateRequestTypes>ACCOUNT</RateRequestTypes>
    <RateRequestTypes>LIST</RateRequestTypes>
    <PackageCount>1</PackageCount>
    <RequestedPackageLineItems>
      <SequenceNumber>1</SequenceNumber>
      <GroupPackageCount>1</GroupPackageCount>
      <InsuredValue />
      <Weight>
        <Units>LB</Units>
        <Value>133.00000</Value>
      </Weight>
      <Dimensions>
        <Units>IN</Units>
      </Dimensions>
    </RequestedPackageLineItems>
  </RequestedShipment>
</RateRequest>

I still receive two errors:

  • 870 - Service type takes precedence over carrier codes; service type used to rate
  • 809 - Package 1 - Weight is missing or invalid.

What should I change to solve this?

Was it helpful?

Solution

I found solution. To resolve first issue I had to change ServiceType value which didn't suite CarrierCodes. The suitable CarrierCode for GROUND_HOME_DELIVERY was FDXG.

The second problem was that the packages with weight over 70lbs should be sent using FEDEX_GROUND , not GROUND_HOME_DELIVERY.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top