Closed danFbach closed 4 months ago
Correction, the oldest occurrence i have of this error is 03/19/2024 10:28:34 PM CST
Also, just checked their API Updates and there is nothing past January...but they don't always post changes.
I think this is also being brought up on the latest comment of #6712
In reference to that comment, they suggest just removing the Alert
object from RateResponse_Response
.
Of course this will work, but is not an ideal solution.
Changing it from
public System.Collections.Generic.ICollection<Response_Alert> Alert { get; set; }
to
public Response_Alert Alert { get; set; }
Also allows it to work.
https://developer.ups.com/api/reference?loc=en_US#operation/Rate
Official UPS documentation still defines Alert
as an array of objects - so the existing implementation should work, and my changes should not fix it.
I've got a ticket open with UPS to get some answers.
It can be EITHER a single object OR an array. wtf. not sure how a deserializer can compensate for that
In fact, multiple fields can be arrays or single objects - probably other fields that aren't listed here too.
If the response contains <= 1 result, it just returns the single object instead of an array with one object.
Hi @danFbach. Thank you for your help. We also don’t know how this is possible, but this is not the first such object that can have a dual structure in the new API. Therefore, we were forced to make our implementation of some fields, such as RateResponse_RatedShipment.RatedPackage. We will make the necessary changes soon
Closed #7119
@skoshelev @AndreiMaz
This plugin still having issue.
I getting error while RatedShipment property get as object from UPS response.
{ "RateResponse": { "Response": { "ResponseStatus": { "Code": "1", "Description": "Success" }, "Alert": [ { "Code": "113060", "Description": "The weight exceeds the limit for the UPS Letter/Envelope rate and will be rated using the weight." }, { "Code": "110971", "Description": "Your invoice may vary from the displayed reference rates" } ], "TransactionReference": { "CustomerContext": "testing", "TransactionIdentifier": "iewssoat24d2WM6mXBy9YL" } }, "RatedShipment": { "Service": { "Code": "65", "Description": "" }, "RatedShipmentAlert": [ { "Code": "113060", "Description": "The weight exceeds the limit for the UPS Letter/Envelope rate and will be rated using the weight." }, { "Code": "110971", "Description": "Your invoice may vary from the displayed reference rates" } ], "BillingWeight": { "UnitOfMeasurement": { "Code": "LBS", "Description": "Pounds" }, "Weight": "1.0" }, "TransportationCharges": { "CurrencyCode": "USD", "MonetaryValue": "126.36" }, "ServiceOptionsCharges": { "CurrencyCode": "USD", "MonetaryValue": "0.00" }, "TotalCharges": { "CurrencyCode": "USD", "MonetaryValue": "126.36" }, "NegotiatedRateCharges": { "TotalCharge": { "CurrencyCode": "USD", "MonetaryValue": "125.10" } }, "RatedPackage": [ { "TransportationCharges": { "CurrencyCode": "USD", "MonetaryValue": "0.00" }, "ServiceOptionsCharges": { "CurrencyCode": "USD", "MonetaryValue": "0.00" }, "TotalCharges": { "CurrencyCode": "USD", "MonetaryValue": "0.00" }, "Weight": "1.0", "BillingWeight": { "UnitOfMeasurement": { "Code": "LBS", "Description": "Pounds" }, "Weight": "1.0" } } ] } } }
Hi @sangeet-shah. This month, UPS updated both the API and documentation; according to the new specification, such problems should no longer exist. We have updated the code to use API version v2403.
Closed #7119
nopCommerce version: 4.60.6
Official nop UPS plugin is failing to retrieve rates. I believe this just started in the last day.
Here's the error log.
I'm guessing that the problem is occurring in
/API/Rates/RateClient.cs
in the methodprotected virtual async System.Threading.Tasks.Task<ObjectResponseResult<T>> ReadObjectResponseAsync<T>(...)
line 200 Not sure how much more i can debug on my own as this appears to be generated code