Get Rates
POST /rates — rate limit 60 / min
Returns one quote for every contract available for the given destination and packages. Use the contractCode of the chosen quote as serviceType when creating the shipment.
Request body
| Field | Type | Required | Description |
|---|---|---|---|
recipient.address.postalCode | string | Yes | Destination postal code |
recipient.address.countryCode | string | Yes | Destination country, ISO 3166-1 alpha-2 |
recipient.address.city | string | No | |
recipient.address.province | string | No | |
shipper.address | Address | No | Origin; default: the operational address of the account |
packages[] | Package[] | Yes | At least one. Each package has its own weight and dimensions |
packages[].weight | Weight | Yes | { "value", "units": "KG"|"G" } |
packages[].dimensions | Dimensions | Yes | { "length", "width", "height", "units": "CM"|"MM" } |
options.pickupFromAddress | boolean | No | Include the pickup surcharge |
options.cod | Money | No | Cash on delivery amount; type optionally selects the carrier COD code |
options.insurance | Money | No | Insured value |
Example
Request
{
"shipper": {
"address": { "postalCode": "20100", "countryCode": "IT" }
},
"recipient": {
"address": { "city": "Roma", "province": "RM", "postalCode": "00100", "countryCode": "IT" }
},
"packages": [
{ "weight": { "value": 3, "units": "KG" }, "dimensions": { "length": 30, "width": 20, "height": 10, "units": "CM" } }
],
"options": {
"cod": { "amount": 25.5, "currency": "EUR" },
"insurance": { "amount": 0, "currency": "EUR" }
}
}Response fields
Each item of data is one available contract:
| Field | Type | Description |
|---|---|---|
carrierCode, carrierName | string | Carrier |
contractCode | string | Pass it as serviceType to create the shipment. Encrypted for level-1 reseller contracts — pass as received |
contractName | string | Display name |
level, slave | integer, boolean | Contract level and reseller flag (see Carriers) |
price.total | number | Total price for this contract |
price.breakdown | object | weight, fuel, insurance, cod, services, extra, pickup components |
billableWeight | Weight | Weight the price is based on (the greater of real and volumetric) |
volumetricWeight | Weight | Volumetric weight computed by the carrier rule |
zone | string|null | Price-list zone matched by the destination |
cashOnDeliveryMethods | object | COD collection methods accepted by the contract (code → label) |
services[] | object[] | Accessory services available (serviceId, serviceName) |
logoUrl | string|null | Carrier logo |
Errors
| HTTP | code | When |
|---|---|---|
404 | not_found | No price list is associated to the account |
422 | validation_failed | Invalid payload |
An empty data array means no contract can serve this destination / package combination. Check the destination, the package limits of your contracts and whether the contracts are paused.
Last updated on