All Products
Search
Document Center

Bastionhost:DescribeInstances

Last Updated:Mar 01, 2024

Queries bastion hosts.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer.

Authorization information

There is currently no authorization information disclosed in the API.

Request parameters

ParameterTypeRequiredDescriptionExample
PageNumberintegerNo

The number of the page to return. Default value: 1.

1
PageSizeintegerNo

The number of entries to return on each page. Default value: 10.

10
RegionIdstringNo

The region ID of the bastion host.

cn-hangzhou
InstanceStatusstringNo

The status of the bastion host. Valid values:

  • PENDING: The bastion host is not initialized.
  • CREATING: The bastion host is being created.
  • RUNNING: The bastion host is running.
  • EXPIRED: The bastion host expired.
  • CREATE_FAILED: The bastion host fails to be created.
  • UPGRADING: The configurations of the bastion host are being changed.
  • UPGRADE_FAILED: The configurations of the bastion host fail to be changed.
RUNNING
ResourceGroupIdstringNo

The ID of the resource group to which the bastion host belongs.

rg-acfm26ougi****
InstanceIdarrayNo

An array that consists of the IDs of the bastion hosts.

stringNo

The ID of the bastion host.

2
Tagobject []No

An array consisting of the tags that are added to the bastion hosts.

KeystringNo

The key of the tag.

test
ValuestringNo

The value of the tag.

testapi

Response parameters

ParameterTypeDescriptionExample
object
TotalCountlong

The total number of bastion hosts that are queried.

4
RequestIdstring

The ID of the request, which is used to locate and troubleshoot issues.

61D36C55-AAFC-4678-8FAD-34FEF9E7182E
Instancesobject []

An array that consists of the queried bastion hosts.

VpcIdstring

The ID of the virtual private cloud (VPC) to which the bastion host belongs.

vpc-bp1c85tzgqu1bf5b****
VswitchIdstring

The ID of the vSwitch to which the bastion host belongs.

vsw-bp1xfwzzfti0kjbf****
ImageVersionstring

The image version of the bastion host.

3.0.0
PlanCodestring

The edition of the bastion host. Valid values:

  • cloudbastion: Basic
  • cloudbastion_ha: Enterprise
cloudbastion_ha
Descriptionstring

The description of the bastion host.

Test API
ExpireTimelong

The timestamp when the bastion host expires. Unit: milliseconds.

1578326400000
Legacyboolean

Indicates whether the bastion host runs an earlier version. Valid values:

  • true: indicates that the bastion host runs V2 or V3.1.
  • false:indicates that the bastion host runs V3.2.
false
InstanceIdstring

The ID of the bastion host.

bastionhost-cn-78v1gh****
InternetEndpointstring

The public O&M address of the bastion host.

drawvxalwb-public.bastionhost.aliyuncs.com
RegionIdstring

The region ID of the bastion host.

cn-hangzhou
IntranetEndpointstring

The private O&M address of the bastion host.

drawvxalwb.bastionhost.aliyuncs.com
StartTimelong

The timestamp when the bastion host is purchased or renewed. Unit: milliseconds.

1577681345000
ResourceGroupIdstring

The ID of the resource group to which the bastion host belongs.

g-acfm26ougi****
InstanceStatusstring

The status of the bastion host. Valid values:

  • PENDING: The bastion host is not initialized.
  • CREATING: The bastion host is being created.
  • RUNNING: The bastion host is running.
  • EXPIRED: The bastion host expired.
  • CREATE_FAILED: The bastion host fails to be created.
  • UPGRADING: The configurations of the bastion host are being changed.
  • UPGRADE_FAILED: The configurations of the bastion host fail to be changed.
RUNNING
LicenseCodestring

The license code of the bastion host.

bhah_ent_50_asset
PublicNetworkAccessboolean

Indicates whether the bastion host can be accessed from the Internet. Valid values:

  • true: The bastion host can be accessed from the Internet.
  • false: The bastion host cannot be accessed from the Internet.
true

Examples

Sample success responses

JSONformat

{
  "TotalCount": 4,
  "RequestId": "61D36C55-AAFC-4678-8FAD-34FEF9E7182E",
  "Instances": [
    {
      "VpcId": "vpc-bp1c85tzgqu1bf5b****",
      "VswitchId": "vsw-bp1xfwzzfti0kjbf****",
      "ImageVersion": "3.0.0",
      "PlanCode": "cloudbastion_ha",
      "Description": "Test API\n",
      "ExpireTime": 1578326400000,
      "Legacy": false,
      "InstanceId": "bastionhost-cn-78v1gh****",
      "InternetEndpoint": "drawvxalwb-public.bastionhost.aliyuncs.com",
      "RegionId": "cn-hangzhou",
      "IntranetEndpoint": "drawvxalwb.bastionhost.aliyuncs.com",
      "StartTime": 1577681345000,
      "ResourceGroupId": "g-acfm26ougi****",
      "InstanceStatus": "RUNNING",
      "LicenseCode": "bhah_ent_50_asset",
      "PublicNetworkAccess": true
    }
  ]
}

Error codes

For a list of error codes, visit the Service error codes.