このページは、まだ日本語ではご利用いただけません。翻訳中です。
古いプラグインバージョンのドキュメントを閲覧しています。
構成
このプラグインはDBレスモードに対応しています。
パラメータ
このプラグインの設定で使用できるすべてのパラメータのリストは次のとおりです。
-
string required
プラグイン名。この場合は
oas-validation
。- Kong Admin API、Kong Konnect API、宣言型構成、または decK ファイルを使用する場合、フィールドは
name
です。 - Kubernetes で KongPlugin オブジェクトを使用する場合、フィールドは
plugin
です。
- Kong Admin API、Kong Konnect API、宣言型構成、または decK ファイルを使用する場合、フィールドは
-
string
プラグインが対象とするサービス名または ID。最上位の
/plugins
エンドポイント. からプラグインをサービスに追加する場合は、これらのパラメータのいずれかを設定してください/services/{serviceName|Id}/plugins
を使用する場合は必要ありません。 -
string
プラグインがターゲットとするルート名または ID。最上位の
/plugins
エンドポイント. を通るルートにプラグインを追加する場合は、これらのパラメータのいずれかを設定してください/routes/{routeName|Id}/plugins
を使用する場合は必要ありません。 -
string
プラグインがターゲットとするコンシューマーの名前または ID。 最上位の
/plugins
エンドポイント. からコンシューマーにプラグインを追加する場合は、これらのパラメーターのいずれかを設定してください/consumers/{consumerName|Id}/plugins
を使用する場合は必要ありません。 -
boolean default:
true
このプラグインが適用されるかどうか。
-
record required
-
string required
The API specification defined using either Swagger or the OpenAPI. This can be either a JSON or YAML based file. If using a YAML file, the spec needs to be URL encoded to preserve the YAML format.
-
boolean default:
false
If set to true, returns a detailed error message for invalid requests & responses. This is useful while testing.
-
boolean default:
true
If set to true, validates the request body content against the API specification.
-
boolean default:
false
If set to true, notifications via event hooks are enabled, but request based validation failures don’t affect the request flow.
-
boolean default:
true
If set to true, validates HTTP header parameters against the API specification.
-
boolean default:
true
If set to true, validates query parameters against the API specification.
-
boolean default:
true
If set to true, validates URI parameters in the request against the API specification.
-
boolean default:
false
If set to true, validates the response from the upstream services against the API specification. If validation fails, it results in an
HTTP 406 Not Acceptable
status code.
-
boolean default:
false
If set to true, notifications via event hooks are enabled, but response validation failures don’t affect the response flow.
-
boolean required default:
false
If set to true, checks if query parameters in the request exist in the API specification.
-
boolean required default:
false
If set to true, checks if HTTP header parameters in the request exist in the API specification.
-
string default:
Host,Content-Type,User-Agent,Accept,Content-Length
List of header parameters in the request that will be ignored when performing HTTP header validation. These are additional headers added to an API request beyond those defined in the API specification.
For example, you might include the HTTP header
User-Agent
, which lets servers and network peers identify the application, operating system, vendor, and/or version of the requesting user agent.
-