From 4256f49ab3ec5798c4c1332a44dc0b9b81719743 Mon Sep 17 00:00:00 2001 From: Charles Treatman Date: Mon, 28 Apr 2025 11:02:25 -0500 Subject: [PATCH 1/7] change default value of disallowAdditionalPropertiesIfNotPresent --- .../main/java/org/openapitools/codegen/CodegenConstants.java | 4 ++-- .../main/java/org/openapitools/codegen/DefaultCodegen.java | 4 ++-- .../openapitools/codegen/languages/CSharpClientCodegen.java | 4 ++-- .../codegen/languages/CSharpReducedClientCodegen.java | 4 ++-- .../org/openapitools/codegen/languages/GoClientCodegen.java | 4 ++-- .../codegen/languages/PowerShellClientCodegen.java | 4 ++-- .../openapitools/codegen/languages/PythonClientCodegen.java | 4 ++-- .../codegen/languages/PythonPydanticV1ClientCodegen.java | 4 ++-- .../org/openapitools/codegen/languages/RClientCodegen.java | 4 ++-- 9 files changed, 18 insertions(+), 18 deletions(-) diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/CodegenConstants.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/CodegenConstants.java index 022089190ee4..1316894e1e61 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/CodegenConstants.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/CodegenConstants.java @@ -408,8 +408,8 @@ public static enum ENUM_PROPERTY_NAMING_TYPE {camelCase, PascalCase, snake_case, public static final String DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT = "disallowAdditionalPropertiesIfNotPresent"; public static final String DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT_DESC = - "If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. " + - "If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default."; + "If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. " + + "If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default."; public static final String UNSUPPORTED_V310_SPEC_MSG = "OpenAPI 3.1 support is still in beta. To report an issue related to 3.1 spec, please kindly open an issue in the Github repo: https://github.com/openAPITools/openapi-generator."; diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/DefaultCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/DefaultCodegen.java index 94eb3273c049..c5991daa2f6b 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/DefaultCodegen.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/DefaultCodegen.java @@ -1808,7 +1808,7 @@ public DefaultCodegen() { // option to change how we process + set the data in the 'additionalProperties' keyword. CliOption disallowAdditionalPropertiesIfNotPresentOpt = CliOption.newBoolean( CodegenConstants.DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT, - CodegenConstants.DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT_DESC).defaultValue(Boolean.TRUE.toString()); + CodegenConstants.DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT_DESC).defaultValue(Boolean.FALSE.toString()); Map disallowAdditionalPropertiesIfNotPresentOpts = new HashMap<>(); disallowAdditionalPropertiesIfNotPresentOpts.put("false", "The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications."); @@ -1816,7 +1816,7 @@ public DefaultCodegen() { "Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default."); disallowAdditionalPropertiesIfNotPresentOpt.setEnum(disallowAdditionalPropertiesIfNotPresentOpts); cliOptions.add(disallowAdditionalPropertiesIfNotPresentOpt); - this.setDisallowAdditionalPropertiesIfNotPresent(true); + this.setDisallowAdditionalPropertiesIfNotPresent(false); CliOption enumUnknownDefaultCaseOpt = CliOption.newBoolean( CodegenConstants.ENUM_UNKNOWN_DEFAULT_CASE, diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/CSharpClientCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/CSharpClientCodegen.java index 3618814273cc..322a639a55c1 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/CSharpClientCodegen.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/CSharpClientCodegen.java @@ -248,7 +248,7 @@ public CSharpClientCodegen() { CliOption disallowAdditionalPropertiesIfNotPresentOpt = CliOption.newBoolean( CodegenConstants.DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT, - CodegenConstants.DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT_DESC).defaultValue(Boolean.TRUE.toString()); + CodegenConstants.DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT_DESC).defaultValue(Boolean.FALSE.toString()); Map disallowAdditionalPropertiesIfNotPresentOpts = new HashMap<>(); disallowAdditionalPropertiesIfNotPresentOpts.put("false", "The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications."); @@ -256,7 +256,7 @@ public CSharpClientCodegen() { "Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default."); disallowAdditionalPropertiesIfNotPresentOpt.setEnum(disallowAdditionalPropertiesIfNotPresentOpts); cliOptions.add(disallowAdditionalPropertiesIfNotPresentOpt); - this.setDisallowAdditionalPropertiesIfNotPresent(true); + this.setDisallowAdditionalPropertiesIfNotPresent(false); ImmutableMap.Builder frameworkBuilder = new ImmutableMap.Builder<>(); for (FrameworkStrategy frameworkStrategy : frameworkStrategies) { diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/CSharpReducedClientCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/CSharpReducedClientCodegen.java index 99ba87ce923e..3055dcaaf958 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/CSharpReducedClientCodegen.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/CSharpReducedClientCodegen.java @@ -188,7 +188,7 @@ public CSharpReducedClientCodegen() { CliOption disallowAdditionalPropertiesIfNotPresentOpt = CliOption.newBoolean( CodegenConstants.DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT, - CodegenConstants.DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT_DESC).defaultValue(Boolean.TRUE.toString()); + CodegenConstants.DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT_DESC).defaultValue(Boolean.FALSE.toString()); Map disallowAdditionalPropertiesIfNotPresentOpts = new HashMap<>(); disallowAdditionalPropertiesIfNotPresentOpts.put("false", "The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications."); @@ -196,7 +196,7 @@ public CSharpReducedClientCodegen() { "Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default."); disallowAdditionalPropertiesIfNotPresentOpt.setEnum(disallowAdditionalPropertiesIfNotPresentOpts); cliOptions.add(disallowAdditionalPropertiesIfNotPresentOpt); - this.setDisallowAdditionalPropertiesIfNotPresent(true); + this.setDisallowAdditionalPropertiesIfNotPresent(false); ImmutableMap.Builder frameworkBuilder = new ImmutableMap.Builder<>(); for (FrameworkStrategy frameworkStrategy : frameworkStrategies) { diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/GoClientCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/GoClientCodegen.java index 7b26d2e120c0..646ebc306e6c 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/GoClientCodegen.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/GoClientCodegen.java @@ -141,7 +141,7 @@ public GoClientCodegen() { // option to change how we process + set the data in the 'additionalProperties' keyword. CliOption disallowAdditionalPropertiesIfNotPresentOpt = CliOption.newBoolean( CodegenConstants.DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT, - CodegenConstants.DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT_DESC).defaultValue(Boolean.TRUE.toString()); + CodegenConstants.DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT_DESC).defaultValue(Boolean.FALSE.toString()); Map disallowAdditionalPropertiesIfNotPresentOpts = new HashMap<>(); disallowAdditionalPropertiesIfNotPresentOpts.put("false", "The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications."); @@ -149,7 +149,7 @@ public GoClientCodegen() { "Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default."); disallowAdditionalPropertiesIfNotPresentOpt.setEnum(disallowAdditionalPropertiesIfNotPresentOpts); cliOptions.add(disallowAdditionalPropertiesIfNotPresentOpt); - this.setDisallowAdditionalPropertiesIfNotPresent(true); + this.setDisallowAdditionalPropertiesIfNotPresent(false); cliOptions.add(CliOption.newBoolean(WITH_GO_MOD, "Generate go.mod and go.sum", true)); cliOptions.add(CliOption.newBoolean(CodegenConstants.GENERATE_MARSHAL_JSON, CodegenConstants.GENERATE_MARSHAL_JSON_DESC, true)); cliOptions.add(CliOption.newBoolean(CodegenConstants.GENERATE_UNMARSHAL_JSON, CodegenConstants.GENERATE_UNMARSHAL_JSON_DESC, true)); diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/PowerShellClientCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/PowerShellClientCodegen.java index d0c603d20a07..1c183ea459d1 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/PowerShellClientCodegen.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/PowerShellClientCodegen.java @@ -559,7 +559,7 @@ public PowerShellClientCodegen() { // option to change how we process + set the data in the 'additionalProperties' keyword. CliOption disallowAdditionalPropertiesIfNotPresentOpt = CliOption.newBoolean( CodegenConstants.DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT, - CodegenConstants.DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT_DESC).defaultValue(Boolean.TRUE.toString()); + CodegenConstants.DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT_DESC).defaultValue(Boolean.FALSE.toString()); Map disallowAdditionalPropertiesIfNotPresentOpts = new HashMap<>(); disallowAdditionalPropertiesIfNotPresentOpts.put("false", "The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications."); @@ -567,7 +567,7 @@ public PowerShellClientCodegen() { "Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default."); disallowAdditionalPropertiesIfNotPresentOpt.setEnum(disallowAdditionalPropertiesIfNotPresentOpts); cliOptions.add(disallowAdditionalPropertiesIfNotPresentOpt); - this.setDisallowAdditionalPropertiesIfNotPresent(true); + this.setDisallowAdditionalPropertiesIfNotPresent(false); // default value in the template additionalProperties.put("powershellVersion", "6.2"); // minimal PS version diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/PythonClientCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/PythonClientCodegen.java index a1caa703f4d2..4153f4405d70 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/PythonClientCodegen.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/PythonClientCodegen.java @@ -166,7 +166,7 @@ public PythonClientCodegen() { // option to change how we process + set the data in the 'additionalProperties' keyword. CliOption disallowAdditionalPropertiesIfNotPresentOpt = CliOption.newBoolean( CodegenConstants.DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT, - CodegenConstants.DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT_DESC).defaultValue(Boolean.TRUE.toString()); + CodegenConstants.DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT_DESC).defaultValue(Boolean.FALSE.toString()); Map disallowAdditionalPropertiesIfNotPresentOpts = new HashMap<>(); disallowAdditionalPropertiesIfNotPresentOpts.put("false", "The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications."); @@ -174,7 +174,7 @@ public PythonClientCodegen() { "Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default."); disallowAdditionalPropertiesIfNotPresentOpt.setEnum(disallowAdditionalPropertiesIfNotPresentOpts); cliOptions.add(disallowAdditionalPropertiesIfNotPresentOpt); - this.setDisallowAdditionalPropertiesIfNotPresent(true); + this.setDisallowAdditionalPropertiesIfNotPresent(false); } @Override diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/PythonPydanticV1ClientCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/PythonPydanticV1ClientCodegen.java index 0834b51cd4cf..a1dcb25ea38b 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/PythonPydanticV1ClientCodegen.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/PythonPydanticV1ClientCodegen.java @@ -171,7 +171,7 @@ public PythonPydanticV1ClientCodegen() { // option to change how we process + set the data in the 'additionalProperties' keyword. CliOption disallowAdditionalPropertiesIfNotPresentOpt = CliOption.newBoolean( CodegenConstants.DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT, - CodegenConstants.DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT_DESC).defaultValue(Boolean.TRUE.toString()); + CodegenConstants.DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT_DESC).defaultValue(Boolean.FALSE.toString()); Map disallowAdditionalPropertiesIfNotPresentOpts = new HashMap<>(); disallowAdditionalPropertiesIfNotPresentOpts.put("false", "The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications."); @@ -179,7 +179,7 @@ public PythonPydanticV1ClientCodegen() { "Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default."); disallowAdditionalPropertiesIfNotPresentOpt.setEnum(disallowAdditionalPropertiesIfNotPresentOpts); cliOptions.add(disallowAdditionalPropertiesIfNotPresentOpt); - this.setDisallowAdditionalPropertiesIfNotPresent(true); + this.setDisallowAdditionalPropertiesIfNotPresent(false); } @Override diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/RClientCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/RClientCodegen.java index d588e42b0995..00d12771026d 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/RClientCodegen.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/RClientCodegen.java @@ -225,7 +225,7 @@ public RClientCodegen() { // option to change how we process + set the data in the 'additionalProperties' keyword. CliOption disallowAdditionalPropertiesIfNotPresentOpt = CliOption.newBoolean( CodegenConstants.DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT, - CodegenConstants.DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT_DESC).defaultValue(Boolean.TRUE.toString()); + CodegenConstants.DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT_DESC).defaultValue(Boolean.FALSE.toString()); Map disallowAdditionalPropertiesIfNotPresentOpts = new HashMap<>(); disallowAdditionalPropertiesIfNotPresentOpts.put("false", "The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications."); @@ -233,7 +233,7 @@ public RClientCodegen() { "Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default."); disallowAdditionalPropertiesIfNotPresentOpt.setEnum(disallowAdditionalPropertiesIfNotPresentOpts); cliOptions.add(disallowAdditionalPropertiesIfNotPresentOpt); - this.setDisallowAdditionalPropertiesIfNotPresent(true); + this.setDisallowAdditionalPropertiesIfNotPresent(false); } From ea4a9f7d04a44e37df4a3da5675e567af29946e0 Mon Sep 17 00:00:00 2001 From: Charles Treatman Date: Thu, 1 May 2025 12:40:25 -0500 Subject: [PATCH 2/7] fix tests --- .../java/org/openapitools/codegen/DefaultCodegenTest.java | 6 +++--- .../openapitools/codegen/java/JavaClientCodegenTest.java | 3 ++- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/modules/openapi-generator/src/test/java/org/openapitools/codegen/DefaultCodegenTest.java b/modules/openapi-generator/src/test/java/org/openapitools/codegen/DefaultCodegenTest.java index f1aca92f0c05..83b74e20fcf8 100644 --- a/modules/openapi-generator/src/test/java/org/openapitools/codegen/DefaultCodegenTest.java +++ b/modules/openapi-generator/src/test/java/org/openapitools/codegen/DefaultCodegenTest.java @@ -305,8 +305,8 @@ public void testAdditionalPropertiesV2SpecDisallowAdditionalPropertiesIfNotPrese // this is the legacy config that most of our tooling uses OpenAPI openAPI = TestUtils.parseFlattenSpec("src/test/resources/2_0/additional-properties-for-testing.yaml"); DefaultCodegen codegen = new DefaultCodegen(); - codegen.setOpenAPI(openAPI); codegen.setDisallowAdditionalPropertiesIfNotPresent(true); + codegen.setOpenAPI(openAPI); Schema schema = openAPI.getComponents().getSchemas().get("AdditionalPropertiesClass"); Assertions.assertNull(schema.getAdditionalProperties()); @@ -385,9 +385,9 @@ public void testAdditionalPropertiesV2SpecDisallowAdditionalPropertiesIfNotPrese public void testAdditionalPropertiesV2SpecDisallowAdditionalPropertiesIfNotPresentFalse() { OpenAPI openAPI = TestUtils.parseFlattenSpec("src/test/resources/2_0/additional-properties-for-testing.yaml"); DefaultCodegen codegen = new DefaultCodegen(); - codegen.setOpenAPI(openAPI); codegen.setDisallowAdditionalPropertiesIfNotPresent(false); codegen.supportsAdditionalPropertiesWithComposedSchema = true; + codegen.setOpenAPI(openAPI); /* When this DisallowAdditionalPropertiesIfNotPresent is false: for CodegenModel/CodegenParameter/CodegenProperty/CodegenResponse.getAdditionalProperties @@ -405,7 +405,7 @@ public void testAdditionalPropertiesV2SpecDisallowAdditionalPropertiesIfNotPrese Schema addProps = ModelUtils.getAdditionalProperties(schema); // The petstore-with-fake-endpoints-models-for-testing.yaml does not set the // 'additionalProperties' keyword for this model, hence assert the value to be null. - Assertions.assertNull(addProps); + Assertions.assertNotNull(addProps); CodegenModel cm = codegen.fromModel("AdditionalPropertiesClass", schema); Assertions.assertNotNull(cm.getAdditionalProperties()); // When the 'additionalProperties' keyword is not present, the model diff --git a/modules/openapi-generator/src/test/java/org/openapitools/codegen/java/JavaClientCodegenTest.java b/modules/openapi-generator/src/test/java/org/openapitools/codegen/java/JavaClientCodegenTest.java index 1547e5054d9e..c7465b988566 100644 --- a/modules/openapi-generator/src/test/java/org/openapitools/codegen/java/JavaClientCodegenTest.java +++ b/modules/openapi-generator/src/test/java/org/openapitools/codegen/java/JavaClientCodegenTest.java @@ -3275,7 +3275,8 @@ public void testRestClientWithXML_issue_19137() { .setLibrary(JavaClientCodegen.RESTCLIENT) .setAdditionalProperties(Map.of( CodegenConstants.API_PACKAGE, "xyz.abcdef.api", - CodegenConstants.WITH_XML, true + CodegenConstants.WITH_XML, true, + CodegenConstants.DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT, true )) .setInputSpec("src/test/resources/3_1/java/petstore.yaml") .setOutputDir(output.toString().replace("\\", "/")); From eb2c79b54e3ea4950414d295f4a7f98756487590 Mon Sep 17 00:00:00 2001 From: Charles Treatman Date: Thu, 1 May 2025 14:11:14 -0500 Subject: [PATCH 3/7] set disallowAdditionalPropertiesIfNotPresent on samples to avoid converting them all at once --- bin/configs/c-bearer-auth.yaml | 2 ++ bin/configs/cpp-restbed-server.yaml | 2 ++ bin/configs/cpp-restsdk-client.yaml | 1 + bin/configs/csharp-generichost-latest-composedEnum.yaml | 1 + bin/configs/csharp-generichost-latest-helloWorld.yaml | 1 + bin/configs/csharp-generichost-latest-inlineEnumAnyOf.yaml | 1 + bin/configs/csharp-generichost-latest-oneOfList.yaml | 1 + bin/configs/csharp-generichost-net4.7-useDateTimeForDate.yaml | 1 + bin/configs/csharp-generichost-net8-useDateTimeForDate.yaml | 1 + bin/configs/csharp-generichost-net9-useDateTimeForDate.yaml | 1 + bin/configs/csharp-restsharp-net4.7-multipleFrameworks.yaml | 1 + bin/configs/csharp-restsharp-net8-compareNetObjects.yaml | 1 + bin/configs/csharp-restsharp-net8-echo-api.yaml | 1 + bin/configs/csharp-restsharp-net8-name-mappings.yaml | 1 + bin/configs/csharp-restsharp-net8-useDateTimeForDate.yaml | 1 + bin/configs/csharp-restsharp-netstandard2.0-complexfiles.yaml | 1 + bin/configs/csharp-restsharp-useVirtualForHooks.yaml | 1 + bin/configs/csharp-unityWebRequest-netstandard2.0.yaml | 1 + bin/configs/dart-dio-petstore-client-lib-fake.yaml | 1 + bin/configs/go-echo-api.yaml | 1 + bin/configs/go-echo-external-refs-test.yaml | 1 + bin/configs/go-multiple-allof-ref-with-discriminator.yaml | 1 + bin/configs/go-oneof-anyof-required.yaml | 1 + bin/configs/go-oneof-discriminator-lookup.yaml | 1 + bin/configs/go-petstore-generateMarshalJSON-false.yaml | 1 - bin/configs/go-petstore-oas2.yaml | 1 + bin/configs/go-petstore.yaml | 1 - bin/configs/java-feign-gson-echo-api.yaml | 1 + bin/configs/java-feign-hc5.yaml | 3 ++- bin/configs/java-feign-no-nullable.yaml | 1 + bin/configs/java-feign.yaml | 1 + bin/configs/java-jersey2-8-oas2.yaml | 1 + bin/configs/java-jersey2-8-oneOfDuplicateList.yaml | 1 + bin/configs/java-jersey2-8-oneOfMixed.yaml | 1 + bin/configs/java-jersey2-8-swagger1.yaml | 1 - bin/configs/java-jersey2-8-swagger2.yaml | 1 - bin/configs/java-jersey2-8.yaml | 1 - bin/configs/java-jersey2-java8-localdatetime.yaml | 1 + bin/configs/java-jersey2-special-characters.yaml | 1 - bin/configs/java-jersey3-oneOf.yaml | 1 + bin/configs/java-jersey3.yaml | 1 - bin/configs/java-microprofile-rest-client-3.0-jackson.yaml | 1 + bin/configs/java-native-async.yaml | 1 + bin/configs/java-native-echo-api.yaml | 2 +- bin/configs/java-native.yaml | 1 + bin/configs/java-okhttp-gson-3.1-duplicated-operationid.yaml | 1 - bin/configs/java-okhttp-gson-3.1.yaml | 1 - bin/configs/java-okhttp-gson-awsv4signature.yaml | 1 - bin/configs/java-okhttp-gson-dynamicOperations.yaml | 1 + bin/configs/java-okhttp-gson-echo-api.yaml | 1 + bin/configs/java-okhttp-gson-group-parameter.yaml | 1 - bin/configs/java-okhttp-gson-nullable-required.yaml | 1 - bin/configs/java-okhttp-gson-oneOf-array.yaml | 1 + bin/configs/java-okhttp-gson-parcelableModel.yaml | 1 + bin/configs/java-okhttp-gson-streaming.yaml | 1 + bin/configs/java-okhttp-gson-swagger1.yaml | 1 - bin/configs/java-okhttp-gson-swagger2.yaml | 1 - bin/configs/java-okhttp-gson.yaml | 1 - bin/configs/java-okhttp-user-defined-templates.yaml | 1 + bin/configs/java-restclient-echo-api.yaml | 2 +- bin/configs/java-restclient-swagger2.yaml | 1 + .../java-restclient-useSingleRequestParameter-static.yaml | 3 ++- bin/configs/java-restclient-useSingleRequestParameter.yaml | 1 + bin/configs/java-restclient.yaml | 1 + bin/configs/java-resttemplate-echo-api.yaml | 1 + bin/configs/java-resttemplate-withXml.yaml | 1 + bin/configs/java-resttemplate.yaml | 1 + bin/configs/java-webclient-jakarta.yaml | 1 + bin/configs/java-webclient-sealedInterface.yaml | 1 + bin/configs/java-webclient-swagger2.yaml | 1 + bin/configs/java-webclient-useSingleRequestParameter.yaml | 1 + bin/configs/java-webclient.yaml | 1 + bin/configs/jaxrs-spec-jakarta.yaml | 1 + .../jaxrs-spec-quarkus-microprofile-openapi-annotations.yaml | 1 + bin/configs/jaxrs-spec-quarkus-mutiny.yaml | 1 + bin/configs/jaxrs-spec-required-and-readonly-property.yaml | 1 + bin/configs/jaxrs-spec-swagger-annotations.yaml | 1 + bin/configs/jaxrs-spec-swagger-v3-annotations-jakarta.yaml | 1 + bin/configs/jaxrs-spec-swagger-v3-annotations.yaml | 1 + bin/configs/jaxrs-spec-withxml.yaml | 1 + bin/configs/jaxrs-spec.yaml | 1 + bin/configs/powershell-echo-api.yaml | 1 + bin/configs/powershell.yaml | 1 + bin/configs/protobuf-schema.yaml | 1 + bin/configs/python-aiohttp.yaml | 1 + bin/configs/python-echo-api.yaml | 1 + bin/configs/python-fastapi.yaml | 1 + bin/configs/python-pydantic-v1-aiohttp.yaml | 1 + bin/configs/python-pydantic-v1-echo-api.yaml | 1 + bin/configs/python-pydantic-v1.yaml | 1 - bin/configs/python.yaml | 1 - bin/configs/r-client.yaml | 1 - bin/configs/r-echo-api.yaml | 1 + bin/configs/r-httr2-client.yaml | 2 +- bin/configs/r-httr2-wrapper-client.yaml | 1 - bin/configs/rust-server-deprecated-openapi-v3.yaml | 1 + ...ecated-petstore-with-fake-endpoints-models-for-testing.yaml | 1 + bin/configs/rust-server-openapi-v3.yaml | 1 + ...server-petstore-with-fake-endpoints-models-for-testing.yaml | 1 + bin/configs/scala-cask-petstore.yaml | 3 ++- bin/configs/spring-boot-beanvalidation-no-nullable.yaml | 1 + bin/configs/spring-boot-beanvalidation.yaml | 1 + bin/configs/spring-boot-builtin-validation.yaml | 1 + .../spring-boot-defaultInterface-unhandledException.yaml | 1 + bin/configs/spring-boot-delegate-j8.yaml | 1 + bin/configs/spring-boot-delegate-oas3.yaml | 1 + bin/configs/spring-boot-delegate.yaml | 1 + bin/configs/spring-boot-implicitHeaders-oas3.yaml | 1 + bin/configs/spring-boot-implicitHeaders.yaml | 1 + bin/configs/spring-boot-oneof-sealed.yaml | 1 + bin/configs/spring-boot-oneof.yaml | 1 + bin/configs/spring-boot-reactive-noResponseEntity.yaml | 1 + bin/configs/spring-boot-reactive.yaml | 1 + bin/configs/spring-boot-useoptional.yaml | 1 + bin/configs/spring-boot-virtualan.yaml | 1 + bin/configs/spring-boot.yaml | 1 + bin/configs/spring-cloud-oas3-fakeapi.yaml | 1 + bin/configs/spring-http-interface-noResponseEntity.yaml | 1 + .../spring-http-interface-reactive-noResponseEntity.yaml | 2 +- bin/configs/spring-http-interface-reactive.yaml | 2 +- bin/configs/spring-http-interface.yaml | 1 + ...tore-server-spring-pageable-delegatePattern-without-j8.yaml | 1 + ...ngboot-petstore-server-spring-pageable-delegatePattern.yaml | 1 + .../springboot-petstore-server-spring-pageable-without-j8.yaml | 1 + bin/configs/springboot-petstore-server-spring-pageable.yaml | 1 + bin/configs/typescript-fetch-validation-attributes.yaml | 1 + 126 files changed, 112 insertions(+), 27 deletions(-) diff --git a/bin/configs/c-bearer-auth.yaml b/bin/configs/c-bearer-auth.yaml index 8556eb16298c..3a9ec8a8fc3b 100644 --- a/bin/configs/c-bearer-auth.yaml +++ b/bin/configs/c-bearer-auth.yaml @@ -2,3 +2,5 @@ generatorName: c outputDir: samples/client/others/c/bearerAuth inputSpec: modules/openapi-generator/src/test/resources/3_0/c/bearer_auth.yaml templateDir: modules/openapi-generator/src/main/resources/C-libcurl +additionalProperties: + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/cpp-restbed-server.yaml b/bin/configs/cpp-restbed-server.yaml index 6dc3929ec089..19422bacebaf 100644 --- a/bin/configs/cpp-restbed-server.yaml +++ b/bin/configs/cpp-restbed-server.yaml @@ -2,3 +2,5 @@ generatorName: cpp-restbed-server outputDir: samples/server/petstore/cpp-restbed/generated/3_0 inputSpec: modules/openapi-generator/src/test/resources/3_0/petstore-with-fake-endpoints-models-for-testing.yaml templateDir: modules/openapi-generator/src/main/resources/cpp-restbed-server +additionalProperties: + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/cpp-restsdk-client.yaml b/bin/configs/cpp-restsdk-client.yaml index ccd23932b49c..6ff6940ed625 100644 --- a/bin/configs/cpp-restsdk-client.yaml +++ b/bin/configs/cpp-restsdk-client.yaml @@ -4,3 +4,4 @@ inputSpec: modules/openapi-generator/src/test/resources/3_0/cpp-restsdk/petstore templateDir: modules/openapi-generator/src/main/resources/cpp-rest-sdk-client additionalProperties: packageName: CppRestPetstoreClient + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/csharp-generichost-latest-composedEnum.yaml b/bin/configs/csharp-generichost-latest-composedEnum.yaml index cfd9c37e7541..9214ea517ca3 100644 --- a/bin/configs/csharp-generichost-latest-composedEnum.yaml +++ b/bin/configs/csharp-generichost-latest-composedEnum.yaml @@ -7,4 +7,5 @@ additionalProperties: packageGuid: '{321C8C3F-0156-40C1-AE42-D59761FB9B6C}' modelPropertySorting: alphabetical operationParameterSorting: alphabetical + disallowAdditionalPropertiesIfNotPresent: true validateSpec: false diff --git a/bin/configs/csharp-generichost-latest-helloWorld.yaml b/bin/configs/csharp-generichost-latest-helloWorld.yaml index 4a6bdd392fa9..7609dee80448 100644 --- a/bin/configs/csharp-generichost-latest-helloWorld.yaml +++ b/bin/configs/csharp-generichost-latest-helloWorld.yaml @@ -7,3 +7,4 @@ additionalProperties: packageGuid: '{321C8C3F-0156-40C1-AE42-D59761FB9B6C}' modelPropertySorting: alphabetical operationParameterSorting: alphabetical + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/csharp-generichost-latest-inlineEnumAnyOf.yaml b/bin/configs/csharp-generichost-latest-inlineEnumAnyOf.yaml index b3ff03864ec1..a0bad07989f7 100644 --- a/bin/configs/csharp-generichost-latest-inlineEnumAnyOf.yaml +++ b/bin/configs/csharp-generichost-latest-inlineEnumAnyOf.yaml @@ -7,6 +7,7 @@ additionalProperties: packageGuid: '{321C8C3F-0156-40C1-AE42-D59761FB9B6C}' modelPropertySorting: alphabetical operationParameterSorting: alphabetical + disallowAdditionalPropertiesIfNotPresent: true validateSpec: false inlineSchemaOptions: RESOLVE_INLINE_ENUMS: true diff --git a/bin/configs/csharp-generichost-latest-oneOfList.yaml b/bin/configs/csharp-generichost-latest-oneOfList.yaml index c6a9bd87bb58..24c2d3ea4308 100644 --- a/bin/configs/csharp-generichost-latest-oneOfList.yaml +++ b/bin/configs/csharp-generichost-latest-oneOfList.yaml @@ -6,3 +6,4 @@ additionalProperties: packageGuid: '{321C8C3F-0156-40C1-AE42-D59761FB9B6C}' modelPropertySorting: alphabetical operationParameterSorting: alphabetical + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/csharp-generichost-net4.7-useDateTimeForDate.yaml b/bin/configs/csharp-generichost-net4.7-useDateTimeForDate.yaml index 46a0a2d33a53..1b781dbc226b 100644 --- a/bin/configs/csharp-generichost-net4.7-useDateTimeForDate.yaml +++ b/bin/configs/csharp-generichost-net4.7-useDateTimeForDate.yaml @@ -9,3 +9,4 @@ additionalProperties: targetFramework: net47 modelPropertySorting: alphabetical operationParameterSorting: alphabetical + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/csharp-generichost-net8-useDateTimeForDate.yaml b/bin/configs/csharp-generichost-net8-useDateTimeForDate.yaml index 12b56019db5a..42f54c1158b6 100644 --- a/bin/configs/csharp-generichost-net8-useDateTimeForDate.yaml +++ b/bin/configs/csharp-generichost-net8-useDateTimeForDate.yaml @@ -9,3 +9,4 @@ additionalProperties: targetFramework: net8.0 modelPropertySorting: alphabetical operationParameterSorting: alphabetical + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/csharp-generichost-net9-useDateTimeForDate.yaml b/bin/configs/csharp-generichost-net9-useDateTimeForDate.yaml index 189f64d2a556..0993f5940f36 100644 --- a/bin/configs/csharp-generichost-net9-useDateTimeForDate.yaml +++ b/bin/configs/csharp-generichost-net9-useDateTimeForDate.yaml @@ -9,3 +9,4 @@ additionalProperties: targetFramework: net9.0 modelPropertySorting: alphabetical operationParameterSorting: alphabetical + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/csharp-restsharp-net4.7-multipleFrameworks.yaml b/bin/configs/csharp-restsharp-net4.7-multipleFrameworks.yaml index b53220d0dbf8..ffa7bd2407c1 100644 --- a/bin/configs/csharp-restsharp-net4.7-multipleFrameworks.yaml +++ b/bin/configs/csharp-restsharp-net4.7-multipleFrameworks.yaml @@ -8,3 +8,4 @@ additionalProperties: targetFramework: netstandard2.1;net47 useCompareNetObjects: "true" equatable: true + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/csharp-restsharp-net8-compareNetObjects.yaml b/bin/configs/csharp-restsharp-net8-compareNetObjects.yaml index 89ee23c7e9f5..a3d33883d5b2 100644 --- a/bin/configs/csharp-restsharp-net8-compareNetObjects.yaml +++ b/bin/configs/csharp-restsharp-net8-compareNetObjects.yaml @@ -8,3 +8,4 @@ additionalProperties: targetFramework: net8.0 useCompareNetObjects: "true" equatable: true + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/csharp-restsharp-net8-echo-api.yaml b/bin/configs/csharp-restsharp-net8-echo-api.yaml index f3e38ddabeec..3f6ab0ca6dfd 100644 --- a/bin/configs/csharp-restsharp-net8-echo-api.yaml +++ b/bin/configs/csharp-restsharp-net8-echo-api.yaml @@ -9,3 +9,4 @@ additionalProperties: setCompareNetObjects: "true" hideGenerationTimestamp: "true" equatable: true + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/csharp-restsharp-net8-name-mappings.yaml b/bin/configs/csharp-restsharp-net8-name-mappings.yaml index 7c97f10e434a..e8b627a79f4c 100644 --- a/bin/configs/csharp-restsharp-net8-name-mappings.yaml +++ b/bin/configs/csharp-restsharp-net8-name-mappings.yaml @@ -18,3 +18,4 @@ additionalProperties: hideGenerationTimestamp: "true" targetFramework: net8.0 equatable: true + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/csharp-restsharp-net8-useDateTimeForDate.yaml b/bin/configs/csharp-restsharp-net8-useDateTimeForDate.yaml index d9bb354d074b..d5b0b7182c2b 100644 --- a/bin/configs/csharp-restsharp-net8-useDateTimeForDate.yaml +++ b/bin/configs/csharp-restsharp-net8-useDateTimeForDate.yaml @@ -8,3 +8,4 @@ additionalProperties: packageGuid: '{D0A67E81-4061-48EB-B4B8-C73BDF8B2D95}' targetFramework: net8.0 useDateTimeForDate: true + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/csharp-restsharp-netstandard2.0-complexfiles.yaml b/bin/configs/csharp-restsharp-netstandard2.0-complexfiles.yaml index 07b20129a566..312b718cad35 100644 --- a/bin/configs/csharp-restsharp-netstandard2.0-complexfiles.yaml +++ b/bin/configs/csharp-restsharp-netstandard2.0-complexfiles.yaml @@ -8,5 +8,6 @@ additionalProperties: targetFramework: netstandard2.0 useCompareNetObjects: "true" equatable: true + disallowAdditionalPropertiesIfNotPresent: true globalProperties: skipFormModel: "false" diff --git a/bin/configs/csharp-restsharp-useVirtualForHooks.yaml b/bin/configs/csharp-restsharp-useVirtualForHooks.yaml index cc1675f55189..5f5ae93905cb 100644 --- a/bin/configs/csharp-restsharp-useVirtualForHooks.yaml +++ b/bin/configs/csharp-restsharp-useVirtualForHooks.yaml @@ -8,3 +8,4 @@ additionalProperties: packageGuid: '{D0A67E81-4061-48EB-B4B8-C73BDF8B2D95}' targetFramework: net8.0 useVirtualForHooks: true + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/csharp-unityWebRequest-netstandard2.0.yaml b/bin/configs/csharp-unityWebRequest-netstandard2.0.yaml index daac769aadcf..1a00efdfbee9 100644 --- a/bin/configs/csharp-unityWebRequest-netstandard2.0.yaml +++ b/bin/configs/csharp-unityWebRequest-netstandard2.0.yaml @@ -7,3 +7,4 @@ library: unityWebRequest additionalProperties: targetFramework: netstandard2.0 equatable: true + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/dart-dio-petstore-client-lib-fake.yaml b/bin/configs/dart-dio-petstore-client-lib-fake.yaml index d5b67a495e72..9034879687eb 100644 --- a/bin/configs/dart-dio-petstore-client-lib-fake.yaml +++ b/bin/configs/dart-dio-petstore-client-lib-fake.yaml @@ -9,5 +9,6 @@ typeMappings: additionalProperties: hideGenerationTimestamp: "true" enumUnknownDefaultCase: "true" + disallowAdditionalPropertiesIfNotPresent: true reservedWordsMappings: class: "classField" diff --git a/bin/configs/go-echo-api.yaml b/bin/configs/go-echo-api.yaml index 1d6b3be9b5ca..28d3be12a0be 100644 --- a/bin/configs/go-echo-api.yaml +++ b/bin/configs/go-echo-api.yaml @@ -4,3 +4,4 @@ inputSpec: modules/openapi-generator/src/test/resources/3_0/echo_api.yaml templateDir: modules/openapi-generator/src/main/resources/go additionalProperties: hideGenerationTimestamp: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/go-echo-external-refs-test.yaml b/bin/configs/go-echo-external-refs-test.yaml index b4145a26d486..9c6f58f1484c 100644 --- a/bin/configs/go-echo-external-refs-test.yaml +++ b/bin/configs/go-echo-external-refs-test.yaml @@ -4,3 +4,4 @@ inputSpec: modules/openapi-generator/src/test/resources/3_0/external-refs/echo_a templateDir: modules/openapi-generator/src/main/resources/go additionalProperties: hideGenerationTimestamp: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/go-multiple-allof-ref-with-discriminator.yaml b/bin/configs/go-multiple-allof-ref-with-discriminator.yaml index c2c8a195dc56..020b6cfa254e 100644 --- a/bin/configs/go-multiple-allof-ref-with-discriminator.yaml +++ b/bin/configs/go-multiple-allof-ref-with-discriminator.yaml @@ -3,3 +3,4 @@ outputDir: samples/client/others/go/allof_multiple_ref_and_discriminator inputSpec: modules/openapi-generator/src/test/resources/3_0/go/allof_multiple_ref_and_discriminator.yaml additionalProperties: hideGenerationTimestamp: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/go-oneof-anyof-required.yaml b/bin/configs/go-oneof-anyof-required.yaml index c91e0baa4a32..f1a1486ae8d3 100644 --- a/bin/configs/go-oneof-anyof-required.yaml +++ b/bin/configs/go-oneof-anyof-required.yaml @@ -3,3 +3,4 @@ outputDir: samples/client/others/go/oneof-anyof-required inputSpec: modules/openapi-generator/src/test/resources/3_0/go/spec-with-oneof-anyof-required.yaml additionalProperties: hideGenerationTimestamp: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/go-oneof-discriminator-lookup.yaml b/bin/configs/go-oneof-discriminator-lookup.yaml index b6b9e7ad28ef..a53e8bf800ba 100644 --- a/bin/configs/go-oneof-discriminator-lookup.yaml +++ b/bin/configs/go-oneof-discriminator-lookup.yaml @@ -4,3 +4,4 @@ inputSpec: modules/openapi-generator/src/test/resources/3_0/go/spec-with-oneof-d additionalProperties: useOneOfDiscriminatorLookup: "true" hideGenerationTimestamp: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/go-petstore-generateMarshalJSON-false.yaml b/bin/configs/go-petstore-generateMarshalJSON-false.yaml index ea9652acba66..c030862a65bb 100644 --- a/bin/configs/go-petstore-generateMarshalJSON-false.yaml +++ b/bin/configs/go-petstore-generateMarshalJSON-false.yaml @@ -5,5 +5,4 @@ templateDir: modules/openapi-generator/src/main/resources/go additionalProperties: enumClassPrefix: "true" packageName: petstore - disallowAdditionalPropertiesIfNotPresent: false generateMarshalJSON: false diff --git a/bin/configs/go-petstore-oas2.yaml b/bin/configs/go-petstore-oas2.yaml index 31f3436cf270..f8cabe030016 100644 --- a/bin/configs/go-petstore-oas2.yaml +++ b/bin/configs/go-petstore-oas2.yaml @@ -5,3 +5,4 @@ templateDir: modules/openapi-generator/src/main/resources/go additionalProperties: packageName: petstore generateInterfaces: true + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/go-petstore.yaml b/bin/configs/go-petstore.yaml index 7ab12f332a3e..755013dbc10b 100644 --- a/bin/configs/go-petstore.yaml +++ b/bin/configs/go-petstore.yaml @@ -13,7 +13,6 @@ parameterNameMappings: additionalProperties: enumClassPrefix: "true" packageName: petstore - disallowAdditionalPropertiesIfNotPresent: false generateInterfaces: true useDefaultValuesForRequiredVars: "true" enumNameMappings: diff --git a/bin/configs/java-feign-gson-echo-api.yaml b/bin/configs/java-feign-gson-echo-api.yaml index d765eb41c024..eeba2efce3cb 100644 --- a/bin/configs/java-feign-gson-echo-api.yaml +++ b/bin/configs/java-feign-gson-echo-api.yaml @@ -7,3 +7,4 @@ additionalProperties: serializationLibrary: gson artifactId: echo-api-feign-json hideGenerationTimestamp: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/java-feign-hc5.yaml b/bin/configs/java-feign-hc5.yaml index 47f816a0e3fb..03097dd03634 100644 --- a/bin/configs/java-feign-hc5.yaml +++ b/bin/configs/java-feign-hc5.yaml @@ -6,4 +6,5 @@ templateDir: modules/openapi-generator/src/main/resources/Java additionalProperties: booleanGetterPrefix: is artifactId: petstore-feign-hc5 - hideGenerationTimestamp: "true" \ No newline at end of file + hideGenerationTimestamp: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/java-feign-no-nullable.yaml b/bin/configs/java-feign-no-nullable.yaml index 50aacc2ff08f..6c5edc7a7ce9 100644 --- a/bin/configs/java-feign-no-nullable.yaml +++ b/bin/configs/java-feign-no-nullable.yaml @@ -11,3 +11,4 @@ additionalProperties: openApiNullable: false useReflectionEqualsHashCode: true annotationLibrary: "swagger1" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/java-feign.yaml b/bin/configs/java-feign.yaml index c27e7abaaabe..9f9101e8358e 100644 --- a/bin/configs/java-feign.yaml +++ b/bin/configs/java-feign.yaml @@ -7,3 +7,4 @@ additionalProperties: booleanGetterPrefix: is artifactId: petstore-feign hideGenerationTimestamp: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/java-jersey2-8-oas2.yaml b/bin/configs/java-jersey2-8-oas2.yaml index 4d3253e23ee5..20be125c2bb2 100644 --- a/bin/configs/java-jersey2-8-oas2.yaml +++ b/bin/configs/java-jersey2-8-oas2.yaml @@ -9,3 +9,4 @@ additionalProperties: serverPort: "8082" dateLibrary: java8 useOneOfDiscriminatorLookup: true + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/java-jersey2-8-oneOfDuplicateList.yaml b/bin/configs/java-jersey2-8-oneOfDuplicateList.yaml index 08b5c281f1a4..64cdc4a66473 100644 --- a/bin/configs/java-jersey2-8-oneOfDuplicateList.yaml +++ b/bin/configs/java-jersey2-8-oneOfDuplicateList.yaml @@ -5,3 +5,4 @@ inputSpec: modules/openapi-generator/src/test/resources/3_0/oneOf_duplicateArray templateDir: modules/openapi-generator/src/main/resources/Java additionalProperties: hideGenerationTimestamp: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/java-jersey2-8-oneOfMixed.yaml b/bin/configs/java-jersey2-8-oneOfMixed.yaml index af000059ac1c..a79f47014c5b 100644 --- a/bin/configs/java-jersey2-8-oneOfMixed.yaml +++ b/bin/configs/java-jersey2-8-oneOfMixed.yaml @@ -5,3 +5,4 @@ inputSpec: modules/openapi-generator/src/test/resources/3_0/oneOf_primitiveAndAr templateDir: modules/openapi-generator/src/main/resources/Java additionalProperties: hideGenerationTimestamp: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/java-jersey2-8-swagger1.yaml b/bin/configs/java-jersey2-8-swagger1.yaml index 643db1be1278..e99e88a84df9 100644 --- a/bin/configs/java-jersey2-8-swagger1.yaml +++ b/bin/configs/java-jersey2-8-swagger1.yaml @@ -9,6 +9,5 @@ additionalProperties: serverPort: "8082" dateLibrary: java8 useOneOfDiscriminatorLookup: true - disallowAdditionalPropertiesIfNotPresent: false gradleProperties: "\n# JVM arguments\norg.gradle.jvmargs=-Xmx2024m -XX:MaxPermSize=512m\n# set timeout\norg.gradle.daemon.idletimeout=3600000\n# show all warnings\norg.gradle.warning.mode=all" annotationLibrary: "swagger1" diff --git a/bin/configs/java-jersey2-8-swagger2.yaml b/bin/configs/java-jersey2-8-swagger2.yaml index f6513d8563e3..b28395b6a2b4 100644 --- a/bin/configs/java-jersey2-8-swagger2.yaml +++ b/bin/configs/java-jersey2-8-swagger2.yaml @@ -9,6 +9,5 @@ additionalProperties: serverPort: "8082" dateLibrary: java8 useOneOfDiscriminatorLookup: true - disallowAdditionalPropertiesIfNotPresent: false gradleProperties: "\n# JVM arguments\norg.gradle.jvmargs=-Xmx2024m -XX:MaxPermSize=512m\n# set timeout\norg.gradle.daemon.idletimeout=3600000\n# show all warnings\norg.gradle.warning.mode=all" annotationLibrary: "swagger2" diff --git a/bin/configs/java-jersey2-8.yaml b/bin/configs/java-jersey2-8.yaml index 259b88e07ceb..308f0d197c3c 100644 --- a/bin/configs/java-jersey2-8.yaml +++ b/bin/configs/java-jersey2-8.yaml @@ -9,7 +9,6 @@ additionalProperties: serverPort: "8082" dateLibrary: java8 useOneOfDiscriminatorLookup: true - disallowAdditionalPropertiesIfNotPresent: false gradleProperties: "\n# JVM arguments\norg.gradle.jvmargs=-Xmx2024m -XX:MaxPermSize=512m\n# set timeout\norg.gradle.daemon.idletimeout=3600000\n# show all warnings\norg.gradle.warning.mode=all" failOnUnknownProperties: true useReflectionEqualsHashCode: true diff --git a/bin/configs/java-jersey2-java8-localdatetime.yaml b/bin/configs/java-jersey2-java8-localdatetime.yaml index efa977d08a3b..ce8bd268626c 100644 --- a/bin/configs/java-jersey2-java8-localdatetime.yaml +++ b/bin/configs/java-jersey2-java8-localdatetime.yaml @@ -9,3 +9,4 @@ additionalProperties: dateLibrary: java8-localdatetime java8: true delegatePattern: true + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/java-jersey2-special-characters.yaml b/bin/configs/java-jersey2-special-characters.yaml index d2fb98091a29..99c6d7383ecb 100644 --- a/bin/configs/java-jersey2-special-characters.yaml +++ b/bin/configs/java-jersey2-special-characters.yaml @@ -9,5 +9,4 @@ additionalProperties: serverPort: "8082" dateLibrary: java8 useOneOfDiscriminatorLookup: true - disallowAdditionalPropertiesIfNotPresent: false validateSpec: false diff --git a/bin/configs/java-jersey3-oneOf.yaml b/bin/configs/java-jersey3-oneOf.yaml index 846b7bda109a..158a566e07bd 100644 --- a/bin/configs/java-jersey3-oneOf.yaml +++ b/bin/configs/java-jersey3-oneOf.yaml @@ -5,3 +5,4 @@ inputSpec: modules/openapi-generator/src/test/resources/3_0/oneOf_additionalProp templateDir: modules/openapi-generator/src/main/resources/Java additionalProperties: hideGenerationTimestamp: true + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/java-jersey3.yaml b/bin/configs/java-jersey3.yaml index 513f3889d3c7..c85701ae06d4 100644 --- a/bin/configs/java-jersey3.yaml +++ b/bin/configs/java-jersey3.yaml @@ -10,7 +10,6 @@ additionalProperties: serverPort: "8082" dateLibrary: java8 useOneOfDiscriminatorLookup: true - disallowAdditionalPropertiesIfNotPresent: false gradleProperties: "\n# JVM arguments\norg.gradle.jvmargs=-Xmx2024m -XX:MaxPermSize=512m\n# set timeout\norg.gradle.daemon.idletimeout=3600000\n# show all warnings\norg.gradle.warning.mode=all" failOnUnknownProperties: true useReflectionEqualsHashCode: true diff --git a/bin/configs/java-microprofile-rest-client-3.0-jackson.yaml b/bin/configs/java-microprofile-rest-client-3.0-jackson.yaml index 7ffcc1cdcb85..e877fe2dc2b3 100644 --- a/bin/configs/java-microprofile-rest-client-3.0-jackson.yaml +++ b/bin/configs/java-microprofile-rest-client-3.0-jackson.yaml @@ -10,3 +10,4 @@ additionalProperties: microprofileRestClientVersion: "3.0" hideGenerationTimestamp: true useReflectionEqualsHashCode: true + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/java-native-async.yaml b/bin/configs/java-native-async.yaml index a1932980486a..4363c2941542 100644 --- a/bin/configs/java-native-async.yaml +++ b/bin/configs/java-native-async.yaml @@ -7,3 +7,4 @@ additionalProperties: artifactId: petstore-native hideGenerationTimestamp: "true" asyncNative: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/java-native-echo-api.yaml b/bin/configs/java-native-echo-api.yaml index b782fe01fed2..c0d4b01ff01e 100644 --- a/bin/configs/java-native-echo-api.yaml +++ b/bin/configs/java-native-echo-api.yaml @@ -6,7 +6,7 @@ templateDir: modules/openapi-generator/src/main/resources/Java additionalProperties: artifactId: echo-api-native hideGenerationTimestamp: "true" - + disallowAdditionalPropertiesIfNotPresent: true typeMappings: OffsetDateTime: "Instant" importMappings: diff --git a/bin/configs/java-native.yaml b/bin/configs/java-native.yaml index 467d6da65459..4d1e6d7e555b 100644 --- a/bin/configs/java-native.yaml +++ b/bin/configs/java-native.yaml @@ -8,3 +8,4 @@ additionalProperties: hideGenerationTimestamp: "true" generateBuilders: true useReflectionEqualsHashCode: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/java-okhttp-gson-3.1-duplicated-operationid.yaml b/bin/configs/java-okhttp-gson-3.1-duplicated-operationid.yaml index a15c7f7f3c14..6580940ec3f2 100644 --- a/bin/configs/java-okhttp-gson-3.1-duplicated-operationid.yaml +++ b/bin/configs/java-okhttp-gson-3.1-duplicated-operationid.yaml @@ -7,6 +7,5 @@ validateSpec: false additionalProperties: artifactId: petstore-okhttp-gson-31-do hideGenerationTimestamp: "true" - disallowAdditionalPropertiesIfNotPresent: false openapiNormalizer: FIX_DUPLICATED_OPERATIONID: true diff --git a/bin/configs/java-okhttp-gson-3.1.yaml b/bin/configs/java-okhttp-gson-3.1.yaml index 845d7510c677..e5b1858df455 100644 --- a/bin/configs/java-okhttp-gson-3.1.yaml +++ b/bin/configs/java-okhttp-gson-3.1.yaml @@ -14,7 +14,6 @@ additionalProperties: artifactId: petstore-okhttp-gson-31 hideGenerationTimestamp: "true" useOneOfDiscriminatorLookup: "true" - disallowAdditionalPropertiesIfNotPresent: false enumPropertyNaming: legacy openapiNormalizer: FIX_DUPLICATED_OPERATIONID: true diff --git a/bin/configs/java-okhttp-gson-awsv4signature.yaml b/bin/configs/java-okhttp-gson-awsv4signature.yaml index 2c665cb4b087..d28e5fedee67 100644 --- a/bin/configs/java-okhttp-gson-awsv4signature.yaml +++ b/bin/configs/java-okhttp-gson-awsv4signature.yaml @@ -7,5 +7,4 @@ additionalProperties: artifactId: okhttp-gson-awsv4signature hideGenerationTimestamp: "true" useOneOfDiscriminatorLookup: "true" - disallowAdditionalPropertiesIfNotPresent: false withAWSV4Signature: true \ No newline at end of file diff --git a/bin/configs/java-okhttp-gson-dynamicOperations.yaml b/bin/configs/java-okhttp-gson-dynamicOperations.yaml index 751ce2e992c9..be18d465e131 100644 --- a/bin/configs/java-okhttp-gson-dynamicOperations.yaml +++ b/bin/configs/java-okhttp-gson-dynamicOperations.yaml @@ -7,3 +7,4 @@ additionalProperties: artifactId: petstore-okhttp-gson-dynamicoperations hideGenerationTimestamp: "true" dynamicOperations: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/java-okhttp-gson-echo-api.yaml b/bin/configs/java-okhttp-gson-echo-api.yaml index 825c1902eee8..e0994a3186be 100644 --- a/bin/configs/java-okhttp-gson-echo-api.yaml +++ b/bin/configs/java-okhttp-gson-echo-api.yaml @@ -6,3 +6,4 @@ templateDir: modules/openapi-generator/src/main/resources/Java additionalProperties: artifactId: echo-api-okhttp-gson hideGenerationTimestamp: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/java-okhttp-gson-group-parameter.yaml b/bin/configs/java-okhttp-gson-group-parameter.yaml index 936f9f0a4b0e..267d380db4f6 100644 --- a/bin/configs/java-okhttp-gson-group-parameter.yaml +++ b/bin/configs/java-okhttp-gson-group-parameter.yaml @@ -6,5 +6,4 @@ templateDir: modules/openapi-generator/src/main/resources/Java additionalProperties: artifactId: petstore-okhttp-gson-group-parameter hideGenerationTimestamp: "true" - disallowAdditionalPropertiesIfNotPresent: false useSingleRequestParameter: true diff --git a/bin/configs/java-okhttp-gson-nullable-required.yaml b/bin/configs/java-okhttp-gson-nullable-required.yaml index 756f8b1b269f..88e78917b25a 100644 --- a/bin/configs/java-okhttp-gson-nullable-required.yaml +++ b/bin/configs/java-okhttp-gson-nullable-required.yaml @@ -7,4 +7,3 @@ additionalProperties: artifactId: nullable-required-okhttp-gson hideGenerationTimestamp: "true" useOneOfDiscriminatorLookup: "true" - disallowAdditionalPropertiesIfNotPresent: false diff --git a/bin/configs/java-okhttp-gson-oneOf-array.yaml b/bin/configs/java-okhttp-gson-oneOf-array.yaml index 98cf51a976ff..3e0b8e43f741 100644 --- a/bin/configs/java-okhttp-gson-oneOf-array.yaml +++ b/bin/configs/java-okhttp-gson-oneOf-array.yaml @@ -6,3 +6,4 @@ templateDir: modules/openapi-generator/src/main/resources/Java additionalProperties: hideGenerationTimestamp: "true" useBeanValidation: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/java-okhttp-gson-parcelableModel.yaml b/bin/configs/java-okhttp-gson-parcelableModel.yaml index c9cbb2008b1d..d4d2eba339dd 100644 --- a/bin/configs/java-okhttp-gson-parcelableModel.yaml +++ b/bin/configs/java-okhttp-gson-parcelableModel.yaml @@ -7,3 +7,4 @@ additionalProperties: parcelableModel: "true" artifactId: petstore-okhttp-gson-parcelableModel hideGenerationTimestamp: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/java-okhttp-gson-streaming.yaml b/bin/configs/java-okhttp-gson-streaming.yaml index a5ab03be70dd..f5f2aa07f7fb 100644 --- a/bin/configs/java-okhttp-gson-streaming.yaml +++ b/bin/configs/java-okhttp-gson-streaming.yaml @@ -9,3 +9,4 @@ additionalProperties: supportStreaming: true serializableModel: true enumPropertyNaming: legacy + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/java-okhttp-gson-swagger1.yaml b/bin/configs/java-okhttp-gson-swagger1.yaml index df09bc1f9df6..f98403b29246 100644 --- a/bin/configs/java-okhttp-gson-swagger1.yaml +++ b/bin/configs/java-okhttp-gson-swagger1.yaml @@ -7,7 +7,6 @@ additionalProperties: artifactId: petstore-okhttp-gson hideGenerationTimestamp: "true" useOneOfDiscriminatorLookup: "true" - disallowAdditionalPropertiesIfNotPresent: false annotationLibrary: "swagger1" openapiNormalizer: SET_TAGS_FOR_ALL_OPERATIONS: common diff --git a/bin/configs/java-okhttp-gson-swagger2.yaml b/bin/configs/java-okhttp-gson-swagger2.yaml index 0abc66536fa6..05a09d6cbe23 100644 --- a/bin/configs/java-okhttp-gson-swagger2.yaml +++ b/bin/configs/java-okhttp-gson-swagger2.yaml @@ -7,6 +7,5 @@ additionalProperties: artifactId: petstore-okhttp-gson hideGenerationTimestamp: "true" useOneOfDiscriminatorLookup: "true" - disallowAdditionalPropertiesIfNotPresent: false annotationLibrary: "swagger2" diff --git a/bin/configs/java-okhttp-gson.yaml b/bin/configs/java-okhttp-gson.yaml index f404858c2776..476a742050d8 100644 --- a/bin/configs/java-okhttp-gson.yaml +++ b/bin/configs/java-okhttp-gson.yaml @@ -14,7 +14,6 @@ additionalProperties: artifactId: petstore-okhttp-gson hideGenerationTimestamp: true useOneOfDiscriminatorLookup: true - disallowAdditionalPropertiesIfNotPresent: false useReflectionEqualsHashCode:: true removeEnumValuePrefix: true enumNameMappings: diff --git a/bin/configs/java-okhttp-user-defined-templates.yaml b/bin/configs/java-okhttp-user-defined-templates.yaml index 650c2dc1b195..20374ff3151c 100644 --- a/bin/configs/java-okhttp-user-defined-templates.yaml +++ b/bin/configs/java-okhttp-user-defined-templates.yaml @@ -5,6 +5,7 @@ inputSpec: modules/openapi-generator/src/test/resources/3_0/petstore.yaml templateDir: modules/openapi-generator/src/main/resources/Java additionalProperties: hideGenerationTimestamp: "true" + disallowAdditionalPropertiesIfNotPresent: true files: README.mustache: destinationFilename: info.md diff --git a/bin/configs/java-restclient-echo-api.yaml b/bin/configs/java-restclient-echo-api.yaml index 9612901f8f7e..65d734598911 100644 --- a/bin/configs/java-restclient-echo-api.yaml +++ b/bin/configs/java-restclient-echo-api.yaml @@ -6,7 +6,7 @@ templateDir: modules/openapi-generator/src/main/resources/Java additionalProperties: artifactId: echo-api-native hideGenerationTimestamp: "true" - + disallowAdditionalPropertiesIfNotPresent: true typeMappings: OffsetDateTime: "Instant" importMappings: diff --git a/bin/configs/java-restclient-swagger2.yaml b/bin/configs/java-restclient-swagger2.yaml index a4fc8ba02cd2..f69f833186c6 100644 --- a/bin/configs/java-restclient-swagger2.yaml +++ b/bin/configs/java-restclient-swagger2.yaml @@ -8,3 +8,4 @@ additionalProperties: hideGenerationTimestamp: "true" containerDefaultToNull: "true" annotationLibrary: "swagger2" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/java-restclient-useSingleRequestParameter-static.yaml b/bin/configs/java-restclient-useSingleRequestParameter-static.yaml index 256bf5ebcb6e..8740bcec273f 100644 --- a/bin/configs/java-restclient-useSingleRequestParameter-static.yaml +++ b/bin/configs/java-restclient-useSingleRequestParameter-static.yaml @@ -6,4 +6,5 @@ templateDir: modules/openapi-generator/src/main/resources/Java additionalProperties: artifactId: singleparam-restclient-static hideGenerationTimestamp: "true" - useSingleRequestParameter: static \ No newline at end of file + useSingleRequestParameter: static + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/java-restclient-useSingleRequestParameter.yaml b/bin/configs/java-restclient-useSingleRequestParameter.yaml index 163d83e10db1..fe1d70825cf2 100644 --- a/bin/configs/java-restclient-useSingleRequestParameter.yaml +++ b/bin/configs/java-restclient-useSingleRequestParameter.yaml @@ -7,3 +7,4 @@ additionalProperties: artifactId: singleparam-restclient hideGenerationTimestamp: "true" useSingleRequestParameter: true + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/java-restclient.yaml b/bin/configs/java-restclient.yaml index e5c5ac1e73fb..c6c66545514a 100644 --- a/bin/configs/java-restclient.yaml +++ b/bin/configs/java-restclient.yaml @@ -7,3 +7,4 @@ additionalProperties: artifactId: petstore-restclient hideGenerationTimestamp: "true" containerDefaultToNull: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/java-resttemplate-echo-api.yaml b/bin/configs/java-resttemplate-echo-api.yaml index 27e9a63cfa69..30792cdba258 100644 --- a/bin/configs/java-resttemplate-echo-api.yaml +++ b/bin/configs/java-resttemplate-echo-api.yaml @@ -8,3 +8,4 @@ additionalProperties: hideGenerationTimestamp: "true" java8: true containerDefaultToNull: true + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/java-resttemplate-withXml.yaml b/bin/configs/java-resttemplate-withXml.yaml index 6733aab84006..415a46cafc75 100644 --- a/bin/configs/java-resttemplate-withXml.yaml +++ b/bin/configs/java-resttemplate-withXml.yaml @@ -8,3 +8,4 @@ additionalProperties: withXml: "true" artifactId: petstore-resttemplate-withxml hideGenerationTimestamp: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/java-resttemplate.yaml b/bin/configs/java-resttemplate.yaml index 9d8bec574615..7367b655574b 100644 --- a/bin/configs/java-resttemplate.yaml +++ b/bin/configs/java-resttemplate.yaml @@ -10,3 +10,4 @@ additionalProperties: containerDefaultToNull: true generateConstructorWithAllArgs: true generateBuilders: true + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/java-webclient-jakarta.yaml b/bin/configs/java-webclient-jakarta.yaml index 038c74112699..3fb97afad093 100644 --- a/bin/configs/java-webclient-jakarta.yaml +++ b/bin/configs/java-webclient-jakarta.yaml @@ -7,3 +7,4 @@ additionalProperties: artifactId: petstore-webclient hideGenerationTimestamp: "true" useJakartaEe: true + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/java-webclient-sealedInterface.yaml b/bin/configs/java-webclient-sealedInterface.yaml index 43ba9421f7bc..6cb804e02db3 100644 --- a/bin/configs/java-webclient-sealedInterface.yaml +++ b/bin/configs/java-webclient-sealedInterface.yaml @@ -8,3 +8,4 @@ additionalProperties: hideGenerationTimestamp: "true" useOneOfInterfaces: true useSealedOneOfInterfaces: true + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/java-webclient-swagger2.yaml b/bin/configs/java-webclient-swagger2.yaml index 0c1d647a1b4d..29f05334d102 100644 --- a/bin/configs/java-webclient-swagger2.yaml +++ b/bin/configs/java-webclient-swagger2.yaml @@ -8,3 +8,4 @@ additionalProperties: hideGenerationTimestamp: "true" containerDefaultToNull: "true" annotationLibrary: "swagger2" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/java-webclient-useSingleRequestParameter.yaml b/bin/configs/java-webclient-useSingleRequestParameter.yaml index d0e3662823f9..ea44307f613c 100644 --- a/bin/configs/java-webclient-useSingleRequestParameter.yaml +++ b/bin/configs/java-webclient-useSingleRequestParameter.yaml @@ -7,3 +7,4 @@ additionalProperties: artifactId: singleparam-webclient hideGenerationTimestamp: "true" useSingleRequestParameter: true + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/java-webclient.yaml b/bin/configs/java-webclient.yaml index d05ea4bc14b4..302829eed93e 100644 --- a/bin/configs/java-webclient.yaml +++ b/bin/configs/java-webclient.yaml @@ -7,3 +7,4 @@ additionalProperties: artifactId: petstore-webclient hideGenerationTimestamp: "true" containerDefaultToNull: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/jaxrs-spec-jakarta.yaml b/bin/configs/jaxrs-spec-jakarta.yaml index 760dbdea9df4..b324f1bc04af 100644 --- a/bin/configs/jaxrs-spec-jakarta.yaml +++ b/bin/configs/jaxrs-spec-jakarta.yaml @@ -9,3 +9,4 @@ additionalProperties: implicitHeadersRegex: (api_key|enum_header_string) generateBuilders: "true" useJakartaEe: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/jaxrs-spec-quarkus-microprofile-openapi-annotations.yaml b/bin/configs/jaxrs-spec-quarkus-microprofile-openapi-annotations.yaml index 2a52665ab94c..4170b29ffd42 100644 --- a/bin/configs/jaxrs-spec-quarkus-microprofile-openapi-annotations.yaml +++ b/bin/configs/jaxrs-spec-quarkus-microprofile-openapi-annotations.yaml @@ -11,3 +11,4 @@ additionalProperties: useMicroProfileOpenAPIAnnotations: "true" library: "quarkus" dateLibrary: "java8-localdatetime" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/jaxrs-spec-quarkus-mutiny.yaml b/bin/configs/jaxrs-spec-quarkus-mutiny.yaml index 5620523e027f..d320d38ba0d7 100644 --- a/bin/configs/jaxrs-spec-quarkus-mutiny.yaml +++ b/bin/configs/jaxrs-spec-quarkus-mutiny.yaml @@ -13,3 +13,4 @@ additionalProperties: useMutiny: "true" library: "quarkus" dateLibrary: "java8-localdatetime" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/jaxrs-spec-required-and-readonly-property.yaml b/bin/configs/jaxrs-spec-required-and-readonly-property.yaml index c6a1f2573852..ae485900b1a6 100644 --- a/bin/configs/jaxrs-spec-required-and-readonly-property.yaml +++ b/bin/configs/jaxrs-spec-required-and-readonly-property.yaml @@ -8,3 +8,4 @@ additionalProperties: hideGenerationTimestamp: "true" implicitHeadersRegex: (api_key|enum_header_string) generateBuilders: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/jaxrs-spec-swagger-annotations.yaml b/bin/configs/jaxrs-spec-swagger-annotations.yaml index 32b94175c667..ddd92e4b15bf 100644 --- a/bin/configs/jaxrs-spec-swagger-annotations.yaml +++ b/bin/configs/jaxrs-spec-swagger-annotations.yaml @@ -9,3 +9,4 @@ additionalProperties: implicitHeadersRegex: (api_key|enum_header_string) generateBuilders: "true" useSwaggerAnnotations: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/jaxrs-spec-swagger-v3-annotations-jakarta.yaml b/bin/configs/jaxrs-spec-swagger-v3-annotations-jakarta.yaml index 45176fa3384f..d60bfdbaf3ae 100644 --- a/bin/configs/jaxrs-spec-swagger-v3-annotations-jakarta.yaml +++ b/bin/configs/jaxrs-spec-swagger-v3-annotations-jakarta.yaml @@ -10,3 +10,4 @@ additionalProperties: generateBuilders: "true" useSwaggerV3Annotations: "true" useJakartaEe: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/jaxrs-spec-swagger-v3-annotations.yaml b/bin/configs/jaxrs-spec-swagger-v3-annotations.yaml index 903753fa5e2f..74f484a43ebc 100644 --- a/bin/configs/jaxrs-spec-swagger-v3-annotations.yaml +++ b/bin/configs/jaxrs-spec-swagger-v3-annotations.yaml @@ -9,3 +9,4 @@ additionalProperties: implicitHeadersRegex: (api_key|enum_header_string) generateBuilders: "true" useSwaggerV3Annotations: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/jaxrs-spec-withxml.yaml b/bin/configs/jaxrs-spec-withxml.yaml index f893491fc9fb..dcb6546408fa 100644 --- a/bin/configs/jaxrs-spec-withxml.yaml +++ b/bin/configs/jaxrs-spec-withxml.yaml @@ -8,3 +8,4 @@ additionalProperties: hideGenerationTimestamp: "true" generateBuilders: "true" withXml: true + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/jaxrs-spec.yaml b/bin/configs/jaxrs-spec.yaml index 0eca24e42590..bede25c1147a 100644 --- a/bin/configs/jaxrs-spec.yaml +++ b/bin/configs/jaxrs-spec.yaml @@ -8,3 +8,4 @@ additionalProperties: hideGenerationTimestamp: "true" implicitHeadersRegex: (api_key|enum_header_string) generateBuilders: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/powershell-echo-api.yaml b/bin/configs/powershell-echo-api.yaml index 2bf9c383c17a..91713e9694c9 100644 --- a/bin/configs/powershell-echo-api.yaml +++ b/bin/configs/powershell-echo-api.yaml @@ -5,3 +5,4 @@ templateDir: modules/openapi-generator/src/main/resources/powershell additionalProperties: hideGenerationTimestamp: "true" packageGuid: a27b908d-2a20-467f-bc32-af6f3a654ac5 + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/powershell.yaml b/bin/configs/powershell.yaml index 3dccae4c8b71..7e712d0ab824 100644 --- a/bin/configs/powershell.yaml +++ b/bin/configs/powershell.yaml @@ -14,6 +14,7 @@ additionalProperties: projectUri: https://github.com/OpenAPITools/openapi-generator releaseNotes: 'This is a sample project' tags: 'PetStore,powershell,sdk' + disallowAdditionalPropertiesIfNotPresent: true nameMappings: name_mapping: SomethingElse modelNameMappings: diff --git a/bin/configs/protobuf-schema.yaml b/bin/configs/protobuf-schema.yaml index c3947e075dca..3976fce83b9e 100644 --- a/bin/configs/protobuf-schema.yaml +++ b/bin/configs/protobuf-schema.yaml @@ -4,6 +4,7 @@ inputSpec: modules/openapi-generator/src/test/resources/3_0/protobuf/petstore.ya templateDir: modules/openapi-generator/src/main/resources/protobuf-schema additionalProperties: packageName: petstore + disallowAdditionalPropertiesIfNotPresent: true typeMappings: object: "google.protobuf.Struct" importMappings: diff --git a/bin/configs/python-aiohttp.yaml b/bin/configs/python-aiohttp.yaml index 14a1adeffd39..4de1d31d1f86 100644 --- a/bin/configs/python-aiohttp.yaml +++ b/bin/configs/python-aiohttp.yaml @@ -7,6 +7,7 @@ additionalProperties: packageName: petstore_api mapNumberTo: float poetry1: true + disallowAdditionalPropertiesIfNotPresent: true nameMappings: _type: underscore_type type_: type_with_underscore diff --git a/bin/configs/python-echo-api.yaml b/bin/configs/python-echo-api.yaml index 8c161951aca8..edd245c060d4 100644 --- a/bin/configs/python-echo-api.yaml +++ b/bin/configs/python-echo-api.yaml @@ -4,3 +4,4 @@ inputSpec: modules/openapi-generator/src/test/resources/3_0/echo_api.yaml templateDir: modules/openapi-generator/src/main/resources/python additionalProperties: hideGenerationTimestamp: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/python-fastapi.yaml b/bin/configs/python-fastapi.yaml index f2b7c97fbd1c..c757d25e092b 100644 --- a/bin/configs/python-fastapi.yaml +++ b/bin/configs/python-fastapi.yaml @@ -5,3 +5,4 @@ templateDir: modules/openapi-generator/src/main/resources/python-fastapi sourceFolder: "src" additionalProperties: hideGenerationTimestamp: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/python-pydantic-v1-aiohttp.yaml b/bin/configs/python-pydantic-v1-aiohttp.yaml index 2ba8f2326741..e72d0f917af8 100644 --- a/bin/configs/python-pydantic-v1-aiohttp.yaml +++ b/bin/configs/python-pydantic-v1-aiohttp.yaml @@ -6,3 +6,4 @@ library: asyncio additionalProperties: packageName: petstore_api mapNumberTo: float + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/python-pydantic-v1-echo-api.yaml b/bin/configs/python-pydantic-v1-echo-api.yaml index 19020abc3b6a..bb9487f9159d 100644 --- a/bin/configs/python-pydantic-v1-echo-api.yaml +++ b/bin/configs/python-pydantic-v1-echo-api.yaml @@ -4,3 +4,4 @@ inputSpec: modules/openapi-generator/src/test/resources/3_0/echo_api.yaml templateDir: modules/openapi-generator/src/main/resources/python-pydantic-v1 additionalProperties: hideGenerationTimestamp: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/python-pydantic-v1.yaml b/bin/configs/python-pydantic-v1.yaml index e5530ff42019..0e7ce54670d3 100644 --- a/bin/configs/python-pydantic-v1.yaml +++ b/bin/configs/python-pydantic-v1.yaml @@ -8,7 +8,6 @@ gitRepoId: GIT_REPO_ID additionalProperties: packageName: petstore_api useOneOfDiscriminatorLookup: "true" - disallowAdditionalPropertiesIfNotPresent: false mapNumberTo: StrictFloat nameMappings: _type: underscore_type diff --git a/bin/configs/python.yaml b/bin/configs/python.yaml index 606ef8c77423..c35490682bc2 100644 --- a/bin/configs/python.yaml +++ b/bin/configs/python.yaml @@ -5,7 +5,6 @@ templateDir: modules/openapi-generator/src/main/resources/python additionalProperties: packageName: petstore_api useOneOfDiscriminatorLookup: "true" - disallowAdditionalPropertiesIfNotPresent: false mapNumberTo: StrictFloat nameMappings: _type: underscore_type diff --git a/bin/configs/r-client.yaml b/bin/configs/r-client.yaml index d52db86cac8f..65483a37f4b8 100644 --- a/bin/configs/r-client.yaml +++ b/bin/configs/r-client.yaml @@ -10,4 +10,3 @@ additionalProperties: returnExceptionOnFailure: true errorObjectType: "ModelApiResponse" operationIdNaming: PascalCase #default - disallowAdditionalPropertiesIfNotPresent: false diff --git a/bin/configs/r-echo-api.yaml b/bin/configs/r-echo-api.yaml index 4e631725783e..fab07f2b6c09 100644 --- a/bin/configs/r-echo-api.yaml +++ b/bin/configs/r-echo-api.yaml @@ -4,3 +4,4 @@ inputSpec: modules/openapi-generator/src/test/resources/3_0/echo_api.yaml templateDir: modules/openapi-generator/src/main/resources/r additionalProperties: hideGenerationTimestamp: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/r-httr2-client.yaml b/bin/configs/r-httr2-client.yaml index c842eefa49e4..ce6e574063fe 100644 --- a/bin/configs/r-httr2-client.yaml +++ b/bin/configs/r-httr2-client.yaml @@ -17,4 +17,4 @@ additionalProperties: returnExceptionOnFailure: true errorObjectType: "ModelApiResponse" operationIdNaming: snake_case - + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/r-httr2-wrapper-client.yaml b/bin/configs/r-httr2-wrapper-client.yaml index 18b3dbc4bb1c..796479f0dceb 100644 --- a/bin/configs/r-httr2-wrapper-client.yaml +++ b/bin/configs/r-httr2-wrapper-client.yaml @@ -13,4 +13,3 @@ additionalProperties: operationIdNaming: snake_case generateWrapper: true useOneOfDiscriminatorLookup: true - disallowAdditionalPropertiesIfNotPresent: false diff --git a/bin/configs/rust-server-deprecated-openapi-v3.yaml b/bin/configs/rust-server-deprecated-openapi-v3.yaml index f4fc0e28ed8c..902f9d0a3d56 100644 --- a/bin/configs/rust-server-deprecated-openapi-v3.yaml +++ b/bin/configs/rust-server-deprecated-openapi-v3.yaml @@ -6,3 +6,4 @@ generateAliasAsModel: true additionalProperties: hideGenerationTimestamp: "true" packageName: openapi-v3 + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/rust-server-deprecated-petstore-with-fake-endpoints-models-for-testing.yaml b/bin/configs/rust-server-deprecated-petstore-with-fake-endpoints-models-for-testing.yaml index 0a88b74392b3..0a749c21dbf7 100644 --- a/bin/configs/rust-server-deprecated-petstore-with-fake-endpoints-models-for-testing.yaml +++ b/bin/configs/rust-server-deprecated-petstore-with-fake-endpoints-models-for-testing.yaml @@ -7,3 +7,4 @@ additionalProperties: hideGenerationTimestamp: "true" packageName: petstore-with-fake-endpoints-models-for-testing publishRustRegistry: crates-io + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/rust-server-openapi-v3.yaml b/bin/configs/rust-server-openapi-v3.yaml index 6ed1c294662a..e62bafefbcf2 100644 --- a/bin/configs/rust-server-openapi-v3.yaml +++ b/bin/configs/rust-server-openapi-v3.yaml @@ -6,3 +6,4 @@ generateAliasAsModel: true additionalProperties: hideGenerationTimestamp: "true" packageName: openapi-v3 + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/rust-server-petstore-with-fake-endpoints-models-for-testing.yaml b/bin/configs/rust-server-petstore-with-fake-endpoints-models-for-testing.yaml index 7e009c7d9529..0e9d71cef1a8 100644 --- a/bin/configs/rust-server-petstore-with-fake-endpoints-models-for-testing.yaml +++ b/bin/configs/rust-server-petstore-with-fake-endpoints-models-for-testing.yaml @@ -7,3 +7,4 @@ additionalProperties: hideGenerationTimestamp: "true" packageName: petstore-with-fake-endpoints-models-for-testing publishRustRegistry: crates-io + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/scala-cask-petstore.yaml b/bin/configs/scala-cask-petstore.yaml index 283d643de95b..23393dac584c 100644 --- a/bin/configs/scala-cask-petstore.yaml +++ b/bin/configs/scala-cask-petstore.yaml @@ -10,4 +10,5 @@ additionalProperties: modelPackage: "sample.cask.model" apiPackage: "sample.cask.api" gitRepoId: "sample-cask-repo" - gitUserId: "sample-cask-user" \ No newline at end of file + gitUserId: "sample-cask-user" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/spring-boot-beanvalidation-no-nullable.yaml b/bin/configs/spring-boot-beanvalidation-no-nullable.yaml index 718b0a87e9d0..3908d71f99ec 100644 --- a/bin/configs/spring-boot-beanvalidation-no-nullable.yaml +++ b/bin/configs/spring-boot-beanvalidation-no-nullable.yaml @@ -11,3 +11,4 @@ additionalProperties: artifactId: spring-boot-beanvalidation-no-nullable hideGenerationTimestamp: "true" openApiNullable: "false" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/spring-boot-beanvalidation.yaml b/bin/configs/spring-boot-beanvalidation.yaml index b43f22721a1b..cfa39236a7d7 100644 --- a/bin/configs/spring-boot-beanvalidation.yaml +++ b/bin/configs/spring-boot-beanvalidation.yaml @@ -10,3 +10,4 @@ additionalProperties: useBeanValidation: true artifactId: spring-boot-beanvalidation hideGenerationTimestamp: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/spring-boot-builtin-validation.yaml b/bin/configs/spring-boot-builtin-validation.yaml index a645153158f9..dbab8af0e538 100644 --- a/bin/configs/spring-boot-builtin-validation.yaml +++ b/bin/configs/spring-boot-builtin-validation.yaml @@ -11,3 +11,4 @@ additionalProperties: useSpringBuiltInValidation: true artifactId: spring-boot-builtin-validation hideGenerationTimestamp: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/spring-boot-defaultInterface-unhandledException.yaml b/bin/configs/spring-boot-defaultInterface-unhandledException.yaml index 9e0960628839..79910f866590 100644 --- a/bin/configs/spring-boot-defaultInterface-unhandledException.yaml +++ b/bin/configs/spring-boot-defaultInterface-unhandledException.yaml @@ -9,3 +9,4 @@ additionalProperties: interfaceOnly: true skipDefaultInterface: true unhandledException: true + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/spring-boot-delegate-j8.yaml b/bin/configs/spring-boot-delegate-j8.yaml index be11dd0dec01..78795ebe8755 100644 --- a/bin/configs/spring-boot-delegate-j8.yaml +++ b/bin/configs/spring-boot-delegate-j8.yaml @@ -7,3 +7,4 @@ additionalProperties: artifactId: springboot-delegate-j8 hideGenerationTimestamp: "true" delegatePattern: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/spring-boot-delegate-oas3.yaml b/bin/configs/spring-boot-delegate-oas3.yaml index 28ba653ad086..be1355b6b2e9 100644 --- a/bin/configs/spring-boot-delegate-oas3.yaml +++ b/bin/configs/spring-boot-delegate-oas3.yaml @@ -9,3 +9,4 @@ additionalProperties: hideGenerationTimestamp: "true" java8: true delegatePattern: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/spring-boot-delegate.yaml b/bin/configs/spring-boot-delegate.yaml index cf5e016cdbf8..6925f8894672 100644 --- a/bin/configs/spring-boot-delegate.yaml +++ b/bin/configs/spring-boot-delegate.yaml @@ -9,3 +9,4 @@ additionalProperties: java8: true delegatePattern: "true" generateConstructorWithAllArgs: true + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/spring-boot-implicitHeaders-oas3.yaml b/bin/configs/spring-boot-implicitHeaders-oas3.yaml index 6d204b53c55e..d7e89db82d79 100644 --- a/bin/configs/spring-boot-implicitHeaders-oas3.yaml +++ b/bin/configs/spring-boot-implicitHeaders-oas3.yaml @@ -9,3 +9,4 @@ additionalProperties: artifactId: springboot-implicitHeaders hideGenerationTimestamp: "true" implicitHeaders: true + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/spring-boot-implicitHeaders.yaml b/bin/configs/spring-boot-implicitHeaders.yaml index b9a1a81c146f..0c5fe19892a4 100644 --- a/bin/configs/spring-boot-implicitHeaders.yaml +++ b/bin/configs/spring-boot-implicitHeaders.yaml @@ -7,3 +7,4 @@ additionalProperties: documentationProvider: springfox hideGenerationTimestamp: "true" implicitHeadersRegex: .* + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/spring-boot-oneof-sealed.yaml b/bin/configs/spring-boot-oneof-sealed.yaml index 83da74dc7c01..2fb51a371e6f 100644 --- a/bin/configs/spring-boot-oneof-sealed.yaml +++ b/bin/configs/spring-boot-oneof-sealed.yaml @@ -11,3 +11,4 @@ additionalProperties: generateBuilders: true useOneOfInterfaces: true useSealed: true + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/spring-boot-oneof.yaml b/bin/configs/spring-boot-oneof.yaml index f4a7ca7a99cc..46e849144fd2 100644 --- a/bin/configs/spring-boot-oneof.yaml +++ b/bin/configs/spring-boot-oneof.yaml @@ -9,3 +9,4 @@ additionalProperties: snapshotVersion: "true" hideGenerationTimestamp: "true" generateBuilders: true + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/spring-boot-reactive-noResponseEntity.yaml b/bin/configs/spring-boot-reactive-noResponseEntity.yaml index 746184ef2aba..1a5b7725d1a5 100644 --- a/bin/configs/spring-boot-reactive-noResponseEntity.yaml +++ b/bin/configs/spring-boot-reactive-noResponseEntity.yaml @@ -10,3 +10,4 @@ additionalProperties: hideGenerationTimestamp: "true" delegatePattern: "true" useResponseEntity: "false" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/spring-boot-reactive.yaml b/bin/configs/spring-boot-reactive.yaml index ed5a1e56239e..5524264f325d 100644 --- a/bin/configs/spring-boot-reactive.yaml +++ b/bin/configs/spring-boot-reactive.yaml @@ -9,3 +9,4 @@ additionalProperties: reactive: "true" hideGenerationTimestamp: "true" delegatePattern: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/spring-boot-useoptional.yaml b/bin/configs/spring-boot-useoptional.yaml index 82530260d677..e878668e46b3 100644 --- a/bin/configs/spring-boot-useoptional.yaml +++ b/bin/configs/spring-boot-useoptional.yaml @@ -9,3 +9,4 @@ additionalProperties: artifactId: spring-boot-useoptional hideGenerationTimestamp: "true" generateBuilders: true + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/spring-boot-virtualan.yaml b/bin/configs/spring-boot-virtualan.yaml index 87a2e30fb91a..3ea1ab859ed8 100644 --- a/bin/configs/spring-boot-virtualan.yaml +++ b/bin/configs/spring-boot-virtualan.yaml @@ -10,3 +10,4 @@ additionalProperties: virtualService: true artifactId: springboot-virtualan hideGenerationTimestamp: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/spring-boot.yaml b/bin/configs/spring-boot.yaml index 3480d1ba174f..8d98dc32f0c3 100644 --- a/bin/configs/spring-boot.yaml +++ b/bin/configs/spring-boot.yaml @@ -9,3 +9,4 @@ additionalProperties: hideGenerationTimestamp: "true" camelCaseDollarSign: "true" modelNameSuffix: 'Dto' + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/spring-cloud-oas3-fakeapi.yaml b/bin/configs/spring-cloud-oas3-fakeapi.yaml index b4582cbe1c06..bab00d879c8f 100644 --- a/bin/configs/spring-cloud-oas3-fakeapi.yaml +++ b/bin/configs/spring-cloud-oas3-fakeapi.yaml @@ -12,3 +12,4 @@ additionalProperties: hideGenerationTimestamp: "true" generatedConstructorWithRequiredArgs: "false" useTags: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/spring-http-interface-noResponseEntity.yaml b/bin/configs/spring-http-interface-noResponseEntity.yaml index 86da41551bf8..6b31e06dd69d 100644 --- a/bin/configs/spring-http-interface-noResponseEntity.yaml +++ b/bin/configs/spring-http-interface-noResponseEntity.yaml @@ -17,3 +17,4 @@ additionalProperties: useBeanValidation: "true" performBeanValidation: "true" useResponseEntity: "false" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/spring-http-interface-reactive-noResponseEntity.yaml b/bin/configs/spring-http-interface-reactive-noResponseEntity.yaml index f7933733e896..fc0f0e11ba6c 100644 --- a/bin/configs/spring-http-interface-reactive-noResponseEntity.yaml +++ b/bin/configs/spring-http-interface-reactive-noResponseEntity.yaml @@ -16,4 +16,4 @@ additionalProperties: useBeanValidation: "true" performBeanValidation: "true" useResponseEntity: "false" - + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/spring-http-interface-reactive.yaml b/bin/configs/spring-http-interface-reactive.yaml index b671383e90dc..2038cb6e7e02 100644 --- a/bin/configs/spring-http-interface-reactive.yaml +++ b/bin/configs/spring-http-interface-reactive.yaml @@ -15,4 +15,4 @@ additionalProperties: # validation should be ignored useBeanValidation: "true" performBeanValidation: "true" - + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/spring-http-interface.yaml b/bin/configs/spring-http-interface.yaml index 983d2ad85ff4..052450098da3 100644 --- a/bin/configs/spring-http-interface.yaml +++ b/bin/configs/spring-http-interface.yaml @@ -16,3 +16,4 @@ additionalProperties: # validation should be ignored useBeanValidation: "true" performBeanValidation: "true" + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/springboot-petstore-server-spring-pageable-delegatePattern-without-j8.yaml b/bin/configs/springboot-petstore-server-spring-pageable-delegatePattern-without-j8.yaml index 7716066d45ec..c604536bef9a 100644 --- a/bin/configs/springboot-petstore-server-spring-pageable-delegatePattern-without-j8.yaml +++ b/bin/configs/springboot-petstore-server-spring-pageable-delegatePattern-without-j8.yaml @@ -9,3 +9,4 @@ additionalProperties: documentationProvider: springfox artifactId: springboot-spring-pageable-delegatePattern-without-j8 hideGenerationTimestamp: 'true' + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/springboot-petstore-server-spring-pageable-delegatePattern.yaml b/bin/configs/springboot-petstore-server-spring-pageable-delegatePattern.yaml index 4060de18878f..181ef6b0ec3a 100644 --- a/bin/configs/springboot-petstore-server-spring-pageable-delegatePattern.yaml +++ b/bin/configs/springboot-petstore-server-spring-pageable-delegatePattern.yaml @@ -9,3 +9,4 @@ additionalProperties: artifactId: springboot-spring-pageable-delegatePattern hideGenerationTimestamp: 'true' implicitHeadersRegex: ^Version.* + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/springboot-petstore-server-spring-pageable-without-j8.yaml b/bin/configs/springboot-petstore-server-spring-pageable-without-j8.yaml index bbfb4e853129..fb41eb7983f1 100644 --- a/bin/configs/springboot-petstore-server-spring-pageable-without-j8.yaml +++ b/bin/configs/springboot-petstore-server-spring-pageable-without-j8.yaml @@ -8,3 +8,4 @@ additionalProperties: documentationProvider: springfox artifactId: springboot-spring-pageable-withoutj8 hideGenerationTimestamp: 'true' + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/springboot-petstore-server-spring-pageable.yaml b/bin/configs/springboot-petstore-server-spring-pageable.yaml index 5ba082602992..21d6544561bf 100644 --- a/bin/configs/springboot-petstore-server-spring-pageable.yaml +++ b/bin/configs/springboot-petstore-server-spring-pageable.yaml @@ -8,3 +8,4 @@ additionalProperties: artifactId: springboot-spring-pageable hideGenerationTimestamp: 'true' implicitHeadersRegex: ^Version.* + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/typescript-fetch-validation-attributes.yaml b/bin/configs/typescript-fetch-validation-attributes.yaml index 24625b80cc24..241c443e6d8c 100644 --- a/bin/configs/typescript-fetch-validation-attributes.yaml +++ b/bin/configs/typescript-fetch-validation-attributes.yaml @@ -4,3 +4,4 @@ inputSpec: modules/openapi-generator/src/test/resources/3_0/typescript-fetch/val templateDir: modules/openapi-generator/src/main/resources/typescript-fetch additionalProperties: validationAttributes: true + disallowAdditionalPropertiesIfNotPresent: true From e2805e703a0a4c5373071e04d5105c8d516e507e Mon Sep 17 00:00:00 2001 From: Charles Treatman Date: Thu, 1 May 2025 16:27:49 -0500 Subject: [PATCH 4/7] Regenerate docs --- docs/generators/ada-server.md | 2 +- docs/generators/ada.md | 2 +- docs/generators/android.md | 2 +- docs/generators/apache2.md | 2 +- docs/generators/apex.md | 2 +- docs/generators/asciidoc.md | 2 +- docs/generators/aspnet-fastendpoints.md | 2 +- docs/generators/avro-schema.md | 2 +- docs/generators/bash.md | 2 +- docs/generators/c.md | 2 +- docs/generators/clojure.md | 2 +- docs/generators/cpp-qt-client.md | 2 +- docs/generators/cpp-qt-qhttpengine-server.md | 2 +- docs/generators/cpp-tiny.md | 2 +- docs/generators/cpp-tizen.md | 2 +- docs/generators/cpp-ue4.md | 2 +- docs/generators/crystal.md | 2 +- docs/generators/csharp.md | 2 +- docs/generators/cwiki.md | 2 +- docs/generators/dart-dio.md | 2 +- docs/generators/dart.md | 2 +- docs/generators/dynamic-html.md | 2 +- docs/generators/elixir.md | 2 +- docs/generators/fsharp-functions.md | 2 +- docs/generators/gdscript.md | 2 +- docs/generators/go.md | 2 +- docs/generators/groovy.md | 2 +- docs/generators/haskell-http-client.md | 2 +- docs/generators/haskell-yesod.md | 2 +- docs/generators/haskell.md | 2 +- docs/generators/html.md | 2 +- docs/generators/html2.md | 2 +- docs/generators/java-camel.md | 2 +- docs/generators/java-dubbo.md | 2 +- docs/generators/java-helidon-client.md | 2 +- docs/generators/java-helidon-server.md | 2 +- docs/generators/java-inflector.md | 2 +- docs/generators/java-micronaut-client.md | 2 +- docs/generators/java-micronaut-server.md | 2 +- docs/generators/java-microprofile.md | 2 +- docs/generators/java-msf4j.md | 2 +- docs/generators/java-pkmst.md | 2 +- docs/generators/java-play-framework.md | 2 +- docs/generators/java-undertow-server.md | 2 +- docs/generators/java-vertx-web.md | 2 +- docs/generators/java-vertx.md | 2 +- docs/generators/java-wiremock.md | 2 +- docs/generators/java.md | 2 +- docs/generators/javascript-apollo-deprecated.md | 2 +- docs/generators/javascript-closure-angular.md | 2 +- docs/generators/javascript-flowtyped.md | 2 +- docs/generators/javascript.md | 2 +- docs/generators/jaxrs-cxf-cdi.md | 2 +- docs/generators/jaxrs-cxf-client.md | 2 +- docs/generators/jaxrs-cxf-extended.md | 2 +- docs/generators/jaxrs-cxf.md | 2 +- docs/generators/jaxrs-jersey.md | 2 +- docs/generators/jaxrs-resteasy-eap.md | 2 +- docs/generators/jaxrs-resteasy.md | 2 +- docs/generators/jaxrs-spec.md | 2 +- docs/generators/jmeter.md | 2 +- docs/generators/k6.md | 2 +- docs/generators/markdown.md | 2 +- docs/generators/nim.md | 2 +- docs/generators/nodejs-express-server.md | 2 +- docs/generators/ocaml.md | 2 +- docs/generators/openapi-yaml.md | 2 +- docs/generators/openapi.md | 2 +- docs/generators/php-dt.md | 2 +- docs/generators/php-flight.md | 2 +- docs/generators/php-laravel.md | 2 +- docs/generators/php-lumen.md | 2 +- docs/generators/php-mezzio-ph.md | 2 +- docs/generators/php-nextgen.md | 2 +- docs/generators/php-slim4.md | 2 +- docs/generators/php-symfony.md | 2 +- docs/generators/php.md | 2 +- docs/generators/plantuml.md | 2 +- docs/generators/powershell.md | 2 +- docs/generators/python-aiohttp.md | 2 +- docs/generators/python-blueplanet.md | 2 +- docs/generators/python-fastapi.md | 2 +- docs/generators/python-flask.md | 2 +- docs/generators/python-pydantic-v1.md | 2 +- docs/generators/python.md | 2 +- docs/generators/r.md | 2 +- docs/generators/ruby.md | 2 +- docs/generators/scala-akka-http-server.md | 2 +- docs/generators/scala-akka.md | 2 +- docs/generators/scala-cask.md | 2 +- docs/generators/scala-gatling.md | 2 +- docs/generators/scala-http4s-server.md | 2 +- docs/generators/scala-http4s.md | 2 +- docs/generators/scala-lagom-server-deprecated.md | 2 +- docs/generators/scala-pekko.md | 2 +- docs/generators/scala-play-server.md | 2 +- docs/generators/scala-sttp.md | 2 +- docs/generators/scala-sttp4-jsoniter.md | 2 +- docs/generators/scala-sttp4.md | 2 +- docs/generators/scalatra.md | 2 +- docs/generators/scalaz.md | 2 +- docs/generators/spring.md | 2 +- docs/generators/swift-combine.md | 2 +- docs/generators/swift5.md | 2 +- docs/generators/swift6.md | 2 +- docs/generators/typescript-angular.md | 2 +- docs/generators/typescript-aurelia.md | 2 +- docs/generators/typescript-axios.md | 2 +- docs/generators/typescript-fetch.md | 2 +- docs/generators/typescript-inversify.md | 2 +- docs/generators/typescript-jquery.md | 2 +- docs/generators/typescript-nestjs-server.md | 2 +- docs/generators/typescript-nestjs.md | 2 +- docs/generators/typescript-node.md | 2 +- docs/generators/typescript-redux-query.md | 2 +- docs/generators/typescript-rxjs.md | 2 +- docs/generators/typescript.md | 2 +- docs/generators/wsdl-schema.md | 2 +- docs/generators/xojo-client.md | 2 +- docs/generators/zapier.md | 2 +- 120 files changed, 120 insertions(+), 120 deletions(-) diff --git a/docs/generators/ada-server.md b/docs/generators/ada-server.md index 8762b5e3dbaf..bae8a59c082d 100644 --- a/docs/generators/ada-server.md +++ b/docs/generators/ada-server.md @@ -19,7 +19,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |httpSupport|The name of the HTTP support library. Possible values include 'curl' or 'aws'.| |null| diff --git a/docs/generators/ada.md b/docs/generators/ada.md index 866f60e5c351..86bfb1e3bb6e 100644 --- a/docs/generators/ada.md +++ b/docs/generators/ada.md @@ -19,7 +19,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |httpSupport|The name of the HTTP support library. Possible values include 'curl' or 'aws'.| |null| diff --git a/docs/generators/android.md b/docs/generators/android.md index 44d974431739..08827afe8ae1 100644 --- a/docs/generators/android.md +++ b/docs/generators/android.md @@ -25,7 +25,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |apiPackage|package for generated api classes| |null| |artifactId|artifactId for use in the generated build.gradle and pom.xml| |null| |artifactVersion|artifact version for use in the generated build.gradle and pom.xml| |null| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |groupId|groupId for use in the generated build.gradle and pom.xml| |null| diff --git a/docs/generators/apache2.md b/docs/generators/apache2.md index 29c6859fe3ca..d413e3abed35 100644 --- a/docs/generators/apache2.md +++ b/docs/generators/apache2.md @@ -19,7 +19,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/apex.md b/docs/generators/apex.md index 490be47dfd02..16bee1ab27b6 100644 --- a/docs/generators/apex.md +++ b/docs/generators/apex.md @@ -22,7 +22,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |apiVersion|The Metadata API version number to use for components in this package.| |null| |buildMethod|The build method for this package.| |null| |classPrefix|Prefix for generated classes. Set this to avoid overwriting existing classes in your org.| |null| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/asciidoc.md b/docs/generators/asciidoc.md index 96666aedf42a..8a5965845863 100644 --- a/docs/generators/asciidoc.md +++ b/docs/generators/asciidoc.md @@ -23,7 +23,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |appName|short name of the application| |null| |artifactId|artifactId in generated pom.xml. This also becomes part of the generated library's filename| |null| |artifactVersion|artifact version in generated pom.xml. This also becomes part of the generated library's filename. If not provided, uses the version from the OpenAPI specification file. If that's also not present, uses the default value of the artifactVersion option.| |null| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |groupId|groupId in generated pom.xml| |null| diff --git a/docs/generators/aspnet-fastendpoints.md b/docs/generators/aspnet-fastendpoints.md index 5e7e2f1f65fc..57578ac697e4 100644 --- a/docs/generators/aspnet-fastendpoints.md +++ b/docs/generators/aspnet-fastendpoints.md @@ -20,7 +20,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |apiVersion|The version of the API. Used only if useApiVersioning is true| |1| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/avro-schema.md b/docs/generators/avro-schema.md index 488988699447..b2495176fb96 100644 --- a/docs/generators/avro-schema.md +++ b/docs/generators/avro-schema.md @@ -19,7 +19,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/bash.md b/docs/generators/bash.md index 2975eed1ba0e..a378db61fb1f 100644 --- a/docs/generators/bash.md +++ b/docs/generators/bash.md @@ -22,7 +22,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |apiKeyAuthEnvironmentVariable|Name of environment variable where API key can be defined (e.g. PETSTORE_APIKEY='kjhasdGASDa5asdASD')| |false| |basicAuthEnvironmentVariable|Name of environment variable where username and password can be defined (e.g. PETSTORE_CREDS='username:password')| |null| |curlOptions|Default cURL options| |null| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |generateBashCompletion|Whether to generate the Bash completion script| |false| diff --git a/docs/generators/c.md b/docs/generators/c.md index 22f54ac1b53e..a6b876ab10e2 100644 --- a/docs/generators/c.md +++ b/docs/generators/c.md @@ -19,7 +19,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |hideGenerationTimestamp|Hides the generation timestamp when files are generated.| |true| diff --git a/docs/generators/clojure.md b/docs/generators/clojure.md index f8afb80b8934..b00d39db1422 100644 --- a/docs/generators/clojure.md +++ b/docs/generators/clojure.md @@ -20,7 +20,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |baseNamespace|the base/top namespace (Default: generated from projectName)| |null| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/cpp-qt-client.md b/docs/generators/cpp-qt-client.md index 0cac6f6e4f7d..eb4f4c9ce076 100644 --- a/docs/generators/cpp-qt-client.md +++ b/docs/generators/cpp-qt-client.md @@ -22,7 +22,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |contentCompression|Enable Compressed Content Encoding for requests and responses| |false| |cppNamespace|C++ namespace (convention: name::space::for::api).| |OpenAPI| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/cpp-qt-qhttpengine-server.md b/docs/generators/cpp-qt-qhttpengine-server.md index 185d84f74b75..cba9a22a520f 100644 --- a/docs/generators/cpp-qt-qhttpengine-server.md +++ b/docs/generators/cpp-qt-qhttpengine-server.md @@ -21,7 +21,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |contentCompression|Enable Compressed Content Encoding for requests and responses| |false| |cppNamespace|C++ namespace (convention: name::space::for::api).| |OpenAPI| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/cpp-tiny.md b/docs/generators/cpp-tiny.md index 99102d0697e0..26968a8505b4 100644 --- a/docs/generators/cpp-tiny.md +++ b/docs/generators/cpp-tiny.md @@ -20,7 +20,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |controller|name of microcontroller (e.g esp32 or esp8266)| |esp32| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/cpp-tizen.md b/docs/generators/cpp-tizen.md index f033687c2b39..05e9a72402c4 100644 --- a/docs/generators/cpp-tizen.md +++ b/docs/generators/cpp-tizen.md @@ -19,7 +19,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/cpp-ue4.md b/docs/generators/cpp-ue4.md index bc0cc4b47f4f..a1b0e92c733a 100644 --- a/docs/generators/cpp-ue4.md +++ b/docs/generators/cpp-ue4.md @@ -20,7 +20,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |cppNamespace|C++ namespace (convention: name::space::for::api).| |OpenAPI| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/crystal.md b/docs/generators/crystal.md index b9d588123329..cae47bdb8ceb 100644 --- a/docs/generators/crystal.md +++ b/docs/generators/crystal.md @@ -19,7 +19,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |hideGenerationTimestamp|Hides the generation timestamp when files are generated.| |true| diff --git a/docs/generators/csharp.md b/docs/generators/csharp.md index e42095155728..49b5e5652bd6 100644 --- a/docs/generators/csharp.md +++ b/docs/generators/csharp.md @@ -24,7 +24,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |conditionalSerialization|Serialize only those properties which are initialized by user, accepted values are true or false, default value is false.| |false| |dateFormat|The default Date format (only `generichost` library supports this option).| |yyyy'-'MM'-'dd| |dateTimeFormat|The default DateTime format (only `generichost` library supports this option).| |yyyy'-'MM'-'dd'T'HH':'mm':'ss'.'fffffffK| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |equatable|Overrides Equals and GetHashCode methods.| |false| |hideGenerationTimestamp|Hides the generation timestamp when files are generated.| |true| |interfacePrefix|Prefix interfaces with a community standard or widely accepted prefix.| |I| diff --git a/docs/generators/cwiki.md b/docs/generators/cwiki.md index 01da2a29f3f5..804c7c7561bc 100644 --- a/docs/generators/cwiki.md +++ b/docs/generators/cwiki.md @@ -22,7 +22,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |appName|short name of the application| |null| |artifactId|artifactId in generated pom.xml. This also becomes part of the generated library's filename| |null| |artifactVersion|artifact version in generated pom.xml. This also becomes part of the generated library's filename. If not provided, uses the version from the OpenAPI specification file. If that's also not present, uses the default value of the artifactVersion option.| |null| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |groupId|groupId in generated pom.xml| |null| diff --git a/docs/generators/dart-dio.md b/docs/generators/dart-dio.md index 7e62f92f0782..9525261a070c 100644 --- a/docs/generators/dart-dio.md +++ b/docs/generators/dart-dio.md @@ -20,7 +20,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |dateLibrary|Specify Date library|
**core**
[DEFAULT] Dart core library (DateTime)
**timemachine**
Time Machine is date and time library for Flutter, Web, and Server with support for timezones, calendars, cultures, formatting and parsing.
|core| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |equalityCheckMethod|Specify equality check method. Takes effect only in case if serializationLibrary is json_serializable.|
**default**
[DEFAULT] Built in hash code generation method
**equatable**
Uses equatable library for equality checking
|default| diff --git a/docs/generators/dart.md b/docs/generators/dart.md index 79148a7e4791..6c695ec2cc63 100644 --- a/docs/generators/dart.md +++ b/docs/generators/dart.md @@ -19,7 +19,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/dynamic-html.md b/docs/generators/dynamic-html.md index c202321b816f..c1ac7b054341 100644 --- a/docs/generators/dynamic-html.md +++ b/docs/generators/dynamic-html.md @@ -20,7 +20,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |artifactId|artifactId in generated pom.xml. This also becomes part of the generated library's filename| |null| |artifactVersion|artifact version in generated pom.xml. This also becomes part of the generated library's filename. If not provided, uses the version from the OpenAPI specification file. If that's also not present, uses the default value of the artifactVersion option.| |null| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |groupId|groupId in generated pom.xml| |null| diff --git a/docs/generators/elixir.md b/docs/generators/elixir.md index 9d76b6b09f54..d743eaae6c16 100644 --- a/docs/generators/elixir.md +++ b/docs/generators/elixir.md @@ -19,7 +19,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |invokerPackage|The main namespace to use for all classes. e.g. Yay.Pets| |null| diff --git a/docs/generators/fsharp-functions.md b/docs/generators/fsharp-functions.md index a20382152aab..b3ace10cd90d 100644 --- a/docs/generators/fsharp-functions.md +++ b/docs/generators/fsharp-functions.md @@ -19,7 +19,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/gdscript.md b/docs/generators/gdscript.md index d5a70846ab0b..5f4d36d3b31e 100644 --- a/docs/generators/gdscript.md +++ b/docs/generators/gdscript.md @@ -23,7 +23,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |anticollisionSuffix|Suffix added at the ending of reserved words| || |coreNamePrefix|PascalCase prefix added to all core classes| || |coreNameSuffix|PascalCase suffix added to all core classes| || -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/go.md b/docs/generators/go.md index 328740c461c6..129c5f71e567 100644 --- a/docs/generators/go.md +++ b/docs/generators/go.md @@ -18,7 +18,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |enumClassPrefix|Prefix enum with class name| |false| |generateInterfaces|Generate interfaces for api classes| |false| |generateMarshalJSON|Generate MarshalJSON method| |true| diff --git a/docs/generators/groovy.md b/docs/generators/groovy.md index e2f1314c4bb1..9c82030f8390 100644 --- a/docs/generators/groovy.md +++ b/docs/generators/groovy.md @@ -35,7 +35,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |developerOrganization|developer organization in generated pom.xml| |OpenAPITools.org| |developerOrganizationUrl|developer organization URL in generated pom.xml| |http://openapitools.org| |disableHtmlEscaping|Disable HTML escaping of JSON strings when using gson (needed to avoid problems with byte[] fields)| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |discriminatorCaseSensitive|Whether the discriminator value lookup should be case-sensitive or not. This option only works for Java API client| |true| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumPropertyNaming|Naming convention for enum properties: 'MACRO_CASE', 'legacy' and 'original'| |MACRO_CASE| diff --git a/docs/generators/haskell-http-client.md b/docs/generators/haskell-http-client.md index 5bb4352ec301..ad23d9918b3c 100644 --- a/docs/generators/haskell-http-client.md +++ b/docs/generators/haskell-http-client.md @@ -30,7 +30,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |dateFormat|format string used to parse/render a date| |%Y-%m-%d| |dateTimeFormat|format string used to parse/render a datetime| |null| |dateTimeParseFormat|overrides the format string used to parse a datetime| |null| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |generateEnums|Generate specific datatypes for OpenAPI enums| |true| diff --git a/docs/generators/haskell-yesod.md b/docs/generators/haskell-yesod.md index d3694b12ed50..76b03ae3cf04 100644 --- a/docs/generators/haskell-yesod.md +++ b/docs/generators/haskell-yesod.md @@ -20,7 +20,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |apiModuleName|name of the API module (Default: generated from info.title or "API")| |null| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/haskell.md b/docs/generators/haskell.md index dfada1754f43..b4286ab6bf61 100644 --- a/docs/generators/haskell.md +++ b/docs/generators/haskell.md @@ -20,7 +20,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |apiPackage|package for generated api classes| |null| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/html.md b/docs/generators/html.md index 719041987dcf..743e02055177 100644 --- a/docs/generators/html.md +++ b/docs/generators/html.md @@ -22,7 +22,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |appName|short name of the application| |null| |artifactId|artifactId in generated pom.xml. This also becomes part of the generated library's filename| |null| |artifactVersion|artifact version in generated pom.xml. This also becomes part of the generated library's filename. If not provided, uses the version from the OpenAPI specification file. If that's also not present, uses the default value of the artifactVersion option.| |null| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |groupId|groupId in generated pom.xml| |null| diff --git a/docs/generators/html2.md b/docs/generators/html2.md index f0ffcab1c633..6042c710032b 100644 --- a/docs/generators/html2.md +++ b/docs/generators/html2.md @@ -22,7 +22,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |appName|short name of the application| |null| |artifactId|artifactId in generated pom.xml. This also becomes part of the generated library's filename| |null| |artifactVersion|artifact version in generated pom.xml. This also becomes part of the generated library's filename. If not provided, uses the version from the OpenAPI specification file. If that's also not present, uses the default value of the artifactVersion option.| |null| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |groupId|groupId in generated pom.xml| |null| diff --git a/docs/generators/java-camel.md b/docs/generators/java-camel.md index b50d9b4728c1..e34198158230 100644 --- a/docs/generators/java-camel.md +++ b/docs/generators/java-camel.md @@ -50,7 +50,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |developerOrganization|developer organization in generated pom.xml| |OpenAPITools.org| |developerOrganizationUrl|developer organization URL in generated pom.xml| |http://openapitools.org| |disableHtmlEscaping|Disable HTML escaping of JSON strings when using gson (needed to avoid problems with byte[] fields)| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |discriminatorCaseSensitive|Whether the discriminator value lookup should be case-sensitive or not. This option only works for Java API client| |true| |documentationProvider|Select the OpenAPI documentation provider.|
**none**
Do not publish an OpenAPI specification.
**source**
Publish the original input OpenAPI specification.
**springfox**
Generate an OpenAPI 2 (fka Swagger RESTful API Documentation Specification) specification using SpringFox 2.x. Deprecated (for removal); use springdoc instead.
**springdoc**
Generate an OpenAPI 3 specification using SpringDoc.
|springdoc| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| diff --git a/docs/generators/java-dubbo.md b/docs/generators/java-dubbo.md index fa64f3d35955..d69c521c59d1 100644 --- a/docs/generators/java-dubbo.md +++ b/docs/generators/java-dubbo.md @@ -39,7 +39,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |developerOrganization|developer organization in generated pom.xml| |OpenAPITools.org| |developerOrganizationUrl|developer organization URL in generated pom.xml| |http://openapitools.org| |disableHtmlEscaping|Disable HTML escaping of JSON strings when using gson (needed to avoid problems with byte[] fields)| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |discriminatorCaseSensitive|Whether the discriminator value lookup should be case-sensitive or not. This option only works for Java API client| |true| |dubboVersion|Dubbo version| |3.2.18| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| diff --git a/docs/generators/java-helidon-client.md b/docs/generators/java-helidon-client.md index 5f309c81ce6b..d939564d3f79 100644 --- a/docs/generators/java-helidon-client.md +++ b/docs/generators/java-helidon-client.md @@ -33,7 +33,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |configKey|Config key in @RegisterRestClient. Default to none.| |null| |containerDefaultToNull|Set containers (array, set, map) default to null| |false| |dateLibrary|Option. Date library to use|
**joda**
Joda (for legacy app only)
**legacy**
Legacy java.util.Date
**java8-localdatetime**
Java 8 using LocalDateTime (for legacy app only)
**java8**
Java 8 native JSR310 (preferred for jdk 1.8+)
|java8| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |discriminatorCaseSensitive|Whether the discriminator value lookup should be case-sensitive or not. This option only works for Java API client| |true| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumPropertyNaming|Naming convention for enum properties: 'MACRO_CASE', 'legacy' and 'original'| |MACRO_CASE| diff --git a/docs/generators/java-helidon-server.md b/docs/generators/java-helidon-server.md index b4d8db132743..60d6ce74f6c7 100644 --- a/docs/generators/java-helidon-server.md +++ b/docs/generators/java-helidon-server.md @@ -32,7 +32,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |camelCaseDollarSign|Fix camelCase when starting with $ sign. when true : $Value when false : $value| |false| |containerDefaultToNull|Set containers (array, set, map) default to null| |false| |dateLibrary|Option. Date library to use|
**joda**
Joda (for legacy app only)
**legacy**
Legacy java.util.Date
**java8-localdatetime**
Java 8 using LocalDateTime (for legacy app only)
**java8**
Java 8 native JSR310 (preferred for jdk 1.8+)
|java8| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |discriminatorCaseSensitive|Whether the discriminator value lookup should be case-sensitive or not. This option only works for Java API client| |true| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumPropertyNaming|Naming convention for enum properties: 'MACRO_CASE', 'legacy' and 'original'| |MACRO_CASE| diff --git a/docs/generators/java-inflector.md b/docs/generators/java-inflector.md index 3adfffad38df..3e3908cf0661 100644 --- a/docs/generators/java-inflector.md +++ b/docs/generators/java-inflector.md @@ -37,7 +37,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |developerOrganization|developer organization in generated pom.xml| |OpenAPITools.org| |developerOrganizationUrl|developer organization URL in generated pom.xml| |http://openapitools.org| |disableHtmlEscaping|Disable HTML escaping of JSON strings when using gson (needed to avoid problems with byte[] fields)| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |discriminatorCaseSensitive|Whether the discriminator value lookup should be case-sensitive or not. This option only works for Java API client| |true| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumPropertyNaming|Naming convention for enum properties: 'MACRO_CASE', 'legacy' and 'original'| |MACRO_CASE| diff --git a/docs/generators/java-micronaut-client.md b/docs/generators/java-micronaut-client.md index 37a2d8907ee1..d63e8d87b840 100644 --- a/docs/generators/java-micronaut-client.md +++ b/docs/generators/java-micronaut-client.md @@ -46,7 +46,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |developerOrganization|developer organization in generated pom.xml| |OpenAPITools.org| |developerOrganizationUrl|developer organization URL in generated pom.xml| |http://openapitools.org| |disableHtmlEscaping|Disable HTML escaping of JSON strings when using gson (needed to avoid problems with byte[] fields)| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |discriminatorCaseSensitive|Whether the discriminator value lookup should be case-sensitive or not. This option only works for Java API client| |true| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumPropertyNaming|Naming convention for enum properties: 'MACRO_CASE', 'legacy' and 'original'| |MACRO_CASE| diff --git a/docs/generators/java-micronaut-server.md b/docs/generators/java-micronaut-server.md index 4a21268afbd5..5d3021679cda 100644 --- a/docs/generators/java-micronaut-server.md +++ b/docs/generators/java-micronaut-server.md @@ -41,7 +41,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |developerOrganization|developer organization in generated pom.xml| |OpenAPITools.org| |developerOrganizationUrl|developer organization URL in generated pom.xml| |http://openapitools.org| |disableHtmlEscaping|Disable HTML escaping of JSON strings when using gson (needed to avoid problems with byte[] fields)| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |discriminatorCaseSensitive|Whether the discriminator value lookup should be case-sensitive or not. This option only works for Java API client| |true| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumPropertyNaming|Naming convention for enum properties: 'MACRO_CASE', 'legacy' and 'original'| |MACRO_CASE| diff --git a/docs/generators/java-microprofile.md b/docs/generators/java-microprofile.md index b928fb0f32e3..7ee7b6dc9feb 100644 --- a/docs/generators/java-microprofile.md +++ b/docs/generators/java-microprofile.md @@ -42,7 +42,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |developerOrganization|developer organization in generated pom.xml| |OpenAPITools.org| |developerOrganizationUrl|developer organization URL in generated pom.xml| |http://openapitools.org| |disableHtmlEscaping|Disable HTML escaping of JSON strings when using gson (needed to avoid problems with byte[] fields)| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |discriminatorCaseSensitive|Whether the discriminator value lookup should be case-sensitive or not. This option only works for Java API client| |true| |documentationProvider|Select the OpenAPI documentation provider.|
**none**
Do not publish an OpenAPI specification.
**source**
Publish the original input OpenAPI specification.
|source| |dynamicOperations|Generate operations dynamically at runtime from an OAS| |false| diff --git a/docs/generators/java-msf4j.md b/docs/generators/java-msf4j.md index 7251308c1440..4b3aa30296df 100644 --- a/docs/generators/java-msf4j.md +++ b/docs/generators/java-msf4j.md @@ -37,7 +37,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |developerOrganization|developer organization in generated pom.xml| |OpenAPITools.org| |developerOrganizationUrl|developer organization URL in generated pom.xml| |http://openapitools.org| |disableHtmlEscaping|Disable HTML escaping of JSON strings when using gson (needed to avoid problems with byte[] fields)| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |discriminatorCaseSensitive|Whether the discriminator value lookup should be case-sensitive or not. This option only works for Java API client| |true| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumPropertyNaming|Naming convention for enum properties: 'MACRO_CASE', 'legacy' and 'original'| |MACRO_CASE| diff --git a/docs/generators/java-pkmst.md b/docs/generators/java-pkmst.md index e2299587c5f2..efdce62b7ef0 100644 --- a/docs/generators/java-pkmst.md +++ b/docs/generators/java-pkmst.md @@ -38,7 +38,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |developerOrganization|developer organization in generated pom.xml| |OpenAPITools.org| |developerOrganizationUrl|developer organization URL in generated pom.xml| |http://openapitools.org| |disableHtmlEscaping|Disable HTML escaping of JSON strings when using gson (needed to avoid problems with byte[] fields)| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |discriminatorCaseSensitive|Whether the discriminator value lookup should be case-sensitive or not. This option only works for Java API client| |true| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumPropertyNaming|Naming convention for enum properties: 'MACRO_CASE', 'legacy' and 'original'| |MACRO_CASE| diff --git a/docs/generators/java-play-framework.md b/docs/generators/java-play-framework.md index c5f80ab75d16..ac4ee3ad7d51 100644 --- a/docs/generators/java-play-framework.md +++ b/docs/generators/java-play-framework.md @@ -40,7 +40,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |developerOrganization|developer organization in generated pom.xml| |OpenAPITools.org| |developerOrganizationUrl|developer organization URL in generated pom.xml| |http://openapitools.org| |disableHtmlEscaping|Disable HTML escaping of JSON strings when using gson (needed to avoid problems with byte[] fields)| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |discriminatorCaseSensitive|Whether the discriminator value lookup should be case-sensitive or not. This option only works for Java API client| |true| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumPropertyNaming|Naming convention for enum properties: 'MACRO_CASE', 'legacy' and 'original'| |MACRO_CASE| diff --git a/docs/generators/java-undertow-server.md b/docs/generators/java-undertow-server.md index c258e9aa5df4..68d58b60bb99 100644 --- a/docs/generators/java-undertow-server.md +++ b/docs/generators/java-undertow-server.md @@ -37,7 +37,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |developerOrganization|developer organization in generated pom.xml| |OpenAPITools.org| |developerOrganizationUrl|developer organization URL in generated pom.xml| |http://openapitools.org| |disableHtmlEscaping|Disable HTML escaping of JSON strings when using gson (needed to avoid problems with byte[] fields)| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |discriminatorCaseSensitive|Whether the discriminator value lookup should be case-sensitive or not. This option only works for Java API client| |true| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumPropertyNaming|Naming convention for enum properties: 'MACRO_CASE', 'legacy' and 'original'| |MACRO_CASE| diff --git a/docs/generators/java-vertx-web.md b/docs/generators/java-vertx-web.md index 473c40d1af7d..906e83758a18 100644 --- a/docs/generators/java-vertx-web.md +++ b/docs/generators/java-vertx-web.md @@ -37,7 +37,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |developerOrganization|developer organization in generated pom.xml| |OpenAPITools.org| |developerOrganizationUrl|developer organization URL in generated pom.xml| |http://openapitools.org| |disableHtmlEscaping|Disable HTML escaping of JSON strings when using gson (needed to avoid problems with byte[] fields)| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |discriminatorCaseSensitive|Whether the discriminator value lookup should be case-sensitive or not. This option only works for Java API client| |true| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumPropertyNaming|Naming convention for enum properties: 'MACRO_CASE', 'legacy' and 'original'| |MACRO_CASE| diff --git a/docs/generators/java-vertx.md b/docs/generators/java-vertx.md index dd2722079b63..3fd7711b89d9 100644 --- a/docs/generators/java-vertx.md +++ b/docs/generators/java-vertx.md @@ -37,7 +37,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |developerOrganization|developer organization in generated pom.xml| |OpenAPITools.org| |developerOrganizationUrl|developer organization URL in generated pom.xml| |http://openapitools.org| |disableHtmlEscaping|Disable HTML escaping of JSON strings when using gson (needed to avoid problems with byte[] fields)| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |discriminatorCaseSensitive|Whether the discriminator value lookup should be case-sensitive or not. This option only works for Java API client| |true| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumPropertyNaming|Naming convention for enum properties: 'MACRO_CASE', 'legacy' and 'original'| |MACRO_CASE| diff --git a/docs/generators/java-wiremock.md b/docs/generators/java-wiremock.md index 39b0a40d6edf..b5f291774494 100644 --- a/docs/generators/java-wiremock.md +++ b/docs/generators/java-wiremock.md @@ -37,7 +37,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |developerOrganization|developer organization in generated pom.xml| |OpenAPITools.org| |developerOrganizationUrl|developer organization URL in generated pom.xml| |http://openapitools.org| |disableHtmlEscaping|Disable HTML escaping of JSON strings when using gson (needed to avoid problems with byte[] fields)| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |discriminatorCaseSensitive|Whether the discriminator value lookup should be case-sensitive or not. This option only works for Java API client| |true| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumPropertyNaming|Naming convention for enum properties: 'MACRO_CASE', 'legacy' and 'original'| |MACRO_CASE| diff --git a/docs/generators/java.md b/docs/generators/java.md index 7c9ffca4760d..8a0f83bd13cd 100644 --- a/docs/generators/java.md +++ b/docs/generators/java.md @@ -42,7 +42,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |developerOrganization|developer organization in generated pom.xml| |OpenAPITools.org| |developerOrganizationUrl|developer organization URL in generated pom.xml| |http://openapitools.org| |disableHtmlEscaping|Disable HTML escaping of JSON strings when using gson (needed to avoid problems with byte[] fields)| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |discriminatorCaseSensitive|Whether the discriminator value lookup should be case-sensitive or not. This option only works for Java API client| |true| |documentationProvider|Select the OpenAPI documentation provider.|
**none**
Do not publish an OpenAPI specification.
**source**
Publish the original input OpenAPI specification.
|source| |dynamicOperations|Generate operations dynamically at runtime from an OAS| |false| diff --git a/docs/generators/javascript-apollo-deprecated.md b/docs/generators/javascript-apollo-deprecated.md index c70d3e81b584..81088dd7743c 100644 --- a/docs/generators/javascript-apollo-deprecated.md +++ b/docs/generators/javascript-apollo-deprecated.md @@ -20,7 +20,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |apiPackage|package for generated api classes| |null| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |emitJSDoc|generate JSDoc comments| |true| |emitModelMethods|generate getters and setters for model properties| |false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| diff --git a/docs/generators/javascript-closure-angular.md b/docs/generators/javascript-closure-angular.md index 860b2f523f53..7c77ea12d4fb 100644 --- a/docs/generators/javascript-closure-angular.md +++ b/docs/generators/javascript-closure-angular.md @@ -19,7 +19,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |hideGenerationTimestamp|Hides the generation timestamp when files are generated.| |true| diff --git a/docs/generators/javascript-flowtyped.md b/docs/generators/javascript-flowtyped.md index 80c2ba07d753..26898299e6f1 100644 --- a/docs/generators/javascript-flowtyped.md +++ b/docs/generators/javascript-flowtyped.md @@ -19,7 +19,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumNameSuffix|Suffix that will be appended to all enum names.| |Enum| |enumPropertyNaming|Naming convention for enum properties: 'camelCase', 'PascalCase', 'snake_case', 'UPPERCASE', and 'original'| |PascalCase| diff --git a/docs/generators/javascript.md b/docs/generators/javascript.md index 6921b32ca093..94c3b0742f60 100644 --- a/docs/generators/javascript.md +++ b/docs/generators/javascript.md @@ -20,7 +20,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |apiPackage|package for generated api classes| |null| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |emitJSDoc|generate JSDoc comments| |true| |emitModelMethods|generate getters and setters for model properties| |false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| diff --git a/docs/generators/jaxrs-cxf-cdi.md b/docs/generators/jaxrs-cxf-cdi.md index 02f6b177827e..a0957847e399 100644 --- a/docs/generators/jaxrs-cxf-cdi.md +++ b/docs/generators/jaxrs-cxf-cdi.md @@ -37,7 +37,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |developerOrganization|developer organization in generated pom.xml| |OpenAPITools.org| |developerOrganizationUrl|developer organization URL in generated pom.xml| |http://openapitools.org| |disableHtmlEscaping|Disable HTML escaping of JSON strings when using gson (needed to avoid problems with byte[] fields)| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |discriminatorCaseSensitive|Whether the discriminator value lookup should be case-sensitive or not. This option only works for Java API client| |true| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumPropertyNaming|Naming convention for enum properties: 'MACRO_CASE', 'legacy' and 'original'| |MACRO_CASE| diff --git a/docs/generators/jaxrs-cxf-client.md b/docs/generators/jaxrs-cxf-client.md index e735d8f0ef4b..5443481a401c 100644 --- a/docs/generators/jaxrs-cxf-client.md +++ b/docs/generators/jaxrs-cxf-client.md @@ -38,7 +38,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |developerOrganization|developer organization in generated pom.xml| |OpenAPITools.org| |developerOrganizationUrl|developer organization URL in generated pom.xml| |http://openapitools.org| |disableHtmlEscaping|Disable HTML escaping of JSON strings when using gson (needed to avoid problems with byte[] fields)| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |discriminatorCaseSensitive|Whether the discriminator value lookup should be case-sensitive or not. This option only works for Java API client| |true| |documentationProvider|Select the OpenAPI documentation provider.|
**none**
Do not publish an OpenAPI specification.
**swagger1**
Generate an OpenAPI 2 (fka Swagger RESTful API Documentation Specification) specification using Swagger-Core 1.x.
**swagger2**
Generate an OpenAPI 3 specification using Swagger-Core 2.x.
|swagger1| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| diff --git a/docs/generators/jaxrs-cxf-extended.md b/docs/generators/jaxrs-cxf-extended.md index aeb82d2dce55..baab30a93f76 100644 --- a/docs/generators/jaxrs-cxf-extended.md +++ b/docs/generators/jaxrs-cxf-extended.md @@ -39,7 +39,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |developerOrganization|developer organization in generated pom.xml| |OpenAPITools.org| |developerOrganizationUrl|developer organization URL in generated pom.xml| |http://openapitools.org| |disableHtmlEscaping|Disable HTML escaping of JSON strings when using gson (needed to avoid problems with byte[] fields)| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |discriminatorCaseSensitive|Whether the discriminator value lookup should be case-sensitive or not. This option only works for Java API client| |true| |documentationProvider|Select the OpenAPI documentation provider.|
**none**
Do not publish an OpenAPI specification.
**swagger1**
Generate an OpenAPI 2 (fka Swagger RESTful API Documentation Specification) specification using Swagger-Core 1.x.
**swagger2**
Generate an OpenAPI 3 specification using Swagger-Core 2.x.
|swagger1| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| diff --git a/docs/generators/jaxrs-cxf.md b/docs/generators/jaxrs-cxf.md index b9b120e2f8d9..dd5d34d6d577 100644 --- a/docs/generators/jaxrs-cxf.md +++ b/docs/generators/jaxrs-cxf.md @@ -39,7 +39,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |developerOrganization|developer organization in generated pom.xml| |OpenAPITools.org| |developerOrganizationUrl|developer organization URL in generated pom.xml| |http://openapitools.org| |disableHtmlEscaping|Disable HTML escaping of JSON strings when using gson (needed to avoid problems with byte[] fields)| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |discriminatorCaseSensitive|Whether the discriminator value lookup should be case-sensitive or not. This option only works for Java API client| |true| |documentationProvider|Select the OpenAPI documentation provider.|
**none**
Do not publish an OpenAPI specification.
**swagger1**
Generate an OpenAPI 2 (fka Swagger RESTful API Documentation Specification) specification using Swagger-Core 1.x.
**swagger2**
Generate an OpenAPI 3 specification using Swagger-Core 2.x.
|swagger1| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| diff --git a/docs/generators/jaxrs-jersey.md b/docs/generators/jaxrs-jersey.md index a5d3e9a3c51a..ae41781ea2a1 100644 --- a/docs/generators/jaxrs-jersey.md +++ b/docs/generators/jaxrs-jersey.md @@ -37,7 +37,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |developerOrganization|developer organization in generated pom.xml| |OpenAPITools.org| |developerOrganizationUrl|developer organization URL in generated pom.xml| |http://openapitools.org| |disableHtmlEscaping|Disable HTML escaping of JSON strings when using gson (needed to avoid problems with byte[] fields)| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |discriminatorCaseSensitive|Whether the discriminator value lookup should be case-sensitive or not. This option only works for Java API client| |true| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumPropertyNaming|Naming convention for enum properties: 'MACRO_CASE', 'legacy' and 'original'| |MACRO_CASE| diff --git a/docs/generators/jaxrs-resteasy-eap.md b/docs/generators/jaxrs-resteasy-eap.md index 85a3ea082300..cc49239159cd 100644 --- a/docs/generators/jaxrs-resteasy-eap.md +++ b/docs/generators/jaxrs-resteasy-eap.md @@ -37,7 +37,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |developerOrganization|developer organization in generated pom.xml| |OpenAPITools.org| |developerOrganizationUrl|developer organization URL in generated pom.xml| |http://openapitools.org| |disableHtmlEscaping|Disable HTML escaping of JSON strings when using gson (needed to avoid problems with byte[] fields)| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |discriminatorCaseSensitive|Whether the discriminator value lookup should be case-sensitive or not. This option only works for Java API client| |true| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumPropertyNaming|Naming convention for enum properties: 'MACRO_CASE', 'legacy' and 'original'| |MACRO_CASE| diff --git a/docs/generators/jaxrs-resteasy.md b/docs/generators/jaxrs-resteasy.md index c03831051659..456ad1ea83c7 100644 --- a/docs/generators/jaxrs-resteasy.md +++ b/docs/generators/jaxrs-resteasy.md @@ -37,7 +37,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |developerOrganization|developer organization in generated pom.xml| |OpenAPITools.org| |developerOrganizationUrl|developer organization URL in generated pom.xml| |http://openapitools.org| |disableHtmlEscaping|Disable HTML escaping of JSON strings when using gson (needed to avoid problems with byte[] fields)| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |discriminatorCaseSensitive|Whether the discriminator value lookup should be case-sensitive or not. This option only works for Java API client| |true| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumPropertyNaming|Naming convention for enum properties: 'MACRO_CASE', 'legacy' and 'original'| |MACRO_CASE| diff --git a/docs/generators/jaxrs-spec.md b/docs/generators/jaxrs-spec.md index 03c2d043bf78..a756ce4e6fc1 100644 --- a/docs/generators/jaxrs-spec.md +++ b/docs/generators/jaxrs-spec.md @@ -37,7 +37,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |developerOrganization|developer organization in generated pom.xml| |OpenAPITools.org| |developerOrganizationUrl|developer organization URL in generated pom.xml| |http://openapitools.org| |disableHtmlEscaping|Disable HTML escaping of JSON strings when using gson (needed to avoid problems with byte[] fields)| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |discriminatorCaseSensitive|Whether the discriminator value lookup should be case-sensitive or not. This option only works for Java API client| |true| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumPropertyNaming|Naming convention for enum properties: 'MACRO_CASE', 'legacy' and 'original'| |MACRO_CASE| diff --git a/docs/generators/jmeter.md b/docs/generators/jmeter.md index 085b94493518..41a1724c0d29 100644 --- a/docs/generators/jmeter.md +++ b/docs/generators/jmeter.md @@ -19,7 +19,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/k6.md b/docs/generators/k6.md index a8c4932adb8c..af7087df1913 100644 --- a/docs/generators/k6.md +++ b/docs/generators/k6.md @@ -19,7 +19,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/markdown.md b/docs/generators/markdown.md index 7572bca67301..5a0802033c22 100644 --- a/docs/generators/markdown.md +++ b/docs/generators/markdown.md @@ -18,7 +18,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/nim.md b/docs/generators/nim.md index d61882b2bc94..04cdb351e444 100644 --- a/docs/generators/nim.md +++ b/docs/generators/nim.md @@ -19,7 +19,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/nodejs-express-server.md b/docs/generators/nodejs-express-server.md index d766f4c8702a..919f0cc0f3c7 100644 --- a/docs/generators/nodejs-express-server.md +++ b/docs/generators/nodejs-express-server.md @@ -19,7 +19,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/ocaml.md b/docs/generators/ocaml.md index 9f98b06ac073..8cc3cbbb0eb5 100644 --- a/docs/generators/ocaml.md +++ b/docs/generators/ocaml.md @@ -19,7 +19,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/openapi-yaml.md b/docs/generators/openapi-yaml.md index 22566b22a045..a907ace51805 100644 --- a/docs/generators/openapi-yaml.md +++ b/docs/generators/openapi-yaml.md @@ -18,7 +18,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/openapi.md b/docs/generators/openapi.md index aea32dad388c..8c3446a94b65 100644 --- a/docs/generators/openapi.md +++ b/docs/generators/openapi.md @@ -18,7 +18,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/php-dt.md b/docs/generators/php-dt.md index 67e83ce4c8a7..8dda204d9508 100644 --- a/docs/generators/php-dt.md +++ b/docs/generators/php-dt.md @@ -25,7 +25,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |composerPackageName|The name to use in the composer package name field. e.g. `vendor/project` (must be lowercase and consist of words separated by `-`, `.` or `_`).| |null| |developerOrganization|developer organization in generated pom.xml| |null| |developerOrganizationUrl|developer organization URL in generated pom.xml| |null| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |invokerPackage|The main namespace to use for all classes. e.g. Yay\Pets| |null| diff --git a/docs/generators/php-flight.md b/docs/generators/php-flight.md index fed502b1d1db..23bdc376c261 100644 --- a/docs/generators/php-flight.md +++ b/docs/generators/php-flight.md @@ -25,7 +25,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |composerPackageName|The name to use in the composer package name field. e.g. `vendor/project` (must be lowercase and consist of words separated by `-`, `.` or `_`).| |null| |developerOrganization|developer organization in generated pom.xml| |null| |developerOrganizationUrl|developer organization URL in generated pom.xml| |null| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |hideGenerationTimestamp|Hides the generation timestamp when files are generated.| |true| diff --git a/docs/generators/php-laravel.md b/docs/generators/php-laravel.md index 52937aef3fef..d755c32a1cd9 100644 --- a/docs/generators/php-laravel.md +++ b/docs/generators/php-laravel.md @@ -26,7 +26,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |composerPackageName|The name to use in the composer package name field. e.g. `vendor/project` (must be lowercase and consist of words separated by `-`, `.` or `_`).| |null| |developerOrganization|developer organization in generated pom.xml| |null| |developerOrganizationUrl|developer organization URL in generated pom.xml| |null| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |invokerPackage|The main namespace to use for all classes. e.g. Yay\Pets| |null| diff --git a/docs/generators/php-lumen.md b/docs/generators/php-lumen.md index 5c54efc5701b..2aecbf0a48ca 100644 --- a/docs/generators/php-lumen.md +++ b/docs/generators/php-lumen.md @@ -25,7 +25,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |composerPackageName|The name to use in the composer package name field. e.g. `vendor/project` (must be lowercase and consist of words separated by `-`, `.` or `_`).| |null| |developerOrganization|developer organization in generated pom.xml| |null| |developerOrganizationUrl|developer organization URL in generated pom.xml| |null| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |invokerPackage|The main namespace to use for all classes. e.g. Yay\Pets| |null| diff --git a/docs/generators/php-mezzio-ph.md b/docs/generators/php-mezzio-ph.md index 2d2bc470d073..b05d1f1c8016 100644 --- a/docs/generators/php-mezzio-ph.md +++ b/docs/generators/php-mezzio-ph.md @@ -25,7 +25,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |composerPackageName|The name to use in the composer package name field. e.g. `vendor/project` (must be lowercase and consist of words separated by `-`, `.` or `_`).| |null| |developerOrganization|developer organization in generated pom.xml| |null| |developerOrganizationUrl|developer organization URL in generated pom.xml| |null| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |invokerPackage|The main namespace to use for all classes. e.g. Yay\Pets| |null| diff --git a/docs/generators/php-nextgen.md b/docs/generators/php-nextgen.md index 339f665da0a8..bbc6f9938afb 100644 --- a/docs/generators/php-nextgen.md +++ b/docs/generators/php-nextgen.md @@ -25,7 +25,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |composerPackageName|The name to use in the composer package name field. e.g. `vendor/project` (must be lowercase and consist of words separated by `-`, `.` or `_`).| |null| |developerOrganization|developer organization in generated pom.xml| |null| |developerOrganizationUrl|developer organization URL in generated pom.xml| |null| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |hideGenerationTimestamp|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |true| diff --git a/docs/generators/php-slim4.md b/docs/generators/php-slim4.md index 5062d3d75475..112f3e0ef93e 100644 --- a/docs/generators/php-slim4.md +++ b/docs/generators/php-slim4.md @@ -25,7 +25,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |composerPackageName|The name to use in the composer package name field. e.g. `vendor/project` (must be lowercase and consist of words separated by `-`, `.` or `_`).| |null| |developerOrganization|developer organization in generated pom.xml| |null| |developerOrganizationUrl|developer organization URL in generated pom.xml| |null| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |invokerPackage|The main namespace to use for all classes. e.g. Yay\Pets| |null| diff --git a/docs/generators/php-symfony.md b/docs/generators/php-symfony.md index a516a3fac4e5..8d366ee3a3e5 100644 --- a/docs/generators/php-symfony.md +++ b/docs/generators/php-symfony.md @@ -29,7 +29,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |composerVendorName|The vendor name used in the composer package name. The template uses {{composerVendorName}}/{{composerProjectName}} for the composer package name. e.g. yaypets| |null| |developerOrganization|developer organization in generated pom.xml| |null| |developerOrganizationUrl|developer organization URL in generated pom.xml| |null| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |hideGenerationTimestamp|Hides the generation timestamp when files are generated.| |true| diff --git a/docs/generators/php.md b/docs/generators/php.md index d245377279ee..fe887a9d61a0 100644 --- a/docs/generators/php.md +++ b/docs/generators/php.md @@ -25,7 +25,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |composerPackageName|The name to use in the composer package name field. e.g. `vendor/project` (must be lowercase and consist of words separated by `-`, `.` or `_`).| |null| |developerOrganization|developer organization in generated pom.xml| |null| |developerOrganizationUrl|developer organization URL in generated pom.xml| |null| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |hideGenerationTimestamp|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |true| diff --git a/docs/generators/plantuml.md b/docs/generators/plantuml.md index 2149de62f1ef..9d904f9e2632 100644 --- a/docs/generators/plantuml.md +++ b/docs/generators/plantuml.md @@ -18,7 +18,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/powershell.md b/docs/generators/powershell.md index 025c1e10854f..f51f37fe33e6 100644 --- a/docs/generators/powershell.md +++ b/docs/generators/powershell.md @@ -20,7 +20,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | ------ | ----------- | ------ | ------- | |apiNamePrefix|Prefix that will be appended to all PS objects. Default: empty string. e.g. Pet => PSPet.| |null| |commonVerbs|PS common verb mappings. e.g. Delete=Remove:Patch=Update to map Delete with Remove and Patch with Update accordingly.| |null| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |discardReadOnly|Set discardReadonly to true to generate the Initialize cmdlet without readonly parameters| |null| |iconUri|A URL to an icon representing the generated PowerShell module| |null| |licenseUri|A URL to the license for the generated PowerShell module| |null| diff --git a/docs/generators/python-aiohttp.md b/docs/generators/python-aiohttp.md index 22f61793ba8e..037c76c60386 100644 --- a/docs/generators/python-aiohttp.md +++ b/docs/generators/python-aiohttp.md @@ -22,7 +22,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |controllerPackage|controller package| |controllers| |defaultController|default controller| |default_controller| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |featureCORS|use flask-cors for handling CORS requests| |false| diff --git a/docs/generators/python-blueplanet.md b/docs/generators/python-blueplanet.md index 50c0aa7f3b84..717c36168f12 100644 --- a/docs/generators/python-blueplanet.md +++ b/docs/generators/python-blueplanet.md @@ -22,7 +22,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |controllerPackage|controller package| |controllers| |defaultController|default controller| |default_controller| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |featureCORS|use flask-cors for handling CORS requests| |false| diff --git a/docs/generators/python-fastapi.md b/docs/generators/python-fastapi.md index 5a87a2fcee28..500d5d29af4e 100644 --- a/docs/generators/python-fastapi.md +++ b/docs/generators/python-fastapi.md @@ -20,7 +20,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |fastapiImplementationPackage|python package name for the implementation code (convention: snake_case).| |impl| diff --git a/docs/generators/python-flask.md b/docs/generators/python-flask.md index 0f8e85f4f031..7fb148292224 100644 --- a/docs/generators/python-flask.md +++ b/docs/generators/python-flask.md @@ -22,7 +22,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |controllerPackage|controller package| |controllers| |defaultController|default controller| |default_controller| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |featureCORS|use flask-cors for handling CORS requests| |false| diff --git a/docs/generators/python-pydantic-v1.md b/docs/generators/python-pydantic-v1.md index 0d8b836a7b29..ea766cd1e982 100644 --- a/docs/generators/python-pydantic-v1.md +++ b/docs/generators/python-pydantic-v1.md @@ -21,7 +21,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | ------ | ----------- | ------ | ------- | |dateFormat|date format for query parameters| |%Y-%m-%d| |datetimeFormat|datetime format for query parameters| |%Y-%m-%dT%H:%M:%S%z| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |generateSourceCodeOnly|Specifies that only a library source code is to be generated.| |false| |hideGenerationTimestamp|Hides the generation timestamp when files are generated.| |true| |library|library template (sub-template) to use: asyncio, tornado (deprecated), urllib3| |urllib3| diff --git a/docs/generators/python.md b/docs/generators/python.md index e0706592cdff..7b4fe9da77cc 100644 --- a/docs/generators/python.md +++ b/docs/generators/python.md @@ -21,7 +21,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | ------ | ----------- | ------ | ------- | |dateFormat|date format for query parameters| |%Y-%m-%d| |datetimeFormat|datetime format for query parameters| |%Y-%m-%dT%H:%M:%S%z| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |generateSourceCodeOnly|Specifies that only a library source code is to be generated.| |false| |hideGenerationTimestamp|Hides the generation timestamp when files are generated.| |true| |lazyImports|Enable lazy imports.| |false| diff --git a/docs/generators/r.md b/docs/generators/r.md index 4e7f0d2e4f9c..b3faea9553cf 100644 --- a/docs/generators/r.md +++ b/docs/generators/r.md @@ -18,7 +18,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |errorObjectType|Error object type.| |null| |exceptionPackage|Specify the exception handling package|
**default**
Use stop() for raising exceptions.
**rlang**
Use rlang package for exceptions.
|default| |generateWrapper|Generate a wrapper class (single point of access) for the R client. This option only works with `httr2` library.| |false| diff --git a/docs/generators/ruby.md b/docs/generators/ruby.md index e643257b13e1..d8de091f7e6b 100644 --- a/docs/generators/ruby.md +++ b/docs/generators/ruby.md @@ -19,7 +19,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |gemAuthor|gem author (only one is supported).| |OpenAPI-Generator| diff --git a/docs/generators/scala-akka-http-server.md b/docs/generators/scala-akka-http-server.md index 4dfa451cb311..fed99976383f 100644 --- a/docs/generators/scala-akka-http-server.md +++ b/docs/generators/scala-akka-http-server.md @@ -25,7 +25,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |artifactVersion|artifact version in generated pom.xml. This also becomes part of the generated library's filename| |1.0.0| |asManagedSources|Resulting files cab be used as managed resources. No build files or default controllers will be generated| |false| |dateLibrary|Option. Date library to use|
**joda**
Joda (for legacy app)
**java8**
Java 8 native JSR310 (preferred for JDK 1.8+)
|java8| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |groupId|groupId in generated pom.xml| |org.openapitools| diff --git a/docs/generators/scala-akka.md b/docs/generators/scala-akka.md index 7b9cf9267b58..712962681dbe 100644 --- a/docs/generators/scala-akka.md +++ b/docs/generators/scala-akka.md @@ -21,7 +21,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |apiPackage|package for generated api classes| |null| |dateLibrary|Option. Date library to use|
**joda**
Joda (for legacy app)
**java8**
Java 8 native JSR310 (preferred for JDK 1.8+)
|java8| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/scala-cask.md b/docs/generators/scala-cask.md index 802870eef7b5..72018ddb3399 100644 --- a/docs/generators/scala-cask.md +++ b/docs/generators/scala-cask.md @@ -23,7 +23,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |artifactId|artifactId in generated pom.xml. This also becomes part of the generated library's filename| |null| |artifactVersion|artifact version in generated pom.xml. This also becomes part of the generated library's filename. If not provided, uses the version from the OpenAPI specification file. If that's also not present, uses the default value of the artifactVersion option.| |null| |dateLibrary|Option. Date library to use|
**joda**
Joda (for legacy app)
**java8**
Java 8 native JSR310 (preferred for JDK 1.8+)
|java8| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |gitRepoId|Git repo ID, e.g. openapi-generator.| |null| diff --git a/docs/generators/scala-gatling.md b/docs/generators/scala-gatling.md index 903f6149bbc0..31da7065f8e2 100644 --- a/docs/generators/scala-gatling.md +++ b/docs/generators/scala-gatling.md @@ -21,7 +21,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |apiPackage|package for generated api classes| |null| |dateLibrary|Option. Date library to use|
**joda**
Joda (for legacy app)
**java8**
Java 8 native JSR310 (preferred for JDK 1.8+)
|java8| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/scala-http4s-server.md b/docs/generators/scala-http4s-server.md index 9031c8ef8948..76de72d19080 100644 --- a/docs/generators/scala-http4s-server.md +++ b/docs/generators/scala-http4s-server.md @@ -19,7 +19,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |excludeSbt|exclude sbt from generation| |null| diff --git a/docs/generators/scala-http4s.md b/docs/generators/scala-http4s.md index 52abc4fa6123..0d48046433c7 100644 --- a/docs/generators/scala-http4s.md +++ b/docs/generators/scala-http4s.md @@ -21,7 +21,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |apiPackage|package for generated api classes| |null| |dateLibrary|Option. Date library to use|
**joda**
Joda (for legacy app)
**java8**
Java 8 native JSR310 (preferred for JDK 1.8+)
|java8| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/scala-lagom-server-deprecated.md b/docs/generators/scala-lagom-server-deprecated.md index f100a8825fa2..fa0f42136f79 100644 --- a/docs/generators/scala-lagom-server-deprecated.md +++ b/docs/generators/scala-lagom-server-deprecated.md @@ -21,7 +21,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |apiPackage|package for generated api classes| |null| |dateLibrary|Option. Date library to use|
**joda**
Joda (for legacy app)
**java8**
Java 8 native JSR310 (preferred for JDK 1.8+)
|java8| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/scala-pekko.md b/docs/generators/scala-pekko.md index ebc33bb69870..201e17f13856 100644 --- a/docs/generators/scala-pekko.md +++ b/docs/generators/scala-pekko.md @@ -21,7 +21,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |apiPackage|package for generated api classes| |null| |dateLibrary|Option. Date library to use|
**joda**
Joda (for legacy app)
**java8**
Java 8 native JSR310 (preferred for JDK 1.8+)
|java8| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/scala-play-server.md b/docs/generators/scala-play-server.md index cc632ff4d726..48328d7fc4ec 100644 --- a/docs/generators/scala-play-server.md +++ b/docs/generators/scala-play-server.md @@ -21,7 +21,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |apiPackage|package for generated api classes| |null| |basePackage|Base package in which supporting classes are generated.| |org.openapitools| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |generateCustomExceptions|If set, generates custom exception types.| |true| diff --git a/docs/generators/scala-sttp.md b/docs/generators/scala-sttp.md index 798740d25668..d050d8f180df 100644 --- a/docs/generators/scala-sttp.md +++ b/docs/generators/scala-sttp.md @@ -22,7 +22,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |apiPackage|package for generated api classes| |null| |circeVersion|The version of circe library| |0.14.1| |dateLibrary|Option. Date library to use|
**joda**
Joda (for legacy app)
**java8**
Java 8 native JSR310 (preferred for JDK 1.8+)
|java8| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |jodaTimeVersion|The version of joda-time library| |2.10.13| diff --git a/docs/generators/scala-sttp4-jsoniter.md b/docs/generators/scala-sttp4-jsoniter.md index 91e963d47550..2761389d465d 100644 --- a/docs/generators/scala-sttp4-jsoniter.md +++ b/docs/generators/scala-sttp4-jsoniter.md @@ -20,7 +20,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |apiPackage|package for generated api classes| |null| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |jsoniterVersion|The version of jsoniter-scala library| |2.31.1| diff --git a/docs/generators/scala-sttp4.md b/docs/generators/scala-sttp4.md index 2ff0143b0eda..72b5306e5241 100644 --- a/docs/generators/scala-sttp4.md +++ b/docs/generators/scala-sttp4.md @@ -21,7 +21,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |apiPackage|package for generated api classes| |null| |dateLibrary|Option. Date library to use|
**joda**
Joda (for legacy app)
**java8**
Java 8 native JSR310 (preferred for JDK 1.8+)
|java8| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |jodaTimeVersion|The version of joda-time library| |2.10.13| diff --git a/docs/generators/scalatra.md b/docs/generators/scalatra.md index 6621eaae2f4d..ff553c2a91bd 100644 --- a/docs/generators/scalatra.md +++ b/docs/generators/scalatra.md @@ -21,7 +21,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |apiPackage|package for generated api classes| |null| |dateLibrary|Option. Date library to use|
**joda**
Joda (for legacy app)
**java8**
Java 8 native JSR310 (preferred for JDK 1.8+)
|java8| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/scalaz.md b/docs/generators/scalaz.md index 627af71ef68d..e021d8d7e5f8 100644 --- a/docs/generators/scalaz.md +++ b/docs/generators/scalaz.md @@ -21,7 +21,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |apiPackage|package for generated api classes| |null| |dateLibrary|Option. Date library to use|
**joda**
Joda (for legacy app)
**java8**
Java 8 native JSR310 (preferred for JDK 1.8+)
|java8| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/spring.md b/docs/generators/spring.md index 2af0fe826a3e..0f5f447f9316 100644 --- a/docs/generators/spring.md +++ b/docs/generators/spring.md @@ -43,7 +43,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |developerOrganization|developer organization in generated pom.xml| |OpenAPITools.org| |developerOrganizationUrl|developer organization URL in generated pom.xml| |http://openapitools.org| |disableHtmlEscaping|Disable HTML escaping of JSON strings when using gson (needed to avoid problems with byte[] fields)| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |discriminatorCaseSensitive|Whether the discriminator value lookup should be case-sensitive or not. This option only works for Java API client| |true| |documentationProvider|Select the OpenAPI documentation provider.|
**none**
Do not publish an OpenAPI specification.
**source**
Publish the original input OpenAPI specification.
**springfox**
Generate an OpenAPI 2 (fka Swagger RESTful API Documentation Specification) specification using SpringFox 2.x. Deprecated (for removal); use springdoc instead.
**springdoc**
Generate an OpenAPI 3 specification using SpringDoc.
|springdoc| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| diff --git a/docs/generators/swift-combine.md b/docs/generators/swift-combine.md index d660a47af3ba..c1e0f4f3127e 100644 --- a/docs/generators/swift-combine.md +++ b/docs/generators/swift-combine.md @@ -20,7 +20,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |apiNamePrefix|Prefix that will be appended to all API names ('tags'). Default: empty string. e.g. Pet => Pet.| |null| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/swift5.md b/docs/generators/swift5.md index 9d565bf5993f..510be3a6f9c1 100644 --- a/docs/generators/swift5.md +++ b/docs/generators/swift5.md @@ -20,7 +20,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |apiNamePrefix|Prefix that will be appended to all API names ('tags'). Default: empty string. e.g. Pet => Pet.| |null| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |generateModelAdditionalProperties|Generate model additional properties (default: true)| |true| diff --git a/docs/generators/swift6.md b/docs/generators/swift6.md index dfdf2eab373c..eaaeafab6313 100644 --- a/docs/generators/swift6.md +++ b/docs/generators/swift6.md @@ -22,7 +22,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |apiNamePrefix|Prefix that will be appended to all API names ('tags'). Default: empty string. e.g. Pet => Pet.| |null| |apiStaticMethod|Make api calls using a static method (default: true)| |true| |combineDeferred|Make combine usages deferred (default: true)| |true| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |generateModelAdditionalProperties|Generate model additional properties (default: true)| |true| diff --git a/docs/generators/typescript-angular.md b/docs/generators/typescript-angular.md index 7d7c88af9979..ffaed53f3d17 100644 --- a/docs/generators/typescript-angular.md +++ b/docs/generators/typescript-angular.md @@ -21,7 +21,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |apiModulePrefix|The prefix of the generated ApiModule.| |null| |configurationPrefix|The prefix of the generated Configuration.| |null| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumNameSuffix|Suffix that will be appended to all enum names.| |Enum| |enumPropertyNaming|Naming convention for enum properties: 'camelCase', 'PascalCase', 'snake_case', 'UPPERCASE', and 'original'| |PascalCase| diff --git a/docs/generators/typescript-aurelia.md b/docs/generators/typescript-aurelia.md index 5e1add4c4842..3b28116b332c 100644 --- a/docs/generators/typescript-aurelia.md +++ b/docs/generators/typescript-aurelia.md @@ -19,7 +19,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumNameSuffix|Suffix that will be appended to all enum names.| |Enum| |enumPropertyNaming|Naming convention for enum properties: 'camelCase', 'PascalCase', 'snake_case', 'UPPERCASE', and 'original'| |PascalCase| diff --git a/docs/generators/typescript-axios.md b/docs/generators/typescript-axios.md index 269c2b09587e..c9939daaab47 100644 --- a/docs/generators/typescript-axios.md +++ b/docs/generators/typescript-axios.md @@ -21,7 +21,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |apiPackage|package for generated api classes| |null| |axiosVersion|Use this property to override the axios version in package.json| |^1.6.1| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumNameSuffix|Suffix that will be appended to all enum names.| |Enum| |enumPropertyNaming|Naming convention for enum properties: 'camelCase', 'PascalCase', 'snake_case', 'UPPERCASE', and 'original'| |PascalCase| diff --git a/docs/generators/typescript-fetch.md b/docs/generators/typescript-fetch.md index 3019201de917..1e75832d793f 100644 --- a/docs/generators/typescript-fetch.md +++ b/docs/generators/typescript-fetch.md @@ -19,7 +19,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumNameSuffix|Suffix that will be appended to all enum names.| |Enum| |enumPropertyNaming|Naming convention for enum properties: 'camelCase', 'PascalCase', 'snake_case', 'UPPERCASE', and 'original'| |PascalCase| diff --git a/docs/generators/typescript-inversify.md b/docs/generators/typescript-inversify.md index a98d919447b9..cf9697cb6882 100644 --- a/docs/generators/typescript-inversify.md +++ b/docs/generators/typescript-inversify.md @@ -19,7 +19,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumNameSuffix|Suffix that will be appended to all enum names.| |Enum| |enumPropertyNaming|Naming convention for enum properties: 'camelCase', 'PascalCase', 'snake_case', 'UPPERCASE', and 'original'| |PascalCase| diff --git a/docs/generators/typescript-jquery.md b/docs/generators/typescript-jquery.md index 2d7332baa12d..82af1fc0ef51 100644 --- a/docs/generators/typescript-jquery.md +++ b/docs/generators/typescript-jquery.md @@ -19,7 +19,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumNameSuffix|Suffix that will be appended to all enum names.| |Enum| |enumPropertyNaming|Naming convention for enum properties: 'camelCase', 'PascalCase', 'snake_case', 'UPPERCASE', and 'original'| |PascalCase| diff --git a/docs/generators/typescript-nestjs-server.md b/docs/generators/typescript-nestjs-server.md index 3f15cd815bfe..e17cad87768e 100644 --- a/docs/generators/typescript-nestjs-server.md +++ b/docs/generators/typescript-nestjs-server.md @@ -21,7 +21,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |apiFileSuffix|The suffix of the file of the generated API class (api<suffix>.ts).| |.api| |apiSuffix|The suffix of the generated API class| |Api| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumNameSuffix|Suffix that will be appended to all enum names.| |Enum| |enumPropertyNaming|Naming convention for enum properties: 'camelCase', 'PascalCase', 'snake_case', 'UPPERCASE', and 'original'| |PascalCase| diff --git a/docs/generators/typescript-nestjs.md b/docs/generators/typescript-nestjs.md index 4469d54d2194..f780d5f9afa5 100644 --- a/docs/generators/typescript-nestjs.md +++ b/docs/generators/typescript-nestjs.md @@ -19,7 +19,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumNameSuffix|Suffix that will be appended to all enum names.| |Enum| |enumPropertyNaming|Naming convention for enum properties: 'camelCase', 'PascalCase', 'snake_case', 'UPPERCASE', and 'original'| |PascalCase| diff --git a/docs/generators/typescript-node.md b/docs/generators/typescript-node.md index a92f830046fa..d16a18b9fba4 100644 --- a/docs/generators/typescript-node.md +++ b/docs/generators/typescript-node.md @@ -19,7 +19,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumNameSuffix|Suffix that will be appended to all enum names.| |Enum| |enumPropertyNaming|Naming convention for enum properties: 'camelCase', 'PascalCase', 'snake_case', 'UPPERCASE', and 'original'| |PascalCase| diff --git a/docs/generators/typescript-redux-query.md b/docs/generators/typescript-redux-query.md index 8d1466566dfa..682dd6d1050c 100644 --- a/docs/generators/typescript-redux-query.md +++ b/docs/generators/typescript-redux-query.md @@ -19,7 +19,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumNameSuffix|Suffix that will be appended to all enum names.| |Enum| |enumPropertyNaming|Naming convention for enum properties: 'camelCase', 'PascalCase', 'snake_case', 'UPPERCASE', and 'original'| |PascalCase| diff --git a/docs/generators/typescript-rxjs.md b/docs/generators/typescript-rxjs.md index b5af5b3a6843..0243f1ed629a 100644 --- a/docs/generators/typescript-rxjs.md +++ b/docs/generators/typescript-rxjs.md @@ -19,7 +19,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumNameSuffix|Suffix that will be appended to all enum names.| |Enum| |enumPropertyNaming|Naming convention for enum properties: 'camelCase', 'PascalCase', 'snake_case', 'UPPERCASE', and 'original'| |PascalCase| diff --git a/docs/generators/typescript.md b/docs/generators/typescript.md index 5634f424a966..8d701674a1f8 100644 --- a/docs/generators/typescript.md +++ b/docs/generators/typescript.md @@ -19,7 +19,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumNameSuffix|Suffix that will be appended to all enum names.| |Enum| |enumPropertyNaming|Naming convention for enum properties: 'camelCase', 'PascalCase', 'snake_case', 'UPPERCASE', and 'original'| |PascalCase| diff --git a/docs/generators/wsdl-schema.md b/docs/generators/wsdl-schema.md index 0d45c1d00d68..e4216966f7db 100644 --- a/docs/generators/wsdl-schema.md +++ b/docs/generators/wsdl-schema.md @@ -20,7 +20,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |contentTypeVersion|generate WSDL with parameters/responses of the specified content-type| |null| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |hostname|the hostname of the service| |null| diff --git a/docs/generators/xojo-client.md b/docs/generators/xojo-client.md index ed4358303c82..984c106019b3 100644 --- a/docs/generators/xojo-client.md +++ b/docs/generators/xojo-client.md @@ -21,7 +21,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| |apiNamePrefix|Prefix that will be appended to all API classes. Default: empty string.| |null| |apiPackage|package for generated api classes| |null| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| diff --git a/docs/generators/zapier.md b/docs/generators/zapier.md index 220ae7e4df0a..47e34436fcc8 100644 --- a/docs/generators/zapier.md +++ b/docs/generators/zapier.md @@ -18,7 +18,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl | Option | Description | Values | Default | | ------ | ----------- | ------ | ------- | |allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false| -|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|true| +|disallowAdditionalPropertiesIfNotPresent|If false (default), the 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications. If true, keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|
**false**
The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.
**true**
Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.
|false| |ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true| |enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|
**false**
No changes to the enum's are made, this is the default option.
**true**
With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.
|false| |legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|
**true**
The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.
**false**
The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.
|true| From 41af1a23718dc96cda6984c878e506b52867366c Mon Sep 17 00:00:00 2001 From: Charles Treatman Date: Thu, 1 May 2025 16:47:19 -0500 Subject: [PATCH 5/7] regenerate samples --- .../csharp-generichost-net4.8-useDateTimeForDate.yaml | 1 + bin/configs/csharp-unityWebRequest-net9.yaml | 1 + .../python-pydantic-v1/openapi_client/models/bird.py | 5 +++++ .../python-pydantic-v1/openapi_client/models/category.py | 5 +++++ .../python-pydantic-v1/openapi_client/models/data_query.py | 5 +++++ .../openapi_client/models/default_value.py | 5 +++++ .../openapi_client/models/number_properties_only.py | 5 +++++ .../echo_api/python-pydantic-v1/openapi_client/models/pet.py | 5 +++++ .../echo_api/python-pydantic-v1/openapi_client/models/tag.py | 5 +++++ .../models/test_form_object_multipart_request_marker.py | 5 +++++ ...ject_explode_true_object_all_of_query_object_parameter.py | 5 +++++ ..._form_explode_true_array_string_query_object_parameter.py | 5 +++++ samples/client/echo_api/python/openapi_client/models/bird.py | 5 +++++ .../client/echo_api/python/openapi_client/models/category.py | 5 +++++ .../echo_api/python/openapi_client/models/data_query.py | 5 +++++ .../echo_api/python/openapi_client/models/default_value.py | 5 +++++ .../python/openapi_client/models/number_properties_only.py | 5 +++++ samples/client/echo_api/python/openapi_client/models/pet.py | 5 +++++ samples/client/echo_api/python/openapi_client/models/tag.py | 5 +++++ .../models/test_form_object_multipart_request_marker.py | 5 +++++ ...ject_explode_true_object_all_of_query_object_parameter.py | 5 +++++ ..._form_explode_true_array_string_query_object_parameter.py | 5 +++++ .../petstore_api/models/additional_properties_class.py | 5 +++++ .../python-aiohttp/petstore_api/models/all_of_super_model.py | 5 +++++ .../petstore_api/models/all_of_with_single_ref.py | 5 +++++ .../petstore_api/models/array_of_array_of_model.py | 5 +++++ .../petstore_api/models/array_of_array_of_number_only.py | 5 +++++ .../petstore_api/models/array_of_number_only.py | 5 +++++ .../python-aiohttp/petstore_api/models/array_test.py | 5 +++++ .../python-aiohttp/petstore_api/models/basque_pig.py | 5 +++++ .../petstore/python-aiohttp/petstore_api/models/bathing.py | 5 +++++ .../python-aiohttp/petstore_api/models/capitalization.py | 5 +++++ .../petstore/python-aiohttp/petstore_api/models/cat.py | 5 +++++ .../petstore/python-aiohttp/petstore_api/models/category.py | 5 +++++ .../petstore_api/models/circular_all_of_ref.py | 5 +++++ .../petstore_api/models/circular_reference_model.py | 5 +++++ .../python-aiohttp/petstore_api/models/class_model.py | 5 +++++ .../petstore/python-aiohttp/petstore_api/models/client.py | 5 +++++ .../python-aiohttp/petstore_api/models/creature_info.py | 5 +++++ .../python-aiohttp/petstore_api/models/danish_pig.py | 5 +++++ .../python-aiohttp/petstore_api/models/deprecated_object.py | 5 +++++ .../petstore_api/models/discriminator_all_of_sub.py | 5 +++++ .../petstore/python-aiohttp/petstore_api/models/dog.py | 5 +++++ .../python-aiohttp/petstore_api/models/dummy_model.py | 5 +++++ .../python-aiohttp/petstore_api/models/enum_arrays.py | 5 +++++ .../petstore/python-aiohttp/petstore_api/models/enum_test.py | 5 +++++ .../petstore/python-aiohttp/petstore_api/models/feeding.py | 5 +++++ .../petstore/python-aiohttp/petstore_api/models/file.py | 5 +++++ .../petstore_api/models/file_schema_test_class.py | 5 +++++ .../petstore/python-aiohttp/petstore_api/models/first_ref.py | 5 +++++ .../petstore/python-aiohttp/petstore_api/models/foo.py | 5 +++++ .../petstore_api/models/foo_get_default_response.py | 5 +++++ .../python-aiohttp/petstore_api/models/format_test.py | 5 +++++ .../python-aiohttp/petstore_api/models/has_only_read_only.py | 5 +++++ .../petstore_api/models/health_check_result.py | 5 +++++ .../python-aiohttp/petstore_api/models/hunting_dog.py | 5 +++++ .../petstore/python-aiohttp/petstore_api/models/info.py | 5 +++++ .../petstore_api/models/inner_dict_with_property.py | 5 +++++ .../python-aiohttp/petstore_api/models/input_all_of.py | 5 +++++ .../python-aiohttp/petstore_api/models/list_class.py | 5 +++++ .../petstore_api/models/map_of_array_of_model.py | 5 +++++ .../petstore/python-aiohttp/petstore_api/models/map_test.py | 5 +++++ .../mixed_properties_and_additional_properties_class.py | 5 +++++ .../python-aiohttp/petstore_api/models/model200_response.py | 5 +++++ .../python-aiohttp/petstore_api/models/model_api_response.py | 5 +++++ .../python-aiohttp/petstore_api/models/model_field.py | 5 +++++ .../python-aiohttp/petstore_api/models/model_return.py | 5 +++++ .../python-aiohttp/petstore_api/models/multi_arrays.py | 5 +++++ .../petstore/python-aiohttp/petstore_api/models/name.py | 5 +++++ .../python-aiohttp/petstore_api/models/nullable_property.py | 5 +++++ .../python-aiohttp/petstore_api/models/number_only.py | 5 +++++ .../models/object_to_test_additional_properties.py | 5 +++++ .../petstore_api/models/object_with_deprecated_fields.py | 5 +++++ .../petstore/python-aiohttp/petstore_api/models/order.py | 5 +++++ .../python-aiohttp/petstore_api/models/outer_composite.py | 5 +++++ .../petstore_api/models/outer_object_with_enum_property.py | 5 +++++ .../petstore/python-aiohttp/petstore_api/models/parent.py | 5 +++++ .../petstore_api/models/parent_with_optional_dict.py | 5 +++++ .../petstore/python-aiohttp/petstore_api/models/pet.py | 5 +++++ .../python-aiohttp/petstore_api/models/pony_sizes.py | 5 +++++ .../python-aiohttp/petstore_api/models/poop_cleaning.py | 5 +++++ .../python-aiohttp/petstore_api/models/primitive_string.py | 5 +++++ .../python-aiohttp/petstore_api/models/property_map.py | 5 +++++ .../petstore_api/models/property_name_collision.py | 5 +++++ .../python-aiohttp/petstore_api/models/read_only_first.py | 5 +++++ .../petstore_api/models/second_circular_all_of_ref.py | 5 +++++ .../python-aiohttp/petstore_api/models/second_ref.py | 5 +++++ .../petstore_api/models/self_reference_model.py | 5 +++++ .../python-aiohttp/petstore_api/models/special_model_name.py | 5 +++++ .../python-aiohttp/petstore_api/models/special_name.py | 5 +++++ .../petstore/python-aiohttp/petstore_api/models/tag.py | 5 +++++ .../petstore/python-aiohttp/petstore_api/models/task.py | 5 +++++ .../models/test_error_responses_with_model400_response.py | 5 +++++ .../models/test_error_responses_with_model404_response.py | 5 +++++ .../petstore_api/models/test_model_with_enum_default.py | 5 +++++ .../test_object_for_multipart_requests_request_marker.py | 5 +++++ .../petstore/python-aiohttp/petstore_api/models/tiger.py | 5 +++++ .../unnamed_dict_with_additional_model_list_properties.py | 5 +++++ .../unnamed_dict_with_additional_string_list_properties.py | 5 +++++ .../upload_file_with_additional_properties_request_object.py | 5 +++++ .../petstore/python-aiohttp/petstore_api/models/user.py | 5 +++++ .../python-aiohttp/petstore_api/models/with_nested_one_of.py | 5 +++++ .../petstore_api/models/additional_properties_class.py | 5 +++++ .../petstore_api/models/all_of_super_model.py | 5 +++++ .../petstore_api/models/all_of_with_single_ref.py | 5 +++++ .../petstore_api/models/api_response.py | 5 +++++ .../petstore_api/models/array_of_array_of_model.py | 5 +++++ .../petstore_api/models/array_of_array_of_number_only.py | 5 +++++ .../petstore_api/models/array_of_number_only.py | 5 +++++ .../petstore_api/models/array_test.py | 5 +++++ .../petstore_api/models/basque_pig.py | 5 +++++ .../petstore_api/models/bathing.py | 5 +++++ .../petstore_api/models/capitalization.py | 5 +++++ .../python-pydantic-v1-aiohttp/petstore_api/models/cat.py | 5 +++++ .../petstore_api/models/category.py | 5 +++++ .../petstore_api/models/circular_all_of_ref.py | 5 +++++ .../petstore_api/models/circular_reference_model.py | 5 +++++ .../petstore_api/models/class_model.py | 5 +++++ .../python-pydantic-v1-aiohttp/petstore_api/models/client.py | 5 +++++ .../petstore_api/models/creature_info.py | 5 +++++ .../petstore_api/models/danish_pig.py | 5 +++++ .../petstore_api/models/deprecated_object.py | 5 +++++ .../petstore_api/models/discriminator_all_of_sub.py | 5 +++++ .../python-pydantic-v1-aiohttp/petstore_api/models/dog.py | 5 +++++ .../petstore_api/models/dummy_model.py | 5 +++++ .../petstore_api/models/enum_arrays.py | 5 +++++ .../petstore_api/models/enum_test.py | 5 +++++ .../petstore_api/models/feeding.py | 5 +++++ .../python-pydantic-v1-aiohttp/petstore_api/models/field.py | 5 +++++ .../python-pydantic-v1-aiohttp/petstore_api/models/file.py | 5 +++++ .../petstore_api/models/file_schema_test_class.py | 5 +++++ .../petstore_api/models/first_ref.py | 5 +++++ .../python-pydantic-v1-aiohttp/petstore_api/models/foo.py | 5 +++++ .../petstore_api/models/foo_get_default_response.py | 5 +++++ .../petstore_api/models/format_test.py | 5 +++++ .../petstore_api/models/has_only_read_only.py | 5 +++++ .../petstore_api/models/health_check_result.py | 5 +++++ .../petstore_api/models/hunting_dog.py | 5 +++++ .../python-pydantic-v1-aiohttp/petstore_api/models/info.py | 5 +++++ .../petstore_api/models/inner_dict_with_property.py | 5 +++++ .../petstore_api/models/input_all_of.py | 5 +++++ .../petstore_api/models/list_class.py | 5 +++++ .../petstore_api/models/map_of_array_of_model.py | 5 +++++ .../petstore_api/models/map_test.py | 5 +++++ .../mixed_properties_and_additional_properties_class.py | 5 +++++ .../petstore_api/models/model200_response.py | 5 +++++ .../petstore_api/models/model_return.py | 5 +++++ .../petstore_api/models/multi_arrays.py | 5 +++++ .../python-pydantic-v1-aiohttp/petstore_api/models/name.py | 5 +++++ .../petstore_api/models/nullable_property.py | 5 +++++ .../petstore_api/models/number_only.py | 5 +++++ .../models/object_to_test_additional_properties.py | 5 +++++ .../petstore_api/models/object_with_deprecated_fields.py | 5 +++++ .../python-pydantic-v1-aiohttp/petstore_api/models/order.py | 5 +++++ .../petstore_api/models/outer_composite.py | 5 +++++ .../petstore_api/models/outer_object_with_enum_property.py | 5 +++++ .../python-pydantic-v1-aiohttp/petstore_api/models/parent.py | 5 +++++ .../petstore_api/models/parent_with_optional_dict.py | 5 +++++ .../python-pydantic-v1-aiohttp/petstore_api/models/pet.py | 5 +++++ .../petstore_api/models/pony_sizes.py | 5 +++++ .../petstore_api/models/poop_cleaning.py | 5 +++++ .../petstore_api/models/primitive_string.py | 5 +++++ .../petstore_api/models/property_map.py | 5 +++++ .../petstore_api/models/property_name_collision.py | 5 +++++ .../petstore_api/models/read_only_first.py | 5 +++++ .../petstore_api/models/second_circular_all_of_ref.py | 5 +++++ .../petstore_api/models/second_ref.py | 5 +++++ .../petstore_api/models/self_reference_model.py | 5 +++++ .../petstore_api/models/special_model_name.py | 5 +++++ .../petstore_api/models/special_name.py | 5 +++++ .../python-pydantic-v1-aiohttp/petstore_api/models/tag.py | 5 +++++ .../python-pydantic-v1-aiohttp/petstore_api/models/task.py | 5 +++++ .../models/test_error_responses_with_model400_response.py | 5 +++++ .../models/test_error_responses_with_model404_response.py | 5 +++++ .../petstore_api/models/test_model_with_enum_default.py | 5 +++++ .../test_object_for_multipart_requests_request_marker.py | 5 +++++ .../python-pydantic-v1-aiohttp/petstore_api/models/tiger.py | 5 +++++ .../unnamed_dict_with_additional_model_list_properties.py | 5 +++++ .../unnamed_dict_with_additional_string_list_properties.py | 5 +++++ .../upload_file_with_additional_properties_request_object.py | 5 +++++ .../python-pydantic-v1-aiohttp/petstore_api/models/user.py | 5 +++++ .../petstore_api/models/with_nested_one_of.py | 5 +++++ .../python-fastapi/src/openapi_server/models/api_response.py | 5 +++++ .../python-fastapi/src/openapi_server/models/category.py | 5 +++++ .../python-fastapi/src/openapi_server/models/order.py | 5 +++++ .../petstore/python-fastapi/src/openapi_server/models/pet.py | 5 +++++ .../petstore/python-fastapi/src/openapi_server/models/tag.py | 5 +++++ .../python-fastapi/src/openapi_server/models/user.py | 5 +++++ 188 files changed, 932 insertions(+) diff --git a/bin/configs/csharp-generichost-net4.8-useDateTimeForDate.yaml b/bin/configs/csharp-generichost-net4.8-useDateTimeForDate.yaml index b8be398bde5f..865592237ea4 100644 --- a/bin/configs/csharp-generichost-net4.8-useDateTimeForDate.yaml +++ b/bin/configs/csharp-generichost-net4.8-useDateTimeForDate.yaml @@ -9,3 +9,4 @@ additionalProperties: targetFramework: net48 modelPropertySorting: alphabetical operationParameterSorting: alphabetical + disallowAdditionalPropertiesIfNotPresent: true diff --git a/bin/configs/csharp-unityWebRequest-net9.yaml b/bin/configs/csharp-unityWebRequest-net9.yaml index b5e84fae8528..5f098c4dcdb7 100644 --- a/bin/configs/csharp-unityWebRequest-net9.yaml +++ b/bin/configs/csharp-unityWebRequest-net9.yaml @@ -7,3 +7,4 @@ library: unityWebRequest additionalProperties: targetFramework: net9.0 equatable: true + disallowAdditionalPropertiesIfNotPresent: true diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/bird.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/bird.py index 77887a53120d..d408009f1b92 100644 --- a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/bird.py +++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/bird.py @@ -65,6 +65,11 @@ def from_dict(cls, obj: dict) -> Bird: if not isinstance(obj, dict): return Bird.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Bird) in the input: " + obj) + _obj = Bird.parse_obj({ "size": obj.get("size"), "color": obj.get("color") diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/category.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/category.py index ee8e5c258ae9..ee881426b742 100644 --- a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/category.py +++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/category.py @@ -65,6 +65,11 @@ def from_dict(cls, obj: dict) -> Category: if not isinstance(obj, dict): return Category.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Category) in the input: " + obj) + _obj = Category.parse_obj({ "id": obj.get("id"), "name": obj.get("name") diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/data_query.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/data_query.py index 84f355f3fdd5..2f8e0c6925e1 100644 --- a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/data_query.py +++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/data_query.py @@ -67,6 +67,11 @@ def from_dict(cls, obj: dict) -> DataQuery: if not isinstance(obj, dict): return DataQuery.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in DataQuery) in the input: " + obj) + _obj = DataQuery.parse_obj({ "id": obj.get("id"), "outcomes": obj.get("outcomes"), diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/default_value.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/default_value.py index e038747ba4eb..e7856e453d11 100644 --- a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/default_value.py +++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/default_value.py @@ -98,6 +98,11 @@ def from_dict(cls, obj: dict) -> DefaultValue: if not isinstance(obj, dict): return DefaultValue.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in DefaultValue) in the input: " + obj) + _obj = DefaultValue.parse_obj({ "array_string_enum_ref_default": obj.get("array_string_enum_ref_default"), "array_string_enum_default": obj.get("array_string_enum_default"), diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/number_properties_only.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/number_properties_only.py index 10bb3a590a21..af75f84829bb 100644 --- a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/number_properties_only.py +++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/number_properties_only.py @@ -66,6 +66,11 @@ def from_dict(cls, obj: dict) -> NumberPropertiesOnly: if not isinstance(obj, dict): return NumberPropertiesOnly.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in NumberPropertiesOnly) in the input: " + obj) + _obj = NumberPropertiesOnly.parse_obj({ "number": obj.get("number"), "float": obj.get("float"), diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/pet.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/pet.py index 1d26ea28a588..e0feb7b49680 100644 --- a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/pet.py +++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/pet.py @@ -91,6 +91,11 @@ def from_dict(cls, obj: dict) -> Pet: if not isinstance(obj, dict): return Pet.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Pet) in the input: " + obj) + _obj = Pet.parse_obj({ "id": obj.get("id"), "name": obj.get("name"), diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/tag.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/tag.py index 66a39adff29c..e205ae3883eb 100644 --- a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/tag.py +++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/tag.py @@ -65,6 +65,11 @@ def from_dict(cls, obj: dict) -> Tag: if not isinstance(obj, dict): return Tag.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Tag) in the input: " + obj) + _obj = Tag.parse_obj({ "id": obj.get("id"), "name": obj.get("name") diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/test_form_object_multipart_request_marker.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/test_form_object_multipart_request_marker.py index 54ea54fd8d27..89a10f94cdbc 100644 --- a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/test_form_object_multipart_request_marker.py +++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/test_form_object_multipart_request_marker.py @@ -64,6 +64,11 @@ def from_dict(cls, obj: dict) -> TestFormObjectMultipartRequestMarker: if not isinstance(obj, dict): return TestFormObjectMultipartRequestMarker.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in TestFormObjectMultipartRequestMarker) in the input: " + obj) + _obj = TestFormObjectMultipartRequestMarker.parse_obj({ "name": obj.get("name") }) diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter.py index 42e1101ec022..c2677f595ab0 100644 --- a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter.py +++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter.py @@ -67,6 +67,11 @@ def from_dict(cls, obj: dict) -> TestQueryStyleDeepObjectExplodeTrueObjectAllOfQ if not isinstance(obj, dict): return TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter) in the input: " + obj) + _obj = TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter.parse_obj({ "size": obj.get("size"), "color": obj.get("color"), diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.py index 1bff80a6df1c..f5302ec8a603 100644 --- a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.py +++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.py @@ -64,6 +64,11 @@ def from_dict(cls, obj: dict) -> TestQueryStyleFormExplodeTrueArrayStringQueryOb if not isinstance(obj, dict): return TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter) in the input: " + obj) + _obj = TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.parse_obj({ "values": obj.get("values") }) diff --git a/samples/client/echo_api/python/openapi_client/models/bird.py b/samples/client/echo_api/python/openapi_client/models/bird.py index 9f0dd625119d..9bb24b9e6d80 100644 --- a/samples/client/echo_api/python/openapi_client/models/bird.py +++ b/samples/client/echo_api/python/openapi_client/models/bird.py @@ -81,6 +81,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Bird) in the input: " + _key) + _obj = cls.model_validate({ "size": obj.get("size"), "color": obj.get("color") diff --git a/samples/client/echo_api/python/openapi_client/models/category.py b/samples/client/echo_api/python/openapi_client/models/category.py index d81b92c0f6e3..c8e9bb709fd1 100644 --- a/samples/client/echo_api/python/openapi_client/models/category.py +++ b/samples/client/echo_api/python/openapi_client/models/category.py @@ -81,6 +81,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Category) in the input: " + _key) + _obj = cls.model_validate({ "id": obj.get("id"), "name": obj.get("name") diff --git a/samples/client/echo_api/python/openapi_client/models/data_query.py b/samples/client/echo_api/python/openapi_client/models/data_query.py index dc9a58598e63..255a5ab7f422 100644 --- a/samples/client/echo_api/python/openapi_client/models/data_query.py +++ b/samples/client/echo_api/python/openapi_client/models/data_query.py @@ -84,6 +84,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in DataQuery) in the input: " + _key) + _obj = cls.model_validate({ "id": obj.get("id"), "outcomes": obj.get("outcomes"), diff --git a/samples/client/echo_api/python/openapi_client/models/default_value.py b/samples/client/echo_api/python/openapi_client/models/default_value.py index feee1843319f..8dceac31e3d5 100644 --- a/samples/client/echo_api/python/openapi_client/models/default_value.py +++ b/samples/client/echo_api/python/openapi_client/models/default_value.py @@ -114,6 +114,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in DefaultValue) in the input: " + _key) + _obj = cls.model_validate({ "array_string_enum_ref_default": obj.get("array_string_enum_ref_default"), "array_string_enum_default": obj.get("array_string_enum_default"), diff --git a/samples/client/echo_api/python/openapi_client/models/number_properties_only.py b/samples/client/echo_api/python/openapi_client/models/number_properties_only.py index 08b3d5600ffa..d089c9775ace 100644 --- a/samples/client/echo_api/python/openapi_client/models/number_properties_only.py +++ b/samples/client/echo_api/python/openapi_client/models/number_properties_only.py @@ -83,6 +83,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in NumberPropertiesOnly) in the input: " + _key) + _obj = cls.model_validate({ "number": obj.get("number"), "float": obj.get("float"), diff --git a/samples/client/echo_api/python/openapi_client/models/pet.py b/samples/client/echo_api/python/openapi_client/models/pet.py index 0a0ae74d1155..bfe90956d977 100644 --- a/samples/client/echo_api/python/openapi_client/models/pet.py +++ b/samples/client/echo_api/python/openapi_client/models/pet.py @@ -107,6 +107,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Pet) in the input: " + _key) + _obj = cls.model_validate({ "id": obj.get("id"), "name": obj.get("name"), diff --git a/samples/client/echo_api/python/openapi_client/models/tag.py b/samples/client/echo_api/python/openapi_client/models/tag.py index feec4b3f31cc..5ec177ca73ae 100644 --- a/samples/client/echo_api/python/openapi_client/models/tag.py +++ b/samples/client/echo_api/python/openapi_client/models/tag.py @@ -81,6 +81,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Tag) in the input: " + _key) + _obj = cls.model_validate({ "id": obj.get("id"), "name": obj.get("name") diff --git a/samples/client/echo_api/python/openapi_client/models/test_form_object_multipart_request_marker.py b/samples/client/echo_api/python/openapi_client/models/test_form_object_multipart_request_marker.py index 9f7747151bd5..9fab70ea178d 100644 --- a/samples/client/echo_api/python/openapi_client/models/test_form_object_multipart_request_marker.py +++ b/samples/client/echo_api/python/openapi_client/models/test_form_object_multipart_request_marker.py @@ -80,6 +80,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in TestFormObjectMultipartRequestMarker) in the input: " + _key) + _obj = cls.model_validate({ "name": obj.get("name") }) diff --git a/samples/client/echo_api/python/openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter.py b/samples/client/echo_api/python/openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter.py index 8ed0f58c990b..8cf292b6a90b 100644 --- a/samples/client/echo_api/python/openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter.py +++ b/samples/client/echo_api/python/openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter.py @@ -83,6 +83,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter) in the input: " + _key) + _obj = cls.model_validate({ "size": obj.get("size"), "color": obj.get("color"), diff --git a/samples/client/echo_api/python/openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.py b/samples/client/echo_api/python/openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.py index a9a7a5929f2e..726b427743ca 100644 --- a/samples/client/echo_api/python/openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.py +++ b/samples/client/echo_api/python/openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.py @@ -80,6 +80,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter) in the input: " + _key) + _obj = cls.model_validate({ "values": obj.get("values") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/additional_properties_class.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/additional_properties_class.py index 4b2cc457e499..1a150211b071 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/additional_properties_class.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/additional_properties_class.py @@ -80,6 +80,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in AdditionalPropertiesClass) in the input: " + _key) + _obj = cls.model_validate({ "map_property": obj.get("map_property"), "map_of_map_property": obj.get("map_of_map_property") diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/all_of_super_model.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/all_of_super_model.py index 03f554592935..b1209579f1b5 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/all_of_super_model.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/all_of_super_model.py @@ -79,6 +79,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in AllOfSuperModel) in the input: " + _key) + _obj = cls.model_validate({ "_name": obj.get("_name") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/all_of_with_single_ref.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/all_of_with_single_ref.py index 44c7da9114a8..0bb417646ab1 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/all_of_with_single_ref.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/all_of_with_single_ref.py @@ -81,6 +81,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in AllOfWithSingleRef) in the input: " + _key) + _obj = cls.model_validate({ "username": obj.get("username"), "SingleRefType": obj.get("SingleRefType") diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_array_of_model.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_array_of_model.py index 4f8eeda66c30..25488a12eb67 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_array_of_model.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_array_of_model.py @@ -89,6 +89,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in ArrayOfArrayOfModel) in the input: " + _key) + _obj = cls.model_validate({ "another_property": [ [Tag.from_dict(_inner_item) for _inner_item in _item] diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_array_of_number_only.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_array_of_number_only.py index 02b0f6d657f4..8d64329bb362 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_array_of_number_only.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_array_of_number_only.py @@ -79,6 +79,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in ArrayOfArrayOfNumberOnly) in the input: " + _key) + _obj = cls.model_validate({ "ArrayArrayNumber": obj.get("ArrayArrayNumber") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_number_only.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_number_only.py index b22632b0ce4d..66a08b5a1421 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_number_only.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_number_only.py @@ -79,6 +79,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in ArrayOfNumberOnly) in the input: " + _key) + _obj = cls.model_validate({ "ArrayNumber": obj.get("ArrayNumber") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_test.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_test.py index e8f8acf67cc0..bf6c1649d706 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_test.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_test.py @@ -93,6 +93,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in ArrayTest) in the input: " + _key) + _obj = cls.model_validate({ "array_of_string": obj.get("array_of_string"), "array_of_nullable_float": obj.get("array_of_nullable_float"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/basque_pig.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/basque_pig.py index a1f32a6edcfc..cfc5bb49b67a 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/basque_pig.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/basque_pig.py @@ -80,6 +80,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in BasquePig) in the input: " + _key) + _obj = cls.model_validate({ "className": obj.get("className"), "color": obj.get("color") diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/bathing.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/bathing.py index 088e6ad3b873..278057f26d96 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/bathing.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/bathing.py @@ -95,6 +95,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Bathing) in the input: " + _key) + _obj = cls.model_validate({ "task_name": obj.get("task_name"), "function_name": obj.get("function_name"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/capitalization.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/capitalization.py index b3c20af54440..f743107a4d88 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/capitalization.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/capitalization.py @@ -84,6 +84,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Capitalization) in the input: " + _key) + _obj = cls.model_validate({ "smallCamel": obj.get("smallCamel"), "CapitalCamel": obj.get("CapitalCamel"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/cat.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/cat.py index 0c2c9788dca3..354cc8eb0570 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/cat.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/cat.py @@ -80,6 +80,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Cat) in the input: " + _key) + _obj = cls.model_validate({ "className": obj.get("className"), "color": obj.get("color") if obj.get("color") is not None else 'red', diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/category.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/category.py index dcc6247b5ac7..8b6744fd3b64 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/category.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/category.py @@ -80,6 +80,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Category) in the input: " + _key) + _obj = cls.model_validate({ "id": obj.get("id"), "name": obj.get("name") if obj.get("name") is not None else 'default-name' diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/circular_all_of_ref.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/circular_all_of_ref.py index f98247ae0fb5..4524c698c758 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/circular_all_of_ref.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/circular_all_of_ref.py @@ -87,6 +87,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in CircularAllOfRef) in the input: " + _key) + _obj = cls.model_validate({ "_name": obj.get("_name"), "secondCircularAllOfRef": [SecondCircularAllOfRef.from_dict(_item) for _item in obj["secondCircularAllOfRef"]] if obj.get("secondCircularAllOfRef") is not None else None diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/circular_reference_model.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/circular_reference_model.py index 3b2854caaac2..2b1045a0cf4a 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/circular_reference_model.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/circular_reference_model.py @@ -83,6 +83,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in CircularReferenceModel) in the input: " + _key) + _obj = cls.model_validate({ "size": obj.get("size"), "nested": FirstRef.from_dict(obj["nested"]) if obj.get("nested") is not None else None diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/class_model.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/class_model.py index 6def0e52d146..921a5641babb 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/class_model.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/class_model.py @@ -79,6 +79,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in ClassModel) in the input: " + _key) + _obj = cls.model_validate({ "_class": obj.get("_class") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/client.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/client.py index 1c12c9a145c8..8969db28f5bb 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/client.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/client.py @@ -79,6 +79,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Client) in the input: " + _key) + _obj = cls.model_validate({ "client": obj.get("client") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/creature_info.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/creature_info.py index e7927446c238..95a4d898cb76 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/creature_info.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/creature_info.py @@ -79,6 +79,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in CreatureInfo) in the input: " + _key) + _obj = cls.model_validate({ "name": obj.get("name") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/danish_pig.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/danish_pig.py index 061e16a486a5..8e36166fb3fc 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/danish_pig.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/danish_pig.py @@ -80,6 +80,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in DanishPig) in the input: " + _key) + _obj = cls.model_validate({ "className": obj.get("className"), "size": obj.get("size") diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/deprecated_object.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/deprecated_object.py index bb4747a1e18c..ff83f87309b6 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/deprecated_object.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/deprecated_object.py @@ -79,6 +79,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in DeprecatedObject) in the input: " + _key) + _obj = cls.model_validate({ "name": obj.get("name") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/discriminator_all_of_sub.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/discriminator_all_of_sub.py index 2e8d4a6d7633..c6bbb59241fd 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/discriminator_all_of_sub.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/discriminator_all_of_sub.py @@ -79,6 +79,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in DiscriminatorAllOfSub) in the input: " + _key) + _obj = cls.model_validate({ "elementType": obj.get("elementType") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/dog.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/dog.py index a0f4ed786b4e..f599b798bf11 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/dog.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/dog.py @@ -80,6 +80,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Dog) in the input: " + _key) + _obj = cls.model_validate({ "className": obj.get("className"), "color": obj.get("color") if obj.get("color") is not None else 'red', diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/dummy_model.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/dummy_model.py index 3050cbf66dc4..2e7735152161 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/dummy_model.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/dummy_model.py @@ -83,6 +83,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in DummyModel) in the input: " + _key) + _obj = cls.model_validate({ "category": obj.get("category"), "self_ref": SelfReferenceModel.from_dict(obj["self_ref"]) if obj.get("self_ref") is not None else None diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/enum_arrays.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/enum_arrays.py index 68ceb962b03e..614007cd3f9a 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/enum_arrays.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/enum_arrays.py @@ -101,6 +101,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in EnumArrays) in the input: " + _key) + _obj = cls.model_validate({ "just_symbol": obj.get("just_symbol"), "array_enum": obj.get("array_enum") diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/enum_test.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/enum_test.py index b7e6ec36230f..2ba4c2870b12 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/enum_test.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/enum_test.py @@ -169,6 +169,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in EnumTest) in the input: " + _key) + _obj = cls.model_validate({ "enum_string": obj.get("enum_string"), "enum_string_required": obj.get("enum_string_required"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/feeding.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/feeding.py index 1183b314fdd0..f2e07e7d0090 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/feeding.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/feeding.py @@ -95,6 +95,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Feeding) in the input: " + _key) + _obj = cls.model_validate({ "task_name": obj.get("task_name"), "function_name": obj.get("function_name"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/file.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/file.py index 0ecacf44bb8e..66927f8a9ff7 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/file.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/file.py @@ -79,6 +79,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in File) in the input: " + _key) + _obj = cls.model_validate({ "sourceURI": obj.get("sourceURI") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/file_schema_test_class.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/file_schema_test_class.py index c533c0777b24..56549f9da0eb 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/file_schema_test_class.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/file_schema_test_class.py @@ -91,6 +91,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in FileSchemaTestClass) in the input: " + _key) + _obj = cls.model_validate({ "file": File.from_dict(obj["file"]) if obj.get("file") is not None else None, "files": [File.from_dict(_item) for _item in obj["files"]] if obj.get("files") is not None else None diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/first_ref.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/first_ref.py index 6aa0f722d874..ec92dc9632e8 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/first_ref.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/first_ref.py @@ -83,6 +83,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in FirstRef) in the input: " + _key) + _obj = cls.model_validate({ "category": obj.get("category"), "self_ref": SecondRef.from_dict(obj["self_ref"]) if obj.get("self_ref") is not None else None diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/foo.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/foo.py index 67b29f1ab87c..bd706f5ec423 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/foo.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/foo.py @@ -79,6 +79,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Foo) in the input: " + _key) + _obj = cls.model_validate({ "bar": obj.get("bar") if obj.get("bar") is not None else 'bar' }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/foo_get_default_response.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/foo_get_default_response.py index ae191aad80a8..279f04af3ee4 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/foo_get_default_response.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/foo_get_default_response.py @@ -83,6 +83,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in FooGetDefaultResponse) in the input: " + _key) + _obj = cls.model_validate({ "string": Foo.from_dict(obj["string"]) if obj.get("string") is not None else None }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/format_test.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/format_test.py index 8d70a96f3a7c..e6c0ba1d315e 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/format_test.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/format_test.py @@ -139,6 +139,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in FormatTest) in the input: " + _key) + _obj = cls.model_validate({ "integer": obj.get("integer"), "int32": obj.get("int32"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/has_only_read_only.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/has_only_read_only.py index 2137bc880484..e92a949ef033 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/has_only_read_only.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/has_only_read_only.py @@ -84,6 +84,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in HasOnlyReadOnly) in the input: " + _key) + _obj = cls.model_validate({ "bar": obj.get("bar"), "foo": obj.get("foo") diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/health_check_result.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/health_check_result.py index 4dbdd852097f..1407cc8df9fc 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/health_check_result.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/health_check_result.py @@ -84,6 +84,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in HealthCheckResult) in the input: " + _key) + _obj = cls.model_validate({ "NullableMessage": obj.get("NullableMessage") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/hunting_dog.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/hunting_dog.py index cd678616f62f..47586d7bfd69 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/hunting_dog.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/hunting_dog.py @@ -84,6 +84,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in HuntingDog) in the input: " + _key) + _obj = cls.model_validate({ "info": CreatureInfo.from_dict(obj["info"]) if obj.get("info") is not None else None, "type": obj.get("type"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/info.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/info.py index 5a15b5f9f52f..3c3f2daf0705 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/info.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/info.py @@ -83,6 +83,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Info) in the input: " + _key) + _obj = cls.model_validate({ "_typeName": obj.get("_typeName"), "val": BaseDiscriminator.from_dict(obj["val"]) if obj.get("val") is not None else None diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/inner_dict_with_property.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/inner_dict_with_property.py index 27816b995f53..b60a7a53ebe6 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/inner_dict_with_property.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/inner_dict_with_property.py @@ -79,6 +79,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in InnerDictWithProperty) in the input: " + _key) + _obj = cls.model_validate({ "aProperty": obj.get("aProperty") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/input_all_of.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/input_all_of.py index 63870cca83ed..d8e102b086c9 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/input_all_of.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/input_all_of.py @@ -87,6 +87,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in InputAllOf) in the input: " + _key) + _obj = cls.model_validate({ "some_data": dict( (_k, Tag.from_dict(_v)) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/list_class.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/list_class.py index ab12a7fac521..1277e466e152 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/list_class.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/list_class.py @@ -79,6 +79,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in ListClass) in the input: " + _key) + _obj = cls.model_validate({ "123-list": obj.get("123-list") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/map_of_array_of_model.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/map_of_array_of_model.py index a9bd000ad9ba..c3070a18c65c 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/map_of_array_of_model.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/map_of_array_of_model.py @@ -89,6 +89,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in MapOfArrayOfModel) in the input: " + _key) + _obj = cls.model_validate({ "shopIdToOrgOnlineLipMap": dict( (_k, diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/map_test.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/map_test.py index 2a056ab5532a..2b4801db6a9c 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/map_test.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/map_test.py @@ -93,6 +93,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in MapTest) in the input: " + _key) + _obj = cls.model_validate({ "map_map_of_string": obj.get("map_map_of_string"), "map_of_enum_string": obj.get("map_of_enum_string"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/mixed_properties_and_additional_properties_class.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/mixed_properties_and_additional_properties_class.py index 46998dfb5c68..1ebae82846a9 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/mixed_properties_and_additional_properties_class.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/mixed_properties_and_additional_properties_class.py @@ -91,6 +91,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in MixedPropertiesAndAdditionalPropertiesClass) in the input: " + _key) + _obj = cls.model_validate({ "uuid": obj.get("uuid"), "dateTime": obj.get("dateTime"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model200_response.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model200_response.py index d6012c57fbd7..3332d7e90dd2 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model200_response.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model200_response.py @@ -80,6 +80,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Model200Response) in the input: " + _key) + _obj = cls.model_validate({ "name": obj.get("name"), "class": obj.get("class") diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_api_response.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_api_response.py index 005c77823bef..88d442b023d7 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_api_response.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_api_response.py @@ -81,6 +81,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in ModelApiResponse) in the input: " + _key) + _obj = cls.model_validate({ "code": obj.get("code"), "type": obj.get("type"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_field.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_field.py index 9e36a6ac7e48..53bd7b31e899 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_field.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_field.py @@ -79,6 +79,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in ModelField) in the input: " + _key) + _obj = cls.model_validate({ "field": obj.get("field") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_return.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_return.py index a8c0f53f6c19..29b924cff642 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_return.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_return.py @@ -79,6 +79,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in ModelReturn) in the input: " + _key) + _obj = cls.model_validate({ "return": obj.get("return") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/multi_arrays.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/multi_arrays.py index 177a8359468f..2c014ec61b6b 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/multi_arrays.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/multi_arrays.py @@ -96,6 +96,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in MultiArrays) in the input: " + _key) + _obj = cls.model_validate({ "tags": [Tag.from_dict(_item) for _item in obj["tags"]] if obj.get("tags") is not None else None, "files": [File.from_dict(_item) for _item in obj["files"]] if obj.get("files") is not None else None diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/name.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/name.py index f33b2ecb18be..a7cb24002f8b 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/name.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/name.py @@ -86,6 +86,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Name) in the input: " + _key) + _obj = cls.model_validate({ "name": obj.get("name"), "snake_case": obj.get("snake_case"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/nullable_property.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/nullable_property.py index 2324745d7dd1..94427b756a72 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/nullable_property.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/nullable_property.py @@ -96,6 +96,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in NullableProperty) in the input: " + _key) + _obj = cls.model_validate({ "id": obj.get("id"), "name": obj.get("name") diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/number_only.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/number_only.py index 18c3ec953080..75912ab7e1f3 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/number_only.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/number_only.py @@ -79,6 +79,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in NumberOnly) in the input: " + _key) + _obj = cls.model_validate({ "JustNumber": obj.get("JustNumber") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/object_to_test_additional_properties.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/object_to_test_additional_properties.py index 22b8bd401a1c..3f5e62f6f008 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/object_to_test_additional_properties.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/object_to_test_additional_properties.py @@ -79,6 +79,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in ObjectToTestAdditionalProperties) in the input: " + _key) + _obj = cls.model_validate({ "property": obj.get("property") if obj.get("property") is not None else False }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/object_with_deprecated_fields.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/object_with_deprecated_fields.py index 4d76d9f5fc72..aaed85668228 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/object_with_deprecated_fields.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/object_with_deprecated_fields.py @@ -86,6 +86,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in ObjectWithDeprecatedFields) in the input: " + _key) + _obj = cls.model_validate({ "uuid": obj.get("uuid"), "id": obj.get("id"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/order.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/order.py index f742027e088a..f36c74a11466 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/order.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/order.py @@ -95,6 +95,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Order) in the input: " + _key) + _obj = cls.model_validate({ "id": obj.get("id"), "petId": obj.get("petId"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/outer_composite.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/outer_composite.py index 6a82d49970cb..29e2e7f2cbfe 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/outer_composite.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/outer_composite.py @@ -81,6 +81,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in OuterComposite) in the input: " + _key) + _obj = cls.model_validate({ "my_number": obj.get("my_number"), "my_string": obj.get("my_string"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/outer_object_with_enum_property.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/outer_object_with_enum_property.py index 4f453c2a8d0c..3983b374078b 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/outer_object_with_enum_property.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/outer_object_with_enum_property.py @@ -87,6 +87,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in OuterObjectWithEnumProperty) in the input: " + _key) + _obj = cls.model_validate({ "str_value": obj.get("str_value"), "value": obj.get("value") diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/parent.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/parent.py index 5986da45ab04..10cfd44b142c 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/parent.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/parent.py @@ -87,6 +87,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Parent) in the input: " + _key) + _obj = cls.model_validate({ "optionalDict": dict( (_k, InnerDictWithProperty.from_dict(_v)) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/parent_with_optional_dict.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/parent_with_optional_dict.py index 84445b64043a..94932ca889fc 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/parent_with_optional_dict.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/parent_with_optional_dict.py @@ -87,6 +87,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in ParentWithOptionalDict) in the input: " + _key) + _obj = cls.model_validate({ "optionalDict": dict( (_k, InnerDictWithProperty.from_dict(_v)) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/pet.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/pet.py index be47c3b1a894..2e484b1fc1f9 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/pet.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/pet.py @@ -107,6 +107,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Pet) in the input: " + _key) + _obj = cls.model_validate({ "id": obj.get("id"), "category": Category.from_dict(obj["category"]) if obj.get("category") is not None else None, diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/pony_sizes.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/pony_sizes.py index 00bd38659577..809c15e32be6 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/pony_sizes.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/pony_sizes.py @@ -80,6 +80,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in PonySizes) in the input: " + _key) + _obj = cls.model_validate({ "type": obj.get("type") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/poop_cleaning.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/poop_cleaning.py index 047cf0d481a9..3ea1c21a6154 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/poop_cleaning.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/poop_cleaning.py @@ -95,6 +95,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in PoopCleaning) in the input: " + _key) + _obj = cls.model_validate({ "task_name": obj.get("task_name"), "function_name": obj.get("function_name"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/primitive_string.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/primitive_string.py index 5a7065597861..e79f1e70876f 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/primitive_string.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/primitive_string.py @@ -80,6 +80,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in PrimitiveString) in the input: " + _key) + _obj = cls.model_validate({ "_typeName": obj.get("_typeName"), "_value": obj.get("_value") diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/property_map.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/property_map.py index 940016a86a72..33141e3cc888 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/property_map.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/property_map.py @@ -87,6 +87,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in PropertyMap) in the input: " + _key) + _obj = cls.model_validate({ "some_data": dict( (_k, Tag.from_dict(_v)) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/property_name_collision.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/property_name_collision.py index 0eb56422b648..9694ac677b9f 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/property_name_collision.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/property_name_collision.py @@ -81,6 +81,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in PropertyNameCollision) in the input: " + _key) + _obj = cls.model_validate({ "_type": obj.get("_type"), "type": obj.get("type"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/read_only_first.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/read_only_first.py index c9f4fc6c0df9..500910d67bc3 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/read_only_first.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/read_only_first.py @@ -82,6 +82,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in ReadOnlyFirst) in the input: " + _key) + _obj = cls.model_validate({ "bar": obj.get("bar"), "baz": obj.get("baz") diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/second_circular_all_of_ref.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/second_circular_all_of_ref.py index 854749b4fb13..8909508a3448 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/second_circular_all_of_ref.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/second_circular_all_of_ref.py @@ -87,6 +87,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in SecondCircularAllOfRef) in the input: " + _key) + _obj = cls.model_validate({ "_name": obj.get("_name"), "circularAllOfRef": [CircularAllOfRef.from_dict(_item) for _item in obj["circularAllOfRef"]] if obj.get("circularAllOfRef") is not None else None diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/second_ref.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/second_ref.py index c6627cf0ba63..c96f49eb3dcf 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/second_ref.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/second_ref.py @@ -83,6 +83,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in SecondRef) in the input: " + _key) + _obj = cls.model_validate({ "category": obj.get("category"), "circular_ref": CircularReferenceModel.from_dict(obj["circular_ref"]) if obj.get("circular_ref") is not None else None diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/self_reference_model.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/self_reference_model.py index 7c145db0d3ae..9422a8698bb3 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/self_reference_model.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/self_reference_model.py @@ -83,6 +83,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in SelfReferenceModel) in the input: " + _key) + _obj = cls.model_validate({ "size": obj.get("size"), "nested": DummyModel.from_dict(obj["nested"]) if obj.get("nested") is not None else None diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/special_model_name.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/special_model_name.py index 0336e24d17da..c8874d2a8ced 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/special_model_name.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/special_model_name.py @@ -79,6 +79,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in SpecialModelName) in the input: " + _key) + _obj = cls.model_validate({ "$special[property.name]": obj.get("$special[property.name]") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/special_name.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/special_name.py index d3c8f6185683..b9cb5f15c9f7 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/special_name.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/special_name.py @@ -95,6 +95,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in SpecialName) in the input: " + _key) + _obj = cls.model_validate({ "property": obj.get("property"), "async": Category.from_dict(obj["async"]) if obj.get("async") is not None else None, diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/tag.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/tag.py index e5ddcbcd4a74..965c106a5b40 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/tag.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/tag.py @@ -80,6 +80,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Tag) in the input: " + _key) + _obj = cls.model_validate({ "id": obj.get("id"), "name": obj.get("name") diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/task.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/task.py index 312b2c8ee473..f3ed486d686b 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/task.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/task.py @@ -85,6 +85,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Task) in the input: " + _key) + _obj = cls.model_validate({ "id": obj.get("id"), "activity": TaskActivity.from_dict(obj["activity"]) if obj.get("activity") is not None else None diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_error_responses_with_model400_response.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_error_responses_with_model400_response.py index cba4ab845e5e..d08c727d7d88 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_error_responses_with_model400_response.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_error_responses_with_model400_response.py @@ -79,6 +79,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in TestErrorResponsesWithModel400Response) in the input: " + _key) + _obj = cls.model_validate({ "reason400": obj.get("reason400") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_error_responses_with_model404_response.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_error_responses_with_model404_response.py index 787ca11942ab..df161436e448 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_error_responses_with_model404_response.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_error_responses_with_model404_response.py @@ -79,6 +79,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in TestErrorResponsesWithModel404Response) in the input: " + _key) + _obj = cls.model_validate({ "reason404": obj.get("reason404") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_model_with_enum_default.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_model_with_enum_default.py index 218fa8f16d22..a5aed19c2e6e 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_model_with_enum_default.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_model_with_enum_default.py @@ -95,6 +95,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in TestModelWithEnumDefault) in the input: " + _key) + _obj = cls.model_validate({ "test_enum": obj.get("test_enum"), "test_string": obj.get("test_string"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_object_for_multipart_requests_request_marker.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_object_for_multipart_requests_request_marker.py index a5c3bfdbb1b5..d87943e6d696 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_object_for_multipart_requests_request_marker.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_object_for_multipart_requests_request_marker.py @@ -79,6 +79,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in TestObjectForMultipartRequestsRequestMarker) in the input: " + _key) + _obj = cls.model_validate({ "name": obj.get("name") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/tiger.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/tiger.py index bf8cbf0596ae..e2104073b4fb 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/tiger.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/tiger.py @@ -79,6 +79,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Tiger) in the input: " + _key) + _obj = cls.model_validate({ "skill": obj.get("skill") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py index e50edf2efa85..5cfaf6039826 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py @@ -89,6 +89,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in UnnamedDictWithAdditionalModelListProperties) in the input: " + _key) + _obj = cls.model_validate({ "dictProperty": dict( (_k, diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py index 477dcae27c7c..3213070bb338 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py @@ -79,6 +79,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in UnnamedDictWithAdditionalStringListProperties) in the input: " + _key) + _obj = cls.model_validate({ "dictProperty": obj.get("dictProperty") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/upload_file_with_additional_properties_request_object.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/upload_file_with_additional_properties_request_object.py index 9040618ac0d7..529f50aaa5c8 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/upload_file_with_additional_properties_request_object.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/upload_file_with_additional_properties_request_object.py @@ -79,6 +79,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in UploadFileWithAdditionalPropertiesRequestObject) in the input: " + _key) + _obj = cls.model_validate({ "name": obj.get("name") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/user.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/user.py index 45e0a66f89dd..9bbf8fdad6a6 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/user.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/user.py @@ -86,6 +86,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in User) in the input: " + _key) + _obj = cls.model_validate({ "id": obj.get("id"), "username": obj.get("username"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/with_nested_one_of.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/with_nested_one_of.py index f2cd8b7a3a30..29c45b0360dd 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/with_nested_one_of.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/with_nested_one_of.py @@ -86,6 +86,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in WithNestedOneOf) in the input: " + _key) + _obj = cls.model_validate({ "size": obj.get("size"), "nested_pig": Pig.from_dict(obj["nested_pig"]) if obj.get("nested_pig") is not None else None, diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/additional_properties_class.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/additional_properties_class.py index c53af3e2ca67..4dd4bac8768d 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/additional_properties_class.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/additional_properties_class.py @@ -64,6 +64,11 @@ def from_dict(cls, obj: dict) -> AdditionalPropertiesClass: if not isinstance(obj, dict): return AdditionalPropertiesClass.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in AdditionalPropertiesClass) in the input: " + obj) + _obj = AdditionalPropertiesClass.parse_obj({ "map_property": obj.get("map_property"), "map_of_map_property": obj.get("map_of_map_property") diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/all_of_super_model.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/all_of_super_model.py index 88fdc0e20116..d1f41c7c9ab9 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/all_of_super_model.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/all_of_super_model.py @@ -63,6 +63,11 @@ def from_dict(cls, obj: dict) -> AllOfSuperModel: if not isinstance(obj, dict): return AllOfSuperModel.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in AllOfSuperModel) in the input: " + obj) + _obj = AllOfSuperModel.parse_obj({ "name": obj.get("_name") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/all_of_with_single_ref.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/all_of_with_single_ref.py index a02cecd8e346..73a08e910e4c 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/all_of_with_single_ref.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/all_of_with_single_ref.py @@ -65,6 +65,11 @@ def from_dict(cls, obj: dict) -> AllOfWithSingleRef: if not isinstance(obj, dict): return AllOfWithSingleRef.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in AllOfWithSingleRef) in the input: " + obj) + _obj = AllOfWithSingleRef.parse_obj({ "username": obj.get("username"), "single_ref_type": obj.get("SingleRefType") diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/api_response.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/api_response.py index 2c58b8b9ccb8..7a9069ff086d 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/api_response.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/api_response.py @@ -65,6 +65,11 @@ def from_dict(cls, obj: dict) -> ApiResponse: if not isinstance(obj, dict): return ApiResponse.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in ApiResponse) in the input: " + obj) + _obj = ApiResponse.parse_obj({ "code": obj.get("code"), "type": obj.get("type"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_array_of_model.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_array_of_model.py index 6f67b220ccf1..a666e3b413f0 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_array_of_model.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_array_of_model.py @@ -73,6 +73,11 @@ def from_dict(cls, obj: dict) -> ArrayOfArrayOfModel: if not isinstance(obj, dict): return ArrayOfArrayOfModel.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in ArrayOfArrayOfModel) in the input: " + obj) + _obj = ArrayOfArrayOfModel.parse_obj({ "another_property": [ [Tag.from_dict(_inner_item) for _inner_item in _item] diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_array_of_number_only.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_array_of_number_only.py index 3c160bb53034..d232781a9e7b 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_array_of_number_only.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_array_of_number_only.py @@ -63,6 +63,11 @@ def from_dict(cls, obj: dict) -> ArrayOfArrayOfNumberOnly: if not isinstance(obj, dict): return ArrayOfArrayOfNumberOnly.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in ArrayOfArrayOfNumberOnly) in the input: " + obj) + _obj = ArrayOfArrayOfNumberOnly.parse_obj({ "array_array_number": obj.get("ArrayArrayNumber") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_number_only.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_number_only.py index ce172811448a..6ce44b01f475 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_number_only.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_number_only.py @@ -63,6 +63,11 @@ def from_dict(cls, obj: dict) -> ArrayOfNumberOnly: if not isinstance(obj, dict): return ArrayOfNumberOnly.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in ArrayOfNumberOnly) in the input: " + obj) + _obj = ArrayOfNumberOnly.parse_obj({ "array_number": obj.get("ArrayNumber") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_test.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_test.py index 206b34dc4021..36849e6d7b0a 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_test.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_test.py @@ -76,6 +76,11 @@ def from_dict(cls, obj: dict) -> ArrayTest: if not isinstance(obj, dict): return ArrayTest.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in ArrayTest) in the input: " + obj) + _obj = ArrayTest.parse_obj({ "array_of_string": obj.get("array_of_string"), "array_of_nullable_float": obj.get("array_of_nullable_float"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/basque_pig.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/basque_pig.py index 6efcc0a9b659..a10b247d207e 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/basque_pig.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/basque_pig.py @@ -64,6 +64,11 @@ def from_dict(cls, obj: dict) -> BasquePig: if not isinstance(obj, dict): return BasquePig.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in BasquePig) in the input: " + obj) + _obj = BasquePig.parse_obj({ "class_name": obj.get("className"), "color": obj.get("color") diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/bathing.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/bathing.py index 753acf8d6948..b5feb44f2ac0 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/bathing.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/bathing.py @@ -79,6 +79,11 @@ def from_dict(cls, obj: dict) -> Bathing: if not isinstance(obj, dict): return Bathing.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Bathing) in the input: " + obj) + _obj = Bathing.parse_obj({ "task_name": obj.get("task_name"), "function_name": obj.get("function_name"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/capitalization.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/capitalization.py index 9191b76ccd71..cfc5515b4ea8 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/capitalization.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/capitalization.py @@ -68,6 +68,11 @@ def from_dict(cls, obj: dict) -> Capitalization: if not isinstance(obj, dict): return Capitalization.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Capitalization) in the input: " + obj) + _obj = Capitalization.parse_obj({ "small_camel": obj.get("smallCamel"), "capital_camel": obj.get("CapitalCamel"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/cat.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/cat.py index efff0890a41a..ae8449fa1899 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/cat.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/cat.py @@ -64,6 +64,11 @@ def from_dict(cls, obj: dict) -> Cat: if not isinstance(obj, dict): return Cat.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Cat) in the input: " + obj) + _obj = Cat.parse_obj({ "class_name": obj.get("className"), "color": obj.get("color") if obj.get("color") is not None else 'red', diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/category.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/category.py index 86a10a8683cf..620ccd2016fe 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/category.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/category.py @@ -64,6 +64,11 @@ def from_dict(cls, obj: dict) -> Category: if not isinstance(obj, dict): return Category.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Category) in the input: " + obj) + _obj = Category.parse_obj({ "id": obj.get("id"), "name": obj.get("name") if obj.get("name") is not None else 'default-name' diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/circular_all_of_ref.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/circular_all_of_ref.py index 9177641a136f..d8b579195518 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/circular_all_of_ref.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/circular_all_of_ref.py @@ -71,6 +71,11 @@ def from_dict(cls, obj: dict) -> CircularAllOfRef: if not isinstance(obj, dict): return CircularAllOfRef.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in CircularAllOfRef) in the input: " + obj) + _obj = CircularAllOfRef.parse_obj({ "name": obj.get("_name"), "second_circular_all_of_ref": [SecondCircularAllOfRef.from_dict(_item) for _item in obj.get("secondCircularAllOfRef")] if obj.get("secondCircularAllOfRef") is not None else None diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/circular_reference_model.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/circular_reference_model.py index 6a9956f5af3b..020fdbb965ff 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/circular_reference_model.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/circular_reference_model.py @@ -67,6 +67,11 @@ def from_dict(cls, obj: dict) -> CircularReferenceModel: if not isinstance(obj, dict): return CircularReferenceModel.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in CircularReferenceModel) in the input: " + obj) + _obj = CircularReferenceModel.parse_obj({ "size": obj.get("size"), "nested": FirstRef.from_dict(obj.get("nested")) if obj.get("nested") is not None else None diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/class_model.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/class_model.py index 01e00e6328aa..ad9fcd965f91 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/class_model.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/class_model.py @@ -63,6 +63,11 @@ def from_dict(cls, obj: dict) -> ClassModel: if not isinstance(obj, dict): return ClassModel.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in ClassModel) in the input: " + obj) + _obj = ClassModel.parse_obj({ "var_class": obj.get("_class") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/client.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/client.py index 01f60acef507..28ea887c08b9 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/client.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/client.py @@ -63,6 +63,11 @@ def from_dict(cls, obj: dict) -> Client: if not isinstance(obj, dict): return Client.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Client) in the input: " + obj) + _obj = Client.parse_obj({ "client": obj.get("client") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/creature_info.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/creature_info.py index 327ce9bc4fbc..de2dfaca6e3e 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/creature_info.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/creature_info.py @@ -63,6 +63,11 @@ def from_dict(cls, obj: dict) -> CreatureInfo: if not isinstance(obj, dict): return CreatureInfo.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in CreatureInfo) in the input: " + obj) + _obj = CreatureInfo.parse_obj({ "name": obj.get("name") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/danish_pig.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/danish_pig.py index b53aa7221874..9c9403334f32 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/danish_pig.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/danish_pig.py @@ -64,6 +64,11 @@ def from_dict(cls, obj: dict) -> DanishPig: if not isinstance(obj, dict): return DanishPig.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in DanishPig) in the input: " + obj) + _obj = DanishPig.parse_obj({ "class_name": obj.get("className"), "size": obj.get("size") diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/deprecated_object.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/deprecated_object.py index 9ce72f88d48b..b074764f4d60 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/deprecated_object.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/deprecated_object.py @@ -63,6 +63,11 @@ def from_dict(cls, obj: dict) -> DeprecatedObject: if not isinstance(obj, dict): return DeprecatedObject.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in DeprecatedObject) in the input: " + obj) + _obj = DeprecatedObject.parse_obj({ "name": obj.get("name") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/discriminator_all_of_sub.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/discriminator_all_of_sub.py index 65d54ea8d1a6..327a4284068d 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/discriminator_all_of_sub.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/discriminator_all_of_sub.py @@ -63,6 +63,11 @@ def from_dict(cls, obj: dict) -> DiscriminatorAllOfSub: if not isinstance(obj, dict): return DiscriminatorAllOfSub.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in DiscriminatorAllOfSub) in the input: " + obj) + _obj = DiscriminatorAllOfSub.parse_obj({ "element_type": obj.get("elementType") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/dog.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/dog.py index f0533a50e495..b03c0d516366 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/dog.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/dog.py @@ -64,6 +64,11 @@ def from_dict(cls, obj: dict) -> Dog: if not isinstance(obj, dict): return Dog.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Dog) in the input: " + obj) + _obj = Dog.parse_obj({ "class_name": obj.get("className"), "color": obj.get("color") if obj.get("color") is not None else 'red', diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/dummy_model.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/dummy_model.py index 8e4db12e5c92..34247cd806df 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/dummy_model.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/dummy_model.py @@ -67,6 +67,11 @@ def from_dict(cls, obj: dict) -> DummyModel: if not isinstance(obj, dict): return DummyModel.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in DummyModel) in the input: " + obj) + _obj = DummyModel.parse_obj({ "category": obj.get("category"), "self_ref": SelfReferenceModel.from_dict(obj.get("self_ref")) if obj.get("self_ref") is not None else None diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/enum_arrays.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/enum_arrays.py index 05d532614fff..1edc760b9a43 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/enum_arrays.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/enum_arrays.py @@ -85,6 +85,11 @@ def from_dict(cls, obj: dict) -> EnumArrays: if not isinstance(obj, dict): return EnumArrays.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in EnumArrays) in the input: " + obj) + _obj = EnumArrays.parse_obj({ "just_symbol": obj.get("just_symbol"), "array_enum": obj.get("array_enum") diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/enum_test.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/enum_test.py index 40247e276473..df18966304d6 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/enum_test.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/enum_test.py @@ -153,6 +153,11 @@ def from_dict(cls, obj: dict) -> EnumTest: if not isinstance(obj, dict): return EnumTest.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in EnumTest) in the input: " + obj) + _obj = EnumTest.parse_obj({ "enum_string": obj.get("enum_string"), "enum_string_required": obj.get("enum_string_required"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/feeding.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/feeding.py index 3013f7d57d00..1fb706a22f2f 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/feeding.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/feeding.py @@ -79,6 +79,11 @@ def from_dict(cls, obj: dict) -> Feeding: if not isinstance(obj, dict): return Feeding.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Feeding) in the input: " + obj) + _obj = Feeding.parse_obj({ "task_name": obj.get("task_name"), "function_name": obj.get("function_name"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/field.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/field.py index f37f521c0564..770be284bee3 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/field.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/field.py @@ -63,6 +63,11 @@ def from_dict(cls, obj: dict) -> Field: if not isinstance(obj, dict): return Field.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Field) in the input: " + obj) + _obj = Field.parse_obj({ "field": obj.get("field") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/file.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/file.py index 3d2e4e288bf5..01f13383428c 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/file.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/file.py @@ -63,6 +63,11 @@ def from_dict(cls, obj: dict) -> File: if not isinstance(obj, dict): return File.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in File) in the input: " + obj) + _obj = File.parse_obj({ "source_uri": obj.get("sourceURI") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/file_schema_test_class.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/file_schema_test_class.py index 32058bd16fa0..2e7c8f4d09cf 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/file_schema_test_class.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/file_schema_test_class.py @@ -75,6 +75,11 @@ def from_dict(cls, obj: dict) -> FileSchemaTestClass: if not isinstance(obj, dict): return FileSchemaTestClass.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in FileSchemaTestClass) in the input: " + obj) + _obj = FileSchemaTestClass.parse_obj({ "file": File.from_dict(obj.get("file")) if obj.get("file") is not None else None, "files": [File.from_dict(_item) for _item in obj.get("files")] if obj.get("files") is not None else None diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/first_ref.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/first_ref.py index ace84a5bcb84..45b22e3d566d 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/first_ref.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/first_ref.py @@ -67,6 +67,11 @@ def from_dict(cls, obj: dict) -> FirstRef: if not isinstance(obj, dict): return FirstRef.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in FirstRef) in the input: " + obj) + _obj = FirstRef.parse_obj({ "category": obj.get("category"), "self_ref": SecondRef.from_dict(obj.get("self_ref")) if obj.get("self_ref") is not None else None diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/foo.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/foo.py index fc58b159e5f5..928c6abb8a78 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/foo.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/foo.py @@ -63,6 +63,11 @@ def from_dict(cls, obj: dict) -> Foo: if not isinstance(obj, dict): return Foo.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Foo) in the input: " + obj) + _obj = Foo.parse_obj({ "bar": obj.get("bar") if obj.get("bar") is not None else 'bar' }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/foo_get_default_response.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/foo_get_default_response.py index e792358dc002..b3cb9eeca843 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/foo_get_default_response.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/foo_get_default_response.py @@ -67,6 +67,11 @@ def from_dict(cls, obj: dict) -> FooGetDefaultResponse: if not isinstance(obj, dict): return FooGetDefaultResponse.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in FooGetDefaultResponse) in the input: " + obj) + _obj = FooGetDefaultResponse.parse_obj({ "string": Foo.from_dict(obj.get("string")) if obj.get("string") is not None else None }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/format_test.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/format_test.py index e8ba23b7243a..1ca788e29035 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/format_test.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/format_test.py @@ -119,6 +119,11 @@ def from_dict(cls, obj: dict) -> FormatTest: if not isinstance(obj, dict): return FormatTest.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in FormatTest) in the input: " + obj) + _obj = FormatTest.parse_obj({ "integer": obj.get("integer"), "int32": obj.get("int32"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/has_only_read_only.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/has_only_read_only.py index 5a6dd7857d12..f6567a36f4d0 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/has_only_read_only.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/has_only_read_only.py @@ -66,6 +66,11 @@ def from_dict(cls, obj: dict) -> HasOnlyReadOnly: if not isinstance(obj, dict): return HasOnlyReadOnly.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in HasOnlyReadOnly) in the input: " + obj) + _obj = HasOnlyReadOnly.parse_obj({ "bar": obj.get("bar"), "foo": obj.get("foo") diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/health_check_result.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/health_check_result.py index a914e4ffeec4..029897a16f85 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/health_check_result.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/health_check_result.py @@ -68,6 +68,11 @@ def from_dict(cls, obj: dict) -> HealthCheckResult: if not isinstance(obj, dict): return HealthCheckResult.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in HealthCheckResult) in the input: " + obj) + _obj = HealthCheckResult.parse_obj({ "nullable_message": obj.get("NullableMessage") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/hunting_dog.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/hunting_dog.py index 21df0725400d..030c0b83dd5d 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/hunting_dog.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/hunting_dog.py @@ -68,6 +68,11 @@ def from_dict(cls, obj: dict) -> HuntingDog: if not isinstance(obj, dict): return HuntingDog.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in HuntingDog) in the input: " + obj) + _obj = HuntingDog.parse_obj({ "info": CreatureInfo.from_dict(obj.get("info")) if obj.get("info") is not None else None, "type": obj.get("type"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/info.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/info.py index a181034ea313..698c93fcd6a4 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/info.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/info.py @@ -67,6 +67,11 @@ def from_dict(cls, obj: dict) -> Info: if not isinstance(obj, dict): return Info.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Info) in the input: " + obj) + _obj = Info.parse_obj({ "type_name": obj.get("_typeName"), "val": BaseDiscriminator.from_dict(obj.get("val")) if obj.get("val") is not None else None diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/inner_dict_with_property.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/inner_dict_with_property.py index a455a5bb59dd..5c3bfc291370 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/inner_dict_with_property.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/inner_dict_with_property.py @@ -63,6 +63,11 @@ def from_dict(cls, obj: dict) -> InnerDictWithProperty: if not isinstance(obj, dict): return InnerDictWithProperty.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in InnerDictWithProperty) in the input: " + obj) + _obj = InnerDictWithProperty.parse_obj({ "a_property": obj.get("aProperty") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/input_all_of.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/input_all_of.py index 03990b32988f..96b2c56f2057 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/input_all_of.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/input_all_of.py @@ -71,6 +71,11 @@ def from_dict(cls, obj: dict) -> InputAllOf: if not isinstance(obj, dict): return InputAllOf.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in InputAllOf) in the input: " + obj) + _obj = InputAllOf.parse_obj({ "some_data": dict( (_k, Tag.from_dict(_v)) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/list_class.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/list_class.py index 23aebf15d17d..9cff751c3955 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/list_class.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/list_class.py @@ -63,6 +63,11 @@ def from_dict(cls, obj: dict) -> ListClass: if not isinstance(obj, dict): return ListClass.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in ListClass) in the input: " + obj) + _obj = ListClass.parse_obj({ "var_123_list": obj.get("123-list") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/map_of_array_of_model.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/map_of_array_of_model.py index 3e0c5f2f782f..497ac831dd99 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/map_of_array_of_model.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/map_of_array_of_model.py @@ -73,6 +73,11 @@ def from_dict(cls, obj: dict) -> MapOfArrayOfModel: if not isinstance(obj, dict): return MapOfArrayOfModel.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in MapOfArrayOfModel) in the input: " + obj) + _obj = MapOfArrayOfModel.parse_obj({ "shop_id_to_org_online_lip_map": dict( (_k, diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/map_test.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/map_test.py index ce853d3d77b1..5b0f552aafda 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/map_test.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/map_test.py @@ -76,6 +76,11 @@ def from_dict(cls, obj: dict) -> MapTest: if not isinstance(obj, dict): return MapTest.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in MapTest) in the input: " + obj) + _obj = MapTest.parse_obj({ "map_map_of_string": obj.get("map_map_of_string"), "map_of_enum_string": obj.get("map_of_enum_string"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/mixed_properties_and_additional_properties_class.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/mixed_properties_and_additional_properties_class.py index 59b1adeee43b..812582941ca7 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/mixed_properties_and_additional_properties_class.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/mixed_properties_and_additional_properties_class.py @@ -73,6 +73,11 @@ def from_dict(cls, obj: dict) -> MixedPropertiesAndAdditionalPropertiesClass: if not isinstance(obj, dict): return MixedPropertiesAndAdditionalPropertiesClass.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in MixedPropertiesAndAdditionalPropertiesClass) in the input: " + obj) + _obj = MixedPropertiesAndAdditionalPropertiesClass.parse_obj({ "uuid": obj.get("uuid"), "date_time": obj.get("dateTime"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/model200_response.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/model200_response.py index 7efca1e60410..20bb4653d4c8 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/model200_response.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/model200_response.py @@ -64,6 +64,11 @@ def from_dict(cls, obj: dict) -> Model200Response: if not isinstance(obj, dict): return Model200Response.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Model200Response) in the input: " + obj) + _obj = Model200Response.parse_obj({ "name": obj.get("name"), "var_class": obj.get("class") diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/model_return.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/model_return.py index 69be3ef4b951..8cdfde948cdf 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/model_return.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/model_return.py @@ -63,6 +63,11 @@ def from_dict(cls, obj: dict) -> ModelReturn: if not isinstance(obj, dict): return ModelReturn.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in ModelReturn) in the input: " + obj) + _obj = ModelReturn.parse_obj({ "var_return": obj.get("return") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/multi_arrays.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/multi_arrays.py index ce0acf8c8fda..e221ce90744e 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/multi_arrays.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/multi_arrays.py @@ -80,6 +80,11 @@ def from_dict(cls, obj: dict) -> MultiArrays: if not isinstance(obj, dict): return MultiArrays.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in MultiArrays) in the input: " + obj) + _obj = MultiArrays.parse_obj({ "tags": [Tag.from_dict(_item) for _item in obj.get("tags")] if obj.get("tags") is not None else None, "files": [File.from_dict(_item) for _item in obj.get("files")] if obj.get("files") is not None else None diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/name.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/name.py index 200ad652b342..65dbff22f3e1 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/name.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/name.py @@ -68,6 +68,11 @@ def from_dict(cls, obj: dict) -> Name: if not isinstance(obj, dict): return Name.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Name) in the input: " + obj) + _obj = Name.parse_obj({ "name": obj.get("name"), "snake_case": obj.get("snake_case"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/nullable_property.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/nullable_property.py index 2312fbbbf5fd..224fb59c768c 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/nullable_property.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/nullable_property.py @@ -79,6 +79,11 @@ def from_dict(cls, obj: dict) -> NullableProperty: if not isinstance(obj, dict): return NullableProperty.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in NullableProperty) in the input: " + obj) + _obj = NullableProperty.parse_obj({ "id": obj.get("id"), "name": obj.get("name") diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/number_only.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/number_only.py index b194840c0c1a..35665e623803 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/number_only.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/number_only.py @@ -63,6 +63,11 @@ def from_dict(cls, obj: dict) -> NumberOnly: if not isinstance(obj, dict): return NumberOnly.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in NumberOnly) in the input: " + obj) + _obj = NumberOnly.parse_obj({ "just_number": obj.get("JustNumber") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/object_to_test_additional_properties.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/object_to_test_additional_properties.py index b78667ae0902..03c0c70b52ca 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/object_to_test_additional_properties.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/object_to_test_additional_properties.py @@ -63,6 +63,11 @@ def from_dict(cls, obj: dict) -> ObjectToTestAdditionalProperties: if not isinstance(obj, dict): return ObjectToTestAdditionalProperties.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in ObjectToTestAdditionalProperties) in the input: " + obj) + _obj = ObjectToTestAdditionalProperties.parse_obj({ "var_property": obj.get("property") if obj.get("property") is not None else False }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/object_with_deprecated_fields.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/object_with_deprecated_fields.py index e976e40738bd..0a2ec666823f 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/object_with_deprecated_fields.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/object_with_deprecated_fields.py @@ -70,6 +70,11 @@ def from_dict(cls, obj: dict) -> ObjectWithDeprecatedFields: if not isinstance(obj, dict): return ObjectWithDeprecatedFields.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in ObjectWithDeprecatedFields) in the input: " + obj) + _obj = ObjectWithDeprecatedFields.parse_obj({ "uuid": obj.get("uuid"), "id": obj.get("id"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/order.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/order.py index fb76b99915a5..c3fb545e40f4 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/order.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/order.py @@ -78,6 +78,11 @@ def from_dict(cls, obj: dict) -> Order: if not isinstance(obj, dict): return Order.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Order) in the input: " + obj) + _obj = Order.parse_obj({ "id": obj.get("id"), "pet_id": obj.get("petId"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/outer_composite.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/outer_composite.py index 63627c3d0fde..16befb999a53 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/outer_composite.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/outer_composite.py @@ -65,6 +65,11 @@ def from_dict(cls, obj: dict) -> OuterComposite: if not isinstance(obj, dict): return OuterComposite.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in OuterComposite) in the input: " + obj) + _obj = OuterComposite.parse_obj({ "my_number": obj.get("my_number"), "my_string": obj.get("my_string"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/outer_object_with_enum_property.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/outer_object_with_enum_property.py index c4ae68e5510f..e942d9dc650e 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/outer_object_with_enum_property.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/outer_object_with_enum_property.py @@ -71,6 +71,11 @@ def from_dict(cls, obj: dict) -> OuterObjectWithEnumProperty: if not isinstance(obj, dict): return OuterObjectWithEnumProperty.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in OuterObjectWithEnumProperty) in the input: " + obj) + _obj = OuterObjectWithEnumProperty.parse_obj({ "str_value": obj.get("str_value"), "value": obj.get("value") diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/parent.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/parent.py index 5abdaa381149..8bbe230a6e26 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/parent.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/parent.py @@ -71,6 +71,11 @@ def from_dict(cls, obj: dict) -> Parent: if not isinstance(obj, dict): return Parent.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Parent) in the input: " + obj) + _obj = Parent.parse_obj({ "optional_dict": dict( (_k, InnerDictWithProperty.from_dict(_v)) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/parent_with_optional_dict.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/parent_with_optional_dict.py index 1ef787705030..438021c74966 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/parent_with_optional_dict.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/parent_with_optional_dict.py @@ -71,6 +71,11 @@ def from_dict(cls, obj: dict) -> ParentWithOptionalDict: if not isinstance(obj, dict): return ParentWithOptionalDict.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in ParentWithOptionalDict) in the input: " + obj) + _obj = ParentWithOptionalDict.parse_obj({ "optional_dict": dict( (_k, InnerDictWithProperty.from_dict(_v)) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/pet.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/pet.py index 112508adac5a..f9001a068eb8 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/pet.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/pet.py @@ -90,6 +90,11 @@ def from_dict(cls, obj: dict) -> Pet: if not isinstance(obj, dict): return Pet.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Pet) in the input: " + obj) + _obj = Pet.parse_obj({ "id": obj.get("id"), "category": Category.from_dict(obj.get("category")) if obj.get("category") is not None else None, diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/pony_sizes.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/pony_sizes.py index d7c0716b43db..4b9d557eac71 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/pony_sizes.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/pony_sizes.py @@ -64,6 +64,11 @@ def from_dict(cls, obj: dict) -> PonySizes: if not isinstance(obj, dict): return PonySizes.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in PonySizes) in the input: " + obj) + _obj = PonySizes.parse_obj({ "type": obj.get("type") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/poop_cleaning.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/poop_cleaning.py index 9bf76733284f..4b13e6e02785 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/poop_cleaning.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/poop_cleaning.py @@ -79,6 +79,11 @@ def from_dict(cls, obj: dict) -> PoopCleaning: if not isinstance(obj, dict): return PoopCleaning.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in PoopCleaning) in the input: " + obj) + _obj = PoopCleaning.parse_obj({ "task_name": obj.get("task_name"), "function_name": obj.get("function_name"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/primitive_string.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/primitive_string.py index 4d84353e6035..5d32d276071f 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/primitive_string.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/primitive_string.py @@ -64,6 +64,11 @@ def from_dict(cls, obj: dict) -> PrimitiveString: if not isinstance(obj, dict): return PrimitiveString.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in PrimitiveString) in the input: " + obj) + _obj = PrimitiveString.parse_obj({ "type_name": obj.get("_typeName"), "value": obj.get("_value") diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/property_map.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/property_map.py index 9d3d06512b33..1a6a31a77e5e 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/property_map.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/property_map.py @@ -71,6 +71,11 @@ def from_dict(cls, obj: dict) -> PropertyMap: if not isinstance(obj, dict): return PropertyMap.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in PropertyMap) in the input: " + obj) + _obj = PropertyMap.parse_obj({ "some_data": dict( (_k, Tag.from_dict(_v)) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/property_name_collision.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/property_name_collision.py index 43d74bed7c56..05a7f7cecaeb 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/property_name_collision.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/property_name_collision.py @@ -65,6 +65,11 @@ def from_dict(cls, obj: dict) -> PropertyNameCollision: if not isinstance(obj, dict): return PropertyNameCollision.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in PropertyNameCollision) in the input: " + obj) + _obj = PropertyNameCollision.parse_obj({ "type": obj.get("_type"), "type": obj.get("type"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/read_only_first.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/read_only_first.py index da66589ee79c..ef6b24b9a8c4 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/read_only_first.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/read_only_first.py @@ -65,6 +65,11 @@ def from_dict(cls, obj: dict) -> ReadOnlyFirst: if not isinstance(obj, dict): return ReadOnlyFirst.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in ReadOnlyFirst) in the input: " + obj) + _obj = ReadOnlyFirst.parse_obj({ "bar": obj.get("bar"), "baz": obj.get("baz") diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/second_circular_all_of_ref.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/second_circular_all_of_ref.py index 2d000534484d..44ff7db768f8 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/second_circular_all_of_ref.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/second_circular_all_of_ref.py @@ -71,6 +71,11 @@ def from_dict(cls, obj: dict) -> SecondCircularAllOfRef: if not isinstance(obj, dict): return SecondCircularAllOfRef.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in SecondCircularAllOfRef) in the input: " + obj) + _obj = SecondCircularAllOfRef.parse_obj({ "name": obj.get("_name"), "circular_all_of_ref": [CircularAllOfRef.from_dict(_item) for _item in obj.get("circularAllOfRef")] if obj.get("circularAllOfRef") is not None else None diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/second_ref.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/second_ref.py index 0c4f70eb9395..e34d1b3c0083 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/second_ref.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/second_ref.py @@ -67,6 +67,11 @@ def from_dict(cls, obj: dict) -> SecondRef: if not isinstance(obj, dict): return SecondRef.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in SecondRef) in the input: " + obj) + _obj = SecondRef.parse_obj({ "category": obj.get("category"), "circular_ref": CircularReferenceModel.from_dict(obj.get("circular_ref")) if obj.get("circular_ref") is not None else None diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/self_reference_model.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/self_reference_model.py index f7470db995e6..d1024f4882b9 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/self_reference_model.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/self_reference_model.py @@ -67,6 +67,11 @@ def from_dict(cls, obj: dict) -> SelfReferenceModel: if not isinstance(obj, dict): return SelfReferenceModel.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in SelfReferenceModel) in the input: " + obj) + _obj = SelfReferenceModel.parse_obj({ "size": obj.get("size"), "nested": DummyModel.from_dict(obj.get("nested")) if obj.get("nested") is not None else None diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/special_model_name.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/special_model_name.py index 16c328fa5506..805cc74b6887 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/special_model_name.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/special_model_name.py @@ -63,6 +63,11 @@ def from_dict(cls, obj: dict) -> SpecialModelName: if not isinstance(obj, dict): return SpecialModelName.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in SpecialModelName) in the input: " + obj) + _obj = SpecialModelName.parse_obj({ "special_property_name": obj.get("$special[property.name]") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/special_name.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/special_name.py index 1ce291e969be..6f77aedfb18a 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/special_name.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/special_name.py @@ -79,6 +79,11 @@ def from_dict(cls, obj: dict) -> SpecialName: if not isinstance(obj, dict): return SpecialName.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in SpecialName) in the input: " + obj) + _obj = SpecialName.parse_obj({ "var_property": obj.get("property"), "var_async": Category.from_dict(obj.get("async")) if obj.get("async") is not None else None, diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/tag.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/tag.py index 45605d239331..ded7a2487009 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/tag.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/tag.py @@ -64,6 +64,11 @@ def from_dict(cls, obj: dict) -> Tag: if not isinstance(obj, dict): return Tag.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Tag) in the input: " + obj) + _obj = Tag.parse_obj({ "id": obj.get("id"), "name": obj.get("name") diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/task.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/task.py index 2fb988a0a5d5..b9014315d95b 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/task.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/task.py @@ -68,6 +68,11 @@ def from_dict(cls, obj: dict) -> Task: if not isinstance(obj, dict): return Task.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Task) in the input: " + obj) + _obj = Task.parse_obj({ "id": obj.get("id"), "activity": TaskActivity.from_dict(obj.get("activity")) if obj.get("activity") is not None else None diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_error_responses_with_model400_response.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_error_responses_with_model400_response.py index c4904af2905c..f2c94872ff1e 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_error_responses_with_model400_response.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_error_responses_with_model400_response.py @@ -63,6 +63,11 @@ def from_dict(cls, obj: dict) -> TestErrorResponsesWithModel400Response: if not isinstance(obj, dict): return TestErrorResponsesWithModel400Response.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in TestErrorResponsesWithModel400Response) in the input: " + obj) + _obj = TestErrorResponsesWithModel400Response.parse_obj({ "reason400": obj.get("reason400") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_error_responses_with_model404_response.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_error_responses_with_model404_response.py index 96b5f6c58715..82f16a056504 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_error_responses_with_model404_response.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_error_responses_with_model404_response.py @@ -63,6 +63,11 @@ def from_dict(cls, obj: dict) -> TestErrorResponsesWithModel404Response: if not isinstance(obj, dict): return TestErrorResponsesWithModel404Response.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in TestErrorResponsesWithModel404Response) in the input: " + obj) + _obj = TestErrorResponsesWithModel404Response.parse_obj({ "reason404": obj.get("reason404") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_model_with_enum_default.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_model_with_enum_default.py index 861926379409..0f373f65b7ec 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_model_with_enum_default.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_model_with_enum_default.py @@ -79,6 +79,11 @@ def from_dict(cls, obj: dict) -> TestModelWithEnumDefault: if not isinstance(obj, dict): return TestModelWithEnumDefault.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in TestModelWithEnumDefault) in the input: " + obj) + _obj = TestModelWithEnumDefault.parse_obj({ "test_enum": obj.get("test_enum"), "test_string": obj.get("test_string"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_object_for_multipart_requests_request_marker.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_object_for_multipart_requests_request_marker.py index 957ccc5af28f..32782da0f9d9 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_object_for_multipart_requests_request_marker.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_object_for_multipart_requests_request_marker.py @@ -63,6 +63,11 @@ def from_dict(cls, obj: dict) -> TestObjectForMultipartRequestsRequestMarker: if not isinstance(obj, dict): return TestObjectForMultipartRequestsRequestMarker.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in TestObjectForMultipartRequestsRequestMarker) in the input: " + obj) + _obj = TestObjectForMultipartRequestsRequestMarker.parse_obj({ "name": obj.get("name") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/tiger.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/tiger.py index 88b2f3c6a04f..c629915454f6 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/tiger.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/tiger.py @@ -63,6 +63,11 @@ def from_dict(cls, obj: dict) -> Tiger: if not isinstance(obj, dict): return Tiger.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Tiger) in the input: " + obj) + _obj = Tiger.parse_obj({ "skill": obj.get("skill") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py index f4e22caa9d25..9fa8ca79677d 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py @@ -73,6 +73,11 @@ def from_dict(cls, obj: dict) -> UnnamedDictWithAdditionalModelListProperties: if not isinstance(obj, dict): return UnnamedDictWithAdditionalModelListProperties.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in UnnamedDictWithAdditionalModelListProperties) in the input: " + obj) + _obj = UnnamedDictWithAdditionalModelListProperties.parse_obj({ "dict_property": dict( (_k, diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py index af559dfa890c..76718e8e0803 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py @@ -63,6 +63,11 @@ def from_dict(cls, obj: dict) -> UnnamedDictWithAdditionalStringListProperties: if not isinstance(obj, dict): return UnnamedDictWithAdditionalStringListProperties.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in UnnamedDictWithAdditionalStringListProperties) in the input: " + obj) + _obj = UnnamedDictWithAdditionalStringListProperties.parse_obj({ "dict_property": obj.get("dictProperty") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/upload_file_with_additional_properties_request_object.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/upload_file_with_additional_properties_request_object.py index bafe5045c0d5..76bf1757ce40 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/upload_file_with_additional_properties_request_object.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/upload_file_with_additional_properties_request_object.py @@ -63,6 +63,11 @@ def from_dict(cls, obj: dict) -> UploadFileWithAdditionalPropertiesRequestObject if not isinstance(obj, dict): return UploadFileWithAdditionalPropertiesRequestObject.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in UploadFileWithAdditionalPropertiesRequestObject) in the input: " + obj) + _obj = UploadFileWithAdditionalPropertiesRequestObject.parse_obj({ "name": obj.get("name") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/user.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/user.py index df5086cb4573..42678a7ee227 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/user.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/user.py @@ -70,6 +70,11 @@ def from_dict(cls, obj: dict) -> User: if not isinstance(obj, dict): return User.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in User) in the input: " + obj) + _obj = User.parse_obj({ "id": obj.get("id"), "username": obj.get("username"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/with_nested_one_of.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/with_nested_one_of.py index 2fa98ce371e2..7cd3cce5b455 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/with_nested_one_of.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/with_nested_one_of.py @@ -70,6 +70,11 @@ def from_dict(cls, obj: dict) -> WithNestedOneOf: if not isinstance(obj, dict): return WithNestedOneOf.parse_obj(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in WithNestedOneOf) in the input: " + obj) + _obj = WithNestedOneOf.parse_obj({ "size": obj.get("size"), "nested_pig": Pig.from_dict(obj.get("nested_pig")) if obj.get("nested_pig") is not None else None, diff --git a/samples/server/petstore/python-fastapi/src/openapi_server/models/api_response.py b/samples/server/petstore/python-fastapi/src/openapi_server/models/api_response.py index 441c3b825096..2ddf9c7f7fe5 100644 --- a/samples/server/petstore/python-fastapi/src/openapi_server/models/api_response.py +++ b/samples/server/petstore/python-fastapi/src/openapi_server/models/api_response.py @@ -84,6 +84,11 @@ def from_dict(cls, obj: Dict) -> Self: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in ApiResponse) in the input: " + _key) + _obj = cls.model_validate({ "code": obj.get("code"), "type": obj.get("type"), diff --git a/samples/server/petstore/python-fastapi/src/openapi_server/models/category.py b/samples/server/petstore/python-fastapi/src/openapi_server/models/category.py index 48b689cba886..655f9035c7d9 100644 --- a/samples/server/petstore/python-fastapi/src/openapi_server/models/category.py +++ b/samples/server/petstore/python-fastapi/src/openapi_server/models/category.py @@ -94,6 +94,11 @@ def from_dict(cls, obj: Dict) -> Self: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Category) in the input: " + _key) + _obj = cls.model_validate({ "id": obj.get("id"), "name": obj.get("name") diff --git a/samples/server/petstore/python-fastapi/src/openapi_server/models/order.py b/samples/server/petstore/python-fastapi/src/openapi_server/models/order.py index 7a5a38cdb7b4..f43fd31c0b15 100644 --- a/samples/server/petstore/python-fastapi/src/openapi_server/models/order.py +++ b/samples/server/petstore/python-fastapi/src/openapi_server/models/order.py @@ -98,6 +98,11 @@ def from_dict(cls, obj: Dict) -> Self: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Order) in the input: " + _key) + _obj = cls.model_validate({ "id": obj.get("id"), "petId": obj.get("petId"), diff --git a/samples/server/petstore/python-fastapi/src/openapi_server/models/pet.py b/samples/server/petstore/python-fastapi/src/openapi_server/models/pet.py index 450c1b71393f..c303d7151e05 100644 --- a/samples/server/petstore/python-fastapi/src/openapi_server/models/pet.py +++ b/samples/server/petstore/python-fastapi/src/openapi_server/models/pet.py @@ -109,6 +109,11 @@ def from_dict(cls, obj: Dict) -> Self: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Pet) in the input: " + _key) + _obj = cls.model_validate({ "id": obj.get("id"), "category": Category.from_dict(obj.get("category")) if obj.get("category") is not None else None, diff --git a/samples/server/petstore/python-fastapi/src/openapi_server/models/tag.py b/samples/server/petstore/python-fastapi/src/openapi_server/models/tag.py index 8b21d362f55c..5c6c8da930cf 100644 --- a/samples/server/petstore/python-fastapi/src/openapi_server/models/tag.py +++ b/samples/server/petstore/python-fastapi/src/openapi_server/models/tag.py @@ -83,6 +83,11 @@ def from_dict(cls, obj: Dict) -> Self: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in Tag) in the input: " + _key) + _obj = cls.model_validate({ "id": obj.get("id"), "name": obj.get("name") diff --git a/samples/server/petstore/python-fastapi/src/openapi_server/models/user.py b/samples/server/petstore/python-fastapi/src/openapi_server/models/user.py index cb98a57479b5..abc8332607eb 100644 --- a/samples/server/petstore/python-fastapi/src/openapi_server/models/user.py +++ b/samples/server/petstore/python-fastapi/src/openapi_server/models/user.py @@ -89,6 +89,11 @@ def from_dict(cls, obj: Dict) -> Self: if not isinstance(obj, dict): return cls.model_validate(obj) + # raise errors for additional fields in the input + for _key in obj.keys(): + if _key not in cls.__properties: + raise ValueError("Error due to additional fields (not defined in User) in the input: " + _key) + _obj = cls.model_validate({ "id": obj.get("id"), "username": obj.get("username"), From ab972b2e5b5ce3232b9124b71dc3f492b9fbd0e1 Mon Sep 17 00:00:00 2001 From: Charles Treatman Date: Mon, 16 Jun 2025 11:36:46 -0500 Subject: [PATCH 6/7] add Python generator config setting for backwards compatibility --- bin/configs/python-aiohttp.yaml | 1 + bin/configs/python-echo-api.yaml | 1 + bin/configs/python-fastapi.yaml | 1 + bin/configs/python-httpx.yaml | 2 ++ bin/configs/python-pydantic-v1-aiohttp.yaml | 1 + bin/configs/python-pydantic-v1-echo-api.yaml | 1 + bin/configs/spring-boot-oneof-interface.yaml | 1 + .../org/openapitools/codegen/CodegenConstants.java | 4 ++++ .../codegen/languages/AbstractPythonCodegen.java | 10 ++++++++++ .../languages/AbstractPythonPydanticV1Codegen.java | 10 ++++++++++ .../resources/python-fastapi/model_generic.mustache | 4 ++-- .../python-pydantic-v1/model_generic.mustache | 4 ++-- .../src/main/resources/python/model_generic.mustache | 4 ++-- 13 files changed, 38 insertions(+), 6 deletions(-) diff --git a/bin/configs/python-aiohttp.yaml b/bin/configs/python-aiohttp.yaml index 4de1d31d1f86..7ad01a3414e7 100644 --- a/bin/configs/python-aiohttp.yaml +++ b/bin/configs/python-aiohttp.yaml @@ -8,6 +8,7 @@ additionalProperties: mapNumberTo: float poetry1: true disallowAdditionalPropertiesIfNotPresent: true + legacyDisallowAdditionalPropertiesDefaultBehavior: true nameMappings: _type: underscore_type type_: type_with_underscore diff --git a/bin/configs/python-echo-api.yaml b/bin/configs/python-echo-api.yaml index edd245c060d4..63cf76dc6cbd 100644 --- a/bin/configs/python-echo-api.yaml +++ b/bin/configs/python-echo-api.yaml @@ -5,3 +5,4 @@ templateDir: modules/openapi-generator/src/main/resources/python additionalProperties: hideGenerationTimestamp: "true" disallowAdditionalPropertiesIfNotPresent: true + legacyDisallowAdditionalPropertiesDefaultBehavior: true diff --git a/bin/configs/python-fastapi.yaml b/bin/configs/python-fastapi.yaml index c757d25e092b..98ab7a198ed7 100644 --- a/bin/configs/python-fastapi.yaml +++ b/bin/configs/python-fastapi.yaml @@ -6,3 +6,4 @@ sourceFolder: "src" additionalProperties: hideGenerationTimestamp: "true" disallowAdditionalPropertiesIfNotPresent: true + legacyDisallowAdditionalPropertiesDefaultBehavior: true diff --git a/bin/configs/python-httpx.yaml b/bin/configs/python-httpx.yaml index afc0b04ee9c0..101659b77699 100644 --- a/bin/configs/python-httpx.yaml +++ b/bin/configs/python-httpx.yaml @@ -7,6 +7,8 @@ additionalProperties: packageName: petstore_api mapNumberTo: float poetry1: false + disallowAdditionalPropertiesIfNotPresent: true + legacyDisallowAdditionalPropertiesDefaultBehavior: true nameMappings: _type: underscore_type type_: type_with_underscore diff --git a/bin/configs/python-pydantic-v1-aiohttp.yaml b/bin/configs/python-pydantic-v1-aiohttp.yaml index e72d0f917af8..a390cfa940c7 100644 --- a/bin/configs/python-pydantic-v1-aiohttp.yaml +++ b/bin/configs/python-pydantic-v1-aiohttp.yaml @@ -7,3 +7,4 @@ additionalProperties: packageName: petstore_api mapNumberTo: float disallowAdditionalPropertiesIfNotPresent: true + legacyDisallowAdditionalPropertiesDefaultBehavior: true diff --git a/bin/configs/python-pydantic-v1-echo-api.yaml b/bin/configs/python-pydantic-v1-echo-api.yaml index bb9487f9159d..ee1da091cb75 100644 --- a/bin/configs/python-pydantic-v1-echo-api.yaml +++ b/bin/configs/python-pydantic-v1-echo-api.yaml @@ -5,3 +5,4 @@ templateDir: modules/openapi-generator/src/main/resources/python-pydantic-v1 additionalProperties: hideGenerationTimestamp: "true" disallowAdditionalPropertiesIfNotPresent: true + legacyDisallowAdditionalPropertiesDefaultBehavior: true diff --git a/bin/configs/spring-boot-oneof-interface.yaml b/bin/configs/spring-boot-oneof-interface.yaml index a66a2c4bfc97..7addfb9a4d70 100644 --- a/bin/configs/spring-boot-oneof-interface.yaml +++ b/bin/configs/spring-boot-oneof-interface.yaml @@ -10,3 +10,4 @@ additionalProperties: hideGenerationTimestamp: "true" useOneOfInterfaces: "true" useDeductionForOneOfInterfaces: "true" + disallowAdditionalPropertiesIfNotPresent: "true" diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/CodegenConstants.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/CodegenConstants.java index 1316894e1e61..8dd35c5a9cbd 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/CodegenConstants.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/CodegenConstants.java @@ -403,6 +403,10 @@ public static enum ENUM_PROPERTY_NAMING_TYPE {camelCase, PascalCase, snake_case, public static final String LEGACY_DISCRIMINATOR_BEHAVIOR = "legacyDiscriminatorBehavior"; public static final String LEGACY_DISCRIMINATOR_BEHAVIOR_DESC = "Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default)."; + public static final String LEGACY_DEFAULT_DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT_BEHAVIOR = "legacyDisallowAdditionalPropertiesDefaultBehavior"; + public static final String LEGACY_DEFAULT_DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT_BEHAVIOR_DESC = "Set to true for Python generators so that generated code matches what was previously produced when `disallowAdditionalProperties` was unspecified"; + + public static final String USE_SINGLE_REQUEST_PARAMETER = "useSingleRequestParameter"; public static final String USE_SINGLE_REQUEST_PARAMETER_DESC = "Setting this property to true will generate functions with a single argument containing all API endpoint parameters instead of one argument per parameter."; diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractPythonCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractPythonCodegen.java index 0f43180be5a0..825da2329fa7 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractPythonCodegen.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractPythonCodegen.java @@ -54,6 +54,8 @@ public abstract class AbstractPythonCodegen extends DefaultCodegen implements Co protected String packageName = "openapi_client"; @Setter protected String packageVersion = "1.0.0"; @Setter protected String projectName; // for setup.py, e.g. petstore-api + @Setter + protected boolean legacyDisallowAdditionalPropertiesDefaultBehavior = false; protected boolean hasModelsToImport = Boolean.FALSE; protected String mapNumberTo = "Union[StrictFloat, StrictInt]"; protected Map regexModifiers; @@ -150,6 +152,10 @@ public AbstractPythonCodegen() { public void processOpts() { super.processOpts(); + if (additionalProperties.containsKey(CodegenConstants.LEGACY_DEFAULT_DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT_BEHAVIOR)) { + setLegacyDisallowAdditionalPropertiesDefaultBehavior(Boolean.parseBoolean(additionalProperties.get(CodegenConstants.LEGACY_DEFAULT_DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT_BEHAVIOR).toString())); + } + if (StringUtils.isEmpty(System.getenv("PYTHON_POST_PROCESS_FILE"))) { LOGGER.info("Environment variable PYTHON_POST_PROCESS_FILE not defined so the Python code may not be properly formatted. To define it, try 'export PYTHON_POST_PROCESS_FILE=\"/usr/local/bin/yapf -i\"' (Linux/Mac)"); LOGGER.info("NOTE: To enable file post-processing, 'enablePostProcessFile' must be set to `true` (--enable-post-process-file for CLI)."); @@ -991,6 +997,10 @@ private ModelsMap postProcessModelsMap(ModelsMap objs) { // set the extensions if the key is absent model.getVendorExtensions().putIfAbsent("x-py-readonly", readOnlyFields); + if (legacyDisallowAdditionalPropertiesDefaultBehavior) { + model.vendorExtensions.putIfAbsent("x-py-legacy-disallow-additional-properties-default-behavior", true); + } + // remove the items of postponedModelImports in modelImports to avoid circular imports error if (!modelImports.isEmpty() && !postponedModelImports.isEmpty()) { modelImports.removeAll(postponedModelImports); diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractPythonPydanticV1Codegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractPythonPydanticV1Codegen.java index 7591c1df7c37..2919bc170166 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractPythonPydanticV1Codegen.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractPythonPydanticV1Codegen.java @@ -51,6 +51,8 @@ public abstract class AbstractPythonPydanticV1Codegen extends DefaultCodegen imp protected String packageName = "openapi_client"; @Setter protected String packageVersion = "1.0.0"; @Setter protected String projectName; // for setup.py, e.g. petstore-api + @Setter + protected boolean legacyDisallowAdditionalPropertiesDefaultBehavior = false; protected boolean hasModelsToImport = Boolean.FALSE; protected String mapNumberTo = "Union[StrictFloat, StrictInt]"; protected Map regexModifiers; @@ -140,6 +142,10 @@ public AbstractPythonPydanticV1Codegen() { public void processOpts() { super.processOpts(); + if (additionalProperties.containsKey(CodegenConstants.LEGACY_DEFAULT_DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT_BEHAVIOR)) { + setLegacyDisallowAdditionalPropertiesDefaultBehavior(Boolean.parseBoolean(additionalProperties.get(CodegenConstants.LEGACY_DEFAULT_DISALLOW_ADDITIONAL_PROPERTIES_IF_NOT_PRESENT_BEHAVIOR).toString())); + } + if (StringUtils.isEmpty(System.getenv("PYTHON_POST_PROCESS_FILE"))) { LOGGER.info("Environment variable PYTHON_POST_PROCESS_FILE not defined so the Python code may not be properly formatted. To define it, try 'export PYTHON_POST_PROCESS_FILE=\"/usr/local/bin/yapf -i\"' (Linux/Mac)"); LOGGER.info("NOTE: To enable file post-processing, 'enablePostProcessFile' must be set to `true` (--enable-post-process-file for CLI)."); @@ -985,6 +991,10 @@ private ModelsMap postProcessModelsMap(ModelsMap objs) { model.getVendorExtensions().putIfAbsent("x-py-datetime-imports", datetimeImports); model.getVendorExtensions().putIfAbsent("x-py-readonly", readOnlyFields); + if (legacyDisallowAdditionalPropertiesDefaultBehavior) { + model.vendorExtensions.putIfAbsent("x-py-legacy-disallow-additional-properties-default-behavior", true); + } + // remove the items of postponedModelImports in modelImports to avoid circular imports error if (!modelImports.isEmpty() && !postponedModelImports.isEmpty()) { modelImports.removeAll(postponedModelImports); diff --git a/modules/openapi-generator/src/main/resources/python-fastapi/model_generic.mustache b/modules/openapi-generator/src/main/resources/python-fastapi/model_generic.mustache index 41354ee62410..adf97a47c200 100644 --- a/modules/openapi-generator/src/main/resources/python-fastapi/model_generic.mustache +++ b/modules/openapi-generator/src/main/resources/python-fastapi/model_generic.mustache @@ -260,7 +260,7 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}} if not isinstance(obj, dict): return cls.model_validate(obj) - {{#disallowAdditionalPropertiesIfNotPresent}} + {{^vendorExtensions.x-py-legacy-disallow-additional-properties-default-behavior}} {{^isAdditionalPropertiesTrue}} # raise errors for additional fields in the input for _key in obj.keys(): @@ -268,7 +268,7 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}} raise ValueError("Error due to additional fields (not defined in {{classname}}) in the input: " + _key) {{/isAdditionalPropertiesTrue}} - {{/disallowAdditionalPropertiesIfNotPresent}} + {{/vendorExtensions.x-py-legacy-disallow-additional-properties-default-behavior}} _obj = cls.model_validate({ {{#allVars}} {{#isContainer}} diff --git a/modules/openapi-generator/src/main/resources/python-pydantic-v1/model_generic.mustache b/modules/openapi-generator/src/main/resources/python-pydantic-v1/model_generic.mustache index e9ed69317f5f..f56f2051a402 100644 --- a/modules/openapi-generator/src/main/resources/python-pydantic-v1/model_generic.mustache +++ b/modules/openapi-generator/src/main/resources/python-pydantic-v1/model_generic.mustache @@ -252,7 +252,7 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}} if not isinstance(obj, dict): return {{{classname}}}.parse_obj(obj) - {{#disallowAdditionalPropertiesIfNotPresent}} + {{^vendorExtensions.x-py-legacy-disallow-additional-properties-default-behavior}} {{^isAdditionalPropertiesTrue}} # raise errors for additional fields in the input for _key in obj.keys(): @@ -260,7 +260,7 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}} raise ValueError("Error due to additional fields (not defined in {{classname}}) in the input: " + obj) {{/isAdditionalPropertiesTrue}} - {{/disallowAdditionalPropertiesIfNotPresent}} + {{/vendorExtensions.x-py-legacy-disallow-additional-properties-default-behavior}} _obj = {{{classname}}}.parse_obj({ {{#allVars}} {{#isContainer}} diff --git a/modules/openapi-generator/src/main/resources/python/model_generic.mustache b/modules/openapi-generator/src/main/resources/python/model_generic.mustache index 70804d448de0..10c7a248ad9d 100644 --- a/modules/openapi-generator/src/main/resources/python/model_generic.mustache +++ b/modules/openapi-generator/src/main/resources/python/model_generic.mustache @@ -279,7 +279,7 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}} if not isinstance(obj, dict): return cls.model_validate(obj) - {{#disallowAdditionalPropertiesIfNotPresent}} + {{^vendorExtensions.x-py-legacy-disallow-additional-properties-default-behavior}} {{^isAdditionalPropertiesTrue}} # raise errors for additional fields in the input for _key in obj.keys(): @@ -287,7 +287,7 @@ class {{classname}}({{#parent}}{{{.}}}{{/parent}}{{^parent}}BaseModel{{/parent}} raise ValueError("Error due to additional fields (not defined in {{classname}}) in the input: " + _key) {{/isAdditionalPropertiesTrue}} - {{/disallowAdditionalPropertiesIfNotPresent}} + {{/vendorExtensions.x-py-legacy-disallow-additional-properties-default-behavior}} _obj = cls.model_validate({ {{#allVars}} {{#isContainer}} From d0619431b4bdd36f48fcde9a7a4c42e16c95819d Mon Sep 17 00:00:00 2001 From: Charles Treatman Date: Mon, 16 Jun 2025 14:05:42 -0500 Subject: [PATCH 7/7] regenerate Python samples --- .../python-pydantic-v1/openapi_client/models/bird.py | 5 ----- .../python-pydantic-v1/openapi_client/models/category.py | 5 ----- .../python-pydantic-v1/openapi_client/models/data_query.py | 5 ----- .../openapi_client/models/default_value.py | 5 ----- .../openapi_client/models/number_properties_only.py | 5 ----- .../echo_api/python-pydantic-v1/openapi_client/models/pet.py | 5 ----- .../echo_api/python-pydantic-v1/openapi_client/models/tag.py | 5 ----- .../models/test_form_object_multipart_request_marker.py | 5 ----- ...ject_explode_true_object_all_of_query_object_parameter.py | 5 ----- ..._form_explode_true_array_string_query_object_parameter.py | 5 ----- samples/client/echo_api/python/openapi_client/models/bird.py | 5 ----- .../client/echo_api/python/openapi_client/models/category.py | 5 ----- .../echo_api/python/openapi_client/models/data_query.py | 5 ----- .../echo_api/python/openapi_client/models/default_value.py | 5 ----- .../python/openapi_client/models/number_properties_only.py | 5 ----- samples/client/echo_api/python/openapi_client/models/pet.py | 5 ----- samples/client/echo_api/python/openapi_client/models/tag.py | 5 ----- .../models/test_form_object_multipart_request_marker.py | 5 ----- ...ject_explode_true_object_all_of_query_object_parameter.py | 5 ----- ..._form_explode_true_array_string_query_object_parameter.py | 5 ----- .../petstore_api/models/additional_properties_class.py | 5 ----- .../python-aiohttp/petstore_api/models/all_of_super_model.py | 5 ----- .../petstore_api/models/all_of_with_single_ref.py | 5 ----- .../petstore_api/models/array_of_array_of_model.py | 5 ----- .../petstore_api/models/array_of_array_of_number_only.py | 5 ----- .../petstore_api/models/array_of_number_only.py | 5 ----- .../python-aiohttp/petstore_api/models/array_test.py | 5 ----- .../python-aiohttp/petstore_api/models/basque_pig.py | 5 ----- .../petstore/python-aiohttp/petstore_api/models/bathing.py | 5 ----- .../python-aiohttp/petstore_api/models/capitalization.py | 5 ----- .../petstore/python-aiohttp/petstore_api/models/cat.py | 5 ----- .../petstore/python-aiohttp/petstore_api/models/category.py | 5 ----- .../petstore_api/models/circular_all_of_ref.py | 5 ----- .../petstore_api/models/circular_reference_model.py | 5 ----- .../python-aiohttp/petstore_api/models/class_model.py | 5 ----- .../petstore/python-aiohttp/petstore_api/models/client.py | 5 ----- .../python-aiohttp/petstore_api/models/creature_info.py | 5 ----- .../python-aiohttp/petstore_api/models/danish_pig.py | 5 ----- .../python-aiohttp/petstore_api/models/deprecated_object.py | 5 ----- .../petstore_api/models/discriminator_all_of_sub.py | 5 ----- .../petstore/python-aiohttp/petstore_api/models/dog.py | 5 ----- .../python-aiohttp/petstore_api/models/dummy_model.py | 5 ----- .../python-aiohttp/petstore_api/models/enum_arrays.py | 5 ----- .../petstore/python-aiohttp/petstore_api/models/enum_test.py | 5 ----- .../petstore/python-aiohttp/petstore_api/models/feeding.py | 5 ----- .../petstore/python-aiohttp/petstore_api/models/file.py | 5 ----- .../petstore_api/models/file_schema_test_class.py | 5 ----- .../petstore/python-aiohttp/petstore_api/models/first_ref.py | 5 ----- .../petstore/python-aiohttp/petstore_api/models/foo.py | 5 ----- .../petstore_api/models/foo_get_default_response.py | 5 ----- .../python-aiohttp/petstore_api/models/format_test.py | 5 ----- .../python-aiohttp/petstore_api/models/has_only_read_only.py | 5 ----- .../petstore_api/models/health_check_result.py | 5 ----- .../python-aiohttp/petstore_api/models/hunting_dog.py | 5 ----- .../petstore/python-aiohttp/petstore_api/models/info.py | 5 ----- .../petstore_api/models/inner_dict_with_property.py | 5 ----- .../python-aiohttp/petstore_api/models/input_all_of.py | 5 ----- .../python-aiohttp/petstore_api/models/list_class.py | 5 ----- .../petstore_api/models/map_of_array_of_model.py | 5 ----- .../petstore/python-aiohttp/petstore_api/models/map_test.py | 5 ----- .../mixed_properties_and_additional_properties_class.py | 5 ----- .../python-aiohttp/petstore_api/models/model200_response.py | 5 ----- .../python-aiohttp/petstore_api/models/model_api_response.py | 5 ----- .../python-aiohttp/petstore_api/models/model_field.py | 5 ----- .../python-aiohttp/petstore_api/models/model_return.py | 5 ----- .../python-aiohttp/petstore_api/models/multi_arrays.py | 5 ----- .../petstore/python-aiohttp/petstore_api/models/name.py | 5 ----- .../python-aiohttp/petstore_api/models/nullable_property.py | 5 ----- .../python-aiohttp/petstore_api/models/number_only.py | 5 ----- .../models/object_to_test_additional_properties.py | 5 ----- .../petstore_api/models/object_with_deprecated_fields.py | 5 ----- .../petstore/python-aiohttp/petstore_api/models/order.py | 5 ----- .../python-aiohttp/petstore_api/models/outer_composite.py | 5 ----- .../petstore_api/models/outer_object_with_enum_property.py | 5 ----- .../petstore/python-aiohttp/petstore_api/models/parent.py | 5 ----- .../petstore_api/models/parent_with_optional_dict.py | 5 ----- .../petstore/python-aiohttp/petstore_api/models/pet.py | 5 ----- .../python-aiohttp/petstore_api/models/pony_sizes.py | 5 ----- .../python-aiohttp/petstore_api/models/poop_cleaning.py | 5 ----- .../python-aiohttp/petstore_api/models/primitive_string.py | 5 ----- .../python-aiohttp/petstore_api/models/property_map.py | 5 ----- .../petstore_api/models/property_name_collision.py | 5 ----- .../python-aiohttp/petstore_api/models/read_only_first.py | 5 ----- .../petstore_api/models/second_circular_all_of_ref.py | 5 ----- .../python-aiohttp/petstore_api/models/second_ref.py | 5 ----- .../petstore_api/models/self_reference_model.py | 5 ----- .../python-aiohttp/petstore_api/models/special_model_name.py | 5 ----- .../python-aiohttp/petstore_api/models/special_name.py | 5 ----- .../petstore/python-aiohttp/petstore_api/models/tag.py | 5 ----- .../petstore/python-aiohttp/petstore_api/models/task.py | 5 ----- .../models/test_error_responses_with_model400_response.py | 5 ----- .../models/test_error_responses_with_model404_response.py | 5 ----- .../petstore_api/models/test_model_with_enum_default.py | 5 ----- .../test_object_for_multipart_requests_request_marker.py | 5 ----- .../petstore/python-aiohttp/petstore_api/models/tiger.py | 5 ----- .../unnamed_dict_with_additional_model_list_properties.py | 5 ----- .../unnamed_dict_with_additional_string_list_properties.py | 5 ----- .../upload_file_with_additional_properties_request_object.py | 5 ----- .../petstore/python-aiohttp/petstore_api/models/user.py | 5 ----- .../python-aiohttp/petstore_api/models/with_nested_one_of.py | 5 ----- .../petstore_api/models/additional_properties_class.py | 5 ----- .../petstore_api/models/all_of_super_model.py | 5 ----- .../petstore_api/models/all_of_with_single_ref.py | 5 ----- .../petstore_api/models/api_response.py | 5 ----- .../petstore_api/models/array_of_array_of_model.py | 5 ----- .../petstore_api/models/array_of_array_of_number_only.py | 5 ----- .../petstore_api/models/array_of_number_only.py | 5 ----- .../petstore_api/models/array_test.py | 5 ----- .../petstore_api/models/basque_pig.py | 5 ----- .../petstore_api/models/bathing.py | 5 ----- .../petstore_api/models/capitalization.py | 5 ----- .../python-pydantic-v1-aiohttp/petstore_api/models/cat.py | 5 ----- .../petstore_api/models/category.py | 5 ----- .../petstore_api/models/circular_all_of_ref.py | 5 ----- .../petstore_api/models/circular_reference_model.py | 5 ----- .../petstore_api/models/class_model.py | 5 ----- .../python-pydantic-v1-aiohttp/petstore_api/models/client.py | 5 ----- .../petstore_api/models/creature_info.py | 5 ----- .../petstore_api/models/danish_pig.py | 5 ----- .../petstore_api/models/deprecated_object.py | 5 ----- .../petstore_api/models/discriminator_all_of_sub.py | 5 ----- .../python-pydantic-v1-aiohttp/petstore_api/models/dog.py | 5 ----- .../petstore_api/models/dummy_model.py | 5 ----- .../petstore_api/models/enum_arrays.py | 5 ----- .../petstore_api/models/enum_test.py | 5 ----- .../petstore_api/models/feeding.py | 5 ----- .../python-pydantic-v1-aiohttp/petstore_api/models/field.py | 5 ----- .../python-pydantic-v1-aiohttp/petstore_api/models/file.py | 5 ----- .../petstore_api/models/file_schema_test_class.py | 5 ----- .../petstore_api/models/first_ref.py | 5 ----- .../python-pydantic-v1-aiohttp/petstore_api/models/foo.py | 5 ----- .../petstore_api/models/foo_get_default_response.py | 5 ----- .../petstore_api/models/format_test.py | 5 ----- .../petstore_api/models/has_only_read_only.py | 5 ----- .../petstore_api/models/health_check_result.py | 5 ----- .../petstore_api/models/hunting_dog.py | 5 ----- .../python-pydantic-v1-aiohttp/petstore_api/models/info.py | 5 ----- .../petstore_api/models/inner_dict_with_property.py | 5 ----- .../petstore_api/models/input_all_of.py | 5 ----- .../petstore_api/models/list_class.py | 5 ----- .../petstore_api/models/map_of_array_of_model.py | 5 ----- .../petstore_api/models/map_test.py | 5 ----- .../mixed_properties_and_additional_properties_class.py | 5 ----- .../petstore_api/models/model200_response.py | 5 ----- .../petstore_api/models/model_return.py | 5 ----- .../petstore_api/models/multi_arrays.py | 5 ----- .../python-pydantic-v1-aiohttp/petstore_api/models/name.py | 5 ----- .../petstore_api/models/nullable_property.py | 5 ----- .../petstore_api/models/number_only.py | 5 ----- .../models/object_to_test_additional_properties.py | 5 ----- .../petstore_api/models/object_with_deprecated_fields.py | 5 ----- .../python-pydantic-v1-aiohttp/petstore_api/models/order.py | 5 ----- .../petstore_api/models/outer_composite.py | 5 ----- .../petstore_api/models/outer_object_with_enum_property.py | 5 ----- .../python-pydantic-v1-aiohttp/petstore_api/models/parent.py | 5 ----- .../petstore_api/models/parent_with_optional_dict.py | 5 ----- .../python-pydantic-v1-aiohttp/petstore_api/models/pet.py | 5 ----- .../petstore_api/models/pony_sizes.py | 5 ----- .../petstore_api/models/poop_cleaning.py | 5 ----- .../petstore_api/models/primitive_string.py | 5 ----- .../petstore_api/models/property_map.py | 5 ----- .../petstore_api/models/property_name_collision.py | 5 ----- .../petstore_api/models/read_only_first.py | 5 ----- .../petstore_api/models/second_circular_all_of_ref.py | 5 ----- .../petstore_api/models/second_ref.py | 5 ----- .../petstore_api/models/self_reference_model.py | 5 ----- .../petstore_api/models/special_model_name.py | 5 ----- .../petstore_api/models/special_name.py | 5 ----- .../python-pydantic-v1-aiohttp/petstore_api/models/tag.py | 5 ----- .../python-pydantic-v1-aiohttp/petstore_api/models/task.py | 5 ----- .../models/test_error_responses_with_model400_response.py | 5 ----- .../models/test_error_responses_with_model404_response.py | 5 ----- .../petstore_api/models/test_model_with_enum_default.py | 5 ----- .../test_object_for_multipart_requests_request_marker.py | 5 ----- .../python-pydantic-v1-aiohttp/petstore_api/models/tiger.py | 5 ----- .../unnamed_dict_with_additional_model_list_properties.py | 5 ----- .../unnamed_dict_with_additional_string_list_properties.py | 5 ----- .../upload_file_with_additional_properties_request_object.py | 5 ----- .../python-pydantic-v1-aiohttp/petstore_api/models/user.py | 5 ----- .../petstore_api/models/with_nested_one_of.py | 5 ----- .../python-fastapi/src/openapi_server/models/api_response.py | 5 ----- .../python-fastapi/src/openapi_server/models/category.py | 5 ----- .../python-fastapi/src/openapi_server/models/order.py | 5 ----- .../petstore/python-fastapi/src/openapi_server/models/pet.py | 5 ----- .../petstore/python-fastapi/src/openapi_server/models/tag.py | 5 ----- .../python-fastapi/src/openapi_server/models/user.py | 5 ----- 186 files changed, 930 deletions(-) diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/bird.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/bird.py index d408009f1b92..77887a53120d 100644 --- a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/bird.py +++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/bird.py @@ -65,11 +65,6 @@ def from_dict(cls, obj: dict) -> Bird: if not isinstance(obj, dict): return Bird.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Bird) in the input: " + obj) - _obj = Bird.parse_obj({ "size": obj.get("size"), "color": obj.get("color") diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/category.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/category.py index ee881426b742..ee8e5c258ae9 100644 --- a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/category.py +++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/category.py @@ -65,11 +65,6 @@ def from_dict(cls, obj: dict) -> Category: if not isinstance(obj, dict): return Category.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Category) in the input: " + obj) - _obj = Category.parse_obj({ "id": obj.get("id"), "name": obj.get("name") diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/data_query.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/data_query.py index 2f8e0c6925e1..84f355f3fdd5 100644 --- a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/data_query.py +++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/data_query.py @@ -67,11 +67,6 @@ def from_dict(cls, obj: dict) -> DataQuery: if not isinstance(obj, dict): return DataQuery.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in DataQuery) in the input: " + obj) - _obj = DataQuery.parse_obj({ "id": obj.get("id"), "outcomes": obj.get("outcomes"), diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/default_value.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/default_value.py index e7856e453d11..e038747ba4eb 100644 --- a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/default_value.py +++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/default_value.py @@ -98,11 +98,6 @@ def from_dict(cls, obj: dict) -> DefaultValue: if not isinstance(obj, dict): return DefaultValue.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in DefaultValue) in the input: " + obj) - _obj = DefaultValue.parse_obj({ "array_string_enum_ref_default": obj.get("array_string_enum_ref_default"), "array_string_enum_default": obj.get("array_string_enum_default"), diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/number_properties_only.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/number_properties_only.py index af75f84829bb..10bb3a590a21 100644 --- a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/number_properties_only.py +++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/number_properties_only.py @@ -66,11 +66,6 @@ def from_dict(cls, obj: dict) -> NumberPropertiesOnly: if not isinstance(obj, dict): return NumberPropertiesOnly.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in NumberPropertiesOnly) in the input: " + obj) - _obj = NumberPropertiesOnly.parse_obj({ "number": obj.get("number"), "float": obj.get("float"), diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/pet.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/pet.py index e0feb7b49680..1d26ea28a588 100644 --- a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/pet.py +++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/pet.py @@ -91,11 +91,6 @@ def from_dict(cls, obj: dict) -> Pet: if not isinstance(obj, dict): return Pet.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Pet) in the input: " + obj) - _obj = Pet.parse_obj({ "id": obj.get("id"), "name": obj.get("name"), diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/tag.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/tag.py index e205ae3883eb..66a39adff29c 100644 --- a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/tag.py +++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/tag.py @@ -65,11 +65,6 @@ def from_dict(cls, obj: dict) -> Tag: if not isinstance(obj, dict): return Tag.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Tag) in the input: " + obj) - _obj = Tag.parse_obj({ "id": obj.get("id"), "name": obj.get("name") diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/test_form_object_multipart_request_marker.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/test_form_object_multipart_request_marker.py index 89a10f94cdbc..54ea54fd8d27 100644 --- a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/test_form_object_multipart_request_marker.py +++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/test_form_object_multipart_request_marker.py @@ -64,11 +64,6 @@ def from_dict(cls, obj: dict) -> TestFormObjectMultipartRequestMarker: if not isinstance(obj, dict): return TestFormObjectMultipartRequestMarker.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in TestFormObjectMultipartRequestMarker) in the input: " + obj) - _obj = TestFormObjectMultipartRequestMarker.parse_obj({ "name": obj.get("name") }) diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter.py index c2677f595ab0..42e1101ec022 100644 --- a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter.py +++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter.py @@ -67,11 +67,6 @@ def from_dict(cls, obj: dict) -> TestQueryStyleDeepObjectExplodeTrueObjectAllOfQ if not isinstance(obj, dict): return TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter) in the input: " + obj) - _obj = TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter.parse_obj({ "size": obj.get("size"), "color": obj.get("color"), diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.py index f5302ec8a603..1bff80a6df1c 100644 --- a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.py +++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.py @@ -64,11 +64,6 @@ def from_dict(cls, obj: dict) -> TestQueryStyleFormExplodeTrueArrayStringQueryOb if not isinstance(obj, dict): return TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter) in the input: " + obj) - _obj = TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.parse_obj({ "values": obj.get("values") }) diff --git a/samples/client/echo_api/python/openapi_client/models/bird.py b/samples/client/echo_api/python/openapi_client/models/bird.py index 9bb24b9e6d80..9f0dd625119d 100644 --- a/samples/client/echo_api/python/openapi_client/models/bird.py +++ b/samples/client/echo_api/python/openapi_client/models/bird.py @@ -81,11 +81,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Bird) in the input: " + _key) - _obj = cls.model_validate({ "size": obj.get("size"), "color": obj.get("color") diff --git a/samples/client/echo_api/python/openapi_client/models/category.py b/samples/client/echo_api/python/openapi_client/models/category.py index c8e9bb709fd1..d81b92c0f6e3 100644 --- a/samples/client/echo_api/python/openapi_client/models/category.py +++ b/samples/client/echo_api/python/openapi_client/models/category.py @@ -81,11 +81,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Category) in the input: " + _key) - _obj = cls.model_validate({ "id": obj.get("id"), "name": obj.get("name") diff --git a/samples/client/echo_api/python/openapi_client/models/data_query.py b/samples/client/echo_api/python/openapi_client/models/data_query.py index 255a5ab7f422..dc9a58598e63 100644 --- a/samples/client/echo_api/python/openapi_client/models/data_query.py +++ b/samples/client/echo_api/python/openapi_client/models/data_query.py @@ -84,11 +84,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in DataQuery) in the input: " + _key) - _obj = cls.model_validate({ "id": obj.get("id"), "outcomes": obj.get("outcomes"), diff --git a/samples/client/echo_api/python/openapi_client/models/default_value.py b/samples/client/echo_api/python/openapi_client/models/default_value.py index 8dceac31e3d5..feee1843319f 100644 --- a/samples/client/echo_api/python/openapi_client/models/default_value.py +++ b/samples/client/echo_api/python/openapi_client/models/default_value.py @@ -114,11 +114,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in DefaultValue) in the input: " + _key) - _obj = cls.model_validate({ "array_string_enum_ref_default": obj.get("array_string_enum_ref_default"), "array_string_enum_default": obj.get("array_string_enum_default"), diff --git a/samples/client/echo_api/python/openapi_client/models/number_properties_only.py b/samples/client/echo_api/python/openapi_client/models/number_properties_only.py index d089c9775ace..08b3d5600ffa 100644 --- a/samples/client/echo_api/python/openapi_client/models/number_properties_only.py +++ b/samples/client/echo_api/python/openapi_client/models/number_properties_only.py @@ -83,11 +83,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in NumberPropertiesOnly) in the input: " + _key) - _obj = cls.model_validate({ "number": obj.get("number"), "float": obj.get("float"), diff --git a/samples/client/echo_api/python/openapi_client/models/pet.py b/samples/client/echo_api/python/openapi_client/models/pet.py index bfe90956d977..0a0ae74d1155 100644 --- a/samples/client/echo_api/python/openapi_client/models/pet.py +++ b/samples/client/echo_api/python/openapi_client/models/pet.py @@ -107,11 +107,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Pet) in the input: " + _key) - _obj = cls.model_validate({ "id": obj.get("id"), "name": obj.get("name"), diff --git a/samples/client/echo_api/python/openapi_client/models/tag.py b/samples/client/echo_api/python/openapi_client/models/tag.py index 5ec177ca73ae..feec4b3f31cc 100644 --- a/samples/client/echo_api/python/openapi_client/models/tag.py +++ b/samples/client/echo_api/python/openapi_client/models/tag.py @@ -81,11 +81,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Tag) in the input: " + _key) - _obj = cls.model_validate({ "id": obj.get("id"), "name": obj.get("name") diff --git a/samples/client/echo_api/python/openapi_client/models/test_form_object_multipart_request_marker.py b/samples/client/echo_api/python/openapi_client/models/test_form_object_multipart_request_marker.py index 9fab70ea178d..9f7747151bd5 100644 --- a/samples/client/echo_api/python/openapi_client/models/test_form_object_multipart_request_marker.py +++ b/samples/client/echo_api/python/openapi_client/models/test_form_object_multipart_request_marker.py @@ -80,11 +80,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in TestFormObjectMultipartRequestMarker) in the input: " + _key) - _obj = cls.model_validate({ "name": obj.get("name") }) diff --git a/samples/client/echo_api/python/openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter.py b/samples/client/echo_api/python/openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter.py index 8cf292b6a90b..8ed0f58c990b 100644 --- a/samples/client/echo_api/python/openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter.py +++ b/samples/client/echo_api/python/openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter.py @@ -83,11 +83,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter) in the input: " + _key) - _obj = cls.model_validate({ "size": obj.get("size"), "color": obj.get("color"), diff --git a/samples/client/echo_api/python/openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.py b/samples/client/echo_api/python/openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.py index 726b427743ca..a9a7a5929f2e 100644 --- a/samples/client/echo_api/python/openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.py +++ b/samples/client/echo_api/python/openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.py @@ -80,11 +80,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter) in the input: " + _key) - _obj = cls.model_validate({ "values": obj.get("values") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/additional_properties_class.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/additional_properties_class.py index 1a150211b071..4b2cc457e499 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/additional_properties_class.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/additional_properties_class.py @@ -80,11 +80,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in AdditionalPropertiesClass) in the input: " + _key) - _obj = cls.model_validate({ "map_property": obj.get("map_property"), "map_of_map_property": obj.get("map_of_map_property") diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/all_of_super_model.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/all_of_super_model.py index b1209579f1b5..03f554592935 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/all_of_super_model.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/all_of_super_model.py @@ -79,11 +79,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in AllOfSuperModel) in the input: " + _key) - _obj = cls.model_validate({ "_name": obj.get("_name") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/all_of_with_single_ref.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/all_of_with_single_ref.py index 0bb417646ab1..44c7da9114a8 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/all_of_with_single_ref.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/all_of_with_single_ref.py @@ -81,11 +81,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in AllOfWithSingleRef) in the input: " + _key) - _obj = cls.model_validate({ "username": obj.get("username"), "SingleRefType": obj.get("SingleRefType") diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_array_of_model.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_array_of_model.py index 25488a12eb67..4f8eeda66c30 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_array_of_model.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_array_of_model.py @@ -89,11 +89,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in ArrayOfArrayOfModel) in the input: " + _key) - _obj = cls.model_validate({ "another_property": [ [Tag.from_dict(_inner_item) for _inner_item in _item] diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_array_of_number_only.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_array_of_number_only.py index 8d64329bb362..02b0f6d657f4 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_array_of_number_only.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_array_of_number_only.py @@ -79,11 +79,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in ArrayOfArrayOfNumberOnly) in the input: " + _key) - _obj = cls.model_validate({ "ArrayArrayNumber": obj.get("ArrayArrayNumber") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_number_only.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_number_only.py index 66a08b5a1421..b22632b0ce4d 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_number_only.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_of_number_only.py @@ -79,11 +79,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in ArrayOfNumberOnly) in the input: " + _key) - _obj = cls.model_validate({ "ArrayNumber": obj.get("ArrayNumber") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_test.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_test.py index bf6c1649d706..e8f8acf67cc0 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_test.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/array_test.py @@ -93,11 +93,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in ArrayTest) in the input: " + _key) - _obj = cls.model_validate({ "array_of_string": obj.get("array_of_string"), "array_of_nullable_float": obj.get("array_of_nullable_float"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/basque_pig.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/basque_pig.py index cfc5bb49b67a..a1f32a6edcfc 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/basque_pig.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/basque_pig.py @@ -80,11 +80,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in BasquePig) in the input: " + _key) - _obj = cls.model_validate({ "className": obj.get("className"), "color": obj.get("color") diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/bathing.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/bathing.py index 278057f26d96..088e6ad3b873 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/bathing.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/bathing.py @@ -95,11 +95,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Bathing) in the input: " + _key) - _obj = cls.model_validate({ "task_name": obj.get("task_name"), "function_name": obj.get("function_name"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/capitalization.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/capitalization.py index f743107a4d88..b3c20af54440 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/capitalization.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/capitalization.py @@ -84,11 +84,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Capitalization) in the input: " + _key) - _obj = cls.model_validate({ "smallCamel": obj.get("smallCamel"), "CapitalCamel": obj.get("CapitalCamel"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/cat.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/cat.py index 354cc8eb0570..0c2c9788dca3 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/cat.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/cat.py @@ -80,11 +80,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Cat) in the input: " + _key) - _obj = cls.model_validate({ "className": obj.get("className"), "color": obj.get("color") if obj.get("color") is not None else 'red', diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/category.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/category.py index 8b6744fd3b64..dcc6247b5ac7 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/category.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/category.py @@ -80,11 +80,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Category) in the input: " + _key) - _obj = cls.model_validate({ "id": obj.get("id"), "name": obj.get("name") if obj.get("name") is not None else 'default-name' diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/circular_all_of_ref.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/circular_all_of_ref.py index 4524c698c758..f98247ae0fb5 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/circular_all_of_ref.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/circular_all_of_ref.py @@ -87,11 +87,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in CircularAllOfRef) in the input: " + _key) - _obj = cls.model_validate({ "_name": obj.get("_name"), "secondCircularAllOfRef": [SecondCircularAllOfRef.from_dict(_item) for _item in obj["secondCircularAllOfRef"]] if obj.get("secondCircularAllOfRef") is not None else None diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/circular_reference_model.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/circular_reference_model.py index 2b1045a0cf4a..3b2854caaac2 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/circular_reference_model.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/circular_reference_model.py @@ -83,11 +83,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in CircularReferenceModel) in the input: " + _key) - _obj = cls.model_validate({ "size": obj.get("size"), "nested": FirstRef.from_dict(obj["nested"]) if obj.get("nested") is not None else None diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/class_model.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/class_model.py index 921a5641babb..6def0e52d146 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/class_model.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/class_model.py @@ -79,11 +79,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in ClassModel) in the input: " + _key) - _obj = cls.model_validate({ "_class": obj.get("_class") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/client.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/client.py index 8969db28f5bb..1c12c9a145c8 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/client.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/client.py @@ -79,11 +79,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Client) in the input: " + _key) - _obj = cls.model_validate({ "client": obj.get("client") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/creature_info.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/creature_info.py index 95a4d898cb76..e7927446c238 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/creature_info.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/creature_info.py @@ -79,11 +79,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in CreatureInfo) in the input: " + _key) - _obj = cls.model_validate({ "name": obj.get("name") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/danish_pig.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/danish_pig.py index 8e36166fb3fc..061e16a486a5 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/danish_pig.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/danish_pig.py @@ -80,11 +80,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in DanishPig) in the input: " + _key) - _obj = cls.model_validate({ "className": obj.get("className"), "size": obj.get("size") diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/deprecated_object.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/deprecated_object.py index ff83f87309b6..bb4747a1e18c 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/deprecated_object.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/deprecated_object.py @@ -79,11 +79,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in DeprecatedObject) in the input: " + _key) - _obj = cls.model_validate({ "name": obj.get("name") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/discriminator_all_of_sub.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/discriminator_all_of_sub.py index c6bbb59241fd..2e8d4a6d7633 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/discriminator_all_of_sub.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/discriminator_all_of_sub.py @@ -79,11 +79,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in DiscriminatorAllOfSub) in the input: " + _key) - _obj = cls.model_validate({ "elementType": obj.get("elementType") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/dog.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/dog.py index f599b798bf11..a0f4ed786b4e 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/dog.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/dog.py @@ -80,11 +80,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Dog) in the input: " + _key) - _obj = cls.model_validate({ "className": obj.get("className"), "color": obj.get("color") if obj.get("color") is not None else 'red', diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/dummy_model.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/dummy_model.py index 2e7735152161..3050cbf66dc4 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/dummy_model.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/dummy_model.py @@ -83,11 +83,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in DummyModel) in the input: " + _key) - _obj = cls.model_validate({ "category": obj.get("category"), "self_ref": SelfReferenceModel.from_dict(obj["self_ref"]) if obj.get("self_ref") is not None else None diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/enum_arrays.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/enum_arrays.py index 614007cd3f9a..68ceb962b03e 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/enum_arrays.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/enum_arrays.py @@ -101,11 +101,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in EnumArrays) in the input: " + _key) - _obj = cls.model_validate({ "just_symbol": obj.get("just_symbol"), "array_enum": obj.get("array_enum") diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/enum_test.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/enum_test.py index 2ba4c2870b12..b7e6ec36230f 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/enum_test.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/enum_test.py @@ -169,11 +169,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in EnumTest) in the input: " + _key) - _obj = cls.model_validate({ "enum_string": obj.get("enum_string"), "enum_string_required": obj.get("enum_string_required"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/feeding.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/feeding.py index f2e07e7d0090..1183b314fdd0 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/feeding.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/feeding.py @@ -95,11 +95,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Feeding) in the input: " + _key) - _obj = cls.model_validate({ "task_name": obj.get("task_name"), "function_name": obj.get("function_name"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/file.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/file.py index 66927f8a9ff7..0ecacf44bb8e 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/file.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/file.py @@ -79,11 +79,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in File) in the input: " + _key) - _obj = cls.model_validate({ "sourceURI": obj.get("sourceURI") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/file_schema_test_class.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/file_schema_test_class.py index 56549f9da0eb..c533c0777b24 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/file_schema_test_class.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/file_schema_test_class.py @@ -91,11 +91,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in FileSchemaTestClass) in the input: " + _key) - _obj = cls.model_validate({ "file": File.from_dict(obj["file"]) if obj.get("file") is not None else None, "files": [File.from_dict(_item) for _item in obj["files"]] if obj.get("files") is not None else None diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/first_ref.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/first_ref.py index ec92dc9632e8..6aa0f722d874 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/first_ref.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/first_ref.py @@ -83,11 +83,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in FirstRef) in the input: " + _key) - _obj = cls.model_validate({ "category": obj.get("category"), "self_ref": SecondRef.from_dict(obj["self_ref"]) if obj.get("self_ref") is not None else None diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/foo.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/foo.py index bd706f5ec423..67b29f1ab87c 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/foo.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/foo.py @@ -79,11 +79,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Foo) in the input: " + _key) - _obj = cls.model_validate({ "bar": obj.get("bar") if obj.get("bar") is not None else 'bar' }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/foo_get_default_response.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/foo_get_default_response.py index 279f04af3ee4..ae191aad80a8 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/foo_get_default_response.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/foo_get_default_response.py @@ -83,11 +83,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in FooGetDefaultResponse) in the input: " + _key) - _obj = cls.model_validate({ "string": Foo.from_dict(obj["string"]) if obj.get("string") is not None else None }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/format_test.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/format_test.py index e6c0ba1d315e..8d70a96f3a7c 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/format_test.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/format_test.py @@ -139,11 +139,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in FormatTest) in the input: " + _key) - _obj = cls.model_validate({ "integer": obj.get("integer"), "int32": obj.get("int32"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/has_only_read_only.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/has_only_read_only.py index e92a949ef033..2137bc880484 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/has_only_read_only.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/has_only_read_only.py @@ -84,11 +84,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in HasOnlyReadOnly) in the input: " + _key) - _obj = cls.model_validate({ "bar": obj.get("bar"), "foo": obj.get("foo") diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/health_check_result.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/health_check_result.py index 1407cc8df9fc..4dbdd852097f 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/health_check_result.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/health_check_result.py @@ -84,11 +84,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in HealthCheckResult) in the input: " + _key) - _obj = cls.model_validate({ "NullableMessage": obj.get("NullableMessage") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/hunting_dog.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/hunting_dog.py index 47586d7bfd69..cd678616f62f 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/hunting_dog.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/hunting_dog.py @@ -84,11 +84,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in HuntingDog) in the input: " + _key) - _obj = cls.model_validate({ "info": CreatureInfo.from_dict(obj["info"]) if obj.get("info") is not None else None, "type": obj.get("type"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/info.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/info.py index 3c3f2daf0705..5a15b5f9f52f 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/info.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/info.py @@ -83,11 +83,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Info) in the input: " + _key) - _obj = cls.model_validate({ "_typeName": obj.get("_typeName"), "val": BaseDiscriminator.from_dict(obj["val"]) if obj.get("val") is not None else None diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/inner_dict_with_property.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/inner_dict_with_property.py index b60a7a53ebe6..27816b995f53 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/inner_dict_with_property.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/inner_dict_with_property.py @@ -79,11 +79,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in InnerDictWithProperty) in the input: " + _key) - _obj = cls.model_validate({ "aProperty": obj.get("aProperty") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/input_all_of.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/input_all_of.py index d8e102b086c9..63870cca83ed 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/input_all_of.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/input_all_of.py @@ -87,11 +87,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in InputAllOf) in the input: " + _key) - _obj = cls.model_validate({ "some_data": dict( (_k, Tag.from_dict(_v)) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/list_class.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/list_class.py index 1277e466e152..ab12a7fac521 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/list_class.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/list_class.py @@ -79,11 +79,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in ListClass) in the input: " + _key) - _obj = cls.model_validate({ "123-list": obj.get("123-list") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/map_of_array_of_model.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/map_of_array_of_model.py index c3070a18c65c..a9bd000ad9ba 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/map_of_array_of_model.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/map_of_array_of_model.py @@ -89,11 +89,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in MapOfArrayOfModel) in the input: " + _key) - _obj = cls.model_validate({ "shopIdToOrgOnlineLipMap": dict( (_k, diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/map_test.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/map_test.py index 2b4801db6a9c..2a056ab5532a 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/map_test.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/map_test.py @@ -93,11 +93,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in MapTest) in the input: " + _key) - _obj = cls.model_validate({ "map_map_of_string": obj.get("map_map_of_string"), "map_of_enum_string": obj.get("map_of_enum_string"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/mixed_properties_and_additional_properties_class.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/mixed_properties_and_additional_properties_class.py index 1ebae82846a9..46998dfb5c68 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/mixed_properties_and_additional_properties_class.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/mixed_properties_and_additional_properties_class.py @@ -91,11 +91,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in MixedPropertiesAndAdditionalPropertiesClass) in the input: " + _key) - _obj = cls.model_validate({ "uuid": obj.get("uuid"), "dateTime": obj.get("dateTime"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model200_response.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model200_response.py index 3332d7e90dd2..d6012c57fbd7 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model200_response.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model200_response.py @@ -80,11 +80,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Model200Response) in the input: " + _key) - _obj = cls.model_validate({ "name": obj.get("name"), "class": obj.get("class") diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_api_response.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_api_response.py index 88d442b023d7..005c77823bef 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_api_response.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_api_response.py @@ -81,11 +81,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in ModelApiResponse) in the input: " + _key) - _obj = cls.model_validate({ "code": obj.get("code"), "type": obj.get("type"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_field.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_field.py index 53bd7b31e899..9e36a6ac7e48 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_field.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_field.py @@ -79,11 +79,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in ModelField) in the input: " + _key) - _obj = cls.model_validate({ "field": obj.get("field") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_return.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_return.py index 29b924cff642..a8c0f53f6c19 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_return.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/model_return.py @@ -79,11 +79,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in ModelReturn) in the input: " + _key) - _obj = cls.model_validate({ "return": obj.get("return") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/multi_arrays.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/multi_arrays.py index 2c014ec61b6b..177a8359468f 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/multi_arrays.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/multi_arrays.py @@ -96,11 +96,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in MultiArrays) in the input: " + _key) - _obj = cls.model_validate({ "tags": [Tag.from_dict(_item) for _item in obj["tags"]] if obj.get("tags") is not None else None, "files": [File.from_dict(_item) for _item in obj["files"]] if obj.get("files") is not None else None diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/name.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/name.py index a7cb24002f8b..f33b2ecb18be 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/name.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/name.py @@ -86,11 +86,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Name) in the input: " + _key) - _obj = cls.model_validate({ "name": obj.get("name"), "snake_case": obj.get("snake_case"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/nullable_property.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/nullable_property.py index 94427b756a72..2324745d7dd1 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/nullable_property.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/nullable_property.py @@ -96,11 +96,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in NullableProperty) in the input: " + _key) - _obj = cls.model_validate({ "id": obj.get("id"), "name": obj.get("name") diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/number_only.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/number_only.py index 75912ab7e1f3..18c3ec953080 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/number_only.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/number_only.py @@ -79,11 +79,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in NumberOnly) in the input: " + _key) - _obj = cls.model_validate({ "JustNumber": obj.get("JustNumber") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/object_to_test_additional_properties.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/object_to_test_additional_properties.py index 3f5e62f6f008..22b8bd401a1c 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/object_to_test_additional_properties.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/object_to_test_additional_properties.py @@ -79,11 +79,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in ObjectToTestAdditionalProperties) in the input: " + _key) - _obj = cls.model_validate({ "property": obj.get("property") if obj.get("property") is not None else False }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/object_with_deprecated_fields.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/object_with_deprecated_fields.py index aaed85668228..4d76d9f5fc72 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/object_with_deprecated_fields.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/object_with_deprecated_fields.py @@ -86,11 +86,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in ObjectWithDeprecatedFields) in the input: " + _key) - _obj = cls.model_validate({ "uuid": obj.get("uuid"), "id": obj.get("id"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/order.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/order.py index f36c74a11466..f742027e088a 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/order.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/order.py @@ -95,11 +95,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Order) in the input: " + _key) - _obj = cls.model_validate({ "id": obj.get("id"), "petId": obj.get("petId"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/outer_composite.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/outer_composite.py index 29e2e7f2cbfe..6a82d49970cb 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/outer_composite.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/outer_composite.py @@ -81,11 +81,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in OuterComposite) in the input: " + _key) - _obj = cls.model_validate({ "my_number": obj.get("my_number"), "my_string": obj.get("my_string"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/outer_object_with_enum_property.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/outer_object_with_enum_property.py index 3983b374078b..4f453c2a8d0c 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/outer_object_with_enum_property.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/outer_object_with_enum_property.py @@ -87,11 +87,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in OuterObjectWithEnumProperty) in the input: " + _key) - _obj = cls.model_validate({ "str_value": obj.get("str_value"), "value": obj.get("value") diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/parent.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/parent.py index 10cfd44b142c..5986da45ab04 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/parent.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/parent.py @@ -87,11 +87,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Parent) in the input: " + _key) - _obj = cls.model_validate({ "optionalDict": dict( (_k, InnerDictWithProperty.from_dict(_v)) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/parent_with_optional_dict.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/parent_with_optional_dict.py index 94932ca889fc..84445b64043a 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/parent_with_optional_dict.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/parent_with_optional_dict.py @@ -87,11 +87,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in ParentWithOptionalDict) in the input: " + _key) - _obj = cls.model_validate({ "optionalDict": dict( (_k, InnerDictWithProperty.from_dict(_v)) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/pet.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/pet.py index 2e484b1fc1f9..be47c3b1a894 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/pet.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/pet.py @@ -107,11 +107,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Pet) in the input: " + _key) - _obj = cls.model_validate({ "id": obj.get("id"), "category": Category.from_dict(obj["category"]) if obj.get("category") is not None else None, diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/pony_sizes.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/pony_sizes.py index 809c15e32be6..00bd38659577 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/pony_sizes.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/pony_sizes.py @@ -80,11 +80,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in PonySizes) in the input: " + _key) - _obj = cls.model_validate({ "type": obj.get("type") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/poop_cleaning.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/poop_cleaning.py index 3ea1c21a6154..047cf0d481a9 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/poop_cleaning.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/poop_cleaning.py @@ -95,11 +95,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in PoopCleaning) in the input: " + _key) - _obj = cls.model_validate({ "task_name": obj.get("task_name"), "function_name": obj.get("function_name"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/primitive_string.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/primitive_string.py index e79f1e70876f..5a7065597861 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/primitive_string.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/primitive_string.py @@ -80,11 +80,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in PrimitiveString) in the input: " + _key) - _obj = cls.model_validate({ "_typeName": obj.get("_typeName"), "_value": obj.get("_value") diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/property_map.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/property_map.py index 33141e3cc888..940016a86a72 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/property_map.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/property_map.py @@ -87,11 +87,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in PropertyMap) in the input: " + _key) - _obj = cls.model_validate({ "some_data": dict( (_k, Tag.from_dict(_v)) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/property_name_collision.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/property_name_collision.py index 9694ac677b9f..0eb56422b648 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/property_name_collision.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/property_name_collision.py @@ -81,11 +81,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in PropertyNameCollision) in the input: " + _key) - _obj = cls.model_validate({ "_type": obj.get("_type"), "type": obj.get("type"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/read_only_first.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/read_only_first.py index 500910d67bc3..c9f4fc6c0df9 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/read_only_first.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/read_only_first.py @@ -82,11 +82,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in ReadOnlyFirst) in the input: " + _key) - _obj = cls.model_validate({ "bar": obj.get("bar"), "baz": obj.get("baz") diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/second_circular_all_of_ref.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/second_circular_all_of_ref.py index 8909508a3448..854749b4fb13 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/second_circular_all_of_ref.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/second_circular_all_of_ref.py @@ -87,11 +87,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in SecondCircularAllOfRef) in the input: " + _key) - _obj = cls.model_validate({ "_name": obj.get("_name"), "circularAllOfRef": [CircularAllOfRef.from_dict(_item) for _item in obj["circularAllOfRef"]] if obj.get("circularAllOfRef") is not None else None diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/second_ref.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/second_ref.py index c96f49eb3dcf..c6627cf0ba63 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/second_ref.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/second_ref.py @@ -83,11 +83,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in SecondRef) in the input: " + _key) - _obj = cls.model_validate({ "category": obj.get("category"), "circular_ref": CircularReferenceModel.from_dict(obj["circular_ref"]) if obj.get("circular_ref") is not None else None diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/self_reference_model.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/self_reference_model.py index 9422a8698bb3..7c145db0d3ae 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/self_reference_model.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/self_reference_model.py @@ -83,11 +83,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in SelfReferenceModel) in the input: " + _key) - _obj = cls.model_validate({ "size": obj.get("size"), "nested": DummyModel.from_dict(obj["nested"]) if obj.get("nested") is not None else None diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/special_model_name.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/special_model_name.py index c8874d2a8ced..0336e24d17da 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/special_model_name.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/special_model_name.py @@ -79,11 +79,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in SpecialModelName) in the input: " + _key) - _obj = cls.model_validate({ "$special[property.name]": obj.get("$special[property.name]") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/special_name.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/special_name.py index b9cb5f15c9f7..d3c8f6185683 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/special_name.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/special_name.py @@ -95,11 +95,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in SpecialName) in the input: " + _key) - _obj = cls.model_validate({ "property": obj.get("property"), "async": Category.from_dict(obj["async"]) if obj.get("async") is not None else None, diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/tag.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/tag.py index 965c106a5b40..e5ddcbcd4a74 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/tag.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/tag.py @@ -80,11 +80,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Tag) in the input: " + _key) - _obj = cls.model_validate({ "id": obj.get("id"), "name": obj.get("name") diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/task.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/task.py index f3ed486d686b..312b2c8ee473 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/task.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/task.py @@ -85,11 +85,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Task) in the input: " + _key) - _obj = cls.model_validate({ "id": obj.get("id"), "activity": TaskActivity.from_dict(obj["activity"]) if obj.get("activity") is not None else None diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_error_responses_with_model400_response.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_error_responses_with_model400_response.py index d08c727d7d88..cba4ab845e5e 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_error_responses_with_model400_response.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_error_responses_with_model400_response.py @@ -79,11 +79,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in TestErrorResponsesWithModel400Response) in the input: " + _key) - _obj = cls.model_validate({ "reason400": obj.get("reason400") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_error_responses_with_model404_response.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_error_responses_with_model404_response.py index df161436e448..787ca11942ab 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_error_responses_with_model404_response.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_error_responses_with_model404_response.py @@ -79,11 +79,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in TestErrorResponsesWithModel404Response) in the input: " + _key) - _obj = cls.model_validate({ "reason404": obj.get("reason404") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_model_with_enum_default.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_model_with_enum_default.py index a5aed19c2e6e..218fa8f16d22 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_model_with_enum_default.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_model_with_enum_default.py @@ -95,11 +95,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in TestModelWithEnumDefault) in the input: " + _key) - _obj = cls.model_validate({ "test_enum": obj.get("test_enum"), "test_string": obj.get("test_string"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_object_for_multipart_requests_request_marker.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_object_for_multipart_requests_request_marker.py index d87943e6d696..a5c3bfdbb1b5 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_object_for_multipart_requests_request_marker.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/test_object_for_multipart_requests_request_marker.py @@ -79,11 +79,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in TestObjectForMultipartRequestsRequestMarker) in the input: " + _key) - _obj = cls.model_validate({ "name": obj.get("name") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/tiger.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/tiger.py index e2104073b4fb..bf8cbf0596ae 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/tiger.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/tiger.py @@ -79,11 +79,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Tiger) in the input: " + _key) - _obj = cls.model_validate({ "skill": obj.get("skill") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py index 5cfaf6039826..e50edf2efa85 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py @@ -89,11 +89,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in UnnamedDictWithAdditionalModelListProperties) in the input: " + _key) - _obj = cls.model_validate({ "dictProperty": dict( (_k, diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py index 3213070bb338..477dcae27c7c 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py @@ -79,11 +79,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in UnnamedDictWithAdditionalStringListProperties) in the input: " + _key) - _obj = cls.model_validate({ "dictProperty": obj.get("dictProperty") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/upload_file_with_additional_properties_request_object.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/upload_file_with_additional_properties_request_object.py index 529f50aaa5c8..9040618ac0d7 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/upload_file_with_additional_properties_request_object.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/upload_file_with_additional_properties_request_object.py @@ -79,11 +79,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in UploadFileWithAdditionalPropertiesRequestObject) in the input: " + _key) - _obj = cls.model_validate({ "name": obj.get("name") }) diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/user.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/user.py index 9bbf8fdad6a6..45e0a66f89dd 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/user.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/user.py @@ -86,11 +86,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in User) in the input: " + _key) - _obj = cls.model_validate({ "id": obj.get("id"), "username": obj.get("username"), diff --git a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/with_nested_one_of.py b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/with_nested_one_of.py index 29c45b0360dd..f2cd8b7a3a30 100644 --- a/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/with_nested_one_of.py +++ b/samples/openapi3/client/petstore/python-aiohttp/petstore_api/models/with_nested_one_of.py @@ -86,11 +86,6 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in WithNestedOneOf) in the input: " + _key) - _obj = cls.model_validate({ "size": obj.get("size"), "nested_pig": Pig.from_dict(obj["nested_pig"]) if obj.get("nested_pig") is not None else None, diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/additional_properties_class.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/additional_properties_class.py index 4dd4bac8768d..c53af3e2ca67 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/additional_properties_class.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/additional_properties_class.py @@ -64,11 +64,6 @@ def from_dict(cls, obj: dict) -> AdditionalPropertiesClass: if not isinstance(obj, dict): return AdditionalPropertiesClass.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in AdditionalPropertiesClass) in the input: " + obj) - _obj = AdditionalPropertiesClass.parse_obj({ "map_property": obj.get("map_property"), "map_of_map_property": obj.get("map_of_map_property") diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/all_of_super_model.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/all_of_super_model.py index d1f41c7c9ab9..88fdc0e20116 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/all_of_super_model.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/all_of_super_model.py @@ -63,11 +63,6 @@ def from_dict(cls, obj: dict) -> AllOfSuperModel: if not isinstance(obj, dict): return AllOfSuperModel.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in AllOfSuperModel) in the input: " + obj) - _obj = AllOfSuperModel.parse_obj({ "name": obj.get("_name") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/all_of_with_single_ref.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/all_of_with_single_ref.py index 73a08e910e4c..a02cecd8e346 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/all_of_with_single_ref.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/all_of_with_single_ref.py @@ -65,11 +65,6 @@ def from_dict(cls, obj: dict) -> AllOfWithSingleRef: if not isinstance(obj, dict): return AllOfWithSingleRef.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in AllOfWithSingleRef) in the input: " + obj) - _obj = AllOfWithSingleRef.parse_obj({ "username": obj.get("username"), "single_ref_type": obj.get("SingleRefType") diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/api_response.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/api_response.py index 7a9069ff086d..2c58b8b9ccb8 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/api_response.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/api_response.py @@ -65,11 +65,6 @@ def from_dict(cls, obj: dict) -> ApiResponse: if not isinstance(obj, dict): return ApiResponse.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in ApiResponse) in the input: " + obj) - _obj = ApiResponse.parse_obj({ "code": obj.get("code"), "type": obj.get("type"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_array_of_model.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_array_of_model.py index a666e3b413f0..6f67b220ccf1 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_array_of_model.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_array_of_model.py @@ -73,11 +73,6 @@ def from_dict(cls, obj: dict) -> ArrayOfArrayOfModel: if not isinstance(obj, dict): return ArrayOfArrayOfModel.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in ArrayOfArrayOfModel) in the input: " + obj) - _obj = ArrayOfArrayOfModel.parse_obj({ "another_property": [ [Tag.from_dict(_inner_item) for _inner_item in _item] diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_array_of_number_only.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_array_of_number_only.py index d232781a9e7b..3c160bb53034 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_array_of_number_only.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_array_of_number_only.py @@ -63,11 +63,6 @@ def from_dict(cls, obj: dict) -> ArrayOfArrayOfNumberOnly: if not isinstance(obj, dict): return ArrayOfArrayOfNumberOnly.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in ArrayOfArrayOfNumberOnly) in the input: " + obj) - _obj = ArrayOfArrayOfNumberOnly.parse_obj({ "array_array_number": obj.get("ArrayArrayNumber") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_number_only.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_number_only.py index 6ce44b01f475..ce172811448a 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_number_only.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_of_number_only.py @@ -63,11 +63,6 @@ def from_dict(cls, obj: dict) -> ArrayOfNumberOnly: if not isinstance(obj, dict): return ArrayOfNumberOnly.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in ArrayOfNumberOnly) in the input: " + obj) - _obj = ArrayOfNumberOnly.parse_obj({ "array_number": obj.get("ArrayNumber") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_test.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_test.py index 36849e6d7b0a..206b34dc4021 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_test.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/array_test.py @@ -76,11 +76,6 @@ def from_dict(cls, obj: dict) -> ArrayTest: if not isinstance(obj, dict): return ArrayTest.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in ArrayTest) in the input: " + obj) - _obj = ArrayTest.parse_obj({ "array_of_string": obj.get("array_of_string"), "array_of_nullable_float": obj.get("array_of_nullable_float"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/basque_pig.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/basque_pig.py index a10b247d207e..6efcc0a9b659 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/basque_pig.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/basque_pig.py @@ -64,11 +64,6 @@ def from_dict(cls, obj: dict) -> BasquePig: if not isinstance(obj, dict): return BasquePig.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in BasquePig) in the input: " + obj) - _obj = BasquePig.parse_obj({ "class_name": obj.get("className"), "color": obj.get("color") diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/bathing.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/bathing.py index b5feb44f2ac0..753acf8d6948 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/bathing.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/bathing.py @@ -79,11 +79,6 @@ def from_dict(cls, obj: dict) -> Bathing: if not isinstance(obj, dict): return Bathing.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Bathing) in the input: " + obj) - _obj = Bathing.parse_obj({ "task_name": obj.get("task_name"), "function_name": obj.get("function_name"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/capitalization.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/capitalization.py index cfc5515b4ea8..9191b76ccd71 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/capitalization.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/capitalization.py @@ -68,11 +68,6 @@ def from_dict(cls, obj: dict) -> Capitalization: if not isinstance(obj, dict): return Capitalization.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Capitalization) in the input: " + obj) - _obj = Capitalization.parse_obj({ "small_camel": obj.get("smallCamel"), "capital_camel": obj.get("CapitalCamel"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/cat.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/cat.py index ae8449fa1899..efff0890a41a 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/cat.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/cat.py @@ -64,11 +64,6 @@ def from_dict(cls, obj: dict) -> Cat: if not isinstance(obj, dict): return Cat.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Cat) in the input: " + obj) - _obj = Cat.parse_obj({ "class_name": obj.get("className"), "color": obj.get("color") if obj.get("color") is not None else 'red', diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/category.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/category.py index 620ccd2016fe..86a10a8683cf 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/category.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/category.py @@ -64,11 +64,6 @@ def from_dict(cls, obj: dict) -> Category: if not isinstance(obj, dict): return Category.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Category) in the input: " + obj) - _obj = Category.parse_obj({ "id": obj.get("id"), "name": obj.get("name") if obj.get("name") is not None else 'default-name' diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/circular_all_of_ref.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/circular_all_of_ref.py index d8b579195518..9177641a136f 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/circular_all_of_ref.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/circular_all_of_ref.py @@ -71,11 +71,6 @@ def from_dict(cls, obj: dict) -> CircularAllOfRef: if not isinstance(obj, dict): return CircularAllOfRef.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in CircularAllOfRef) in the input: " + obj) - _obj = CircularAllOfRef.parse_obj({ "name": obj.get("_name"), "second_circular_all_of_ref": [SecondCircularAllOfRef.from_dict(_item) for _item in obj.get("secondCircularAllOfRef")] if obj.get("secondCircularAllOfRef") is not None else None diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/circular_reference_model.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/circular_reference_model.py index 020fdbb965ff..6a9956f5af3b 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/circular_reference_model.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/circular_reference_model.py @@ -67,11 +67,6 @@ def from_dict(cls, obj: dict) -> CircularReferenceModel: if not isinstance(obj, dict): return CircularReferenceModel.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in CircularReferenceModel) in the input: " + obj) - _obj = CircularReferenceModel.parse_obj({ "size": obj.get("size"), "nested": FirstRef.from_dict(obj.get("nested")) if obj.get("nested") is not None else None diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/class_model.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/class_model.py index ad9fcd965f91..01e00e6328aa 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/class_model.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/class_model.py @@ -63,11 +63,6 @@ def from_dict(cls, obj: dict) -> ClassModel: if not isinstance(obj, dict): return ClassModel.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in ClassModel) in the input: " + obj) - _obj = ClassModel.parse_obj({ "var_class": obj.get("_class") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/client.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/client.py index 28ea887c08b9..01f60acef507 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/client.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/client.py @@ -63,11 +63,6 @@ def from_dict(cls, obj: dict) -> Client: if not isinstance(obj, dict): return Client.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Client) in the input: " + obj) - _obj = Client.parse_obj({ "client": obj.get("client") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/creature_info.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/creature_info.py index de2dfaca6e3e..327ce9bc4fbc 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/creature_info.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/creature_info.py @@ -63,11 +63,6 @@ def from_dict(cls, obj: dict) -> CreatureInfo: if not isinstance(obj, dict): return CreatureInfo.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in CreatureInfo) in the input: " + obj) - _obj = CreatureInfo.parse_obj({ "name": obj.get("name") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/danish_pig.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/danish_pig.py index 9c9403334f32..b53aa7221874 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/danish_pig.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/danish_pig.py @@ -64,11 +64,6 @@ def from_dict(cls, obj: dict) -> DanishPig: if not isinstance(obj, dict): return DanishPig.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in DanishPig) in the input: " + obj) - _obj = DanishPig.parse_obj({ "class_name": obj.get("className"), "size": obj.get("size") diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/deprecated_object.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/deprecated_object.py index b074764f4d60..9ce72f88d48b 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/deprecated_object.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/deprecated_object.py @@ -63,11 +63,6 @@ def from_dict(cls, obj: dict) -> DeprecatedObject: if not isinstance(obj, dict): return DeprecatedObject.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in DeprecatedObject) in the input: " + obj) - _obj = DeprecatedObject.parse_obj({ "name": obj.get("name") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/discriminator_all_of_sub.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/discriminator_all_of_sub.py index 327a4284068d..65d54ea8d1a6 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/discriminator_all_of_sub.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/discriminator_all_of_sub.py @@ -63,11 +63,6 @@ def from_dict(cls, obj: dict) -> DiscriminatorAllOfSub: if not isinstance(obj, dict): return DiscriminatorAllOfSub.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in DiscriminatorAllOfSub) in the input: " + obj) - _obj = DiscriminatorAllOfSub.parse_obj({ "element_type": obj.get("elementType") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/dog.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/dog.py index b03c0d516366..f0533a50e495 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/dog.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/dog.py @@ -64,11 +64,6 @@ def from_dict(cls, obj: dict) -> Dog: if not isinstance(obj, dict): return Dog.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Dog) in the input: " + obj) - _obj = Dog.parse_obj({ "class_name": obj.get("className"), "color": obj.get("color") if obj.get("color") is not None else 'red', diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/dummy_model.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/dummy_model.py index 34247cd806df..8e4db12e5c92 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/dummy_model.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/dummy_model.py @@ -67,11 +67,6 @@ def from_dict(cls, obj: dict) -> DummyModel: if not isinstance(obj, dict): return DummyModel.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in DummyModel) in the input: " + obj) - _obj = DummyModel.parse_obj({ "category": obj.get("category"), "self_ref": SelfReferenceModel.from_dict(obj.get("self_ref")) if obj.get("self_ref") is not None else None diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/enum_arrays.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/enum_arrays.py index 1edc760b9a43..05d532614fff 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/enum_arrays.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/enum_arrays.py @@ -85,11 +85,6 @@ def from_dict(cls, obj: dict) -> EnumArrays: if not isinstance(obj, dict): return EnumArrays.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in EnumArrays) in the input: " + obj) - _obj = EnumArrays.parse_obj({ "just_symbol": obj.get("just_symbol"), "array_enum": obj.get("array_enum") diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/enum_test.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/enum_test.py index df18966304d6..40247e276473 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/enum_test.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/enum_test.py @@ -153,11 +153,6 @@ def from_dict(cls, obj: dict) -> EnumTest: if not isinstance(obj, dict): return EnumTest.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in EnumTest) in the input: " + obj) - _obj = EnumTest.parse_obj({ "enum_string": obj.get("enum_string"), "enum_string_required": obj.get("enum_string_required"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/feeding.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/feeding.py index 1fb706a22f2f..3013f7d57d00 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/feeding.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/feeding.py @@ -79,11 +79,6 @@ def from_dict(cls, obj: dict) -> Feeding: if not isinstance(obj, dict): return Feeding.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Feeding) in the input: " + obj) - _obj = Feeding.parse_obj({ "task_name": obj.get("task_name"), "function_name": obj.get("function_name"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/field.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/field.py index 770be284bee3..f37f521c0564 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/field.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/field.py @@ -63,11 +63,6 @@ def from_dict(cls, obj: dict) -> Field: if not isinstance(obj, dict): return Field.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Field) in the input: " + obj) - _obj = Field.parse_obj({ "field": obj.get("field") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/file.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/file.py index 01f13383428c..3d2e4e288bf5 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/file.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/file.py @@ -63,11 +63,6 @@ def from_dict(cls, obj: dict) -> File: if not isinstance(obj, dict): return File.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in File) in the input: " + obj) - _obj = File.parse_obj({ "source_uri": obj.get("sourceURI") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/file_schema_test_class.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/file_schema_test_class.py index 2e7c8f4d09cf..32058bd16fa0 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/file_schema_test_class.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/file_schema_test_class.py @@ -75,11 +75,6 @@ def from_dict(cls, obj: dict) -> FileSchemaTestClass: if not isinstance(obj, dict): return FileSchemaTestClass.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in FileSchemaTestClass) in the input: " + obj) - _obj = FileSchemaTestClass.parse_obj({ "file": File.from_dict(obj.get("file")) if obj.get("file") is not None else None, "files": [File.from_dict(_item) for _item in obj.get("files")] if obj.get("files") is not None else None diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/first_ref.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/first_ref.py index 45b22e3d566d..ace84a5bcb84 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/first_ref.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/first_ref.py @@ -67,11 +67,6 @@ def from_dict(cls, obj: dict) -> FirstRef: if not isinstance(obj, dict): return FirstRef.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in FirstRef) in the input: " + obj) - _obj = FirstRef.parse_obj({ "category": obj.get("category"), "self_ref": SecondRef.from_dict(obj.get("self_ref")) if obj.get("self_ref") is not None else None diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/foo.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/foo.py index 928c6abb8a78..fc58b159e5f5 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/foo.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/foo.py @@ -63,11 +63,6 @@ def from_dict(cls, obj: dict) -> Foo: if not isinstance(obj, dict): return Foo.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Foo) in the input: " + obj) - _obj = Foo.parse_obj({ "bar": obj.get("bar") if obj.get("bar") is not None else 'bar' }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/foo_get_default_response.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/foo_get_default_response.py index b3cb9eeca843..e792358dc002 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/foo_get_default_response.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/foo_get_default_response.py @@ -67,11 +67,6 @@ def from_dict(cls, obj: dict) -> FooGetDefaultResponse: if not isinstance(obj, dict): return FooGetDefaultResponse.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in FooGetDefaultResponse) in the input: " + obj) - _obj = FooGetDefaultResponse.parse_obj({ "string": Foo.from_dict(obj.get("string")) if obj.get("string") is not None else None }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/format_test.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/format_test.py index 1ca788e29035..e8ba23b7243a 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/format_test.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/format_test.py @@ -119,11 +119,6 @@ def from_dict(cls, obj: dict) -> FormatTest: if not isinstance(obj, dict): return FormatTest.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in FormatTest) in the input: " + obj) - _obj = FormatTest.parse_obj({ "integer": obj.get("integer"), "int32": obj.get("int32"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/has_only_read_only.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/has_only_read_only.py index f6567a36f4d0..5a6dd7857d12 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/has_only_read_only.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/has_only_read_only.py @@ -66,11 +66,6 @@ def from_dict(cls, obj: dict) -> HasOnlyReadOnly: if not isinstance(obj, dict): return HasOnlyReadOnly.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in HasOnlyReadOnly) in the input: " + obj) - _obj = HasOnlyReadOnly.parse_obj({ "bar": obj.get("bar"), "foo": obj.get("foo") diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/health_check_result.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/health_check_result.py index 029897a16f85..a914e4ffeec4 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/health_check_result.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/health_check_result.py @@ -68,11 +68,6 @@ def from_dict(cls, obj: dict) -> HealthCheckResult: if not isinstance(obj, dict): return HealthCheckResult.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in HealthCheckResult) in the input: " + obj) - _obj = HealthCheckResult.parse_obj({ "nullable_message": obj.get("NullableMessage") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/hunting_dog.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/hunting_dog.py index 030c0b83dd5d..21df0725400d 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/hunting_dog.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/hunting_dog.py @@ -68,11 +68,6 @@ def from_dict(cls, obj: dict) -> HuntingDog: if not isinstance(obj, dict): return HuntingDog.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in HuntingDog) in the input: " + obj) - _obj = HuntingDog.parse_obj({ "info": CreatureInfo.from_dict(obj.get("info")) if obj.get("info") is not None else None, "type": obj.get("type"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/info.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/info.py index 698c93fcd6a4..a181034ea313 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/info.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/info.py @@ -67,11 +67,6 @@ def from_dict(cls, obj: dict) -> Info: if not isinstance(obj, dict): return Info.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Info) in the input: " + obj) - _obj = Info.parse_obj({ "type_name": obj.get("_typeName"), "val": BaseDiscriminator.from_dict(obj.get("val")) if obj.get("val") is not None else None diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/inner_dict_with_property.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/inner_dict_with_property.py index 5c3bfc291370..a455a5bb59dd 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/inner_dict_with_property.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/inner_dict_with_property.py @@ -63,11 +63,6 @@ def from_dict(cls, obj: dict) -> InnerDictWithProperty: if not isinstance(obj, dict): return InnerDictWithProperty.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in InnerDictWithProperty) in the input: " + obj) - _obj = InnerDictWithProperty.parse_obj({ "a_property": obj.get("aProperty") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/input_all_of.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/input_all_of.py index 96b2c56f2057..03990b32988f 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/input_all_of.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/input_all_of.py @@ -71,11 +71,6 @@ def from_dict(cls, obj: dict) -> InputAllOf: if not isinstance(obj, dict): return InputAllOf.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in InputAllOf) in the input: " + obj) - _obj = InputAllOf.parse_obj({ "some_data": dict( (_k, Tag.from_dict(_v)) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/list_class.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/list_class.py index 9cff751c3955..23aebf15d17d 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/list_class.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/list_class.py @@ -63,11 +63,6 @@ def from_dict(cls, obj: dict) -> ListClass: if not isinstance(obj, dict): return ListClass.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in ListClass) in the input: " + obj) - _obj = ListClass.parse_obj({ "var_123_list": obj.get("123-list") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/map_of_array_of_model.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/map_of_array_of_model.py index 497ac831dd99..3e0c5f2f782f 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/map_of_array_of_model.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/map_of_array_of_model.py @@ -73,11 +73,6 @@ def from_dict(cls, obj: dict) -> MapOfArrayOfModel: if not isinstance(obj, dict): return MapOfArrayOfModel.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in MapOfArrayOfModel) in the input: " + obj) - _obj = MapOfArrayOfModel.parse_obj({ "shop_id_to_org_online_lip_map": dict( (_k, diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/map_test.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/map_test.py index 5b0f552aafda..ce853d3d77b1 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/map_test.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/map_test.py @@ -76,11 +76,6 @@ def from_dict(cls, obj: dict) -> MapTest: if not isinstance(obj, dict): return MapTest.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in MapTest) in the input: " + obj) - _obj = MapTest.parse_obj({ "map_map_of_string": obj.get("map_map_of_string"), "map_of_enum_string": obj.get("map_of_enum_string"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/mixed_properties_and_additional_properties_class.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/mixed_properties_and_additional_properties_class.py index 812582941ca7..59b1adeee43b 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/mixed_properties_and_additional_properties_class.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/mixed_properties_and_additional_properties_class.py @@ -73,11 +73,6 @@ def from_dict(cls, obj: dict) -> MixedPropertiesAndAdditionalPropertiesClass: if not isinstance(obj, dict): return MixedPropertiesAndAdditionalPropertiesClass.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in MixedPropertiesAndAdditionalPropertiesClass) in the input: " + obj) - _obj = MixedPropertiesAndAdditionalPropertiesClass.parse_obj({ "uuid": obj.get("uuid"), "date_time": obj.get("dateTime"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/model200_response.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/model200_response.py index 20bb4653d4c8..7efca1e60410 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/model200_response.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/model200_response.py @@ -64,11 +64,6 @@ def from_dict(cls, obj: dict) -> Model200Response: if not isinstance(obj, dict): return Model200Response.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Model200Response) in the input: " + obj) - _obj = Model200Response.parse_obj({ "name": obj.get("name"), "var_class": obj.get("class") diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/model_return.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/model_return.py index 8cdfde948cdf..69be3ef4b951 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/model_return.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/model_return.py @@ -63,11 +63,6 @@ def from_dict(cls, obj: dict) -> ModelReturn: if not isinstance(obj, dict): return ModelReturn.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in ModelReturn) in the input: " + obj) - _obj = ModelReturn.parse_obj({ "var_return": obj.get("return") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/multi_arrays.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/multi_arrays.py index e221ce90744e..ce0acf8c8fda 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/multi_arrays.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/multi_arrays.py @@ -80,11 +80,6 @@ def from_dict(cls, obj: dict) -> MultiArrays: if not isinstance(obj, dict): return MultiArrays.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in MultiArrays) in the input: " + obj) - _obj = MultiArrays.parse_obj({ "tags": [Tag.from_dict(_item) for _item in obj.get("tags")] if obj.get("tags") is not None else None, "files": [File.from_dict(_item) for _item in obj.get("files")] if obj.get("files") is not None else None diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/name.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/name.py index 65dbff22f3e1..200ad652b342 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/name.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/name.py @@ -68,11 +68,6 @@ def from_dict(cls, obj: dict) -> Name: if not isinstance(obj, dict): return Name.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Name) in the input: " + obj) - _obj = Name.parse_obj({ "name": obj.get("name"), "snake_case": obj.get("snake_case"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/nullable_property.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/nullable_property.py index 224fb59c768c..2312fbbbf5fd 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/nullable_property.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/nullable_property.py @@ -79,11 +79,6 @@ def from_dict(cls, obj: dict) -> NullableProperty: if not isinstance(obj, dict): return NullableProperty.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in NullableProperty) in the input: " + obj) - _obj = NullableProperty.parse_obj({ "id": obj.get("id"), "name": obj.get("name") diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/number_only.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/number_only.py index 35665e623803..b194840c0c1a 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/number_only.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/number_only.py @@ -63,11 +63,6 @@ def from_dict(cls, obj: dict) -> NumberOnly: if not isinstance(obj, dict): return NumberOnly.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in NumberOnly) in the input: " + obj) - _obj = NumberOnly.parse_obj({ "just_number": obj.get("JustNumber") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/object_to_test_additional_properties.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/object_to_test_additional_properties.py index 03c0c70b52ca..b78667ae0902 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/object_to_test_additional_properties.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/object_to_test_additional_properties.py @@ -63,11 +63,6 @@ def from_dict(cls, obj: dict) -> ObjectToTestAdditionalProperties: if not isinstance(obj, dict): return ObjectToTestAdditionalProperties.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in ObjectToTestAdditionalProperties) in the input: " + obj) - _obj = ObjectToTestAdditionalProperties.parse_obj({ "var_property": obj.get("property") if obj.get("property") is not None else False }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/object_with_deprecated_fields.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/object_with_deprecated_fields.py index 0a2ec666823f..e976e40738bd 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/object_with_deprecated_fields.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/object_with_deprecated_fields.py @@ -70,11 +70,6 @@ def from_dict(cls, obj: dict) -> ObjectWithDeprecatedFields: if not isinstance(obj, dict): return ObjectWithDeprecatedFields.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in ObjectWithDeprecatedFields) in the input: " + obj) - _obj = ObjectWithDeprecatedFields.parse_obj({ "uuid": obj.get("uuid"), "id": obj.get("id"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/order.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/order.py index c3fb545e40f4..fb76b99915a5 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/order.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/order.py @@ -78,11 +78,6 @@ def from_dict(cls, obj: dict) -> Order: if not isinstance(obj, dict): return Order.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Order) in the input: " + obj) - _obj = Order.parse_obj({ "id": obj.get("id"), "pet_id": obj.get("petId"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/outer_composite.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/outer_composite.py index 16befb999a53..63627c3d0fde 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/outer_composite.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/outer_composite.py @@ -65,11 +65,6 @@ def from_dict(cls, obj: dict) -> OuterComposite: if not isinstance(obj, dict): return OuterComposite.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in OuterComposite) in the input: " + obj) - _obj = OuterComposite.parse_obj({ "my_number": obj.get("my_number"), "my_string": obj.get("my_string"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/outer_object_with_enum_property.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/outer_object_with_enum_property.py index e942d9dc650e..c4ae68e5510f 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/outer_object_with_enum_property.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/outer_object_with_enum_property.py @@ -71,11 +71,6 @@ def from_dict(cls, obj: dict) -> OuterObjectWithEnumProperty: if not isinstance(obj, dict): return OuterObjectWithEnumProperty.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in OuterObjectWithEnumProperty) in the input: " + obj) - _obj = OuterObjectWithEnumProperty.parse_obj({ "str_value": obj.get("str_value"), "value": obj.get("value") diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/parent.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/parent.py index 8bbe230a6e26..5abdaa381149 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/parent.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/parent.py @@ -71,11 +71,6 @@ def from_dict(cls, obj: dict) -> Parent: if not isinstance(obj, dict): return Parent.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Parent) in the input: " + obj) - _obj = Parent.parse_obj({ "optional_dict": dict( (_k, InnerDictWithProperty.from_dict(_v)) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/parent_with_optional_dict.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/parent_with_optional_dict.py index 438021c74966..1ef787705030 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/parent_with_optional_dict.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/parent_with_optional_dict.py @@ -71,11 +71,6 @@ def from_dict(cls, obj: dict) -> ParentWithOptionalDict: if not isinstance(obj, dict): return ParentWithOptionalDict.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in ParentWithOptionalDict) in the input: " + obj) - _obj = ParentWithOptionalDict.parse_obj({ "optional_dict": dict( (_k, InnerDictWithProperty.from_dict(_v)) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/pet.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/pet.py index f9001a068eb8..112508adac5a 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/pet.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/pet.py @@ -90,11 +90,6 @@ def from_dict(cls, obj: dict) -> Pet: if not isinstance(obj, dict): return Pet.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Pet) in the input: " + obj) - _obj = Pet.parse_obj({ "id": obj.get("id"), "category": Category.from_dict(obj.get("category")) if obj.get("category") is not None else None, diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/pony_sizes.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/pony_sizes.py index 4b9d557eac71..d7c0716b43db 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/pony_sizes.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/pony_sizes.py @@ -64,11 +64,6 @@ def from_dict(cls, obj: dict) -> PonySizes: if not isinstance(obj, dict): return PonySizes.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in PonySizes) in the input: " + obj) - _obj = PonySizes.parse_obj({ "type": obj.get("type") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/poop_cleaning.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/poop_cleaning.py index 4b13e6e02785..9bf76733284f 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/poop_cleaning.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/poop_cleaning.py @@ -79,11 +79,6 @@ def from_dict(cls, obj: dict) -> PoopCleaning: if not isinstance(obj, dict): return PoopCleaning.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in PoopCleaning) in the input: " + obj) - _obj = PoopCleaning.parse_obj({ "task_name": obj.get("task_name"), "function_name": obj.get("function_name"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/primitive_string.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/primitive_string.py index 5d32d276071f..4d84353e6035 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/primitive_string.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/primitive_string.py @@ -64,11 +64,6 @@ def from_dict(cls, obj: dict) -> PrimitiveString: if not isinstance(obj, dict): return PrimitiveString.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in PrimitiveString) in the input: " + obj) - _obj = PrimitiveString.parse_obj({ "type_name": obj.get("_typeName"), "value": obj.get("_value") diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/property_map.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/property_map.py index 1a6a31a77e5e..9d3d06512b33 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/property_map.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/property_map.py @@ -71,11 +71,6 @@ def from_dict(cls, obj: dict) -> PropertyMap: if not isinstance(obj, dict): return PropertyMap.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in PropertyMap) in the input: " + obj) - _obj = PropertyMap.parse_obj({ "some_data": dict( (_k, Tag.from_dict(_v)) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/property_name_collision.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/property_name_collision.py index 05a7f7cecaeb..43d74bed7c56 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/property_name_collision.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/property_name_collision.py @@ -65,11 +65,6 @@ def from_dict(cls, obj: dict) -> PropertyNameCollision: if not isinstance(obj, dict): return PropertyNameCollision.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in PropertyNameCollision) in the input: " + obj) - _obj = PropertyNameCollision.parse_obj({ "type": obj.get("_type"), "type": obj.get("type"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/read_only_first.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/read_only_first.py index ef6b24b9a8c4..da66589ee79c 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/read_only_first.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/read_only_first.py @@ -65,11 +65,6 @@ def from_dict(cls, obj: dict) -> ReadOnlyFirst: if not isinstance(obj, dict): return ReadOnlyFirst.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in ReadOnlyFirst) in the input: " + obj) - _obj = ReadOnlyFirst.parse_obj({ "bar": obj.get("bar"), "baz": obj.get("baz") diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/second_circular_all_of_ref.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/second_circular_all_of_ref.py index 44ff7db768f8..2d000534484d 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/second_circular_all_of_ref.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/second_circular_all_of_ref.py @@ -71,11 +71,6 @@ def from_dict(cls, obj: dict) -> SecondCircularAllOfRef: if not isinstance(obj, dict): return SecondCircularAllOfRef.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in SecondCircularAllOfRef) in the input: " + obj) - _obj = SecondCircularAllOfRef.parse_obj({ "name": obj.get("_name"), "circular_all_of_ref": [CircularAllOfRef.from_dict(_item) for _item in obj.get("circularAllOfRef")] if obj.get("circularAllOfRef") is not None else None diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/second_ref.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/second_ref.py index e34d1b3c0083..0c4f70eb9395 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/second_ref.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/second_ref.py @@ -67,11 +67,6 @@ def from_dict(cls, obj: dict) -> SecondRef: if not isinstance(obj, dict): return SecondRef.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in SecondRef) in the input: " + obj) - _obj = SecondRef.parse_obj({ "category": obj.get("category"), "circular_ref": CircularReferenceModel.from_dict(obj.get("circular_ref")) if obj.get("circular_ref") is not None else None diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/self_reference_model.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/self_reference_model.py index d1024f4882b9..f7470db995e6 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/self_reference_model.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/self_reference_model.py @@ -67,11 +67,6 @@ def from_dict(cls, obj: dict) -> SelfReferenceModel: if not isinstance(obj, dict): return SelfReferenceModel.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in SelfReferenceModel) in the input: " + obj) - _obj = SelfReferenceModel.parse_obj({ "size": obj.get("size"), "nested": DummyModel.from_dict(obj.get("nested")) if obj.get("nested") is not None else None diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/special_model_name.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/special_model_name.py index 805cc74b6887..16c328fa5506 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/special_model_name.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/special_model_name.py @@ -63,11 +63,6 @@ def from_dict(cls, obj: dict) -> SpecialModelName: if not isinstance(obj, dict): return SpecialModelName.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in SpecialModelName) in the input: " + obj) - _obj = SpecialModelName.parse_obj({ "special_property_name": obj.get("$special[property.name]") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/special_name.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/special_name.py index 6f77aedfb18a..1ce291e969be 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/special_name.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/special_name.py @@ -79,11 +79,6 @@ def from_dict(cls, obj: dict) -> SpecialName: if not isinstance(obj, dict): return SpecialName.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in SpecialName) in the input: " + obj) - _obj = SpecialName.parse_obj({ "var_property": obj.get("property"), "var_async": Category.from_dict(obj.get("async")) if obj.get("async") is not None else None, diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/tag.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/tag.py index ded7a2487009..45605d239331 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/tag.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/tag.py @@ -64,11 +64,6 @@ def from_dict(cls, obj: dict) -> Tag: if not isinstance(obj, dict): return Tag.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Tag) in the input: " + obj) - _obj = Tag.parse_obj({ "id": obj.get("id"), "name": obj.get("name") diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/task.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/task.py index b9014315d95b..2fb988a0a5d5 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/task.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/task.py @@ -68,11 +68,6 @@ def from_dict(cls, obj: dict) -> Task: if not isinstance(obj, dict): return Task.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Task) in the input: " + obj) - _obj = Task.parse_obj({ "id": obj.get("id"), "activity": TaskActivity.from_dict(obj.get("activity")) if obj.get("activity") is not None else None diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_error_responses_with_model400_response.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_error_responses_with_model400_response.py index f2c94872ff1e..c4904af2905c 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_error_responses_with_model400_response.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_error_responses_with_model400_response.py @@ -63,11 +63,6 @@ def from_dict(cls, obj: dict) -> TestErrorResponsesWithModel400Response: if not isinstance(obj, dict): return TestErrorResponsesWithModel400Response.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in TestErrorResponsesWithModel400Response) in the input: " + obj) - _obj = TestErrorResponsesWithModel400Response.parse_obj({ "reason400": obj.get("reason400") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_error_responses_with_model404_response.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_error_responses_with_model404_response.py index 82f16a056504..96b5f6c58715 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_error_responses_with_model404_response.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_error_responses_with_model404_response.py @@ -63,11 +63,6 @@ def from_dict(cls, obj: dict) -> TestErrorResponsesWithModel404Response: if not isinstance(obj, dict): return TestErrorResponsesWithModel404Response.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in TestErrorResponsesWithModel404Response) in the input: " + obj) - _obj = TestErrorResponsesWithModel404Response.parse_obj({ "reason404": obj.get("reason404") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_model_with_enum_default.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_model_with_enum_default.py index 0f373f65b7ec..861926379409 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_model_with_enum_default.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_model_with_enum_default.py @@ -79,11 +79,6 @@ def from_dict(cls, obj: dict) -> TestModelWithEnumDefault: if not isinstance(obj, dict): return TestModelWithEnumDefault.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in TestModelWithEnumDefault) in the input: " + obj) - _obj = TestModelWithEnumDefault.parse_obj({ "test_enum": obj.get("test_enum"), "test_string": obj.get("test_string"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_object_for_multipart_requests_request_marker.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_object_for_multipart_requests_request_marker.py index 32782da0f9d9..957ccc5af28f 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_object_for_multipart_requests_request_marker.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/test_object_for_multipart_requests_request_marker.py @@ -63,11 +63,6 @@ def from_dict(cls, obj: dict) -> TestObjectForMultipartRequestsRequestMarker: if not isinstance(obj, dict): return TestObjectForMultipartRequestsRequestMarker.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in TestObjectForMultipartRequestsRequestMarker) in the input: " + obj) - _obj = TestObjectForMultipartRequestsRequestMarker.parse_obj({ "name": obj.get("name") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/tiger.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/tiger.py index c629915454f6..88b2f3c6a04f 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/tiger.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/tiger.py @@ -63,11 +63,6 @@ def from_dict(cls, obj: dict) -> Tiger: if not isinstance(obj, dict): return Tiger.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Tiger) in the input: " + obj) - _obj = Tiger.parse_obj({ "skill": obj.get("skill") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py index 9fa8ca79677d..f4e22caa9d25 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/unnamed_dict_with_additional_model_list_properties.py @@ -73,11 +73,6 @@ def from_dict(cls, obj: dict) -> UnnamedDictWithAdditionalModelListProperties: if not isinstance(obj, dict): return UnnamedDictWithAdditionalModelListProperties.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in UnnamedDictWithAdditionalModelListProperties) in the input: " + obj) - _obj = UnnamedDictWithAdditionalModelListProperties.parse_obj({ "dict_property": dict( (_k, diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py index 76718e8e0803..af559dfa890c 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/unnamed_dict_with_additional_string_list_properties.py @@ -63,11 +63,6 @@ def from_dict(cls, obj: dict) -> UnnamedDictWithAdditionalStringListProperties: if not isinstance(obj, dict): return UnnamedDictWithAdditionalStringListProperties.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in UnnamedDictWithAdditionalStringListProperties) in the input: " + obj) - _obj = UnnamedDictWithAdditionalStringListProperties.parse_obj({ "dict_property": obj.get("dictProperty") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/upload_file_with_additional_properties_request_object.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/upload_file_with_additional_properties_request_object.py index 76bf1757ce40..bafe5045c0d5 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/upload_file_with_additional_properties_request_object.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/upload_file_with_additional_properties_request_object.py @@ -63,11 +63,6 @@ def from_dict(cls, obj: dict) -> UploadFileWithAdditionalPropertiesRequestObject if not isinstance(obj, dict): return UploadFileWithAdditionalPropertiesRequestObject.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in UploadFileWithAdditionalPropertiesRequestObject) in the input: " + obj) - _obj = UploadFileWithAdditionalPropertiesRequestObject.parse_obj({ "name": obj.get("name") }) diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/user.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/user.py index 42678a7ee227..df5086cb4573 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/user.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/user.py @@ -70,11 +70,6 @@ def from_dict(cls, obj: dict) -> User: if not isinstance(obj, dict): return User.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in User) in the input: " + obj) - _obj = User.parse_obj({ "id": obj.get("id"), "username": obj.get("username"), diff --git a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/with_nested_one_of.py b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/with_nested_one_of.py index 7cd3cce5b455..2fa98ce371e2 100644 --- a/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/with_nested_one_of.py +++ b/samples/openapi3/client/petstore/python-pydantic-v1-aiohttp/petstore_api/models/with_nested_one_of.py @@ -70,11 +70,6 @@ def from_dict(cls, obj: dict) -> WithNestedOneOf: if not isinstance(obj, dict): return WithNestedOneOf.parse_obj(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in WithNestedOneOf) in the input: " + obj) - _obj = WithNestedOneOf.parse_obj({ "size": obj.get("size"), "nested_pig": Pig.from_dict(obj.get("nested_pig")) if obj.get("nested_pig") is not None else None, diff --git a/samples/server/petstore/python-fastapi/src/openapi_server/models/api_response.py b/samples/server/petstore/python-fastapi/src/openapi_server/models/api_response.py index 2ddf9c7f7fe5..441c3b825096 100644 --- a/samples/server/petstore/python-fastapi/src/openapi_server/models/api_response.py +++ b/samples/server/petstore/python-fastapi/src/openapi_server/models/api_response.py @@ -84,11 +84,6 @@ def from_dict(cls, obj: Dict) -> Self: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in ApiResponse) in the input: " + _key) - _obj = cls.model_validate({ "code": obj.get("code"), "type": obj.get("type"), diff --git a/samples/server/petstore/python-fastapi/src/openapi_server/models/category.py b/samples/server/petstore/python-fastapi/src/openapi_server/models/category.py index 655f9035c7d9..48b689cba886 100644 --- a/samples/server/petstore/python-fastapi/src/openapi_server/models/category.py +++ b/samples/server/petstore/python-fastapi/src/openapi_server/models/category.py @@ -94,11 +94,6 @@ def from_dict(cls, obj: Dict) -> Self: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Category) in the input: " + _key) - _obj = cls.model_validate({ "id": obj.get("id"), "name": obj.get("name") diff --git a/samples/server/petstore/python-fastapi/src/openapi_server/models/order.py b/samples/server/petstore/python-fastapi/src/openapi_server/models/order.py index f43fd31c0b15..7a5a38cdb7b4 100644 --- a/samples/server/petstore/python-fastapi/src/openapi_server/models/order.py +++ b/samples/server/petstore/python-fastapi/src/openapi_server/models/order.py @@ -98,11 +98,6 @@ def from_dict(cls, obj: Dict) -> Self: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Order) in the input: " + _key) - _obj = cls.model_validate({ "id": obj.get("id"), "petId": obj.get("petId"), diff --git a/samples/server/petstore/python-fastapi/src/openapi_server/models/pet.py b/samples/server/petstore/python-fastapi/src/openapi_server/models/pet.py index c303d7151e05..450c1b71393f 100644 --- a/samples/server/petstore/python-fastapi/src/openapi_server/models/pet.py +++ b/samples/server/petstore/python-fastapi/src/openapi_server/models/pet.py @@ -109,11 +109,6 @@ def from_dict(cls, obj: Dict) -> Self: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Pet) in the input: " + _key) - _obj = cls.model_validate({ "id": obj.get("id"), "category": Category.from_dict(obj.get("category")) if obj.get("category") is not None else None, diff --git a/samples/server/petstore/python-fastapi/src/openapi_server/models/tag.py b/samples/server/petstore/python-fastapi/src/openapi_server/models/tag.py index 5c6c8da930cf..8b21d362f55c 100644 --- a/samples/server/petstore/python-fastapi/src/openapi_server/models/tag.py +++ b/samples/server/petstore/python-fastapi/src/openapi_server/models/tag.py @@ -83,11 +83,6 @@ def from_dict(cls, obj: Dict) -> Self: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in Tag) in the input: " + _key) - _obj = cls.model_validate({ "id": obj.get("id"), "name": obj.get("name") diff --git a/samples/server/petstore/python-fastapi/src/openapi_server/models/user.py b/samples/server/petstore/python-fastapi/src/openapi_server/models/user.py index abc8332607eb..cb98a57479b5 100644 --- a/samples/server/petstore/python-fastapi/src/openapi_server/models/user.py +++ b/samples/server/petstore/python-fastapi/src/openapi_server/models/user.py @@ -89,11 +89,6 @@ def from_dict(cls, obj: Dict) -> Self: if not isinstance(obj, dict): return cls.model_validate(obj) - # raise errors for additional fields in the input - for _key in obj.keys(): - if _key not in cls.__properties: - raise ValueError("Error due to additional fields (not defined in User) in the input: " + _key) - _obj = cls.model_validate({ "id": obj.get("id"), "username": obj.get("username"),