{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/red-hat-ansible-automation-platform/json-schema/red-hat-ansible-automation-platform-ad-hoc-command-detail-schema.json",
  "title": "AdHocCommandDetail",
  "x-generated": "2026-11-25",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/red-hat-ansible-automation-platform-ad-hoc-commands-api-openapi.yml#/components/schemas/AdHocCommandDetail",
  "type": "object",
  "properties": {
    "id": {
      "type": "integer",
      "readOnly": true
    },
    "type": {
      "type": "string",
      "readOnly": true
    },
    "url": {
      "type": "string",
      "readOnly": true
    },
    "related": {
      "type": "string",
      "readOnly": true
    },
    "summary_fields": {
      "type": "string",
      "readOnly": true
    },
    "created": {
      "type": "string",
      "readOnly": true
    },
    "modified": {
      "type": "string",
      "readOnly": true
    },
    "name": {
      "type": [
        "string",
        "null"
      ],
      "readOnly": true
    },
    "launch_type": {
      "enum": [
        "manual",
        "relaunch",
        "callback",
        "scheduled",
        "dependency",
        "workflow",
        "webhook",
        "sync",
        "scm"
      ],
      "type": "string",
      "description": "* `manual` - Manual\n* `relaunch` - Relaunch\n* `callback` - Callback\n* `scheduled` - Scheduled\n* `dependency` - Dependency\n* `workflow` - Workflow\n* `webhook` - Webhook\n* `sync` - Sync\n* `scm` - SCM Update",
      "x-spec-enum-id": "e5bed25c2e652da3",
      "readOnly": true
    },
    "status": {
      "enum": [
        "new",
        "pending",
        "waiting",
        "running",
        "successful",
        "failed",
        "error",
        "canceled"
      ],
      "type": "string",
      "description": "* `new` - New\n* `pending` - Pending\n* `waiting` - Waiting\n* `running` - Running\n* `successful` - Successful\n* `failed` - Failed\n* `error` - Error\n* `canceled` - Canceled",
      "x-spec-enum-id": "6021859c28387823",
      "readOnly": true
    },
    "execution_environment": {
      "type": [
        "integer",
        "null"
      ],
      "description": "The container image to be used for execution."
    },
    "failed": {
      "type": "boolean",
      "readOnly": true
    },
    "started": {
      "type": [
        "string",
        "null"
      ],
      "format": "date-time",
      "readOnly": true,
      "description": "The date and time the job was queued for starting."
    },
    "finished": {
      "type": [
        "string",
        "null"
      ],
      "format": "date-time",
      "readOnly": true,
      "description": "The date and time the job finished execution."
    },
    "canceled_on": {
      "type": [
        "string",
        "null"
      ],
      "format": "date-time",
      "readOnly": true,
      "description": "The date and time when the cancel request was sent."
    },
    "elapsed": {
      "type": "string",
      "format": "decimal",
      "pattern": "^-?\\d{0,9}(?:\\.\\d{0,3})?$",
      "readOnly": true,
      "description": "Elapsed time in seconds that the job ran."
    },
    "job_args": {
      "type": "string",
      "readOnly": true
    },
    "job_cwd": {
      "type": "string",
      "readOnly": true
    },
    "job_env": {
      "readOnly": true
    },
    "job_explanation": {
      "type": "string",
      "readOnly": true,
      "description": "A status field to indicate the state of the job if it wasn't able to run and capture stdout"
    },
    "execution_node": {
      "type": "string",
      "readOnly": true,
      "description": "The node the job executed on."
    },
    "controller_node": {
      "type": "string",
      "readOnly": true,
      "description": "The instance that managed the execution environment."
    },
    "result_traceback": {
      "type": "string",
      "readOnly": true
    },
    "event_processing_finished": {
      "type": "boolean",
      "readOnly": true,
      "description": "Indicates whether all of the events generated by this unified job have been saved to the database."
    },
    "launched_by": {
      "type": "string",
      "readOnly": true
    },
    "work_unit_id": {
      "type": [
        "string",
        "null"
      ],
      "readOnly": true,
      "description": "The Receptor work unit ID associated with this job."
    },
    "job_type": {
      "enum": [
        "run",
        "check",
        null
      ],
      "type": [
        "string",
        "null"
      ],
      "description": "* `run` - Run\n* `check` - Check",
      "x-spec-enum-id": "726608a431c1f104",
      "default": "run"
    },
    "inventory": {
      "type": [
        "integer",
        "null"
      ]
    },
    "limit": {
      "type": [
        "string",
        "null"
      ],
      "default": ""
    },
    "credential": {
      "type": [
        "integer",
        "null"
      ]
    },
    "module_name": {
      "enum": [
        "command",
        "shell",
        "yum",
        "apt",
        "apt_key",
        "apt_repository",
        "apt_rpm",
        "service",
        "group",
        "user",
        "mount",
        "ping",
        "selinux",
        "setup",
        "win_ping",
        "win_service",
        "win_updates",
        "win_group",
        "win_user"
      ],
      "type": "string",
      "description": "* `command` - command\n* `shell` - shell\n* `yum` - yum\n* `apt` - apt\n* `apt_key` - apt_key\n* `apt_repository` - apt_repository\n* `apt_rpm` - apt_rpm\n* `service` - service\n* `group` - group\n* `user` - user\n* `mount` - mount\n* `ping` - ping\n* `selinux` - selinux\n* `setup` - setup\n* `win_ping` - win_ping\n* `win_service` - win_service\n* `win_updates` - win_updates\n* `win_group` - win_group\n* `win_user` - win_user",
      "x-spec-enum-id": "857230cdbb58eda2",
      "default": "command"
    },
    "module_args": {
      "type": [
        "string",
        "null"
      ],
      "default": ""
    },
    "forks": {
      "type": "integer",
      "maximum": 9223372036854775807,
      "minimum": 0,
      "format": "int64",
      "default": 0
    },
    "verbosity": {
      "enum": [
        0,
        1,
        2,
        3,
        4,
        5
      ],
      "type": "integer",
      "description": "* `0` - 0 (Normal)\n* `1` - 1 (Verbose)\n* `2` - 2 (More Verbose)\n* `3` - 3 (Debug)\n* `4` - 4 (Connection Debug)\n* `5` - 5 (WinRM Debug)",
      "x-spec-enum-id": "8cfb81af905b865a",
      "default": 0,
      "minimum": 0,
      "maximum": 9223372036854775807
    },
    "extra_vars": {
      "type": [
        "string",
        "null"
      ],
      "default": ""
    },
    "become_enabled": {
      "type": [
        "boolean",
        "null"
      ],
      "default": false
    },
    "diff_mode": {
      "type": [
        "boolean",
        "null"
      ],
      "default": false
    },
    "host_status_counts": {
      "readOnly": true,
      "description": "Playbook stats from the Ansible playbook_on_stats event."
    }
  }
}