#api #ups
Вопрос:
Добрый день!
Согласованные ставки возвращают слишком большие суммы по запросу API, но не по калькулятору затрат на сайте UPS. Вы можете увидеть это в ответе на тариф, согласованные тарифы слишком велики, чем общая сумма сборов.
URL-адрес производства: https://onlinetools.ups.com/rest/Rate
Когда я использовал тестовый URL (https://wwwcie.ups.com/rest/Rate) он возвращает нормальный, но не по производственному URL-адресу. Есть ли что-нибудь, что я пропустил?
Запрос на Оценку:
{
"UPSSecurity":{
"UsernameToken":{
"Username":"XXX",
"Password":"XXX"
},
"ServiceAccessToken":{
"AccessLicenseNumber":"XXX"
}
},
"RateRequest":{
"Request" : {
"RequestOption": "Shoptimeintransit"
},
"Shipment":
{
"ShipmentRatingOptions": {
"NegotiatedRatesIndicator" : "True",
"UserLevelDiscountIndicator" : "True"
},
"Shipper":{
"ShipperNumber":"XXX",
"Address":{
"AddressLine":"",
"City":"Fort Myers",
"StateProvinceCode":"FL",
"PostalCode":"33908-3083",
"CountryCode":"US"
}
},
"ShipTo":{
"Address":{
"AddressLine":"",
"City":"Fort Myers",
"StateProvinceCode":"FL",
"PostalCode":"33908",
"CountryCode":"US"
}
},
"ShipFrom":{
"Address":{
"AddressLine":"Quezon city",
"City":"Quezon",
"StateProvinceCode":"QC",
"PostalCode":"1101",
"CountryCode":"PH"
}
},
"Package":{
"PackagingType":{
"Code":"02"
},
"Dimensions":{
"UnitOfMeasurement":{
"Code":"CM"
},
"Length":"65",
"Width":"45",
"Height":"80"
},
"PackageWeight":{
"UnitOfMeasurement":{
"Code":"KGS"
},
"Weight":"25"
}
},
"DeliveryTimeInformation":
{
"PackageBillType":"03"
},
"ShipmentTotalWeight": {
"UnitOfMeasurement": {
"Code": "KGS"
},
"Weight": "25"
},
"InvoiceLineTotal" : {
"CurrencyCode":"USD",
"MonetaryValue": "1"
}
}
}
}
Скорость Отклика:
{
"RateResponse": {
"Response": {
"ResponseStatus": {
"Code": "1",
"Description": "Success"
},
"Alert": {
"Code": "110971",
"Description": "Your invoice may vary from the displayed reference rates"
},
"TransactionReference": ""
},
"RatedShipment": [
{
"Service": {
"Code": "54",
"Description": ""
},
"RatedShipmentAlert": {
"Code": "110971",
"Description": "Your invoice may vary from the displayed reference rates"
},
"BillingWeight": {
"UnitOfMeasurement": {
"Code": "KGS",
"Description": "Kilograms"
},
"Weight": "47.0"
},
"TransportationCharges": {
"CurrencyCode": "USD",
"MonetaryValue": "1142.63"
},
"ServiceOptionsCharges": {
"CurrencyCode": "USD",
"MonetaryValue": "0.00"
},
"TotalCharges": {
"CurrencyCode": "USD",
"MonetaryValue": "1142.63"
},
"NegotiatedRateCharges": {
"TotalCharge": {
"CurrencyCode": "USD",
"MonetaryValue": "8842.34"
}
},
"RatedPackage": {
"TransportationCharges": {
"CurrencyCode": "USD",
"MonetaryValue": "0.00"
},
"ServiceOptionsCharges": {
"CurrencyCode": "USD",
"MonetaryValue": "0.00"
},
"TotalCharges": {
"CurrencyCode": "USD",
"MonetaryValue": "0.00"
},
"Weight": "25.0",
"BillingWeight": {
"UnitOfMeasurement": {
"Code": "KGS",
"Description": "Kilograms"
},
"Weight": "47.0"
}
},
"TimeInTransit": {
"PickupDate": "20211005",
"PackageBillType": "03",
"AutoDutyCode": "09",
"Disclaimer": "All services are guaranteed if shipment is paid for in full by a payee in the United States. Services listed as guaranteed are backed by a money-back guarantee for transportation charges only. See Terms and Conditions in the Service Guide for details. Certain commodities and high value shipments may require additional transit time for customs clearance.",
"ServiceSummary": {
"Service": {
"Description": "UPS Worldwide Express Plus"
},
"EstimatedArrival": {
"Arrival": {
"Date": "20211007",
"Time": "090000"
},
"BusinessDaysInTransit": "2",
"Pickup": {
"Date": "20211005",
"Time": "173000"
},
"DayOfWeek": "THU",
"CustomerCenterCutoff": "150000",
"TotalTransitDays": "2"
},
"GuaranteedIndicator": "",
"SaturdayDelivery": "0"
}
}
}
]
}
}
I have tried different settings on request but I still got the same negotiated rates on production URL.
Thanks!