Zen Cart Logo
Forums / Addon Shipping Modules / USPS Shipping Module [Support Thread]

USPS Shipping Module [Support Thread]

Sticky

Views: 77,349

Results 341 to 360 of 447
13 Aug 2023, 12:25 AM
#341
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,096
Plugin Contributions:
56

USPS Shipping Module [Support Thread]

Jeff_Mash:

I am seeing the following error in the logs:

[12-Aug-2023 05:58:41 America/Los_Angeles] Request URI: /store/index.php?main_page=checkout_one, IP address: 129.222.137.108, Language id 1
#1 usps->quote() called at [/home/domain/public_html/store/includes/classes/shipping.php:201]
#2 shipping->quote() called at [/home/domain/public_html/store/includes/modules/pages/checkout_one/header_php.php:222]
#3 require(/home/domain/public_html/store/includes/modules/pages/checkout_one/header_php.php) called at [/home/domain/public_html/store/index.php:35]
--> PHP Warning: A non-numeric value encountered in /home/domain/public_html/store/includes/modules/shipping/usps.php on line 779.

> 
> That part of the USPS.php code deals with Handling Fees.    I noticed that this customer is from Canada, and our USPS Handling Fee for International customers was "BLANK".   I have gone ahead and put a "0" in the field to see if that corrects the issue, but wanted to log it here just in case having a "blank" handling fee value was causing the non-numerical error in line 779.
That would do it!
13 Aug 2023, 5:29 PM
#342
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,799
Plugin Contributions:
15

Re: USPS Shipping Module [Support Thread]

HeleneWallis:

I don't see how this has anything to do with ShipStation. Our ShipStation rates (when we use ShipStation to print labels) are correct. Zencart doesn't interact with ShipStation to pull up rates for the customer--those come from USPS. Agreed, makes no sense.I was simply saying that I am not aware of the discount one gets with ShipStation versus USPS.com logged in or not.

13 Aug 2023, 7:28 PM
#343
helenewallis avatar

helenewallis

Totally Zenned

Join Date:
Jun 2016
Location:
Suffolk VA
Posts:
625
Plugin Contributions:
0

Re: USPS Shipping Module [Support Thread]

dbltoe:

I was simply saying that I am not aware of the discount one gets with ShipStation versus USPS.com logged in or not.

Yes, sorry, I didn't intend that to be criticism of what you said. Just wanted to make it clear that it isn't ShipStation's problem. I'm not sure it's a Zencart problem either, though.

22 Aug 2023, 6:34 PM
#344
sammirah avatar

sammirah

Zen Follower

Join Date:
Apr 2012
Location:
Los Angeles, CA
Posts:
185
Plugin Contributions:
2

Re: USPS Shipping Module [Support Thread]

Is it just me or is First Class Mail options for Domestic Mail not being offered anymore? I really need that for small packages.

This is my recent installation:
USPS Version Date
You have installed:

2023-07-12 K11i

Enable USPS Shipping
Do you want to offer USPS shipping?

True
False

Full Name or Short Name
Do you want to use a Long or Short name for USPS shipping?

Long
Short

Enter the USPS Web Tools User ID
Enter the USPS USERID assigned to you for Rate Quotes/ShippingAPI.
690ATMOS3485

Which server to use
An account at USPS is needed to use the Production server

test
production

Quote Sort Order
Sorts the returned quotes using the service name Alphanumerically or by Price. Unsorted will give the order provided by USPS.

Unsorted
Alphabetical
Price-LowToHigh
Price-HighToLow

Handling Fee - US
National Handling fee for this shipping method.
1.25

Handling Fee - International
International Handling fee for this shipping method.
3.00

Handling Per Order or Per Box
Do you want to charge Handling Fee Per Order or Per Box?

Order
Box

Decimal Settings
Decimal Setting can be 1, 2 or 3. Sometimes International requires 2 decimals, based on Tare Rates or Product weights. Do you want to use 1, 2 or 3 decimals?

1
2
3

Tax Class
Use the following tax class on the shipping fee.

11000

Tax Basis
On what basis is Shipping Tax calculated. Options are
Shipping - Based on customers Shipping Address
Billing Based on customers Billing address
Store - Based on Store address if Billing/Shipping Zone equals Store zone

Shipping
Billing
Store

Shipping Zone
If a zone is selected, only enable this shipping method for that zone.

California

Sort Order
Sort order of display.
0

All Packages are Machinable?
Are all products shipped machinable based on C700 Package Services 2.0 Nonmachinable PARCEL POST USPS Rules and Regulations?

Note: Nonmachinable packages will usually result in a higher Parcel Post Rate Charge.

Packages 35lbs or more, or less than 6 ounces (.375), will be overridden and set to False

True
False

USPS Options
Select from the following the USPS options.
note: this adds a considerable delay in obtaining quotes.

Display weight
Display transit time

USPS Domestic Transit Time Calculation Mode
Select from the following the USPS options.
note: NEW and OLD will add additional time to quotes. CUSTOM allows your custom shipping days.

CUSTOM
NEW
OLD

USPS Domestic minimum Length
The Minimum Length, Width and Height are used to determine shipping methods available for Domestic Shipping.
While dimensions are not supported at this time, the Minimums are sent to USPS for obtaining Rate Quotes.
In most cases, these Minimums should never have to be changed.

Enter the Domestic
Minimum Length - default 8.625
8.625

USPS minimum Width
Enter the Minimum Width - default 5.375
5.375

USPS minimum Height
Enter the Minimum Height - default 1.625
1.625

USPS International minimum Length
The Minimum Length, Width and Height are used to determine shipping methods available for International Shipping.
While dimensions are not supported at this time, the Minimums are sent to USPS for obtaining Rate Quotes.
In most cases, these Minimums should never have to be changed.

Enter the International
Minimum Length - default 8.625
8.625

USPS minimum Width
Enter the Minimum Width - default 5.375
5.375

USPS minimum Height
Enter the Minimum Height - default 1.625
1.625

Shipping Methods (Domestic and International)
Checkbox: Select the services to be offered
Minimum Weight (lbs)first input field
Maximum Weight (lbs):second input field

USPS returns methods based on cart weights. These settings will allow further control (particularly helpful for flat rate methods) but will not override USPS limits

Domestic Rates:
MinMaxHandling

0
70
Media Parcel$
0.00

0
70
USPS Ground Advantage$
0.00

0
70
Priority$
0.00

0
70
Priority F/R Env$
0.00

0
70
Priority Leg. F/R Env$
0.00

0
70
Priority Pad. F/R Env$
0.00

0
70
Priority Sm. F/R Box$
0.00

0
70
Priority Md. F/R Box$
0.00

0
70
Priority Lg. F/R Box$
0.00

0
70
Priority Express$
0.00

0
70
Priority Express F/R Env$
0.00

0
70
Priority Express Leg. F/R Env$
0.00

International Rates:
MinMaxHandling

0
.21875
1st-Class Intl Letter$
0.00

0
4
1st-Class Intl Lg. Env$
0.00

0
4
1st-Class Package Intl Service$
0.00

0
66
Priority Intl$
0.00

0
4
Priority Intl F/R Env$
0.00

0
4
Priority Intl Sm. F/R Box$
0.00

0
20
Priority Intl Md. F/R Box$
0.00

0
20
Priority Intl Lg. F/R Box$
0.00

0
66
Priority Express Intl$
0.00

0
4
Priority Express Intl F/R Env$
0.00

0
70
USPS GXG Envs$
0.00

0
70
Global Exp Guar(GXG)$
0.00

Extra Services (Domestic)
Included in postage rates. Not shown to the customer.
WARNING: Some services cannot work with other services.
NY
Certified Mail
USPS Tracking Electronic
USPS Tracking
Insurance
Priority Mail Express Insurance
Priority Mail Insurance
Adult Sig Restricted Delivery
Adult Sig Required
Registered Mail
Collect on Delivery
Return Receipt
Certificate of Mailing (Form 3665)
Certificate of Mailing (Form 3817)
Sig Confirmation Electronic
Sig Confirmation
Priority Mail Express 1030 AM Delivery
Certified Mail Restricted Delivery
Certified Mail Adult Sig Required
Certified Mail Adult Sig Restricted Delivery
Sig Confirmation Restricted Delivery
Sig Confirmation Electronic Restricted Delivery
Collect on Delivery Restricted Delivery
Registered Mail Restricted Delivery
Insurance Restricted Delivery
Insurance Restricted Delivery (Priority Mail Express)
Insurance Restricted Delivery (Priority Mail)

Extra Services (International)
Included in postage rates. Not shown to the customer.
WARNING: Some services cannot work with other services.
NY
Registered Mail
Insurance
Return Receipt
Electronic USPS Delivery Confirmation International
Certificate of Mailing

Retail pricing or Online pricing?
Rates will be returned ONLY for methods available in this pricing type. Applies to prices and add on services

Retail
Online

Debug Mode
Would you like to enable debug mode? If set to Logs, a file will be written to the store's /logs directory on each USPS request.

Off
Logs

22 Aug 2023, 6:55 PM
#345
jeking avatar

jeking

Totally Zenned

Join Date:
Oct 2005
Location:
Chicago, IL USA
Posts:
1,592
Plugin Contributions:
0

Re: USPS Shipping Module [Support Thread]

sammirah:

Is it just me or is First Class Mail options for Domestic Mail not being offered anymore? I really need that for small packages.

The USPS does not offer First Class anymore. It's been replaced with Ground Advantage
.
https://faq.usps.com/articles/Knowledge/USPS-Ground-Advantage

29 Sep 2023, 2:20 PM
#346
apollowilcox avatar

apollowilcox

Zen Follower

Join Date:
Sep 2014
Location:
Indiana
Posts:
123
Plugin Contributions:
0

Re: USPS Shipping Module [Support Thread]

HeleneWallis:

I'm having the same issue, except that Shipstation is showing a much lower rate than what our customers are being charged. Tare is zero and even if we eliminated our very small handling charge, our customers' cost is several dollars above what we're being charged.

I tried changing from Online to Retail, and everything except Ground Advantage went up by a couple of dollars. Ground Advantage stayed the same, and in that setting, it was the least expensive. But when I went back to Online and the other prices went back down, Ground Advantage was more expensive than several of the Priority Mail services, when it should have been less expensive. I don't see any way to correct this.

We are experiencing this also. Shipstation is notably lower than what the website calculated, then lowers again when the 'Print Label' button is clicked. (Whereas for UPS, the rate initially retrieved by Shipstation does not change at label print.) The USPS shipping cost calc'd / charged online ends up being far higher than our final cost. Our business model is to simply break even on shipping, so this feels like over-charging. Just started in July/ August time frame. Not sure how to address it.

The website and shipstation are simply retrieving rates from the USPS account, so this feels like something going at the USPS source - and not an issue with either ZC or SS.

29 Sep 2023, 4:02 PM
#347
mikestaps avatar

mikestaps

Zen Follower

Join Date:
Aug 2010
Location:
Grand Blanc, MI
Posts:
305
Plugin Contributions:
1

Re: USPS Shipping Module [Support Thread]

HeleneWallis:

I don't see how this has anything to do with ShipStation. Our ShipStation rates (when we use ShipStation to print labels) are correct. Zencart doesn't interact with ShipStation to pull up rates for the customer--those come from USPS. Agreed, makes no sense.

I contacted ShipStation about the rate differences a while ago. My original reasoning was for UPS rates, but we have noticed the differences in the USPS rates as well.
Basically ShipStation gets even lower rates (volume discounts?). In order to quote the ShipSt######## rates through ZenCart they want us to use a third party rating service. Unfortunately at this point I do not recall the name of the company, but it was something like $0.10 per rate lookup.

29 Sep 2023, 4:49 PM
#348
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,096
Plugin Contributions:
56

Re: USPS Shipping Module [Support Thread]

mikestaps:

I contacted ShipStation about the rate differences a while ago. My original reasoning was for UPS rates, but we have noticed the differences in the USPS rates as well.
Basically ShipStation gets even lower rates (volume discounts?). In order to quote the ShipSt######## rates through ZenCart they want us to use a third party rating service. Unfortunately at this point I do not recall the name of the company, but it was something like $0.10 per rate lookup.
Thanks for the update, I'm sure that your response will help others (including myself) when trying to figure out why the UPS/USPS/FedEx shipping quotes retrieved by the Zen Cart shipping modules are more costly than those provided by ShipStation.

4 Oct 2023, 5:53 PM
#349
craftcorner avatar

craftcorner

New Zenner

Join Date:
Dec 2017
Location:
Anderson, IN
Posts:
44
Plugin Contributions:
0

Re: USPS Shipping Module [Support Thread]

Good afternoon! Folks that are using the PC version of the stamps.com software may want to be aware that there is currently a bug that causes a complete software crash on import if you're importing a lot of orders to the software. I have spoken extensively with stamps.com Tier 2 support; they are aware of the issue and are working on it. But in discussions with the Tier 2 rep, he suggested that I ask if there was a way to tell stamps.com not to look at the date when importing orders. Pardon my ignorance, but my response back to him was, "I think that process is actually driven/dictated by the stamps.php file." Am I correct? And, is that file generated by the stamps.com developers, or is it written by ZenCart developers?

9 Oct 2023, 1:03 PM
#350
gothstone avatar

gothstone

Zen Follower

Join Date:
Jun 2005
Posts:
330
Plugin Contributions:
0

Re: USPS Shipping Module [Support Thread]

The latest version is here https://www.zen-cart.com/showthread.php?223833-Stamps-com-getting-error-while-importing&p=1366247#post1366247
and was last touched by drbyte, but its not really his he was just updating it. I have it working ok on my 1.5.7/php 7.4 production site, but can't get it to work on my 1.5.8/php 8.2 dev site. We may have to pay more to use shipstation just cuz it works. :(
Also note, we are off thread topic here. Sorry all.

18 Dec 2023, 9:42 PM
#351
lindasdd avatar

lindasdd

Zen Follower

Join Date:
Jun 2007
Posts:
474
Plugin Contributions:
0

Re: USPS Shipping Module [Support Thread]

Finally upgraded to the latest version of this plugin today and I too am seeing the rate differences mentioned by others.

This has nothing to do with ShipStation or any other shipping tool.

The rates returned on Zen-Cart (via the USPS API) are not what they should be for the associated shipping account. I verified this by comparing the rates returned on stamps.com when logged into stamps.com.

That said, I do not have access to USPS developer services to actually debug the rate quoting that is happening in the programming.

18 Dec 2023, 10:14 PM
#352
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,799
Plugin Contributions:
15

Re: USPS Shipping Module [Support Thread]

What is your setting for "Retail Pricing or Online Pricing?"?

You should probably have it set for Online if using ShipStation.

Of course, tare weights set elsewhere can affect the quote as well.

19 Dec 2023, 2:34 PM
#353
lindasdd avatar

lindasdd

Zen Follower

Join Date:
Jun 2007
Posts:
474
Plugin Contributions:
0

Re: USPS Shipping Module [Support Thread]

dbltoe:

What is your setting for "Retail Pricing or Online Pricing?"?

You should probably have it set for Online if using ShipStation.

Of course, tare weights set elsewhere can affect the quote as well.

I have played with both settings. Neither is correct.

I will re-iterate again though, this has nothing to do with Shipstation, Shipworks, PirateShip, Shippo, or any other shipping tool.

It has to do with the rates being returned from USPS via the API being incorrect for the account number / meter number. I have played with weights and dimensions and everything else to no avail.

Although my understanding of the Zen-Cart module is not strong, I have contacts in USPS that might be able to connect me with their dev. team to try and troubleshoot.

19 Dec 2023, 3:18 PM
#354
lindasdd avatar

lindasdd

Zen Follower

Join Date:
Jun 2007
Posts:
474
Plugin Contributions:
0

Re: USPS Shipping Module [Support Thread]

lindasdd:

I have played with both settings. Neither is correct.

I will re-iterate again though, this has nothing to do with Shipstation, Shipworks, PirateShip, Shippo, or any other shipping tool.

It has to do with the rates being returned from USPS via the API being incorrect for the account number / meter number. I have played with weights and dimensions and everything else to no avail.

Although my understanding of the Zen-Cart module is not strong, I have contacts in USPS that might be able to connect me with their dev. team to try and troubleshoot.

Upon furthur review, it seems the Priority rates might be coming through correctly (although I had thought not yesterday and I think toggling the retail pricing on and then back to online pricing helped for some reason) and the issue was with the Ground Advantage rates.

Upon review of the code, I believe the following change needs to be made to includes\modules\shipping\usps.php
line 1281 should be changed from $service = 'GROUND ADVANTAGE'; to $service = 'GROUND ADVANTAGE COMMERCIAL';

I have made this change and it appears to be quoting correctly for me now.

That does leave one extra wrinkle for shippers to keep in mind - there is a 2nd tier (lower pricing) of Ground Advantage rates. Ground Advantage Cubic. I personally tap into that with the combination of product volume settings and shipping based on volume. Only important if you can utilize the cubic sizes and are shipping to far zones.

19 Dec 2023, 9:05 PM
#355
njcyx avatar

njcyx

Zen Follower

Join Date:
Apr 2019
Posts:
367
Plugin Contributions:
0

Re: USPS Shipping Module [Support Thread]

lindasdd:

Upon furthur review, it seems the Priority rates might be coming through correctly (although I had thought not yesterday and I think toggling the retail pricing on and then back to online pricing helped for some reason) and the issue was with the Ground Advantage rates.

Upon review of the code, I believe the following change needs to be made to includes\modules\shipping\usps.php
line 1281 should be changed from $service = 'GROUND ADVANTAGE'; to $service = 'GROUND ADVANTAGE COMMERCIAL';

I have made this change and it appears to be quoting correctly for me now.

That does leave one extra wrinkle for shippers to keep in mind - there is a 2nd tier (lower pricing) of Ground Advantage rates. Ground Advantage Cubic. I personally tap into that with the combination of product volume settings and shipping based on volume. Only important if you can utilize the cubic sizes and are shipping to far zones.

Thanks for your input! I just tried it on my end and it worked (Ground Advantage)!

13 Feb 2024, 11:03 PM
#356
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,096
Plugin Contributions:
56

Re: USPS Shipping Module [Support Thread]

Heads Up to all USPS shipping module users!

From this (https://www.usps.com/business/web-tools-apis/2024-web-tools-release-notes.pdf) USPS documentation:

Summary: Effective January 31, 2024, Web Tools will require the password be provided with the USERID in each label API XML request. Otherwise, an error will return. In TBD 2024, the password will be required for all API requests. Integrators are strongly encouraged to provide this information in advance of the change to avoid any service disruptions or integration issues. Contact [email protected] for any questions or concerns.

  1. Summary: Effective TBD December 2023, API access and permissions will be added separately after registration. To obtain these permissions, contact [email protected] and provide in your request for access:
  • Username/UserID (from the automated registration email):
  • USPS Mailer ID (MID):
  • Company Website:
    -Are you a shipper or software provider? Please provide details on how your business will use the
    APIs.
    -List of API(s) to which you would like access and expected volume (peak daily, weekly, monthly) – reference www.usps.com/webtools for a complete list of APIs

You'll need to request access to the RatesV4 and IntlV2 APIs.

Existing users note: You'll need to find you oldy-moldy email from USPS that includes that password. A forthcoming release of USPS will include a setting through which you can supply the password (which, for backward compatibility can be blank).

15 Feb 2024, 1:31 AM
#357
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,096
Plugin Contributions:
56

Re: USPS Shipping Module [Support Thread]

USPS Web Tools API shipping-module version 2024_02_14_K11j is now available for download: https://www.zen-cart.com/downloads.php?do=file&id=1292

Adds the PASSWORD setting that USPS will require for Web Tools API requests sometime in 2024, see GitHub issue #41 for details.

Additional documentation is provided at the shipping-module's Wiki: https://github.com/lat9/usps/wiki

Please Note: USPS plans to deprecate (no-longer support in non-tech-speak) the Web Tools API sometime later in 2024. I'm currently reviewing their new API and will have a *new *USPS shipping-module available within the next couple of months. That module will be designed to work with Zen Cart 1.5.8 and later, requiring a minimum PHP version of 8.0, so if your site is currently shipping with USPS on an older version of Zen Cart it's a great time to start planning your upgrade!

19 Feb 2024, 5:56 PM
#358
njcyx avatar

njcyx

Zen Follower

Join Date:
Apr 2019
Posts:
367
Plugin Contributions:
0

Re: USPS Shipping Module [Support Thread]

lat9:

USPS Web Tools API shipping-module version 2024_02_14_K11j is now available for download: https://www.zen-cart.com/downloads.php?do=file&id=1292

Adds the PASSWORD setting that USPS will require for Web Tools API requests sometime in 2024, see GitHub issue #41 for details.

Additional documentation is provided at the shipping-module's Wiki: https://github.com/lat9/usps/wiki

Please Note: USPS plans to deprecate (no-longer support in non-tech-speak) the Web Tools API sometime later in 2024. I'm currently reviewing their new API and will have a *new *USPS shipping-module available within the next couple of months. That module will be designed to work with Zen Cart 1.5.8 and later, requiring a minimum PHP version of 8.0, so if your site is currently shipping with USPS on an older version of Zen Cart it's a great time to start planning your upgrade!

Hi @lat9, thanks for your updates! I just updated my site from 11i to 11j and it worked fine. I only entered the account password. All the settings are the same as before after the upgrade. It seems working fine.

Do you have any comments regarding post #354? $service = 'GROUND ADVANTAGE' or $service = 'GROUND ADVANTAGE COMMERCIAL' ?

https://www.zen-cart.com/showthread.php?227284-USPS-Shipping-Module-Support-Thread&p=1398277#post1398277

2 Mar 2024, 5:08 PM
#359
helenewallis avatar

helenewallis

Totally Zenned

Join Date:
Jun 2016
Location:
Suffolk VA
Posts:
625
Plugin Contributions:
0

Re: USPS Shipping Module [Support Thread]

I need to exclude one product from some shipping services, something I've done with multiple other products. For whatever reason, this product number is being ignored in the statements that should be able to find it. I need to figure out what product id the program is actually seeing, since it's clearly not seeing the number that Zencart allegedly assigned to it. I've been trying to figure out the variable name for the product id in the cart array, and so far have not been successful. Can anyone help?

2 Mar 2024, 8:43 PM
#360
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,096
Plugin Contributions:
56

Re: USPS Shipping Module [Support Thread]

HeleneWallis:

I need to exclude one product from some shipping services, something I've done with multiple other products. For whatever reason, this product number is being ignored in the statements that should be able to find it. I need to figure out what product id the program is actually seeing, since it's clearly not seeing the number that Zencart allegedly assigned to it. I've been trying to figure out the variable name for the product id in the cart array, and so far have not been successful. Can anyone help?
... and what are "the statements that should be able to find it"?