Inventory Device Serial Operation
The Inventory Device Serial Operation endpoints enable remote device management by allowing you to perform critical operations on devices identified by their serial numbers. This API provides a streamlined way to execute common device maintenance tasks such as reboots, factory resets, configuration synchronization, and reconfiguration without physical access to the devices.
Base URL: https://control.zequenze.com/api/v1
Authentication: All endpoints require a Bearer token:
Authorization: Bearer <your-api-token>
Overview
The Inventory Device Serial Operation API category provides device management capabilities for remotely controlling devices in your inventory system. This API is essential for IT administrators, device managers, and automated systems that need to perform maintenance operations on deployed devices across different locations.
Key Features:
- Execute device operations using serial numbers as unique identifiers
- Support for multiple operation types including reboots, factory resets, and configuration management
- Designed for both manual administrative tasks and automated device lifecycle management
- Real-time operation execution with immediate response feedback
Common Scenarios:
- Remote Troubleshooting: Restart unresponsive devices without physical access
- Device Provisioning: Factory reset devices for redeployment or initial setup
- Configuration Management: Sync device configurations or trigger reconfiguration after policy changes
- Maintenance Workflows: Integrate device operations into automated maintenance schedules
This API category is particularly valuable for organizations managing large fleets of devices across multiple locations, where physical access for maintenance operations would be impractical or costly.
Endpoints
PUT /inventory_device_serial_operation/{serial_number}/
Description: Executes a specified operation on a device identified by its serial number. This endpoint supports various device management operations including reboots, factory resets, configuration synchronization, and reconfiguration. The operation is executed immediately upon successful request processing.
Use Cases:
- Remotely restart a device that has become unresponsive or is experiencing connectivity issues
- Perform factory reset on devices being reassigned to different users or locations
- Synchronize device configuration after updating policies or settings in the management system
- Trigger device reconfiguration when network parameters or security settings change
- Reset device settings while preserving core device firmware (device factory reset)
Full URL Example:
https://control.zequenze.com/api/v1/inventory_device_serial_operation/ABC123456789/
Parameters:
| Parameter | Type | In | Required | Description |
|---|---|---|---|---|
| serial_number | string | path | Yes | The unique serial number of the device to operate on |
| data | string | body | Yes | JSON payload containing the operation to perform |
Request Body Schema:
| Field | Type | Required | Description | Allowed Values |
|---|---|---|---|---|
| operation | string | Yes | The operation to perform on the device | reboot, factory, device_factory, sync, reconf |
Operation Types:
-
reboot- Restart the device -
factory- Perform complete factory reset (all settings and data) -
device_factory- Perform device factory reset (preserves some core settings) -
sync- Synchronize device configuration with management server -
reconf- Trigger device reconfiguration process
cURL Example:
curl -X PUT "https://control.zequenze.com/api/v1/inventory_device_serial_operation/ABC123456789/" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"operation": "reboot"
}'
Example Request Body:
{
"operation": "reboot"
}
Example Response:
{
"id": 12345,
"operation": "reboot"
}
Response Fields:
| Field | Type | Description |
|---|---|---|
| id | integer | Unique identifier for the operation request (read-only) |
| operation | string | Confirmation of the operation that was executed |
Response Codes:
| Status | Description |
|---|---|
| 200 | Success - Operation initiated successfully |
| 400 | Bad Request - Invalid operation type or malformed request |
| 401 | Unauthorized - Invalid or missing authentication token |
| 404 | Not Found - Device with specified serial number not found |
| 422 | Unprocessable Entity - Valid request format but operation cannot be processed |
| 500 | Internal Server Error - Server error during operation execution |
Common Use Cases
Use Case 1: Remote Device Troubleshooting
When devices become unresponsive or experience connectivity issues, use the reboot operation to restart them remotely. This is particularly useful for devices deployed in remote locations where physical access is difficult or costly.
Endpoints: PUT /inventory_device_serial_operation/{serial_number}/ with operation: "reboot"
Use Case 2: Device Reassignment and Redeployment
Before reassigning devices to new users or locations, perform a factory reset to ensure all previous user data and configurations are removed. This maintains security and provides a clean slate for new deployments.
Endpoints: PUT /inventory_device_serial_operation/{serial_number}/ with operation: "factory"
Use Case 3: Configuration Management Workflows
After updating device policies, security settings, or network configurations in your management system, trigger configuration synchronization to ensure all devices receive the latest settings without manual intervention.
Endpoints: PUT /inventory_device_serial_operation/{serial_number}/ with operation: "sync"
Use Case 4: Automated Maintenance Schedules
Integrate device operations into automated maintenance workflows that can perform regular reboots during off-hours, sync configurations after policy updates, or prepare devices for redeployment as part of lifecycle management processes.
Endpoints: PUT /inventory_device_serial_operation/{serial_number}/ with various operations based on maintenance requirements
Use Case 5: Emergency Response and Recovery
In emergency situations where devices need immediate reconfiguration (such as security incidents or network changes), use the reconfiguration operation to quickly update device settings without waiting for standard synchronization cycles.
Endpoints: PUT /inventory_device_serial_operation/{serial_number}/ with operation: "reconf"
Best Practices
Operation Selection:
- Use
rebootfor routine troubleshooting and after configuration changes that require a restart - Choose
factoryfor complete device reset when reassigning or decommissioning devices - Select
device_factorywhen you need to reset user settings but preserve core device firmware and basic configurations - Implement
syncoperations after any policy or configuration updates in your management system - Use
reconffor immediate configuration changes that cannot wait for scheduled synchronization
Error Handling:
- Always check the response status code before proceeding with additional operations
- Implement retry logic with exponential backoff for temporary network issues
- Log operation requests and responses for audit trails and troubleshooting
- Handle 404 errors gracefully when serial numbers may not exist in the system
Security Considerations:
- Validate serial numbers before making requests to prevent unauthorized device access
- Use secure token storage and rotation practices for API authentication
- Log all device operations for security auditing and compliance requirements
- Implement rate limiting to prevent accidental mass operations that could disrupt services
Performance and Reliability:
- Allow sufficient time between operations on the same device to ensure completion
- Monitor operation success rates and device response times to identify problematic devices
- Implement proper timeout handling as device operations may take time to complete
- Consider device time zones and usage patterns when scheduling automated operations
Integration Tips:
- Store operation IDs returned in responses for tracking and correlation with device logs
- Implement webhooks or polling mechanisms to monitor operation completion status
- Use device serial numbers consistently across all inventory management systems
- Validate device operational status before attempting operations to avoid conflicts