Modifies the endpoint type used for host O&M. Bastionhost supports O&M over the Internet and private networks.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
yundun-bastionhost:ModifyHostsActiveAddressType |
update |
*Instance
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| InstanceId |
string |
Yes |
The instance ID of the Bastionhost instance to which the host whose endpoint type you want to modify belongs. Note
You can invoke the DescribeInstances operation to obtain the value of this parameter. |
bastionhost-cn-st220aw*** |
| RegionId |
string |
No |
The area ID of the Bastionhost instance to which the host whose endpoint type you want to modify belongs. Note
For more information about the mapping between area IDs and area names, see Regions and active zones. |
cn-hangzhou |
| HostIds |
string |
Yes |
The IDs of the hosts whose endpoint types you want to modify. The value is a character string in JSON format. You can specify up to 100 host IDs. You can invoke the ListHosts operation to obtain the value of this parameter. |
["1","2"] |
| ActiveAddressType |
string |
Yes |
The new endpoint type of the host. Valid values:
|
Private |
| ProjectId |
integer |
No |
The project ID. |
3 |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
|||
| RequestId |
string |
The request ID. It is a unique identifier generated by Alibaba Cloud for the request and can be used for troubleshooting. |
EC9BF0F4-8983-491A-BC8C-1B4DD94976DE |
| Results |
array<object> |
The operation result. |
|
|
object |
|||
| Code |
string |
The result code of the operation. Valid values:
|
OK |
| Message |
string |
[Deprecated] This parameter is deprecated and can be ignored. |
None |
| HostId |
string |
The host ID. |
1 |
Examples
Success response
JSON format
{
"RequestId": "EC9BF0F4-8983-491A-BC8C-1B4DD94976DE",
"Results": [
{
"Code": "OK",
"Message": "None",
"HostId": "1"
}
]
}
Error codes
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 400 | InvalidParameter | The argument is invalid. | The argument is invalid. |
| 500 | InternalError | An unknown error occurred. | An unknown error occurred. |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.