mrbarret
mrbarret

Reputation: 47

USPS International Rate OriginZip

I am querying the USPS Price Calculator for International Shipping. The query, with newlines added for readability, is

<IntlRateV2Request USERID="XXX">
   <Revision>2</Revision>
   <Package ID="1">
      <Pounds>12</Pounds>
      <Ounces>8.93</Ounces>
      <Machinable>false</Machinable>
      <MailType>LARGEENVELOPE</MailType>
      <ValueOfContents>123.45</ValueOfContents>
      <Country>USA</Country>
      <Container>RECTANGULAR</Container>
      <Size>LARGE</Size>
      <Width>13</Width>
      <Length>23</Length>
      <Height>8</Height>
      <Girth>0</Girth>
      <OriginZip>46023</OriginZip>
      <CommercialFlag>N</CommercialFlag>
      <CommercialPlusFlag>N</CommercialPlusFlag>
      <AcceptanceDateTime>2019-09-25T22:24:37-04:00</AcceptanceDateTime>
      <DestinationPostalCode>08083</DestinationPostalCode>
   </Package>
</IntlRateV2Request>

But I am getting the response

<?xml version="1.0" encoding="UTF-8"?>
<IntlRateV2Response><Package ID="1"><Error><Number>-2147219043</Number><Source>;IntlRateV2.ProcessRequest</Source><Description>OriginZip is invalid: 46023</Description><HelpFile/><HelpContext/></Error></Package></IntlRateV2Response>

and I don't know why. I have tried OriginZIP and ZipOrigination but to no avail. Any ideas about what may be going wrong?

Upvotes: 0

Views: 62

Answers (2)

Harry Whitehouse
Harry Whitehouse

Reputation: 41

You have the country as "USA" but you are requesting a price for an international package. So the country code should be that of a foreign country.

The domestic origin ZIP in generally irrelevant for international prices with one exception -- packages going from the USA to Canada. There are slightly different prices depending upon where you induct the package. For instance a Chicago origin (induction point) will have a different price than the same package inducted in Miami.

Upvotes: 0

mrbarret
mrbarret

Reputation: 47

It looks like that OriginZip is not a US location but needs to be.

Upvotes: 0

Related Questions