CreateConsumer

Updated at:
Copy as MD

Creates a consumer.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

No authorization for this operation. If you encounter issues with this operation, contact technical support.

Request syntax

POST  HTTP/1.1

Request parameters

Parameter

Type

Required

Description

Example

GwClusterId

string

Yes

The gateway instance ID.

pg-xxxxxxxxxx

Name

string

Yes

The user name.

test

ConsumerGroupName

string

No

The consumer group name.

cg-p3gk2oh55c**

NickName

string

No

The user nickname.

test

KeyType

string

No

The key type. The only supported value is ApiKey.

ApiKey

RegionId

string

No

The region ID.

cn-beijing

Response elements

Element

Type

Description

Example

object

The response object.

RequestId

string

The request ID.

CD3FA5F3-FAF3-44CA-AFFF-BAF869******

ApiKey

string

The full APIKey, returned only in this response.

6c4b1f0317cd4fd7a5b446d3503d**

KeyType

string

The key type. The value is always ApiKey.

ApiKey

ConsumerId

string

The consumer ID.

c-mqveroemc***

Examples

Success response

JSON format

{
  "RequestId": "CD3FA5F3-FAF3-44CA-AFFF-BAF869******",
  "ApiKey": "6c4b1f0317cd4fd7a5b446d3503d**",
  "KeyType": "ApiKey",
  "ConsumerId": "c-mqveroemc***"
}

Error codes

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.