Get Order Products
Returns the products (line items) for a specific order with enhanced image support and substitute information.
URL: /dts/drone/order/products
Method: GET
Auth required: Yes
Parameters:
| Name | Located in | Description | Required | Type |
|---|---|---|---|---|
| order_id | query | ID of the order to retrieve products for | Yes | string |
| show_status | query | Whether to include status info for items | No | boolean |
Example Request:
GET /dts/drone/order/products?order_id=e2c5f657-60e1-467c-87c2-b0160a996fc3&show_status=true
Success Response
Code: 200 OK
Content example:
{
"responseType": "success",
"status": 200,
"message": {
"error": null,
"message": null,
"data": [
{
"id": "64797",
"name": "Pringles Chips Hot & Spicy 40gm",
"sku": "64797",
"barcode": "5410076067626",
"ean": "5410076067626",
"amount": 3,
"price": 0.83,
"quantity": 3,
"uom": "each",
"substitutable": true,
"category": "Snacks",
"cat_1": "SNACKS",
"cat_1_id": "8000",
"cat_2": "CHIPS & CRISPS",
"cat_2_id": "815",
"cat_3": "FLAVORED CHIPS",
"cat_3_id": "816",
"cat_4": null,
"cat_4_id": null,
"variable_trade_item_type": null,
"is_trade_item_a_variable_unit": false,
"unit_of_measure": "each",
"allow_replace": true,
"fulfilment_flags": [],
"allowed_substitutions": [
{
"ean": "5053990139545",
"times": 1,
"reason": "preferred_substitute",
"product": {
"name": "Pringles Chips Hot & Spicy 200G",
"price": 0,
"ean": "5053990139545",
"item_id": "9a47fa8f-8793-4ffb-a96f-dd2e92478d13",
"quantity": 1,
"properties": {
"category": "",
"required": false,
"sub_enabled": true,
"product_class": "",
"age_restricted": false,
"integration_id": "",
"sub_suggestions": [],
"master_product_id": "ce5c0b91-87b1-4a44-9a54-cf1f3d2c5d9e"
},
"substitutable": true,
"fulfilment_flags": [],
"allowed_substitutions": [],
"images": 0,
"image_guid": []
},
"priority": 1,
"available": true
}
],
"status": "pending",
"picked_quantity": 0,
"images": 5,
"image_guid": [
{
"id": "img-f6fc9bbd-1b2c-4250-8ca2-0fcf24f5cdf7-1",
"media_storage_key": "//images.ctfassets.net/bsfmk4qmje7z/2DVWrZjpDj4aP4YJ6OdAUj/55e20f987eaf25e1030c5d596b5c6371/1028159.jpg",
"media_dimension_width": 70,
"media_dimension_height": 70,
"media_mime_type": "image/png",
"media_type_code": "PICTURE",
"file_size": 0,
"created_at": "2025-08-15T08:22:17.277Z",
"updated_at": "2025-08-15T08:22:17.277Z"
}
]
}
],
"extra": []
}
}
Error Responses
Code: 400 Bad Request
Content:
{
"responseType": "failure",
"status": 400,
"message": {
"error": "Missing required parameter: order_id",
"message": null
}
}
Code: 404 Not Found
Content:
{
"responseType": "failure",
"status": 404,
"message": {
"error": "Order not found",
"message": null
}
}
Product Structure
Each product in the response includes the following fields:
Main Product Fields
| Field Name | Type | Description |
|---|---|---|
| id | string | Unique identifier for the product |
| name | string | Product name |
| sku | string | Stock keeping unit |
| barcode | string | Product barcode (legacy field) |
| ean | string | EAN/barcode identifier |
| amount | integer | Alias for quantity (deprecated) |
| price | number | Product price |
| quantity | integer | Quantity ordered |
| uom | string | Unit of measure |
| substitutable | boolean | Whether substitutions are allowed |
| category | string | Product category |
| fulfilment_flags | array | Special handling requirements for this item |
| status | string | Current status (if show_status=true) |
| picked_quantity | integer | Quantity already picked |
Image Support
Products include comprehensive image metadata:
| Field Name | Type | Description |
|---|---|---|
| images | integer | Number of available images |
| image_guid | array | Array of image metadata objects |
Each image in image_guid contains:
| Field Name | Type | Description |
|---|---|---|
| id | string | Unique image identifier |
| media_storage_key | string | Storage path or URL |
| media_dimension_width | integer | Image width in pixels |
| media_dimension_height | integer | Image height in pixels |
| media_mime_type | string | MIME type (e.g., "image/png") |
| media_type_code | string | Media type code (e.g., "PICTURE") |
| file_size | integer | File size in bytes |
| created_at | string | Creation timestamp (ISO 8601) |
| updated_at | string | Last update timestamp (ISO 8601) |
Substitution Support
Products may include substitute options in the allowed_substitutions array:
| Field Name | Type | Description |
|---|---|---|
| ean | string | EAN/barcode of the substitute |
| times | integer | Number of substitutions allowed |
| reason | string | Reason for substitution |
| priority | integer | Substitution priority |
| available | boolean | Whether substitute is available |
| product | object | Complete substitute product information |
Substitute Product Object
Each substitute product includes:
| Field Name | Type | Description |
|---|---|---|
| item_id | string | Substitute product ID |
| name | string | Substitute product name |
| ean | string | EAN/barcode of the substitute |
| quantity | integer | Substitute quantity |
| price | number | Substitute price |
| substitutable | boolean | Whether further substitution is allowed |
| images | integer | Number of images for substitute |
| image_guid | array | Image metadata (same structure as main product) |
| properties | object | Additional substitute properties |
Important Notes
EAN vs Barcode Fields
- Main products: Both
barcodeandeanfields are included for backward compatibility - Substitute products: Only the
eanfield is included (updated format) - Recommendation: Use the
eanfield as it's the standardized identifier
Image Handling
- Products without images will have
images: 0andimage_guid: [] - Multiple image sizes may be available for the same product
- Image URLs in
media_storage_keymay be relative paths requiring a base URL
Substitution Rules
- Substitutes are ordered by priority (lower numbers = higher priority)
- Each substitute includes complete product information for display
- Substitutes may have their own image data for visual comparison
- The
availableflag indicates current inventory status
Use Cases
Visual Product Identification
Use the image data to help pickers identify the correct products:
// Display main product image
const mainImage = product.image_guid.find(img =>
img.media_dimension_width >= 320
);
// Show substitute options with images
product.allowed_substitutions.forEach(sub => {
if (sub.product.images > 0) {
const subImage = sub.product.image_guid[0];
// Display substitute with image for comparison
}
});
Substitution Workflow
Handle product substitutions during picking:
// Check if substitutions are allowed
if (product.substitutable && product.allowed_substitutions.length > 0) {
// Show available substitutes by priority
const availableSubs = product.allowed_substitutions
.filter(sub => sub.available)
.sort((a, b) => a.priority - b.priority);
// Allow picker to select substitute
}
Status Tracking
Monitor picking progress when show_status=true:
// Calculate picking progress
const totalItems = order.data.length;
const pickedItems = order.data.filter(item =>
item.status === 'picked' || item.picked_quantity > 0
).length;
const progress = (pickedItems / totalItems) * 100;
Enhanced DTS Features
Category Hierarchy
Products now include hierarchical category information optimized for picking operations:
{
"cat_1": "BAKERY", // Primary category
"cat_1_id": "7000", // Primary category ID
"cat_2": "MORNING GOODS", // Secondary category
"cat_2_id": "714", // Secondary category ID
"cat_3": "ROLLS & BUNS", // Tertiary category
"cat_3_id": "715", // Tertiary category ID
"cat_4": null, // Quaternary category (if applicable)
"cat_4_id": null // Quaternary category ID
}
Fulfilment Flags
Products include a fulfilment_flags array that indicates special handling requirements. The system supports both core flags and channel-specific flags.
Core Flags:
| Flag | Description |
|---|---|
| required_item | Item must be fulfilled and cannot be omitted |
| fragile | Item requires careful handling |
| heavy | Item requires special handling due to weight |
| refrigerated | Item requires refrigerated storage |
| frozen | Item requires frozen storage |
| age_restricted | Item has age restrictions |
Channel-Specific Flags:
Certain channels may provide additional flags that the application handles for specialized workflows:
| Flag | Channel | Description |
|---|---|---|
| RESTRICTED_TO_SELL_18 | Naveo | Age verification required (18+) |
| RESTRICTED_TO_SELL_21 | Naveo | Age verification required (21+) |
| MEMBER PRICE | Naveo | Special member pricing applies |
| non_refundable | Naveo | Item cannot be refunded |
| picked | Naveo | Item has been picked |
The flags appear at multiple levels:
- Order-level: Contains only age restriction flags (RESTRICTED_TO_SELL_*) merged from all items for quick verification checks
- Item-level: Contains all applicable flags for each product
- Collected-product-level: Contains flags for the actually collected item
{
"fulfilment_flags": ["RESTRICTED_TO_SELL_18"],
"products": [{
"fulfilment_flags": ["RESTRICTED_TO_SELL_18", "age_restricted", "MEMBER PRICE"],
"collected_product": {
"fulfilment_flags": ["RESTRICTED_TO_SELL_18", "picked"]
}
}]
}
Collected Product Information
When items have been picked, the collected_product field provides detailed information:
{
"collected_product": {
"item_id": "5000128733212",
"name": "Actual collected product",
"quantity": 1,
"price": 1.15,
"barcode": "5000128733212",
"fulfilment_flags": ["picked"],
"properties": {
"picking_status": "completed",
"vat_percentage": 20,
"row_total": 1.15
}
}
}
Enhanced Image Support
Products support multiple image resolutions through the image_guid array:
{
"image_guid": [
{
"media_dimension_height": 100,
"media_dimension_width": 100,
"media_mime_type": "image/png",
"media_storage_key": "product-100x100.png",
"media_type_code": "PICTURE"
},
{
"media_dimension_height": 512,
"media_dimension_width": 512,
"media_mime_type": "image/png",
"media_storage_key": "product-512x512.png",
"media_type_code": "PICTURE"
}
]
}
Extra Items Support
The API now includes extra items (fees, bags, etc.) alongside regular products, providing a complete view of all order components.