Error Getting Rates from USPS

For general questions and discussions specific to the AbleCommerce 7.0 Asp.Net product.
Post Reply
mouse_8b
Commander (CMDR)
Commander (CMDR)
Posts: 115
Joined: Mon Oct 11, 2010 1:21 pm
Location: Austin, TX
Contact:

Error Getting Rates from USPS

Post by mouse_8b » Tue Sep 09, 2014 9:10 am

Hello,
I have been getting 403: Forbidden from the USPS shipping rate calculator. I thought my API might be out of date, so I just uploaded the updated the API from viewtopic.php?f=65&t=18076

I am still getting the error. Does anyone have any ideas on how to solve or troubleshoot this further?

mouse_8b
Commander (CMDR)
Commander (CMDR)
Posts: 115
Joined: Mon Oct 11, 2010 1:21 pm
Location: Austin, TX
Contact:

Re: Error Getting Rates from USPS

Post by mouse_8b » Tue Sep 09, 2014 9:12 am

Also this error:
The underlying connection was closed: An unexpected error occurred on a receive.; Unable to read data from the transport connection: An existing connection was forcibly closed by the remote host.

User avatar
compunerdy
Admiral (ADM)
Admiral (ADM)
Posts: 1283
Joined: Sun Nov 18, 2007 3:55 pm

Re: Error Getting Rates from USPS

Post by compunerdy » Tue Sep 09, 2014 2:52 pm

Not seeing those errors here but I did have two customers say they could not get a rate over the last couple of days.

speedythinker
Commander (CMDR)
Commander (CMDR)
Posts: 121
Joined: Sat Sep 23, 2006 1:00 pm

Re: Error Getting Rates from USPS

Post by speedythinker » Wed Sep 10, 2014 11:37 am

Have trouble to ship to UK. Currently it is showing this error when "United Kingdom" selected:

"No shipping methods are available for the current items and/or the given destination. "

All other countries are just fine


Regards
Speedy

User avatar
compunerdy
Admiral (ADM)
Admiral (ADM)
Posts: 1283
Joined: Sun Nov 18, 2007 3:55 pm

Re: Error Getting Rates from USPS

Post by compunerdy » Wed Sep 10, 2014 3:43 pm

Same here.. 2 UK customers have said that.

User avatar
compunerdy
Admiral (ADM)
Admiral (ADM)
Posts: 1283
Joined: Sun Nov 18, 2007 3:55 pm

Re: Error Getting Rates from USPS

Post by compunerdy » Wed Sep 10, 2014 6:00 pm

Here is the error.. still looking into it.

Send: API=IntlRate&XML=<?xml version="1.0" encoding="UTF-8"?><IntlRateRequest USERID="xxxxxxxxxxx"><Package ID="0"><Pounds>1</Pounds><Ounces>0</Ounces><MailType>Package</MailType><Country>Great Britain</Country></Package></IntlRateRequest>

Receive: <?xml version="1.0" encoding="UTF-8"?>
<IntlRateResponse><Package ID="0"><Error><Number>-2147218043</Number><Source>;IntlRateV2.ProcessRequest</Source><Description>Unable to calculate international postage. No services available.
Invalid Country Name</Description><HelpFile/><HelpContext/></Error></Package></IntlRateResponse>

User avatar
compunerdy
Admiral (ADM)
Admiral (ADM)
Posts: 1283
Joined: Sun Nov 18, 2007 3:55 pm

Re: Error Getting Rates from USPS

Post by compunerdy » Wed Sep 10, 2014 6:18 pm

I cannot find any info that would explain why this suddenly changed.

User avatar
jmestep
AbleCommerce Angel
Posts: 8164
Joined: Sun Feb 29, 2004 8:04 pm
Location: Dayton, OH
Contact:

Re: Error Getting Rates from USPS

Post by jmestep » Thu Sep 11, 2014 3:46 am

It's a joke to try to find much on the USPS site, but I did find this:

INVALID CTRY CODE
If Class of Mail field in Detail Record 1 is IE, country code in Country Code field in Detail Record 1 must be a valid record in Country Code table.

When I Googled, I did find this for Ubercart
INSERT INTO {uc_countries} VALUES ('826', 'United Kingdom (Great Britain)', 'GB', 'GBR', 1)");

I have to apply the new USPS patch on some sites, so I'll do some testing.
Judy Estep
Web Developer
jestep@web2market.com
http://www.web2market.com
708-653-3100 x209
New search report plugin for business intelligence:
http://www.web2market.com/Search-Report ... -P154.aspx

User avatar
Katie
AbleCommerce Admin
AbleCommerce Admin
Posts: 2651
Joined: Tue Dec 02, 2003 1:54 am
Contact:

Re: Error Getting Rates from USPS

Post by Katie » Thu Sep 11, 2014 9:38 am

Has this issue just started recently? If you are still using the older API, I would like to confirm that this is something new within the last few days. I've finding nothing on the USPS site or anything recent on google.
Thank you for choosing AbleCommerce!

http://help.ablecommerce.com - product support
http://wiki.ablecommerce.com - developer support

speedythinker
Commander (CMDR)
Commander (CMDR)
Posts: 121
Joined: Sat Sep 23, 2006 1:00 pm

Re: Error Getting Rates from USPS

Post by speedythinker » Thu Sep 11, 2014 9:44 am

It should be a new glitch I think
Our last order to UK was back to June 30,2014

I'm running 7.0.7.14588
USPS is 7.3.14358.0

Thank you for looking into this case

Speedy

User avatar
Katie
AbleCommerce Admin
AbleCommerce Admin
Posts: 2651
Joined: Tue Dec 02, 2003 1:54 am
Contact:

Re: Error Getting Rates from USPS

Post by Katie » Thu Sep 11, 2014 10:17 am

We might have found the problem. To test, you will need to add a new country record. Use UK for the country code and use the name United Kingdom. Try the shipping calculator using the new country. It should work.

Now, here is the problem. You can't change the country code from GB to UK for the existing record if it has associated orders. That is why creating a new record is required. I think we can come up with a way to either update or remove the current country record, but I'll need the assistance of a developer.

I will try to update here tomorrow with a solution.
Thank you for choosing AbleCommerce!

http://help.ablecommerce.com - product support
http://wiki.ablecommerce.com - developer support

User avatar
compunerdy
Admiral (ADM)
Admiral (ADM)
Posts: 1283
Joined: Sun Nov 18, 2007 3:55 pm

Re: Error Getting Rates from USPS

Post by compunerdy » Thu Sep 11, 2014 12:06 pm

That seems to have fixed it except there are 2 united kingdoms now. For now I will just change the name of the other one until you give the okay to delete or whatever.

EDIT- Actually I just went ahead and deleted the GB United Kingdom one so I hope that was okay lol.

speedythinker
Commander (CMDR)
Commander (CMDR)
Posts: 121
Joined: Sat Sep 23, 2006 1:00 pm

Re: Error Getting Rates from USPS

Post by speedythinker » Thu Sep 11, 2014 12:08 pm

It woks, thank you Judy

I deleted the GB


Regards,
Speedy

User avatar
calvis
Rear Admiral (RADM)
Rear Admiral (RADM)
Posts: 710
Joined: Tue Jan 27, 2004 3:57 pm
Location: Redmond, WA

Re: Error Getting Rates from USPS

Post by calvis » Thu Sep 11, 2014 12:29 pm

In my case I have to keep the GB because that is what UPS uses. So now I have United Kingdom - USPS and United Kingdom - UPS.
Able Customer Since 1999 Currently Running on GOLD R12 SR1 and PCI Certified.

User avatar
Katie
AbleCommerce Admin
AbleCommerce Admin
Posts: 2651
Joined: Tue Dec 02, 2003 1:54 am
Contact:

Re: Error Getting Rates from USPS

Post by Katie » Thu Sep 11, 2014 12:49 pm

I have to wonder if this is something new that USPS changed and didn't bother to keep their customers notified. I believe that GB is still the correct country code. At least, it says so here: http://countrycode.org/uk

USPS is such a pain in the butt.
Thank you for choosing AbleCommerce!

http://help.ablecommerce.com - product support
http://wiki.ablecommerce.com - developer support

speedythinker
Commander (CMDR)
Commander (CMDR)
Posts: 121
Joined: Sat Sep 23, 2006 1:00 pm

Re: Error Getting Rates from USPS

Post by speedythinker » Thu Sep 11, 2014 12:59 pm

Me too, I think it is USPS issue!
This is not the first time or the second time they changed parameters things without a notice

Bad guy! But we got no choice and have to use its service


Speedy

mouse_8b
Commander (CMDR)
Commander (CMDR)
Posts: 115
Joined: Mon Oct 11, 2010 1:21 pm
Location: Austin, TX
Contact:

Re: Error Getting Rates from USPS

Post by mouse_8b » Tue Sep 16, 2014 1:19 pm

Any ideas for troubleshooting my original problem? "The remote server returned an error: (403) Forbidden."

User avatar
Katie
AbleCommerce Admin
AbleCommerce Admin
Posts: 2651
Joined: Tue Dec 02, 2003 1:54 am
Contact:

Re: Error Getting Rates from USPS

Post by Katie » Tue Sep 16, 2014 3:20 pm

403 Forbidden HTTP status code is response to a request from a client for a web page or resource to indicate that the server can be reached and understood the request, but refuses to take any further action. Status code 403 responses are the result of the web server being configured to deny access, for some reason, to the requested resource by the client.

You should check to see if the web server is the problem first. You can also enable debug from the USPS configuration page and view the usps.log file in \app_data\logs\. It will give us information about what was sent to USPS and what was received to generate the rate quote.
Thank you for choosing AbleCommerce!

http://help.ablecommerce.com - product support
http://wiki.ablecommerce.com - developer support

User avatar
compunerdy
Admiral (ADM)
Admiral (ADM)
Posts: 1283
Joined: Sun Nov 18, 2007 3:55 pm

Re: Error Getting Rates from USPS

Post by compunerdy » Tue Sep 16, 2014 11:39 pm

Found another country with a issue.. Uruguay

Any ideas what to change that to?

User avatar
Katie
AbleCommerce Admin
AbleCommerce Admin
Posts: 2651
Joined: Tue Dec 02, 2003 1:54 am
Contact:

Re: Error Getting Rates from USPS

Post by Katie » Wed Sep 17, 2014 6:33 am

Hello Tim,

Can you provide a bit more information?

- what address in Uruguay?
- what services do you have selected?
- do you have the recent USPS patch installed for 7.0.7?
- what errors do you see in the USPS.log file?

All this will help tremendously when trying to figure out if this is another country code issue or something else.

Thanks!
Thank you for choosing AbleCommerce!

http://help.ablecommerce.com - product support
http://wiki.ablecommerce.com - developer support

User avatar
compunerdy
Admiral (ADM)
Admiral (ADM)
Posts: 1283
Joined: Sun Nov 18, 2007 3:55 pm

Re: Error Getting Rates from USPS

Post by compunerdy » Wed Sep 17, 2014 9:28 am

Nevermind.. I just got a E-mail yesterday saying it was not giving rates and he has ordered from us before.. I just tested it and it pulls rates so who knows...

Post Reply