To send a Bastionhost API request, you must send an HTTP GET request to the Bastionhost endpoint. You must add the request parameters that correspond to the API operation being called. After you call the API operation, the system returns a response. The request and response are encoded in UTF-8.

Request structure

Bastionhost API operations use the RPC protocol. You can call Bastionhost API operations by sending HTTP GET requests.

The request syntax is as follows:
  • Endpoint: The endpoint of the Bastionhost API is
    Note The endpoint of the Bastionhost API in a region is the value of the RegionEndpoint parameter of the region returned by the DescribeRegions operation.
  • Action: the name of the operation being performed. For example, to query created Bastionhost instances, you must set the Action parameter to DescribeInstances.
  • Version: the version number of the API. Set the value to 2019-12-09.
  • Parameters: the request parameters for the operation. Separate multiple parameters with ampersands (&).

    Request parameters include both common parameters and operation-specific parameters. Common parameters include the API version and authentication information. For more information, see Common parameters.

The following example demonstrates how to call the DescribeInstances operation to query created Bastionhost instances:
Note The following code has been formatted to ease reading.