Ecommerce software home
Shopping Cart Software Forum for Ecommerce Templates
 
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

Find us on Facebook Follow us on Twitter View our YouTube channel
Search our site
Forum Search
Google Site Search
 All Forums
 Technical
 ASP (Windows server) versions
 UPS Negotiated Rates not working?
Author « Topic »  

Graham Slaughter
Ecommerce Template Expert

821 Posts

Posted - 04/12/2024 :  05:56:31  
A few weeks back our UPS rates on the cart page started to no longer display negotiated rates. They WERE working correctly, and I have made no changes to the code since then.

We are on 7.6.2

Has there been any update to the software in relation to UPS rates since then?


Our debug shows that we are correctly requesting negotiated rates, but the XML reply shows the exact same rate ($) under negotiated as non negotiated.

We have been trying to sort it out with UPS, but they're struggling to be helpful which seems to be common when we contact them.
Their last response wants to know what API we are using (I assume that's the endpoint URL which I already pulled up for them out of the code) and they also want to know if we're using OAuth. Anybody got any input on those 2 questions?

Vince
Administrator

42766 Posts

Posted - 04/12/2024 :  10:25:29  
Hi Graham
In the latest version both the old XML and the new JSON / OAuth API's are integrated, but you do need to re-register. What you'll need to do for the new system is install the latest updater and then go to the UPS Admin registration page and follow the instructions there. But if you can't do that you are using the old, XML integration.

Vince

Click Here for Shopping Cart Software
Click Here to sign up for our newsletter
Click Here for the latest updater

Graham Slaughter
Ecommerce Template Expert

821 Posts

Posted - 04/12/2024 :  14:03:06  
Thanks Vince. Upon further investigation, at least ONE of the rates (International) is returning correctly as negotiated, but the domestic rate we care about is not, so surely the issue is on their end. I'll keep trying to press through with them. Thanks!

Graham Slaughter
Ecommerce Template Expert

821 Posts

Posted - 05/01/2024 :  12:32:41  
This has taken quite some time to get replies from UPS, but I think we may have tracked down the issue.

This is Tristan writing to you from the UPS Third Level Technical Support. I understand you receiving incorrect rates from the UPS Rating API. Based on the information provided, to receive the same rate returned from UPS.com for your account number, the CustomerClassification container is required in the request with a value of 05 passed to the CustomerClassification Code parameter. Please see attached.


Excerpt of the Example from UPS:
<RatingServiceSelectionRequest xml:lang="en-US">
<Request>
<TransactionReference>
<CustomerContext>Rating and Service</CustomerContext>
<XpciVersion>1.0001</XpciVersion>
</TransactionReference>
<RequestAction>Rate</RequestAction>
<RequestOption>shop</RequestOption>
</Request>
<CustomerClassification>
<Code>05</Code>
</CustomerClassification>
<PickupType>
<Code>01</Code>
</PickupType>


I modified our inccart.asp to insert this line in the XML as such:
sXML="<" & "?xml version=""1.0""?><AccessRequest xml:lang=""en-US"">" & addtag("AccessLicenseNumber",upsAccess) & addtag("UserId",upsUser) & addtag("Password",upsPw)&"</AccessRequest><" & "?xml version=""1.0""?>" & _
"<RatingServiceSelectionRequest xml:lang=""en-US""><Request><TransactionReference><CustomerContext>Rating and Service</CustomerContext><XpciVersion>1.0001</XpciVersion></TransactionReference>" & _
"<RequestAction>Rate</RequestAction><RequestOption>" & IIfVr(shipType=11,"Rate","shop") & "</RequestOption></Request> <CustomerClassification><Code>05</Code></CustomerClassification>"


This tweak DID correct the issue of the negotiated rate not bring returned.


All that said, I reverted the code until I can get UPS to tell me what exactly I'm indicating on that XML query ("<CustomerClassification><Code>05</Code></CustomerClassification>") and to ask Vince if this make sense to him and that maybe this needs a bug update?

dbdave
ECT Moderator

USA
10410 Posts

Posted - 05/01/2024 :  15:21:42  
Hi Graham, I know Vince will need to deal with a response, but I did find this
quote:
Are the rates that a customer gets via
the Rating API - Package the same as
the rates they receive at The UPS
Store® locations or UPS Customer
Centers?
The Rating API - Package allows ability to
specify a Customer Classification Code
that determines the Rate returned. Please
refer to the Developer Guide for more
information.


in the PDF linked here - https://www.ups.com/assets/resources/webcontent/vi_VN/Developer_APIs_Knowledge_Base.pdf

Then from this page, I get https://developer.ups.com/api/reference?loc=en_US#tag/Rating_other
quote:
Customer classification code.
Valid values:00
Rates Associated with Shipper Number01
Daily Rates04
Retail Rates05
Regional Rates06
General List Rates53
Standard List RatesLength is not validated.
If customer classification code is not a valid value please refer to Rate Types Table on page 11.


Weird that is shows 5 is retail rates.
Oh and "UPS Third Level Technical Support" WOW! How many levels do they have?

Thanks,
David

Graham Slaughter
Ecommerce Template Expert

821 Posts

Posted - 05/01/2024 :  15:29:25  
Whoever they are, tier 3 if the first one who could actually HELP!

Thanks for pulling that up Dave! How the heck it makes sense to ask for Retail Rates ... at least it worked!

dbdave
ECT Moderator

USA
10410 Posts

Posted - 05/01/2024 :  15:49:59  
There are these long time in use settings for includes and I'm not sure if this is the same thing.
I expect not.
quote:
UPS Options

The way that you deliver your packages to UPS for delivery can affect the total cost of delivering the package. We have set the default as "Customer Counter", though you can change this by setting the following in your vsadmin/includes.asp file . . .

upspickuptype="03"

The code in quotes there would be taken from the following table...

01 - Daily Pickup
03 - Customer Counter
06 - One Time Pickup
07 - On Call Air
19 - Letter Center
20 - Air Service Center


I have mine sent to 01

Thanks,
David

Edited by - dbdave on 05/01/2024 15:50:58

Graham Slaughter
Ecommerce Template Expert

821 Posts

Posted - 05/07/2024 :  05:46:24  
It's definitely not that, but I still have heard back from their support people either. It feels like getting answers from UPS tech support can be a bit slow at times. The poor dudes are probably buried.

That said, Vince I don't suppose you've had a chance to look into it? This tweak definitely fixed my issue of negotiated rates not showing up. To be specific, it WAS showing negotiated rates correctly for international shipments, but not US domestic overnight. I would have tested it more, but I didn't know what the implications of setting that indicator were, so I didn't leave it setup. I still haven't heard from UPS to know what that indicator means, so I haven't tried testing further.

- Graham Slaughter

Vince
Administrator

42766 Posts

Posted - 05/07/2024 :  09:17:15  
Hi Graham
Well this is a strange one really. In all the time people have been using UPS Negotiated Rates I've never come across that CustomerClassification setting or of anyone needing to set it. Also, as UPS are moving to the new API (and will at some point probably stop supporting the old one) it's going to be irrelevant soon anyway. Would the idea be to just keep on using it if it works for you?

Vince

Click Here for Shopping Cart Software
Click Here to sign up for our newsletter
Click Here for the latest updater

Graham Slaughter
Ecommerce Template Expert

821 Posts

Posted - 05/07/2024 :  11:54:59  
No sweat. I'll just code it back in for our personal installation. I probably wont update beyond 7.6.2 for a year or two unless we have an urgent reason to do so, so this should keep me working until then. I'll let you know if it does anything weird

Graham Slaughter
Ecommerce Template Expert

821 Posts

Posted - 05/21/2024 :  09:30:30  
As a final note here incase anybody ever needs to reference it again.

We finally received a reply from UPS about what that tag indicated:
Thank you for your response. The Customer Classification values are related to your account number’s Rate Chart. CustomerClassification Code 05 is for Regional Rates.


We applied this hard coded change to our inccart.asp as indicated. This corrected negotiated rates for domestic shipments. UPS rates for international shipments were not effected by this change. Those rates were already returning negotiated correctly anyway. So far it's working great. I'll post here if anything else goes out of whack.
  « Topic »  
Jump To:
Shopping Cart Software Forum for Ecommerce Templates © 2002-2022 ecommercetemplates.com
This page was generated in 0.03 seconds. Snitz Forums 2000