Need help with your APIs? I offer API discovery, governance & evangelism services. Explore services →
API Evangelist API Evangelist
Discovery
Learnings
Guidance
Toolbox
Alignment
API Evangelist LLC

Kong Consumers API

The consumer object represents a consumer - or a user - of a service.You can either rely on Kong Gateway as the primary datastore, or you can map the consumer list with your database to keep consistency between Kong Gateway and your existing primary datastore.

Kong Consumers API is one of 139 APIs that Kong publishes on the APIs.io network, described by a machine-readable OpenAPI specification.

This API exposes 1 JSON Schema definition.

Tagged areas include Consumers. The published artifact set on APIs.io includes an OpenAPI specification, API documentation, a JSON-LD context, a GitHub repository, an API reference, authentication docs, and 1 JSON Schema.

This API exposes 13 operations across 6 paths, and defines 6 schemas. It is described by OpenAPI 3.1.0, at version 3.14.0.

Requests are made against a single base URL, {protocol}://{hostname}:{port}{path}.

13 operations 6 paths 6 schemas 4 DELETE4 GET3 POST2 PUT

Metadata

The identity and technical contract details declared by the specification.

Specification
OpenAPI 3.1.0
API Version
3.14.0
Base URL
https://konghq.com/
Authentication
API Key
Contact
License
Resource Areas
1

Authentication & Security 1

Kong Consumers API declares 1 security scheme for authenticating requests. An API key is passed in the header as Kong-Admin-Token (adminToken). By default, every request must be authenticated.

Paths & Operations 13

Across 6 paths, the API surfaces 13 operations — 4 DELETE, 4 GET, 3 POST, 2 PUT. Each is listed below with its method, path, parameters, and response codes.

Consumers 13

The consumer object represents a consumer - or a user - of a service. You can either rely on Kong Gateway as the primary datastore, or you can map the consumer list with your data…

POST
/{workspace}/consumers
Create a new Consumer
create-consumer 1 param body → 201401
DELETE
/{workspace}/consumers/{ConsumerIdOrUsername}
Delete a Consumer
delete-consumer 3 params → 204401
GET
/{workspace}/consumers/{ConsumerIdOrUsername}
Get a Consumer
get-consumer 2 params → 200401404
PUT
/{workspace}/consumers/{ConsumerIdOrUsername}
Upsert a Consumer
upsert-consumer 2 params body → 200401
GET
/v2/control-planes/{controlPlaneId}/core-entities/consumers
List all Consumers
list-consumer 7 params → 200401
POST
/v2/control-planes/{controlPlaneId}/core-entities/consumers
Create a new Consumer
create-consumer 1 param body → 201401
DELETE
/v2/control-planes/{controlPlaneId}/core-entities/consumers/{ConsumerId}
Delete a Consumer
delete-consumer 3 params → 204401
GET
/v2/control-planes/{controlPlaneId}/core-entities/consumers/{ConsumerId}
Get a Consumer
get-consumer 2 params → 200401404
PUT
/v2/control-planes/{controlPlaneId}/core-entities/consumers/{ConsumerId}
Upsert a Consumer
upsert-consumer 2 params body → 200401
DELETE
/v2/control-planes/{controlPlaneId}/core-entities/consumers/{ConsumerId}/consumer_groups
Remove consumer from all consumer groups
remove-consumer-from-all-consumer-groups 2 params → 204404
GET
/v2/control-planes/{controlPlaneId}/core-entities/consumers/{ConsumerId}/consumer_groups
List all Consumer Groups a Consumer belongs to
list-consumer-groups-for-consumer 5 params → 200
POST
/v2/control-planes/{controlPlaneId}/core-entities/consumers/{ConsumerId}/consumer_groups
Add consumer to a specific consumer group
add-consumer-to-specific-consumer-group 2 params body → 201
DELETE
/v2/control-planes/{controlPlaneId}/core-entities/consumers/{ConsumerId}/consumer_groups/{ConsumerGroupId}
Remove consumer from consumer group
remove-consumer-from-consumer-group 3 params → 204

Schemas 6

The contract defines 6 schemas that model the data the API accepts and returns. The most detailed are Consumer (6 properties), Consumer_2 (6 properties), ConsumerGroup (5 properties), GatewayUnauthorizedError (2 properties). Each schema is shown below with its type and property counts.

Consumer_2
object
The Consumer object represents a consumer - or a user - of a Service. You can either rely on Kong as the primary datastore, or you can map the consumer list wi…
6 properties
PaginationNextResponse
string
URI to the next page (may be null)
PaginationOffsetResponse
string
Offset is used to paginate through the API. Provide this value to the next list operation to fetch the next page
ConsumerGroup
object
5 properties 1 required
Consumer
object
The Consumer object represents a consumer - or a user - of a Service. You can either rely on Kong as the primary datastore, or you can map the consumer list wi…
6 properties
GatewayUnauthorizedError
object
2 properties 2 required

Specification

The full machine-readable OpenAPI contract behind this narrative.

Source

kong-consumers-api-openapi.yml Raw ↑

Other APIs Kong publishes across the network.

Kong Gateway
Kong AI Gateway
Kong Agent Gateway
Kong MCP Registry
Kong Context Mesh
Kong Mesh
Kong Insomnia
Kong ACLs API
Kong Add-Ons API
Kong API API
Kong API Attributes API
Kong API Documentation API