Retrieves the configuration and status details of the specified power operation task

Open in ChatGPT Open in ChatGPT to ask questions about this page
Open in Claude Open in Claude to ask questions about this page
Copy as MarkdownCopy this page as markdown to use with AI assistants
View as Markdown Open this page as markdown in a new tab

Returns the configuration and status details of the specified scheduled power operation task, including task name, operation type, target computers, schedule, and current execution status.

Request URL

https://{server-hostname}:8383/dcapi/tools/shutdown/tasks/{taskId}

Scope

Tools.READCopied!

Header

Authorization: d92d4xxxxxxxxxxxxx15f52

Request Parameters

- Request Headers

AcceptstringMandatory
application/jsonapplication/jsonCopied!

- Path Parameters

taskIdstringMandatory

The unique identifier of the task

Sample Request

Curl
Java
Python
Deluge
PowerShell
Copied!
curl --request GET \
  --url https://appdomain/dcapi/tools/shutdown/tasks/{taskId} \
  --header 'Accept: application/json' \
  --header 'Authorization:  d92d4xxxxxxxxxxxxx15f52'

Response Parameters

- HTTP code 200

Response Body - application/json
JSON Object
Hide Sub-Attributes
taskIdlong

Scheduled shutdown task unique identifier

taskNamestring

User-defined task name

operationinteger

Operation type: 1=Shutdown, 2=Restart, 3=Logoff, 4=Lock, 5=Hibernate

operationStrstring

Human-readable operation name

statusstring

Task status: Active, Suspended, Completed

platforminteger

Target platform: 1=Windows, 2=macOS

shutdownMessagestring

Message displayed to end users before the operation

shutdownTimeoutinteger

Timeout in seconds before the operation executes

postPoneEnabledboolean

Whether end users can postpone the operation

skipEnabledboolean

Whether end users can skip the operation

nextRunTimelong

Next scheduled execution time (epoch)

targetCountinteger

Number of target computers

Possible Response Codes

200HTTP code

Sample Response: HTTP 200

Copied!
  {
    "postPoneEnabled": true,
    "operationStr": "Shutdown",
    "nextRunTime": 1711508400000,
    "shutdownTimeout": 300,
    "skipEnabled": false,
    "taskName": "Nightly Shutdown",
    "shutdownMessage": "System will shutdown in 5 minutes.",
    "operation": 1,
    "targetCount": 20,
    "taskId": 5,
    "platform": 1,
    "status": "Active"
  }
                
Show full

Duration: 1 minute | Threshold: 30 | Lock period: 5 minutes

Duration - Time window for the threshold.
Threshold - Number of API calls allowed within the specified duration.
Lock Period - Wait time before consecutive API requests.