Skip to main content

Inventory Device Log

The Inventory Device Log endpointsAPI provideprovides access to device operation logs,logs and settings changes,history andwithin auditthe trailsZequenze forControl network devices.platform. These endpoints allow you to trackretrieve configurationdetailed logs of device actions, parameter changes, commands, events, and alerts with comprehensive filtering capabilities. Use these endpoints to monitor device operations, andtroubleshoot maintain compliance through comprehensive loggingissues, and filteringtrack capabilities.configuration changes over time.

Base URL: https://control.zequenze.com/api/v1

Authentication: All endpoints require a Bearer token:

Authorization: Bearer <your-api-token>

Overview

The Inventory Device Log API category provides comprehensive access to device operationoperational logs and settings changehistory. trackingThis withinAPI your network infrastructure. These endpoints areis essential for network administrators who need to monitormonitoring device configurations,behavior, tracktracking changesconfiguration over time,changes, and maintaintroubleshooting auditdevice trailsissues forin compliancemanaged purposes.network environments.

Key Features:

  • AuditAction TrailTracking: Monitor all device actions including set/get operations, commands, events, and alerts
Parameter Management -: Track allparameter configurationvalue changes and operationsconfiguration performed on network devicesupdates AdvancedStatus Monitoring: View operational status with detailed error codes and messages Time-based Filtering: -Query logs within specific date/time ranges using ISO format timestamps Device-specific Logs: Filter logs by device,specific timestamp,devices actionor type,parameter and application statusnames PendingOperational OperationsStatus: MonitoringTrack - Monitorpending operations that are queued but not yetand applied to devices Variable-Level Tracking - Track changes at the individual configuration variable levelconfigurations

Common Integration Scenarios:

  • NetworkAudit monitoringtrails dashboards displaying recentfor device configuration changes
  • ComplianceTroubleshooting reportingdevice systemsconnectivity requiringand detailedparameter audit trailsissues
  • AutomatedMonitoring alertingalert systemsconditions forand failedevent configuration deploymentspatterns
  • TroubleshootingTracking toolscommand thatexecution correlateand completion status
Analyzing device issuesbehavior withover recenttime changesperiods

The API uses cursor-based pagination for efficient handlingdata of large log datasetsretrieval and supports ISO 8601 datetimeextensive filtering foroptions preciseto time-basedhelp queries.you find specific log entries quickly.


Endpoints

GET /inventory_device_log/

Description: Retrieves a paginated list of device operation logs andwith configurationcomprehensive changes.filtering options. This endpoint is theyour primary methodtool for accessing historical device activity,operational monitoringhistory, pendingincluding operations,parameter changes, commands, events, and generating audit reports.alerts. Use thisthe endpointvarious filter parameters to tracknarrow whatdown changesresults wereto made,specific whendevices, theytime occurred,periods, andactions, theiror currentoperational application status.states.

Use Cases:

  • Generate compliance reports showing all device changes within a specific timeframe
Monitor pending configuration changes across your device inventory Create dashboards displaying recent device activity and operationconfiguration statuschanges Generate audit reports for specific time periods Track pending operations across multiple devices Analyze alert patterns and device events Troubleshoot parameter configuration issues by reviewing recent changes to specific devices

Full URL Example:

https://control.zequenze.com/api/v1/inventory_device_log/?parent__id=device-123&datetime__gte=2024-01-01&action=sv&is_pending=false&limit=50

Parameters:

Parameter Type In Required Description
datetime__gte string query No Filter logs from this date/time onward.onwards. Supports ISO format:formats: 2000-2024-01-01,01, 2000-2024-01-01 00:01:00,10:30:00, 2000-2024-01-01 00:01:01T10:30:00+00:00
datetime__lte string query No Filter logs up to this date/time. Supports ISO format:formats: 2000-2024-01-01,01, 2000-2024-01-01 00:01:00,23:59:59, 2000-2024-01-01 00:01:00+01T23:59:59+00:00
parent__id string query No Filter logs by specific device IDID. Use device identifier to showget only operationslogs for thata particular device
action string query No Filter by operationaction typetype: sv (e.g.Set), 'create'uv (Unset), 'update'gv (Get), 'delete'sa (Set attribute), 'deploy')cr (Create), de (Delete), cm (Command), ev (Event), er (Error), ar (Alert raised), ac (Alert cleared)
is_pending boolean query No Filter by pending statusstatus. - true for queuedoperations operations,awaiting execution, false for completed operations
is_applied boolean query No Filter by applicationapplied statusstatus. - true for successfully applied operations
operations, variable_name string query No Filter logsfalse for changesoperations tonot specificyet configuration variablesapplied cursor string query No Pagination cursor for retrieving the nextnext/previous page of results limit integer query No Number of results per page (default:default 20,varies, maximum:typically 20-100) variable_name string query No Filter by specific parameter or variable name as expected by device agent

cURL Example:

curl -X GET "https://control.zequenze.com/api/v1/inventory_device_log/?parent__id=device-123&datetime__gte=2024-01-15T00:00:00Z01&action=sv&limit=25"20" \
  -H "Authorization: Bearer YOUR_API_TOKEN" \
  -H "Content-Type: application/json"

Example Response:

{
  "count": 156,
  "next": "https://control.zequenze.com/api/v1/inventory_device_log/?cursor=eyJpZCI6MTIzfQ%eyJjcmVhdGVkIjoiMjAyNC0wMS0xNVQxMDozMDowMFoifQ%3D%3D",
  "previous": null,
  "results": [
    {
      "id": 1001,1247,
      "parent_id": "device-123",
      "device_name": "core-switch-01",
      "datetime"created": "2024-01-15T14:32:15T10:30:00Z",
      "last_change": "2024-01-15T10:30:15Z",
      "user": 42,
      "parent": 156,
      "type": "string",
      "action": "update"sv",
      "command": "Reconf",
      "name": "WiFi Configuration Update",
      "variable_name": "interface_vlan_config"Device.WiFi.SSID.1.SSID",
      "old_value"value": "vlan 100",
      "new_value": "vlan 200"Corporate_Network_5G",
      "is_pending": false,
      "is_applied": true,
      "applied_at"status": 200,
      "message": "2024-01-15T14:33:15Z",Parameter "user":updated "admin@company.com",
      "operation_id": "op-789456",
      "error_message": nullsuccessfully"
    },
    {
      "id": 1000,1246,
      "parent_id": "device-123", 
      "device_name": "core-switch-01",
      "datetime"created": "2024-01-15T14:15T09:15:00Z",
      "last_change": "2024-01-15T09:15:30Z",
      "user": 38,
      "parent": 156,
      "type": "boolean",
      "action": "create"sv",
      "command": null,
      "name": "Enable Auto-Update",
      "variable_name": "snmp_community"Device.ManagementServer.AutoUpdate.Enabled",
      "old_value": null,
      "new_value"value": "monitoring_readonly"true",
      "is_pending": true,false,
      "is_applied": false,true,
      "applied_at"status": 200,
      "message": "Auto-update enabled successfully"
    },
    {
      "id": 1245,
      "created": "2024-01-15T08:45:00Z",
      "last_change": "2024-01-15T08:45:00Z",
      "user": null,
      "user"parent": 203,
      "type": null,
      "action": "network.admin@company.com"ev",
      "operation_id"command": "op-789455"Boot",
      "error_message"name": null"Device Boot Event",
      "variable_name": null,
      "value": null,
      "is_pending": false,
      "is_applied": true,
      "status": 200,
      "message": "Device completed boot sequence"
    }
  ]
}

Response Codes:

Status Description
200 Success - Returns paginated list of device logs with filtering applied
400 Bad Request - Invalid filter parameters or date format 401 Unauthorized - Invalid or missing authenticationBearer token 403 Forbidden - Insufficient permissions to access device logs 400 Bad Request - Invalid query parameters or date format

GET /inventory_device_log/{id}/

Description: Retrieves detailed information for a specific device log entry by its unique ID.identifier. This endpoint provides complete details about a single operationdevice or configuration change,operation, including itsparameter currentchanges, status,command anyexecution error messages,results, and fulloperational before/after values.status. Use this for detailed investigation of specific operations or when you need completecomprehensive contextinformation about a particularspecific change.log entry identified from the list endpoint.

Use Cases:

  • Get complete details about a specific device operation
Investigate the detailsfull context of a specific failed configuration change Review the complete context and metadata for a particular operation Verify that a critical configuration change was successfully applied Retrieve detailed error messages and status information forAudit troubleshootingspecific deploymentparameter issueschanges with full metadata

Full URL Example:

https://control.zequenze.com/api/v1/inventory_device_log/1001/1247/

Parameters:

Parameter Type In Required Description
id integer path Yes The uniqueUnique identifier of the specificdevice log entry to retrieve
datetime__gte string query No Additional filter byfor minimum date/timedatetime (rarelytypically usednot needed for single record retrieval)
datetime__lte string query No Additional filter byfor maximum date/timedatetime (rarelytypically usednot needed for single record retrieval)
parent__id string query No Additional filter by device ID (typically not needed for validation/securitysingle purposes)record retrieval)
variable_name string query No Additional filter by variable name (typically not needed for validationsingle purposes)record retrieval)
action string query No Additional filter by action type (typically not needed for validationsingle purposes)record retrieval)
is_pending boolean query No Additional filter by pending status (typically not needed for validationsingle purposes)record retrieval)
is_applied boolean query No Additional filter by applied status (typically not needed for validationsingle purposes)record retrieval)

cURL Example:

curl -X GET "https://control.zequenze.com/api/v1/inventory_device_log/1001/1247/" \
  -H "Authorization: Bearer YOUR_API_TOKEN" \
  -H "Content-Type: application/json"

Example Response:

{
  "id": 1001,1247,
  "parent_id": "device-123",
  "device_name": "core-switch-01",
  "device_type": "cisco_ios",
  "device_ip": "192.168.1.10",
  "datetime"created": "2024-01-15T14:32:15T10:30:00Z",
  "last_change": "2024-01-15T10:30:15Z",
  "user": 42,
  "parent": 156,
  "type": "string",
  "action": "update"sv",
  "command": "Reconf",
  "name": "WiFi Configuration Update",
  "variable_name": "interface_vlan_config"Device.WiFi.SSID.1.SSID",
  "variable_category"value": "network_interfaces",
  "old_value": "interface GigabitEthernet0/1\n switchport mode access\n switchport access vlan 100",
  "new_value": "interface GigabitEthernet0/1\n switchport mode access\n switchport access vlan 200"Corporate_Network_5G",
  "is_pending": false,
  "is_applied": true,
  "applied_at"status": 200,
  "message": "2024-01-15T14:33:15Z",Parameter "user":updated "admin@company.com",
  "user_role": "network_administrator",
  "operation_id": "op-789456",
  "batch_id": "batch-456789",
  "error_message": null,
  "rollback_available": true,
  "change_reason": "VLAN migration for security compliance",
  "approval_required": true,
  "approved_by": "manager@company.com",
  "approved_at": "2024-01-15T14:31:45Z",
  "metadata": {
    "source_system": "network_automation",
    "change_ticket": "CHG-2024-001234",
    "estimated_impact": "low",
    "maintenance_window": "2024-01-15T14:30:00Z to 2024-01-15T15:00:00Z"
  }successfully"
}

Response Codes:

Status Description
200 Success - Returns detailed information for the specified log entry information
401 Unauthorized - Invalid or missing authenticationBearer token
403 Forbidden - Insufficient permissions to access this log entry
404 Not Found - Log entry with specified ID does not exist
400 Bad Request - Invalid ID format or query parameters

Common Use Cases

Use Case 1: ComplianceMonitor AuditRecent ReportDevice Configuration Changes

Generate a comprehensive audit trail for a specific time period showingTrack all deviceparameter changes made to devices in the last 24 hours to ensure configuration changes. Use the list endpoint with date filters to extract all operations within your audit timeframe, then format the results for compliance reporting.and detect unauthorized modifications.

GET# Get all parameter set operations from yesterday
https://control.zequenze.com/api/v1/inventory_device_log/?datetime__gte=2024-01-0114&datetime__lte=2024-01-31action=sv&is_applied=true&limit=100

Use Case 2: MonitorTroubleshoot PendingFailed ConfigurationDevice ChangesOperations

TrackIdentify and analyze failed operations by filtering for error statuses and pending operations that arehaven't queuedcompleted but not yet deployed to devices. This helps identify potential bottlenecks in your configuration deployment pipeline and ensure changes are applied in a timely manner.successfully.

GET# Find all failed operations with error status
https://control.zequenze.com/api/v1/inventory_device_log/?is_pending=truestatus=500&is_applied=false

Use Case 3: Device-SpecificAudit ChangeDevice HistoryAlert Activity

ReviewMonitor allalert configurationpatterns changesby fortracking aalert specificraised networkand devicecleared whenevents troubleshootingacross devices to identify recurring issues or planning maintenance activities. Filter by device ID and recent timeframe.needs.

GET# Get all alert-related events from the past week
https://control.zequenze.com/api/v1/inventory_device_log/?parent__id=device-123&datetime__gte=2024-01-15T00:00:00Z08&action=ar,ac

Use Case 4: FailedTrack OperationSpecific InvestigationParameter Changes

Identify and investigate configurationMonitor changes that failed to applycritical properly.device Filterparameters forlike applied=falseWiFi operationssettings, andsecurity retrieveconfigurations, detailedor errornetwork information.parameters across your device inventory.

GET# Monitor WiFi SSID changes across all devices
https://control.zequenze.com/api/v1/inventory_device_log/?is_applied=falsevariable_name=Device.WiFi.SSID.1.SSID&is_pending=falseaction=sv

Use Case 5: Variable-SpecificGenerate ChangeDevice TrackingActivity Reports

MonitorCreate changescomprehensive toactivity criticalreports configurationfor variablesspecific acrossdevices allby devices,combining suchdevice asfiltering securitywith policiestime-based orqueries routingfor configurations.audit and compliance purposes.

GET# Get all activity for device ID 156 in January 2024
https://control.zequenze.com/api/v1/inventory_device_log/?variable_name=security_policyparent__id=156&datetime__gte=2024-01-01&datetime__lte=2024-01-31

Response Field Reference

Action Types

    sv - Set: Parameter value assignment operations uv - Unset: Parameter value removal operations gv - Get: Parameter value retrieval operations sa - Set attribute: Parameter attribute modifications cr - Create: Object or instance creation de - Delete: Object or instance deletion cm - Command: Device command execution ev - Event: System or device events er - Error: Error conditions and failures ar - Alert raised: Alert condition triggered ac - Alert cleared: Alert condition resolved

    Status Codes

      0 - Pending: Operation queued for execution 100 - Sent: Operation transmitted to device 200 - Ok: Operation completed successfully 400 - Invalid parameter: Parameter name or format error 401 - Authentication error: Device authentication failed 403 - Forbidden: Operation not permitted 404 - Invalid request: Malformed request or unknown operation 406 - Invalid value: Parameter value validation failed 500 - Error: General operational error 504 - Timeout: Operation exceeded time limit

      Parameter Types

      Common parameter types you'll encounter in device logs include string, integer, boolean, datetime, select, and specialized types like password and deviceDash for dashboard configurations.


      Best Practices

      • Use Date Filtering Efficiently -: Always includeapply datetimedatetime__gte and datetime__lte filters when possible to limit resultresults setsto relevant time periods and improve query performance. Use ISO 8601 format with timezone information for accuracy.

        performance
      • Implement Proper Pagination - Use the cursor-based pagination for large datasets. Set appropriate limit values (recommended: 25-50 for UI displays, 100+ for bulk processing).

      Monitor Pending Operations -: Regularly check for operations with is_pending=true to identify stuck deployments or configurationdelayed pipelinedevice issues.

      communications

      CombineImplement Filters Strategically - Use multiple filter parameters together to create precise queries. For example, combine device ID with date range and action type for focused troubleshooting.

      Error Handling: BestCheck Practicesboth -HTTP Alwaysstatus checkcodes and the is_appliedstatus and error_message fields when reviewing operation results. Implement retry logic for transient network issues.

      Security Considerations - Log access should be restricted based on user roles. Sensitive configuration values may be maskedfield in log entries dependingto onproperly yourhandle systemoperational configuration.

      failures

      PerformanceLeverage OptimizationPagination: -Use Cachethe frequentlycursor accessedparameter for efficient pagination through large log datadatasets andrather usethan thehigh limit values

      Filter by Device: Use parent__id filtering when troubleshooting specific logdevice entry endpoint when you need details about known operationsissues to reduce APInoise callfrom overhead.other devices Track Critical Parameters: Monitor sensitive parameters like security settings and network configurations using variable_name filtering Correlate Actions: Combine action filtering with status codes to identify patterns in successful vs. failed operations