Queries instance metadata.

Request parameters

ParameterTypeRequiredExampleDescription
ActionStringYesGetMetadataAmount

The operation that you want to perform.

Set the value to GetMetadataAmount.

RegionIdStringNocn-hangzhou

The ID of the region.

InstanceIdStringNoamqp-cn-v0h1kb9n***

The ID of the instance.

Response parameters

ParameterTypeExampleDescription
DataStruct

The returned data.

CurrentExchangesInteger7

The number of created exchanges.

CurrentQueuesInteger1

The number of created queues.

CurrentVirtualHostsInteger1

The number of created vhosts.

MaxExchangesInteger20

The maximum number of exchanges that can be created.

MaxQueuesInteger20

The maximum number of queues that can be created.

MaxVirtualHostsInteger10

The maximum number of vhosts that can be created.

RequestIdStringB75ACF23-2BEB-44AC-A0B6-AE14EDCA***

The ID of the request.

Examples

Sample requests

http(s)://[Endpoint]/?Action=GetMetadataAmount
&InstanceId=amqp-cn-v0h1kb9n***
&RegionId=cn-hangzhou
&<Common request parameters>

Sample success responses

XML format

<GetMetadataAmountResponse>
      <RequestId>B75ACF23-2BEB-44AC-A0B6-AE14EDCA***</RequestId>
      <Data>
            <MaxExchanges>20</MaxExchanges>
            <MaxVirtualHosts>10</MaxVirtualHosts>
            <CurrentExchanges>7</CurrentExchanges>
            <MaxQueues>20</MaxQueues>
            <CurrentVirtualHosts>1</CurrentVirtualHosts>
            <CurrentQueues>1</CurrentQueues>
      </Data>
</GetMetadataAmountResponse>

JSON format

{
    "RequestId": "B75ACF23-2BEB-44AC-A0B6-AE14EDCA***",
    "Data": {
        "MaxExchanges": 20,
        "MaxVirtualHosts": 10,
        "CurrentExchanges": 7,
        "MaxQueues": 20,
        "CurrentVirtualHosts": 1,
        "CurrentQueues": 1
    }
}

Error codes

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