# Update command status

API to update a command status state

Endpoint: PUT /commands/v0/status/{id}/
Version: 1.0.0
Security: apiKey

## Path parameters:

  - `id` (string, required)
    ID of the command status object

## Request fields (application/json):

  - `state` (string)
    Command state to update
    Enum: "Command Acknowledged", "Command In Progress", "Command TimeOut", "Command Success", "Command Failure", "Command Scheduled", "Command Cancelled"

  - `reason` (string)
    State change reason to update

## Response 200 fields (application/json):

  - `code` (integer)

  - `message` (string)

  - `content` (object)

  - `content.id` (string)
    Unique command identifier

  - `content.request` (string)
    Request Id associated with this command

  - `content.device` (string)
    Device associated with this command

  - `content.state` (string)
    Current state of the command
    Enum: "Command Queued", "Command Initiated", "Command Acknowledged", "Command In Progress", "Command TimeOut", "Command Success", "Command Failure", "Command Scheduled", "Command Cancelled"

  - `content.reason` (string)
    details briefing the reason for current command state

  - `content.created_at` (string)
    Timestamp of command creation

  - `content.updated_at` (string)
    Last updated timestamp of command

  - `content.command_meta` (object,null)
    Optional metadata associated with the command execution result. Present only for commands that return structured data from the device.

  - `content.command_meta.result` (any,null)
    Command-specific result data. Structure varies by command type. For OS_UPDATE_STATUS, result is an object with fields: product_key, is_downloaded, download_percent_complete, status, product_version. For SCAN_OS_UPDATES, result is an array of objects with fields: product_key, product_version, build, human_readable_name, is_critical, download_size.

## Response 400 fields (application/json):

  - `code` (integer, required)

  - `message` (string, required)

  - `content` (object)

## Response 401 fields (application/json):

  - `code` (integer, required)

  - `message` (string, required)

  - `content` (object)

## Response 500 fields (application/json):

  - `code` (integer, required)

  - `message` (string, required)

  - `content` (object)


