Automattic / woocommerce-services

WooCommerce Services is a feature plugin that integrates hosted services into WooCommerce (3.0+), and currently includes automated tax rates and the ability to purchase and print USPS shipping labels.
GNU General Public License v2.0
107 stars 20 forks source link

Delivery date and guaranteed date. #1726

Closed budzanowski closed 5 years ago

budzanowski commented 5 years ago

Based on information found in: https://www.easypost.com/can-i-set-an-expected-delivery-date-with-your-api

We should display the delivery date as : Approximate when delivery_date_guaranteed is false and a certain when this field is true.

laurendavissmith commented 5 years ago

@aleftick will provide the verbiage for this, there is a certain language used in the carrier world

aleftick commented 5 years ago

I did quite a bit of research to see if we could approach this in a different way (like using USPS SLAs) and to avoid the EasyPost response increase. All things considered, I believe this is the best path forward.

For Priority Mail Express, EasyPost provides USPS's guaranteed delivery date. For every other service, we get the expected number of days it will take to make the delivery.

We should use the following verbiage:

We may be required to have footnote (I'm getting Legal to review):

*Delivery timelines provided by USPS and not guaranteed by Automattic Inc. For exceptions and details visit USPS.com.

aleftick commented 5 years ago

FYI: Request to Legal about any legalize is here.

aleftick commented 5 years ago

Legal responded and they will update the TOS. We don't need to add any footer note.

superdav42 commented 5 years ago

I was looking at implementing this but delivery_date_guaranteed is always false for all rates returned at least in USPS. USPS Priority Mail Express is the only USPS service with guaranteed delivery dates but it is returning:

  delivery_days: null,
  delivery_date: null,
  delivery_date_guaranteed: false,

Which means it displays nothing where it should say a delivery date. Not sure why we are not getting a date back from easypost but I believe it's related to not specifying a shipping date and time. USPS official calculator requires there is no way I can see to specify a shipping date and time in the easypost API request.

So we need to ask EasyPost why there is no guaranteed delivery date for USPS Express and if we can provide the shipping date.

superdav42 commented 5 years ago

EasyPost seems to be saying it's all USPS's fault and there's nothing they can do. To avoid showing nothing for delivery days for Express I suggest we show the same delivery days as Priority. Express is the fastest so it will be under promising and over delivering.

aleftick commented 5 years ago

I actually think he's misinformed and it's simply because our account doesn't have the "flag" turned on to return delivery dates for PME.

This is a reply from them on another exchange:

First, that field is not always expected to be populated; whether or not it is is dependent on the carrier and the service level in particular. This leads to my second note: The service level of the rate you've provided, USPS Express, is a sort of special case. We'd need to set a flag to populate that value for Express shipments, because doing so slows down the API response by as much as 500ms.

We should turn on the flag but I suspect it will affect our current version as soon as we turn it on. Let's coordinate on slack before we make the request.