Queries queues.

Request parameters

Parameter Type Required Example Description
Action String Yes ListQueues

The operation that you want to perform.

Set the value to ListQueues.

InstanceId String Yes 1880770869023***

The ID of the instance.

MaxResults Integer Yes 1

The maximum number of result entries to return.

RegionId String Yes cn-hangzhou

The ID of the region.

VirtualHost String Yes test

The name of the vhost.

NextToken String No caeba0bbb2be03f84eb48b699f0a****

The token that marks the end position of the previous returned page. Call the operation again by using the value of the NextToken parameter returned by the previous request to obtain the next set of data. Leave this parameter empty the first time you call this operation. If all results have been returned, the value of NextToken in the response parameter is empty.

Response parameters

Parameter Type Example Description
Data Struct

The returned data.

MaxResults Integer 1

The maximum number of returned result entries.

NextToken String caebacccb2be03f84eb48b699f0a****

The token that marks the end of the current returned page. If this parameter is empty, it indicates that you have retrieved all the data.

Queues Array of QueueVO

An array of queues.

Attributes Map test

The attributes.

AutoDeleteState Boolean false

Indicates whether the Auto Delete attribute is configured.

CreateTime Long 1580887085240

The creation time.

ExclusiveState Boolean false

Indicates whether the queue is an exclusive queue.

LastConsumeTime Long 1680887085240

The last consumption time.

Name String QueueTest

The name of the queue.

OwnerId String 1880770869023***

The ID of the instance.

VHostName String test

The name of the vhost.

RequestId String CE811989-9F02-42CE-97A6-2239CB5C2***

The ID of the request.

Examples

Sample requests

http(s)://[Endpoint]/?Action=ListQueues
&InstanceId=1880770869023***
&MaxResults=1
&RegionId=cn-hangzhou
&VirtualHost=test
&<Common request parameters>

Sample success responses

XML format

<ListQueuesResponse>
      <RequestId>CE811989-9F02-42CE-97A6-2239CB5C2***</RequestId>
      <Data>
            <NextToken>,</NextToken>
            <MaxResults>1</MaxResults>
            <Queues>
                  <VHostName>test</VHostName>
                  <OwnerId>1880770869023***</OwnerId>
                  <CreateTime>1580887085240</CreateTime>
                  <ExclusiveState>false</ExclusiveState>
                  <Attributes>test</Attributes>
                  <LastConsumeTime>1680887085240</LastConsumeTime>
                  <AutoDeleteState>false</AutoDeleteState>
                  <Name>QueueTest</Name>
            </Queues>
      </Data>
</ListQueuesResponse>

JSON format

{
    "RequestId": "CE811989-9F02-42CE-97A6-2239CB5C2***",
    "Data": {
        "NextToken": ",",
        "MaxResults": 1,
        "Queues": {
            "VHostName": "test",
            "OwnerId": "1880770869023***",
            "CreateTime": 1580887085240,
            "ExclusiveState": false,
            "Attributes": "test",
            "LastConsumeTime": 1680887085240,
            "AutoDeleteState": false,
            "Name": "QueueTest"
        }
    }
}

Error codes

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