> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://developer-stage.shipbob.dev/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://developer-stage.shipbob.dev/_mcp/server.

# Estimate Delivery Date


POST https://sandbox-api.shipbob.com/2026-07/order:estimateDeliveryDate
Content-Type: application/json

Returns an estimated delivery date for a given destination and set of line items. The destination address must always include `zip_code` and `country`. The flow is auto-detected from the request shape: an address with only `zip_code` and `country` plus exactly one line item is treated as the Product Details Page (PDP) flow; a full address with one or more line items is treated as the Checkout flow.


Reference: https://developer-stage.shipbob.dev/api/orders/estimate-delivery-date

## Authentication

- `Authorization` header (bearer token, required) — Authentication using Personal Access Token (PAT) token
- `Authorization` header (bearer token, required) — OAuth2 authentication using JWT tokens

## Request

### Headers

- `x_correlation_id` (string, optional) — Optional caller-supplied correlation id (UUID) echoed back in the response and logs for end-to-end request tracing. If omitted, the request is still processed; supplying one makes it easier to correlate this call across ShipBob systems.

### Body (application/json)

- `destination_address` (object, required) — Destination address for a POST /order:estimate-delivery-date request.
  - `country` (string, required) — ISO 3166-1 alpha-2 country code (e.g. "US"). Required for both PDP and Checkout flows.
  - `zip_code` (string, required) — Postal/ZIP code. Required for both PDP and Checkout flows.
  - `address1` (string, optional, nullable) — Street address line 1. Required for Checkout flow; omit for PDP flow.
  - `address2` (string, optional, nullable) — Optional street address line 2 (suite, unit, etc.).
  - `city` (string, optional, nullable) — City. Required for Checkout flow; omit for PDP flow.
  - `state` (string, optional, nullable) — State or province code (e.g. "IL"). Required for Checkout flow; omit for PDP flow.
- `line_items` (list of object, required) — The items to estimate. For PDP flow, exactly one item is required. For Checkout flow, one or more items are required. Each item must supply either `inventory_id` or `sku`.
  - `inventory_id` (integer, optional, nullable) — ShipBob inventory ID. Provide this or `sku`, not both.
  - `quantity` (integer, optional, nullable) — Optional. Quantity of this item. Must be greater than zero when specified.
  - `sku` (string, optional, nullable) — Merchant SKU. Provide this or `inventory_id`, not both.
- `reference_id` (string, optional, nullable) — Optional. Caller-supplied correlation identifier echoed back in the response.

## Response

### 200

OK: one of: full success (estimates populated, errors empty), partial success (both populated), or system-can't-fulfill (empty estimates + one ApiError in errors[]).

- `destination_time_zone` (string, optional, nullable) — IANA time-zone id of the destination (e.g. America/New_York), best-effort. Serialized as destination_time_zone. Null when it can't be resolved (non-US destination, unknown zip, or lookup failure) — callers must treat it as optional.
- `errors` (list of object, optional) — Errors encountered while computing partial results. Empty on a fully successful response.
  - `code` (enum, optional) — Machine-readable error code surfaced by FulfillmentEstimator endpoints. See the description next to each value below for what it means.
    - Allowed values: `AMBIGUOUS_FLOW`, `MISSING_REQUIRED_FIELDS`, `INVALID_LINE_ITEM`, `INVALID_QUANTITY`, `INVALID_MERCHANT_ID`, `NO_FULFILLMENT_CENTER_AVAILABLE`, `INVENTORY_NOT_FOUND`, `INVENTORY_NOT_MEASURED`, `WEIGHT_LIMIT_EXCEEDED`, `PACKAGE_SELECTION_FAILED`, `NO_SHIPPING_SERVICES_AVAILABLE`, `EDD_LOOKUP_FAILED`, `DEPENDENCY_TIMEOUT`, `DEPENDENCY_UNAVAILABLE`
  - `context` (map from string to any, optional) — Optional structured context (key/value pairs) with additional detail about the error.
  - `correlation_id` (string, optional, nullable) — Correlation identifier for this error, for tracing the failure across logs. May be null.
  - `description` (string, optional, nullable) — Human-readable explanation of the error. May be null when the code is self-explanatory.
- `estimates` (list of object, optional) — The list of estimates, one per eligible shipping service and fulfillment center combination. Empty when no fulfillment center is available for a PDP request.
  - `delivery_date` (datetime, optional, nullable) — Estimated delivery date in UTC. Null if the EDD service was unavailable or could not determine a date for this shipping service and fulfillment center. A null value does not block the response — other estimates may still have dates.
  - `location` (object, optional) — Fulfillment center (location) reference in an EDD response estimate.
    - `id` (integer, optional) — ShipBob fulfillment center (location) identifier.
    - `name` (string, optional, nullable) — Display name of the fulfillment center.
  - `measurements` (object, optional) — Package measurements for a POST /order:estimate-delivery-date Checkout estimate. Null on the parent estimate for PDP responses.
    - `depth_in` (double, optional, nullable) — Estimated package depth (height) in inches.
    - `length_in` (double, optional, nullable) — Estimated package length in inches.
    - `total_weight_oz` (double, optional, nullable) — Estimated total package weight in ounces.
    - `width_in` (double, optional, nullable) — Estimated package width in inches.
  - `order_by_date` (datetime, optional, nullable) — Latest UTC time the order must be placed to meet `delivery_date`. Derived from the fulfillment center's daily cutoff time and timezone. Null when `delivery_date` is null.
  - `packing_material` (string, optional, nullable) — Checkout only. Packing material used for the shipment (e.g. "Box", "Poly Mailer").
  - `shipping_cost` (object, optional) — A monetary value with its ISO 4217 currency code.
    - `currency_code` (string, optional, nullable) — ISO 4217 three-letter currency code (e.g. "USD"). Defaults to "USD".
    - `value` (double, optional) — The monetary amount.
  - `shipping_service` (object, optional) — Shipping service reference in an EDD response estimate.
    - `id` (integer, optional) — ShipBob shipping service (ship option) identifier.
    - `is_promise` (boolean, optional) — True when this service is a Promise (delivery-date-backed) shipping service.
    - `name` (string, optional, nullable) — Display name of the shipping service (e.g. "Standard", "2-Day").
    - `shipping_methods` (list of string, optional) — Merchant-published ShippingMethod values from ShipOptionUserMapping for this (merchant, ShipOptionId), ordered by MappingId DESC (newest first) and capped at ApplicationSettings.ShippingMethodsLimit (default 20). Empty array when the merchant has no active mapping row for this service (e.g. default services added unconditionally in Precise; promise services exposed in Approximate without a per-merchant mapping).
- `reference_id` (string, optional, nullable) — Echoed from the request's ReferenceId for caller correlation. Null if not supplied.

## Examples

**Request**

```json
{
  "destination_address": {
    "country": "US",
    "zip_code": "60601",
    "address1": "123 Main St",
    "address2": null,
    "city": "Chicago",
    "state": "IL"
  },
  "line_items": [
    {
      "inventory_id": 12345,
      "quantity": 2,
      "sku": null
    }
  ],
  "reference_id": "order-abc-123"
}
```

**Response**

```json
{
  "destination_time_zone": "America/Chicago",
  "errors": [],
  "estimates": [
    {
      "delivery_date": "2026-04-28T00:00:00+00:00",
      "location": {
        "id": 305,
        "name": "Bolingbrook, IL"
      },
      "measurements": {
        "depth_in": 4,
        "length_in": 10,
        "total_weight_oz": 16,
        "width_in": 6
      },
      "order_by_date": "2026-04-24T20:00:00+00:00",
      "packing_material": "Box",
      "shipping_cost": {
        "currency_code": "USD",
        "value": 8.42
      },
      "shipping_service": {
        "id": 12,
        "is_promise": true,
        "name": "UPS Ground",
        "shipping_methods": [
          "Standard",
          "GroundShip"
        ]
      }
    }
  ],
  "reference_id": "order-abc-123"
}
```

**SDK Code**

```python default
import requests

url = "https://sandbox-api.shipbob.com/2026-07/order:estimateDeliveryDate"

payload = {
    "destination_address": {
        "country": "US",
        "zip_code": "60601",
        "address1": "123 Main St",
        "address2": None,
        "city": "Chicago",
        "state": "IL"
    },
    "line_items": [
        {
            "inventory_id": 12345,
            "quantity": 2,
            "sku": None
        }
    ],
    "reference_id": "order-abc-123"
}
headers = {
    "x_correlation_id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
    "Authorization": "Bearer <token>",
    "Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
```

```javascript default
const url = 'https://sandbox-api.shipbob.com/2026-07/order:estimateDeliveryDate';
const options = {
  method: 'POST',
  headers: {
    x_correlation_id: '497f6eca-6276-4993-bfeb-53cbbbba6f08',
    Authorization: 'Bearer <token>',
    'Content-Type': 'application/json'
  },
  body: '{"destination_address":{"country":"US","zip_code":"60601","address1":"123 Main St","address2":null,"city":"Chicago","state":"IL"},"line_items":[{"inventory_id":12345,"quantity":2,"sku":null}],"reference_id":"order-abc-123"}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go default
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://sandbox-api.shipbob.com/2026-07/order:estimateDeliveryDate"

	payload := strings.NewReader("{\n  \"destination_address\": {\n    \"country\": \"US\",\n    \"zip_code\": \"60601\",\n    \"address1\": \"123 Main St\",\n    \"address2\": null,\n    \"city\": \"Chicago\",\n    \"state\": \"IL\"\n  },\n  \"line_items\": [\n    {\n      \"inventory_id\": 12345,\n      \"quantity\": 2,\n      \"sku\": null\n    }\n  ],\n  \"reference_id\": \"order-abc-123\"\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("x_correlation_id", "497f6eca-6276-4993-bfeb-53cbbbba6f08")
	req.Header.Add("Authorization", "Bearer <token>")
	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby default
require 'uri'
require 'net/http'

url = URI("https://sandbox-api.shipbob.com/2026-07/order:estimateDeliveryDate")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["x_correlation_id"] = '497f6eca-6276-4993-bfeb-53cbbbba6f08'
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n  \"destination_address\": {\n    \"country\": \"US\",\n    \"zip_code\": \"60601\",\n    \"address1\": \"123 Main St\",\n    \"address2\": null,\n    \"city\": \"Chicago\",\n    \"state\": \"IL\"\n  },\n  \"line_items\": [\n    {\n      \"inventory_id\": 12345,\n      \"quantity\": 2,\n      \"sku\": null\n    }\n  ],\n  \"reference_id\": \"order-abc-123\"\n}"

response = http.request(request)
puts response.read_body
```

```java default
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.post("https://sandbox-api.shipbob.com/2026-07/order:estimateDeliveryDate")
  .header("x_correlation_id", "497f6eca-6276-4993-bfeb-53cbbbba6f08")
  .header("Authorization", "Bearer <token>")
  .header("Content-Type", "application/json")
  .body("{\n  \"destination_address\": {\n    \"country\": \"US\",\n    \"zip_code\": \"60601\",\n    \"address1\": \"123 Main St\",\n    \"address2\": null,\n    \"city\": \"Chicago\",\n    \"state\": \"IL\"\n  },\n  \"line_items\": [\n    {\n      \"inventory_id\": 12345,\n      \"quantity\": 2,\n      \"sku\": null\n    }\n  ],\n  \"reference_id\": \"order-abc-123\"\n}")
  .asString();
```

```php default
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://sandbox-api.shipbob.com/2026-07/order:estimateDeliveryDate', [
  'body' => '{
  "destination_address": {
    "country": "US",
    "zip_code": "60601",
    "address1": "123 Main St",
    "address2": null,
    "city": "Chicago",
    "state": "IL"
  },
  "line_items": [
    {
      "inventory_id": 12345,
      "quantity": 2,
      "sku": null
    }
  ],
  "reference_id": "order-abc-123"
}',
  'headers' => [
    'Authorization' => 'Bearer <token>',
    'Content-Type' => 'application/json',
    'x_correlation_id' => '497f6eca-6276-4993-bfeb-53cbbbba6f08',
  ],
]);

echo $response->getBody();
```

```csharp default
using RestSharp;

var client = new RestClient("https://sandbox-api.shipbob.com/2026-07/order:estimateDeliveryDate");
var request = new RestRequest(Method.POST);
request.AddHeader("x_correlation_id", "497f6eca-6276-4993-bfeb-53cbbbba6f08");
request.AddHeader("Authorization", "Bearer <token>");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{\n  \"destination_address\": {\n    \"country\": \"US\",\n    \"zip_code\": \"60601\",\n    \"address1\": \"123 Main St\",\n    \"address2\": null,\n    \"city\": \"Chicago\",\n    \"state\": \"IL\"\n  },\n  \"line_items\": [\n    {\n      \"inventory_id\": 12345,\n      \"quantity\": 2,\n      \"sku\": null\n    }\n  ],\n  \"reference_id\": \"order-abc-123\"\n}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift default
import Foundation

let headers = [
  "x_correlation_id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  "Authorization": "Bearer <token>",
  "Content-Type": "application/json"
]
let parameters = [
  "destination_address": [
    "country": "US",
    "zip_code": "60601",
    "address1": "123 Main St",
    "address2": ,
    "city": "Chicago",
    "state": "IL"
  ],
  "line_items": [
    [
      "inventory_id": 12345,
      "quantity": 2,
      "sku": 
    ]
  ],
  "reference_id": "order-abc-123"
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "https://sandbox-api.shipbob.com/2026-07/order:estimateDeliveryDate")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```