Aller au contenu principal

Create Delivery

POST /drive/v2/deliveries is the core endpoint used to create a parcel in DashLink. It is functionally identical to accepting a quote, except it does not allow a preview of the fee or serviceability beforehand.


When to use create delivery​

Use this endpoint instead of quotes when:

  • You already trust your serviceability logic
  • You don’t need to preview fees
  • You want to simplify your integration to a single step
  • You run a synchronous realtime workflow

Endpoint​

POST /drive/v2/deliveries


Request behavior​

The delivery creation call:

  • Creates an active parcel delivery
  • Generates or confirms the tracking code
  • Validates the full request payload
  • Triggers address correction
  • Returns a base64 shipping label
  • Initiates the delivery lifecycle

Request Fields​

A sample request and response found in the Create Delivery Example appendix.

FieldTypeRequirementDescription
external_delivery_idstringRequiredEmpty string signals DashLink to generate the code. Required if shipper-generated tracking codes are used. Must be 15–35 characters, unique, no leading zeros. Prefix must be DashLink-approved
order_fulfillment_methodstringRequiredMust be "parcel" for DashLink.
pickup_external_business_idstringRequiredString identifier for your business provided by DashLink.
origin_facility_idstringRequiredMerchant warehouse ID used for mid-mile routing provided by DashLink.
dropoff_addressstringRequiredFull comma-separated delivery address used for serviceability and fee checks.
pickup_business_namestringRequiredName of the business shipping the item; used in SMS communications and the tracking page.
dropoff_business_namestringRecommendedName of the business receiving the delivery, used to help Dashers identify the dropoff location.
dropoff_location.latintegerOptionalLatitude for precise navigation. Used only for routing, not fee validation and overrides geocoding.
dropoff_location.lngintegerOptionalLongitude for precise navigation. Overrides geocoding.
dropoff_phone_numberstringRequiredMust follow E.164 format (e.g. +16505555555). DashLink has the ability to default a support phone number when an invalid number is passed, please reach out to your representative if you would like this enabled.
dropoff_instructionsstringRecommendedInstructions to help Dashers successfully complete the delivery.
dropoff_contact_given_namestringRequiredRecipient first name.
dropoff_contact_family_namestringRequiredRecipient last name.
dropoff_contact_send_notificationsbooleanRecommendedDefaults to true. Indicates whether SMS notifications will be sent for this delivery.
customer_expected_slaobjectOptionalThe delivery date or time communicated to the customer (e.g., “Arrives by Apr 24”). This field may also be used as a signal that the order will be handed off at a later time (e.g., for future-dated shipments). It does not override the system-calculated delivery estimate and may be ignored if it is not operationally feasible.
expires_byobjectOptionalThe final date or time after which the order is no longer valid and should not be delivered. This acts as a hard cutoff for fulfillment. Contains either day (string, e.g., "2026-04-24") or timestamp fields.

Dropoff Address Components​

FieldTypeRequirementDescription
dropoff_address_components.street_addressstringRequiredStreet address line.
dropoff_address_components.sub_premisestringRecommendedApartment, suite, or unit number.
dropoff_address_components.citystringRequiredCity name.
dropoff_address_components.statestringRequired2-letter state code.
dropoff_address_components.zip_codestringRequiredZIP or postal code.
dropoff_address_components.countrystringRequiredCountry code (e.g. "US").

Order & Item Details​

FieldTypeRequirementDescription
order_valueinteger (cents)RecommendedSubtotal excluding tax/tip (e.g. $19.99 → 1999). Must be ≥ 0.
currencystringOptionalDefaults to USD. Currency code.
items[]arrayRequiredArray of Delivery Item objects (maximum 1 item).

Shipping Label Options​

FieldTypeRequirementDescription
shipping_label_config.label_formatstringRequiredThe file format of the label. Enum: "zpl" "pdf"
shipping_label_config.print_densitystringOptionalRequired when label_format is zpl. Must not be set when label_format is pdf. Enum: "203dpi" "300dpi"
shipping_label_config.label_sizestringRequiredThe size of the label. Value: "4x6"
shipping_label_metadata.internal_location_idstringOptionalInternal location ID for the shipping label.
shipping_label_metadata.label_business_namestringOptionalOptional brand or display name to print as the "business name" on the rendered shipping label. When set, replaces the business name stored on the parcel for label-rendering purposes only; the underlying business identity on the delivery is unchanged. Omit to print the stored business name.

Delivery Item Object​

FieldTypeRequirementDescription
items[].namestringRequiredName of the package or item.
items[].descriptionstringOptionalDescription of item contents.
items[].external_idstringOptionalShipper-provided metadata that will print on the label returned.
items[].quantityintegerRequiredQuantity of item (always 1 for parcel shipments).
items[].heightinteger (inches)RequiredHeight of package. Must be ≤ 36 inches.
items[].widthinteger (inches)RequiredWidth of package. Must be ≤ 36 inches.
items[].lengthinteger (inches)RequiredLength of package. Must be ≤ 36 inches.
items[].weightinteger (pounds)RequiredWeight of package. Must be ≤ 50 pounds.
items[].volumeinteger (cubic feet)OptionalVolume of package, (H × W × L) / 1728. Must be ≤ 6 cubic feet. If omitted, it's calculated from height, width, and length and the same limit applies.
items[].priceinteger (cents)OptionalPrice of item in lowest currency denomination.

Delivery Options​

FieldTypeRequirementDescription
contactless_dropoffbooleanRequiredDefaults to true. If true, Dasher takes photo at dropoff.
dropoff_requires_signaturebooleanRequiredDefaults to false. Requires recipient signature. Mutually exclusive with contactless_dropoff

Response Fields​

In addition to the create delivery request fields returned in the response, the fields below are either only sent in the response or possibly updated from the request inputs sent.

A sample request and response found in the Create Delivery Example appendix.

FieldTypeDescription
external_delivery_idstringEchoed unique delivery ID generated by the caller.
delivery_statusstringAlways "created" for this endpoint.
feeinteger (cents)Delivery fee in lowest currency denomination (e.g. $5.99 → 599).
fee_componentsarrayBreakdown of individual fee components that make up the total fee.
fee_components.typestringType of fee: "package_fee", "fuel_surcharge", or "delivery_area_surcharge".
fee_components.amountinteger (cents)Amount for this fee component in lowest currency denomination.
dropoff_addressstringFull comma-separated delivery address returned by geocoding.
dropoff_location.latintegerLatitude returned by geocoding for precise navigation.
dropoff_location.lngintegerLongitude returned by geocoding for precise navigation.
dropoff_address_components.street_addressstringGeocoded street address line.
dropoff_address_components.sub_premisestringGeocoded apartment, suite, or unit number.
dropoff_address_components.citystringGeocoded city name.
dropoff_address_components.statestringGeocoded 2-letter state code.
dropoff_address_components.zip_codestringGeocoded ZIP or postal code.
dropoff_address_components.countrystringGeocoded country code (e.g. "US").
updated_atstring (ISO-8601)Timestamp indicating when the delivery record was last updated.
pickup_time_estimatedstring (ISO-8601)Estimated pickup time, if available.
dropoff_time_estimatedstring (ISO-8601)Estimated delivery time, if available.
support_referencestringInternal DashLink support reference ID.
tracking_urlstringCustomer-facing tracking page URL.
shipping_label.label_formatstringLabel format (e.g. "zpl").
shipping_label.label_sizestringLabel size (e.g. "4x6").
shipping_label.print_densitystringPrint density (e.g. "203dpi").
shipping_label.label_stringstring (base64)Base64-encoded shipping label string.
action_if_undeliverablestringWhat DashLink should do if the parcel cannot be delivered. All parcel shipments use: "return_to_pickup", parcels are never disposed or left behind unless configured differently.

Note: Not all fields that may be returned by the Drive API are listed above.
This table includes only the fields relevant to the DashLink parcel use case.