All Products
Search
Document Center

Message Queue for Apache Kafka:GetConsumerList

Last Updated:Nov 18, 2022

Queries one or more consumer groups in a specified Message Queue for Apache Kafka instance.

Authorization information

There is currently no authorization information disclosed in the API.

Request parameters

ParameterTypeRequiredDescriptionExample
InstanceIdstringYes

The ID of the instance to which the consumer group belongs.

alikafka_post-cn-v0h18sav****
RegionIdstringYes

The region ID of the instance to which the consumer group belongs.

cn-hangzhou
ConsumerIdstringNo

The ID of the consumer group. If you do not configure this parameter, all consumer groups are queried.

kafka-test

Response parameters

ParameterTypeDescriptionExample
object
Codeinteger

The HTTP status code returned. The HTTP status code 200 indicates that the request is successful.

200
Messagestring

The returned message.

operation success.
RequestIdstring

The ID of the request.

808F042B-CB9A-4FBC-9009-00E7DDB6****
Successboolean

Indicates whether the request is successful.

true
ConsumerListarray

The information about the consumer groups.

object
ConsumerIdstring

The name of the consumer group.

kafka-test
InstanceIdstring

The ID of the instance.

alikafka_post-cn-v0h18sav****
Remarkstring

The description of the consumer group.

test
RegionIdstring

The region ID of the instance.

cn-hangzhou
Tagsarray

The tags that are attached to the consumer group.

object
Keystring

The key of the tag.

test
Valuestring

The value of the tag.

test

Example

Normal return example

JSONFormat

{
  "Code": 200,
  "Message": "operation success.",
  "RequestId": "808F042B-CB9A-4FBC-9009-00E7DDB6****",
  "Success": true,
  "ConsumerList": [
    {
      "ConsumerId": "kafka-test",
      "InstanceId": "alikafka_post-cn-v0h18sav****",
      "Remark": "test",
      "RegionId": "cn-hangzhou",
      "Tags": [
        {
          "Key": "test",
          "Value": "test"
        }
      ]
    }
  ]
}

Error codes

For a list of error codes, visit the API error center.