Configures security groups for a specified Bastionhost instance.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String Yes ConfigInstanceSecurityGroups

The operation that you want to perform.

Set the value to ConfigInstanceSecurityGroups.

AuthorizedSecurityGroups.N RepeatList Yes sg-bp14u00sh39jvw5****

The ID of authorized security group N.

Valid values of N: 1 to 100.

InstanceId String Yes bastionhost-cn-78v1gh****

The ID of the Bastionhost instance.

Note You can call the DescribeInstances operation to obtain the ID of the Bastionhost instance.
RegionId String No cn-hangzhou

The region ID of the Bastionhost instance.

Response parameters

Parameter Type Example Description
InstanceId String bastionhost-cn-78v1gh****

The ID of the Bastionhost instance for which security groups were configured.

RequestId String 0ECCC399-4D35-48A7-8379-5C6180E66235

The ID of the request.

Examples

Sample requests

http(s)://[Endpoint]/?Action=ConfigInstanceSecurityGroups
&AuthorizedSecurityGroups.1=sg-bp14u00sh39jvw5****
&InstanceId=bastionhost-cn-78v1gh****
&<Common request parameters>

Sample success responses

XML format

<ConfigInstanceSecurityGroupsResponse>
      <RequestId>0ECCC399-4D35-48A7-8379-5C6180E66235</RequestId>
      <InstanceId>bastionhost-cn-78v1gh****</InstanceId>
</ConfigInstanceSecurityGroupsResponse>

JSON format

{
    "RequestId":"0ECCC399-4D35-48A7-8379-5C6180E66235",
    "InstanceId":"bastionhost-cn-78v1gh****"
    }

Error codes

For a list of error codes, visit the API Error Center.