Querying Consumers in a Specified Consumer Group
Function
This API is used to query consumers in a specified consumer group.
Calling Method
For details, see Calling APIs.
URI
GET /v2/{engine}/{project_id}/instances/{instance_id}/groups/{group}/members
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| engine | Yes | String | Engine. |
| project_id | Yes | String | Project ID. For details, see Obtaining a Project ID. |
| instance_id | Yes | String | Instance ID. |
| group | Yes | String | Consumer group ID. |
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| offset | No | Integer | Offset, which is the position where the query starts. The value must be greater than or equal to 0. |
| limit | No | Integer | Maximum number of consumers returned in the current query. The default value is 10. The value ranges from 1 to 50. |
| host | No | String | Consumer address. |
| member_id | No | String | Consumer ID. |
Request Parameters
None
Response Parameters
Status code: 200
| Parameter | Type | Description |
|---|---|---|
| members | Array of GroupMemberEntity objects | Consumer details. |
| total | Integer | Total. |
Example Requests
GET https://{endpoint}/v2/{engine}/{project_id}/instances/{instance_id}/groups/{group}/members Example Responses
Status code: 200
Successful
{
"members" : [ {
"member_id" : "consumer-1-6b8ee551-d499-47d4-9beb-ba1527496785",
"client_id" : "consumer-1"
}, {
"member_id" : "consumer-2-6b8ee551-d499-47d4-9beb-ba1527491125",
"client_id" : "consumer-2"
} ],
"total" : 2
} Status Codes
| Status Code | Description |
|---|---|
| 200 | Successful |
Error Codes
See Error Codes.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.