Jump to content
  • Checkout
  • Login
  • Get in touch


The e-commerce.

UPSXML returns incorrect pricing from UPS


Recommended Posts

Hi Everyone,


This is my first post here, so please bear with me. First a few details:


I'm attempting to set up a brand new store, using osCommerce v2.2 RC2 and UPSXML v1.3.7

Site: http://muellerized.com/shop/


I was able to successfully install osCommerce and the UPSXML shipping module and had ZERO errors. I am not trying to do anything fancy, but I am trying to use the UPS rates using our UPS account and other associated data (keys, etc...) which should be fairly straightforward. I have everything set up correctly as far as I can tell, but my problem is that the rates returned by UPSXML are not the same as the rates returned by logging into UPS using the same account and retrieving a quote (or even placing an actual shipping order). I am NOT trying to use the dimensional shipping support (yet) and so the estimates returned by UPSXML are just based off of weight.


I would be happy to give login information for our osCommerce site to anyone who would like to take a look and see if maybe I just screwed up a simple setting. The site is not live and this is really the only reason it isn't. I have plenty of small things to clean up looks-wise as well as actually entering our full catalog, but if I can't get shipping quotes set up, there is not really much reason to launch the site.


Here is an example of what I mean:


1. Test Product - http://muellerized.com/shop/product_info.p...;products_id=28

2. The products weight is set up to be 58 lbs.

3. When checking out with the test product selected, UPSXML returns a quote of $47.04 for UPS Ground. UPS.com using our account and the same shipping weight returns a quote for $19 or so (I can mess with the dimensions all over and it really doesn't change the quote too much.


One of two things is happening. Either I misunderstand the feature-set of UPSXML, and accurate quotes can only be returned with the dimensional support set up (with product parameters entered appropriately), or I have something misconfigured.


Can anyone shed some light on this? I would be very grateful for any suggestions.



Link to comment
Share on other sites

I just want to add that displayed above the UPSXML quotes that are returned is the following:

"United Parcel Service (2 pkg(s) x 32 lbs total)"


How 58 lbs translates to 2 packages x 32 lbs is beyond me. If anyone needs any more information I would be more than happy to provide it. Thanks in advance :)



Link to comment
Share on other sites

How 58 lbs translates to 2 packages x 32 lbs is beyond me. If anyone needs any more information I would be more than happy to provide it.

osC splits the order in packages and adds tare using admin settings (documentation for v3 but still the same rules).


Then your company might enjoy discounted rates from UPS. If you start using UPSXML it usually takes a while before they start returning those discounted rates.

Link to comment
Share on other sites

  • 2 weeks later...
osC splits the order in packages and adds tare using admin settings (documentation for v3 but still the same rules).


Then your company might enjoy discounted rates from UPS. If you start using UPSXML it usually takes a while before they start returning those discounted rates.


Since this response I've removed all the extra charges via the admin (to try to compare quotes in OSCommerce/UPSXML with the discounted rates received through our UPS account on the UPS.com website). This did bring the OSCommerce/UPSXML rates to be a little closer to the ones returned on UPS.com but not by enough :(


I did have some dialogue with Jan over PM which I thought I'd include here for anyone else having the same problem in the future. Here are Jan's statements, which were helpful in troubleshooting this issue:


1. "I think I read somewhere that they need to reconfigure things at the UPS site and they only update that once in a while. Might be a week or so before the discounted rates appear (the xml already contains discounted rates but also a warning that they are not, which is not shown to the customer)."


I have already had UPSXML up and returning rates (albeit not usable ones yet) for over a month. This may be helpful to someone else in the future.


2. My question to Jan: "Do you know where I can check the response from UPS regarding rates? I set up UPSXML over a month ago and don't get even close to the discounted rates I get when I use the UPS website."


Jan's response:

"Of course you have to set it in the admin section of UPSXML that you ask for discounted rates. In the trouble shoot section of the UPSXML contribution is described how you can save the requests and responses of UPS to a log file.


If you are sure the request for discounted rates go out but none are received from UPS (discounted and normal rate are the same) then is the time to confront UPS with it."


CURRENT STATUS (and what I've completed so far):

I found in the documentation where it states how to create a log file and have been able to create this log file successfully. For anyone not versed in how to do this, the file you will need to edit is located in shop/includes/modules/shipping/upsxml.php and is easily accessible/editable through the OSCommerce Admin File Manager


You remove the characters // in the following line:

// $this->logfile = '/srv/www/htdocs/catalog/includes/modules/shipping/upsxml.log';


You may also need to edit this line to point to the correct directory on your server. In my case for example I had to change it to the following:

$this->logfile = '/home/strider/public_html/shop//includes/modules/shipping/upsxml.log';


You also need to create the file in the OSCommerce File Manager, this is very straightforward.


Once you run a shipping quote then the log will show some data.



So now that I did the above I ran one shipping quote and the log file returned results. The results are in line with the results I'm seeing except that they are all $5 less than what the OSCommerce page is displaying. However, I do have the "One Time Pickup" setting checked for the Pickup Method so UPSXML may be adding $5 for that (can anyone confirm?). For reference, when logged into UPS.com and using the exact same address and settings I am getting a quote of ~$20 versus the $29.57 quote I am getting from OSCommerce/UPSXML (choosing UPS Ground on both). Please also note that I am NOT using dimensional support yet. If someone thinks that this is the problem, please let me know :)


If someone can please explain to me what this means I would greatly appreciate it. I would like to know if this means I have to contact UPS in order to get them to start returning correctly discounted rates (this is what I believe). I have included the complete log file below (our UPS login information has been purposely removed so as not to broadcast it to the internet). I feel like I am very close here. Thanks to Jan for the helpful responses and anyone else that can shed some light on my issue. After the below UPSXML log results I have included a copy of my UPSXML settings:



DATE AND TIME: 2009-09-28 13:55:04

UPS URL: https://www.ups.com:443/ups.app/xml/Rate

UPS REQUEST: <?xml version="1.0"?>

<AccessRequest xml:lang="en-US">





<?xml version="1.0"?>

<RatingServiceSelectionRequest xml:lang="en-US">



<CustomerContext>Rating and Service</CustomerContext>













<City>Costa Mesa</City>








<City>Huntington Beach</City>
































UPS RESPONSE: <?xml version="1.0"?>

<RatingServiceSelectionResponse><Response><TransactionReference><CustomerContext>Rating and Service</CustomerContext><XpciVersion>1.0001</XpciVersion></TransactionReference><ResponseStatusCode>1</ResponseStatusCode><ResponseStatusDescription>Success</ResponseStatusDescription></Response><RatedShipment><Service><Code>03</Code></Service><RatedShipmentWarning>Your invoice may vary from the displayed reference rates</RatedShipmentWarning><BillingWeight><UnitOfMeasurement><Code>LBS</Code></UnitOfMeasurement><Weight>58.0</Weight></BillingWeight><TransportationCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>24.57</MonetaryValue></TransportationCharges><ServiceOptionsCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>0.00</MonetaryValue></ServiceOptionsCharges><TotalCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>24.57</MonetaryValue></TotalCharges><GuaranteedDaysToDelivery/><ScheduledDeliveryTime/><RatedPackage><TransportationCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>24.57</MonetaryValue></TransportationCharges><ServiceOptionsCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>0.00</MonetaryValue></ServiceOptionsCharges><TotalCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>24.57</MonetaryValue></TotalCharges><Weight>58.0</Weight><BillingWeight><UnitOfMeasurement><Code>LBS</Code></UnitOfMeasurement><Weight>58.0</Weight></BillingWeight></RatedPackage></RatedShipment><RatedShipment><Service><Code>12</Code></Service><RatedShipmentWarning>Your invoice may vary from the displayed reference rates</RatedShipmentWarning><BillingWeight><UnitOfMeasurement><Code>LBS</Code></UnitOfMeasurement><Weight>58.0</Weight></BillingWeight><TransportationCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>48.58</MonetaryValue></TransportationCharges><ServiceOptionsCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>0.00</MonetaryValue></ServiceOptionsCharges><TotalCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>48.58</MonetaryValue></TotalCharges><GuaranteedDaysToDelivery>3</GuaranteedDaysToDelivery><ScheduledDeliveryTime/><RatedPackage><TransportationCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>48.58</MonetaryValue></TransportationCharges><ServiceOptionsCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>0.00</MonetaryValue></ServiceOptionsCharges><TotalCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>48.58</MonetaryValue></TotalCharges><Weight>58.0</Weight><BillingWeight><UnitOfMeasurement><Code>LBS</Code></UnitOfMeasurement><Weight>58.0</Weight></BillingWeight></RatedPackage></RatedShipment><RatedShipment><Service><Code>59</Code></Service><RatedShipmentWarning>Your invoice may vary from the displayed reference rates</RatedShipmentWarning><BillingWeight><UnitOfMeasurement><Code>LBS</Code></UnitOfMeasurement><Weight>58.0</Weight></BillingWeight><TransportationCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>73.59</MonetaryValue></TransportationCharges><ServiceOptionsCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>0.00</MonetaryValue></ServiceOptionsCharges><TotalCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>73.59</MonetaryValue></TotalCharges><GuaranteedDaysToDelivery>2</GuaranteedDaysToDelivery><ScheduledDeliveryTime>10:30 A.M.</ScheduledDeliveryTime><RatedPackage><TransportationCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>73.59</MonetaryValue></TransportationCharges><ServiceOptionsCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>0.00</MonetaryValue></ServiceOptionsCharges><TotalCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>73.59</MonetaryValue></TotalCharges><Weight>58.0</Weight><BillingWeight><UnitOfMeasurement><Code>LBS</Code></UnitOfMeasurement><Weight>58.0</Weight></BillingWeight></RatedPackage></RatedShipment><RatedShipment><Service><Code>02</Code></Service><RatedShipmentWarning>Your invoice may vary from the displayed reference rates</RatedShipmentWarning><BillingWeight><UnitOfMeasurement><Code>LBS</Code></UnitOfMeasurement><Weight>58.0</Weight></BillingWeight><TransportationCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>63.99</MonetaryValue></TransportationCharges><ServiceOptionsCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>0.00</MonetaryValue></ServiceOptionsCharges><TotalCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>63.99</MonetaryValue></TotalCharges><GuaranteedDaysToDelivery>2</GuaranteedDaysToDelivery><ScheduledDeliveryTime/><RatedPackage><TransportationCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>63.99</MonetaryValue></TransportationCharges><ServiceOptionsCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>0.00</MonetaryValue></ServiceOptionsCharges><TotalCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>63.99</MonetaryValue></TotalCharges><Weight>58.0</Weight><BillingWeight><UnitOfMeasurement><Code>LBS</Code></UnitOfMeasurement><Weight>58.0</Weight></BillingWeight></RatedPackage></RatedShipment><RatedShipment><Service><Code>13</Code></Service><RatedShipmentWarning>Your invoice may vary from the displayed reference rates</RatedShipmentWarning><BillingWeight><UnitOfMeasurement><Code>LBS</Code></UnitOfMeasurement><Weight>58.0</Weight></BillingWeight><TransportationCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>84.87</MonetaryValue></TransportationCharges><ServiceOptionsCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>0.00</MonetaryValue></ServiceOptionsCharges><TotalCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>84.87</MonetaryValue></TotalCharges><GuaranteedDaysToDelivery>1</GuaranteedDaysToDelivery><ScheduledDeliveryTime>3:00 P.M.</ScheduledDeliveryTime><RatedPackage><TransportationCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>84.87</MonetaryValue></TransportationCharges><ServiceOptionsCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>0.00</MonetaryValue></ServiceOptionsCharges><TotalCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>84.87</MonetaryValue></TotalCharges><Weight>58.0</Weight><BillingWeight><UnitOfMeasurement><Code>LBS</Code></UnitOfMeasurement><Weight>58.0</Weight></BillingWeight></RatedPackage></RatedShipment><RatedShipment><Service><Code>14</Code></Service><RatedShipmentWarning>Your invoice may vary from the displayed reference rates</RatedShipmentWarning><BillingWeight><UnitOfMeasurement><Code>LBS</Code></UnitOfMeasurement><Weight>58.0</Weight></BillingWeight><TransportationCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>134.51</MonetaryValue></TransportationCharges><ServiceOptionsCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>0.00</MonetaryValue></ServiceOptionsCharges><TotalCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>134.51</MonetaryValue></TotalCharges><GuaranteedDaysToDelivery>1</GuaranteedDaysToDelivery><ScheduledDeliveryTime>8:00 A.M.</ScheduledDeliveryTime><RatedPackage><TransportationCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>134.51</MonetaryValue></TransportationCharges><ServiceOptionsCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>0.00</MonetaryValue></ServiceOptionsCharges><TotalCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>134.51</MonetaryValue></TotalCharges><Weight>58.0</Weight><BillingWeight><UnitOfMeasurement><Code>LBS</Code></UnitOfMeasurement><Weight>58.0</Weight></BillingWeight></RatedPackage></RatedShipment><RatedShipment><Service><Code>01</Code></Service><RatedShipmentWarning>Your invoice may vary from the displayed reference rates</RatedShipmentWarning><BillingWeight><UnitOfMeasurement><Code>LBS</Code></UnitOfMeasurement><Weight>58.0</Weight></BillingWeight><TransportationCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>101.81</MonetaryValue></TransportationCharges><ServiceOptionsCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>0.00</MonetaryValue></ServiceOptionsCharges><TotalCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>101.81</MonetaryValue></TotalCharges><GuaranteedDaysToDelivery>1</GuaranteedDaysToDelivery><ScheduledDeliveryTime>10:30 A.M.</ScheduledDeliveryTime><RatedPackage><TransportationCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>101.81</MonetaryValue></TransportationCharges><ServiceOptionsCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>0.00</MonetaryValue></ServiceOptionsCharges><TotalCharges><CurrencyCode>USD</CurrencyCode><MonetaryValue>101.81</MonetaryValue></TotalCharges><Weight>58.0</Weight><BillingWeight><UnitOfMeasurement><Code>LBS</Code></UnitOfMeasurement><Weight>58.0</Weight></BillingWeight></RatedPackage></RatedShipment></RatingServiceSelectionResponse>


UPS XML Settings:

United Parcel Service (XML)


Enable UPS Shipping



UPS Rates Access Key



UPS Rates Username



UPS Rates Password



Pickup Method

One Time Pickup


Packaging Type



Customer Classification Code



Shipping Origin

US Origin


Origin City

Costa Mesa


Origin State/Province



Origin Country



Origin Zip/Postal Code



Test or Production Mode



Quote Type



Negotiated rates



UPS Account Number



Manual Negotiated Rate



Handling Type

Flat Fee


Handling Fee



Enable Insurance



UPS Currency Code



Tax Class



Shipping Zone



Sort order of display.



Disallowed Shipping Methods

Worldwide Express, Worldwide Express Plus, Worldwide Expedited, Next Day Air Saver, Next Day Air Early A.M., Expedited, 2nd Day Air A.M., Saver, Express Early A.M., Express Plus, Today Standard, Today Dedicated Courier, Today Intercity, Today Express, Today Express Saver


Shipping Delay



Email UPS errors



Time in Transit View Type



Display Weight


Edited by muellerizedsales



Link to comment
Share on other sites

Okay, well I've had lots of views but no ideas. Maybe adding a little more information will help :)


Below I've got pricing from UPS.com vs the UPSXML returns to a much further away address (Pennsylvania and we are located in Southern California) for the exact same package as in the above example:



Ground = $50.63

3 Day Select = $119.58

2nd Day Air = $178.51



Ground = $68.86

3 Day Select = $149.55

2nd Day Air = $226.46


Amount OSCommerce/UPSXML is over the UPS.com rates:

Ground = +18.23

3 Day Select = +29.97

2nd Day Air = +47.95


As you can see there is a rather large discrepancy in shipping rates that only gets worse the further away we are shipping something.


I have the handling fee removed as well as ANY other additional charges in UPSXML. It appears that it is returning rates from UPS but they are just a lot higher. Does this mean that perhaps my access key is not functional? I don't see in the results that it specifically states whether the returned rates are normal or discounted.


Please help :(



Link to comment
Share on other sites

Is the quote that you are comparing to also One Time Pickup? I find that unusual for a company with negotiated rates. Try both quotes using the normal daily pickup and see if that matches.


The only other thing I can think of is that UPSXML is not picking up your negotiated rates and is using the standard rate. You could try comparing to a quote without the negotiated rates and see if taht matches.




See my profile for a list of my addons and ways to get support.

Link to comment
Share on other sites

Is the quote that you are comparing to also One Time Pickup? I find that unusual for a company with negotiated rates. Try both quotes using the normal daily pickup and see if that matches.


The only other thing I can think of is that UPSXML is not picking up your negotiated rates and is using the standard rate. You could try comparing to a quote without the negotiated rates and see if that matches.





Thanks for the reply, Jim.


I was indeed comparing One Time Pickup to One Time Pickup.


On a whim I decided to compare the supposedly negotiated rates that UPSXML (for a One Time Pickup, which costs roughly $4 normally) is returning with a non-negotiated cost estimate via the UPS.com website while NOT logged in with my UPS account.


After running the numbers for shipments near and far, all the numbers line up almost exactly (with the UPSXML rates roughly $4 higher every single time). So it appears that the response UPSXML is getting from the UPS Rates service is not a negotiated rate after all (in my case).


I guess the only remaining three possible causes are the following:

1. My account information is not inputted correctly in UPSXML or UPSXML is somehow garbling that information when sending it to the UPS Rates server.

2. UPS Rates is not recognizing my account information as valid and thus returning non-negotiated rates.

3. OSCommerce hates me. :blush:


Any ideas from anyone else?


Fortunately, I think I'd be content launching with essentially non-negotiated rates (as that would cover enough markup for my initial purposes), but I really would prefer in the future to be able to return negotiated rates and then mark it up with the various settings in UPSXML as appropriate.


Again, any suggestions would be greatly appreciated :)



Link to comment
Share on other sites

  • 1 month later...

Any ideas from anyone else?


I received an e-mail today from a member who was having similar trouble. It actually helped me solve my problem (sort of). The relevant part of the e-mail is copied below:


I saw your post on the OSC forum concerning the UPS shipping prices. Were you able to resolve your problem? I tried to reply in the forum, but wasn't successful. I have been working on that module for my customer's site which is my first OSC site. From what I read in your post, I think you might get satisfaction by changing to "one time pickup" to "daily pickup". I think that is the key they use to indicate a special rate. I also found a difference in whether I selected "commercial" or "residential". Since this is only a quote, I just changed configuration settings in OSC until I got a quote sufficiently close to the cost I get when I go to actually get a shipping label from UPS.


I changed my OSCommerce UPSXML settings as follows:


Pickup Method changed from "One Time Pickup" to "Daily Pickup"

Customer Classification Code changed from "03" to "01"


Once I changed those settings and re-tested shipping with a comparison between OSCommerce/UPSXML and the UPS.com website (logged in for negotiated rates) WITHOUT a one-time pick up selected on the UPS.com website, I got essentially the same rates returned (off by only a dollar or two at worst even on a $45 dollar shipment). I chalk this up to the fact that I'm not even passing dimension information to UPS via UPSXML (yet) so I am very satisfied with this. While I would prefer to be able to get negotiated rates including a one time pickup via OSC/UPSXML, this is even better than I expected versus my last post. Indeed once we are shipping a lot we will probably have a daily pickup anyway.


Thanks to the community, you guys rock! Hope this helps someone else :)



Link to comment
Share on other sites

  • 2 months later...

Yea i been racking my head on this for some time. If i click on the negoated rates i don't even get a responce when i have my site set to show the rates after adding items to cart..


If anyone knows the fix i would apreciate it.

Link to comment
Share on other sites

  • 5 years later...

Not that this will help a long-since dead thread OP, but for anyone who stumbles across this while looking for a solution:



However, I do have the "One Time Pickup" setting checked for the Pickup Method so UPSXML may be adding $5 for that (can anyone confirm?).


In the config portion of that post, your handling fee is set to "flat" with "5" in the next field, so your site is adding $5 to each quote for handling.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...