When using the Validate Against OpenAPI Documentation assertion in Broadcom Layer7 API Gateway, requests fail with the following error:
validation.request.parameter.schema.invalidJsonUnable to parse JSON - Unrecognized token 'token_value': was expecting (JSON String, Number, Array, Object or token 'null', 'true' or 'false')
This occurs even when the OpenAPI document is correctly defined and the URI being tested (e.g., /v1/key/test) appears valid.
This issue is caused by a defect in the underlying validation library (tracked as DE683418). The assertion incorrectly attempts to parse certain string-based path parameters as JSON tokens. When a path parameter (like "test") is not a valid JSON primitive, the parser fails with an "Unrecognized token" error.
This issue is resolved in the following releases:
The fix is natively included in API Gateway version 11.2.1 and higher. Upgrading to this version provides a permanent resolution.
For customers remaining on the 11.1 branch, the fix is included in the Gateway 11.1.4 July MSP (Monthly Support Patch) update. It is also incorporated into Gateway 11.1.5.