kongctl 선언형 리소스 참조
kongctl 선언형 리소스 참조 (kongctl Declarative Resource Reference)
이 문서는 kongctl 선언형 구성에서 사용할 수 있는 리소스 타입을 한눈에 확인할 수 있는 참조 자료예요. 지원되는 리소스 타입과 필드별 공통 값을 정리하고, 리소스 구성은 YAML 파일 하나 이상으로 작성해서 kongctl 선언형 명령어에 전달하는 방식이에요. 정확한 스키마는 사용 중인 CLI가 직접 생성하니까 kongctl explain이나 kongctl scaffold로 확인하는 게 가장 확실해요. 파일 수준 기본값, 구성 템플릿, YAML 태그 같은 핵심 개념부터 API, 포털, AI Gateway 같은 리소스별 항목까지 함께 다뤄요
출처: 문서
본문
지원되는 리소스 타입과 일반적인 필드 수준 값을 나열해요. 리소스 구성은 YAML 파일로 제공되며, kongctl declarative 명령에 전달하는 하나 이상의 파일로 표현할 수 있어요.
사용 중인 kongctl 버전의 확정 스키마는 CLI 자체에서 생성해요. 예시 명령은 다음을 포함해요:
kongctl explain api
kongctl explain portal.identity_providers --output yaml
kongctl scaffold api
kongctl explain을 사용해 허용되는 필드 이름, 필수 필드, 선호되는 YAML 태그, 루트 키, 중첩 또는 루트 선언 지원 여부를 확인하세요.
kongctl scaffold를 사용해 리소스 타입의 시작용 YAML을 생성하세요.
이 페이지가 설치된 CLI와 다르면 CLI 출력을 따르세요.
이 리소스들을 선언적으로 관리하는 방법은 선언적 구성 가이드를 참고하세요.
파일 수준 기본값
_defaults.kongctl을 사용해 이 파일의 부모 리소스에 기본 namespace와 protected 메타데이터를 적용하세요.
리소스 수준의 kongctl 값이 이 기본값을 재정의해요.
_defaults:
kongctl:
namespace: platform-team
protected: false
구성 템플릿
최상위 _templates 키 아래에 재사용 가능한 구성 블록을 정의하고 _extends로 그중 하나를 선택해요:
_templates:
private-portal:
authentication_enabled: true
default_api_visibility: private
portals:
- _extends: private-portal
ref: developer-portal
name: Developer Portal
템플릿은 하나의 명령이 로드하는 모든 소스에서 공유돼요. 템플릿을 소비하는 객체는 템플릿 객체를 재귀적으로 재정의해요. 스칼라, 배열, 명시적 null, 그리고 타입이 다른 값은 상속받은 값을 대체해요. 배열은 이어 붙이지 않아요.
탐색, 상속, 태그, 동기화 범위 동작에 대한 내용은 구성 템플릿을 참고하세요.
YAML 태그
필드 값에 YAML 태그를 사용해 파일을 로드하거나 다른 리소스를 참조하세요.
!file: 파일에서 내용을 로드해요.path#extract.path형식과path/extract맵 형식을 지원해요.!env: 환경 변수에서 문자열 내용을 로드해요.VAR#extract.path형식과var/extract맵 형식을 지원해요.!ref:ref로 다른 선언적 리소스를 참조해요.resource-ref#field형식을 지원하며, 기본 필드는id예요.!lookup: 관계 필드에서 기존 리소스를 직접 확인해요.!external:!lookup과 완전히 동일한 별칭이에요.!secret: 쓰기 전용 값의 처리를 실행 시점까지 미루고, 확인된 값이 저장된 플랜에 포함되지 않게 해요.!ref는 문자열 필드에서 사용하기 위한 거예요.- 이 문서의
string (uuid)와array[string(uuid)]표기는 API 값 타입을 설명하는 거예요. 선언적 구성에서는!ref를 사용하고 리터럴 UUID 값은 피하세요. - 재사용하는 관리되지 않는 리소스나 관리되는 자식을 둔 외부 부모에는
_external.selector를 사용하고!ref로 리소스를 참조하세요. - 일회성 관리되지 않는 관계에는
!lookup을 사용하세요. - 동기화는 외부 부모를 절대 변경하거나 삭제하지 않아요. 명시적으로 범위가 지정된 자식 컬렉션은 여전히 완전히 조정돼요.
- 큰 텍스트/spec 필드는 보통
!file로 로드해요. !file경로는 구성 파일을 기준으로 상대적으로 해석되며, 구성된 기본 디렉터리 경계 안에 있어야 해요.
portals:
- ref: docs-portal
_external:
selector:
matchFields:
name: "Docs Portal"
apis:
- ref: billing-api
publications:
- ref: billing-publication
portal_id: !ref docs-portal
맵핑 문법을 사용하면 !lookup이나 !external 안에, 또는 !secret 안에 !env를 조합할 수 있어요:
portal_id: !lookup
name: !env PORTAL_NAME
value: !secret
parts:
- "Bearer "
- !env AI_PROVIDER_TOKEN
감사 로그
감사 로그 웹훅 대상(destination)은 조직 범위의 Konnect 리소스예요. 선언적 구성은 이를 외부 참조로 지원하기 때문에, 관리되는 포털 감사 로그 웹훅이 다른 곳에서 생성된 대상을 가리킬 수 있어요.
audit-logs:
destinations:
- ref: string
_external:
id: string # destination UUID, or use selector
selector:
matchFields:
name: string
참고:
_external.id와_external.selector.matchFields.name만 지원돼요. 감사 로그 웹훅 대상은 kongctl 메타데이터를 선언할 수 없으며, 선언적kongctl apply로 생성, 업데이트, 삭제되지 않아요.
API
apis:
- ref: string
name: string required (1-255 chars)
_external: # alternative to managed API fields
id: string # API UUID, or use selector.matchFields.name
description: string (nullable)
version: string (1-255 chars, nullable)
slug: string (pattern: ^[\w-]+$, nullable)
labels: object [string]string
key: value
attributes: object [string]array[string]
key:
- value
versions: # /api/konnect/api-builder/v3/#/operations/create-api-version
- ref: string
version: string
spec: object required
content: string required (OpenAPI or AsyncAPI content; json or yaml) # prefer: !file ./specs/api.yaml
publications: # /api/konnect/api-builder/v3/#/operations/publish-api-to-portal
- ref: string
portal_id: string required (uuid) # prefer: !ref <portal-ref>
auto_approve_registrations: boolean
auth_strategy_ids: array[string(uuid)] (nullable, max 1 item) # prefer: !ref values
visibility: One of (public | private)
implementations: # /api/konnect/api-builder/v3/#/operations/create-api-implementation
- ref: string
type: service # optional when service is present
service:
id: string required (uuid) # prefer: !ref <gateway-service-ref>
control_plane_id: string required (uuid) # prefer: !ref <control-plane-ref>
- ref: string
type: control_plane # optional when control_plane is present
control_plane:
control_plane_id: string required (uuid) # prefer: !ref <control-plane-ref>
documents: # /api/konnect/api-builder/v3/#/operations/create-api-document
- ref: string
content: string required (markdown) # prefer: !file ./docs/page.md
title: string required unless content has a YAML frontmatter title
slug: string (pattern: ^[\w-]+$)
status: One of (published | unpublished)
parent_document_id: string (uuid, nullable) # prefer: !ref <document-ref>
children:
- ref: string
content: string required (markdown) # prefer: !file ./docs/page.md
title: string
slug: string (pattern: ^[\w-]+$)
status: One of (published | unpublished)
{:.collapsible}
API 사양은 versions[].spec 또는 루트 수준의 api_versions[].spec으로 API 버전에 선언해야 해요. 선언적 구성에서는 apis[].spec_content를 지원하지 않아요.
외부 API는 관리되는 버전, 퍼블리케이션, 구현체, 문서를 가질 수 있어요. kongctl은 API를 확인하고 선언된 자식만 플랜에 포함해요. API 자체는 절대 생성, 업데이트, 삭제하지 않아요. 각 구현체는 service 또는 control_plane 중 정확히 하나를 정의해요. type이 있으면 선택한 페이로드와 일치해야 해요.
애플리케이션 인증 전략
application_auth_strategies:
- ref: string
name: string required
display_name: string required
strategy_type: One of (key_auth | openid_connect) required
configs: object required
key-auth: # if strategy_type: key_auth
key_names: array[string] required (1-10 items)
ttl: object
value: integer required (minimum: 1)
unit: One of (days | weeks | years) required
openid-connect: # if strategy_type: openid_connect
issuer: string (url, max 256 chars) required
credential_claim: array[string] required (max 10 items)
scopes: array[string] required (max 50 items)
auth_methods: array[string] required (max 10 items)
dcr_provider_id: string (uuid, nullable; openid_connect only) # prefer: !ref <dcr-provider-ref>
labels: object [string]string
key: value
DCR 프로바이더
dcr_providers:
- ref: string
name: string required
display_name: string
provider_type: One of (auth0 | azureAd | curity | okta | http) required
issuer: string (url, max 256 chars) required
dcr_config: object required
labels: object [string]string
key: value
카탈로그 서비스
catalog_services:
- ref: string
name: string required (1-120 chars, pattern: ^[0-9a-z.-]+$)
display_name: string required (1-120 chars)
description: string (max 2048 chars)
labels: object [string]string
key: value
custom_fields: object
key: value
대시보드
대시보드 이름은 Konnect에서 고유할 필요가 없지만, kongctl은 선언적 구성의 다른 부분에서 사용하는 것과 동일한 리소스 매칭 패턴을 따라요.
라이브 상태를 기준으로 플랜을 세울 때는 일치하는 KONGCTL-namespace 라벨이 붙은 대시보드를 고려하고, 이름으로 원하는 대시보드를 매칭해요.
kongctl 네임스페이스 안에서는 중복된 대시보드 이름 사용을 피하세요.
대시보드 리소스는 analytics 그룹핑 키 아래에 선언해요.
Konnect UI에서 만든 대시보드라면:
- 대시보드 ID와 함께
kongctl adopt analytics dashboard를 실행해 네임스페이스 라벨을 적용하세요. kongctl dump declarative --resources=analytics.dashboards --default-namespace <name>을 실행해 선언적 구성을 생성하세요.
이름 기반 어답션은 이름이 여러 대시보드와 일치하면 실패해요.
Konnect에서 내보낸 대시보드 정의 JSON을 definition 값으로 사용하세요.
이 필드는 그 API 형태의 객체를 인라인으로 받거나 !file로 JSON/YAML 파일에서 로드할 수 있어요. kongctl은 파싱된 객체를 다른 스키마로 변환하지 않고 그대로 대시보드 정의로 전송해요.
더 큰 대시보드 정의에는 !file을 사용하는 게 좋아요.
analytics:
dashboards:
- ref: string
name: string required
definition: object required # prefer: !file ./definitions/dashboard.json
tiles: array[object] required
preset_filters: array[object]
labels: object [string]string
key: value
내보낸 JSON에 전체 API 응답이 담겨 있으면, #definition을 사용해 대시보드 API가 기대하는 페이로드를 추출하세요:
analytics:
dashboards:
- ref: traffic-summary
name: Traffic Summary
definition: !file ./exports/traffic-summary.json#definition
컨트롤 플레인
control_planes는 Kong Gateway 리소스예요.
Event Gateway 컨트롤 플레인에 대해서는 Event Gateways를 참고하세요.
control_planes:
- ref: string
name: string required
description: string
cluster_type: >-
One of (CLUSTER_TYPE_CONTROL_PLANE |
CLUSTER_TYPE_K8S_INGRESS_CONTROLLER |
CLUSTER_TYPE_CONTROL_PLANE_GROUP |
CLUSTER_TYPE_SERVERLESS |
CLUSTER_TYPE_SERVERLESS_V1)
auth_type: One of (pinned_client_certs | pki_client_certs)
cloud_gateway: boolean
proxy_urls: array[object]
- host: string required
port: integer required
protocol: string required
labels: object [string]string
key: value
_deck:
files: array[string]
flags: array[string]
_external:
selector:
matchFields:
name: string
requires:
deck: boolean
gateway_services:
- ref: string
# _external only, Kong Gateway resources are managed by deck
_external:
selector:
matchFields:
name: string
# API: create-dataplane-certificate
data_plane_certificates:
- ref: string
cert: string required # prefer: !file ./certs/data-plane.pem
컨트롤 플레인-데이터 플레인 인증서도 루트 리소스로 선언할 수 있어요.
인증서 ID를 사용할 수 없을 때는 인증서 내용이 해당 컨트롤 플레인 내에서 인증서를 식별해요.
cert 필드는 !file과 !env를 지원해요.
control_plane_data_plane_certificates:
- ref: string
control_plane: string required # control plane ref
cert: string required # prefer: !file ./certs/data-plane.pem
이벤트 게이트웨이
이 섹션은 kongctl에서 지원하는 Event Gateway 리소스에 대한 개요예요. 중첩된 Event Gateway 리소스와 필드의 공식 스키마로는 kongctl explain event_gateway --output yaml을 사용하고, 시작용 YAML을 생성하려면 kongctl scaffold event_gateway를 사용하세요.
event_gateways:
- ref: string
name: string required (1-255 chars)
description: string (max 512 chars)
min_runtime_version: string (pattern: ^\d+\.\d+$)
labels: object [string]string
key: value
backend_clusters: # /api/konnect/event-gateway/v1/#/operations/create-event-gateway-backend-cluster
- ref: string
name: string required (1-255 chars)
description: string (max 512 chars)
authentication: object required
type: One of (anonymous | sasl_plain | sasl_scram) required
username: string # required for sasl_plain/sasl_scram
password: string # required for sasl_plain/sasl_scram
algorithm: One of (sha256 | sha512) # required for sasl_scram
insecure_allow_anonymous_virtual_cluster_auth: boolean
bootstrap_servers: array[string] required (address:port)
tls: object required
enabled: boolean required
insecure_skip_verify: boolean
ca_bundle: string
tls_versions: array[One of (tls12 | tls13)]
client_identity: object # requires min_runtime_version: "1.1"
certificate: string required
key: string required
metadata_update_interval_seconds: integer (1-43200)
labels: object [string]string
key: value
virtual_clusters: # /api/konnect/event-gateway/v1/#/operations/create-event-gateway-virtual-cluster
- ref: string
name: string required (1-255 chars)
description: string (max 512 chars)
destination: object required
id: string (uuid) # oneOf; declarative: prefer !ref <backend-cluster-ref>
name: string # oneOf
authentication: array[object] required (min 1 item)
- type: One of (anonymous | sasl_plain | sasl_scram | oauth_bearer | client_certificate) required
mediation: One of (passthrough | terminate) # required for sasl_plain; One of (passthrough | validate_forward | terminate) for oauth_bearer
principals: array[object] # for sasl_plain terminate mode
- username: string required
password: string required
algorithm: One of (sha256 | sha512) # required for sasl_scram
claims_mapping: object # for oauth_bearer
sub: string
scope: string
jwks: object # for oauth_bearer
endpoint: string (uri) required
timeout: string (default: 10s)
cache_expiration: string (default: 1h)
validate: object # for oauth_bearer
audiences: array[object] (min 1 item)
- name: string required
issuer: string
# client_certificate requires no additional fields; requires min_runtime_version: "1.1"
namespace:
mode: One of (hide_prefix | enforce_prefix) required
prefix: string required
additional:
topics: array[object]
- type: One of (glob | exact_list) required
glob: string # if type=glob
conflict: One of (warn | ignore) # if type=glob or exact_list
exact_list: array[object] (min 1 item) # if type=exact_list
- backend: string required
consumer_groups: array[object]
- type: One of (glob | exact_list) required
glob: string # if type=glob
exact_list: array[object] (min 1 item) # if type=exact_list
- value: string required
topic_aliases:
- alias: string required
topic: string required
condition: string
conflict: One of (warn | ignore) (default: warn)
acl_mode: One of (enforce_on_gateway | passthrough) required
dns_label: string required (1-63 chars, RFC1035 label)
labels: object [string]string
key: value
cluster_policies: # /api/konnect/event-gateway/v1/#/operations/create-event-gateway-virtual-cluster-cluster-level-policy
- ref: string
type: acls required
name: string (1-255 chars)
description: string (max 512 chars)
enabled: boolean
labels: object [string]string
key: value
config: object required
rules: array[object] required (min 1 item)
- resource_type: One of (topic | group | transactional_id | cluster) required
action: One of (allow | deny) required
operations: array[object] required
- name: One of (all | alter | alter_configs | create | delete | describe | describe_configs | idempotent_write | read | write) required
resource_names: array[object] required (max 50 items)
- match: string required # glob pattern; * matches any characters
condition: string (boolean expression, max 1000 chars)
produce_policies: # /api/konnect/event-gateway/v1/#/operations/create-event-gateway-virtual-cluster-produce-policy
- ref: string
type: One of (modify_headers | schema_validation | encrypt) required
name: string (1-255 chars)
description: string (max 512 chars)
enabled: boolean
labels: object [string]string
key: value
config: object required
actions: array[object] required (min 1 item) # if type=modify_headers
- op: One of (remove | set) required
key: string required
value: string # required if op=set
type: One of (confluent_schema_registry | json) required # if type=schema_validation
schema_registry: object # if type=schema_validation; oneOf id or name
id: string (uuid) # declarative: prefer !ref <schema-registry-ref>
name: string
key_validation_action: One of (reject | mark) # if type=schema_validation
value_validation_action: One of (reject | mark) # if type=schema_validation
failure_mode: One of (error | passthrough) required # if type=encrypt
part_of_record: array[One of (key | value)] required (min 1 item) # if type=encrypt
encryption_key: object required # if type=encrypt
type: One of (aws | static) required
arn: string # required if type=aws; AWS KMS key ARN (pattern: ^arn:aws:kms:.+)
key: object # required if type=static; declarative: prefer !ref <static-key-ref>
id: string (uuid) # oneOf
name: string # oneOf
condition: string (boolean expression, max 1000 chars)
parent_policy_id: string (uuid) # for child policies under schema_validation
consume_policies: # /api/konnect/event-gateway/v1/#/operations/create-event-gateway-virtual-cluster-consume-policy
- ref: string
type: One of (schema_validation | modify_headers | skip_record | decrypt) required
name: string (1-255 chars)
description: string (max 512 chars)
enabled: boolean
labels: object [string]string
key: value
config: object required
type: One of (confluent_schema_registry | json) required # if type=schema_validation
schema_registry: object # if type=schema_validation; oneOf id or name
id: string (uuid) # declarative: prefer !ref <schema-registry-ref>
name: string
key_validation_action: One of (mark | skip) # if type=schema_validation
value_validation_action: One of (mark | skip) # if type=schema_validation
actions: array[object] required (min 1 item) # if type=modify_headers
- op: One of (remove | set) required
key: string required
value: string # required if op=set
failure_mode: One of (error | skip | passthrough | mark) required # if type=decrypt
key_sources: array[object] required (min 1 item) # if type=decrypt
- type: One of (aws | static) required
part_of_record: array[One of (key | value)] required (min 1 item) # if type=decrypt
condition: string (boolean expression, max 1000 chars)
parent_policy_id: string (uuid) # for child policies under schema_validation
listeners: # /api/konnect/event-gateway/v1/#/operations/create-event-gateway-listener
- ref: string
name: string required (1-255 chars)
description: string (max 512 chars)
addresses: array[string] required (min 1 item)
ports: array[integer|string] required (min 1 item)
labels: object [string]string
key: value
policies: # /api/konnect/event-gateway/v1/#/operations/create-event-gateway-listener-policy
- ref: string
type: One of (tls_server | forward_to_virtual_cluster) required
name: string
description: string
enabled: boolean
labels: object [string]string
key: value
config: object required
certificates: array[object] required (min 1, max 1 item) # if type=tls_server
- certificate: string required
key: string required
versions: object # if type=tls_server
min: One of (TLSv1.2 | TLSv1.3)
max: One of (TLSv1.2 | TLSv1.3)
allow_plaintext: boolean # if type=tls_server
client_authentication: object # if type=tls_server; requires min_runtime_version: "1.1"
mode: One of (required | requested) required
tls_trust_bundles: array[object] required (min 1 item)
- id: string (uuid) # oneOf; declarative: prefer !ref <tls-trust-bundle-ref>
name: string # oneOf
principal_mapping: string # expression; requires min_runtime_version: "1.1"
type: One of (sni | port_mapping) required # if type=forward_to_virtual_cluster
sni_suffix: string # if config.type=sni
advertised_port: integer # if config.type=sni
broker_host_format: object # if config.type=sni; requires min_runtime_version: "1.1"
type: One of (per_cluster_suffix | shared_suffix) required
destination: object required # if config.type=port_mapping; oneOf id or name
id: string (uuid) # declarative: prefer !ref <virtual-cluster-ref>
name: string
advertised_host: string required # if config.type=port_mapping
bootstrap_port: One of (none | at_start) # if config.type=port_mapping
min_broker_id: integer # if config.type=port_mapping
data_plane_certificates: # /api/konnect/event-gateway/v1/#/operations/create-event-gateway-data-plane-certificate
- ref: string
name: string (1-255 chars)
description: string (max 512 chars)
certificate: string required # PEM-encoded certificate; prefer: !file ./certs/data-plane.pem
schema_registries: # /api/konnect/event-gateway/v1/#/operations/create-event-gateway-schema-registry
- ref: string
type: confluent required
name: string required (1-255 chars)
description: string (max 512 chars)
labels: object [string]string
key: value
config: object required
schema_type: One of (avro | json) required
endpoint: string (uri) required
timeout_seconds: integer (min 1, default 10)
authentication: object
type: basic required
username: string required
password: string required
static_keys: # /api/konnect/event-gateway/v1/#/operations/create-event-gateway-static-key
- ref: string
name: string required (1-255 chars)
description: string (max 512 chars)
labels: object [string]string
key: value
value: string required # sensitive; prefer: !env SECRET_KEY
tls_trust_bundles: # /api/konnect/event-gateway/v1/#/operations/create-event-gateway-tls-trust-bundle; requires min_runtime_version: "1.1"
- ref: string
name: string required (1-255 chars)
description: string (max 512 chars)
labels: object [string]string
key: value
config: object required
trusted_ca: string required # PEM-encoded CA certificates; prefer: !file ./certs/ca.pem
{:.collapsible}
Organization
organization:
teams:
# /api/konnect/identity/v3/#/operations/create-team
- ref: string
name: string required
description: string (max 250 chars)
labels: object [string]string
key: value
roles:
- ref: string
role_name: string
# Prefer: !ref <api-ref> when entity_type_name=APIs.
entity_id: string (uuid)
entity_type_name: string
entity_region: One of (us | eu | au | me | in | sg | *)
Organization 팀 역할도 루트 리소스로 선언할 수 있어요.
organization_team_roles:
- ref: string
# Declarative organization team ref, not team name or UUID.
team: string required
role_name: string
# Prefer: !ref <api-ref> when entity_type_name=APIs.
entity_id: string (uuid)
entity_type_name: string
entity_region: One of (us | eu | au | me | in | sg | *)
Portals
portals:
- ref: string
name: string required (1-255 chars)
display_name: string (1-255 chars)
description: string (max 512 chars, nullable)
authentication_enabled: boolean (default: true)
rbac_enabled: boolean (default: false)
default_api_visibility: One of (public | private)
default_page_visibility: One of (public | private)
default_application_auth_strategy_id: string (uuid, nullable) # prefer: !ref <app-auth-strategy-ref>
auto_approve_developers: boolean (default: false)
auto_approve_applications: boolean (default: false)
sipr_enabled: boolean (default: false)
labels: object [string]string
key: value
customization: # /api/konnect/portal-management/v3/#/operations/replace-portal-customization
ref: string
theme:
name: string
mode: One of (light | dark | system)
colors:
primary: string (hex color, for example #0055A4)
layout: string
css: string (nullable)
menu:
main: array[PortalMenuItem]
footer_sections: array[PortalFooterMenuSection]
footer_bottom: array[PortalMenuItem]
spec_renderer:
try_it_ui: boolean
try_it_insomnia: boolean
infinite_scroll: boolean
show_schemas: boolean
hide_internal: boolean
hide_deprecated: boolean
allow_custom_server_urls: boolean
robots: string (nullable)
auth_settings: # /api/konnect/portal-management/v3/#/operations/update-portal-authentication-settings
ref: string
# OIDC and SAML provider-specific fields are no longer supported here.
# Move provider config to identity_providers or portal_identity_providers.
basic_auth_enabled: boolean
konnect_mapping_enabled: boolean
idp_mapping_enabled: boolean
ip_allow_list: # /api/konnect/portal-management/v3/#/operations/create-portal-ip-allow-list
ref: string
allowed_ips: array[string] required # IP addresses or CIDR blocks
integrations: # /api/konnect/portal-management/v3/#/operations/upsert-portal-integrations
ref: string
google_tag_manager:
enabled: boolean required
type: tracking
config_data:
id: string required (pattern: ^GTM-[A-Za-z0-9]+$)
l: string (nullable)
preview: string (nullable)
cookies_win: boolean (nullable)
debug: boolean (nullable)
npa: boolean (nullable)
data_layer: string (nullable)
env_name: string (nullable)
auth_referrer_policy: string (nullable)
google_analytics_4:
enabled: boolean required
type: analytics
config_data:
id: string required (pattern: ^G-[A-Za-z0-9-]+$)
l: string (nullable)
identity_providers: # /api/konnect/portal-management/v3/#/operations/create-portal-identity-provider
- ref: string
# Use this child for portal OIDC and SAML provider configuration.
# At the root of a config, use portal_identity_providers.
type: One of (oidc | saml) required
enabled: boolean
config: object required
issuer_url: string # OIDC
client_id: string # OIDC
client_secret: string # OIDC
scopes: array[string] # OIDC
claim_mappings: # OIDC
name: string
email: string
groups: string
idp_metadata_url: string # SAML
idp_metadata_xml: string # SAML
custom_domain: # /api/konnect/portal-management/v3/#/operations/create-portal-custom-domain
ref: string
hostname: string required
enabled: boolean required
ssl: object required
domain_verification_method: One of (http | custom_certificate) required
custom_certificate: string # when domain_verification_method=custom_certificate
custom_private_key: string # when domain_verification_method=custom_certificate
skip_ca_check: boolean
pages: # /api/konnect/portal-management/v3/#/operations/create-portal-page
- ref: string
slug: string required (max 512 chars)
content: string required (markdown) # prefer: !file ./docs/page.md
title: string (max 512 chars)
visibility: One of (public | private)
status: One of (published | unpublished)
description: string (max 160 chars)
parent_page_id: string (uuid, nullable) # prefer: !ref <page-ref>
children:
- ref: string
slug: string required (max 512 chars)
content: string required (markdown) # prefer: !file ./docs/page.md
title: string (max 512 chars)
visibility: One of (public | private)
status: One of (published | unpublished)
description: string (max 160 chars)
parent_page_id: string (uuid, nullable) # prefer: !ref <page-ref>
snippets: # /api/konnect/portal-management/v3/#/operations/create-portal-snippet
- ref: string
name: string required (max 512 chars)
content: string required (markdown) # prefer: !file ./docs/snippet.md
title: string (max 512 chars)
visibility: One of (public | private)
status: One of (published | unpublished)
description: string (max 160 chars)
teams: # /api/konnect/portal-management/v3/#/operations/create-portal-team
- ref: string
name: string required
description: string (max 250 chars)
can_own_applications: boolean (default: false)
roles: # /api/konnect/portal-management/v3/#/operations/assign-role-to-portal-teams
- ref: string
role_name: string
entity_id: string (uuid)
entity_type_name: string
entity_region: One of (us | eu | au | me | in | sg | *)
email_config: # /api/konnect/portal-management/v3/#/operations/create-portal-email-config
ref: string
domain_name: string (nullable)
from_name: string (nullable)
from_email: string (email, nullable)
reply_to_email: string (email, nullable)
audit_log_webhook: # /api/konnect/portal-management/v3/#/operations/update-portal-audit-log-webhook
ref: string
enabled: boolean
audit_log_destination_id: string (uuid) # prefer: !ref
email_templates: # /api/konnect/portal-management/v3/#/operations/update-portal-custom-email-template
<template_name>:
ref: string
name: string
enabled: boolean
content:
subject: string (max 1024 chars, nullable)
title: string (max 1024 chars, nullable)
body: string (max 4096 chars, nullable)
button_label: string (max 128 chars, nullable)
assets:
logo: string # data URL image (png/jpeg/gif/ico/svg)
favicon: string # data URL image (png/jpeg/gif/ico/svg)
{:.collapsible}
포털 ID 공급자와 통합도 루트 리소스로 선언할 수 있어요.
portal_identity_providers:
- ref: string
portal: string required # prefer: !ref <portal-ref>
type: One of (oidc | saml) required
enabled: boolean
config: object required
issuer_url: string # OIDC
client_id: string # OIDC
client_secret: string # OIDC
scopes: array[string] # OIDC
claim_mappings: # OIDC
name: string
email: string
groups: string
idp_metadata_url: string # SAML
idp_metadata_xml: string # SAML
portal_integrations:
- ref: string
portal: string required # prefer: !ref <portal-ref>
google_tag_manager:
enabled: boolean required
type: tracking
config_data:
id: string required (pattern: ^GTM-[A-Za-z0-9]+$)
l: string (nullable)
preview: string (nullable)
cookies_win: boolean (nullable)
debug: boolean (nullable)
npa: boolean (nullable)
data_layer: string (nullable)
env_name: string (nullable)
auth_referrer_policy: string (nullable)
google_analytics_4:
enabled: boolean required
type: analytics
config_data:
id: string required (pattern: ^G-[A-Za-z0-9-]+$)
l: string (nullable)
포털 IP 허용 목록도 루트 리소스로 선언할 수 있어요.
portal_ip_allow_lists:
- ref: string
portal: string required # prefer: !ref <portal-ref>
allowed_ips: array[string] required # IP addresses or CIDR blocks
sync 모드에서는 생략된 ip_allow_list 구성이 무시돼요. 포털 IP 허용 목록을 이 구성이 소유하는 경우에는 ip_allow_list 블록을 포함하세요.
포털 감사 로그 웹훅도 루트 리소스로 선언할 수 있어요.
portal_audit_log_webhooks:
- ref: string
portal: string required # prefer: !ref <portal-ref>
enabled: boolean
audit_log_destination_id: string (uuid) # prefer: !ref
sync 모드에서는 생략된 audit_log_webhook 구성이 무시돼요. 포털 웹훅을 이 구성이 소유하는 경우에는 audit_log_webhook 블록을 포함하세요.
portals:
- ref: docs-portal
name: Docs Portal
audit_log_webhook:
ref: docs-portal-audit-log-webhook
enabled: true
audit_log_destination_id: !ref foo
audit-logs:
destinations:
- ref: foo
_external:
selector:
matchFields:
name: foo
AI Gateway
이 섹션에서는 kongctl이 지원하는 AI Gateway 리소스를 다뤄요.
중첩된 AI Gateway 리소스와 필드의 공식 스키마로는 kongctl explain ai_gateway --output yaml을 사용하고, 시작용 YAML을 생성할 때는 kongctl scaffold ai_gateway를 사용하세요.
AI Gateway 노드는 명령형이면서 읽기 전용인 리소스예요. kongctl get ai-gateway nodes로 조회할 수 있고, 선언형 구성에는 포함하지 마세요.
AI Gateways
AI Gateways는 다른 AI Gateway 리소스를 담는 최상위 리소스예요.
ai_gateways:
- ref: string
name: string required
display_name: string required
description: string (nullable)
deployment_type: One of (hybrid | managed | serverless) (default: hybrid)
proxy_urls: array[object]
- host: string required
port: integer required
protocol: string required
labels: object [string]string
key: value
model_providers: # see AI Model Providers
auth_strategies: # see AI Auth Strategies
policies: # see AI Policies
agents: # see AI Agents
consumers: # see AI Consumers
consumer_groups: # see AI Consumer Groups
models: # see AI Models
mcp_servers: # see AI MCP Servers
config_stores: # see AI Config Stores
vaults: # see AI Vaults
data_plane_certificates:
- ref: string
title: string required
description: string (nullable)
cert: string required # PEM-encoded certificate; prefer: !file ./certs/data-plane.pem
AI 모델 프로바이더
AI 모델 프로바이더는 업스트림 LLM 서비스에 대한 연결을 정의하고 인증 자격 증명을 저장해요.
type 필드는 프로바이더와 config.auth의 형태를 결정해요.
대부분의 프로바이더는 headers 배열과 함께 type: basic 인증을 사용해요.
AWS Bedrock은 IAM 자격 증명을 위해 type: aws를 지원해요.
Azure는 서비스 주체 또는 관리 ID 인증을 위해 type: azure를 지원해요.
Gemini는 서비스 계정 인증을 위해 type: gcp를 지원해요.
ai_gateway_model_providers:
- ref: string
ai_gateway: string required # prefer: !ref <ai-gateway-ref>
name: string required
display_name: string required
labels: object [string]string
key: value
# Basic auth (used by openai, anthropic, cerebras, cohere, dashscope,
# databricks, deepseek, huggingface, kimi, llama2, mistral, ollama,
# vercel, vllm, xai, and as an option for bedrock, azure, gemini)
type: One of (openai | anthropic | cerebras | cohere | dashscope | databricks | deepseek | huggingface | kimi | llama2 | mistral | ollama | vercel | vllm | xai | bedrock | azure | gemini) required
config:
auth:
type: basic required
headers: # at least one of headers or params
- name: string required
value: string
params:
- name: string required
value: string
location: One of (body | query)
# AWS Bedrock with IAM credentials (type=bedrock, auth type=aws)
# type: bedrock
# config:
# auth:
# type: aws
# access_key_id: string # prefer: !env AWS_ACCESS_KEY_ID
# secret_access_key: string # prefer: !env AWS_SECRET_ACCESS_KEY
# assume_role_arn: string (nullable)
# role_session_name: string (nullable)
# sts_endpoint_url: string (nullable)
# batch_role_arn: string (nullable)
# Azure with service principal (type=azure, auth type=azure)
# type: azure
# config:
# auth:
# type: azure
# client_id: string # prefer: !env AZURE_CLIENT_ID
# client_secret: string # prefer: !env AZURE_CLIENT_SECRET
# tenant_id: string # prefer: !env AZURE_TENANT_ID
# use_managed_identity: boolean
# instance: string # Azure instance name
# GCP-based providers (type=gemini, auth type=gcp)
# type: gemini
# config:
# auth:
# type: gcp
# service_account_json: string # prefer: !env GCP_SERVICE_ACCOUNT_JSON
# metadata_url: string (nullable)
# oauth_token_url: string (nullable)
# use_gcp_service_account: boolean
{:.collapsible}
AI 모델
AI 모델은 사용 가능한 업스트림 모델을 선언하고, 라우팅을 구성하며, 사용할 AI 모델 프로바이더를 지정해요.
ai_gateway_models:
- ref: string
ai_gateway: string required # prefer: !ref <ai-gateway-ref>
name: string required
display_name: string required
enabled: boolean
type: One of (model | api) required
formats: array[object] required
- type: string required (for example openai)
config:
route: object required
paths: array[string]
hosts: array[string]
methods: array[string]
protocols: array[string]
headers: object
strip_path: boolean
preserve_host: boolean
regex_priority: integer
https_redirect_status_code: integer
request_buffering: boolean
response_buffering: boolean
tags: array[string]
model: object
alias: string
logging: object
payloads: boolean
statistics: boolean
response_streaming: One of (allow | deny | always)
max_request_body_size: integer
balancer: object
proxy: object
targets: array[object] required
- name: string required # upstream model name (for example gpt-4o)
provider: string required # AI Model Provider name
weight: integer
semantic_description: string
allow_auth_override: boolean
config:
type: One of (openai | anthropic | azure | bedrock | cerebras | cohere | dashscope | databricks | deepseek | gemini | huggingface | kimi | llama2 | mistral | ollama | vercel | vllm | xai) required
upstream_url: string (nullable)
# anthropic
version: string
# azure
deployment_id: string
api_version: string
# bedrock
region: string
# and more provider-specific fields; run `kongctl explain ai_gateway_models` for full detail
access: object
acls:
oneOf:
allow: array[string] # consumer group names
deny: array[string]
auth_strategies: array[string] # Auth Strategy names; prefer: !ref values
capabilities: array[string] # for example [generate]
policies: array[string] # policy names; prefer: !ref values
labels: object [string]string
key: value
{:.collapsible}
AI 인증 전략
AI 인증 전략은 AI Gateway 엔드포인트에 대한 인증을 구성해요.
ai_gateway_auth_strategies:
- ref: string
ai_gateway: string required # prefer: !ref <ai-gateway-ref>
name: string required
display_name: string required
labels: object [string]string
key: value
type: One of (key-auth | openid-connect) required
# Key auth
config: # if type=key-auth
hide_credentials: boolean
key_in_body: boolean
key_in_header: boolean
key_in_query: boolean
key_names: array[string] required
# OIDC
# config: # if type=openid-connect
# issuer: string required
# client_id: array[string]
# client_secret: array[string] # write-only; prefer: !env
# scopes: array[string]
# auth_methods: array[string]
# consumer_claims: array[string]
# consumer_optional: boolean
# cache_tokens_salt: string
# ssl_verify: boolean
AI 정책
AI 정책은 AI Gateway를 통과하는 요청과 응답에 규칙을 적용해요.
ai_gateway_policies:
- ref: string
ai_gateway: string required # prefer: !ref <ai-gateway-ref>
name: string required
display_name: string required
type: string required # for example ai-sanitizer
enabled: boolean
global: boolean
config: object # policy-specific configuration
labels: object [string]string
key: value
AI 컨슈머
AI 컨슈머는 AI Gateway 엔드포인트에 접근하는 클라이언트를 나타내요.
ai_gateway_consumers:
- ref: string
ai_gateway: string required # prefer: !ref <ai-gateway-ref>
name: string required
display_name: string required
type: One of (api-key | oauth) required
custom_id: string (nullable)
policies: array[string] # policy names; prefer: !ref values
credentials:
- ref: string
ai_gateway_consumer: string required # prefer: !ref <consumer-ref>
name: string required
display_name: string required
type: One of (api-key) required
api_key: string # create-only; must use !secret when provided
ttl: integer
labels: object [string]string
key: value
labels: object [string]string
key: value
AI 컨슈머 그룹
AI 컨슈머 그룹은 컨슈머들을 모아서 정책을 하나의 집합으로 적용할 수 있게 해줘요.
ai_gateway_consumer_groups:
- ref: string
ai_gateway: string required # prefer: !ref <ai-gateway-ref>
name: string required
display_name: string required
consumers: array[string] # consumer names; prefer: !ref <consumer-ref>#name
policies: array[string] # policy names; prefer: !ref values
labels: object [string]string
key: value
AI MCP 서버
AI MCP 서버는 AI Gateway를 통해 Model Context Protocol 도구 엔드포인트를 노출해요.
type은 서버가 노출되는 방식을 제어해요: conversion-only는 리스너 없이 MCP를 REST로 변환하고, listener는 전용 MCP 리스너를 만들고, passthrough-listener는 MCP 트래픽을 그대로 전달하고, upstream-server는 업스트림 MCP 서버로 프록시해요.
ai_gateway_mcp_servers:
- ref: string
ai_gateway: string required # prefer: !ref <ai-gateway-ref>
name: string required
display_name: string required
enabled: boolean
type: One of (conversion-only | conversion-listener | listener | passthrough-listener | upstream-server) required
config:
url: string required # upstream MCP server URL
route: object
paths: array[string]
hosts: array[string]
methods: array[string]
protocols: array[string]
headers: object
strip_path: boolean
preserve_host: boolean
regex_priority: integer
https_redirect_status_code: integer
request_buffering: boolean
response_buffering: boolean
tags: array[string]
logging: object
payloads: boolean
statistics: boolean
audits: boolean
max_request_body_size: integer
server: object
proxy: object
tools_cache_ttl_seconds: integer
tools: array[object]
- name: string required
description: string
method: string required # for example GET
path: string required # for example /customers/{customer_id}
scheme: string
host: string
headers: object
query: object
request_body: object
responses: object
parameters: array[object]
- name: string required
in: One of (path | query | header) required
description: string
required: boolean
schema: object
annotations: object
title: string
read_only_hint: boolean
destructive_hint: boolean
idempotent_hint: boolean
open_world_hint: boolean
input_schema: object
output_schema: object
access: object
acls:
oneOf:
allow: array[string]
deny: array[string]
access: object # for listener, passthrough-listener, conversion-listener, upstream-server types
acl_attribute_type: One of (consumer)
access_token_claim_field: string
acls:
oneOf:
allow: array[string]
deny: array[string]
default_tool_acls:
oneOf:
allow: array[string]
deny: array[string]
auth_strategies: array[string] # Auth Strategy names; prefer: !ref values
policies: array[string] # policy names
labels: object [string]string
key: value
{:.collapsible}
AI 에이전트
AI 에이전트는 AI Gateway를 통해 에이전트 간(A2A) 엔드포인트를 노출해요.
ai_gateway_agents:
- ref: string
ai_gateway: string required # prefer: !ref <ai-gateway-ref>
name: string required
display_name: string required
type: One of (a2a) required
enabled: boolean
config:
url: string required # upstream agent URL
route: object
paths: array[string]
hosts: array[string]
methods: array[string]
protocols: array[string]
headers: object
strip_path: boolean
preserve_host: boolean
regex_priority: integer
https_redirect_status_code: integer
request_buffering: boolean
response_buffering: boolean
tags: array[string]
max_request_body_size: integer
logging: object
payloads: boolean
statistics: boolean
max_payload_size: integer
access: object
acls:
oneOf:
allow: array[string] # consumer group names
deny: array[string]
auth_strategies: array[string] # Auth Strategy names; prefer: !ref values
policies: array[string] # policy names; prefer: !ref values
labels: object [string]string
key: value
{:.collapsible}
AI 컨피그 스토어
AI 컨피그 스토어는 다른 AI Gateway 리소스에서 참조할 수 있는 시크릿을 담고 있어요. 컨피그 스토어 이름은 생성 후에는 변경할 수 없어요.
ai_gateway_config_stores:
- ref: string
ai_gateway: string required # prefer: !ref <ai-gateway-ref>
name: string required
display_name: string required
secrets:
- ref: string
key: string required
value: string # write-only; must use !secret
컨피그 스토어 시크릿은 ai_gateway_config_store 부모와 함께 루트 수준에서 선언할 수도 있어요. 시크릿 값은 절대 반환되지 않아요. 시크릿을 생성하려면 value가 필요하고, 교체할 때는 --write-secret 또는 --write-secrets도 필요해요.
ai_gateway_config_store_secrets:
- ref: string
ai_gateway_config_store: string required # prefer: !ref <config-store-ref>
key: string required
value: string # write-only; must use !secret
AI Vaults
AI Vaults는 AI Gateway 리소스에서 사용할 시크릿과 자격 증명을 저장해요.
type 필드는 백엔드와 config의 형태를 결정해요.
ai_gateway_vaults:
- ref: string
ai_gateway: string required # prefer: !ref <ai-gateway-ref>
name: string required
description: string (nullable)
type: One of (env | konnect | aws | gcp | azure | conjur | hcv) required
labels: object [string]string
key: value
# Environment variables (type=env)
config: # if type=env
prefix: string required
base64_decode: boolean
# Konnect Config Store (type=konnect)
# config: # if type=konnect
# config_store_id: string required
# AWS Secrets Manager (type=aws)
# config: # if type=aws
# region: string required
# GCP Secret Manager (type=gcp)
# config: # if type=gcp
# project_id: string required
# Azure Key Vault (type=azure)
# config: # if type=azure
# vault_uri: string required
# HashiCorp Vault (type=hcv) and Conjur (type=conjur)
# config: # provider-specific; run `kongctl explain ai_gateway_vaults` for full detail
{:.collapsible}
자식 컬렉션을 생략하면 해당 컬렉션은 동기화 범위 밖에 두게 돼요. 식별된 게이트웨이, 컨슈머, 또는 Config Store 아래에 빈 컬렉션을 사용하면 해당 부모의 관리 대상 자식들이 삭제돼요. 루트 레벨의 빈 자식 컬렉션은 부모를 식별하지 않기 때문에 유효하지 않아요.
AI Gateway와 그 자식들을 덤프하려면 --resources ai_gateways --include-child-resources를 사용하세요. 직계 자식 덤프 셀렉터는 지원되지 않아요.
예시는 AI Gateway 선언형 구성을 참고하세요.
관련 리소스
다음 단계
더 알아보기 (Learn more)
- 리소스를 선언형으로 관리하는 전체 워크플로를 안내하는 가이드예요 — declarative configuration guide
- kongctl 설치와 기본 사용법부터 시작해 보세요 — Get started with kongctl
- kongctl 설정 파일 작성 방법을 참조할 수 있어요 — kongctl configuration reference guide
- kongctl로 AI Gateway 리소스를 관리하는 방법을 설명해요 — Using kongctl to manage AI Gateway
- 리소스 생성·조회에 쓰이는 Konnect API 명세를 확인할 수 있어요 — View the Konnect API reference