rate.quote
rate.quote (object $destination, object $items, object $methodInfo)
Request shipping and handling quotes based on a set of order items and a destination zip code.
[ { "sku": "product1", "qty": 1 }, { "sku": "product2", "qty": 3 } ]
{
"jsonrpc" : 2.0,
"id" : 1234,
"method" : "call",
"params" : [
"be1c13ed4e03f0ed7f1e4053dfff9658",
"rate.quote",
[
{
"country" : "US",
"region" : "NY",
"city" : "New York",
"street" : "11 Times Square",
"postcode" : "10036",
"company" : "Microsoft",
"classification" : "com"
},
[
{
"sku" : "product1",
"qty": 1
},
{
"sku" : "product2",
"qty" : 3
}
],
{
"methods" : "ups_03",
"signature_required" : "adult",
"saturday_delivery" : false,
"overbox" : false
}
]
]
}
{
"jsonrpc" : 2.0,
"id" : 1234,
"error" : null,
"result" : {
"rates" : [
{
"code" : "ups_03",
"description" : "UPS Ground",
"zone" : "002",
"days_in_transit" : "2",
"package_count" : 1,
"shipping_cost" : "17.23",
"shipping_cost_currency" : "USD",
"if_ordered_by" : "15:00:00",
"min_delivery_date" : "2017-02-05",
"max_delivery_date" : "2017-02-05",
"signature_fee" : "1.15",
"signature_fee_currency" : "USD",
"multiple_warehouses" : false,
"allocation" : [
{ "product1" : [{ "warehouse_id": 1, "qty": "1.000" }] },
{ "product2" : [{ "warehouse_id": 1, "qty": "3.000" }] }
]
}
],
"handling_cost" : "2.4",
"handling_cost_currency" : "USD"
}
}
rate.services
rate.services (int|null $warehouseId)
Get a list of the enabled shipping methods.
{
"jsonrpc" : 2.0,
"id" : 1234,
"method" : "call",
"params" : [
"c4d62bb4c368d8158b1221cd5f27a659",
"rate.services",
1
]
}
{
"jsonrpc" : 2.0,
"id" : 1234,
"result" : {
"external_ltl" : {
"title" : "LTL",
"carrier_code" : "external",
"service" : "ltl",
"rates_available" : false
},
"external_ltl_thirdparty" : {
"title" : "LTL - Third Party",
"carrier_code" : "external",
"service" : "ltl_thirdparty",
"rates_available" : false
},
"fedex_EUROPE_FIRST_INTERNATIONAL_PRIORITY" : {
"title" : "FedEx Europe First International Priority",
"carrier_code" : "fedex",
"service" : "EUROPE_FIRST_INTERNATIONAL_PRIORITY",
"rates_available" : true
},
"fedex_FEDEX_1_DAY_FREIGHT" : {
"title" : "FedEx 1 Day Freight",
"carrier_code" : "fedex",
"service" : "FEDEX_1_DAY_FREIGHT",
"rates_available" : true
},
"fedex_FEDEX_2_DAY" : {
"title" : "FedEx 2 Day",
"carrier_code" : "fedex",
"service" : "FEDEX_2_DAY",
"rates_available" : true
},
"ups_02" : {
"title" : "UPS 2nd Day Air",
"carrier_code" : "ups",
"service" : "02",
"rates_available" : true
},
"ups_03" : {
"title" : "UPS Ground",
"carrier_code" : "ups",
"service" : "03",
"rates_available" : true
},
"ups_07" : {
"title" : "UPS Worldwide Express",
"carrier_code" : "ups",
"service" : "07",
"rates_available" : true
}
}
}
Show Destination Properties
Show Method Information Properties
Show Rate Properties