Queries the details of a specified O&M task.
Try it now
Test
RAM authorization
Request syntax
POST HTTP/1.1
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| InstanceId |
string |
No |
The instance ID of the bastion host. Note
You can call the DescribeInstances operation to query this parameter. |
bastionhost-cn-st220aw**** |
| RegionId |
string |
No |
The region ID of the bastion host. Note
For the mapping between region IDs and region names, see Regions and zones. |
cn-hangzhou |
| TaskId |
string |
Yes |
The ID of the O&M task that you want to query. |
7 |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
Schema of Response |
||
| RequestId |
string |
The request ID. |
81500666-d7f5-4143-8329-0223cc738105 |
| Task |
object |
The details of the O&M task. |
|
| AllowedOverTime |
integer |
The time when the approval of the O&M task was completed. This value is a UNIX timestamp. Unit: seconds. |
1669965908 |
| Comment |
string |
The remarks of the O&M task. |
comment |
| Name |
string |
The name of the O&M task. |
taskname |
| ScheduleTimeInfo |
string |
The execution plan of the O&M task.
|
{"ExecAt":0,"PeriodNum":0,"PeriodUnit":""} |
| ScheduleType |
string |
The scheduling type of the task.
|
FixTime |
| Script |
string |
The content of the script to be executed by the O&M task. The value is Base64-encoded. |
bHM= |
| ScriptId |
integer |
The ID of the script associated with the O&M task. This parameter is returned only when ScriptType is set to SpecificScript. |
2 |
| ScriptName |
string |
The name of the script associated with the O&M task. |
name |
| ScriptType |
string |
The script type of the O&M task.
|
HandInput |
| TaskId |
string |
The ID of the O&M task. |
1 |
| TaskState |
string |
The status of the O&M task.
|
PendingApproval |
Examples
Success response
JSON format
{
"RequestId": "81500666-d7f5-4143-8329-0223cc738105",
"Task": {
"AllowedOverTime": 1669965908,
"Comment": "comment",
"Name": "taskname",
"ScheduleTimeInfo": "{\"ExecAt\":0,\"PeriodNum\":0,\"PeriodUnit\":\"\"}",
"ScheduleType": "FixTime",
"Script": "bHM=",
"ScriptId": 2,
"ScriptName": "name",
"ScriptType": "HandInput",
"TaskId": "1",
"TaskState": "PendingApproval"
}
}
Error codes
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.