Compare Carrier Rates In One Request
Shop eligible USPS and UPS services with a single authenticated POST. Use the same ZIP-to-ZIP contract as the SyncShip Rate Browser.
Overview
The Rates API returns comparable quotes for a package between two postal codes. Responses include carrier, service, amount, and optional delivery estimates so you can present options or auto-select the cheapest eligible rate.
- POST /api/v1/shipments/rates
- Filter by carrier, service, or delivery speed
- Residential and commercial surcharges included
- Response time depends on request type and downstream carrier services
Authentication
Authenticate every request with a Bearer token issued for your SyncShip developer account.
Endpoint
Send a JSON body describing origin, destination, and package details. The service returns the set of available rates for enabled carriers on your account.
/api/v1/shipments/ratesRequest
Required fields cover origin ZIP, destination ZIP, and weight. Dimensions and carrier filters are optional but improve quote accuracy.
| Parameter | Type | Required | Description |
|---|---|---|---|
| fromPostalCode | string | Yes | Origin postal code (ship-from). |
| toPostalCode | string | Yes | Destination postal code (ship-to). |
| toCountry | string | No | ISO destination country. Defaults to US when omitted. |
| residential | boolean | No | Whether the destination is residential. Affects surcharges. |
| weightLb | number | Yes | Package weight in pounds. |
| weightOz | number | Yes | Additional ounces beyond whole pounds. |
| length | number | No | Package length in inches. |
| width | number | No | Package width in inches. |
| height | number | No | Package height in inches. |
| packageType | string | No | Carrier package type when applicable (for example package). |
| carriers | string[] | No | Limit quotes to enabled SyncShip carriers such as usps or ups. |
Response
Successful responses include a source indicator, carrier coverage counts, and an array of rate objects. Amounts are returned in the account currency.
Example response
Errors
Standard HTTP status codes are used. Treat 4xx as client corrections and retry 429 with backoff.
401Missing or invalid API key.422Validation failed — check postal codes, weight, or dimensions.429Too many requests — retry with exponential backoff.
Next steps
After you can shop rates, continue with label purchase, event delivery, or the sandbox quickstart.