Queries the maintenance attributes of an instance.
Operation description
This operation is used to query the specified maintenance policy of an instance, which contains the following maintenance attributes:
- Maintenance window: the time period that you specify for maintenance.
- Maintenance action: the action that you specify in response to instance shutdown.
Debugging
Authorization information
There is currently no authorization information disclosed in the API.
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
RegionId | string | Yes | The region ID of the instance. You can call the DescribeRegions operation to query the most recent region list. | cn-hangzhou |
PageNumber | long | No | The page number. Pages start from page 1. Default value: 1. | 1 |
PageSize | long | No | The number of entries per page. Valid values: 1 to 100. Default value: 10. | 10 |
InstanceId | array | No | The instance IDs. You can specify up to 100 instance IDs. | |
string | No | The instance ID. | i-bp67acfmxazb4p**** |
Response parameters
Examples
Sample success responses
JSON
format
{
"PageSize": 10,
"RequestId": "473469C7-AA6F-4DC5-B3DB-A3DC0DE3C83E",
"PageNumber": 1,
"TotalCount": 100,
"MaintenanceAttributes": {
"MaintenanceAttribute": [
{
"NotifyOnMaintenance": false,
"InstanceId": "i-bp67acfmxazb4p****",
"MaintenanceWindows": {
"MaintenanceWindow": [
{
"EndTime": "18:00:00",
"StartTime": "02:00:00"
}
]
},
"ActionOnMaintenance": {
"DefaultValue": "AutoRecover",
"Value": "Stop",
"SupportedValues": {
"SupportedValue": [
"Stop"
]
}
}
}
]
}
}
Error codes
HTTP status code | Error code | Error message | Description |
---|---|---|---|
400 | MissingParameter | %s | A parameter is not specified. |
403 | InvalidParameter | %s | The specified parameter is invalid. |
403 | InstanceIdLimitExceeded | %s | More than 100 instance IDs are specified. |
403 | OperationDenied.NotInWhiteList | %s | You are not authorized to perform this operation. Try again when you are authorized. |
404 | InvalidInstanceId.NotFound | The specified InstanceId does not exist. | The specified instance does not exist. |
For a list of error codes, visit the Service error codes.