The Warehouse
A warehouse is a physical facility or silo where loading and unloading operations are carried out. In DigiAnt, the warehouse acts as a reference point for authorizations: it defines the physical location a carrier is authorized to access.
Two possible origins
| Origin | Description |
|---|---|
| Native DigiAnt | Created via the Partner API. Has no external reference. All fields are managed directly in DigiAnt. |
| ERP-synced | Imported from the ERP. Has an externalId that uniquely identifies it in the source system. |
When the ERP updates a warehouse (name, code), DigiAnt applies the change to the existing record using externalId as the upsert key — it never creates a duplicate.
Operational status
The status field controls whether the warehouse accepts new operations. Three values are possible:
| Status | Behaviour |
|---|---|
Open | The warehouse is operational. Assigned trucks advance through the queue normally. |
Paused | The warehouse is temporarily paused. Trucks can be assigned but the queue does not advance until the warehouse returns to Open. |
Closed | The warehouse is closed. No trucks can be assigned. |
A newly created warehouse — whether native or ERP-synced — starts in Open status.
Status is a field managed exclusively by DigiAnt. ERP syncs never overwrite it: if you change a warehouse's status in DigiAnt and the ERP later sends a sync, the status is preserved.
Field ownership
DigiAnt distinguishes which fields belong to each domain:
| Field | Owner | Notes |
|---|---|---|
name | ERP (synced warehouses) | The ERP can update it via sync; DigiAnt does not modify it. |
code | ERP (synced warehouses) | Short warehouse identifier. |
status | DigiAnt | Never overwritten by an ERP sync. |
totemGroupId | DigiAnt | Assigned and managed in DigiAnt. |
hasDisplay | DigiAnt | Whether the warehouse has a physical display screen. |
displayText | DigiAnt | Text shown on the display. Only editable when hasDisplay: true. |
For native warehouses (no ERP), all fields are managed by DigiAnt via the Partner API.
Display screen
If a warehouse has hasDisplay: true, it has a physical screen that shows real-time information. The screen text is managed via the displayText field.
Attempting to set displayText on a warehouse without a display (hasDisplay: false) returns a validation error.
Lifecycle
Warehouses support soft delete: deleting a warehouse does not remove it physically — it is marked as deleted. Existing authorizations that referenced the warehouse are not affected.
| Operation | Effect |
|---|---|
| Create | New record, status Open. |
| Sync from ERP | Upsert by externalId: creates if not found, updates name and code if already exists. |
| Delete | Soft delete — deleted: true, deletedAt recorded. |
Managing warehouses via the Partner API
Create
POST /partner/warehouses
X-Partner-API-Key: dpk_live_...
Content-Type: application/json
{
"name": "Central Silo",
"code": "SILO-C",
"totemGroupId": "totem-group-uuid",
"hasDisplay": true
}
name, code, and hasDisplay are required. totemGroupId is optional.
List and retrieve
List all warehouses for your logistics company:
GET /partner/warehouses
X-Partner-API-Key: dpk_live_...
Retrieve a specific warehouse by UUID:
GET /partner/warehouses/{id}
X-Partner-API-Key: dpk_live_...
Update
Update the fields of a native warehouse. Only works on native warehouses — ERP-synced ones return 403.
PATCH /partner/warehouses/{id}
X-Partner-API-Key: dpk_live_...
Content-Type: application/json
{
"name": "Renovated Central Silo",
"code": "SILO-CR",
"totemGroupId": "totem-group-uuid",
"hasDisplay": false
}
All three fields — name, code, and hasDisplay — are required in the PATCH body.
Delete
Soft-deletes the warehouse. Only works on native warehouses.
DELETE /partner/warehouses/{id}
X-Partner-API-Key: dpk_live_...
Returns 204 on success, 403 if the warehouse was ERP-synced.
The warehouseExternalId field in authorizations
When creating an authorization, the warehouse is referenced by its ERP identifier in the warehouseExternalId field:
{
"warehouseExternalId": "ERP-WAREHOUSE-01"
}
DigiAnt looks up the warehouse by that identifier in the catalog. If no warehouse with that externalId exists, the request returns 422. The authorization response returns the resolved reference as warehouse.