deck "schema violation" in plugin config in CI
decK validated a Kong plugin block against its schema and a field failed: an unknown key, a wrong type, or a missing required field. Kong returns a "schema violation" naming the plugin and field.
What this error means
deck gateway sync or validate fails with "schema violation (config.X: ...)" for a plugin such as rate-limiting, key-auth, or cors.
deck
Error: 1 schema violation (config.minute: expected an integer)
in plugin 'rate-limiting'
Common causes
A plugin field has the wrong type or name
A string was given where an integer is required, or a key was renamed across Kong versions, so the field is rejected.
A required plugin field is missing
The plugin schema requires a field (a key, a header, a limit) that the config does not set.
How to fix it
Correct the plugin field to match the schema
- Read which plugin and which
config.*field the violation names. - Check that plugin's schema for the expected type and required keys.
- Fix the value or add the missing field, then re-validate.
kong.yaml
plugins:
- name: rate-limiting
config:
minute: 100
policy: localPin the decK and Kong versions together
Plugin schemas change between Kong versions; pin both so a field valid locally stays valid in CI.
.github/workflows/ci.yml
- uses: kong/setup-deck@v1
with:
deck-version: '1.40.3'How to prevent it
- Validate plugin config in CI before any sync.
- Track Kong version upgrades alongside plugin schema changes.
- Avoid copying plugin blocks between Kong versions without re-validating.
Related guides
deck "could not parse state file" / validation failed in CIFix decK "could not parse state file" / "validation failed" in CI - the Kong declarative YAML is malformed or…
deck sync HTTP 401 (RBAC token) in CIFix decK sync "HTTP status 401 (message: Unauthorized)" in CI - the Kong Admin API requires an RBAC token tha…
Tyk "Couldn't load API definition" (JSON) in CIFix Tyk "Couldn't load API" / JSON parse error in CI - an API definition file is invalid JSON or missing requ…