Queries the details about an instance, such as instance ID and description.

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 DescribeInstanceAttribute

The operation that you want to perform.

Set the value to DescribeInstanceAttribute.

InstanceId String Yes bastionhost-cn-78v1ghxxxxx

The ID of the Bastionhost instance.

RegionId String No cn-hangzhou

The ID of the region.

Response parameters

Parameter Type Example Description
RequestId String 082FAB35-6AB9-4FD5-8750-D36673548E76

The ID of the request.

InstanceAttribute Struct

The attribute information of the instance.

InstanceId String bastionhost-cn-78v1ghxxxxx

The ID of the instance.

InstanceStatus String RUNNING

The status of the instance. Valid values:

  • PENDING: The instance is not initialized.
  • CREATING: The instance is being created.
  • RUNNING: The instance is running.
  • EXPIRED: The instance expired.
  • CREATE_FAILED: The instance fails to be created.
  • UPGRADING: The configurations of the instance are being changed.
  • UPGRADE_FAILED: The configurations of the instance fail to be changed.
VpcId String vpc-bp1c85tzgqu1bf5bxxxxx

The ID of the VPC to which the instance belongs.

VswitchId String vsw-bp1xfwzzfti0kjbfxxxxx

The ID of the VSwitch to which the instance belongs.

IntranetEndpoint String drawvxalwb.bastionhost.aliyuncs.com

The private endpoint.

InternetEndpoint String drawvxalwb-public.bastionhost.aliyuncs.com

The public endpoint.

PublicNetworkAccess Boolean true

Indicates whether the Bastionhost instance can be accessed over the Internet.

EniInstanceId String eni-bp1455jrzwm7moaxxxxx

The ID of the Elastic Network Interface (ENI).

StartTime Long 1577681345000

The time when the instance started.

ExpireTime Long 1578326400000

The time when the instance expires.

Description String Test API operation

The description of the instance.

LicenseCode String bhah_ent_50_asset

The license code.

PublicWhiteList List [10.162.168.xx/32]

The public IP addresses that are allowed to access the instance.

PrivateWhiteList List []

The private IP addresses that are allowed to access the instance.

SecurityGroupIds List []

The IDs of the security groups to which the instance belongs.

AuthorizedSecurityGroups List [sg-bp14u00sh39jvw5xxxxx]

The IDs of authorized security groups.

Examples

Sample requests

http(s)://[Endpoint]/?Action=DescribeInstanceAttribute
&InstanceId=bastionhost-cn-78v1ghxxxxx
&<Common request parameters>

Sample success responses

XML format

<DescribeInstanceAttributeResponse>
    <RequestId>082FAB35-6AB9-4FD5-8750-D36673548E76</RequestId>
    <InstanceAttribute>
        <LicenseCode>bhah_ent_50_asset</LicenseCode>
        <Description>Test API operation</Description>
        <InstanceId>bastionhost-cn-78v1ghxxxxx</InstanceId>
        <StartTime>1577681345000</StartTime>
        <VswitchId>vsw-bp1xfwzzfti0kjbfxxxxx</VswitchId>
        <PublicWhiteList>10.162.168.xx/32</PublicWhiteList>
        <VpcId>vpc-bp1c85tzgqu1bf5bxxxxx</VpcId>
        <PublicNetworkAccess>true</PublicNetworkAccess>
        <AuthorizedSecurityGroups>sg-bp14u00sh39jvw5xxxxx</AuthorizedSecurityGroups>
        <InstanceStatus>RUNNING</InstanceStatus>
        <EniInstanceId>eni-bp1455jrzwm7moaxxxxx</EniInstanceId>
        <InternetEndpoint>drawvxalwb-public.bastionhost.aliyuncs.com</InternetEndpoint>
        <ExpireTime>1578326400000</ExpireTime>
        <IntranetEndpoint>drawvxalwb.bastionhost.aliyuncs.com</IntranetEndpoint>
    </InstanceAttribute>
</DescribeInstanceAttributeResponse>

JSON format

{
    "RequestId":"082FAB35-6AB9-4FD5-8750-D36673548E76",
    "InstanceAttribute":{
        "LicenseCode":"bhah_ent_50_asset",
        "Description":"Test API operation",
        "InstanceId":"bastionhost-cn-78v1ghxxxxx",
        "PrivateWhiteList":[],
        "StartTime":1577681345000,
        "SecurityGroupIds":[],
        "VswitchId":"vsw-bp1xfwzzfti0kjbfxxxxx",
        "PublicWhiteList":[
            "10.162.168.xx/32"
        ],
        "VpcId":"vpc-bp1c85tzgqu1bf5bxxxxx",
        "PublicNetworkAccess":true,
        "AuthorizedSecurityGroups":[
            "sg-bp14u00sh39jvw5xxxxx"
        ],
        "InstanceStatus":"RUNNING",
        "EniInstanceId":"eni-bp1455jrzwm7moaxxxxx",
        "InternetEndpoint":"drawvxalwb-public.bastionhost.aliyuncs.com",
        "ExpireTime":1578326400000,
        "IntranetEndpoint":"drawvxalwb.bastionhost.aliyuncs.com"
    }
}

Error codes

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