delivery_predictions

Predict delivery dates

Changed on

Predict delivery dates for one or more carrier and service combinations on a single lane, using ShipStation's delivery prediction model rather than the estimate quoted by the carrier.

The prediction stands on its own: this endpoint does not price the shipment, create a shipment or a label, and nothing it returns is stored. Send the origin and destination once and list every carrier and service combination you want predicted for that lane.

A requested combination comes back as an entry in delivery_predictions or as an entry in warnings, never both. A combination the model has no coverage for becomes a warning, so a response where nothing is supported is still a 200 with an empty delivery_predictions array. A combination the model returns nothing usable for is in neither array. Combinations are matched by carrier_code and service_code rather than by position, and are returned as the model reports them rather than echoed back.

There is no limit you need to manage on your side: a request with more combinations than the model accepts in one call is split across several calls automatically, and none are dropped.

post/v1/delivery_predictions

Request

  • Base URL: https://api.shipengine.com
  • URL: https://api.shipengine.com/v1/delivery_predictions
  • Auth: API key in header API-Key

Request body

from_country_codestring required

The ISO 3166-1 alpha-2 country code of the origin.

from_postal_codestring required

The postal code of the origin.

to_country_codestring required

The ISO 3166-1 alpha-2 country code of the destination.

to_postal_codestring required

The postal code of the destination.

ship_datestring date

The date the shipment leaves the origin. Defaults to today when omitted. A date in the past is rejected.

Example request

{
  "from_country_code": "US",
  "from_postal_code": "78701",
  "to_country_code": "US",
  "to_postal_code": "90210",
  "ship_date": "2026-07-01",
  "delivery_options": [
    {
      "carrier_details": {
        "carrier_code": "ups",
        "service_code": "ups_ground"
      }
    }
  ]
}

Response

The predictions for the requested lane, and a warning for every combination that could not be predicted.

Example response

{
  "delivery_predictions": [
    {
      "ship_date": "2026-07-01",
      "delivery_date": "2026-07-04",
      "confidence_level": "high",
      "carrier_details": {
        "carrier_code": "ups",
        "service_code": "ups_ground"
      }
    }
  ],
  "warnings": [
    {
      "carrier_details": {
        "carrier_code": "ups",
        "service_code": "ups_ground"
      },
      "message": "Carrier and service combination is unsupported."
    }
  ]
}

Changes