From 0366c96d3b8bcfcedc1f51330f52fa63ba08dfd6 Mon Sep 17 00:00:00 2001 From: Madhav Murthy Date: Wed, 1 Jul 2020 17:43:14 -0700 Subject: [PATCH] Update additionalProperties to support JsonSchema As per: https://json-schema.org/understanding-json-schema/reference/object.html, the additionalProperties can be boolean or JsonSchema. JsonSchema was previously supported by APIGateway but It was removed for some reason here: https://github.com/aws/aws-cdk/commit/73a1de1cecd57b45335fbcf6eef24d3d0cdeefd9. --- packages/@aws-cdk/aws-apigateway/lib/json-schema.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/@aws-cdk/aws-apigateway/lib/json-schema.ts b/packages/@aws-cdk/aws-apigateway/lib/json-schema.ts index 7ef0577566a29..b320031edf499 100644 --- a/packages/@aws-cdk/aws-apigateway/lib/json-schema.ts +++ b/packages/@aws-cdk/aws-apigateway/lib/json-schema.ts @@ -63,7 +63,7 @@ export interface JsonSchema { readonly minProperties?: number; readonly required?: string[]; readonly properties?: { [name: string]: JsonSchema }; - readonly additionalProperties?: boolean; + readonly additionalProperties?: JsonSchema | boolean; readonly patternProperties?: { [name: string]: JsonSchema }; readonly dependencies?: { [name: string]: JsonSchema | string[] }; readonly propertyNames?: JsonSchema;