Queries the security group that is associated with an endpoint.

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 ListVpcEndpointSecurityGroups

The operation that you want to perform. Set the value to ListVpcEndpointSecurityGroups.

EndpointId String Yes ep-hp33b2e43fays7s8****

The ID of the endpoint.

RegionId String Yes eu-west-1

The ID of the region where the endpoint is created. You can call the DescribeRegions operation to query region IDs.

NextToken String No caeba0bbb2be03f84eb48b699f0a4883

The query token. Set this parameter to the NextToken parameter value that is returned in the last API call. If no subsequent queries are to be sent, you can leave the parameter empty.

MaxResults Integer No 50

The number of entries to return on each page. Valid values:1 to 50. Default value: 50.

Response parameters

Parameter Type Example Description
MaxResults String 50

The number of entries to return on each page.

NextToken String caeba0bbb2be03f84eb48b699f0a4883

The token required by the next query. If the NextToken parameter is empty, this indicates that no subsequent query will be sent.

RequestId String 0ED8D006-F706-4D23-88ED-E11ED28DCAC0

The ID of the request.

SecurityGroups Array of SecurityGroup

The information about the security group.

SecurityGroupId String sg-hp33bw6ynvm2yb0e****

The ID of the security group that is associated with the endpoint.

Examples

Sample requests

https://[Endpoint]/?Action=ListVpcEndpointSecurityGroups
&EndpointId=ep-hp33b2e43fays7s8****
&RegionId=eu-west-1
&<Common request parameters>

Sample success responses

XML format

<ListVpcEndpointSecurityGroupsResponse>
      <SecurityGroups>
            <SecurityGroupId>sg-hp3c8qj1tyct90ej****</SecurityGroupId>
      </SecurityGroups>
      <SecurityGroups>
            <SecurityGroupId>sg-hp33bw6ynvm2yb0e****</SecurityGroupId>
      </SecurityGroups>
      <RequestId>8D778FF9-7640-4C13-BCD6-9265CA9A2F81</RequestId>
      <MaxResults>50</MaxResults>
</ListVpcEndpointSecurityGroupsResponse>

JSON format

{
  "SecurityGroups": [
    {
      "SecurityGroupId": "sg-hp3c8qj1tyct90ej****"
    },
    {
      "SecurityGroupId": "sg-hp33bw6ynvm2yb0e****"
    }
  ],
  "RequestId": "8D778FF9-7640-4C13-BCD6-9265CA9A2F81",
  "MaxResults": 50
}

Error codes

HttpCode Error code Error message Description
400 EndpointNotFound The specified Endpoint does not exist. The error message returned because the specified endpoint is not found.

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