Kong Gateway Admin API

The Kong Gateway Admin API provides a RESTful interface for configuring and managing Kong Gateway instances, including services, routes, plugins, consumers, certificates, RBAC, workspaces, and event hooks. It is the programmatic surface operators use to configure the gateway directly or via decK declarative configuration.

OpenAPI Specification

kong-gateway-admin-api.yml Raw ↑
openapi: 3.1.0
info:
  contact:
    email: [email protected]
    name: Kong Inc
    url: 'https://konghq.com'
  description: |-
    OpenAPI 3.0 spec for Kong Gateway's Admin API.

    You can learn more about Kong Gateway at [developer.konghq.com](https://developer.konghq.com).
    Give Kong a star at the [Kong/kong](https://github.com/kong/kong) repository.
  license:
    name: Apache 2.0
    url: 'https://www.apache.org/licenses/LICENSE-2.0.html'
  title: Kong Enterprise Admin API
  version: 3.14.0
servers:
  - description: Default Admin API URL
    url: '{protocol}://{hostname}:{port}{path}'
    variables:
      hostname:
        default: localhost
        description: Hostname for Kong's Admin API
      path:
        default: /
        description: Base path for Kong's Admin API
      port:
        default: '8001'
        description: Port for Kong's Admin API
      protocol:
        default: http
        description: Protocol for requests to Kong's Admin API
        enum:
          - http
          - https
paths:
  '/{workspace}/certificates':
    post:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: Certificate#create
      operationId: create-certificate
      summary: Create a new Certificate
      description: Create a new Certificate
      parameters:
        - $ref: '#/components/parameters/Workspace'
      requestBody:
        description: Description of the new Certificate for creation
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Certificate'
      responses:
        '201':
          description: Successfully created Certificate
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Certificate'
        '401':
          $ref: '#/components/responses/HTTP401Error'
      tags:
        - Certificates
  '/{workspace}/certificates/{CertificateId}':
    delete:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: Certificate#delete
      operationId: delete-certificate
      summary: Delete a Certificate
      description: Delete a Certificate
      parameters:
        - $ref: '#/components/parameters/CertificateId'
        - $ref: '#/components/parameters/Workspace'
      responses:
        '204':
          description: Successfully deleted Certificate or the resource didn't exist
        '401':
          $ref: '#/components/responses/HTTP401Error'
      tags:
        - Certificates
    get:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: Certificate#read
      operationId: get-certificate
      summary: Get a Certificate
      description: Get a Certificate using ID.
      parameters:
        - $ref: '#/components/parameters/Workspace'
      responses:
        '200':
          description: Successfully fetched Certificate
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Certificate'
        '401':
          $ref: '#/components/responses/HTTP401Error'
        '404':
          description: Resource does not exist
      tags:
        - Certificates
    parameters:
      - $ref: '#/components/parameters/CertificateId'
    put:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: Certificate#update
      operationId: upsert-certificate
      summary: Upsert a Certificate
      description: Create or Update Certificate using ID.
      parameters:
        - $ref: '#/components/parameters/Workspace'
      requestBody:
        description: Description of the Certificate
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Certificate'
      responses:
        '200':
          description: Successfully upserted Certificate
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Certificate'
        '401':
          $ref: '#/components/responses/HTTP401Error'
      tags:
        - Certificates
  '/{workspace}/consumer_groups':
    post:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: ConsumerGroup#create
      operationId: create-consumer_group
      summary: Create a new Consumer Group
      description: Create a new Consumer Group
      parameters:
        - $ref: '#/components/parameters/Workspace'
      requestBody:
        description: Description of the new Consumer Group for creation
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ConsumerGroup'
      responses:
        '201':
          description: Successfully created Consumer Group
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ConsumerGroup'
        '401':
          $ref: '#/components/responses/HTTP401Error'
      tags:
        - Consumer Groups
  '/{workspace}/consumer_groups/{ConsumerGroupId}':
    delete:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: ConsumerGroup#delete
      operationId: delete-consumer_group
      summary: Delete a Consumer Group
      description: Delete a Consumer Group
      parameters:
        - $ref: '#/components/parameters/ConsumerGroupId'
        - $ref: '#/components/parameters/Workspace'
      responses:
        '204':
          description: Successfully deleted Consumer Group or the resource didn't exist
        '401':
          $ref: '#/components/responses/HTTP401Error'
      tags:
        - Consumer Groups
    get:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: ConsumerGroup#read
      operationId: get-consumer_group
      summary: Get a Consumer Group
      description: Get a Consumer Group using ID.
      parameters:
        - $ref: '#/components/parameters/Workspace'
      responses:
        '200':
          description: Successfully fetched Consumer Group
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ConsumerGroupInsideWrapper'
        '401':
          $ref: '#/components/responses/HTTP401Error'
        '404':
          description: Resource does not exist
      tags:
        - Consumer Groups
    parameters:
      - $ref: '#/components/parameters/ConsumerGroupId'
    put:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: ConsumerGroup#update
      operationId: upsert-consumer_group
      summary: Upsert a Consumer Group
      description: Create or Update Consumer Group using ID.
      parameters:
        - $ref: '#/components/parameters/Workspace'
      requestBody:
        description: Description of the Consumer Group
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ConsumerGroup'
      responses:
        '200':
          description: Successfully upserted Consumer Group
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ConsumerGroup'
        '401':
          $ref: '#/components/responses/HTTP401Error'
      tags:
        - Consumer Groups
  '/{workspace}/consumer_groups/{ConsumerGroupId}/consumers':
    parameters:
      - $ref: '#/components/parameters/ConsumerGroupIdManageConsumers'
    post:
      x-speakeasy-entity-operation: ConsumerGroupMember#create
      operationId: add-consumer-to-group
      summary: Add consumer to consumer group
      description: Add a consumer to a consumer group
      parameters:
        - $ref: '#/components/parameters/Workspace'
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                consumer:
                  type: string
                  example: cf4c7e60-11db-49dd-b300-7c7e5f0f7e6b
                  x-speakeasy-name-override: consumer_id
      responses:
        '201':
          description: Consumer added to group
          content:
            application/json:
              schema:
                type: object
                properties:
                  consumer_group:
                    $ref: '#/components/schemas/ConsumerGroup'
                  consumers:
                    type: array
                    items:
                      $ref: '#/components/schemas/Consumer'
      tags:
        - Consumer Groups
  '/{workspace}/consumer_groups/{ConsumerGroupId}/consumers/{ConsumerIdOrUsername}':
    delete:
      x-speakeasy-entity-operation: ConsumerGroupMember#delete
      operationId: remove-consumer-from-group
      summary: Remove consumer from consumer group
      description: Remove a consumer from a consumer group
      parameters:
        - $ref: '#/components/parameters/Workspace'
      responses:
        '204':
          description: Consumer removed from group
      tags:
        - Consumer Groups
    parameters:
      - $ref: '#/components/parameters/ConsumerGroupIdManageConsumers'
      - name: ConsumerIdOrUsername
        in: path
        required: true
        schema:
          type: string
        x-speakeasy-name-override: consumer_id
  '/{workspace}/consumers':
    post:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: Consumer#create
      operationId: create-consumer
      summary: Create a new Consumer
      description: Create a new Consumer
      parameters:
        - $ref: '#/components/parameters/Workspace'
      requestBody:
        description: Description of the new Consumer for creation
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Consumer'
      responses:
        '201':
          description: Successfully created Consumer
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Consumer'
        '401':
          $ref: '#/components/responses/HTTP401Error'
      tags:
        - Consumers
  '/{workspace}/consumers/{ConsumerIdForNestedEntities}/acls':
    post:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: ACL#create
      operationId: create-acl-with-consumer
      summary: Create a new ACL associated with a Consumer
      description: Create a new ACL associated with a Consumer
      parameters:
        - $ref: '#/components/parameters/ConsumerIdForNestedEntities'
        - $ref: '#/components/parameters/Workspace'
      requestBody:
        description: Description of new ACL for creation
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ACLWithoutParents'
      responses:
        '201':
          description: Successfully created ACL
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ACL'
      tags:
        - ACLs
  '/{workspace}/consumers/{ConsumerIdForNestedEntities}/acls/{ACLId}':
    delete:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: ACL#delete
      operationId: delete-acl-with-consumer
      summary: Delete a an ACL associated with a Consumer
      description: Delete a an ACL associated with a Consumer using ID.
      parameters:
        - $ref: '#/components/parameters/ConsumerIdForNestedEntities'
        - $ref: '#/components/parameters/ACLId'
        - $ref: '#/components/parameters/Workspace'
      responses:
        '204':
          description: Successfully deleted ACL or the resource didn't exist
      tags:
        - ACLs
    get:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: ACL#read
      operationId: get-acl-with-consumer
      summary: Get an ACL associated with a Consumer
      description: Get an ACL associated with a Consumer using ID.
      parameters:
        - $ref: '#/components/parameters/ConsumerIdForNestedEntities'
        - $ref: '#/components/parameters/ACLId'
        - $ref: '#/components/parameters/Workspace'
      responses:
        '200':
          description: Successfully fetched ACL
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ACL'
        '404':
          description: Resource does not exist
      tags:
        - ACLs
  '/{workspace}/consumers/{ConsumerIdForNestedEntities}/basic-auth':
    post:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: BasicAuth#create
      operationId: create-basic-auth-with-consumer
      summary: Create a new Basic-auth credential associated with a Consumer
      description: Create a new Basic-auth credential associated with a Consumer
      parameters:
        - $ref: '#/components/parameters/ConsumerIdForNestedEntities'
        - $ref: '#/components/parameters/Workspace'
      requestBody:
        description: Description of new Basic-auth credential for creation
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/BasicAuthWithoutParents'
      responses:
        '201':
          description: Successfully created Basic-auth credential
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BasicAuth'
      tags:
        - Basic-auth credentials
  '/{workspace}/consumers/{ConsumerIdForNestedEntities}/basic-auth/{BasicAuthId}':
    delete:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: BasicAuth#delete
      operationId: delete-basic-auth-with-consumer
      summary: Delete a a Basic-auth credential associated with a Consumer
      description: Delete a a Basic-auth credential associated with a Consumer using ID.
      parameters:
        - $ref: '#/components/parameters/ConsumerIdForNestedEntities'
        - $ref: '#/components/parameters/BasicAuthId'
        - $ref: '#/components/parameters/Workspace'
      responses:
        '204':
          description: Successfully deleted Basic-auth credential or the resource didn't exist
      tags:
        - Basic-auth credentials
    get:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: BasicAuth#read
      operationId: get-basic-auth-with-consumer
      summary: Get a Basic-auth credential associated with a Consumer
      description: Get a Basic-auth credential associated with a Consumer using ID.
      parameters:
        - $ref: '#/components/parameters/ConsumerIdForNestedEntities'
        - $ref: '#/components/parameters/BasicAuthId'
        - $ref: '#/components/parameters/Workspace'
      responses:
        '200':
          description: Successfully fetched Basic-auth credential
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BasicAuth'
        '404':
          description: Resource does not exist
      tags:
        - Basic-auth credentials
  '/{workspace}/consumers/{ConsumerIdForNestedEntities}/hmac-auth':
    post:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: HMACAuth#create
      operationId: create-hmac-auth-with-consumer
      summary: Create a new HMAC-auth credential associated with a Consumer
      description: Create a new HMAC-auth credential associated with a Consumer
      parameters:
        - $ref: '#/components/parameters/ConsumerIdForNestedEntities'
        - $ref: '#/components/parameters/Workspace'
      requestBody:
        description: Description of new HMAC-auth credential for creation
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/HMACAuthWithoutParents'
      responses:
        '201':
          description: Successfully created HMAC-auth credential
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HMACAuth'
      tags:
        - HMAC-auth credentials
  '/{workspace}/consumers/{ConsumerIdForNestedEntities}/hmac-auth/{HMACAuthId}':
    delete:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: HMACAuth#delete
      operationId: delete-hmac-auth-with-consumer
      summary: Delete a a HMAC-auth credential associated with a Consumer
      description: Delete a a HMAC-auth credential associated with a Consumer using ID.
      parameters:
        - $ref: '#/components/parameters/ConsumerIdForNestedEntities'
        - $ref: '#/components/parameters/HMACAuthId'
        - $ref: '#/components/parameters/Workspace'
      responses:
        '204':
          description: Successfully deleted HMAC-auth credential or the resource didn't exist
      tags:
        - HMAC-auth credentials
    get:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: HMACAuth#read
      operationId: get-hmac-auth-with-consumer
      summary: Get a HMAC-auth credential associated with a Consumer
      description: Get a HMAC-auth credential associated with a Consumer using ID.
      parameters:
        - $ref: '#/components/parameters/ConsumerIdForNestedEntities'
        - $ref: '#/components/parameters/HMACAuthId'
        - $ref: '#/components/parameters/Workspace'
      responses:
        '200':
          description: Successfully fetched HMAC-auth credential
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HMACAuth'
        '404':
          description: Resource does not exist
      tags:
        - HMAC-auth credentials
  '/{workspace}/consumers/{ConsumerIdForNestedEntities}/jwt':
    post:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: JWT#create
      operationId: create-jwt-with-consumer
      summary: Create a new JWT associated with a Consumer
      description: Create a new JWT associated with a Consumer
      parameters:
        - $ref: '#/components/parameters/ConsumerIdForNestedEntities'
        - $ref: '#/components/parameters/Workspace'
      requestBody:
        description: Description of new JWT for creation
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/JWTWithoutParents'
      responses:
        '201':
          description: Successfully created JWT
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/JWT'
      tags:
        - JWTs
  '/{workspace}/consumers/{ConsumerIdForNestedEntities}/jwt/{JWTId}':
    delete:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: JWT#delete
      operationId: delete-jwt-with-consumer
      summary: Delete a a JWT associated with a Consumer
      description: Delete a a JWT associated with a Consumer using ID.
      parameters:
        - $ref: '#/components/parameters/ConsumerIdForNestedEntities'
        - $ref: '#/components/parameters/JWTId'
        - $ref: '#/components/parameters/Workspace'
      responses:
        '204':
          description: Successfully deleted JWT or the resource didn't exist
      tags:
        - JWTs
    get:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: JWT#read
      operationId: get-jwt-with-consumer
      summary: Get a JWT associated with a Consumer
      description: Get a JWT associated with a Consumer using ID.
      parameters:
        - $ref: '#/components/parameters/ConsumerIdForNestedEntities'
        - $ref: '#/components/parameters/JWTId'
        - $ref: '#/components/parameters/Workspace'
      responses:
        '200':
          description: Successfully fetched JWT
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/JWT'
        '404':
          description: Resource does not exist
      tags:
        - JWTs
  '/{workspace}/consumers/{ConsumerIdForNestedEntities}/key-auth':
    post:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: KeyAuth#create
      operationId: create-key-auth-with-consumer
      summary: Create a new API-key associated with a Consumer
      description: Create a new API-key associated with a Consumer
      parameters:
        - $ref: '#/components/parameters/ConsumerIdForNestedEntities'
        - $ref: '#/components/parameters/Workspace'
      requestBody:
        description: Description of new API-key for creation
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/KeyAuthWithoutParents'
      responses:
        '201':
          description: Successfully created API-key
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/KeyAuth'
      tags:
        - API-keys
  '/{workspace}/consumers/{ConsumerIdForNestedEntities}/key-auth/{KeyAuthId}':
    delete:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: KeyAuth#delete
      operationId: delete-key-auth-with-consumer
      summary: Delete a an API-key associated with a Consumer
      description: Delete a an API-key associated with a Consumer using ID.
      parameters:
        - $ref: '#/components/parameters/ConsumerIdForNestedEntities'
        - $ref: '#/components/parameters/KeyAuthId'
        - $ref: '#/components/parameters/Workspace'
      responses:
        '204':
          description: Successfully deleted API-key or the resource didn't exist
      tags:
        - API-keys
    get:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: KeyAuth#read
      operationId: get-key-auth-with-consumer
      summary: Get an API-key associated with a Consumer
      description: Get an API-key associated with a Consumer using ID.
      parameters:
        - $ref: '#/components/parameters/ConsumerIdForNestedEntities'
        - $ref: '#/components/parameters/KeyAuthId'
        - $ref: '#/components/parameters/Workspace'
      responses:
        '200':
          description: Successfully fetched API-key
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/KeyAuth'
        '404':
          description: Resource does not exist
      tags:
        - API-keys
  '/{workspace}/consumers/{ConsumerIdForNestedEntities}/mtls-auth':
    post:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: MTLSAuth#create
      operationId: create-mtls-auth-with-consumer
      summary: Create a new MTLS-auth credential associated with a Consumer
      description: Create a new MTLS-auth credential associated with a Consumer
      parameters:
        - $ref: '#/components/parameters/ConsumerIdForNestedEntities'
        - $ref: '#/components/parameters/Workspace'
      requestBody:
        description: Description of new MTLS-auth credential for creation
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/MTLSAuthWithoutParents'
      responses:
        '201':
          description: Successfully created MTLS-auth credential
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/MTLSAuth'
      tags:
        - MTLS-auth credentials
  '/{workspace}/consumers/{ConsumerIdForNestedEntities}/mtls-auth/{MTLSAuthId}':
    delete:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: MTLSAuth#delete
      operationId: delete-mtls-auth-with-consumer
      summary: Delete a a MTLS-auth credential associated with a Consumer
      description: Delete a a MTLS-auth credential associated with a Consumer using ID.
      parameters:
        - $ref: '#/components/parameters/ConsumerIdForNestedEntities'
        - $ref: '#/components/parameters/MTLSAuthId'
        - $ref: '#/components/parameters/Workspace'
      responses:
        '204':
          description: Successfully deleted MTLS-auth credential or the resource didn't exist
      tags:
        - MTLS-auth credentials
    get:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: MTLSAuth#read
      operationId: get-mtls-auth-with-consumer
      summary: Get a MTLS-auth credential associated with a Consumer
      description: Get a MTLS-auth credential associated with a Consumer using ID.
      parameters:
        - $ref: '#/components/parameters/ConsumerIdForNestedEntities'
        - $ref: '#/components/parameters/MTLSAuthId'
        - $ref: '#/components/parameters/Workspace'
      responses:
        '200':
          description: Successfully fetched MTLS-auth credential
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/MTLSAuth'
        '404':
          description: Resource does not exist
      tags:
        - MTLS-auth credentials
  '/{workspace}/consumers/{ConsumerIdOrUsername}':
    delete:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: Consumer#delete
      operationId: delete-consumer
      summary: Delete a Consumer
      description: Delete a Consumer
      parameters:
        - $ref: '#/components/parameters/ConsumerIdOrUsername'
        - $ref: '#/components/parameters/Workspace'
      responses:
        '204':
          description: Successfully deleted Consumer or the resource didn't exist
        '401':
          $ref: '#/components/responses/HTTP401Error'
      tags:
        - Consumers
    get:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: Consumer#read
      operationId: get-consumer
      summary: Get a Consumer
      description: Get a Consumer using ID or username.
      parameters:
        - $ref: '#/components/parameters/Workspace'
      responses:
        '200':
          description: Successfully fetched Consumer
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Consumer'
        '401':
          $ref: '#/components/responses/HTTP401Error'
        '404':
          description: Resource does not exist
      tags:
        - Consumers
    parameters:
      - $ref: '#/components/parameters/ConsumerIdOrUsername'
    put:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: Consumer#update
      operationId: upsert-consumer
      summary: Upsert a Consumer
      description: Create or Update Consumer using ID or username.
      parameters:
        - $ref: '#/components/parameters/Workspace'
      requestBody:
        description: Description of the Consumer
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Consumer'
      responses:
        '200':
          description: Successfully upserted Consumer
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Consumer'
        '401':
          $ref: '#/components/responses/HTTP401Error'
      tags:
        - Consumers
  '/{workspace}/key-sets':
    post:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: KeySet#create
      operationId: create-key-set
      summary: Create a new KeySet
      description: Create a new KeySet
      parameters:
        - $ref: '#/components/parameters/Workspace'
      requestBody:
        description: Description of the new KeySet for creation
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/KeySet'
      responses:
        '201':
          description: Successfully created KeySet
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/KeySet'
        '401':
          $ref: '#/components/responses/HTTP401Error'
      tags:
        - KeySets
  '/{workspace}/key-sets/{KeySetIdOrName}':
    delete:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: KeySet#delete
      operationId: delete-key-set
      summary: Delete a KeySet
      description: Delete a KeySet
      parameters:
        - $ref: '#/components/parameters/KeySetIdOrName'
        - $ref: '#/components/parameters/Workspace'
      responses:
        '204':
          description: Successfully deleted KeySet or the resource didn't exist
        '401':
          $ref: '#/components/responses/HTTP401Error'
      tags:
        - KeySets
    get:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: KeySet#read
      operationId: get-key-set
      summary: Get a KeySet
      description: Get a KeySet using ID or name.
      parameters:
        - $ref: '#/components/parameters/Workspace'
      responses:
        '200':
          description: Successfully fetched KeySet
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/KeySet'
        '401':
          $ref: '#/components/responses/HTTP401Error'
        '404':
          description: Resource does not exist
      tags:
        - KeySets
    parameters:
      - $ref: '#/components/parameters/KeySetIdOrName'
    put:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: KeySet#update
      operationId: upsert-key-set
      summary: Upsert a KeySet
      description: Create or Update KeySet using ID or name.
      parameters:
        - $ref: '#/components/parameters/Workspace'
      requestBody:
        description: Description of the KeySet
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/KeySet'
      responses:
        '200':
          description: Successfully upserted KeySet
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/KeySet'
        '401':
          $ref: '#/components/responses/HTTP401Error'
      tags:
        - KeySets
  '/{workspace}/keys':
    post:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: Key#create
      operationId: create-key
      summary: Create a new Key
      description: Create a new Key
      parameters:
        - $ref: '#/components/parameters/Workspace'
      requestBody:
        description: Description of the new Key for creation
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Key'
      responses:
        '201':
          description: Successfully created Key
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Key'
        '401':
          $ref: '#/components/responses/HTTP401Error'
      tags:
        - Keys
  '/{workspace}/keys/{KeyIdOrName}':
    delete:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: Key#delete
      operationId: delete-key
      summary: Delete a Key
      description: Delete a Key
      parameters:
        - $ref: '#/components/parameters/KeyIdOrName'
        - $ref: '#/components/parameters/Workspace'
      responses:
        '204':
          description: Successfully deleted Key or the resource didn't exist
        '401':
          $ref: '#/components/responses/HTTP401Error'
      tags:
        - Keys
    get:
      x-speakeasy-entity-operation:
        terraform-datasource: null
        terraform-resource: Key#read
      operationId: get-key
      summary: Get a Key
      description: Get a Key using ID or name.
      parameters:
        - $ref: '#/components/parameters/Workspace'
      responses:
        '200':
          description: Successfully fetched Key
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Key'
        '401':
          $ref: '#/component

# --- truncated at 32 KB (1799 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/kong/refs/heads/main/openapi/kong-gateway-admin-api.yml