Integrating 1C-Bitrix with Mobile Data Terminals (MDT)
An MDT is a handheld scanner with an embedded computer running Android or Windows CE/Mobile, used by warehouse staff for receiving goods, inventory counting, order picking, and stock transfers. Without 1C-Bitrix integration, the workflow looks like this: an employee scans barcodes on the MDT, the data remains on the device, and someone manually transfers it into the system later — causing delays, data entry errors, and stock discrepancies.
Interaction Architecture
The MDT does not communicate directly with the 1C-Bitrix database — this would be a security violation and is technically infeasible in most cases. The correct architecture is: MDT ↔ REST API on the 1C-Bitrix side ↔ catalog / sale modules.
A set of API endpoints is implemented on the 1C-Bitrix side; the MDT communicates with them over the warehouse Wi-Fi network. For offline operation, the MDT stores the task locally and synchronizes when connectivity is restored.
REST API for MDT
A controller /api/tsd/v1/ is created with the following methods:
Retrieve a picking task:
GET /api/tsd/v1/tasks/{task_id}
Authorization: Bearer {token}
The response contains the list of order line items: product_id, barcode, name, qty_required, location (warehouse location from the product property WAREHOUSE_LOCATION).
Confirm a scanned line item:
POST /api/tsd/v1/tasks/{task_id}/scan
{
"barcode": "4601234567890",
"qty_scanned": 1,
"location": "A-02-05"
}
The controller validates the barcode via \Bitrix\Catalog\ProductTable (the BARCODE field or the associated table b_catalog_product_barcode), finds the matching task line item, and updates its counter.
Complete a task:
POST /api/tsd/v1/tasks/{task_id}/complete
When a picking task is completed: all items collected → the order transitions to "Ready for shipment" status, and a notification is sent to the manager.
Inventory Counting via MDT
An inventory task of type inventory is created as follows:
class TsdInventoryTask
{
public function create(int $warehouseId, array $productIds = []): array
{
// Create a record in bl_tsd_inventory_task
$taskId = InventoryTaskTable::add([
'WAREHOUSE_ID' => $warehouseId,
'STATUS' => 'pending',
'CREATED_BY' => $GLOBALS['USER']->GetID(),
])->getId();
// Load expected stock from b_catalog_store_product
$expected = \Bitrix\Catalog\StoreProductTable::getList([
'filter' => ['STORE_ID' => $warehouseId],
'select' => ['PRODUCT_ID', 'AMOUNT'],
]);
while ($row = $expected->fetch()) {
InventoryItemTable::add([
'TASK_ID' => $taskId,
'PRODUCT_ID' => $row['PRODUCT_ID'],
'QTY_SYSTEM' => $row['AMOUNT'],
'QTY_ACTUAL' => null, // filled in by the MDT
]);
}
return ['task_id' => $taskId];
}
}
The MDT loads the task, the employee scans barcodes and enters quantities. The API accepts results one line item at a time. After completion, a discrepancy report (qty_system vs qty_actual) is available in the admin panel.
Goods Receipt via MDT
During a goods receipt, the employee scans each unit. The API handler /api/tsd/v1/receipt/scan matches the barcode to a purchase order line item (via the supplier table b_catalog_docs_element or a custom procurement table) and increments the count of received units.
Upon completing the receipt, the following actions are performed automatically:
- Stock levels are updated in
b_catalog_store_product - A receipt document is created via the
\Bitrix\Catalog\Document\StoreAPI - If there is a discrepancy with the purchase order, a task is created for the manager in CRM
MDT Authentication
Each MDT receives a personal API token (bl_tsd_tokens) during setup. The token is strictly bound to warehouse_id — the device cannot see tasks for another warehouse. Tokens have no expiry date but can be revoked via the administrator interface.
Supported MDT Devices
| Device | OS | Protocol | Status |
|---|---|---|---|
| Honeywell CK65 | Android 8+ | REST/JSON | Full support |
| Zebra TC52/TC57 | Android 8+ | REST/JSON | Full support |
| Urovo DT50 | Android | REST/JSON | Full support |
| Datalogic Memor 20 | Android | REST/JSON | Full support |
| Motorola MC9200 | Windows CE 7 | REST via HTTPPOST | Limited |
For Windows CE devices, REST/JSON is implemented via native HTTP libraries; it is recommended to limit functionality to order picking only.
Timeline
| Phase | Duration |
|---|---|
| API and DB schema design | 2 days |
| API controllers (picking, receipt, inventory) | 5–6 days |
| Administrative task management interface | 3 days |
| Testing with a real MDT device | 2–3 days |
| Total | 12–15 days |

