# Convert quote to shipment Convert an accepted quote into a shipment. ## What happens 1. Quote status is set to WON (if not already) 2. A new Shipment is created 3. The Order from the quote is linked to the shipment 4. Optionally, additional orders can be added ## Prerequisites - Quote must be in QUOTED or WON status - Quote cannot already have a shipment ## Response Returns the IDs of both the quote and the newly created shipment. Endpoint: POST /quotes/{id}/convert-to-shipment Version: 1.0.0 Security: BearerAuth ## Path parameters: - `id` (string, required) Resource ID (UUID) or client key Example: "550e8400-e29b-41d4-a716-446655440000" ## Query parameters: - `by` (string) Specify lookup type for faster retrieval. If omitted, defaults to looking up by ID first, then falls back to client key if not found. Use by=key when you know you're providing a client key for best performance. Enum: "id", "key" ## Request fields (application/json): - `additionalOrders` (array) Optional additional orders to add to the shipment - `additionalOrders.mode` (string, required) Transportation mode. - TL: Full Truckload - LTL: Less than Truckload - AIR: Air freight - OCEAN: Ocean freight - RAIL: Rail freight - INTERMODAL: Intermodal (multiple modes) - DRAYAGE: Drayage/cartage Enum: "TL", "LTL", "AIR", "OCEAN", "RAIL", "INTERMODAL", "DRAYAGE" - `additionalOrders.stops` (array, required) At least origin and destination stops - `additionalOrders.stops.type` (string, required) Type of stop Enum: "PICKUP", "DELIVERY", "CROSS_DOCK" - `additionalOrders.stops.location` (any) - `additionalOrders.stops.address` (object) Address for ad-hoc stop (if no location reference) - `additionalOrders.stops.address.line1` (string, required) Primary street address line Example: "123 Main St" - `additionalOrders.stops.address.line2` (string) Secondary address line (suite, floor, etc.) Example: "Suite 400" - `additionalOrders.stops.address.city` (string, required) City name Example: "Chicago" - `additionalOrders.stops.address.country` (string, required) Country name or code Example: "USA" - `additionalOrders.stops.address.market` (string, required) Market or region identifier Example: "CHI" - `additionalOrders.stops.address.latitude` (string) Latitude coordinate Example: "41.8781" - `additionalOrders.stops.address.longitude` (string) Longitude coordinate Example: "-87.6298" - `additionalOrders.stops.address.isAirportOrAirbase` (boolean) Whether this location is an airport or airbase - `additionalOrders.stops.address.isConstructionOrUtilitySite` (boolean) Whether this location is a construction or utility site - `additionalOrders.stops.address.isSmartyValidated` (boolean) Whether address has been validated by SmartyStreets Example: true - `additionalOrders.stops.address.obeysDst` (boolean) Whether this location observes daylight saving time Example: true - `additionalOrders.stops.address.cityId` (string) Reference to standardized city record (internal use) - `additionalOrders.stops.requestedStartDate` (string) Requested start date for the stop - `additionalOrders.stops.requestedEndDate` (string) Requested end date for the stop - `additionalOrders.stops.requestedStartTime` (string) Requested start time (HH:MM format) - `additionalOrders.stops.requestedEndTime` (string) Requested end time (HH:MM format) - `additionalOrders.stops.appointmentRequired` (boolean) Whether an appointment is required - `additionalOrders.stops.notes` (string) Special instructions for the stop - `additionalOrders.freight` (object) Freight details for an order - `additionalOrders.freight.handlingUnitQuantity` (integer) Number of handling units - `additionalOrders.freight.handlingUnitType` (string) Type of handling unit Enum: "PALLET", "SKID", "CARTON", "CRATE", "DRUM", "BUNDLE", "ROLL", "BAG", "TOTE", "OTHER" - `additionalOrders.freight.weight` (number) Total weight in pounds - `additionalOrders.freight.volume` (number) Total volume in cubic feet - `additionalOrders.freight.length` (number) Length in inches - `additionalOrders.freight.width` (number) Width in inches - `additionalOrders.freight.height` (number) Height in inches - `additionalOrders.freight.commodityDescription` (string) Description of the commodity - `additionalOrders.freight.hazmat` (boolean) Whether freight is hazardous materials - `additionalOrders.freight.stackable` (boolean) Whether freight is stackable - `additionalOrders.equipment` (array) Equipment types required - `additionalOrders.references` (array) Reference numbers for the order - `additionalOrders.references.type` (string, required) Reference type (e.g., BOL_NUMBER, PO_NUMBER) - `additionalOrders.references.value` (string, required) Reference value - `additionalOrders.specialRequirements` (array) Special requirements (e.g., liftgate, team drivers) ## Response 200 fields (application/json): - `quoteId` (string, required) Quote ID that was converted - `quoteStatus` (string, required) Quote status after conversion (always WON) Enum: "WON" - `shipmentId` (string, required) Created shipment ID - `shipmentKey` (string, required) Created shipment friendly ID - `orderId` (string, required) Order ID from the quote ## Response 400 fields (application/json): - `error` (string, required) Error code - `message` (string, required) Human-readable error message ## Response 401 fields (application/json): - `error` (string, required) Error code - `message` (string, required) Human-readable error message ## Response 404 fields (application/json): - `error` (string, required) Error code - `message` (string, required) Human-readable error message ## Response 409 fields (application/problem+json): - `error` (string, required) Error code - `message` (string, required) Human-readable error message