From 7b32de1bc30ce4da416f82d6d07885971f22baa8 Mon Sep 17 00:00:00 2001 From: Tom E <1036527+thommy101@users.noreply.github.com> Date: Sat, 9 May 2020 14:24:33 +0200 Subject: [PATCH 1/4] [c-sharp] Fix #6225 default values with discriminator --- .../org/openapitools/codegen/languages/CSharpClientCodegen.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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 a12d712c3ffa..340532348fa1 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 @@ -609,7 +609,7 @@ public CodegenModel fromModel(String name, Schema model) { } for (final CodegenProperty property : codegenModel.readWriteVars) { - if (property.defaultValue == null && parentCodegenModel.discriminator != null && property.baseName.equals(parentCodegenModel.discriminator.getPropertyName())) { + if (property.defaultValue == null && parentCodegenModel.discriminator != null && property.name.equals(parentCodegenModel.discriminator.getPropertyName())) { property.defaultValue = "\"" + name + "\""; } } From 0ce5405b04c83f5e77cc9ddad4e3ae611154fdde Mon Sep 17 00:00:00 2001 From: Tom E <1036527+thommy101@users.noreply.github.com> Date: Sat, 9 May 2020 14:26:33 +0200 Subject: [PATCH 2/4] [c-sharp] Update sample files --- .../src/Org.OpenAPITools/Model/Cat.cs | 2 +- .../src/Org.OpenAPITools/Model/Dog.cs | 2 +- .../src/Org.OpenAPITools/Model/Cat.cs | 2 +- .../src/Org.OpenAPITools/Model/Dog.cs | 2 +- .../src/Org.OpenAPITools/Model/Cat.cs | 2 +- .../src/Org.OpenAPITools/Model/Dog.cs | 2 +- .../Org.OpenAPITools.sln | 10 +- .../csharp/OpenAPIClientNetStandard/README.md | 45 +- .../docs/AdditionalPropertiesClass.md | 13 +- .../docs/AnotherFakeApi.md | 8 +- .../docs/DefaultApi.md | 32 +- .../OpenAPIClientNetStandard/docs/EnumTest.md | 3 + .../OpenAPIClientNetStandard/docs/FakeApi.md | 162 +++-- .../docs/FakeClassnameTags123Api.md | 8 +- .../OpenAPIClientNetStandard/docs/Foo.md | 6 +- .../docs/FormatTest.md | 3 +- .../docs/HealthCheckResult.md | 13 + .../docs/InlineObject.md | 6 +- .../docs/InlineObject1.md | 6 +- .../docs/InlineObject2.md | 6 +- .../docs/InlineObject3.md | 22 +- .../docs/InlineObject4.md | 6 +- .../docs/InlineObject5.md | 6 +- .../docs/InlineResponseDefault.md | 6 +- .../docs/NullableClass.md | 24 + .../docs/OuterEnumDefaultValue.md | 12 + .../docs/OuterEnumInteger.md | 12 + .../docs/OuterEnumIntegerDefaultValue.md | 12 + .../OpenAPIClientNetStandard/docs/PetApi.md | 19 +- .../OpenAPIClientNetStandard/docs/StoreApi.md | 10 +- .../OpenAPIClientNetStandard/docs/UserApi.md | 40 +- .../Org.OpenAPITools/Api/AnotherFakeApi.cs | 60 +- .../src/Org.OpenAPITools/Api/DefaultApi.cs | 19 +- .../src/Org.OpenAPITools/Api/FakeApi.cs | 633 +++++++++++------ .../Api/FakeClassnameTags123Api.cs | 60 +- .../src/Org.OpenAPITools/Api/PetApi.cs | 120 ++-- .../src/Org.OpenAPITools/Api/StoreApi.cs | 62 +- .../src/Org.OpenAPITools/Api/UserApi.cs | 248 +++---- .../Model/AdditionalPropertiesClass.cs | 200 +----- .../src/Org.OpenAPITools/Model/Animal.cs | 1 - .../src/Org.OpenAPITools/Model/Cat.cs | 2 +- .../src/Org.OpenAPITools/Model/Dog.cs | 2 +- .../src/Org.OpenAPITools/Model/EnumTest.cs | 53 +- .../src/Org.OpenAPITools/Model/Foo.cs | 2 +- .../src/Org.OpenAPITools/Model/FormatTest.cs | 42 +- .../Model/HealthCheckResult.cs | 113 ++++ .../Org.OpenAPITools/Model/InlineObject.cs | 2 +- .../Org.OpenAPITools/Model/InlineObject1.cs | 2 +- .../Org.OpenAPITools/Model/InlineObject2.cs | 3 +- .../Org.OpenAPITools/Model/InlineObject3.cs | 32 +- .../Org.OpenAPITools/Model/InlineObject4.cs | 8 +- .../Org.OpenAPITools/Model/InlineObject5.cs | 5 +- .../Model/InlineResponseDefault.cs | 2 +- .../Org.OpenAPITools/Model/NullableClass.cs | 306 +++++++++ .../Model/OuterEnumDefaultValue.cs | 53 ++ .../Model/OuterEnumInteger.cs | 53 ++ .../Model/OuterEnumIntegerDefaultValue.cs | 53 ++ .../Org.OpenAPITools/Org.OpenAPITools.csproj | 2 +- .../src/Org.OpenAPITools/Model/Cat.cs | 2 +- .../src/Org.OpenAPITools/Model/Dog.cs | 2 +- .../OpenAPIClient/.openapi-generator/VERSION | 2 +- .../petstore/csharp/OpenAPIClient/README.md | 56 +- .../petstore/csharp/OpenAPIClient/build.bat | 4 +- .../petstore/csharp/OpenAPIClient/build.sh | 4 +- .../docs/AdditionalPropertiesClass.md | 6 +- .../csharp/OpenAPIClient/docs/Animal.md | 6 +- .../OpenAPIClient/docs/AnotherFakeApi.md | 32 +- .../csharp/OpenAPIClient/docs/ApiResponse.md | 8 +- .../docs/ArrayOfArrayOfNumberOnly.md | 8 +- .../OpenAPIClient/docs/ArrayOfNumberOnly.md | 8 +- .../csharp/OpenAPIClient/docs/ArrayTest.md | 8 +- .../OpenAPIClient/docs/Capitalization.md | 6 +- .../petstore/csharp/OpenAPIClient/docs/Cat.md | 8 +- .../csharp/OpenAPIClient/docs/CatAllOf.md | 13 + .../csharp/OpenAPIClient/docs/Category.md | 8 +- .../csharp/OpenAPIClient/docs/ClassModel.md | 6 +- .../csharp/OpenAPIClient/docs/DefaultApi.md | 32 +- .../petstore/csharp/OpenAPIClient/docs/Dog.md | 6 +- .../csharp/OpenAPIClient/docs/DogAllOf.md | 13 + .../csharp/OpenAPIClient/docs/EnumArrays.md | 6 +- .../csharp/OpenAPIClient/docs/EnumClass.md | 6 +- .../csharp/OpenAPIClient/docs/EnumTest.md | 18 +- .../csharp/OpenAPIClient/docs/FakeApi.md | 621 +++++++++++++---- .../docs/FakeClassnameTags123Api.md | 32 +- .../csharp/OpenAPIClient/docs/File.md | 6 +- .../OpenAPIClient/docs/FileSchemaTestClass.md | 6 +- .../petstore/csharp/OpenAPIClient/docs/Foo.md | 6 +- .../csharp/OpenAPIClient/docs/FormatTest.md | 24 +- .../OpenAPIClient/docs/HasOnlyReadOnly.md | 10 +- .../OpenAPIClient/docs/HealthCheckResult.md | 6 +- .../csharp/OpenAPIClient/docs/InlineObject.md | 6 +- .../OpenAPIClient/docs/InlineObject1.md | 6 +- .../OpenAPIClient/docs/InlineObject2.md | 6 +- .../OpenAPIClient/docs/InlineObject3.md | 22 +- .../OpenAPIClient/docs/InlineObject4.md | 6 +- .../OpenAPIClient/docs/InlineObject5.md | 6 +- .../docs/InlineResponseDefault.md | 6 +- .../csharp/OpenAPIClient/docs/List.md | 6 +- .../csharp/OpenAPIClient/docs/MapTest.md | 10 +- ...dPropertiesAndAdditionalPropertiesClass.md | 10 +- .../OpenAPIClient/docs/Model200Response.md | 8 +- .../csharp/OpenAPIClient/docs/ModelClient.md | 6 +- .../csharp/OpenAPIClient/docs/Name.md | 12 +- .../OpenAPIClient/docs/NullableClass.md | 6 +- .../csharp/OpenAPIClient/docs/NumberOnly.md | 8 +- .../csharp/OpenAPIClient/docs/Order.md | 16 +- .../OpenAPIClient/docs/OuterComposite.md | 10 +- .../csharp/OpenAPIClient/docs/OuterEnum.md | 6 +- .../docs/OuterEnumDefaultValue.md | 6 +- .../OpenAPIClient/docs/OuterEnumInteger.md | 6 +- .../docs/OuterEnumIntegerDefaultValue.md | 6 +- .../petstore/csharp/OpenAPIClient/docs/Pet.md | 8 +- .../csharp/OpenAPIClient/docs/PetApi.md | 336 ++++++--- .../OpenAPIClient/docs/ReadOnlyFirst.md | 8 +- .../csharp/OpenAPIClient/docs/Return.md | 8 +- .../OpenAPIClient/docs/SpecialModelName.md | 8 +- .../csharp/OpenAPIClient/docs/StoreApi.md | 144 ++-- .../petstore/csharp/OpenAPIClient/docs/Tag.md | 8 +- .../csharp/OpenAPIClient/docs/User.md | 10 +- .../csharp/OpenAPIClient/docs/UserApi.md | 265 ++++++-- .../petstore/csharp/OpenAPIClient/git_push.sh | 14 +- .../csharp/OpenAPIClient/mono_nunit_test.sh | 6 +- .../Model/CatAllOfTests.cs | 79 +++ .../Model/DogAllOfTests.cs | 79 +++ .../Org.OpenAPITools.Test.csproj | 26 +- .../src/Org.OpenAPITools.Test/packages.config | 6 +- .../Org.OpenAPITools/Api/AnotherFakeApi.cs | 4 +- .../src/Org.OpenAPITools/Api/DefaultApi.cs | 4 +- .../src/Org.OpenAPITools/Api/FakeApi.cs | 636 +++++++++++++++--- .../Api/FakeClassnameTags123Api.cs | 4 +- .../src/Org.OpenAPITools/Api/PetApi.cs | 86 +-- .../src/Org.OpenAPITools/Api/StoreApi.cs | 64 +- .../src/Org.OpenAPITools/Api/UserApi.cs | 6 +- .../src/Org.OpenAPITools/Client/ApiClient.cs | 6 +- .../Org.OpenAPITools/Client/ApiException.cs | 2 +- .../Org.OpenAPITools/Client/ApiResponse.cs | 2 +- .../Org.OpenAPITools/Client/Configuration.cs | 2 +- .../Client/ExceptionFactory.cs | 2 +- .../Client/GlobalConfiguration.cs | 2 +- .../Org.OpenAPITools/Client/IApiAccessor.cs | 2 +- .../Client/IReadableConfiguration.cs | 2 +- .../Client/OpenAPIDateConverter.cs | 2 +- .../Model/AdditionalPropertiesClass.cs | 4 +- .../src/Org.OpenAPITools/Model/Animal.cs | 7 +- .../src/Org.OpenAPITools/Model/ApiResponse.cs | 6 +- .../Model/ArrayOfArrayOfNumberOnly.cs | 7 +- .../Model/ArrayOfNumberOnly.cs | 7 +- .../src/Org.OpenAPITools/Model/ArrayTest.cs | 9 +- .../Org.OpenAPITools/Model/Capitalization.cs | 2 +- .../src/Org.OpenAPITools/Model/Cat.cs | 6 +- .../src/Org.OpenAPITools/Model/CatAllOf.cs | 124 ++++ .../src/Org.OpenAPITools/Model/Category.cs | 9 +- .../src/Org.OpenAPITools/Model/ClassModel.cs | 2 +- .../src/Org.OpenAPITools/Model/Dog.cs | 4 +- .../src/Org.OpenAPITools/Model/DogAllOf.cs | 124 ++++ .../src/Org.OpenAPITools/Model/EnumArrays.cs | 3 +- .../src/Org.OpenAPITools/Model/EnumClass.cs | 2 +- .../src/Org.OpenAPITools/Model/EnumTest.cs | 48 +- .../src/Org.OpenAPITools/Model/File.cs | 2 +- .../Model/FileSchemaTestClass.cs | 3 +- .../src/Org.OpenAPITools/Model/Foo.cs | 2 +- .../src/Org.OpenAPITools/Model/FormatTest.cs | 90 ++- .../Org.OpenAPITools/Model/HasOnlyReadOnly.cs | 2 +- .../Model/HealthCheckResult.cs | 5 +- .../Org.OpenAPITools/Model/InlineObject.cs | 2 +- .../Org.OpenAPITools/Model/InlineObject1.cs | 2 +- .../Org.OpenAPITools/Model/InlineObject2.cs | 3 +- .../Org.OpenAPITools/Model/InlineObject3.cs | 84 ++- .../Org.OpenAPITools/Model/InlineObject4.cs | 8 +- .../Org.OpenAPITools/Model/InlineObject5.cs | 5 +- .../Model/InlineResponseDefault.cs | 2 +- .../src/Org.OpenAPITools/Model/List.cs | 2 +- .../src/Org.OpenAPITools/Model/MapTest.cs | 12 +- ...dPropertiesAndAdditionalPropertiesClass.cs | 9 +- .../Model/Model200Response.cs | 6 +- .../src/Org.OpenAPITools/Model/ModelClient.cs | 2 +- .../src/Org.OpenAPITools/Model/Name.cs | 13 +- .../Org.OpenAPITools/Model/NullableClass.cs | 38 +- .../src/Org.OpenAPITools/Model/NumberOnly.cs | 6 +- .../src/Org.OpenAPITools/Model/Order.cs | 14 +- .../Org.OpenAPITools/Model/OuterComposite.cs | 8 +- .../src/Org.OpenAPITools/Model/OuterEnum.cs | 2 +- .../Model/OuterEnumDefaultValue.cs | 2 +- .../Model/OuterEnumInteger.cs | 2 +- .../Model/OuterEnumIntegerDefaultValue.cs | 2 +- .../src/Org.OpenAPITools/Model/Pet.cs | 14 +- .../Org.OpenAPITools/Model/ReadOnlyFirst.cs | 2 +- .../src/Org.OpenAPITools/Model/Return.cs | 6 +- .../Model/SpecialModelName.cs | 6 +- .../src/Org.OpenAPITools/Model/Tag.cs | 6 +- .../src/Org.OpenAPITools/Model/User.cs | 8 +- .../Org.OpenAPITools/Org.OpenAPITools.csproj | 26 +- .../Org.OpenAPITools/Org.OpenAPITools.nuspec | 4 +- .../src/Org.OpenAPITools/packages.config | 5 +- 194 files changed, 4592 insertions(+), 1801 deletions(-) create mode 100644 samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/HealthCheckResult.md create mode 100644 samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/NullableClass.md create mode 100644 samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/OuterEnumDefaultValue.md create mode 100644 samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/OuterEnumInteger.md create mode 100644 samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/OuterEnumIntegerDefaultValue.md create mode 100644 samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/HealthCheckResult.cs create mode 100644 samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/NullableClass.cs create mode 100644 samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/OuterEnumDefaultValue.cs create mode 100644 samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/OuterEnumInteger.cs create mode 100644 samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/OuterEnumIntegerDefaultValue.cs create mode 100644 samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/CatAllOf.md create mode 100644 samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/DogAllOf.md create mode 100644 samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools.Test/Model/CatAllOfTests.cs create mode 100644 samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools.Test/Model/DogAllOfTests.cs create mode 100644 samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/CatAllOf.cs create mode 100644 samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/DogAllOf.cs diff --git a/samples/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Cat.cs b/samples/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Cat.cs index 42674c5ffce8..2326d55ac486 100644 --- a/samples/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Cat.cs +++ b/samples/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Cat.cs @@ -39,7 +39,7 @@ protected Cat() { } /// Initializes a new instance of the class. /// /// declawed. - public Cat(bool declawed = default(bool), string className = default(string), string color = "red") : base(className, color) + public Cat(bool declawed = default(bool), string className = "Cat", string color = "red") : base(className, color) { this.Declawed = declawed; } diff --git a/samples/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Dog.cs b/samples/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Dog.cs index 96e568628fe5..b925fb99c324 100644 --- a/samples/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Dog.cs +++ b/samples/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Dog.cs @@ -39,7 +39,7 @@ protected Dog() { } /// Initializes a new instance of the class. /// /// breed. - public Dog(string breed = default(string), string className = default(string), string color = "red") : base(className, color) + public Dog(string breed = default(string), string className = "Dog", string color = "red") : base(className, color) { this.Breed = breed; } diff --git a/samples/client/petstore/csharp/OpenAPIClientNet35/src/Org.OpenAPITools/Model/Cat.cs b/samples/client/petstore/csharp/OpenAPIClientNet35/src/Org.OpenAPITools/Model/Cat.cs index 036ed97c89ef..9ca5d9c2b5ea 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNet35/src/Org.OpenAPITools/Model/Cat.cs +++ b/samples/client/petstore/csharp/OpenAPIClientNet35/src/Org.OpenAPITools/Model/Cat.cs @@ -39,7 +39,7 @@ protected Cat() { } /// Initializes a new instance of the class. /// /// declawed. - public Cat(bool declawed = default(bool), string className = default(string), string color = "red") : base(className, color) + public Cat(bool declawed = default(bool), string className = "Cat", string color = "red") : base(className, color) { this.Declawed = declawed; } diff --git a/samples/client/petstore/csharp/OpenAPIClientNet35/src/Org.OpenAPITools/Model/Dog.cs b/samples/client/petstore/csharp/OpenAPIClientNet35/src/Org.OpenAPITools/Model/Dog.cs index bc15d1113639..cfc41f564489 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNet35/src/Org.OpenAPITools/Model/Dog.cs +++ b/samples/client/petstore/csharp/OpenAPIClientNet35/src/Org.OpenAPITools/Model/Dog.cs @@ -39,7 +39,7 @@ protected Dog() { } /// Initializes a new instance of the class. /// /// breed. - public Dog(string breed = default(string), string className = default(string), string color = "red") : base(className, color) + public Dog(string breed = default(string), string className = "Dog", string color = "red") : base(className, color) { this.Breed = breed; } diff --git a/samples/client/petstore/csharp/OpenAPIClientNet40/src/Org.OpenAPITools/Model/Cat.cs b/samples/client/petstore/csharp/OpenAPIClientNet40/src/Org.OpenAPITools/Model/Cat.cs index 42674c5ffce8..2326d55ac486 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNet40/src/Org.OpenAPITools/Model/Cat.cs +++ b/samples/client/petstore/csharp/OpenAPIClientNet40/src/Org.OpenAPITools/Model/Cat.cs @@ -39,7 +39,7 @@ protected Cat() { } /// Initializes a new instance of the class. /// /// declawed. - public Cat(bool declawed = default(bool), string className = default(string), string color = "red") : base(className, color) + public Cat(bool declawed = default(bool), string className = "Cat", string color = "red") : base(className, color) { this.Declawed = declawed; } diff --git a/samples/client/petstore/csharp/OpenAPIClientNet40/src/Org.OpenAPITools/Model/Dog.cs b/samples/client/petstore/csharp/OpenAPIClientNet40/src/Org.OpenAPITools/Model/Dog.cs index 96e568628fe5..b925fb99c324 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNet40/src/Org.OpenAPITools/Model/Dog.cs +++ b/samples/client/petstore/csharp/OpenAPIClientNet40/src/Org.OpenAPITools/Model/Dog.cs @@ -39,7 +39,7 @@ protected Dog() { } /// Initializes a new instance of the class. /// /// breed. - public Dog(string breed = default(string), string className = default(string), string color = "red") : base(className, color) + public Dog(string breed = default(string), string className = "Dog", string color = "red") : base(className, color) { this.Breed = breed; } diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/Org.OpenAPITools.sln b/samples/client/petstore/csharp/OpenAPIClientNetStandard/Org.OpenAPITools.sln index 4f3b7e0fdef6..8d85f5b71f0b 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/Org.OpenAPITools.sln +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/Org.OpenAPITools.sln @@ -2,7 +2,7 @@ Microsoft Visual Studio Solution File, Format Version 12.00 # Visual Studio 14 VisualStudioVersion = 14.0.25420.1 MinimumVisualStudioVersion = 10.0.40219.1 -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Org.OpenAPITools", "src\Org.OpenAPITools\Org.OpenAPITools.csproj", "{3AB1F259-1769-484B-9411-84505FCCBD55}" +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Org.OpenAPITools", "src\Org.OpenAPITools\Org.OpenAPITools.csproj", "{321C8C3F-0156-40C1-AE42-D59761FB9B6C}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution @@ -10,10 +10,10 @@ Global Release|Any CPU = Release|Any CPU EndGlobalSection GlobalSection(ProjectConfigurationPlatforms) = postSolution - {3AB1F259-1769-484B-9411-84505FCCBD55}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {3AB1F259-1769-484B-9411-84505FCCBD55}.Debug|Any CPU.Build.0 = Debug|Any CPU - {3AB1F259-1769-484B-9411-84505FCCBD55}.Release|Any CPU.ActiveCfg = Release|Any CPU - {3AB1F259-1769-484B-9411-84505FCCBD55}.Release|Any CPU.Build.0 = Release|Any CPU + {321C8C3F-0156-40C1-AE42-D59761FB9B6C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {321C8C3F-0156-40C1-AE42-D59761FB9B6C}.Debug|Any CPU.Build.0 = Debug|Any CPU + {321C8C3F-0156-40C1-AE42-D59761FB9B6C}.Release|Any CPU.ActiveCfg = Release|Any CPU + {321C8C3F-0156-40C1-AE42-D59761FB9B6C}.Release|Any CPU.Build.0 = Release|Any CPU {19F1DEBC-DE5E-4517-8062-F000CD499087}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {19F1DEBC-DE5E-4517-8062-F000CD499087}.Debug|Any CPU.Build.0 = Debug|Any CPU {19F1DEBC-DE5E-4517-8062-F000CD499087}.Release|Any CPU.ActiveCfg = Release|Any CPU diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/README.md b/samples/client/petstore/csharp/OpenAPIClientNetStandard/README.md index 19c69aa88d0b..ec898745410c 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/README.md +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/README.md @@ -55,12 +55,12 @@ namespace Example Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; var apiInstance = new AnotherFakeApi(Configuration.Default); - var body = new ModelClient(); // ModelClient | client model + var modelClient = new ModelClient(); // ModelClient | client model try { // To test special tags - ModelClient result = apiInstance.Call123TestSpecialTags(body); + ModelClient result = apiInstance.Call123TestSpecialTags(modelClient); Debug.WriteLine(result); } catch (ApiException e) @@ -82,7 +82,9 @@ All URIs are relative to *http://petstore.swagger.io:80/v2* Class | Method | HTTP request | Description ------------ | ------------- | ------------- | ------------- *AnotherFakeApi* | [**Call123TestSpecialTags**](docs/AnotherFakeApi.md#call123testspecialtags) | **PATCH** /another-fake/dummy | To test special tags -*FakeApi* | [**CreateXmlItem**](docs/FakeApi.md#createxmlitem) | **POST** /fake/create_xml_item | creates an XmlItem +*DefaultApi* | [**FooGet**](docs/DefaultApi.md#fooget) | **GET** /foo | +*FakeApi* | [**FakeHealthGet**](docs/FakeApi.md#fakehealthget) | **GET** /fake/health | Health check endpoint +*FakeApi* | [**FakeHttpSignatureTest**](docs/FakeApi.md#fakehttpsignaturetest) | **GET** /fake/http-signature-test | test http signature authentication *FakeApi* | [**FakeOuterBooleanSerialize**](docs/FakeApi.md#fakeouterbooleanserialize) | **POST** /fake/outer/boolean | *FakeApi* | [**FakeOuterCompositeSerialize**](docs/FakeApi.md#fakeoutercompositeserialize) | **POST** /fake/outer/composite | *FakeApi* | [**FakeOuterNumberSerialize**](docs/FakeApi.md#fakeouternumberserialize) | **POST** /fake/outer/number | @@ -90,7 +92,7 @@ Class | Method | HTTP request | Description *FakeApi* | [**TestBodyWithFileSchema**](docs/FakeApi.md#testbodywithfileschema) | **PUT** /fake/body-with-file-schema | *FakeApi* | [**TestBodyWithQueryParams**](docs/FakeApi.md#testbodywithqueryparams) | **PUT** /fake/body-with-query-params | *FakeApi* | [**TestClientModel**](docs/FakeApi.md#testclientmodel) | **PATCH** /fake | To test \"client\" model -*FakeApi* | [**TestEndpointParameters**](docs/FakeApi.md#testendpointparameters) | **POST** /fake | Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 +*FakeApi* | [**TestEndpointParameters**](docs/FakeApi.md#testendpointparameters) | **POST** /fake | Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 *FakeApi* | [**TestEnumParameters**](docs/FakeApi.md#testenumparameters) | **GET** /fake | To test enum parameters *FakeApi* | [**TestGroupParameters**](docs/FakeApi.md#testgroupparameters) | **DELETE** /fake | Fake endpoint to test group parameters (optional) *FakeApi* | [**TestInlineAdditionalProperties**](docs/FakeApi.md#testinlineadditionalproperties) | **POST** /fake/inline-additionalProperties | test inline additionalProperties @@ -122,21 +124,12 @@ Class | Method | HTTP request | Description ## Documentation for Models - - [Model.AdditionalPropertiesAnyType](docs/AdditionalPropertiesAnyType.md) - - [Model.AdditionalPropertiesArray](docs/AdditionalPropertiesArray.md) - - [Model.AdditionalPropertiesBoolean](docs/AdditionalPropertiesBoolean.md) - [Model.AdditionalPropertiesClass](docs/AdditionalPropertiesClass.md) - - [Model.AdditionalPropertiesInteger](docs/AdditionalPropertiesInteger.md) - - [Model.AdditionalPropertiesNumber](docs/AdditionalPropertiesNumber.md) - - [Model.AdditionalPropertiesObject](docs/AdditionalPropertiesObject.md) - - [Model.AdditionalPropertiesString](docs/AdditionalPropertiesString.md) - [Model.Animal](docs/Animal.md) - [Model.ApiResponse](docs/ApiResponse.md) - [Model.ArrayOfArrayOfNumberOnly](docs/ArrayOfArrayOfNumberOnly.md) - [Model.ArrayOfNumberOnly](docs/ArrayOfNumberOnly.md) - [Model.ArrayTest](docs/ArrayTest.md) - - [Model.BigCat](docs/BigCat.md) - - [Model.BigCatAllOf](docs/BigCatAllOf.md) - [Model.Capitalization](docs/Capitalization.md) - [Model.Cat](docs/Cat.md) - [Model.CatAllOf](docs/CatAllOf.md) @@ -149,27 +142,37 @@ Class | Method | HTTP request | Description - [Model.EnumTest](docs/EnumTest.md) - [Model.File](docs/File.md) - [Model.FileSchemaTestClass](docs/FileSchemaTestClass.md) + - [Model.Foo](docs/Foo.md) - [Model.FormatTest](docs/FormatTest.md) - [Model.HasOnlyReadOnly](docs/HasOnlyReadOnly.md) + - [Model.HealthCheckResult](docs/HealthCheckResult.md) + - [Model.InlineObject](docs/InlineObject.md) + - [Model.InlineObject1](docs/InlineObject1.md) + - [Model.InlineObject2](docs/InlineObject2.md) + - [Model.InlineObject3](docs/InlineObject3.md) + - [Model.InlineObject4](docs/InlineObject4.md) + - [Model.InlineObject5](docs/InlineObject5.md) + - [Model.InlineResponseDefault](docs/InlineResponseDefault.md) - [Model.List](docs/List.md) - [Model.MapTest](docs/MapTest.md) - [Model.MixedPropertiesAndAdditionalPropertiesClass](docs/MixedPropertiesAndAdditionalPropertiesClass.md) - [Model.Model200Response](docs/Model200Response.md) - [Model.ModelClient](docs/ModelClient.md) - [Model.Name](docs/Name.md) + - [Model.NullableClass](docs/NullableClass.md) - [Model.NumberOnly](docs/NumberOnly.md) - [Model.Order](docs/Order.md) - [Model.OuterComposite](docs/OuterComposite.md) - [Model.OuterEnum](docs/OuterEnum.md) + - [Model.OuterEnumDefaultValue](docs/OuterEnumDefaultValue.md) + - [Model.OuterEnumInteger](docs/OuterEnumInteger.md) + - [Model.OuterEnumIntegerDefaultValue](docs/OuterEnumIntegerDefaultValue.md) - [Model.Pet](docs/Pet.md) - [Model.ReadOnlyFirst](docs/ReadOnlyFirst.md) - [Model.Return](docs/Return.md) - [Model.SpecialModelName](docs/SpecialModelName.md) - [Model.Tag](docs/Tag.md) - - [Model.TypeHolderDefault](docs/TypeHolderDefault.md) - - [Model.TypeHolderExample](docs/TypeHolderExample.md) - [Model.User](docs/User.md) - - [Model.XmlItem](docs/XmlItem.md) ## Documentation for Authorization @@ -191,12 +194,22 @@ Class | Method | HTTP request | Description - **Location**: URL query string +### bearer_test + + +- **Type**: HTTP bearer authentication + + ### http_basic_test - **Type**: HTTP basic authentication +### http_signature_test + + + ### petstore_auth diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/AdditionalPropertiesClass.md b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/AdditionalPropertiesClass.md index d07f57619d5e..847bf120968f 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/AdditionalPropertiesClass.md +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/AdditionalPropertiesClass.md @@ -5,17 +5,8 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**MapString** | **Dictionary<string, string>** | | [optional] -**MapNumber** | **Dictionary<string, decimal>** | | [optional] -**MapInteger** | **Dictionary<string, int>** | | [optional] -**MapBoolean** | **Dictionary<string, bool>** | | [optional] -**MapArrayInteger** | **Dictionary<string, List<int>>** | | [optional] -**MapArrayAnytype** | **Dictionary<string, List<Object>>** | | [optional] -**MapMapString** | **Dictionary<string, Dictionary<string, string>>** | | [optional] -**MapMapAnytype** | **Dictionary<string, Dictionary<string, Object>>** | | [optional] -**Anytype1** | [**Object**](.md) | | [optional] -**Anytype2** | [**Object**](.md) | | [optional] -**Anytype3** | [**Object**](.md) | | [optional] +**MapProperty** | **Dictionary<string, string>** | | [optional] +**MapOfMapProperty** | **Dictionary<string, Dictionary<string, string>>** | | [optional] [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/AnotherFakeApi.md b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/AnotherFakeApi.md index 5af41a1862c2..c7cb3d05138b 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/AnotherFakeApi.md +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/AnotherFakeApi.md @@ -10,7 +10,7 @@ Method | HTTP request | Description ## Call123TestSpecialTags -> ModelClient Call123TestSpecialTags (ModelClient body) +> ModelClient Call123TestSpecialTags (ModelClient modelClient) To test special tags @@ -33,12 +33,12 @@ namespace Example { Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; var apiInstance = new AnotherFakeApi(Configuration.Default); - var body = new ModelClient(); // ModelClient | client model + var modelClient = new ModelClient(); // ModelClient | client model try { // To test special tags - ModelClient result = apiInstance.Call123TestSpecialTags(body); + ModelClient result = apiInstance.Call123TestSpecialTags(modelClient); Debug.WriteLine(result); } catch (ApiException e) @@ -57,7 +57,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**ModelClient**](ModelClient.md)| client model | + **modelClient** | [**ModelClient**](ModelClient.md)| client model | ### Return type diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/DefaultApi.md b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/DefaultApi.md index 92f2dc125c04..7ee074eba27c 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/DefaultApi.md +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/DefaultApi.md @@ -7,15 +7,17 @@ Method | HTTP request | Description [**FooGet**](DefaultApi.md#fooget) | **GET** /foo | - -# **FooGet** + +## FooGet + > InlineResponseDefault FooGet () ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -25,18 +27,21 @@ namespace Example { public class FooGetExample { - public void main() + public static void Main() { - var apiInstance = new DefaultApi(); + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new DefaultApi(Configuration.Default); try { InlineResponseDefault result = apiInstance.FooGet(); Debug.WriteLine(result); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling DefaultApi.FooGet: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -44,6 +49,7 @@ namespace Example ``` ### Parameters + This endpoint does not need any parameter. ### Return type @@ -56,8 +62,16 @@ No authorization required ### HTTP request headers - - **Content-Type**: Not defined - - **Accept**: application/json +- **Content-Type**: Not defined +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **0** | response | - | -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/EnumTest.md b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/EnumTest.md index f8bc67baa6ab..a8a888d45249 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/EnumTest.md +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/EnumTest.md @@ -10,6 +10,9 @@ Name | Type | Description | Notes **EnumInteger** | **int** | | [optional] **EnumNumber** | **double** | | [optional] **OuterEnum** | **OuterEnum** | | [optional] +**OuterEnumInteger** | **OuterEnumInteger** | | [optional] +**OuterEnumDefaultValue** | **OuterEnumDefaultValue** | | [optional] +**OuterEnumIntegerDefaultValue** | **OuterEnumIntegerDefaultValue** | | [optional] [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/FakeApi.md b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/FakeApi.md index 661c2cba6ab3..38ab478e715b 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/FakeApi.md +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/FakeApi.md @@ -4,7 +4,8 @@ All URIs are relative to *http://petstore.swagger.io:80/v2* Method | HTTP request | Description ------------- | ------------- | ------------- -[**CreateXmlItem**](FakeApi.md#createxmlitem) | **POST** /fake/create_xml_item | creates an XmlItem +[**FakeHealthGet**](FakeApi.md#fakehealthget) | **GET** /fake/health | Health check endpoint +[**FakeHttpSignatureTest**](FakeApi.md#fakehttpsignaturetest) | **GET** /fake/http-signature-test | test http signature authentication [**FakeOuterBooleanSerialize**](FakeApi.md#fakeouterbooleanserialize) | **POST** /fake/outer/boolean | [**FakeOuterCompositeSerialize**](FakeApi.md#fakeoutercompositeserialize) | **POST** /fake/outer/composite | [**FakeOuterNumberSerialize**](FakeApi.md#fakeouternumberserialize) | **POST** /fake/outer/number | @@ -12,7 +13,7 @@ Method | HTTP request | Description [**TestBodyWithFileSchema**](FakeApi.md#testbodywithfileschema) | **PUT** /fake/body-with-file-schema | [**TestBodyWithQueryParams**](FakeApi.md#testbodywithqueryparams) | **PUT** /fake/body-with-query-params | [**TestClientModel**](FakeApi.md#testclientmodel) | **PATCH** /fake | To test \"client\" model -[**TestEndpointParameters**](FakeApi.md#testendpointparameters) | **POST** /fake | Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 +[**TestEndpointParameters**](FakeApi.md#testendpointparameters) | **POST** /fake | Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 [**TestEnumParameters**](FakeApi.md#testenumparameters) | **GET** /fake | To test enum parameters [**TestGroupParameters**](FakeApi.md#testgroupparameters) | **DELETE** /fake | Fake endpoint to test group parameters (optional) [**TestInlineAdditionalProperties**](FakeApi.md#testinlineadditionalproperties) | **POST** /fake/inline-additionalProperties | test inline additionalProperties @@ -21,13 +22,80 @@ Method | HTTP request | Description -## CreateXmlItem +## FakeHealthGet -> void CreateXmlItem (XmlItem xmlItem) +> HealthCheckResult FakeHealthGet () -creates an XmlItem +Health check endpoint -this route creates an XmlItem +### Example + +```csharp +using System.Collections.Generic; +using System.Diagnostics; +using Org.OpenAPITools.Api; +using Org.OpenAPITools.Client; +using Org.OpenAPITools.Model; + +namespace Example +{ + public class FakeHealthGetExample + { + public static void Main() + { + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new FakeApi(Configuration.Default); + + try + { + // Health check endpoint + HealthCheckResult result = apiInstance.FakeHealthGet(); + Debug.WriteLine(result); + } + catch (ApiException e) + { + Debug.Print("Exception when calling FakeApi.FakeHealthGet: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); + } + } + } +} +``` + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**HealthCheckResult**](HealthCheckResult.md) + +### Authorization + +No authorization required + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | The instance started successfully | - | + +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) + + +## FakeHttpSignatureTest + +> void FakeHttpSignatureTest (Pet pet, string query1 = null, string header1 = null) + +test http signature authentication ### Example @@ -40,22 +108,25 @@ using Org.OpenAPITools.Model; namespace Example { - public class CreateXmlItemExample + public class FakeHttpSignatureTestExample { public static void Main() { Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new FakeApi(Configuration.Default); - var xmlItem = new XmlItem(); // XmlItem | XmlItem Body + var pet = new Pet(); // Pet | Pet object that needs to be added to the store + var query1 = query1_example; // string | query parameter (optional) + var header1 = header1_example; // string | header parameter (optional) try { - // creates an XmlItem - apiInstance.CreateXmlItem(xmlItem); + // test http signature authentication + apiInstance.FakeHttpSignatureTest(pet, query1, header1); } catch (ApiException e) { - Debug.Print("Exception when calling FakeApi.CreateXmlItem: " + e.Message ); + Debug.Print("Exception when calling FakeApi.FakeHttpSignatureTest: " + e.Message ); Debug.Print("Status Code: "+ e.ErrorCode); Debug.Print(e.StackTrace); } @@ -69,7 +140,9 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **xmlItem** | [**XmlItem**](XmlItem.md)| XmlItem Body | + **pet** | [**Pet**](Pet.md)| Pet object that needs to be added to the store | + **query1** | **string**| query parameter | [optional] + **header1** | **string**| header parameter | [optional] ### Return type @@ -77,17 +150,17 @@ void (empty response body) ### Authorization -No authorization required +[http_signature_test](../README.md#http_signature_test) ### HTTP request headers -- **Content-Type**: application/xml, application/xml; charset=utf-8, application/xml; charset=utf-16, text/xml, text/xml; charset=utf-8, text/xml; charset=utf-16 +- **Content-Type**: application/json, application/xml - **Accept**: Not defined ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **200** | successful operation | - | +| **200** | The instance started successfully | - | [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) @@ -155,7 +228,7 @@ No authorization required ### HTTP request headers -- **Content-Type**: Not defined +- **Content-Type**: application/json - **Accept**: */* ### HTTP response details @@ -171,7 +244,7 @@ No authorization required ## FakeOuterCompositeSerialize -> OuterComposite FakeOuterCompositeSerialize (OuterComposite body = null) +> OuterComposite FakeOuterCompositeSerialize (OuterComposite outerComposite = null) @@ -194,11 +267,11 @@ namespace Example { Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; var apiInstance = new FakeApi(Configuration.Default); - var body = new OuterComposite(); // OuterComposite | Input composite as post body (optional) + var outerComposite = new OuterComposite(); // OuterComposite | Input composite as post body (optional) try { - OuterComposite result = apiInstance.FakeOuterCompositeSerialize(body); + OuterComposite result = apiInstance.FakeOuterCompositeSerialize(outerComposite); Debug.WriteLine(result); } catch (ApiException e) @@ -217,7 +290,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**OuterComposite**](OuterComposite.md)| Input composite as post body | [optional] + **outerComposite** | [**OuterComposite**](OuterComposite.md)| Input composite as post body | [optional] ### Return type @@ -229,7 +302,7 @@ No authorization required ### HTTP request headers -- **Content-Type**: Not defined +- **Content-Type**: application/json - **Accept**: */* ### HTTP response details @@ -303,7 +376,7 @@ No authorization required ### HTTP request headers -- **Content-Type**: Not defined +- **Content-Type**: application/json - **Accept**: */* ### HTTP response details @@ -377,7 +450,7 @@ No authorization required ### HTTP request headers -- **Content-Type**: Not defined +- **Content-Type**: application/json - **Accept**: */* ### HTTP response details @@ -393,7 +466,7 @@ No authorization required ## TestBodyWithFileSchema -> void TestBodyWithFileSchema (FileSchemaTestClass body) +> void TestBodyWithFileSchema (FileSchemaTestClass fileSchemaTestClass) @@ -416,11 +489,11 @@ namespace Example { Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; var apiInstance = new FakeApi(Configuration.Default); - var body = new FileSchemaTestClass(); // FileSchemaTestClass | + var fileSchemaTestClass = new FileSchemaTestClass(); // FileSchemaTestClass | try { - apiInstance.TestBodyWithFileSchema(body); + apiInstance.TestBodyWithFileSchema(fileSchemaTestClass); } catch (ApiException e) { @@ -438,7 +511,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**FileSchemaTestClass**](FileSchemaTestClass.md)| | + **fileSchemaTestClass** | [**FileSchemaTestClass**](FileSchemaTestClass.md)| | ### Return type @@ -466,7 +539,7 @@ No authorization required ## TestBodyWithQueryParams -> void TestBodyWithQueryParams (string query, User body) +> void TestBodyWithQueryParams (string query, User user) @@ -488,11 +561,11 @@ namespace Example Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; var apiInstance = new FakeApi(Configuration.Default); var query = query_example; // string | - var body = new User(); // User | + var user = new User(); // User | try { - apiInstance.TestBodyWithQueryParams(query, body); + apiInstance.TestBodyWithQueryParams(query, user); } catch (ApiException e) { @@ -511,7 +584,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **query** | **string**| | - **body** | [**User**](User.md)| | + **user** | [**User**](User.md)| | ### Return type @@ -539,7 +612,7 @@ No authorization required ## TestClientModel -> ModelClient TestClientModel (ModelClient body) +> ModelClient TestClientModel (ModelClient modelClient) To test \"client\" model @@ -562,12 +635,12 @@ namespace Example { Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; var apiInstance = new FakeApi(Configuration.Default); - var body = new ModelClient(); // ModelClient | client model + var modelClient = new ModelClient(); // ModelClient | client model try { // To test \"client\" model - ModelClient result = apiInstance.TestClientModel(body); + ModelClient result = apiInstance.TestClientModel(modelClient); Debug.WriteLine(result); } catch (ApiException e) @@ -586,7 +659,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**ModelClient**](ModelClient.md)| client model | + **modelClient** | [**ModelClient**](ModelClient.md)| client model | ### Return type @@ -616,9 +689,9 @@ No authorization required > void TestEndpointParameters (decimal number, double _double, string patternWithoutDelimiter, byte[] _byte, int? integer = null, int? int32 = null, long? int64 = null, float? _float = null, string _string = null, System.IO.Stream binary = null, DateTime? date = null, DateTime? dateTime = null, string password = null, string callback = null) -Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 +Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 -Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 +Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 ### Example @@ -658,7 +731,7 @@ namespace Example try { - // Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + // Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 apiInstance.TestEndpointParameters(number, _double, patternWithoutDelimiter, _byte, integer, int32, int64, _float, _string, binary, date, dateTime, password, callback); } catch (ApiException e) @@ -830,6 +903,9 @@ namespace Example public static void Main() { Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + // Configure HTTP bearer authorization: bearer_test + Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN"; + var apiInstance = new FakeApi(Configuration.Default); var requiredStringGroup = 56; // int | Required String in group parameters var requiredBooleanGroup = true; // bool | Required Boolean in group parameters @@ -872,7 +948,7 @@ void (empty response body) ### Authorization -No authorization required +[bearer_test](../README.md#bearer_test) ### HTTP request headers @@ -892,7 +968,7 @@ No authorization required ## TestInlineAdditionalProperties -> void TestInlineAdditionalProperties (Dictionary param) +> void TestInlineAdditionalProperties (Dictionary requestBody) test inline additionalProperties @@ -913,12 +989,12 @@ namespace Example { Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; var apiInstance = new FakeApi(Configuration.Default); - var param = new Dictionary(); // Dictionary | request body + var requestBody = new Dictionary(); // Dictionary | request body try { // test inline additionalProperties - apiInstance.TestInlineAdditionalProperties(param); + apiInstance.TestInlineAdditionalProperties(requestBody); } catch (ApiException e) { @@ -936,7 +1012,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **param** | [**Dictionary<string, string>**](string.md)| request body | + **requestBody** | [**Dictionary<string, string>**](string.md)| request body | ### Return type diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/FakeClassnameTags123Api.md b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/FakeClassnameTags123Api.md index deb97a27697f..93eb8b274552 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/FakeClassnameTags123Api.md +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/FakeClassnameTags123Api.md @@ -10,7 +10,7 @@ Method | HTTP request | Description ## TestClassname -> ModelClient TestClassname (ModelClient body) +> ModelClient TestClassname (ModelClient modelClient) To test class name in snake case @@ -38,12 +38,12 @@ namespace Example // Configuration.Default.AddApiKeyPrefix("api_key_query", "Bearer"); var apiInstance = new FakeClassnameTags123Api(Configuration.Default); - var body = new ModelClient(); // ModelClient | client model + var modelClient = new ModelClient(); // ModelClient | client model try { // To test class name in snake case - ModelClient result = apiInstance.TestClassname(body); + ModelClient result = apiInstance.TestClassname(modelClient); Debug.WriteLine(result); } catch (ApiException e) @@ -62,7 +62,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**ModelClient**](ModelClient.md)| client model | + **modelClient** | [**ModelClient**](ModelClient.md)| client model | ### Return type diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/Foo.md b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/Foo.md index fd84dc2038c9..ea6f4245da6e 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/Foo.md +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/Foo.md @@ -1,9 +1,13 @@ + # Org.OpenAPITools.Model.Foo + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **Bar** | **string** | | [optional] [default to "bar"] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/FormatTest.md b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/FormatTest.md index 92d7d1e0104d..6cef48d5b4db 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/FormatTest.md +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/FormatTest.md @@ -18,7 +18,8 @@ Name | Type | Description | Notes **DateTime** | **DateTime** | | [optional] **Uuid** | **Guid** | | [optional] **Password** | **string** | | -**BigDecimal** | **decimal** | | [optional] +**PatternWithDigits** | **string** | A string that is a 10 digit number. Can have leading zeros. | [optional] +**PatternWithDigitsAndDelimiter** | **string** | A string starting with 'image_' (case insensitive) and one to three digits following i.e. Image_01. | [optional] [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/HealthCheckResult.md b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/HealthCheckResult.md new file mode 100644 index 000000000000..08e5992d20cb --- /dev/null +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/HealthCheckResult.md @@ -0,0 +1,13 @@ + +# Org.OpenAPITools.Model.HealthCheckResult + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**NullableMessage** | **string** | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) + diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/InlineObject.md b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/InlineObject.md index 40e16da1bb7d..12ec90a8c699 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/InlineObject.md +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/InlineObject.md @@ -1,4 +1,6 @@ + # Org.OpenAPITools.Model.InlineObject + ## Properties Name | Type | Description | Notes @@ -6,5 +8,7 @@ Name | Type | Description | Notes **Name** | **string** | Updated name of the pet | [optional] **Status** | **string** | Updated status of the pet | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/InlineObject1.md b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/InlineObject1.md index 2e6d226754e4..581fe20b1e21 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/InlineObject1.md +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/InlineObject1.md @@ -1,4 +1,6 @@ + # Org.OpenAPITools.Model.InlineObject1 + ## Properties Name | Type | Description | Notes @@ -6,5 +8,7 @@ Name | Type | Description | Notes **AdditionalMetadata** | **string** | Additional data to pass to server | [optional] **File** | **System.IO.Stream** | file to upload | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/InlineObject2.md b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/InlineObject2.md index c02c78f9b2d0..79abb7a467c4 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/InlineObject2.md +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/InlineObject2.md @@ -1,4 +1,6 @@ + # Org.OpenAPITools.Model.InlineObject2 + ## Properties Name | Type | Description | Notes @@ -6,5 +8,7 @@ Name | Type | Description | Notes **EnumFormStringArray** | **List<string>** | Form parameter enum test (string array) | [optional] **EnumFormString** | **string** | Form parameter enum test (string) | [optional] [default to EnumFormStringEnum.Efg] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/InlineObject3.md b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/InlineObject3.md index 192926bbe927..684db7f7227b 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/InlineObject3.md +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/InlineObject3.md @@ -1,22 +1,26 @@ + # Org.OpenAPITools.Model.InlineObject3 + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Integer** | **int?** | None | [optional] -**Int32** | **int?** | None | [optional] -**Int64** | **long?** | None | [optional] -**Number** | **decimal?** | None | -**Float** | **float?** | None | [optional] -**Double** | **double?** | None | +**Integer** | **int** | None | [optional] +**Int32** | **int** | None | [optional] +**Int64** | **long** | None | [optional] +**Number** | **decimal** | None | +**Float** | **float** | None | [optional] +**Double** | **double** | None | **String** | **string** | None | [optional] **PatternWithoutDelimiter** | **string** | None | **Byte** | **byte[]** | None | **Binary** | **System.IO.Stream** | None | [optional] -**Date** | **DateTime?** | None | [optional] -**DateTime** | **DateTime?** | None | [optional] +**Date** | **DateTime** | None | [optional] +**DateTime** | **DateTime** | None | [optional] **Password** | **string** | None | [optional] **Callback** | **string** | None | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/InlineObject4.md b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/InlineObject4.md index c8e00663ee88..18e4a1f3ce50 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/InlineObject4.md +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/InlineObject4.md @@ -1,4 +1,6 @@ + # Org.OpenAPITools.Model.InlineObject4 + ## Properties Name | Type | Description | Notes @@ -6,5 +8,7 @@ Name | Type | Description | Notes **Param** | **string** | field1 | **Param2** | **string** | field2 | -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/InlineObject5.md b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/InlineObject5.md index a28ff47f2ec0..291c88623eea 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/InlineObject5.md +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/InlineObject5.md @@ -1,4 +1,6 @@ + # Org.OpenAPITools.Model.InlineObject5 + ## Properties Name | Type | Description | Notes @@ -6,5 +8,7 @@ Name | Type | Description | Notes **AdditionalMetadata** | **string** | Additional data to pass to server | [optional] **RequiredFile** | **System.IO.Stream** | file to upload | -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/InlineResponseDefault.md b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/InlineResponseDefault.md index 8c96fb62ac88..ecfb254001a2 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/InlineResponseDefault.md +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/InlineResponseDefault.md @@ -1,9 +1,13 @@ + # Org.OpenAPITools.Model.InlineResponseDefault + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **String** | [**Foo**](Foo.md) | | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/NullableClass.md b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/NullableClass.md new file mode 100644 index 000000000000..84dd092d8a38 --- /dev/null +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/NullableClass.md @@ -0,0 +1,24 @@ + +# Org.OpenAPITools.Model.NullableClass + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**IntegerProp** | **int?** | | [optional] +**NumberProp** | **decimal?** | | [optional] +**BooleanProp** | **bool?** | | [optional] +**StringProp** | **string** | | [optional] +**DateProp** | **DateTime?** | | [optional] +**DatetimeProp** | **DateTime?** | | [optional] +**ArrayNullableProp** | **List<Object>** | | [optional] +**ArrayAndItemsNullableProp** | **List<Object>** | | [optional] +**ArrayItemsNullable** | **List<Object>** | | [optional] +**ObjectNullableProp** | **Dictionary<string, Object>** | | [optional] +**ObjectAndItemsNullableProp** | **Dictionary<string, Object>** | | [optional] +**ObjectItemsNullable** | **Dictionary<string, Object>** | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) + diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/OuterEnumDefaultValue.md b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/OuterEnumDefaultValue.md new file mode 100644 index 000000000000..41474099f2ee --- /dev/null +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/OuterEnumDefaultValue.md @@ -0,0 +1,12 @@ + +# Org.OpenAPITools.Model.OuterEnumDefaultValue + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- + +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) + diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/OuterEnumInteger.md b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/OuterEnumInteger.md new file mode 100644 index 000000000000..b82abc3adac4 --- /dev/null +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/OuterEnumInteger.md @@ -0,0 +1,12 @@ + +# Org.OpenAPITools.Model.OuterEnumInteger + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- + +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) + diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/OuterEnumIntegerDefaultValue.md b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/OuterEnumIntegerDefaultValue.md new file mode 100644 index 000000000000..46939d01522e --- /dev/null +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/OuterEnumIntegerDefaultValue.md @@ -0,0 +1,12 @@ + +# Org.OpenAPITools.Model.OuterEnumIntegerDefaultValue + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- + +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) + diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/PetApi.md b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/PetApi.md index 1a9eba14868f..5d9c6cb6f791 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/PetApi.md +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/PetApi.md @@ -18,7 +18,7 @@ Method | HTTP request | Description ## AddPet -> void AddPet (Pet body) +> void AddPet (Pet pet) Add a new pet to the store @@ -42,12 +42,12 @@ namespace Example Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN"; var apiInstance = new PetApi(Configuration.Default); - var body = new Pet(); // Pet | Pet object that needs to be added to the store + var pet = new Pet(); // Pet | Pet object that needs to be added to the store try { // Add a new pet to the store - apiInstance.AddPet(body); + apiInstance.AddPet(pet); } catch (ApiException e) { @@ -65,7 +65,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**Pet**](Pet.md)| Pet object that needs to be added to the store | + **pet** | [**Pet**](Pet.md)| Pet object that needs to be added to the store | ### Return type @@ -83,7 +83,6 @@ void (empty response body) ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **200** | successful operation | - | | **405** | Invalid input | - | [[Back to top]](#) @@ -161,7 +160,6 @@ void (empty response body) ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **200** | successful operation | - | | **400** | Invalid pet value | - | [[Back to top]](#) @@ -412,7 +410,7 @@ Name | Type | Description | Notes ## UpdatePet -> void UpdatePet (Pet body) +> void UpdatePet (Pet pet) Update an existing pet @@ -436,12 +434,12 @@ namespace Example Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN"; var apiInstance = new PetApi(Configuration.Default); - var body = new Pet(); // Pet | Pet object that needs to be added to the store + var pet = new Pet(); // Pet | Pet object that needs to be added to the store try { // Update an existing pet - apiInstance.UpdatePet(body); + apiInstance.UpdatePet(pet); } catch (ApiException e) { @@ -459,7 +457,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**Pet**](Pet.md)| Pet object that needs to be added to the store | + **pet** | [**Pet**](Pet.md)| Pet object that needs to be added to the store | ### Return type @@ -477,7 +475,6 @@ void (empty response body) ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **200** | successful operation | - | | **400** | Invalid ID supplied | - | | **404** | Pet not found | - | | **405** | Validation exception | - | diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/StoreApi.md b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/StoreApi.md index 57247772d4ff..d3c3c7c54053 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/StoreApi.md +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/StoreApi.md @@ -241,7 +241,7 @@ No authorization required ## PlaceOrder -> Order PlaceOrder (Order body) +> Order PlaceOrder (Order order) Place an order for a pet @@ -262,12 +262,12 @@ namespace Example { Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; var apiInstance = new StoreApi(Configuration.Default); - var body = new Order(); // Order | order placed for purchasing the pet + var order = new Order(); // Order | order placed for purchasing the pet try { // Place an order for a pet - Order result = apiInstance.PlaceOrder(body); + Order result = apiInstance.PlaceOrder(order); Debug.WriteLine(result); } catch (ApiException e) @@ -286,7 +286,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**Order**](Order.md)| order placed for purchasing the pet | + **order** | [**Order**](Order.md)| order placed for purchasing the pet | ### Return type @@ -298,7 +298,7 @@ No authorization required ### HTTP request headers -- **Content-Type**: Not defined +- **Content-Type**: application/json - **Accept**: application/xml, application/json ### HTTP response details diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/UserApi.md b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/UserApi.md index 1385d840413c..7c37179a9102 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/UserApi.md +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/docs/UserApi.md @@ -17,7 +17,7 @@ Method | HTTP request | Description ## CreateUser -> void CreateUser (User body) +> void CreateUser (User user) Create user @@ -40,12 +40,12 @@ namespace Example { Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; var apiInstance = new UserApi(Configuration.Default); - var body = new User(); // User | Created user object + var user = new User(); // User | Created user object try { // Create user - apiInstance.CreateUser(body); + apiInstance.CreateUser(user); } catch (ApiException e) { @@ -63,7 +63,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**User**](User.md)| Created user object | + **user** | [**User**](User.md)| Created user object | ### Return type @@ -75,7 +75,7 @@ No authorization required ### HTTP request headers -- **Content-Type**: Not defined +- **Content-Type**: application/json - **Accept**: Not defined ### HTTP response details @@ -91,7 +91,7 @@ No authorization required ## CreateUsersWithArrayInput -> void CreateUsersWithArrayInput (List body) +> void CreateUsersWithArrayInput (List user) Creates list of users with given input array @@ -112,12 +112,12 @@ namespace Example { Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; var apiInstance = new UserApi(Configuration.Default); - var body = new List(); // List | List of user object + var user = new List(); // List | List of user object try { // Creates list of users with given input array - apiInstance.CreateUsersWithArrayInput(body); + apiInstance.CreateUsersWithArrayInput(user); } catch (ApiException e) { @@ -135,7 +135,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**List<User>**](User.md)| List of user object | + **user** | [**List<User>**](User.md)| List of user object | ### Return type @@ -147,7 +147,7 @@ No authorization required ### HTTP request headers -- **Content-Type**: Not defined +- **Content-Type**: application/json - **Accept**: Not defined ### HTTP response details @@ -163,7 +163,7 @@ No authorization required ## CreateUsersWithListInput -> void CreateUsersWithListInput (List body) +> void CreateUsersWithListInput (List user) Creates list of users with given input array @@ -184,12 +184,12 @@ namespace Example { Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; var apiInstance = new UserApi(Configuration.Default); - var body = new List(); // List | List of user object + var user = new List(); // List | List of user object try { // Creates list of users with given input array - apiInstance.CreateUsersWithListInput(body); + apiInstance.CreateUsersWithListInput(user); } catch (ApiException e) { @@ -207,7 +207,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**List<User>**](User.md)| List of user object | + **user** | [**List<User>**](User.md)| List of user object | ### Return type @@ -219,7 +219,7 @@ No authorization required ### HTTP request headers -- **Content-Type**: Not defined +- **Content-Type**: application/json - **Accept**: Not defined ### HTTP response details @@ -529,7 +529,7 @@ No authorization required ## UpdateUser -> void UpdateUser (string username, User body) +> void UpdateUser (string username, User user) Updated user @@ -553,12 +553,12 @@ namespace Example Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; var apiInstance = new UserApi(Configuration.Default); var username = username_example; // string | name that need to be deleted - var body = new User(); // User | Updated user object + var user = new User(); // User | Updated user object try { // Updated user - apiInstance.UpdateUser(username, body); + apiInstance.UpdateUser(username, user); } catch (ApiException e) { @@ -577,7 +577,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **username** | **string**| name that need to be deleted | - **body** | [**User**](User.md)| Updated user object | + **user** | [**User**](User.md)| Updated user object | ### Return type @@ -589,7 +589,7 @@ No authorization required ### HTTP request headers -- **Content-Type**: Not defined +- **Content-Type**: application/json - **Accept**: Not defined ### HTTP response details diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Api/AnotherFakeApi.cs b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Api/AnotherFakeApi.cs index 1ad994047eb7..ced72f4e057b 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Api/AnotherFakeApi.cs +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Api/AnotherFakeApi.cs @@ -31,9 +31,9 @@ public interface IAnotherFakeApi : IApiAccessor /// To test special tags and operation ID starting with number /// /// Thrown when fails to make API call - /// client model + /// client model /// ModelClient - ModelClient Call123TestSpecialTags (ModelClient body); + ModelClient Call123TestSpecialTags (ModelClient modelClient); /// /// To test special tags @@ -42,9 +42,9 @@ public interface IAnotherFakeApi : IApiAccessor /// To test special tags and operation ID starting with number /// /// Thrown when fails to make API call - /// client model + /// client model /// ApiResponse of ModelClient - ApiResponse Call123TestSpecialTagsWithHttpInfo (ModelClient body); + ApiResponse Call123TestSpecialTagsWithHttpInfo (ModelClient modelClient); #endregion Synchronous Operations #region Asynchronous Operations /// @@ -54,9 +54,9 @@ public interface IAnotherFakeApi : IApiAccessor /// To test special tags and operation ID starting with number /// /// Thrown when fails to make API call - /// client model + /// client model /// Task of ModelClient - System.Threading.Tasks.Task Call123TestSpecialTagsAsync (ModelClient body); + System.Threading.Tasks.Task Call123TestSpecialTagsAsync (ModelClient modelClient); /// /// To test special tags @@ -65,9 +65,9 @@ public interface IAnotherFakeApi : IApiAccessor /// To test special tags and operation ID starting with number /// /// Thrown when fails to make API call - /// client model + /// client model /// Task of ApiResponse (ModelClient) - System.Threading.Tasks.Task> Call123TestSpecialTagsAsyncWithHttpInfo (ModelClient body); + System.Threading.Tasks.Task> Call123TestSpecialTagsAsyncWithHttpInfo (ModelClient modelClient); #endregion Asynchronous Operations } @@ -183,11 +183,11 @@ public void AddDefaultHeader(string key, string value) /// To test special tags To test special tags and operation ID starting with number /// /// Thrown when fails to make API call - /// client model + /// client model /// ModelClient - public ModelClient Call123TestSpecialTags (ModelClient body) + public ModelClient Call123TestSpecialTags (ModelClient modelClient) { - ApiResponse localVarResponse = Call123TestSpecialTagsWithHttpInfo(body); + ApiResponse localVarResponse = Call123TestSpecialTagsWithHttpInfo(modelClient); return localVarResponse.Data; } @@ -195,13 +195,13 @@ public ModelClient Call123TestSpecialTags (ModelClient body) /// To test special tags To test special tags and operation ID starting with number /// /// Thrown when fails to make API call - /// client model + /// client model /// ApiResponse of ModelClient - public ApiResponse Call123TestSpecialTagsWithHttpInfo (ModelClient body) + public ApiResponse Call123TestSpecialTagsWithHttpInfo (ModelClient modelClient) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling AnotherFakeApi->Call123TestSpecialTags"); + // verify the required parameter 'modelClient' is set + if (modelClient == null) + throw new ApiException(400, "Missing required parameter 'modelClient' when calling AnotherFakeApi->Call123TestSpecialTags"); var localVarPath = "./another-fake/dummy"; var localVarPathParams = new Dictionary(); @@ -225,13 +225,13 @@ public ApiResponse Call123TestSpecialTagsWithHttpInfo (ModelClient if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (modelClient != null && modelClient.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(modelClient); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = modelClient; // byte array } @@ -257,11 +257,11 @@ public ApiResponse Call123TestSpecialTagsWithHttpInfo (ModelClient /// To test special tags To test special tags and operation ID starting with number /// /// Thrown when fails to make API call - /// client model + /// client model /// Task of ModelClient - public async System.Threading.Tasks.Task Call123TestSpecialTagsAsync (ModelClient body) + public async System.Threading.Tasks.Task Call123TestSpecialTagsAsync (ModelClient modelClient) { - ApiResponse localVarResponse = await Call123TestSpecialTagsAsyncWithHttpInfo(body); + ApiResponse localVarResponse = await Call123TestSpecialTagsAsyncWithHttpInfo(modelClient); return localVarResponse.Data; } @@ -270,13 +270,13 @@ public async System.Threading.Tasks.Task Call123TestSpecialTagsAsyn /// To test special tags To test special tags and operation ID starting with number /// /// Thrown when fails to make API call - /// client model + /// client model /// Task of ApiResponse (ModelClient) - public async System.Threading.Tasks.Task> Call123TestSpecialTagsAsyncWithHttpInfo (ModelClient body) + public async System.Threading.Tasks.Task> Call123TestSpecialTagsAsyncWithHttpInfo (ModelClient modelClient) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling AnotherFakeApi->Call123TestSpecialTags"); + // verify the required parameter 'modelClient' is set + if (modelClient == null) + throw new ApiException(400, "Missing required parameter 'modelClient' when calling AnotherFakeApi->Call123TestSpecialTags"); var localVarPath = "./another-fake/dummy"; var localVarPathParams = new Dictionary(); @@ -300,13 +300,13 @@ public async System.Threading.Tasks.Task> Call123TestSp if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (modelClient != null && modelClient.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(modelClient); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = modelClient; // byte array } diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Api/DefaultApi.cs b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Api/DefaultApi.cs index ff0cb9b0b5d8..75b49ea3ee28 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Api/DefaultApi.cs +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Api/DefaultApi.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -85,6 +85,17 @@ public DefaultApi(String basePath) ExceptionFactory = Org.OpenAPITools.Client.Configuration.DefaultExceptionFactory; } + /// + /// Initializes a new instance of the class + /// + /// + public DefaultApi() + { + this.Configuration = Org.OpenAPITools.Client.Configuration.Default; + + ExceptionFactory = Org.OpenAPITools.Client.Configuration.DefaultExceptionFactory; + } + /// /// Initializes a new instance of the class /// using Configuration object @@ -180,7 +191,7 @@ public InlineResponseDefault FooGet () /// /// Thrown when fails to make API call /// ApiResponse of InlineResponseDefault - public ApiResponse< InlineResponseDefault > FooGetWithHttpInfo () + public ApiResponse FooGetWithHttpInfo () { var localVarPath = "./foo"; @@ -220,7 +231,7 @@ public ApiResponse< InlineResponseDefault > FooGetWithHttpInfo () } return new ApiResponse(localVarStatusCode, - localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()), + localVarResponse.Headers.ToDictionary(x => x.Key, x => string.Join(",", x.Value)), (InlineResponseDefault) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(InlineResponseDefault))); } @@ -281,7 +292,7 @@ public async System.Threading.Tasks.Task> Foo } return new ApiResponse(localVarStatusCode, - localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()), + localVarResponse.Headers.ToDictionary(x => x.Key, x => string.Join(",", x.Value)), (InlineResponseDefault) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(InlineResponseDefault))); } diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Api/FakeApi.cs b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Api/FakeApi.cs index e0b9c8bbe2f9..5f1733846776 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Api/FakeApi.cs +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Api/FakeApi.cs @@ -25,26 +25,49 @@ public interface IFakeApi : IApiAccessor { #region Synchronous Operations /// - /// creates an XmlItem + /// Health check endpoint /// /// - /// this route creates an XmlItem + /// + /// + /// Thrown when fails to make API call + /// HealthCheckResult + HealthCheckResult FakeHealthGet (); + + /// + /// Health check endpoint + /// + /// + /// + /// + /// Thrown when fails to make API call + /// ApiResponse of HealthCheckResult + ApiResponse FakeHealthGetWithHttpInfo (); + /// + /// test http signature authentication + /// + /// + /// /// /// Thrown when fails to make API call - /// XmlItem Body + /// Pet object that needs to be added to the store + /// query parameter (optional) + /// header parameter (optional) /// - void CreateXmlItem (XmlItem xmlItem); + void FakeHttpSignatureTest (Pet pet, string query1 = default(string), string header1 = default(string)); /// - /// creates an XmlItem + /// test http signature authentication /// /// - /// this route creates an XmlItem + /// /// /// Thrown when fails to make API call - /// XmlItem Body + /// Pet object that needs to be added to the store + /// query parameter (optional) + /// header parameter (optional) /// ApiResponse of Object(void) - ApiResponse CreateXmlItemWithHttpInfo (XmlItem xmlItem); + ApiResponse FakeHttpSignatureTestWithHttpInfo (Pet pet, string query1 = default(string), string header1 = default(string)); /// /// /// @@ -73,9 +96,9 @@ public interface IFakeApi : IApiAccessor /// Test serialization of object with outer number type /// /// Thrown when fails to make API call - /// Input composite as post body (optional) + /// Input composite as post body (optional) /// OuterComposite - OuterComposite FakeOuterCompositeSerialize (OuterComposite body = default(OuterComposite)); + OuterComposite FakeOuterCompositeSerialize (OuterComposite outerComposite = default(OuterComposite)); /// /// @@ -84,9 +107,9 @@ public interface IFakeApi : IApiAccessor /// Test serialization of object with outer number type /// /// Thrown when fails to make API call - /// Input composite as post body (optional) + /// Input composite as post body (optional) /// ApiResponse of OuterComposite - ApiResponse FakeOuterCompositeSerializeWithHttpInfo (OuterComposite body = default(OuterComposite)); + ApiResponse FakeOuterCompositeSerializeWithHttpInfo (OuterComposite outerComposite = default(OuterComposite)); /// /// /// @@ -136,9 +159,9 @@ public interface IFakeApi : IApiAccessor /// For this test, the body for this request much reference a schema named `File`. /// /// Thrown when fails to make API call - /// + /// /// - void TestBodyWithFileSchema (FileSchemaTestClass body); + void TestBodyWithFileSchema (FileSchemaTestClass fileSchemaTestClass); /// /// @@ -147,9 +170,9 @@ public interface IFakeApi : IApiAccessor /// For this test, the body for this request much reference a schema named `File`. /// /// Thrown when fails to make API call - /// + /// /// ApiResponse of Object(void) - ApiResponse TestBodyWithFileSchemaWithHttpInfo (FileSchemaTestClass body); + ApiResponse TestBodyWithFileSchemaWithHttpInfo (FileSchemaTestClass fileSchemaTestClass); /// /// /// @@ -158,9 +181,9 @@ public interface IFakeApi : IApiAccessor /// /// Thrown when fails to make API call /// - /// + /// /// - void TestBodyWithQueryParams (string query, User body); + void TestBodyWithQueryParams (string query, User user); /// /// @@ -170,9 +193,9 @@ public interface IFakeApi : IApiAccessor /// /// Thrown when fails to make API call /// - /// + /// /// ApiResponse of Object(void) - ApiResponse TestBodyWithQueryParamsWithHttpInfo (string query, User body); + ApiResponse TestBodyWithQueryParamsWithHttpInfo (string query, User user); /// /// To test \"client\" model /// @@ -180,9 +203,9 @@ public interface IFakeApi : IApiAccessor /// To test \"client\" model /// /// Thrown when fails to make API call - /// client model + /// client model /// ModelClient - ModelClient TestClientModel (ModelClient body); + ModelClient TestClientModel (ModelClient modelClient); /// /// To test \"client\" model @@ -191,14 +214,14 @@ public interface IFakeApi : IApiAccessor /// To test \"client\" model /// /// Thrown when fails to make API call - /// client model + /// client model /// ApiResponse of ModelClient - ApiResponse TestClientModelWithHttpInfo (ModelClient body); + ApiResponse TestClientModelWithHttpInfo (ModelClient modelClient); /// - /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 /// /// - /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 /// /// Thrown when fails to make API call /// None @@ -219,10 +242,10 @@ public interface IFakeApi : IApiAccessor void TestEndpointParameters (decimal number, double _double, string patternWithoutDelimiter, byte[] _byte, int? integer = default(int?), int? int32 = default(int?), long? int64 = default(long?), float? _float = default(float?), string _string = default(string), System.IO.Stream binary = default(System.IO.Stream), DateTime? date = default(DateTime?), DateTime? dateTime = default(DateTime?), string password = default(string), string callback = default(string)); /// - /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 /// /// - /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 /// /// Thrown when fails to make API call /// None @@ -314,9 +337,9 @@ public interface IFakeApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// request body + /// request body /// - void TestInlineAdditionalProperties (Dictionary param); + void TestInlineAdditionalProperties (Dictionary requestBody); /// /// test inline additionalProperties @@ -325,9 +348,9 @@ public interface IFakeApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// request body + /// request body /// ApiResponse of Object(void) - ApiResponse TestInlineAdditionalPropertiesWithHttpInfo (Dictionary param); + ApiResponse TestInlineAdditionalPropertiesWithHttpInfo (Dictionary requestBody); /// /// test json serialization of form data /// @@ -383,26 +406,49 @@ public interface IFakeApi : IApiAccessor #endregion Synchronous Operations #region Asynchronous Operations /// - /// creates an XmlItem + /// Health check endpoint + /// + /// + /// + /// + /// Thrown when fails to make API call + /// Task of HealthCheckResult + System.Threading.Tasks.Task FakeHealthGetAsync (); + + /// + /// Health check endpoint /// /// - /// this route creates an XmlItem + /// /// /// Thrown when fails to make API call - /// XmlItem Body + /// Task of ApiResponse (HealthCheckResult) + System.Threading.Tasks.Task> FakeHealthGetAsyncWithHttpInfo (); + /// + /// test http signature authentication + /// + /// + /// + /// + /// Thrown when fails to make API call + /// Pet object that needs to be added to the store + /// query parameter (optional) + /// header parameter (optional) /// Task of void - System.Threading.Tasks.Task CreateXmlItemAsync (XmlItem xmlItem); + System.Threading.Tasks.Task FakeHttpSignatureTestAsync (Pet pet, string query1 = default(string), string header1 = default(string)); /// - /// creates an XmlItem + /// test http signature authentication /// /// - /// this route creates an XmlItem + /// /// /// Thrown when fails to make API call - /// XmlItem Body + /// Pet object that needs to be added to the store + /// query parameter (optional) + /// header parameter (optional) /// Task of ApiResponse - System.Threading.Tasks.Task> CreateXmlItemAsyncWithHttpInfo (XmlItem xmlItem); + System.Threading.Tasks.Task> FakeHttpSignatureTestAsyncWithHttpInfo (Pet pet, string query1 = default(string), string header1 = default(string)); /// /// /// @@ -431,9 +477,9 @@ public interface IFakeApi : IApiAccessor /// Test serialization of object with outer number type /// /// Thrown when fails to make API call - /// Input composite as post body (optional) + /// Input composite as post body (optional) /// Task of OuterComposite - System.Threading.Tasks.Task FakeOuterCompositeSerializeAsync (OuterComposite body = default(OuterComposite)); + System.Threading.Tasks.Task FakeOuterCompositeSerializeAsync (OuterComposite outerComposite = default(OuterComposite)); /// /// @@ -442,9 +488,9 @@ public interface IFakeApi : IApiAccessor /// Test serialization of object with outer number type /// /// Thrown when fails to make API call - /// Input composite as post body (optional) + /// Input composite as post body (optional) /// Task of ApiResponse (OuterComposite) - System.Threading.Tasks.Task> FakeOuterCompositeSerializeAsyncWithHttpInfo (OuterComposite body = default(OuterComposite)); + System.Threading.Tasks.Task> FakeOuterCompositeSerializeAsyncWithHttpInfo (OuterComposite outerComposite = default(OuterComposite)); /// /// /// @@ -494,9 +540,9 @@ public interface IFakeApi : IApiAccessor /// For this test, the body for this request much reference a schema named `File`. /// /// Thrown when fails to make API call - /// + /// /// Task of void - System.Threading.Tasks.Task TestBodyWithFileSchemaAsync (FileSchemaTestClass body); + System.Threading.Tasks.Task TestBodyWithFileSchemaAsync (FileSchemaTestClass fileSchemaTestClass); /// /// @@ -505,9 +551,9 @@ public interface IFakeApi : IApiAccessor /// For this test, the body for this request much reference a schema named `File`. /// /// Thrown when fails to make API call - /// + /// /// Task of ApiResponse - System.Threading.Tasks.Task> TestBodyWithFileSchemaAsyncWithHttpInfo (FileSchemaTestClass body); + System.Threading.Tasks.Task> TestBodyWithFileSchemaAsyncWithHttpInfo (FileSchemaTestClass fileSchemaTestClass); /// /// /// @@ -516,9 +562,9 @@ public interface IFakeApi : IApiAccessor /// /// Thrown when fails to make API call /// - /// + /// /// Task of void - System.Threading.Tasks.Task TestBodyWithQueryParamsAsync (string query, User body); + System.Threading.Tasks.Task TestBodyWithQueryParamsAsync (string query, User user); /// /// @@ -528,9 +574,9 @@ public interface IFakeApi : IApiAccessor /// /// Thrown when fails to make API call /// - /// + /// /// Task of ApiResponse - System.Threading.Tasks.Task> TestBodyWithQueryParamsAsyncWithHttpInfo (string query, User body); + System.Threading.Tasks.Task> TestBodyWithQueryParamsAsyncWithHttpInfo (string query, User user); /// /// To test \"client\" model /// @@ -538,9 +584,9 @@ public interface IFakeApi : IApiAccessor /// To test \"client\" model /// /// Thrown when fails to make API call - /// client model + /// client model /// Task of ModelClient - System.Threading.Tasks.Task TestClientModelAsync (ModelClient body); + System.Threading.Tasks.Task TestClientModelAsync (ModelClient modelClient); /// /// To test \"client\" model @@ -549,14 +595,14 @@ public interface IFakeApi : IApiAccessor /// To test \"client\" model /// /// Thrown when fails to make API call - /// client model + /// client model /// Task of ApiResponse (ModelClient) - System.Threading.Tasks.Task> TestClientModelAsyncWithHttpInfo (ModelClient body); + System.Threading.Tasks.Task> TestClientModelAsyncWithHttpInfo (ModelClient modelClient); /// - /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 /// /// - /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 /// /// Thrown when fails to make API call /// None @@ -577,10 +623,10 @@ public interface IFakeApi : IApiAccessor System.Threading.Tasks.Task TestEndpointParametersAsync (decimal number, double _double, string patternWithoutDelimiter, byte[] _byte, int? integer = default(int?), int? int32 = default(int?), long? int64 = default(long?), float? _float = default(float?), string _string = default(string), System.IO.Stream binary = default(System.IO.Stream), DateTime? date = default(DateTime?), DateTime? dateTime = default(DateTime?), string password = default(string), string callback = default(string)); /// - /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 /// /// - /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 /// /// Thrown when fails to make API call /// None @@ -672,9 +718,9 @@ public interface IFakeApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// request body + /// request body /// Task of void - System.Threading.Tasks.Task TestInlineAdditionalPropertiesAsync (Dictionary param); + System.Threading.Tasks.Task TestInlineAdditionalPropertiesAsync (Dictionary requestBody); /// /// test inline additionalProperties @@ -683,9 +729,9 @@ public interface IFakeApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// request body + /// request body /// Task of ApiResponse - System.Threading.Tasks.Task> TestInlineAdditionalPropertiesAsyncWithHttpInfo (Dictionary param); + System.Threading.Tasks.Task> TestInlineAdditionalPropertiesAsyncWithHttpInfo (Dictionary requestBody); /// /// test json serialization of form data /// @@ -850,29 +896,154 @@ public void AddDefaultHeader(string key, string value) } /// - /// creates an XmlItem this route creates an XmlItem + /// Health check endpoint + /// + /// Thrown when fails to make API call + /// HealthCheckResult + public HealthCheckResult FakeHealthGet () + { + ApiResponse localVarResponse = FakeHealthGetWithHttpInfo(); + return localVarResponse.Data; + } + + /// + /// Health check endpoint + /// + /// Thrown when fails to make API call + /// ApiResponse of HealthCheckResult + public ApiResponse FakeHealthGetWithHttpInfo () + { + + var localVarPath = "./fake/health"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new List>(); + var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new Dictionary(); + Object localVarPostBody = null; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + }; + String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + "application/json" + }; + String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + + + // make the HTTP request + IRestResponse localVarResponse = (IRestResponse) this.Configuration.ApiClient.CallApi(localVarPath, + Method.GET, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, + localVarPathParams, localVarHttpContentType); + + int localVarStatusCode = (int) localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("FakeHealthGet", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Key, x => string.Join(",", x.Value)), + (HealthCheckResult) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(HealthCheckResult))); + } + + /// + /// Health check endpoint + /// + /// Thrown when fails to make API call + /// Task of HealthCheckResult + public async System.Threading.Tasks.Task FakeHealthGetAsync () + { + ApiResponse localVarResponse = await FakeHealthGetAsyncWithHttpInfo(); + return localVarResponse.Data; + + } + + /// + /// Health check endpoint /// /// Thrown when fails to make API call - /// XmlItem Body + /// Task of ApiResponse (HealthCheckResult) + public async System.Threading.Tasks.Task> FakeHealthGetAsyncWithHttpInfo () + { + + var localVarPath = "./fake/health"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new List>(); + var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new Dictionary(); + Object localVarPostBody = null; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + }; + String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + "application/json" + }; + String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + + + // make the HTTP request + IRestResponse localVarResponse = (IRestResponse) await this.Configuration.ApiClient.CallApiAsync(localVarPath, + Method.GET, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, + localVarPathParams, localVarHttpContentType); + + int localVarStatusCode = (int) localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("FakeHealthGet", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Key, x => string.Join(",", x.Value)), + (HealthCheckResult) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(HealthCheckResult))); + } + + /// + /// test http signature authentication + /// + /// Thrown when fails to make API call + /// Pet object that needs to be added to the store + /// query parameter (optional) + /// header parameter (optional) /// - public void CreateXmlItem (XmlItem xmlItem) + public void FakeHttpSignatureTest (Pet pet, string query1 = default(string), string header1 = default(string)) { - CreateXmlItemWithHttpInfo(xmlItem); + FakeHttpSignatureTestWithHttpInfo(pet, query1, header1); } /// - /// creates an XmlItem this route creates an XmlItem + /// test http signature authentication /// /// Thrown when fails to make API call - /// XmlItem Body + /// Pet object that needs to be added to the store + /// query parameter (optional) + /// header parameter (optional) /// ApiResponse of Object(void) - public ApiResponse CreateXmlItemWithHttpInfo (XmlItem xmlItem) + public ApiResponse FakeHttpSignatureTestWithHttpInfo (Pet pet, string query1 = default(string), string header1 = default(string)) { - // verify the required parameter 'xmlItem' is set - if (xmlItem == null) - throw new ApiException(400, "Missing required parameter 'xmlItem' when calling FakeApi->CreateXmlItem"); + // verify the required parameter 'pet' is set + if (pet == null) + throw new ApiException(400, "Missing required parameter 'pet' when calling FakeApi->FakeHttpSignatureTest"); - var localVarPath = "./fake/create_xml_item"; + var localVarPath = "./fake/http-signature-test"; var localVarPathParams = new Dictionary(); var localVarQueryParams = new List>(); var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader); @@ -882,12 +1053,8 @@ public ApiResponse CreateXmlItemWithHttpInfo (XmlItem xmlItem) // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { - "application/xml", - "application/xml; charset=utf-8", - "application/xml; charset=utf-16", - "text/xml", - "text/xml; charset=utf-8", - "text/xml; charset=utf-16" + "application/json", + "application/xml" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -898,26 +1065,29 @@ public ApiResponse CreateXmlItemWithHttpInfo (XmlItem xmlItem) if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (xmlItem != null && xmlItem.GetType() != typeof(byte[])) + if (query1 != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "query_1", query1)); // query parameter + if (header1 != null) localVarHeaderParams.Add("header_1", this.Configuration.ApiClient.ParameterToString(header1)); // header parameter + if (pet != null && pet.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(xmlItem); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(pet); // http body (model) parameter } else { - localVarPostBody = xmlItem; // byte array + localVarPostBody = pet; // byte array } + // authentication (http_signature_test) required // make the HTTP request IRestResponse localVarResponse = (IRestResponse) this.Configuration.ApiClient.CallApi(localVarPath, - Method.POST, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, + Method.GET, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, localVarPathParams, localVarHttpContentType); int localVarStatusCode = (int) localVarResponse.StatusCode; if (ExceptionFactory != null) { - Exception exception = ExceptionFactory("CreateXmlItem", localVarResponse); + Exception exception = ExceptionFactory("FakeHttpSignatureTest", localVarResponse); if (exception != null) throw exception; } @@ -927,30 +1097,34 @@ public ApiResponse CreateXmlItemWithHttpInfo (XmlItem xmlItem) } /// - /// creates an XmlItem this route creates an XmlItem + /// test http signature authentication /// /// Thrown when fails to make API call - /// XmlItem Body + /// Pet object that needs to be added to the store + /// query parameter (optional) + /// header parameter (optional) /// Task of void - public async System.Threading.Tasks.Task CreateXmlItemAsync (XmlItem xmlItem) + public async System.Threading.Tasks.Task FakeHttpSignatureTestAsync (Pet pet, string query1 = default(string), string header1 = default(string)) { - await CreateXmlItemAsyncWithHttpInfo(xmlItem); + await FakeHttpSignatureTestAsyncWithHttpInfo(pet, query1, header1); } /// - /// creates an XmlItem this route creates an XmlItem + /// test http signature authentication /// /// Thrown when fails to make API call - /// XmlItem Body + /// Pet object that needs to be added to the store + /// query parameter (optional) + /// header parameter (optional) /// Task of ApiResponse - public async System.Threading.Tasks.Task> CreateXmlItemAsyncWithHttpInfo (XmlItem xmlItem) + public async System.Threading.Tasks.Task> FakeHttpSignatureTestAsyncWithHttpInfo (Pet pet, string query1 = default(string), string header1 = default(string)) { - // verify the required parameter 'xmlItem' is set - if (xmlItem == null) - throw new ApiException(400, "Missing required parameter 'xmlItem' when calling FakeApi->CreateXmlItem"); + // verify the required parameter 'pet' is set + if (pet == null) + throw new ApiException(400, "Missing required parameter 'pet' when calling FakeApi->FakeHttpSignatureTest"); - var localVarPath = "./fake/create_xml_item"; + var localVarPath = "./fake/http-signature-test"; var localVarPathParams = new Dictionary(); var localVarQueryParams = new List>(); var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader); @@ -960,12 +1134,8 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { - "application/xml", - "application/xml; charset=utf-8", - "application/xml; charset=utf-16", - "text/xml", - "text/xml; charset=utf-8", - "text/xml; charset=utf-16" + "application/json", + "application/xml" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -976,26 +1146,29 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (xmlItem != null && xmlItem.GetType() != typeof(byte[])) + if (query1 != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "query_1", query1)); // query parameter + if (header1 != null) localVarHeaderParams.Add("header_1", this.Configuration.ApiClient.ParameterToString(header1)); // header parameter + if (pet != null && pet.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(xmlItem); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(pet); // http body (model) parameter } else { - localVarPostBody = xmlItem; // byte array + localVarPostBody = pet; // byte array } + // authentication (http_signature_test) required // make the HTTP request IRestResponse localVarResponse = (IRestResponse) await this.Configuration.ApiClient.CallApiAsync(localVarPath, - Method.POST, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, + Method.GET, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, localVarPathParams, localVarHttpContentType); int localVarStatusCode = (int) localVarResponse.StatusCode; if (ExceptionFactory != null) { - Exception exception = ExceptionFactory("CreateXmlItem", localVarResponse); + Exception exception = ExceptionFactory("FakeHttpSignatureTest", localVarResponse); if (exception != null) throw exception; } @@ -1035,6 +1208,7 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -1106,6 +1280,7 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -1149,11 +1324,11 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync /// Test serialization of object with outer number type /// /// Thrown when fails to make API call - /// Input composite as post body (optional) + /// Input composite as post body (optional) /// OuterComposite - public OuterComposite FakeOuterCompositeSerialize (OuterComposite body = default(OuterComposite)) + public OuterComposite FakeOuterCompositeSerialize (OuterComposite outerComposite = default(OuterComposite)) { - ApiResponse localVarResponse = FakeOuterCompositeSerializeWithHttpInfo(body); + ApiResponse localVarResponse = FakeOuterCompositeSerializeWithHttpInfo(outerComposite); return localVarResponse.Data; } @@ -1161,9 +1336,9 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync /// Test serialization of object with outer number type /// /// Thrown when fails to make API call - /// Input composite as post body (optional) + /// Input composite as post body (optional) /// ApiResponse of OuterComposite - public ApiResponse FakeOuterCompositeSerializeWithHttpInfo (OuterComposite body = default(OuterComposite)) + public ApiResponse FakeOuterCompositeSerializeWithHttpInfo (OuterComposite outerComposite = default(OuterComposite)) { var localVarPath = "./fake/outer/composite"; @@ -1176,6 +1351,7 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -1187,13 +1363,13 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (outerComposite != null && outerComposite.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(outerComposite); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = outerComposite; // byte array } @@ -1219,11 +1395,11 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync /// Test serialization of object with outer number type /// /// Thrown when fails to make API call - /// Input composite as post body (optional) + /// Input composite as post body (optional) /// Task of OuterComposite - public async System.Threading.Tasks.Task FakeOuterCompositeSerializeAsync (OuterComposite body = default(OuterComposite)) + public async System.Threading.Tasks.Task FakeOuterCompositeSerializeAsync (OuterComposite outerComposite = default(OuterComposite)) { - ApiResponse localVarResponse = await FakeOuterCompositeSerializeAsyncWithHttpInfo(body); + ApiResponse localVarResponse = await FakeOuterCompositeSerializeAsyncWithHttpInfo(outerComposite); return localVarResponse.Data; } @@ -1232,9 +1408,9 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync /// Test serialization of object with outer number type /// /// Thrown when fails to make API call - /// Input composite as post body (optional) + /// Input composite as post body (optional) /// Task of ApiResponse (OuterComposite) - public async System.Threading.Tasks.Task> FakeOuterCompositeSerializeAsyncWithHttpInfo (OuterComposite body = default(OuterComposite)) + public async System.Threading.Tasks.Task> FakeOuterCompositeSerializeAsyncWithHttpInfo (OuterComposite outerComposite = default(OuterComposite)) { var localVarPath = "./fake/outer/composite"; @@ -1247,6 +1423,7 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -1258,13 +1435,13 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (outerComposite != null && outerComposite.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(outerComposite); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = outerComposite; // byte array } @@ -1317,6 +1494,7 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -1388,6 +1566,7 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -1458,6 +1637,7 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -1529,6 +1709,7 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -1572,24 +1753,24 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync /// For this test, the body for this request much reference a schema named `File`. /// /// Thrown when fails to make API call - /// + /// /// - public void TestBodyWithFileSchema (FileSchemaTestClass body) + public void TestBodyWithFileSchema (FileSchemaTestClass fileSchemaTestClass) { - TestBodyWithFileSchemaWithHttpInfo(body); + TestBodyWithFileSchemaWithHttpInfo(fileSchemaTestClass); } /// /// For this test, the body for this request much reference a schema named `File`. /// /// Thrown when fails to make API call - /// + /// /// ApiResponse of Object(void) - public ApiResponse TestBodyWithFileSchemaWithHttpInfo (FileSchemaTestClass body) + public ApiResponse TestBodyWithFileSchemaWithHttpInfo (FileSchemaTestClass fileSchemaTestClass) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling FakeApi->TestBodyWithFileSchema"); + // verify the required parameter 'fileSchemaTestClass' is set + if (fileSchemaTestClass == null) + throw new ApiException(400, "Missing required parameter 'fileSchemaTestClass' when calling FakeApi->TestBodyWithFileSchema"); var localVarPath = "./fake/body-with-file-schema"; var localVarPathParams = new Dictionary(); @@ -1612,13 +1793,13 @@ public ApiResponse TestBodyWithFileSchemaWithHttpInfo (FileSchemaTestCla if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (fileSchemaTestClass != null && fileSchemaTestClass.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(fileSchemaTestClass); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = fileSchemaTestClass; // byte array } @@ -1644,11 +1825,11 @@ public ApiResponse TestBodyWithFileSchemaWithHttpInfo (FileSchemaTestCla /// For this test, the body for this request much reference a schema named `File`. /// /// Thrown when fails to make API call - /// + /// /// Task of void - public async System.Threading.Tasks.Task TestBodyWithFileSchemaAsync (FileSchemaTestClass body) + public async System.Threading.Tasks.Task TestBodyWithFileSchemaAsync (FileSchemaTestClass fileSchemaTestClass) { - await TestBodyWithFileSchemaAsyncWithHttpInfo(body); + await TestBodyWithFileSchemaAsyncWithHttpInfo(fileSchemaTestClass); } @@ -1656,13 +1837,13 @@ public async System.Threading.Tasks.Task TestBodyWithFileSchemaAsync (FileSchema /// For this test, the body for this request much reference a schema named `File`. /// /// Thrown when fails to make API call - /// + /// /// Task of ApiResponse - public async System.Threading.Tasks.Task> TestBodyWithFileSchemaAsyncWithHttpInfo (FileSchemaTestClass body) + public async System.Threading.Tasks.Task> TestBodyWithFileSchemaAsyncWithHttpInfo (FileSchemaTestClass fileSchemaTestClass) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling FakeApi->TestBodyWithFileSchema"); + // verify the required parameter 'fileSchemaTestClass' is set + if (fileSchemaTestClass == null) + throw new ApiException(400, "Missing required parameter 'fileSchemaTestClass' when calling FakeApi->TestBodyWithFileSchema"); var localVarPath = "./fake/body-with-file-schema"; var localVarPathParams = new Dictionary(); @@ -1685,13 +1866,13 @@ public async System.Threading.Tasks.Task> TestBodyWithFileSc if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (fileSchemaTestClass != null && fileSchemaTestClass.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(fileSchemaTestClass); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = fileSchemaTestClass; // byte array } @@ -1718,11 +1899,11 @@ public async System.Threading.Tasks.Task> TestBodyWithFileSc /// /// Thrown when fails to make API call /// - /// + /// /// - public void TestBodyWithQueryParams (string query, User body) + public void TestBodyWithQueryParams (string query, User user) { - TestBodyWithQueryParamsWithHttpInfo(query, body); + TestBodyWithQueryParamsWithHttpInfo(query, user); } /// @@ -1730,16 +1911,16 @@ public void TestBodyWithQueryParams (string query, User body) /// /// Thrown when fails to make API call /// - /// + /// /// ApiResponse of Object(void) - public ApiResponse TestBodyWithQueryParamsWithHttpInfo (string query, User body) + public ApiResponse TestBodyWithQueryParamsWithHttpInfo (string query, User user) { // verify the required parameter 'query' is set if (query == null) throw new ApiException(400, "Missing required parameter 'query' when calling FakeApi->TestBodyWithQueryParams"); - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling FakeApi->TestBodyWithQueryParams"); + // verify the required parameter 'user' is set + if (user == null) + throw new ApiException(400, "Missing required parameter 'user' when calling FakeApi->TestBodyWithQueryParams"); var localVarPath = "./fake/body-with-query-params"; var localVarPathParams = new Dictionary(); @@ -1763,13 +1944,13 @@ public ApiResponse TestBodyWithQueryParamsWithHttpInfo (string query, Us localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); if (query != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "query", query)); // query parameter - if (body != null && body.GetType() != typeof(byte[])) + if (user != null && user.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(user); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = user; // byte array } @@ -1796,11 +1977,11 @@ public ApiResponse TestBodyWithQueryParamsWithHttpInfo (string query, Us /// /// Thrown when fails to make API call /// - /// + /// /// Task of void - public async System.Threading.Tasks.Task TestBodyWithQueryParamsAsync (string query, User body) + public async System.Threading.Tasks.Task TestBodyWithQueryParamsAsync (string query, User user) { - await TestBodyWithQueryParamsAsyncWithHttpInfo(query, body); + await TestBodyWithQueryParamsAsyncWithHttpInfo(query, user); } @@ -1809,16 +1990,16 @@ public async System.Threading.Tasks.Task TestBodyWithQueryParamsAsync (string qu /// /// Thrown when fails to make API call /// - /// + /// /// Task of ApiResponse - public async System.Threading.Tasks.Task> TestBodyWithQueryParamsAsyncWithHttpInfo (string query, User body) + public async System.Threading.Tasks.Task> TestBodyWithQueryParamsAsyncWithHttpInfo (string query, User user) { // verify the required parameter 'query' is set if (query == null) throw new ApiException(400, "Missing required parameter 'query' when calling FakeApi->TestBodyWithQueryParams"); - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling FakeApi->TestBodyWithQueryParams"); + // verify the required parameter 'user' is set + if (user == null) + throw new ApiException(400, "Missing required parameter 'user' when calling FakeApi->TestBodyWithQueryParams"); var localVarPath = "./fake/body-with-query-params"; var localVarPathParams = new Dictionary(); @@ -1842,13 +2023,13 @@ public async System.Threading.Tasks.Task> TestBodyWithQueryP localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); if (query != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "query", query)); // query parameter - if (body != null && body.GetType() != typeof(byte[])) + if (user != null && user.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(user); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = user; // byte array } @@ -1874,11 +2055,11 @@ public async System.Threading.Tasks.Task> TestBodyWithQueryP /// To test \"client\" model To test \"client\" model /// /// Thrown when fails to make API call - /// client model + /// client model /// ModelClient - public ModelClient TestClientModel (ModelClient body) + public ModelClient TestClientModel (ModelClient modelClient) { - ApiResponse localVarResponse = TestClientModelWithHttpInfo(body); + ApiResponse localVarResponse = TestClientModelWithHttpInfo(modelClient); return localVarResponse.Data; } @@ -1886,13 +2067,13 @@ public ModelClient TestClientModel (ModelClient body) /// To test \"client\" model To test \"client\" model /// /// Thrown when fails to make API call - /// client model + /// client model /// ApiResponse of ModelClient - public ApiResponse TestClientModelWithHttpInfo (ModelClient body) + public ApiResponse TestClientModelWithHttpInfo (ModelClient modelClient) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling FakeApi->TestClientModel"); + // verify the required parameter 'modelClient' is set + if (modelClient == null) + throw new ApiException(400, "Missing required parameter 'modelClient' when calling FakeApi->TestClientModel"); var localVarPath = "./fake"; var localVarPathParams = new Dictionary(); @@ -1916,13 +2097,13 @@ public ApiResponse TestClientModelWithHttpInfo (ModelClient body) if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (modelClient != null && modelClient.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(modelClient); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = modelClient; // byte array } @@ -1948,11 +2129,11 @@ public ApiResponse TestClientModelWithHttpInfo (ModelClient body) /// To test \"client\" model To test \"client\" model /// /// Thrown when fails to make API call - /// client model + /// client model /// Task of ModelClient - public async System.Threading.Tasks.Task TestClientModelAsync (ModelClient body) + public async System.Threading.Tasks.Task TestClientModelAsync (ModelClient modelClient) { - ApiResponse localVarResponse = await TestClientModelAsyncWithHttpInfo(body); + ApiResponse localVarResponse = await TestClientModelAsyncWithHttpInfo(modelClient); return localVarResponse.Data; } @@ -1961,13 +2142,13 @@ public async System.Threading.Tasks.Task TestClientModelAsync (Mode /// To test \"client\" model To test \"client\" model /// /// Thrown when fails to make API call - /// client model + /// client model /// Task of ApiResponse (ModelClient) - public async System.Threading.Tasks.Task> TestClientModelAsyncWithHttpInfo (ModelClient body) + public async System.Threading.Tasks.Task> TestClientModelAsyncWithHttpInfo (ModelClient modelClient) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling FakeApi->TestClientModel"); + // verify the required parameter 'modelClient' is set + if (modelClient == null) + throw new ApiException(400, "Missing required parameter 'modelClient' when calling FakeApi->TestClientModel"); var localVarPath = "./fake"; var localVarPathParams = new Dictionary(); @@ -1991,13 +2172,13 @@ public async System.Threading.Tasks.Task> TestClientMod if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (modelClient != null && modelClient.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(modelClient); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = modelClient; // byte array } @@ -2020,7 +2201,7 @@ public async System.Threading.Tasks.Task> TestClientMod } /// - /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 /// /// Thrown when fails to make API call /// None @@ -2044,7 +2225,7 @@ public async System.Threading.Tasks.Task> TestClientMod } /// - /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 /// /// Thrown when fails to make API call /// None @@ -2139,7 +2320,7 @@ public async System.Threading.Tasks.Task> TestClientMod } /// - /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 /// /// Thrown when fails to make API call /// None @@ -2164,7 +2345,7 @@ public async System.Threading.Tasks.Task> TestClientMod } /// - /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 /// /// Thrown when fails to make API call /// None @@ -2313,7 +2494,7 @@ public async System.Threading.Tasks.Task> TestClientMod if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (enumQueryStringArray != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "enum_query_string_array", enumQueryStringArray)); // query parameter + if (enumQueryStringArray != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("multi", "enum_query_string_array", enumQueryStringArray)); // query parameter if (enumQueryString != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "enum_query_string", enumQueryString)); // query parameter if (enumQueryInteger != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "enum_query_integer", enumQueryInteger)); // query parameter if (enumQueryDouble != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "enum_query_double", enumQueryDouble)); // query parameter @@ -2397,7 +2578,7 @@ public async System.Threading.Tasks.Task> TestClientMod if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (enumQueryStringArray != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "enum_query_string_array", enumQueryStringArray)); // query parameter + if (enumQueryStringArray != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("multi", "enum_query_string_array", enumQueryStringArray)); // query parameter if (enumQueryString != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "enum_query_string", enumQueryString)); // query parameter if (enumQueryInteger != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "enum_query_integer", enumQueryInteger)); // query parameter if (enumQueryDouble != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "enum_query_double", enumQueryDouble)); // query parameter @@ -2491,6 +2672,12 @@ public async System.Threading.Tasks.Task> TestClientMod if (requiredBooleanGroup != null) localVarHeaderParams.Add("required_boolean_group", this.Configuration.ApiClient.ParameterToString(requiredBooleanGroup)); // header parameter if (booleanGroup != null) localVarHeaderParams.Add("boolean_group", this.Configuration.ApiClient.ParameterToString(booleanGroup)); // header parameter + // authentication (bearer_test) required + // http beerer authentication required + if (!String.IsNullOrEmpty(this.Configuration.AccessToken)) + { + localVarHeaderParams["Authorization"] = "Bearer " + this.Configuration.AccessToken; + } // make the HTTP request IRestResponse localVarResponse = (IRestResponse) this.Configuration.ApiClient.CallApi(localVarPath, @@ -2577,6 +2764,12 @@ public async System.Threading.Tasks.Task> TestClientMod if (requiredBooleanGroup != null) localVarHeaderParams.Add("required_boolean_group", this.Configuration.ApiClient.ParameterToString(requiredBooleanGroup)); // header parameter if (booleanGroup != null) localVarHeaderParams.Add("boolean_group", this.Configuration.ApiClient.ParameterToString(booleanGroup)); // header parameter + // authentication (bearer_test) required + // http bearer authentication required + if (!String.IsNullOrEmpty(this.Configuration.AccessToken)) + { + localVarHeaderParams["Authorization"] = "Bearer " + this.Configuration.AccessToken; + } // make the HTTP request IRestResponse localVarResponse = (IRestResponse) await this.Configuration.ApiClient.CallApiAsync(localVarPath, @@ -2600,24 +2793,24 @@ public async System.Threading.Tasks.Task> TestClientMod /// test inline additionalProperties /// /// Thrown when fails to make API call - /// request body + /// request body /// - public void TestInlineAdditionalProperties (Dictionary param) + public void TestInlineAdditionalProperties (Dictionary requestBody) { - TestInlineAdditionalPropertiesWithHttpInfo(param); + TestInlineAdditionalPropertiesWithHttpInfo(requestBody); } /// /// test inline additionalProperties /// /// Thrown when fails to make API call - /// request body + /// request body /// ApiResponse of Object(void) - public ApiResponse TestInlineAdditionalPropertiesWithHttpInfo (Dictionary param) + public ApiResponse TestInlineAdditionalPropertiesWithHttpInfo (Dictionary requestBody) { - // verify the required parameter 'param' is set - if (param == null) - throw new ApiException(400, "Missing required parameter 'param' when calling FakeApi->TestInlineAdditionalProperties"); + // verify the required parameter 'requestBody' is set + if (requestBody == null) + throw new ApiException(400, "Missing required parameter 'requestBody' when calling FakeApi->TestInlineAdditionalProperties"); var localVarPath = "./fake/inline-additionalProperties"; var localVarPathParams = new Dictionary(); @@ -2640,13 +2833,13 @@ public ApiResponse TestInlineAdditionalPropertiesWithHttpInfo (Dictionar if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (param != null && param.GetType() != typeof(byte[])) + if (requestBody != null && requestBody.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(param); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(requestBody); // http body (model) parameter } else { - localVarPostBody = param; // byte array + localVarPostBody = requestBody; // byte array } @@ -2672,11 +2865,11 @@ public ApiResponse TestInlineAdditionalPropertiesWithHttpInfo (Dictionar /// test inline additionalProperties /// /// Thrown when fails to make API call - /// request body + /// request body /// Task of void - public async System.Threading.Tasks.Task TestInlineAdditionalPropertiesAsync (Dictionary param) + public async System.Threading.Tasks.Task TestInlineAdditionalPropertiesAsync (Dictionary requestBody) { - await TestInlineAdditionalPropertiesAsyncWithHttpInfo(param); + await TestInlineAdditionalPropertiesAsyncWithHttpInfo(requestBody); } @@ -2684,13 +2877,13 @@ public async System.Threading.Tasks.Task TestInlineAdditionalPropertiesAsync (Di /// test inline additionalProperties /// /// Thrown when fails to make API call - /// request body + /// request body /// Task of ApiResponse - public async System.Threading.Tasks.Task> TestInlineAdditionalPropertiesAsyncWithHttpInfo (Dictionary param) + public async System.Threading.Tasks.Task> TestInlineAdditionalPropertiesAsyncWithHttpInfo (Dictionary requestBody) { - // verify the required parameter 'param' is set - if (param == null) - throw new ApiException(400, "Missing required parameter 'param' when calling FakeApi->TestInlineAdditionalProperties"); + // verify the required parameter 'requestBody' is set + if (requestBody == null) + throw new ApiException(400, "Missing required parameter 'requestBody' when calling FakeApi->TestInlineAdditionalProperties"); var localVarPath = "./fake/inline-additionalProperties"; var localVarPathParams = new Dictionary(); @@ -2713,13 +2906,13 @@ public async System.Threading.Tasks.Task> TestInlineAddition if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (param != null && param.GetType() != typeof(byte[])) + if (requestBody != null && requestBody.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(param); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(requestBody); // http body (model) parameter } else { - localVarPostBody = param; // byte array + localVarPostBody = requestBody; // byte array } @@ -2947,7 +3140,7 @@ public ApiResponse TestQueryParameterCollectionFormatWithHttpInfo (List< if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (pipe != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "pipe", pipe)); // query parameter + if (pipe != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("multi", "pipe", pipe)); // query parameter if (ioutil != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "ioutil", ioutil)); // query parameter if (http != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("space", "http", http)); // query parameter if (url != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "url", url)); // query parameter @@ -3036,7 +3229,7 @@ public async System.Threading.Tasks.Task> TestQueryParameter if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (pipe != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "pipe", pipe)); // query parameter + if (pipe != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("multi", "pipe", pipe)); // query parameter if (ioutil != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "ioutil", ioutil)); // query parameter if (http != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("space", "http", http)); // query parameter if (url != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "url", url)); // query parameter diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs index 4e181eeb4f73..eb9bc7ec3803 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs @@ -31,9 +31,9 @@ public interface IFakeClassnameTags123Api : IApiAccessor /// To test class name in snake case /// /// Thrown when fails to make API call - /// client model + /// client model /// ModelClient - ModelClient TestClassname (ModelClient body); + ModelClient TestClassname (ModelClient modelClient); /// /// To test class name in snake case @@ -42,9 +42,9 @@ public interface IFakeClassnameTags123Api : IApiAccessor /// To test class name in snake case /// /// Thrown when fails to make API call - /// client model + /// client model /// ApiResponse of ModelClient - ApiResponse TestClassnameWithHttpInfo (ModelClient body); + ApiResponse TestClassnameWithHttpInfo (ModelClient modelClient); #endregion Synchronous Operations #region Asynchronous Operations /// @@ -54,9 +54,9 @@ public interface IFakeClassnameTags123Api : IApiAccessor /// To test class name in snake case /// /// Thrown when fails to make API call - /// client model + /// client model /// Task of ModelClient - System.Threading.Tasks.Task TestClassnameAsync (ModelClient body); + System.Threading.Tasks.Task TestClassnameAsync (ModelClient modelClient); /// /// To test class name in snake case @@ -65,9 +65,9 @@ public interface IFakeClassnameTags123Api : IApiAccessor /// To test class name in snake case /// /// Thrown when fails to make API call - /// client model + /// client model /// Task of ApiResponse (ModelClient) - System.Threading.Tasks.Task> TestClassnameAsyncWithHttpInfo (ModelClient body); + System.Threading.Tasks.Task> TestClassnameAsyncWithHttpInfo (ModelClient modelClient); #endregion Asynchronous Operations } @@ -183,11 +183,11 @@ public void AddDefaultHeader(string key, string value) /// To test class name in snake case To test class name in snake case /// /// Thrown when fails to make API call - /// client model + /// client model /// ModelClient - public ModelClient TestClassname (ModelClient body) + public ModelClient TestClassname (ModelClient modelClient) { - ApiResponse localVarResponse = TestClassnameWithHttpInfo(body); + ApiResponse localVarResponse = TestClassnameWithHttpInfo(modelClient); return localVarResponse.Data; } @@ -195,13 +195,13 @@ public ModelClient TestClassname (ModelClient body) /// To test class name in snake case To test class name in snake case /// /// Thrown when fails to make API call - /// client model + /// client model /// ApiResponse of ModelClient - public ApiResponse TestClassnameWithHttpInfo (ModelClient body) + public ApiResponse TestClassnameWithHttpInfo (ModelClient modelClient) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling FakeClassnameTags123Api->TestClassname"); + // verify the required parameter 'modelClient' is set + if (modelClient == null) + throw new ApiException(400, "Missing required parameter 'modelClient' when calling FakeClassnameTags123Api->TestClassname"); var localVarPath = "./fake_classname_test"; var localVarPathParams = new Dictionary(); @@ -225,13 +225,13 @@ public ApiResponse TestClassnameWithHttpInfo (ModelClient body) if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (modelClient != null && modelClient.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(modelClient); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = modelClient; // byte array } // authentication (api_key_query) required @@ -262,11 +262,11 @@ public ApiResponse TestClassnameWithHttpInfo (ModelClient body) /// To test class name in snake case To test class name in snake case /// /// Thrown when fails to make API call - /// client model + /// client model /// Task of ModelClient - public async System.Threading.Tasks.Task TestClassnameAsync (ModelClient body) + public async System.Threading.Tasks.Task TestClassnameAsync (ModelClient modelClient) { - ApiResponse localVarResponse = await TestClassnameAsyncWithHttpInfo(body); + ApiResponse localVarResponse = await TestClassnameAsyncWithHttpInfo(modelClient); return localVarResponse.Data; } @@ -275,13 +275,13 @@ public async System.Threading.Tasks.Task TestClassnameAsync (ModelC /// To test class name in snake case To test class name in snake case /// /// Thrown when fails to make API call - /// client model + /// client model /// Task of ApiResponse (ModelClient) - public async System.Threading.Tasks.Task> TestClassnameAsyncWithHttpInfo (ModelClient body) + public async System.Threading.Tasks.Task> TestClassnameAsyncWithHttpInfo (ModelClient modelClient) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling FakeClassnameTags123Api->TestClassname"); + // verify the required parameter 'modelClient' is set + if (modelClient == null) + throw new ApiException(400, "Missing required parameter 'modelClient' when calling FakeClassnameTags123Api->TestClassname"); var localVarPath = "./fake_classname_test"; var localVarPathParams = new Dictionary(); @@ -305,13 +305,13 @@ public async System.Threading.Tasks.Task> TestClassname if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (modelClient != null && modelClient.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(modelClient); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = modelClient; // byte array } // authentication (api_key_query) required diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Api/PetApi.cs b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Api/PetApi.cs index 835858d4b10f..e7905ad01400 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Api/PetApi.cs +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Api/PetApi.cs @@ -31,9 +31,9 @@ public interface IPetApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// - void AddPet (Pet body); + void AddPet (Pet pet); /// /// Add a new pet to the store @@ -42,9 +42,9 @@ public interface IPetApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// ApiResponse of Object(void) - ApiResponse AddPetWithHttpInfo (Pet body); + ApiResponse AddPetWithHttpInfo (Pet pet); /// /// Deletes a pet /// @@ -138,9 +138,9 @@ public interface IPetApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// - void UpdatePet (Pet body); + void UpdatePet (Pet pet); /// /// Update an existing pet @@ -149,9 +149,9 @@ public interface IPetApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// ApiResponse of Object(void) - ApiResponse UpdatePetWithHttpInfo (Pet body); + ApiResponse UpdatePetWithHttpInfo (Pet pet); /// /// Updates a pet in the store with form data /// @@ -236,9 +236,9 @@ public interface IPetApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// Task of void - System.Threading.Tasks.Task AddPetAsync (Pet body); + System.Threading.Tasks.Task AddPetAsync (Pet pet); /// /// Add a new pet to the store @@ -247,9 +247,9 @@ public interface IPetApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// Task of ApiResponse - System.Threading.Tasks.Task> AddPetAsyncWithHttpInfo (Pet body); + System.Threading.Tasks.Task> AddPetAsyncWithHttpInfo (Pet pet); /// /// Deletes a pet /// @@ -343,9 +343,9 @@ public interface IPetApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// Task of void - System.Threading.Tasks.Task UpdatePetAsync (Pet body); + System.Threading.Tasks.Task UpdatePetAsync (Pet pet); /// /// Update an existing pet @@ -354,9 +354,9 @@ public interface IPetApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// Task of ApiResponse - System.Threading.Tasks.Task> UpdatePetAsyncWithHttpInfo (Pet body); + System.Threading.Tasks.Task> UpdatePetAsyncWithHttpInfo (Pet pet); /// /// Updates a pet in the store with form data /// @@ -547,24 +547,24 @@ public void AddDefaultHeader(string key, string value) /// Add a new pet to the store /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// - public void AddPet (Pet body) + public void AddPet (Pet pet) { - AddPetWithHttpInfo(body); + AddPetWithHttpInfo(pet); } /// /// Add a new pet to the store /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// ApiResponse of Object(void) - public ApiResponse AddPetWithHttpInfo (Pet body) + public ApiResponse AddPetWithHttpInfo (Pet pet) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling PetApi->AddPet"); + // verify the required parameter 'pet' is set + if (pet == null) + throw new ApiException(400, "Missing required parameter 'pet' when calling PetApi->AddPet"); var localVarPath = "./pet"; var localVarPathParams = new Dictionary(); @@ -588,13 +588,13 @@ public ApiResponse AddPetWithHttpInfo (Pet body) if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (pet != null && pet.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(pet); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = pet; // byte array } // authentication (petstore_auth) required @@ -626,11 +626,11 @@ public ApiResponse AddPetWithHttpInfo (Pet body) /// Add a new pet to the store /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// Task of void - public async System.Threading.Tasks.Task AddPetAsync (Pet body) + public async System.Threading.Tasks.Task AddPetAsync (Pet pet) { - await AddPetAsyncWithHttpInfo(body); + await AddPetAsyncWithHttpInfo(pet); } @@ -638,13 +638,13 @@ public async System.Threading.Tasks.Task AddPetAsync (Pet body) /// Add a new pet to the store /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// Task of ApiResponse - public async System.Threading.Tasks.Task> AddPetAsyncWithHttpInfo (Pet body) + public async System.Threading.Tasks.Task> AddPetAsyncWithHttpInfo (Pet pet) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling PetApi->AddPet"); + // verify the required parameter 'pet' is set + if (pet == null) + throw new ApiException(400, "Missing required parameter 'pet' when calling PetApi->AddPet"); var localVarPath = "./pet"; var localVarPathParams = new Dictionary(); @@ -668,13 +668,13 @@ public async System.Threading.Tasks.Task> AddPetAsyncWithHtt if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (pet != null && pet.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(pet); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = pet; // byte array } // authentication (petstore_auth) required @@ -1292,24 +1292,24 @@ public async System.Threading.Tasks.Task> GetPetByIdAsyncWithHt /// Update an existing pet /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// - public void UpdatePet (Pet body) + public void UpdatePet (Pet pet) { - UpdatePetWithHttpInfo(body); + UpdatePetWithHttpInfo(pet); } /// /// Update an existing pet /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// ApiResponse of Object(void) - public ApiResponse UpdatePetWithHttpInfo (Pet body) + public ApiResponse UpdatePetWithHttpInfo (Pet pet) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling PetApi->UpdatePet"); + // verify the required parameter 'pet' is set + if (pet == null) + throw new ApiException(400, "Missing required parameter 'pet' when calling PetApi->UpdatePet"); var localVarPath = "./pet"; var localVarPathParams = new Dictionary(); @@ -1333,13 +1333,13 @@ public ApiResponse UpdatePetWithHttpInfo (Pet body) if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (pet != null && pet.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(pet); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = pet; // byte array } // authentication (petstore_auth) required @@ -1371,11 +1371,11 @@ public ApiResponse UpdatePetWithHttpInfo (Pet body) /// Update an existing pet /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// Task of void - public async System.Threading.Tasks.Task UpdatePetAsync (Pet body) + public async System.Threading.Tasks.Task UpdatePetAsync (Pet pet) { - await UpdatePetAsyncWithHttpInfo(body); + await UpdatePetAsyncWithHttpInfo(pet); } @@ -1383,13 +1383,13 @@ public async System.Threading.Tasks.Task UpdatePetAsync (Pet body) /// Update an existing pet /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// Task of ApiResponse - public async System.Threading.Tasks.Task> UpdatePetAsyncWithHttpInfo (Pet body) + public async System.Threading.Tasks.Task> UpdatePetAsyncWithHttpInfo (Pet pet) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling PetApi->UpdatePet"); + // verify the required parameter 'pet' is set + if (pet == null) + throw new ApiException(400, "Missing required parameter 'pet' when calling PetApi->UpdatePet"); var localVarPath = "./pet"; var localVarPathParams = new Dictionary(); @@ -1413,13 +1413,13 @@ public async System.Threading.Tasks.Task> UpdatePetAsyncWith if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (pet != null && pet.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(pet); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = pet; // byte array } // authentication (petstore_auth) required diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Api/StoreApi.cs b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Api/StoreApi.cs index c7e01ce602b0..32c685ab23de 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Api/StoreApi.cs +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Api/StoreApi.cs @@ -92,9 +92,9 @@ public interface IStoreApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// order placed for purchasing the pet + /// order placed for purchasing the pet /// Order - Order PlaceOrder (Order body); + Order PlaceOrder (Order order); /// /// Place an order for a pet @@ -103,9 +103,9 @@ public interface IStoreApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// order placed for purchasing the pet + /// order placed for purchasing the pet /// ApiResponse of Order - ApiResponse PlaceOrderWithHttpInfo (Order body); + ApiResponse PlaceOrderWithHttpInfo (Order order); #endregion Synchronous Operations #region Asynchronous Operations /// @@ -176,9 +176,9 @@ public interface IStoreApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// order placed for purchasing the pet + /// order placed for purchasing the pet /// Task of Order - System.Threading.Tasks.Task PlaceOrderAsync (Order body); + System.Threading.Tasks.Task PlaceOrderAsync (Order order); /// /// Place an order for a pet @@ -187,9 +187,9 @@ public interface IStoreApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// order placed for purchasing the pet + /// order placed for purchasing the pet /// Task of ApiResponse (Order) - System.Threading.Tasks.Task> PlaceOrderAsyncWithHttpInfo (Order body); + System.Threading.Tasks.Task> PlaceOrderAsyncWithHttpInfo (Order order); #endregion Asynchronous Operations } @@ -700,11 +700,11 @@ public async System.Threading.Tasks.Task> GetOrderByIdAsyncWi /// Place an order for a pet /// /// Thrown when fails to make API call - /// order placed for purchasing the pet + /// order placed for purchasing the pet /// Order - public Order PlaceOrder (Order body) + public Order PlaceOrder (Order order) { - ApiResponse localVarResponse = PlaceOrderWithHttpInfo(body); + ApiResponse localVarResponse = PlaceOrderWithHttpInfo(order); return localVarResponse.Data; } @@ -712,13 +712,13 @@ public Order PlaceOrder (Order body) /// Place an order for a pet /// /// Thrown when fails to make API call - /// order placed for purchasing the pet + /// order placed for purchasing the pet /// ApiResponse of Order - public ApiResponse PlaceOrderWithHttpInfo (Order body) + public ApiResponse PlaceOrderWithHttpInfo (Order order) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling StoreApi->PlaceOrder"); + // verify the required parameter 'order' is set + if (order == null) + throw new ApiException(400, "Missing required parameter 'order' when calling StoreApi->PlaceOrder"); var localVarPath = "./store/order"; var localVarPathParams = new Dictionary(); @@ -730,6 +730,7 @@ public ApiResponse PlaceOrderWithHttpInfo (Order body) // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -742,13 +743,13 @@ public ApiResponse PlaceOrderWithHttpInfo (Order body) if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (order != null && order.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(order); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = order; // byte array } @@ -774,11 +775,11 @@ public ApiResponse PlaceOrderWithHttpInfo (Order body) /// Place an order for a pet /// /// Thrown when fails to make API call - /// order placed for purchasing the pet + /// order placed for purchasing the pet /// Task of Order - public async System.Threading.Tasks.Task PlaceOrderAsync (Order body) + public async System.Threading.Tasks.Task PlaceOrderAsync (Order order) { - ApiResponse localVarResponse = await PlaceOrderAsyncWithHttpInfo(body); + ApiResponse localVarResponse = await PlaceOrderAsyncWithHttpInfo(order); return localVarResponse.Data; } @@ -787,13 +788,13 @@ public async System.Threading.Tasks.Task PlaceOrderAsync (Order body) /// Place an order for a pet /// /// Thrown when fails to make API call - /// order placed for purchasing the pet + /// order placed for purchasing the pet /// Task of ApiResponse (Order) - public async System.Threading.Tasks.Task> PlaceOrderAsyncWithHttpInfo (Order body) + public async System.Threading.Tasks.Task> PlaceOrderAsyncWithHttpInfo (Order order) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling StoreApi->PlaceOrder"); + // verify the required parameter 'order' is set + if (order == null) + throw new ApiException(400, "Missing required parameter 'order' when calling StoreApi->PlaceOrder"); var localVarPath = "./store/order"; var localVarPathParams = new Dictionary(); @@ -805,6 +806,7 @@ public async System.Threading.Tasks.Task> PlaceOrderAsyncWith // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -817,13 +819,13 @@ public async System.Threading.Tasks.Task> PlaceOrderAsyncWith if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (order != null && order.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(order); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = order; // byte array } diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Api/UserApi.cs b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Api/UserApi.cs index 0273aa89c371..3ba4cc796f19 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Api/UserApi.cs +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Api/UserApi.cs @@ -31,9 +31,9 @@ public interface IUserApi : IApiAccessor /// This can only be done by the logged in user. /// /// Thrown when fails to make API call - /// Created user object + /// Created user object /// - void CreateUser (User body); + void CreateUser (User user); /// /// Create user @@ -42,9 +42,9 @@ public interface IUserApi : IApiAccessor /// This can only be done by the logged in user. /// /// Thrown when fails to make API call - /// Created user object + /// Created user object /// ApiResponse of Object(void) - ApiResponse CreateUserWithHttpInfo (User body); + ApiResponse CreateUserWithHttpInfo (User user); /// /// Creates list of users with given input array /// @@ -52,9 +52,9 @@ public interface IUserApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// List of user object + /// List of user object /// - void CreateUsersWithArrayInput (List body); + void CreateUsersWithArrayInput (List user); /// /// Creates list of users with given input array @@ -63,9 +63,9 @@ public interface IUserApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// List of user object + /// List of user object /// ApiResponse of Object(void) - ApiResponse CreateUsersWithArrayInputWithHttpInfo (List body); + ApiResponse CreateUsersWithArrayInputWithHttpInfo (List user); /// /// Creates list of users with given input array /// @@ -73,9 +73,9 @@ public interface IUserApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// List of user object + /// List of user object /// - void CreateUsersWithListInput (List body); + void CreateUsersWithListInput (List user); /// /// Creates list of users with given input array @@ -84,9 +84,9 @@ public interface IUserApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// List of user object + /// List of user object /// ApiResponse of Object(void) - ApiResponse CreateUsersWithListInputWithHttpInfo (List body); + ApiResponse CreateUsersWithListInputWithHttpInfo (List user); /// /// Delete user /// @@ -179,9 +179,9 @@ public interface IUserApi : IApiAccessor /// /// Thrown when fails to make API call /// name that need to be deleted - /// Updated user object + /// Updated user object /// - void UpdateUser (string username, User body); + void UpdateUser (string username, User user); /// /// Updated user @@ -191,9 +191,9 @@ public interface IUserApi : IApiAccessor /// /// Thrown when fails to make API call /// name that need to be deleted - /// Updated user object + /// Updated user object /// ApiResponse of Object(void) - ApiResponse UpdateUserWithHttpInfo (string username, User body); + ApiResponse UpdateUserWithHttpInfo (string username, User user); #endregion Synchronous Operations #region Asynchronous Operations /// @@ -203,9 +203,9 @@ public interface IUserApi : IApiAccessor /// This can only be done by the logged in user. /// /// Thrown when fails to make API call - /// Created user object + /// Created user object /// Task of void - System.Threading.Tasks.Task CreateUserAsync (User body); + System.Threading.Tasks.Task CreateUserAsync (User user); /// /// Create user @@ -214,9 +214,9 @@ public interface IUserApi : IApiAccessor /// This can only be done by the logged in user. /// /// Thrown when fails to make API call - /// Created user object + /// Created user object /// Task of ApiResponse - System.Threading.Tasks.Task> CreateUserAsyncWithHttpInfo (User body); + System.Threading.Tasks.Task> CreateUserAsyncWithHttpInfo (User user); /// /// Creates list of users with given input array /// @@ -224,9 +224,9 @@ public interface IUserApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// List of user object + /// List of user object /// Task of void - System.Threading.Tasks.Task CreateUsersWithArrayInputAsync (List body); + System.Threading.Tasks.Task CreateUsersWithArrayInputAsync (List user); /// /// Creates list of users with given input array @@ -235,9 +235,9 @@ public interface IUserApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// List of user object + /// List of user object /// Task of ApiResponse - System.Threading.Tasks.Task> CreateUsersWithArrayInputAsyncWithHttpInfo (List body); + System.Threading.Tasks.Task> CreateUsersWithArrayInputAsyncWithHttpInfo (List user); /// /// Creates list of users with given input array /// @@ -245,9 +245,9 @@ public interface IUserApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// List of user object + /// List of user object /// Task of void - System.Threading.Tasks.Task CreateUsersWithListInputAsync (List body); + System.Threading.Tasks.Task CreateUsersWithListInputAsync (List user); /// /// Creates list of users with given input array @@ -256,9 +256,9 @@ public interface IUserApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// List of user object + /// List of user object /// Task of ApiResponse - System.Threading.Tasks.Task> CreateUsersWithListInputAsyncWithHttpInfo (List body); + System.Threading.Tasks.Task> CreateUsersWithListInputAsyncWithHttpInfo (List user); /// /// Delete user /// @@ -351,9 +351,9 @@ public interface IUserApi : IApiAccessor /// /// Thrown when fails to make API call /// name that need to be deleted - /// Updated user object + /// Updated user object /// Task of void - System.Threading.Tasks.Task UpdateUserAsync (string username, User body); + System.Threading.Tasks.Task UpdateUserAsync (string username, User user); /// /// Updated user @@ -363,9 +363,9 @@ public interface IUserApi : IApiAccessor /// /// Thrown when fails to make API call /// name that need to be deleted - /// Updated user object + /// Updated user object /// Task of ApiResponse - System.Threading.Tasks.Task> UpdateUserAsyncWithHttpInfo (string username, User body); + System.Threading.Tasks.Task> UpdateUserAsyncWithHttpInfo (string username, User user); #endregion Asynchronous Operations } @@ -481,24 +481,24 @@ public void AddDefaultHeader(string key, string value) /// Create user This can only be done by the logged in user. /// /// Thrown when fails to make API call - /// Created user object + /// Created user object /// - public void CreateUser (User body) + public void CreateUser (User user) { - CreateUserWithHttpInfo(body); + CreateUserWithHttpInfo(user); } /// /// Create user This can only be done by the logged in user. /// /// Thrown when fails to make API call - /// Created user object + /// Created user object /// ApiResponse of Object(void) - public ApiResponse CreateUserWithHttpInfo (User body) + public ApiResponse CreateUserWithHttpInfo (User user) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling UserApi->CreateUser"); + // verify the required parameter 'user' is set + if (user == null) + throw new ApiException(400, "Missing required parameter 'user' when calling UserApi->CreateUser"); var localVarPath = "./user"; var localVarPathParams = new Dictionary(); @@ -510,6 +510,7 @@ public ApiResponse CreateUserWithHttpInfo (User body) // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -520,13 +521,13 @@ public ApiResponse CreateUserWithHttpInfo (User body) if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (user != null && user.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(user); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = user; // byte array } @@ -552,11 +553,11 @@ public ApiResponse CreateUserWithHttpInfo (User body) /// Create user This can only be done by the logged in user. /// /// Thrown when fails to make API call - /// Created user object + /// Created user object /// Task of void - public async System.Threading.Tasks.Task CreateUserAsync (User body) + public async System.Threading.Tasks.Task CreateUserAsync (User user) { - await CreateUserAsyncWithHttpInfo(body); + await CreateUserAsyncWithHttpInfo(user); } @@ -564,13 +565,13 @@ public async System.Threading.Tasks.Task CreateUserAsync (User body) /// Create user This can only be done by the logged in user. /// /// Thrown when fails to make API call - /// Created user object + /// Created user object /// Task of ApiResponse - public async System.Threading.Tasks.Task> CreateUserAsyncWithHttpInfo (User body) + public async System.Threading.Tasks.Task> CreateUserAsyncWithHttpInfo (User user) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling UserApi->CreateUser"); + // verify the required parameter 'user' is set + if (user == null) + throw new ApiException(400, "Missing required parameter 'user' when calling UserApi->CreateUser"); var localVarPath = "./user"; var localVarPathParams = new Dictionary(); @@ -582,6 +583,7 @@ public async System.Threading.Tasks.Task> CreateUserAsyncWit // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -592,13 +594,13 @@ public async System.Threading.Tasks.Task> CreateUserAsyncWit if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (user != null && user.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(user); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = user; // byte array } @@ -624,24 +626,24 @@ public async System.Threading.Tasks.Task> CreateUserAsyncWit /// Creates list of users with given input array /// /// Thrown when fails to make API call - /// List of user object + /// List of user object /// - public void CreateUsersWithArrayInput (List body) + public void CreateUsersWithArrayInput (List user) { - CreateUsersWithArrayInputWithHttpInfo(body); + CreateUsersWithArrayInputWithHttpInfo(user); } /// /// Creates list of users with given input array /// /// Thrown when fails to make API call - /// List of user object + /// List of user object /// ApiResponse of Object(void) - public ApiResponse CreateUsersWithArrayInputWithHttpInfo (List body) + public ApiResponse CreateUsersWithArrayInputWithHttpInfo (List user) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling UserApi->CreateUsersWithArrayInput"); + // verify the required parameter 'user' is set + if (user == null) + throw new ApiException(400, "Missing required parameter 'user' when calling UserApi->CreateUsersWithArrayInput"); var localVarPath = "./user/createWithArray"; var localVarPathParams = new Dictionary(); @@ -653,6 +655,7 @@ public ApiResponse CreateUsersWithArrayInputWithHttpInfo (List bod // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -663,13 +666,13 @@ public ApiResponse CreateUsersWithArrayInputWithHttpInfo (List bod if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (user != null && user.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(user); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = user; // byte array } @@ -695,11 +698,11 @@ public ApiResponse CreateUsersWithArrayInputWithHttpInfo (List bod /// Creates list of users with given input array /// /// Thrown when fails to make API call - /// List of user object + /// List of user object /// Task of void - public async System.Threading.Tasks.Task CreateUsersWithArrayInputAsync (List body) + public async System.Threading.Tasks.Task CreateUsersWithArrayInputAsync (List user) { - await CreateUsersWithArrayInputAsyncWithHttpInfo(body); + await CreateUsersWithArrayInputAsyncWithHttpInfo(user); } @@ -707,13 +710,13 @@ public async System.Threading.Tasks.Task CreateUsersWithArrayInputAsync (List /// Thrown when fails to make API call - /// List of user object + /// List of user object /// Task of ApiResponse - public async System.Threading.Tasks.Task> CreateUsersWithArrayInputAsyncWithHttpInfo (List body) + public async System.Threading.Tasks.Task> CreateUsersWithArrayInputAsyncWithHttpInfo (List user) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling UserApi->CreateUsersWithArrayInput"); + // verify the required parameter 'user' is set + if (user == null) + throw new ApiException(400, "Missing required parameter 'user' when calling UserApi->CreateUsersWithArrayInput"); var localVarPath = "./user/createWithArray"; var localVarPathParams = new Dictionary(); @@ -725,6 +728,7 @@ public async System.Threading.Tasks.Task> CreateUsersWithArr // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -735,13 +739,13 @@ public async System.Threading.Tasks.Task> CreateUsersWithArr if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (user != null && user.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(user); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = user; // byte array } @@ -767,24 +771,24 @@ public async System.Threading.Tasks.Task> CreateUsersWithArr /// Creates list of users with given input array /// /// Thrown when fails to make API call - /// List of user object + /// List of user object /// - public void CreateUsersWithListInput (List body) + public void CreateUsersWithListInput (List user) { - CreateUsersWithListInputWithHttpInfo(body); + CreateUsersWithListInputWithHttpInfo(user); } /// /// Creates list of users with given input array /// /// Thrown when fails to make API call - /// List of user object + /// List of user object /// ApiResponse of Object(void) - public ApiResponse CreateUsersWithListInputWithHttpInfo (List body) + public ApiResponse CreateUsersWithListInputWithHttpInfo (List user) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling UserApi->CreateUsersWithListInput"); + // verify the required parameter 'user' is set + if (user == null) + throw new ApiException(400, "Missing required parameter 'user' when calling UserApi->CreateUsersWithListInput"); var localVarPath = "./user/createWithList"; var localVarPathParams = new Dictionary(); @@ -796,6 +800,7 @@ public ApiResponse CreateUsersWithListInputWithHttpInfo (List body // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -806,13 +811,13 @@ public ApiResponse CreateUsersWithListInputWithHttpInfo (List body if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (user != null && user.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(user); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = user; // byte array } @@ -838,11 +843,11 @@ public ApiResponse CreateUsersWithListInputWithHttpInfo (List body /// Creates list of users with given input array /// /// Thrown when fails to make API call - /// List of user object + /// List of user object /// Task of void - public async System.Threading.Tasks.Task CreateUsersWithListInputAsync (List body) + public async System.Threading.Tasks.Task CreateUsersWithListInputAsync (List user) { - await CreateUsersWithListInputAsyncWithHttpInfo(body); + await CreateUsersWithListInputAsyncWithHttpInfo(user); } @@ -850,13 +855,13 @@ public async System.Threading.Tasks.Task CreateUsersWithListInputAsync (List /// Thrown when fails to make API call - /// List of user object + /// List of user object /// Task of ApiResponse - public async System.Threading.Tasks.Task> CreateUsersWithListInputAsyncWithHttpInfo (List body) + public async System.Threading.Tasks.Task> CreateUsersWithListInputAsyncWithHttpInfo (List user) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling UserApi->CreateUsersWithListInput"); + // verify the required parameter 'user' is set + if (user == null) + throw new ApiException(400, "Missing required parameter 'user' when calling UserApi->CreateUsersWithListInput"); var localVarPath = "./user/createWithList"; var localVarPathParams = new Dictionary(); @@ -868,6 +873,7 @@ public async System.Threading.Tasks.Task> CreateUsersWithLis // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -878,13 +884,13 @@ public async System.Threading.Tasks.Task> CreateUsersWithLis if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (user != null && user.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(user); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = user; // byte array } @@ -1439,11 +1445,11 @@ public async System.Threading.Tasks.Task> LogoutUserAsyncWit /// /// Thrown when fails to make API call /// name that need to be deleted - /// Updated user object + /// Updated user object /// - public void UpdateUser (string username, User body) + public void UpdateUser (string username, User user) { - UpdateUserWithHttpInfo(username, body); + UpdateUserWithHttpInfo(username, user); } /// @@ -1451,16 +1457,16 @@ public void UpdateUser (string username, User body) /// /// Thrown when fails to make API call /// name that need to be deleted - /// Updated user object + /// Updated user object /// ApiResponse of Object(void) - public ApiResponse UpdateUserWithHttpInfo (string username, User body) + public ApiResponse UpdateUserWithHttpInfo (string username, User user) { // verify the required parameter 'username' is set if (username == null) throw new ApiException(400, "Missing required parameter 'username' when calling UserApi->UpdateUser"); - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling UserApi->UpdateUser"); + // verify the required parameter 'user' is set + if (user == null) + throw new ApiException(400, "Missing required parameter 'user' when calling UserApi->UpdateUser"); var localVarPath = "./user/{username}"; var localVarPathParams = new Dictionary(); @@ -1472,6 +1478,7 @@ public ApiResponse UpdateUserWithHttpInfo (string username, User body) // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -1483,13 +1490,13 @@ public ApiResponse UpdateUserWithHttpInfo (string username, User body) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); if (username != null) localVarPathParams.Add("username", this.Configuration.ApiClient.ParameterToString(username)); // path parameter - if (body != null && body.GetType() != typeof(byte[])) + if (user != null && user.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(user); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = user; // byte array } @@ -1516,11 +1523,11 @@ public ApiResponse UpdateUserWithHttpInfo (string username, User body) /// /// Thrown when fails to make API call /// name that need to be deleted - /// Updated user object + /// Updated user object /// Task of void - public async System.Threading.Tasks.Task UpdateUserAsync (string username, User body) + public async System.Threading.Tasks.Task UpdateUserAsync (string username, User user) { - await UpdateUserAsyncWithHttpInfo(username, body); + await UpdateUserAsyncWithHttpInfo(username, user); } @@ -1529,16 +1536,16 @@ public async System.Threading.Tasks.Task UpdateUserAsync (string username, User /// /// Thrown when fails to make API call /// name that need to be deleted - /// Updated user object + /// Updated user object /// Task of ApiResponse - public async System.Threading.Tasks.Task> UpdateUserAsyncWithHttpInfo (string username, User body) + public async System.Threading.Tasks.Task> UpdateUserAsyncWithHttpInfo (string username, User user) { // verify the required parameter 'username' is set if (username == null) throw new ApiException(400, "Missing required parameter 'username' when calling UserApi->UpdateUser"); - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling UserApi->UpdateUser"); + // verify the required parameter 'user' is set + if (user == null) + throw new ApiException(400, "Missing required parameter 'user' when calling UserApi->UpdateUser"); var localVarPath = "./user/{username}"; var localVarPathParams = new Dictionary(); @@ -1550,6 +1557,7 @@ public async System.Threading.Tasks.Task> UpdateUserAsyncWit // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -1561,13 +1569,13 @@ public async System.Threading.Tasks.Task> UpdateUserAsyncWit localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); if (username != null) localVarPathParams.Add("username", this.Configuration.ApiClient.ParameterToString(username)); // path parameter - if (body != null && body.GetType() != typeof(byte[])) + if (user != null && user.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(user); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = user; // byte array } diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/AdditionalPropertiesClass.cs b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/AdditionalPropertiesClass.cs index f56db9cd1655..19d8c2206359 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/AdditionalPropertiesClass.cs +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/AdditionalPropertiesClass.cs @@ -31,97 +31,25 @@ public partial class AdditionalPropertiesClass : IEquatable /// Initializes a new instance of the class. /// - /// mapString. - /// mapNumber. - /// mapInteger. - /// mapBoolean. - /// mapArrayInteger. - /// mapArrayAnytype. - /// mapMapString. - /// mapMapAnytype. - /// anytype1. - /// anytype2. - /// anytype3. - public AdditionalPropertiesClass(Dictionary mapString = default(Dictionary), Dictionary mapNumber = default(Dictionary), Dictionary mapInteger = default(Dictionary), Dictionary mapBoolean = default(Dictionary), Dictionary> mapArrayInteger = default(Dictionary>), Dictionary> mapArrayAnytype = default(Dictionary>), Dictionary> mapMapString = default(Dictionary>), Dictionary> mapMapAnytype = default(Dictionary>), Object anytype1 = default(Object), Object anytype2 = default(Object), Object anytype3 = default(Object)) + /// mapProperty. + /// mapOfMapProperty. + public AdditionalPropertiesClass(Dictionary mapProperty = default(Dictionary), Dictionary> mapOfMapProperty = default(Dictionary>)) { - this.MapString = mapString; - this.MapNumber = mapNumber; - this.MapInteger = mapInteger; - this.MapBoolean = mapBoolean; - this.MapArrayInteger = mapArrayInteger; - this.MapArrayAnytype = mapArrayAnytype; - this.MapMapString = mapMapString; - this.MapMapAnytype = mapMapAnytype; - this.Anytype1 = anytype1; - this.Anytype2 = anytype2; - this.Anytype3 = anytype3; + this.MapProperty = mapProperty; + this.MapOfMapProperty = mapOfMapProperty; } /// - /// Gets or Sets MapString + /// Gets or Sets MapProperty /// - [DataMember(Name="map_string", EmitDefaultValue=false)] - public Dictionary MapString { get; set; } + [DataMember(Name="map_property", EmitDefaultValue=false)] + public Dictionary MapProperty { get; set; } /// - /// Gets or Sets MapNumber + /// Gets or Sets MapOfMapProperty /// - [DataMember(Name="map_number", EmitDefaultValue=false)] - public Dictionary MapNumber { get; set; } - - /// - /// Gets or Sets MapInteger - /// - [DataMember(Name="map_integer", EmitDefaultValue=false)] - public Dictionary MapInteger { get; set; } - - /// - /// Gets or Sets MapBoolean - /// - [DataMember(Name="map_boolean", EmitDefaultValue=false)] - public Dictionary MapBoolean { get; set; } - - /// - /// Gets or Sets MapArrayInteger - /// - [DataMember(Name="map_array_integer", EmitDefaultValue=false)] - public Dictionary> MapArrayInteger { get; set; } - - /// - /// Gets or Sets MapArrayAnytype - /// - [DataMember(Name="map_array_anytype", EmitDefaultValue=false)] - public Dictionary> MapArrayAnytype { get; set; } - - /// - /// Gets or Sets MapMapString - /// - [DataMember(Name="map_map_string", EmitDefaultValue=false)] - public Dictionary> MapMapString { get; set; } - - /// - /// Gets or Sets MapMapAnytype - /// - [DataMember(Name="map_map_anytype", EmitDefaultValue=false)] - public Dictionary> MapMapAnytype { get; set; } - - /// - /// Gets or Sets Anytype1 - /// - [DataMember(Name="anytype_1", EmitDefaultValue=false)] - public Object Anytype1 { get; set; } - - /// - /// Gets or Sets Anytype2 - /// - [DataMember(Name="anytype_2", EmitDefaultValue=false)] - public Object Anytype2 { get; set; } - - /// - /// Gets or Sets Anytype3 - /// - [DataMember(Name="anytype_3", EmitDefaultValue=false)] - public Object Anytype3 { get; set; } + [DataMember(Name="map_of_map_property", EmitDefaultValue=false)] + public Dictionary> MapOfMapProperty { get; set; } /// /// Returns the string presentation of the object @@ -131,17 +59,8 @@ public override string ToString() { var sb = new StringBuilder(); sb.Append("class AdditionalPropertiesClass {\n"); - sb.Append(" MapString: ").Append(MapString).Append("\n"); - sb.Append(" MapNumber: ").Append(MapNumber).Append("\n"); - sb.Append(" MapInteger: ").Append(MapInteger).Append("\n"); - sb.Append(" MapBoolean: ").Append(MapBoolean).Append("\n"); - sb.Append(" MapArrayInteger: ").Append(MapArrayInteger).Append("\n"); - sb.Append(" MapArrayAnytype: ").Append(MapArrayAnytype).Append("\n"); - sb.Append(" MapMapString: ").Append(MapMapString).Append("\n"); - sb.Append(" MapMapAnytype: ").Append(MapMapAnytype).Append("\n"); - sb.Append(" Anytype1: ").Append(Anytype1).Append("\n"); - sb.Append(" Anytype2: ").Append(Anytype2).Append("\n"); - sb.Append(" Anytype3: ").Append(Anytype3).Append("\n"); + sb.Append(" MapProperty: ").Append(MapProperty).Append("\n"); + sb.Append(" MapOfMapProperty: ").Append(MapOfMapProperty).Append("\n"); sb.Append("}\n"); return sb.ToString(); } @@ -177,67 +96,16 @@ public bool Equals(AdditionalPropertiesClass input) return ( - this.MapString == input.MapString || - this.MapString != null && - input.MapString != null && - this.MapString.SequenceEqual(input.MapString) - ) && - ( - this.MapNumber == input.MapNumber || - this.MapNumber != null && - input.MapNumber != null && - this.MapNumber.SequenceEqual(input.MapNumber) - ) && - ( - this.MapInteger == input.MapInteger || - this.MapInteger != null && - input.MapInteger != null && - this.MapInteger.SequenceEqual(input.MapInteger) - ) && - ( - this.MapBoolean == input.MapBoolean || - this.MapBoolean != null && - input.MapBoolean != null && - this.MapBoolean.SequenceEqual(input.MapBoolean) - ) && - ( - this.MapArrayInteger == input.MapArrayInteger || - this.MapArrayInteger != null && - input.MapArrayInteger != null && - this.MapArrayInteger.SequenceEqual(input.MapArrayInteger) - ) && - ( - this.MapArrayAnytype == input.MapArrayAnytype || - this.MapArrayAnytype != null && - input.MapArrayAnytype != null && - this.MapArrayAnytype.SequenceEqual(input.MapArrayAnytype) - ) && - ( - this.MapMapString == input.MapMapString || - this.MapMapString != null && - input.MapMapString != null && - this.MapMapString.SequenceEqual(input.MapMapString) - ) && - ( - this.MapMapAnytype == input.MapMapAnytype || - this.MapMapAnytype != null && - input.MapMapAnytype != null && - this.MapMapAnytype.SequenceEqual(input.MapMapAnytype) - ) && - ( - this.Anytype1 == input.Anytype1 || - (this.Anytype1 != null && - this.Anytype1.Equals(input.Anytype1)) - ) && - ( - this.Anytype2 == input.Anytype2 || - (this.Anytype2 != null && - this.Anytype2.Equals(input.Anytype2)) + this.MapProperty == input.MapProperty || + this.MapProperty != null && + input.MapProperty != null && + this.MapProperty.SequenceEqual(input.MapProperty) ) && ( - this.Anytype3 == input.Anytype3 || - (this.Anytype3 != null && - this.Anytype3.Equals(input.Anytype3)) + this.MapOfMapProperty == input.MapOfMapProperty || + this.MapOfMapProperty != null && + input.MapOfMapProperty != null && + this.MapOfMapProperty.SequenceEqual(input.MapOfMapProperty) ); } @@ -250,28 +118,10 @@ public override int GetHashCode() unchecked // Overflow is fine, just wrap { int hashCode = 41; - if (this.MapString != null) - hashCode = hashCode * 59 + this.MapString.GetHashCode(); - if (this.MapNumber != null) - hashCode = hashCode * 59 + this.MapNumber.GetHashCode(); - if (this.MapInteger != null) - hashCode = hashCode * 59 + this.MapInteger.GetHashCode(); - if (this.MapBoolean != null) - hashCode = hashCode * 59 + this.MapBoolean.GetHashCode(); - if (this.MapArrayInteger != null) - hashCode = hashCode * 59 + this.MapArrayInteger.GetHashCode(); - if (this.MapArrayAnytype != null) - hashCode = hashCode * 59 + this.MapArrayAnytype.GetHashCode(); - if (this.MapMapString != null) - hashCode = hashCode * 59 + this.MapMapString.GetHashCode(); - if (this.MapMapAnytype != null) - hashCode = hashCode * 59 + this.MapMapAnytype.GetHashCode(); - if (this.Anytype1 != null) - hashCode = hashCode * 59 + this.Anytype1.GetHashCode(); - if (this.Anytype2 != null) - hashCode = hashCode * 59 + this.Anytype2.GetHashCode(); - if (this.Anytype3 != null) - hashCode = hashCode * 59 + this.Anytype3.GetHashCode(); + if (this.MapProperty != null) + hashCode = hashCode * 59 + this.MapProperty.GetHashCode(); + if (this.MapOfMapProperty != null) + hashCode = hashCode * 59 + this.MapOfMapProperty.GetHashCode(); return hashCode; } } diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/Animal.cs b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/Animal.cs index 455c3a9bcef3..ac5ce7d22615 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/Animal.cs +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/Animal.cs @@ -30,7 +30,6 @@ namespace Org.OpenAPITools.Model [JsonConverter(typeof(JsonSubtypes), "className")] [JsonSubtypes.KnownSubType(typeof(Dog), "Dog")] [JsonSubtypes.KnownSubType(typeof(Cat), "Cat")] - [JsonSubtypes.KnownSubType(typeof(BigCat), "BigCat")] public partial class Animal : IEquatable { /// diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/Cat.cs b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/Cat.cs index 9659342cda9c..6f283567bf53 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/Cat.cs +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/Cat.cs @@ -37,7 +37,7 @@ protected Cat() { } /// Initializes a new instance of the class. /// /// declawed. - public Cat(bool declawed = default(bool), string className = default(string), string color = "red") : base(className, color) + public Cat(bool declawed = default(bool), string className = "Cat", string color = "red") : base(className, color) { this.Declawed = declawed; } diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/Dog.cs b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/Dog.cs index 503fe9a20ac2..75b181560184 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/Dog.cs +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/Dog.cs @@ -37,7 +37,7 @@ protected Dog() { } /// Initializes a new instance of the class. /// /// breed. - public Dog(string breed = default(string), string className = default(string), string color = "red") : base(className, color) + public Dog(string breed = default(string), string className = "Dog", string color = "red") : base(className, color) { this.Breed = breed; } diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/EnumTest.cs b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/EnumTest.cs index e234f80d68de..305c2f4803ad 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/EnumTest.cs +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/EnumTest.cs @@ -140,9 +140,24 @@ public enum EnumNumberEnum /// /// Gets or Sets OuterEnum /// - [DataMember(Name="outerEnum", EmitDefaultValue=false)] + [DataMember(Name="outerEnum", EmitDefaultValue=true)] public OuterEnum? OuterEnum { get; set; } /// + /// Gets or Sets OuterEnumInteger + /// + [DataMember(Name="outerEnumInteger", EmitDefaultValue=false)] + public OuterEnumInteger? OuterEnumInteger { get; set; } + /// + /// Gets or Sets OuterEnumDefaultValue + /// + [DataMember(Name="outerEnumDefaultValue", EmitDefaultValue=false)] + public OuterEnumDefaultValue? OuterEnumDefaultValue { get; set; } + /// + /// Gets or Sets OuterEnumIntegerDefaultValue + /// + [DataMember(Name="outerEnumIntegerDefaultValue", EmitDefaultValue=false)] + public OuterEnumIntegerDefaultValue? OuterEnumIntegerDefaultValue { get; set; } + /// /// Initializes a new instance of the class. /// [JsonConstructorAttribute] @@ -155,7 +170,10 @@ protected EnumTest() { } /// enumInteger. /// enumNumber. /// outerEnum. - public EnumTest(EnumStringEnum? enumString = default(EnumStringEnum?), EnumStringRequiredEnum enumStringRequired = default(EnumStringRequiredEnum), EnumIntegerEnum? enumInteger = default(EnumIntegerEnum?), EnumNumberEnum? enumNumber = default(EnumNumberEnum?), OuterEnum? outerEnum = default(OuterEnum?)) + /// outerEnumInteger. + /// outerEnumDefaultValue. + /// outerEnumIntegerDefaultValue. + public EnumTest(EnumStringEnum? enumString = default(EnumStringEnum?), EnumStringRequiredEnum enumStringRequired = default(EnumStringRequiredEnum), EnumIntegerEnum? enumInteger = default(EnumIntegerEnum?), EnumNumberEnum? enumNumber = default(EnumNumberEnum?), OuterEnum? outerEnum = default(OuterEnum?), OuterEnumInteger? outerEnumInteger = default(OuterEnumInteger?), OuterEnumDefaultValue? outerEnumDefaultValue = default(OuterEnumDefaultValue?), OuterEnumIntegerDefaultValue? outerEnumIntegerDefaultValue = default(OuterEnumIntegerDefaultValue?)) { // to ensure "enumStringRequired" is required (not null) if (enumStringRequired == null) @@ -167,10 +185,14 @@ protected EnumTest() { } this.EnumStringRequired = enumStringRequired; } + this.OuterEnum = outerEnum; this.EnumString = enumString; this.EnumInteger = enumInteger; this.EnumNumber = enumNumber; this.OuterEnum = outerEnum; + this.OuterEnumInteger = outerEnumInteger; + this.OuterEnumDefaultValue = outerEnumDefaultValue; + this.OuterEnumIntegerDefaultValue = outerEnumIntegerDefaultValue; } @@ -178,6 +200,9 @@ protected EnumTest() { } + + + /// /// Returns the string presentation of the object /// @@ -191,6 +216,9 @@ public override string ToString() sb.Append(" EnumInteger: ").Append(EnumInteger).Append("\n"); sb.Append(" EnumNumber: ").Append(EnumNumber).Append("\n"); sb.Append(" OuterEnum: ").Append(OuterEnum).Append("\n"); + sb.Append(" OuterEnumInteger: ").Append(OuterEnumInteger).Append("\n"); + sb.Append(" OuterEnumDefaultValue: ").Append(OuterEnumDefaultValue).Append("\n"); + sb.Append(" OuterEnumIntegerDefaultValue: ").Append(OuterEnumIntegerDefaultValue).Append("\n"); sb.Append("}\n"); return sb.ToString(); } @@ -249,6 +277,21 @@ public bool Equals(EnumTest input) this.OuterEnum == input.OuterEnum || (this.OuterEnum != null && this.OuterEnum.Equals(input.OuterEnum)) + ) && + ( + this.OuterEnumInteger == input.OuterEnumInteger || + (this.OuterEnumInteger != null && + this.OuterEnumInteger.Equals(input.OuterEnumInteger)) + ) && + ( + this.OuterEnumDefaultValue == input.OuterEnumDefaultValue || + (this.OuterEnumDefaultValue != null && + this.OuterEnumDefaultValue.Equals(input.OuterEnumDefaultValue)) + ) && + ( + this.OuterEnumIntegerDefaultValue == input.OuterEnumIntegerDefaultValue || + (this.OuterEnumIntegerDefaultValue != null && + this.OuterEnumIntegerDefaultValue.Equals(input.OuterEnumIntegerDefaultValue)) ); } @@ -271,6 +314,12 @@ public override int GetHashCode() hashCode = hashCode * 59 + this.EnumNumber.GetHashCode(); if (this.OuterEnum != null) hashCode = hashCode * 59 + this.OuterEnum.GetHashCode(); + if (this.OuterEnumInteger != null) + hashCode = hashCode * 59 + this.OuterEnumInteger.GetHashCode(); + if (this.OuterEnumDefaultValue != null) + hashCode = hashCode * 59 + this.OuterEnumDefaultValue.GetHashCode(); + if (this.OuterEnumIntegerDefaultValue != null) + hashCode = hashCode * 59 + this.OuterEnumIntegerDefaultValue.GetHashCode(); return hashCode; } } diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/Foo.cs b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/Foo.cs index ddb699c34f59..312590522484 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/Foo.cs +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/Foo.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/FormatTest.cs b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/FormatTest.cs index 8128f7a332c7..c5341a1c5ecd 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/FormatTest.cs +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/FormatTest.cs @@ -49,8 +49,9 @@ protected FormatTest() { } /// dateTime. /// uuid. /// password (required). - /// bigDecimal. - public FormatTest(int integer = default(int), int int32 = default(int), long int64 = default(long), decimal number = default(decimal), float _float = default(float), double _double = default(double), string _string = default(string), byte[] _byte = default(byte[]), System.IO.Stream binary = default(System.IO.Stream), DateTime date = default(DateTime), DateTime dateTime = default(DateTime), Guid uuid = default(Guid), string password = default(string), decimal bigDecimal = default(decimal)) + /// A string that is a 10 digit number. Can have leading zeros.. + /// A string starting with 'image_' (case insensitive) and one to three digits following i.e. Image_01.. + public FormatTest(int integer = default(int), int int32 = default(int), long int64 = default(long), decimal number = default(decimal), float _float = default(float), double _double = default(double), string _string = default(string), byte[] _byte = default(byte[]), System.IO.Stream binary = default(System.IO.Stream), DateTime date = default(DateTime), DateTime dateTime = default(DateTime), Guid uuid = default(Guid), string password = default(string), string patternWithDigits = default(string), string patternWithDigitsAndDelimiter = default(string)) { // to ensure "number" is required (not null) if (number == null) @@ -101,7 +102,8 @@ protected FormatTest() { } this.Binary = binary; this.DateTime = dateTime; this.Uuid = uuid; - this.BigDecimal = bigDecimal; + this.PatternWithDigits = patternWithDigits; + this.PatternWithDigitsAndDelimiter = patternWithDigitsAndDelimiter; } /// @@ -184,10 +186,18 @@ protected FormatTest() { } public string Password { get; set; } /// - /// Gets or Sets BigDecimal + /// A string that is a 10 digit number. Can have leading zeros. /// - [DataMember(Name="BigDecimal", EmitDefaultValue=false)] - public decimal BigDecimal { get; set; } + /// A string that is a 10 digit number. Can have leading zeros. + [DataMember(Name="pattern_with_digits", EmitDefaultValue=false)] + public string PatternWithDigits { get; set; } + + /// + /// A string starting with 'image_' (case insensitive) and one to three digits following i.e. Image_01. + /// + /// A string starting with 'image_' (case insensitive) and one to three digits following i.e. Image_01. + [DataMember(Name="pattern_with_digits_and_delimiter", EmitDefaultValue=false)] + public string PatternWithDigitsAndDelimiter { get; set; } /// /// Returns the string presentation of the object @@ -210,7 +220,8 @@ public override string ToString() sb.Append(" DateTime: ").Append(DateTime).Append("\n"); sb.Append(" Uuid: ").Append(Uuid).Append("\n"); sb.Append(" Password: ").Append(Password).Append("\n"); - sb.Append(" BigDecimal: ").Append(BigDecimal).Append("\n"); + sb.Append(" PatternWithDigits: ").Append(PatternWithDigits).Append("\n"); + sb.Append(" PatternWithDigitsAndDelimiter: ").Append(PatternWithDigitsAndDelimiter).Append("\n"); sb.Append("}\n"); return sb.ToString(); } @@ -311,9 +322,14 @@ public bool Equals(FormatTest input) this.Password.Equals(input.Password)) ) && ( - this.BigDecimal == input.BigDecimal || - (this.BigDecimal != null && - this.BigDecimal.Equals(input.BigDecimal)) + this.PatternWithDigits == input.PatternWithDigits || + (this.PatternWithDigits != null && + this.PatternWithDigits.Equals(input.PatternWithDigits)) + ) && + ( + this.PatternWithDigitsAndDelimiter == input.PatternWithDigitsAndDelimiter || + (this.PatternWithDigitsAndDelimiter != null && + this.PatternWithDigitsAndDelimiter.Equals(input.PatternWithDigitsAndDelimiter)) ); } @@ -352,8 +368,10 @@ public override int GetHashCode() hashCode = hashCode * 59 + this.Uuid.GetHashCode(); if (this.Password != null) hashCode = hashCode * 59 + this.Password.GetHashCode(); - if (this.BigDecimal != null) - hashCode = hashCode * 59 + this.BigDecimal.GetHashCode(); + if (this.PatternWithDigits != null) + hashCode = hashCode * 59 + this.PatternWithDigits.GetHashCode(); + if (this.PatternWithDigitsAndDelimiter != null) + hashCode = hashCode * 59 + this.PatternWithDigitsAndDelimiter.GetHashCode(); return hashCode; } } diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/HealthCheckResult.cs b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/HealthCheckResult.cs new file mode 100644 index 000000000000..ab1b6405fdab --- /dev/null +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/HealthCheckResult.cs @@ -0,0 +1,113 @@ +/* + * OpenAPI Petstore + * + * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ + * + * The version of the OpenAPI document: 1.0.0 + * + * Generated by: https://github.com/openapitools/openapi-generator.git + */ + +using System; +using System.Linq; +using System.IO; +using System.Text; +using System.Collections; +using System.Collections.Generic; +using System.Collections.ObjectModel; +using System.Runtime.Serialization; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using OpenAPIDateConverter = Org.OpenAPITools.Client.OpenAPIDateConverter; + +namespace Org.OpenAPITools.Model +{ + /// + /// Just a string to inform instance is up and running. Make it nullable in hope to get it as pointer in generated model. + /// + [DataContract] + public partial class HealthCheckResult : IEquatable + { + /// + /// Initializes a new instance of the class. + /// + /// nullableMessage. + public HealthCheckResult(string nullableMessage = default(string)) + { + this.NullableMessage = nullableMessage; + this.NullableMessage = nullableMessage; + } + + /// + /// Gets or Sets NullableMessage + /// + [DataMember(Name="NullableMessage", EmitDefaultValue=true)] + public string NullableMessage { get; set; } + + /// + /// Returns the string presentation of the object + /// + /// String presentation of the object + public override string ToString() + { + var sb = new StringBuilder(); + sb.Append("class HealthCheckResult {\n"); + sb.Append(" NullableMessage: ").Append(NullableMessage).Append("\n"); + sb.Append("}\n"); + return sb.ToString(); + } + + /// + /// Returns the JSON string presentation of the object + /// + /// JSON string presentation of the object + public virtual string ToJson() + { + return JsonConvert.SerializeObject(this, Formatting.Indented); + } + + /// + /// Returns true if objects are equal + /// + /// Object to be compared + /// Boolean + public override bool Equals(object input) + { + return this.Equals(input as HealthCheckResult); + } + + /// + /// Returns true if HealthCheckResult instances are equal + /// + /// Instance of HealthCheckResult to be compared + /// Boolean + public bool Equals(HealthCheckResult input) + { + if (input == null) + return false; + + return + ( + this.NullableMessage == input.NullableMessage || + (this.NullableMessage != null && + this.NullableMessage.Equals(input.NullableMessage)) + ); + } + + /// + /// Gets the hash code + /// + /// Hash code + public override int GetHashCode() + { + unchecked // Overflow is fine, just wrap + { + int hashCode = 41; + if (this.NullableMessage != null) + hashCode = hashCode * 59 + this.NullableMessage.GetHashCode(); + return hashCode; + } + } + } + +} diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/InlineObject.cs b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/InlineObject.cs index 10ced6b83255..c9b5274e83bc 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/InlineObject.cs +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/InlineObject.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/InlineObject1.cs b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/InlineObject1.cs index 65063f5bf482..586aea86ee63 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/InlineObject1.cs +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/InlineObject1.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/InlineObject2.cs b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/InlineObject2.cs index cc99ca7bf970..ec1a6e1bacf5 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/InlineObject2.cs +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/InlineObject2.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -156,6 +156,7 @@ public bool Equals(InlineObject2 input) ( this.EnumFormStringArray == input.EnumFormStringArray || this.EnumFormStringArray != null && + input.EnumFormStringArray != null && this.EnumFormStringArray.SequenceEqual(input.EnumFormStringArray) ) && ( diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/InlineObject3.cs b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/InlineObject3.cs index 504e0b0fe6a0..97139fd90b2a 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/InlineObject3.cs +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/InlineObject3.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -50,7 +50,7 @@ protected InlineObject3() { } /// None. /// None. /// None. - public InlineObject3(int? integer = default(int?), int? int32 = default(int?), long? int64 = default(long?), decimal? number = default(decimal?), float? _float = default(float?), double? _double = default(double?), string _string = default(string), string patternWithoutDelimiter = default(string), byte[] _byte = default(byte[]), System.IO.Stream binary = default(System.IO.Stream), DateTime? date = default(DateTime?), DateTime? dateTime = default(DateTime?), string password = default(string), string callback = default(string)) + public InlineObject3(int integer = default(int), int int32 = default(int), long int64 = default(long), decimal number = default(decimal), float _float = default(float), double _double = default(double), string _string = default(string), string patternWithoutDelimiter = default(string), byte[] _byte = default(byte[]), System.IO.Stream binary = default(System.IO.Stream), DateTime date = default(DateTime), DateTime dateTime = default(DateTime), string password = default(string), string callback = default(string)) { // to ensure "number" is required (not null) if (number == null) @@ -61,6 +61,7 @@ protected InlineObject3() { } { this.Number = number; } + // to ensure "_double" is required (not null) if (_double == null) { @@ -70,6 +71,7 @@ protected InlineObject3() { } { this.Double = _double; } + // to ensure "patternWithoutDelimiter" is required (not null) if (patternWithoutDelimiter == null) { @@ -79,6 +81,7 @@ protected InlineObject3() { } { this.PatternWithoutDelimiter = patternWithoutDelimiter; } + // to ensure "_byte" is required (not null) if (_byte == null) { @@ -88,6 +91,7 @@ protected InlineObject3() { } { this.Byte = _byte; } + this.Integer = integer; this.Int32 = int32; this.Int64 = int64; @@ -105,42 +109,42 @@ protected InlineObject3() { } /// /// None [DataMember(Name="integer", EmitDefaultValue=false)] - public int? Integer { get; set; } + public int Integer { get; set; } /// /// None /// /// None [DataMember(Name="int32", EmitDefaultValue=false)] - public int? Int32 { get; set; } + public int Int32 { get; set; } /// /// None /// /// None [DataMember(Name="int64", EmitDefaultValue=false)] - public long? Int64 { get; set; } + public long Int64 { get; set; } /// /// None /// /// None - [DataMember(Name="number", EmitDefaultValue=false)] - public decimal? Number { get; set; } + [DataMember(Name="number", EmitDefaultValue=true)] + public decimal Number { get; set; } /// /// None /// /// None [DataMember(Name="float", EmitDefaultValue=false)] - public float? Float { get; set; } + public float Float { get; set; } /// /// None /// /// None - [DataMember(Name="double", EmitDefaultValue=false)] - public double? Double { get; set; } + [DataMember(Name="double", EmitDefaultValue=true)] + public double Double { get; set; } /// /// None @@ -153,14 +157,14 @@ protected InlineObject3() { } /// None /// /// None - [DataMember(Name="pattern_without_delimiter", EmitDefaultValue=false)] + [DataMember(Name="pattern_without_delimiter", EmitDefaultValue=true)] public string PatternWithoutDelimiter { get; set; } /// /// None /// /// None - [DataMember(Name="byte", EmitDefaultValue=false)] + [DataMember(Name="byte", EmitDefaultValue=true)] public byte[] Byte { get; set; } /// @@ -176,14 +180,14 @@ protected InlineObject3() { } /// None [DataMember(Name="date", EmitDefaultValue=false)] [JsonConverter(typeof(OpenAPIDateConverter))] - public DateTime? Date { get; set; } + public DateTime Date { get; set; } /// /// None /// /// None [DataMember(Name="dateTime", EmitDefaultValue=false)] - public DateTime? DateTime { get; set; } + public DateTime DateTime { get; set; } /// /// None diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/InlineObject4.cs b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/InlineObject4.cs index 7ad988b55f88..1cff92535feb 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/InlineObject4.cs +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/InlineObject4.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -49,6 +49,7 @@ protected InlineObject4() { } { this.Param = param; } + // to ensure "param2" is required (not null) if (param2 == null) { @@ -58,20 +59,21 @@ protected InlineObject4() { } { this.Param2 = param2; } + } /// /// field1 /// /// field1 - [DataMember(Name="param", EmitDefaultValue=false)] + [DataMember(Name="param", EmitDefaultValue=true)] public string Param { get; set; } /// /// field2 /// /// field2 - [DataMember(Name="param2", EmitDefaultValue=false)] + [DataMember(Name="param2", EmitDefaultValue=true)] public string Param2 { get; set; } /// diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/InlineObject5.cs b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/InlineObject5.cs index e80e5b733afa..f63950b34095 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/InlineObject5.cs +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/InlineObject5.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -49,6 +49,7 @@ protected InlineObject5() { } { this.RequiredFile = requiredFile; } + this.AdditionalMetadata = additionalMetadata; } @@ -63,7 +64,7 @@ protected InlineObject5() { } /// file to upload /// /// file to upload - [DataMember(Name="requiredFile", EmitDefaultValue=false)] + [DataMember(Name="requiredFile", EmitDefaultValue=true)] public System.IO.Stream RequiredFile { get; set; } /// diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/InlineResponseDefault.cs b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/InlineResponseDefault.cs index 42a0feba4c47..56d89df27aad 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/InlineResponseDefault.cs +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/InlineResponseDefault.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/NullableClass.cs b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/NullableClass.cs new file mode 100644 index 000000000000..35e9bd2ccf68 --- /dev/null +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/NullableClass.cs @@ -0,0 +1,306 @@ +/* + * OpenAPI Petstore + * + * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ + * + * The version of the OpenAPI document: 1.0.0 + * + * Generated by: https://github.com/openapitools/openapi-generator.git + */ + +using System; +using System.Linq; +using System.IO; +using System.Text; +using System.Collections; +using System.Collections.Generic; +using System.Collections.ObjectModel; +using System.Runtime.Serialization; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using OpenAPIDateConverter = Org.OpenAPITools.Client.OpenAPIDateConverter; + +namespace Org.OpenAPITools.Model +{ + /// + /// NullableClass + /// + [DataContract] + public partial class NullableClass : Dictionary, IEquatable + { + /// + /// Initializes a new instance of the class. + /// + /// integerProp. + /// numberProp. + /// booleanProp. + /// stringProp. + /// dateProp. + /// datetimeProp. + /// arrayNullableProp. + /// arrayAndItemsNullableProp. + /// arrayItemsNullable. + /// objectNullableProp. + /// objectAndItemsNullableProp. + /// objectItemsNullable. + public NullableClass(int? integerProp = default(int?), decimal? numberProp = default(decimal?), bool? booleanProp = default(bool?), string stringProp = default(string), DateTime? dateProp = default(DateTime?), DateTime? datetimeProp = default(DateTime?), List arrayNullableProp = default(List), List arrayAndItemsNullableProp = default(List), List arrayItemsNullable = default(List), Dictionary objectNullableProp = default(Dictionary), Dictionary objectAndItemsNullableProp = default(Dictionary), Dictionary objectItemsNullable = default(Dictionary)) : base() + { + this.IntegerProp = integerProp; + this.NumberProp = numberProp; + this.BooleanProp = booleanProp; + this.StringProp = stringProp; + this.DateProp = dateProp; + this.DatetimeProp = datetimeProp; + this.ArrayNullableProp = arrayNullableProp; + this.ArrayAndItemsNullableProp = arrayAndItemsNullableProp; + this.ObjectNullableProp = objectNullableProp; + this.ObjectAndItemsNullableProp = objectAndItemsNullableProp; + this.IntegerProp = integerProp; + this.NumberProp = numberProp; + this.BooleanProp = booleanProp; + this.StringProp = stringProp; + this.DateProp = dateProp; + this.DatetimeProp = datetimeProp; + this.ArrayNullableProp = arrayNullableProp; + this.ArrayAndItemsNullableProp = arrayAndItemsNullableProp; + this.ArrayItemsNullable = arrayItemsNullable; + this.ObjectNullableProp = objectNullableProp; + this.ObjectAndItemsNullableProp = objectAndItemsNullableProp; + this.ObjectItemsNullable = objectItemsNullable; + } + + /// + /// Gets or Sets IntegerProp + /// + [DataMember(Name="integer_prop", EmitDefaultValue=true)] + public int? IntegerProp { get; set; } + + /// + /// Gets or Sets NumberProp + /// + [DataMember(Name="number_prop", EmitDefaultValue=true)] + public decimal? NumberProp { get; set; } + + /// + /// Gets or Sets BooleanProp + /// + [DataMember(Name="boolean_prop", EmitDefaultValue=true)] + public bool? BooleanProp { get; set; } + + /// + /// Gets or Sets StringProp + /// + [DataMember(Name="string_prop", EmitDefaultValue=true)] + public string StringProp { get; set; } + + /// + /// Gets or Sets DateProp + /// + [DataMember(Name="date_prop", EmitDefaultValue=true)] + [JsonConverter(typeof(OpenAPIDateConverter))] + public DateTime? DateProp { get; set; } + + /// + /// Gets or Sets DatetimeProp + /// + [DataMember(Name="datetime_prop", EmitDefaultValue=true)] + public DateTime? DatetimeProp { get; set; } + + /// + /// Gets or Sets ArrayNullableProp + /// + [DataMember(Name="array_nullable_prop", EmitDefaultValue=true)] + public List ArrayNullableProp { get; set; } + + /// + /// Gets or Sets ArrayAndItemsNullableProp + /// + [DataMember(Name="array_and_items_nullable_prop", EmitDefaultValue=true)] + public List ArrayAndItemsNullableProp { get; set; } + + /// + /// Gets or Sets ArrayItemsNullable + /// + [DataMember(Name="array_items_nullable", EmitDefaultValue=false)] + public List ArrayItemsNullable { get; set; } + + /// + /// Gets or Sets ObjectNullableProp + /// + [DataMember(Name="object_nullable_prop", EmitDefaultValue=true)] + public Dictionary ObjectNullableProp { get; set; } + + /// + /// Gets or Sets ObjectAndItemsNullableProp + /// + [DataMember(Name="object_and_items_nullable_prop", EmitDefaultValue=true)] + public Dictionary ObjectAndItemsNullableProp { get; set; } + + /// + /// Gets or Sets ObjectItemsNullable + /// + [DataMember(Name="object_items_nullable", EmitDefaultValue=false)] + public Dictionary ObjectItemsNullable { get; set; } + + /// + /// Returns the string presentation of the object + /// + /// String presentation of the object + public override string ToString() + { + var sb = new StringBuilder(); + sb.Append("class NullableClass {\n"); + sb.Append(" ").Append(base.ToString().Replace("\n", "\n ")).Append("\n"); + sb.Append(" IntegerProp: ").Append(IntegerProp).Append("\n"); + sb.Append(" NumberProp: ").Append(NumberProp).Append("\n"); + sb.Append(" BooleanProp: ").Append(BooleanProp).Append("\n"); + sb.Append(" StringProp: ").Append(StringProp).Append("\n"); + sb.Append(" DateProp: ").Append(DateProp).Append("\n"); + sb.Append(" DatetimeProp: ").Append(DatetimeProp).Append("\n"); + sb.Append(" ArrayNullableProp: ").Append(ArrayNullableProp).Append("\n"); + sb.Append(" ArrayAndItemsNullableProp: ").Append(ArrayAndItemsNullableProp).Append("\n"); + sb.Append(" ArrayItemsNullable: ").Append(ArrayItemsNullable).Append("\n"); + sb.Append(" ObjectNullableProp: ").Append(ObjectNullableProp).Append("\n"); + sb.Append(" ObjectAndItemsNullableProp: ").Append(ObjectAndItemsNullableProp).Append("\n"); + sb.Append(" ObjectItemsNullable: ").Append(ObjectItemsNullable).Append("\n"); + sb.Append("}\n"); + return sb.ToString(); + } + + /// + /// Returns the JSON string presentation of the object + /// + /// JSON string presentation of the object + public string ToJson() + { + return JsonConvert.SerializeObject(this, Formatting.Indented); + } + + /// + /// Returns true if objects are equal + /// + /// Object to be compared + /// Boolean + public override bool Equals(object input) + { + return this.Equals(input as NullableClass); + } + + /// + /// Returns true if NullableClass instances are equal + /// + /// Instance of NullableClass to be compared + /// Boolean + public bool Equals(NullableClass input) + { + if (input == null) + return false; + + return base.Equals(input) && + ( + this.IntegerProp == input.IntegerProp || + (this.IntegerProp != null && + this.IntegerProp.Equals(input.IntegerProp)) + ) && base.Equals(input) && + ( + this.NumberProp == input.NumberProp || + (this.NumberProp != null && + this.NumberProp.Equals(input.NumberProp)) + ) && base.Equals(input) && + ( + this.BooleanProp == input.BooleanProp || + (this.BooleanProp != null && + this.BooleanProp.Equals(input.BooleanProp)) + ) && base.Equals(input) && + ( + this.StringProp == input.StringProp || + (this.StringProp != null && + this.StringProp.Equals(input.StringProp)) + ) && base.Equals(input) && + ( + this.DateProp == input.DateProp || + (this.DateProp != null && + this.DateProp.Equals(input.DateProp)) + ) && base.Equals(input) && + ( + this.DatetimeProp == input.DatetimeProp || + (this.DatetimeProp != null && + this.DatetimeProp.Equals(input.DatetimeProp)) + ) && base.Equals(input) && + ( + this.ArrayNullableProp == input.ArrayNullableProp || + this.ArrayNullableProp != null && + input.ArrayNullableProp != null && + this.ArrayNullableProp.SequenceEqual(input.ArrayNullableProp) + ) && base.Equals(input) && + ( + this.ArrayAndItemsNullableProp == input.ArrayAndItemsNullableProp || + this.ArrayAndItemsNullableProp != null && + input.ArrayAndItemsNullableProp != null && + this.ArrayAndItemsNullableProp.SequenceEqual(input.ArrayAndItemsNullableProp) + ) && base.Equals(input) && + ( + this.ArrayItemsNullable == input.ArrayItemsNullable || + this.ArrayItemsNullable != null && + input.ArrayItemsNullable != null && + this.ArrayItemsNullable.SequenceEqual(input.ArrayItemsNullable) + ) && base.Equals(input) && + ( + this.ObjectNullableProp == input.ObjectNullableProp || + this.ObjectNullableProp != null && + input.ObjectNullableProp != null && + this.ObjectNullableProp.SequenceEqual(input.ObjectNullableProp) + ) && base.Equals(input) && + ( + this.ObjectAndItemsNullableProp == input.ObjectAndItemsNullableProp || + this.ObjectAndItemsNullableProp != null && + input.ObjectAndItemsNullableProp != null && + this.ObjectAndItemsNullableProp.SequenceEqual(input.ObjectAndItemsNullableProp) + ) && base.Equals(input) && + ( + this.ObjectItemsNullable == input.ObjectItemsNullable || + this.ObjectItemsNullable != null && + input.ObjectItemsNullable != null && + this.ObjectItemsNullable.SequenceEqual(input.ObjectItemsNullable) + ); + } + + /// + /// Gets the hash code + /// + /// Hash code + public override int GetHashCode() + { + unchecked // Overflow is fine, just wrap + { + int hashCode = base.GetHashCode(); + if (this.IntegerProp != null) + hashCode = hashCode * 59 + this.IntegerProp.GetHashCode(); + if (this.NumberProp != null) + hashCode = hashCode * 59 + this.NumberProp.GetHashCode(); + if (this.BooleanProp != null) + hashCode = hashCode * 59 + this.BooleanProp.GetHashCode(); + if (this.StringProp != null) + hashCode = hashCode * 59 + this.StringProp.GetHashCode(); + if (this.DateProp != null) + hashCode = hashCode * 59 + this.DateProp.GetHashCode(); + if (this.DatetimeProp != null) + hashCode = hashCode * 59 + this.DatetimeProp.GetHashCode(); + if (this.ArrayNullableProp != null) + hashCode = hashCode * 59 + this.ArrayNullableProp.GetHashCode(); + if (this.ArrayAndItemsNullableProp != null) + hashCode = hashCode * 59 + this.ArrayAndItemsNullableProp.GetHashCode(); + if (this.ArrayItemsNullable != null) + hashCode = hashCode * 59 + this.ArrayItemsNullable.GetHashCode(); + if (this.ObjectNullableProp != null) + hashCode = hashCode * 59 + this.ObjectNullableProp.GetHashCode(); + if (this.ObjectAndItemsNullableProp != null) + hashCode = hashCode * 59 + this.ObjectAndItemsNullableProp.GetHashCode(); + if (this.ObjectItemsNullable != null) + hashCode = hashCode * 59 + this.ObjectItemsNullable.GetHashCode(); + return hashCode; + } + } + } + +} diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/OuterEnumDefaultValue.cs b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/OuterEnumDefaultValue.cs new file mode 100644 index 000000000000..36a3f4322acb --- /dev/null +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/OuterEnumDefaultValue.cs @@ -0,0 +1,53 @@ +/* + * OpenAPI Petstore + * + * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ + * + * The version of the OpenAPI document: 1.0.0 + * + * Generated by: https://github.com/openapitools/openapi-generator.git + */ + +using System; +using System.Linq; +using System.IO; +using System.Text; +using System.Collections; +using System.Collections.Generic; +using System.Collections.ObjectModel; +using System.Runtime.Serialization; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using OpenAPIDateConverter = Org.OpenAPITools.Client.OpenAPIDateConverter; + +namespace Org.OpenAPITools.Model +{ + /// + /// Defines OuterEnumDefaultValue + /// + + [JsonConverter(typeof(StringEnumConverter))] + + public enum OuterEnumDefaultValue + { + /// + /// Enum Placed for value: placed + /// + [EnumMember(Value = "placed")] + Placed = 1, + + /// + /// Enum Approved for value: approved + /// + [EnumMember(Value = "approved")] + Approved = 2, + + /// + /// Enum Delivered for value: delivered + /// + [EnumMember(Value = "delivered")] + Delivered = 3 + + } + +} diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/OuterEnumInteger.cs b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/OuterEnumInteger.cs new file mode 100644 index 000000000000..7908216a230c --- /dev/null +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/OuterEnumInteger.cs @@ -0,0 +1,53 @@ +/* + * OpenAPI Petstore + * + * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ + * + * The version of the OpenAPI document: 1.0.0 + * + * Generated by: https://github.com/openapitools/openapi-generator.git + */ + +using System; +using System.Linq; +using System.IO; +using System.Text; +using System.Collections; +using System.Collections.Generic; +using System.Collections.ObjectModel; +using System.Runtime.Serialization; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using OpenAPIDateConverter = Org.OpenAPITools.Client.OpenAPIDateConverter; + +namespace Org.OpenAPITools.Model +{ + /// + /// Defines OuterEnumInteger + /// + + [JsonConverter(typeof(StringEnumConverter))] + + public enum OuterEnumInteger + { + /// + /// Enum NUMBER_0 for value: 0 + /// + [EnumMember(Value = "0")] + NUMBER_0 = 1, + + /// + /// Enum NUMBER_1 for value: 1 + /// + [EnumMember(Value = "1")] + NUMBER_1 = 2, + + /// + /// Enum NUMBER_2 for value: 2 + /// + [EnumMember(Value = "2")] + NUMBER_2 = 3 + + } + +} diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/OuterEnumIntegerDefaultValue.cs b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/OuterEnumIntegerDefaultValue.cs new file mode 100644 index 000000000000..0c75ede67b32 --- /dev/null +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Model/OuterEnumIntegerDefaultValue.cs @@ -0,0 +1,53 @@ +/* + * OpenAPI Petstore + * + * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ + * + * The version of the OpenAPI document: 1.0.0 + * + * Generated by: https://github.com/openapitools/openapi-generator.git + */ + +using System; +using System.Linq; +using System.IO; +using System.Text; +using System.Collections; +using System.Collections.Generic; +using System.Collections.ObjectModel; +using System.Runtime.Serialization; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using OpenAPIDateConverter = Org.OpenAPITools.Client.OpenAPIDateConverter; + +namespace Org.OpenAPITools.Model +{ + /// + /// Defines OuterEnumIntegerDefaultValue + /// + + [JsonConverter(typeof(StringEnumConverter))] + + public enum OuterEnumIntegerDefaultValue + { + /// + /// Enum NUMBER_0 for value: 0 + /// + [EnumMember(Value = "0")] + NUMBER_0 = 1, + + /// + /// Enum NUMBER_1 for value: 1 + /// + [EnumMember(Value = "1")] + NUMBER_1 = 2, + + /// + /// Enum NUMBER_2 for value: 2 + /// + [EnumMember(Value = "2")] + NUMBER_2 = 3 + + } + +} diff --git a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Org.OpenAPITools.csproj b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Org.OpenAPITools.csproj index 0b8a73d6143f..7c827a81c332 100644 --- a/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Org.OpenAPITools.csproj +++ b/samples/client/petstore/csharp/OpenAPIClientNetStandard/src/Org.OpenAPITools/Org.OpenAPITools.csproj @@ -12,7 +12,7 @@ The version of the OpenAPI document: 1.0.0 14.0 Debug AnyCPU - {3AB1F259-1769-484B-9411-84505FCCBD55} + {321C8C3F-0156-40C1-AE42-D59761FB9B6C} Library Properties Org.OpenAPITools diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/Cat.cs b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/Cat.cs index 364ef5df0d8f..1c2c2baf2976 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/Cat.cs +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/Cat.cs @@ -42,7 +42,7 @@ protected Cat() { } /// Initializes a new instance of the class. /// /// declawed. - public Cat(bool declawed = default(bool), string className = default(string), string color = "red") : base(className, color) + public Cat(bool declawed = default(bool), string className = "Cat", string color = "red") : base(className, color) { this.Declawed = declawed; } diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/Dog.cs b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/Dog.cs index 36fdef563493..b60019d438fa 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/Dog.cs +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/Dog.cs @@ -42,7 +42,7 @@ protected Dog() { } /// Initializes a new instance of the class. /// /// breed. - public Dog(string breed = default(string), string className = default(string), string color = "red") : base(className, color) + public Dog(string breed = default(string), string className = "Dog", string color = "red") : base(className, color) { this.Breed = breed; } diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/.openapi-generator/VERSION b/samples/openapi3/client/petstore/csharp/OpenAPIClient/.openapi-generator/VERSION index afa636560641..d99e7162d01f 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/.openapi-generator/VERSION +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/.openapi-generator/VERSION @@ -1 +1 @@ -4.0.0-SNAPSHOT \ No newline at end of file +5.0.0-SNAPSHOT \ No newline at end of file diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/README.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/README.md index 960cc01cd7e0..4b200ade794d 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/README.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/README.md @@ -8,18 +8,21 @@ This C# SDK is automatically generated by the [OpenAPI Generator](https://openap - SDK version: 1.0.0 - Build package: org.openapitools.codegen.languages.CSharpClientCodegen - ## Frameworks supported + + - .NET 4.0 or later - Windows Phone 7.1 (Mango) - ## Dependencies + + - [RestSharp](https://www.nuget.org/packages/RestSharp) - 105.1.0 or later - [Json.NET](https://www.nuget.org/packages/Newtonsoft.Json/) - 7.0.0 or later - [JsonSubTypes](https://www.nuget.org/packages/JsonSubTypes/) - 1.2.0 or later The DLLs included in the package may not be the latest version. We recommend using [NuGet](https://docs.nuget.org/consume/installing-nuget) to obtain the latest version of the packages: + ``` Install-Package RestSharp Install-Package Newtonsoft.Json @@ -28,19 +31,23 @@ Install-Package JsonSubTypes NOTE: RestSharp versions greater than 105.1.0 have a bug which causes file uploads to fail. See [RestSharp#742](https://github.com/restsharp/RestSharp/issues/742) - ## Installation + Run the following command to generate the DLL + - [Mac/Linux] `/bin/sh build.sh` - [Windows] `build.bat` Then include the DLL (under the `bin` folder) in the C# project, and use the namespaces: + ```csharp using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; using Org.OpenAPITools.Model; + ``` - + + ## Packaging A `.nuspec` is included with the project. You can follow the Nuget quickstart to [create](https://docs.microsoft.com/en-us/nuget/quickstart/create-and-publish-a-package#create-the-package) and [publish](https://docs.microsoft.com/en-us/nuget/quickstart/create-and-publish-a-package#publish-the-package) packages. @@ -53,11 +60,11 @@ nuget pack -Build -OutputDirectory out Org.OpenAPITools.csproj Then, publish to a [local feed](https://docs.microsoft.com/en-us/nuget/hosting-packages/local-feeds) or [other host](https://docs.microsoft.com/en-us/nuget/hosting-packages/overview) and consume the new package via Nuget as usual. - + ## Getting Started ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -67,10 +74,11 @@ namespace Example { public class Example { - public void main() + public static void Main() { - var apiInstance = new AnotherFakeApi(); + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new AnotherFakeApi(Configuration.Default); var modelClient = new ModelClient(); // ModelClient | client model try @@ -79,9 +87,11 @@ namespace Example ModelClient result = apiInstance.Call123TestSpecialTags(modelClient); Debug.WriteLine(result); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling AnotherFakeApi.Call123TestSpecialTags: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } @@ -89,7 +99,6 @@ namespace Example } ``` - ## Documentation for API Endpoints All URIs are relative to *http://petstore.swagger.io:80/v2* @@ -99,6 +108,7 @@ Class | Method | HTTP request | Description *AnotherFakeApi* | [**Call123TestSpecialTags**](docs/AnotherFakeApi.md#call123testspecialtags) | **PATCH** /another-fake/dummy | To test special tags *DefaultApi* | [**FooGet**](docs/DefaultApi.md#fooget) | **GET** /foo | *FakeApi* | [**FakeHealthGet**](docs/FakeApi.md#fakehealthget) | **GET** /fake/health | Health check endpoint +*FakeApi* | [**FakeHttpSignatureTest**](docs/FakeApi.md#fakehttpsignaturetest) | **GET** /fake/http-signature-test | test http signature authentication *FakeApi* | [**FakeOuterBooleanSerialize**](docs/FakeApi.md#fakeouterbooleanserialize) | **POST** /fake/outer/boolean | *FakeApi* | [**FakeOuterCompositeSerialize**](docs/FakeApi.md#fakeoutercompositeserialize) | **POST** /fake/outer/composite | *FakeApi* | [**FakeOuterNumberSerialize**](docs/FakeApi.md#fakeouternumberserialize) | **POST** /fake/outer/number | @@ -111,6 +121,7 @@ Class | Method | HTTP request | Description *FakeApi* | [**TestGroupParameters**](docs/FakeApi.md#testgroupparameters) | **DELETE** /fake | Fake endpoint to test group parameters (optional) *FakeApi* | [**TestInlineAdditionalProperties**](docs/FakeApi.md#testinlineadditionalproperties) | **POST** /fake/inline-additionalProperties | test inline additionalProperties *FakeApi* | [**TestJsonFormData**](docs/FakeApi.md#testjsonformdata) | **GET** /fake/jsonFormData | test json serialization of form data +*FakeApi* | [**TestQueryParameterCollectionFormat**](docs/FakeApi.md#testqueryparametercollectionformat) | **PUT** /fake/test-query-paramters | *FakeClassnameTags123Api* | [**TestClassname**](docs/FakeClassnameTags123Api.md#testclassname) | **PATCH** /fake_classname_test | To test class name in snake case *PetApi* | [**AddPet**](docs/PetApi.md#addpet) | **POST** /pet | Add a new pet to the store *PetApi* | [**DeletePet**](docs/PetApi.md#deletepet) | **DELETE** /pet/{petId} | Deletes a pet @@ -135,7 +146,6 @@ Class | Method | HTTP request | Description *UserApi* | [**UpdateUser**](docs/UserApi.md#updateuser) | **PUT** /user/{username} | Updated user - ## Documentation for Models - [Model.AdditionalPropertiesClass](docs/AdditionalPropertiesClass.md) @@ -146,9 +156,11 @@ Class | Method | HTTP request | Description - [Model.ArrayTest](docs/ArrayTest.md) - [Model.Capitalization](docs/Capitalization.md) - [Model.Cat](docs/Cat.md) + - [Model.CatAllOf](docs/CatAllOf.md) - [Model.Category](docs/Category.md) - [Model.ClassModel](docs/ClassModel.md) - [Model.Dog](docs/Dog.md) + - [Model.DogAllOf](docs/DogAllOf.md) - [Model.EnumArrays](docs/EnumArrays.md) - [Model.EnumClass](docs/EnumClass.md) - [Model.EnumTest](docs/EnumTest.md) @@ -187,36 +199,44 @@ Class | Method | HTTP request | Description - [Model.User](docs/User.md) - ## Documentation for Authorization - + ### api_key - **Type**: API key + - **API key parameter name**: api_key - **Location**: HTTP header - + ### api_key_query - **Type**: API key + - **API key parameter name**: api_key_query - **Location**: URL query string - + ### bearer_test -- **Type**: HTTP basic authentication - +- **Type**: HTTP bearer authentication + + ### http_basic_test + - **Type**: HTTP basic authentication - + +### http_signature_test + + + ### petstore_auth + - **Type**: OAuth - **Flow**: implicit - **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/build.bat b/samples/openapi3/client/petstore/csharp/OpenAPIClient/build.bat index 88942a71d0f7..9849135797df 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/build.bat +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/build.bat @@ -10,8 +10,8 @@ if not exist ".\nuget.exe" powershell -Command "(new-object System.Net.WebClient if not exist ".\bin" mkdir bin -copy packages\Newtonsoft.Json.10.0.3\lib\net45\Newtonsoft.Json.dll bin\Newtonsoft.Json.dll -copy packages\JsonSubTypes.1.2.0\lib\net45\JsonSubTypes.dll bin\JsonSubTypes.dll +copy packages\Newtonsoft.Json.12.0.3\lib\net45\Newtonsoft.Json.dll bin\Newtonsoft.Json.dll +copy packages\JsonSubTypes.1.6.0\lib\net45\JsonSubTypes.dll bin\JsonSubTypes.dll copy packages\RestSharp.105.1.0\lib\net45\RestSharp.dll bin\RestSharp.dll %CSCPATH%\csc /reference:bin\Newtonsoft.Json.dll;bin\JsonSubTypes.dll;bin\RestSharp.dll;System.ComponentModel.DataAnnotations.dll /target:library /out:bin\Org.OpenAPITools.dll /recurse:src\Org.OpenAPITools\*.cs /doc:bin\Org.OpenAPITools.xml diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/build.sh b/samples/openapi3/client/petstore/csharp/OpenAPIClient/build.sh index 269c087258e9..15365d6014d8 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/build.sh +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/build.sh @@ -44,9 +44,9 @@ ${nuget_cmd} install src/Org.OpenAPITools/packages.config -o packages; echo "[INFO] Copy DLLs to the 'bin' folder" mkdir -p bin; -cp packages/Newtonsoft.Json.10.0.3/lib/net45/Newtonsoft.Json.dll bin/Newtonsoft.Json.dll; +cp packages/Newtonsoft.Json.12.0.3/lib/net45/Newtonsoft.Json.dll bin/Newtonsoft.Json.dll; cp packages/RestSharp.105.1.0/lib/net45/RestSharp.dll bin/RestSharp.dll; -cp packages/JsonSubTypes.1.2.0/lib/net45/JsonSubTypes.dll bin/JsonSubTypes.dll +cp packages/JsonSubTypes.1.6.0/lib/net45/JsonSubTypes.dll bin/JsonSubTypes.dll echo "[INFO] Run 'mcs' to build bin/Org.OpenAPITools.dll" mcs -langversion:${langversion} -sdk:${sdk} -r:bin/Newtonsoft.Json.dll,bin/JsonSubTypes.dll,\ diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/AdditionalPropertiesClass.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/AdditionalPropertiesClass.md index 057f5bd65dfc..847bf120968f 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/AdditionalPropertiesClass.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/AdditionalPropertiesClass.md @@ -1,4 +1,6 @@ + # Org.OpenAPITools.Model.AdditionalPropertiesClass + ## Properties Name | Type | Description | Notes @@ -6,5 +8,7 @@ Name | Type | Description | Notes **MapProperty** | **Dictionary<string, string>** | | [optional] **MapOfMapProperty** | **Dictionary<string, Dictionary<string, string>>** | | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Animal.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Animal.md index a97ce49b8018..0a05bcdf0616 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Animal.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Animal.md @@ -1,4 +1,6 @@ + # Org.OpenAPITools.Model.Animal + ## Properties Name | Type | Description | Notes @@ -6,5 +8,7 @@ Name | Type | Description | Notes **ClassName** | **string** | | **Color** | **string** | | [optional] [default to "red"] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/AnotherFakeApi.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/AnotherFakeApi.md index 81cc3106d64f..c7cb3d05138b 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/AnotherFakeApi.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/AnotherFakeApi.md @@ -7,8 +7,9 @@ Method | HTTP request | Description [**Call123TestSpecialTags**](AnotherFakeApi.md#call123testspecialtags) | **PATCH** /another-fake/dummy | To test special tags - -# **Call123TestSpecialTags** + +## Call123TestSpecialTags + > ModelClient Call123TestSpecialTags (ModelClient modelClient) To test special tags @@ -16,8 +17,9 @@ To test special tags To test special tags and operation ID starting with number ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -27,9 +29,10 @@ namespace Example { public class Call123TestSpecialTagsExample { - public void main() + public static void Main() { - var apiInstance = new AnotherFakeApi(); + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new AnotherFakeApi(Configuration.Default); var modelClient = new ModelClient(); // ModelClient | client model try @@ -38,9 +41,11 @@ namespace Example ModelClient result = apiInstance.Call123TestSpecialTags(modelClient); Debug.WriteLine(result); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling AnotherFakeApi.Call123TestSpecialTags: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -49,6 +54,7 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **modelClient** | [**ModelClient**](ModelClient.md)| client model | @@ -63,8 +69,16 @@ No authorization required ### HTTP request headers - - **Content-Type**: application/json - - **Accept**: application/json +- **Content-Type**: application/json +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | - | -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/ApiResponse.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/ApiResponse.md index 01b35815bd40..a3b916355fda 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/ApiResponse.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/ApiResponse.md @@ -1,11 +1,15 @@ + # Org.OpenAPITools.Model.ApiResponse + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Code** | **int?** | | [optional] +**Code** | **int** | | [optional] **Type** | **string** | | [optional] **Message** | **string** | | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/ArrayOfArrayOfNumberOnly.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/ArrayOfArrayOfNumberOnly.md index 614546d32564..e05ea7dc240f 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/ArrayOfArrayOfNumberOnly.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/ArrayOfArrayOfNumberOnly.md @@ -1,9 +1,13 @@ + # Org.OpenAPITools.Model.ArrayOfArrayOfNumberOnly + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**ArrayArrayNumber** | **List<List<decimal?>>** | | [optional] +**ArrayArrayNumber** | **List<List<decimal>>** | | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/ArrayOfNumberOnly.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/ArrayOfNumberOnly.md index 1886a6edcb46..5f593d42929a 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/ArrayOfNumberOnly.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/ArrayOfNumberOnly.md @@ -1,9 +1,13 @@ + # Org.OpenAPITools.Model.ArrayOfNumberOnly + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**ArrayNumber** | **List<decimal?>** | | [optional] +**ArrayNumber** | **List<decimal>** | | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/ArrayTest.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/ArrayTest.md index ff6a6cb24b0e..593bc2d73864 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/ArrayTest.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/ArrayTest.md @@ -1,11 +1,15 @@ + # Org.OpenAPITools.Model.ArrayTest + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **ArrayOfString** | **List<string>** | | [optional] -**ArrayArrayOfInteger** | **List<List<long?>>** | | [optional] +**ArrayArrayOfInteger** | **List<List<long>>** | | [optional] **ArrayArrayOfModel** | **List<List<ReadOnlyFirst>>** | | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Capitalization.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Capitalization.md index 74c1ab66db29..0c66f2d2d440 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Capitalization.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Capitalization.md @@ -1,4 +1,6 @@ + # Org.OpenAPITools.Model.Capitalization + ## Properties Name | Type | Description | Notes @@ -10,5 +12,7 @@ Name | Type | Description | Notes **SCAETHFlowPoints** | **string** | | [optional] **ATT_NAME** | **string** | Name of the pet | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Cat.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Cat.md index 4b79315204f3..6609de8e12a5 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Cat.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Cat.md @@ -1,11 +1,15 @@ + # Org.OpenAPITools.Model.Cat + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **ClassName** | **string** | | **Color** | **string** | | [optional] [default to "red"] -**Declawed** | **bool?** | | [optional] +**Declawed** | **bool** | | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/CatAllOf.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/CatAllOf.md new file mode 100644 index 000000000000..d623d2a0a6ef --- /dev/null +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/CatAllOf.md @@ -0,0 +1,13 @@ + +# Org.OpenAPITools.Model.CatAllOf + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Declawed** | **bool** | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) + diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Category.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Category.md index 67e28fe8d08e..42102d4e5084 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Category.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Category.md @@ -1,10 +1,14 @@ + # Org.OpenAPITools.Model.Category + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Id** | **long?** | | [optional] +**Id** | **long** | | [optional] **Name** | **string** | | [default to "default-name"] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/ClassModel.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/ClassModel.md index 556b05db2410..b2b42407d2b0 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/ClassModel.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/ClassModel.md @@ -1,9 +1,13 @@ + # Org.OpenAPITools.Model.ClassModel + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **Class** | **string** | | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/DefaultApi.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/DefaultApi.md index 92f2dc125c04..7ee074eba27c 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/DefaultApi.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/DefaultApi.md @@ -7,15 +7,17 @@ Method | HTTP request | Description [**FooGet**](DefaultApi.md#fooget) | **GET** /foo | - -# **FooGet** + +## FooGet + > InlineResponseDefault FooGet () ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -25,18 +27,21 @@ namespace Example { public class FooGetExample { - public void main() + public static void Main() { - var apiInstance = new DefaultApi(); + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new DefaultApi(Configuration.Default); try { InlineResponseDefault result = apiInstance.FooGet(); Debug.WriteLine(result); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling DefaultApi.FooGet: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -44,6 +49,7 @@ namespace Example ``` ### Parameters + This endpoint does not need any parameter. ### Return type @@ -56,8 +62,16 @@ No authorization required ### HTTP request headers - - **Content-Type**: Not defined - - **Accept**: application/json +- **Content-Type**: Not defined +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **0** | response | - | -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Dog.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Dog.md index aa5df1a927a1..1f39769d2b93 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Dog.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Dog.md @@ -1,4 +1,6 @@ + # Org.OpenAPITools.Model.Dog + ## Properties Name | Type | Description | Notes @@ -7,5 +9,7 @@ Name | Type | Description | Notes **Color** | **string** | | [optional] [default to "red"] **Breed** | **string** | | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/DogAllOf.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/DogAllOf.md new file mode 100644 index 000000000000..d72134a0f5f6 --- /dev/null +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/DogAllOf.md @@ -0,0 +1,13 @@ + +# Org.OpenAPITools.Model.DogAllOf + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Breed** | **string** | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) + diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/EnumArrays.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/EnumArrays.md index 2dfe0e223884..9d58d25f9729 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/EnumArrays.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/EnumArrays.md @@ -1,4 +1,6 @@ + # Org.OpenAPITools.Model.EnumArrays + ## Properties Name | Type | Description | Notes @@ -6,5 +8,7 @@ Name | Type | Description | Notes **JustSymbol** | **string** | | [optional] **ArrayEnum** | **List<string>** | | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/EnumClass.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/EnumClass.md index 4fb1eae9c066..16d21587b4c8 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/EnumClass.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/EnumClass.md @@ -1,8 +1,12 @@ + # Org.OpenAPITools.Model.EnumClass + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/EnumTest.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/EnumTest.md index 904379e7adeb..a8a888d45249 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/EnumTest.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/EnumTest.md @@ -1,16 +1,20 @@ + # Org.OpenAPITools.Model.EnumTest + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **EnumString** | **string** | | [optional] **EnumStringRequired** | **string** | | -**EnumInteger** | **int?** | | [optional] -**EnumNumber** | **double?** | | [optional] -**OuterEnum** | [**OuterEnum**](OuterEnum.md) | | [optional] -**OuterEnumInteger** | [**OuterEnumInteger**](OuterEnumInteger.md) | | [optional] -**OuterEnumDefaultValue** | [**OuterEnumDefaultValue**](OuterEnumDefaultValue.md) | | [optional] -**OuterEnumIntegerDefaultValue** | [**OuterEnumIntegerDefaultValue**](OuterEnumIntegerDefaultValue.md) | | [optional] +**EnumInteger** | **int** | | [optional] +**EnumNumber** | **double** | | [optional] +**OuterEnum** | **OuterEnum** | | [optional] +**OuterEnumInteger** | **OuterEnumInteger** | | [optional] +**OuterEnumDefaultValue** | **OuterEnumDefaultValue** | | [optional] +**OuterEnumIntegerDefaultValue** | **OuterEnumIntegerDefaultValue** | | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/FakeApi.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/FakeApi.md index 57ad5eefda36..38ab478e715b 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/FakeApi.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/FakeApi.md @@ -5,6 +5,7 @@ All URIs are relative to *http://petstore.swagger.io:80/v2* Method | HTTP request | Description ------------- | ------------- | ------------- [**FakeHealthGet**](FakeApi.md#fakehealthget) | **GET** /fake/health | Health check endpoint +[**FakeHttpSignatureTest**](FakeApi.md#fakehttpsignaturetest) | **GET** /fake/http-signature-test | test http signature authentication [**FakeOuterBooleanSerialize**](FakeApi.md#fakeouterbooleanserialize) | **POST** /fake/outer/boolean | [**FakeOuterCompositeSerialize**](FakeApi.md#fakeoutercompositeserialize) | **POST** /fake/outer/composite | [**FakeOuterNumberSerialize**](FakeApi.md#fakeouternumberserialize) | **POST** /fake/outer/number | @@ -17,17 +18,20 @@ Method | HTTP request | Description [**TestGroupParameters**](FakeApi.md#testgroupparameters) | **DELETE** /fake | Fake endpoint to test group parameters (optional) [**TestInlineAdditionalProperties**](FakeApi.md#testinlineadditionalproperties) | **POST** /fake/inline-additionalProperties | test inline additionalProperties [**TestJsonFormData**](FakeApi.md#testjsonformdata) | **GET** /fake/jsonFormData | test json serialization of form data +[**TestQueryParameterCollectionFormat**](FakeApi.md#testqueryparametercollectionformat) | **PUT** /fake/test-query-paramters | - -# **FakeHealthGet** + +## FakeHealthGet + > HealthCheckResult FakeHealthGet () Health check endpoint ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -37,9 +41,10 @@ namespace Example { public class FakeHealthGetExample { - public void main() + public static void Main() { - var apiInstance = new FakeApi(); + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new FakeApi(Configuration.Default); try { @@ -47,9 +52,11 @@ namespace Example HealthCheckResult result = apiInstance.FakeHealthGet(); Debug.WriteLine(result); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling FakeApi.FakeHealthGet: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -57,6 +64,7 @@ namespace Example ``` ### Parameters + This endpoint does not need any parameter. ### Return type @@ -69,22 +77,109 @@ No authorization required ### HTTP request headers - - **Content-Type**: Not defined - - **Accept**: application/json +- **Content-Type**: Not defined +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | The instance started successfully | - | + +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **FakeOuterBooleanSerialize** -> bool? FakeOuterBooleanSerialize (bool? body = null) +## FakeHttpSignatureTest + +> void FakeHttpSignatureTest (Pet pet, string query1 = null, string header1 = null) + +test http signature authentication + +### Example + +```csharp +using System.Collections.Generic; +using System.Diagnostics; +using Org.OpenAPITools.Api; +using Org.OpenAPITools.Client; +using Org.OpenAPITools.Model; + +namespace Example +{ + public class FakeHttpSignatureTestExample + { + public static void Main() + { + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + + var apiInstance = new FakeApi(Configuration.Default); + var pet = new Pet(); // Pet | Pet object that needs to be added to the store + var query1 = query1_example; // string | query parameter (optional) + var header1 = header1_example; // string | header parameter (optional) + + try + { + // test http signature authentication + apiInstance.FakeHttpSignatureTest(pet, query1, header1); + } + catch (ApiException e) + { + Debug.Print("Exception when calling FakeApi.FakeHttpSignatureTest: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); + } + } + } +} +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pet** | [**Pet**](Pet.md)| Pet object that needs to be added to the store | + **query1** | **string**| query parameter | [optional] + **header1** | **string**| header parameter | [optional] + +### Return type + +void (empty response body) + +### Authorization + +[http_signature_test](../README.md#http_signature_test) + +### HTTP request headers + +- **Content-Type**: application/json, application/xml +- **Accept**: Not defined + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | The instance started successfully | - | + +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) + + +## FakeOuterBooleanSerialize + +> bool FakeOuterBooleanSerialize (bool? body = null) Test serialization of outer boolean types ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -94,19 +189,22 @@ namespace Example { public class FakeOuterBooleanSerializeExample { - public void main() + public static void Main() { - var apiInstance = new FakeApi(); + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new FakeApi(Configuration.Default); var body = true; // bool? | Input boolean as post body (optional) try { - bool? result = apiInstance.FakeOuterBooleanSerialize(body); + bool result = apiInstance.FakeOuterBooleanSerialize(body); Debug.WriteLine(result); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling FakeApi.FakeOuterBooleanSerialize: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -115,13 +213,14 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **body** | **bool?**| Input boolean as post body | [optional] ### Return type -**bool?** +**bool** ### Authorization @@ -129,13 +228,22 @@ No authorization required ### HTTP request headers - - **Content-Type**: application/json - - **Accept**: */* +- **Content-Type**: application/json +- **Accept**: */* + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | Output boolean | - | -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) + + +## FakeOuterCompositeSerialize - -# **FakeOuterCompositeSerialize** > OuterComposite FakeOuterCompositeSerialize (OuterComposite outerComposite = null) @@ -143,8 +251,9 @@ No authorization required Test serialization of object with outer number type ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -154,9 +263,10 @@ namespace Example { public class FakeOuterCompositeSerializeExample { - public void main() + public static void Main() { - var apiInstance = new FakeApi(); + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new FakeApi(Configuration.Default); var outerComposite = new OuterComposite(); // OuterComposite | Input composite as post body (optional) try @@ -164,9 +274,11 @@ namespace Example OuterComposite result = apiInstance.FakeOuterCompositeSerialize(outerComposite); Debug.WriteLine(result); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling FakeApi.FakeOuterCompositeSerialize: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -175,6 +287,7 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **outerComposite** | [**OuterComposite**](OuterComposite.md)| Input composite as post body | [optional] @@ -189,22 +302,32 @@ No authorization required ### HTTP request headers - - **Content-Type**: application/json - - **Accept**: */* +- **Content-Type**: application/json +- **Accept**: */* + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | Output composite | - | -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) - -# **FakeOuterNumberSerialize** -> decimal? FakeOuterNumberSerialize (decimal? body = null) + +## FakeOuterNumberSerialize + +> decimal FakeOuterNumberSerialize (decimal? body = null) Test serialization of outer number types ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -214,19 +337,22 @@ namespace Example { public class FakeOuterNumberSerializeExample { - public void main() + public static void Main() { - var apiInstance = new FakeApi(); + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new FakeApi(Configuration.Default); var body = 8.14; // decimal? | Input number as post body (optional) try { - decimal? result = apiInstance.FakeOuterNumberSerialize(body); + decimal result = apiInstance.FakeOuterNumberSerialize(body); Debug.WriteLine(result); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling FakeApi.FakeOuterNumberSerialize: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -235,13 +361,14 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **body** | **decimal?**| Input number as post body | [optional] ### Return type -**decimal?** +**decimal** ### Authorization @@ -249,13 +376,22 @@ No authorization required ### HTTP request headers - - **Content-Type**: application/json - - **Accept**: */* +- **Content-Type**: application/json +- **Accept**: */* + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | Output number | - | -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) + + +## FakeOuterStringSerialize - -# **FakeOuterStringSerialize** > string FakeOuterStringSerialize (string body = null) @@ -263,8 +399,9 @@ No authorization required Test serialization of outer string types ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -274,9 +411,10 @@ namespace Example { public class FakeOuterStringSerializeExample { - public void main() + public static void Main() { - var apiInstance = new FakeApi(); + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new FakeApi(Configuration.Default); var body = body_example; // string | Input string as post body (optional) try @@ -284,9 +422,11 @@ namespace Example string result = apiInstance.FakeOuterStringSerialize(body); Debug.WriteLine(result); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling FakeApi.FakeOuterStringSerialize: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -295,6 +435,7 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **body** | **string**| Input string as post body | [optional] @@ -309,13 +450,22 @@ No authorization required ### HTTP request headers - - **Content-Type**: application/json - - **Accept**: */* +- **Content-Type**: application/json +- **Accept**: */* + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | Output string | - | -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) + + +## TestBodyWithFileSchema - -# **TestBodyWithFileSchema** > void TestBodyWithFileSchema (FileSchemaTestClass fileSchemaTestClass) @@ -323,8 +473,9 @@ No authorization required For this test, the body for this request much reference a schema named `File`. ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -334,18 +485,21 @@ namespace Example { public class TestBodyWithFileSchemaExample { - public void main() + public static void Main() { - var apiInstance = new FakeApi(); + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new FakeApi(Configuration.Default); var fileSchemaTestClass = new FileSchemaTestClass(); // FileSchemaTestClass | try { apiInstance.TestBodyWithFileSchema(fileSchemaTestClass); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling FakeApi.TestBodyWithFileSchema: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -354,6 +508,7 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **fileSchemaTestClass** | [**FileSchemaTestClass**](FileSchemaTestClass.md)| | @@ -368,20 +523,30 @@ No authorization required ### HTTP request headers - - **Content-Type**: application/json - - **Accept**: Not defined +- **Content-Type**: application/json +- **Accept**: Not defined + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | Success | - | -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) + + +## TestBodyWithQueryParams - -# **TestBodyWithQueryParams** > void TestBodyWithQueryParams (string query, User user) ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -391,9 +556,10 @@ namespace Example { public class TestBodyWithQueryParamsExample { - public void main() + public static void Main() { - var apiInstance = new FakeApi(); + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new FakeApi(Configuration.Default); var query = query_example; // string | var user = new User(); // User | @@ -401,9 +567,11 @@ namespace Example { apiInstance.TestBodyWithQueryParams(query, user); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling FakeApi.TestBodyWithQueryParams: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -412,6 +580,7 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **query** | **string**| | @@ -427,13 +596,22 @@ No authorization required ### HTTP request headers - - **Content-Type**: application/json - - **Accept**: Not defined +- **Content-Type**: application/json +- **Accept**: Not defined + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | Success | - | -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) + + +## TestClientModel - -# **TestClientModel** > ModelClient TestClientModel (ModelClient modelClient) To test \"client\" model @@ -441,8 +619,9 @@ To test \"client\" model To test \"client\" model ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -452,9 +631,10 @@ namespace Example { public class TestClientModelExample { - public void main() + public static void Main() { - var apiInstance = new FakeApi(); + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new FakeApi(Configuration.Default); var modelClient = new ModelClient(); // ModelClient | client model try @@ -463,9 +643,11 @@ namespace Example ModelClient result = apiInstance.TestClientModel(modelClient); Debug.WriteLine(result); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling FakeApi.TestClientModel: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -474,6 +656,7 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **modelClient** | [**ModelClient**](ModelClient.md)| client model | @@ -488,22 +671,32 @@ No authorization required ### HTTP request headers - - **Content-Type**: application/json - - **Accept**: application/json +- **Content-Type**: application/json +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | - | + +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **TestEndpointParameters** -> void TestEndpointParameters (decimal? number, double? _double, string patternWithoutDelimiter, byte[] _byte, int? integer = null, int? int32 = null, long? int64 = null, float? _float = null, string _string = null, System.IO.Stream binary = null, DateTime? date = null, DateTime? dateTime = null, string password = null, string callback = null) +## TestEndpointParameters + +> void TestEndpointParameters (decimal number, double _double, string patternWithoutDelimiter, byte[] _byte, int? integer = null, int? int32 = null, long? int64 = null, float? _float = null, string _string = null, System.IO.Stream binary = null, DateTime? date = null, DateTime? dateTime = null, string password = null, string callback = null) Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -513,15 +706,16 @@ namespace Example { public class TestEndpointParametersExample { - public void main() + public static void Main() { + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; // Configure HTTP basic authorization: http_basic_test Configuration.Default.Username = "YOUR_USERNAME"; Configuration.Default.Password = "YOUR_PASSWORD"; - var apiInstance = new FakeApi(); - var number = 8.14; // decimal? | None - var _double = 1.2D; // double? | None + var apiInstance = new FakeApi(Configuration.Default); + var number = 8.14; // decimal | None + var _double = 1.2D; // double | None var patternWithoutDelimiter = patternWithoutDelimiter_example; // string | None var _byte = BYTE_ARRAY_DATA_HERE; // byte[] | None var integer = 56; // int? | None (optional) @@ -540,9 +734,11 @@ namespace Example // Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 apiInstance.TestEndpointParameters(number, _double, patternWithoutDelimiter, _byte, integer, int32, int64, _float, _string, binary, date, dateTime, password, callback); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling FakeApi.TestEndpointParameters: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -551,10 +747,11 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **number** | **decimal?**| None | - **_double** | **double?**| None | + **number** | **decimal**| None | + **_double** | **double**| None | **patternWithoutDelimiter** | **string**| None | **_byte** | **byte[]**| None | **integer** | **int?**| None | [optional] @@ -578,13 +775,23 @@ void (empty response body) ### HTTP request headers - - **Content-Type**: application/x-www-form-urlencoded - - **Accept**: Not defined +- **Content-Type**: application/x-www-form-urlencoded +- **Accept**: Not defined + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **400** | Invalid username supplied | - | +| **404** | User not found | - | + +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **TestEnumParameters** +## TestEnumParameters + > void TestEnumParameters (List enumHeaderStringArray = null, string enumHeaderString = null, List enumQueryStringArray = null, string enumQueryString = null, int? enumQueryInteger = null, double? enumQueryDouble = null, List enumFormStringArray = null, string enumFormString = null) To test enum parameters @@ -592,8 +799,9 @@ To test enum parameters To test enum parameters ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -603,9 +811,10 @@ namespace Example { public class TestEnumParametersExample { - public void main() + public static void Main() { - var apiInstance = new FakeApi(); + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new FakeApi(Configuration.Default); var enumHeaderStringArray = enumHeaderStringArray_example; // List | Header parameter enum test (string array) (optional) var enumHeaderString = enumHeaderString_example; // string | Header parameter enum test (string) (optional) (default to -efg) var enumQueryStringArray = enumQueryStringArray_example; // List | Query parameter enum test (string array) (optional) @@ -620,9 +829,11 @@ namespace Example // To test enum parameters apiInstance.TestEnumParameters(enumHeaderStringArray, enumHeaderString, enumQueryStringArray, enumQueryString, enumQueryInteger, enumQueryDouble, enumFormStringArray, enumFormString); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling FakeApi.TestEnumParameters: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -631,6 +842,7 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **enumHeaderStringArray** | **List<string>**| Header parameter enum test (string array) | [optional] @@ -652,22 +864,33 @@ No authorization required ### HTTP request headers - - **Content-Type**: application/x-www-form-urlencoded - - **Accept**: Not defined +- **Content-Type**: application/x-www-form-urlencoded +- **Accept**: Not defined + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **400** | Invalid request | - | +| **404** | Not found | - | + +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **TestGroupParameters** -> void TestGroupParameters (int? requiredStringGroup, bool? requiredBooleanGroup, long? requiredInt64Group, int? stringGroup = null, bool? booleanGroup = null, long? int64Group = null) +## TestGroupParameters + +> void TestGroupParameters (int requiredStringGroup, bool requiredBooleanGroup, long requiredInt64Group, int? stringGroup = null, bool? booleanGroup = null, long? int64Group = null) Fake endpoint to test group parameters (optional) Fake endpoint to test group parameters (optional) ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -677,16 +900,16 @@ namespace Example { public class TestGroupParametersExample { - public void main() + public static void Main() { - // Configure HTTP basic authorization: bearer_test - Configuration.Default.Username = "YOUR_USERNAME"; - Configuration.Default.Password = "YOUR_PASSWORD"; - - var apiInstance = new FakeApi(); - var requiredStringGroup = 56; // int? | Required String in group parameters - var requiredBooleanGroup = true; // bool? | Required Boolean in group parameters - var requiredInt64Group = 789; // long? | Required Integer in group parameters + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + // Configure HTTP bearer authorization: bearer_test + Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN"; + + var apiInstance = new FakeApi(Configuration.Default); + var requiredStringGroup = 56; // int | Required String in group parameters + var requiredBooleanGroup = true; // bool | Required Boolean in group parameters + var requiredInt64Group = 789; // long | Required Integer in group parameters var stringGroup = 56; // int? | String in group parameters (optional) var booleanGroup = true; // bool? | Boolean in group parameters (optional) var int64Group = 789; // long? | Integer in group parameters (optional) @@ -696,9 +919,11 @@ namespace Example // Fake endpoint to test group parameters (optional) apiInstance.TestGroupParameters(requiredStringGroup, requiredBooleanGroup, requiredInt64Group, stringGroup, booleanGroup, int64Group); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling FakeApi.TestGroupParameters: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -707,11 +932,12 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **requiredStringGroup** | **int?**| Required String in group parameters | - **requiredBooleanGroup** | **bool?**| Required Boolean in group parameters | - **requiredInt64Group** | **long?**| Required Integer in group parameters | + **requiredStringGroup** | **int**| Required String in group parameters | + **requiredBooleanGroup** | **bool**| Required Boolean in group parameters | + **requiredInt64Group** | **long**| Required Integer in group parameters | **stringGroup** | **int?**| String in group parameters | [optional] **booleanGroup** | **bool?**| Boolean in group parameters | [optional] **int64Group** | **long?**| Integer in group parameters | [optional] @@ -726,20 +952,30 @@ void (empty response body) ### HTTP request headers - - **Content-Type**: Not defined - - **Accept**: Not defined +- **Content-Type**: Not defined +- **Accept**: Not defined + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **400** | Someting wrong | - | + +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **TestInlineAdditionalProperties** +## TestInlineAdditionalProperties + > void TestInlineAdditionalProperties (Dictionary requestBody) test inline additionalProperties ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -749,9 +985,10 @@ namespace Example { public class TestInlineAdditionalPropertiesExample { - public void main() + public static void Main() { - var apiInstance = new FakeApi(); + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new FakeApi(Configuration.Default); var requestBody = new Dictionary(); // Dictionary | request body try @@ -759,9 +996,11 @@ namespace Example // test inline additionalProperties apiInstance.TestInlineAdditionalProperties(requestBody); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling FakeApi.TestInlineAdditionalProperties: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -770,6 +1009,7 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **requestBody** | [**Dictionary<string, string>**](string.md)| request body | @@ -784,20 +1024,30 @@ No authorization required ### HTTP request headers - - **Content-Type**: application/json - - **Accept**: Not defined +- **Content-Type**: application/json +- **Accept**: Not defined + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | - | + +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **TestJsonFormData** +## TestJsonFormData + > void TestJsonFormData (string param, string param2) test json serialization of form data ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -807,9 +1057,10 @@ namespace Example { public class TestJsonFormDataExample { - public void main() + public static void Main() { - var apiInstance = new FakeApi(); + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new FakeApi(Configuration.Default); var param = param_example; // string | field1 var param2 = param2_example; // string | field2 @@ -818,9 +1069,11 @@ namespace Example // test json serialization of form data apiInstance.TestJsonFormData(param, param2); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling FakeApi.TestJsonFormData: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -829,6 +1082,7 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **param** | **string**| field1 | @@ -844,8 +1098,97 @@ No authorization required ### HTTP request headers - - **Content-Type**: application/x-www-form-urlencoded - - **Accept**: Not defined +- **Content-Type**: application/x-www-form-urlencoded +- **Accept**: Not defined + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | - | + +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) + + +## TestQueryParameterCollectionFormat + +> void TestQueryParameterCollectionFormat (List pipe, List ioutil, List http, List url, List context) + + + +To test the collection format in query parameters + +### Example + +```csharp +using System.Collections.Generic; +using System.Diagnostics; +using Org.OpenAPITools.Api; +using Org.OpenAPITools.Client; +using Org.OpenAPITools.Model; + +namespace Example +{ + public class TestQueryParameterCollectionFormatExample + { + public static void Main() + { + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new FakeApi(Configuration.Default); + var pipe = new List(); // List | + var ioutil = new List(); // List | + var http = new List(); // List | + var url = new List(); // List | + var context = new List(); // List | + + try + { + apiInstance.TestQueryParameterCollectionFormat(pipe, ioutil, http, url, context); + } + catch (ApiException e) + { + Debug.Print("Exception when calling FakeApi.TestQueryParameterCollectionFormat: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); + } + } + } +} +``` + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pipe** | [**List<string>**](string.md)| | + **ioutil** | [**List<string>**](string.md)| | + **http** | [**List<string>**](string.md)| | + **url** | [**List<string>**](string.md)| | + **context** | [**List<string>**](string.md)| | + +### Return type + +void (empty response body) + +### Authorization + +No authorization required + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: Not defined + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | Success | - | -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/FakeClassnameTags123Api.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/FakeClassnameTags123Api.md index f069b0983997..93eb8b274552 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/FakeClassnameTags123Api.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/FakeClassnameTags123Api.md @@ -7,8 +7,9 @@ Method | HTTP request | Description [**TestClassname**](FakeClassnameTags123Api.md#testclassname) | **PATCH** /fake_classname_test | To test class name in snake case - -# **TestClassname** + +## TestClassname + > ModelClient TestClassname (ModelClient modelClient) To test class name in snake case @@ -16,8 +17,9 @@ To test class name in snake case To test class name in snake case ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -27,14 +29,15 @@ namespace Example { public class TestClassnameExample { - public void main() + public static void Main() { + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; // Configure API key authorization: api_key_query Configuration.Default.AddApiKey("api_key_query", "YOUR_API_KEY"); // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed // Configuration.Default.AddApiKeyPrefix("api_key_query", "Bearer"); - var apiInstance = new FakeClassnameTags123Api(); + var apiInstance = new FakeClassnameTags123Api(Configuration.Default); var modelClient = new ModelClient(); // ModelClient | client model try @@ -43,9 +46,11 @@ namespace Example ModelClient result = apiInstance.TestClassname(modelClient); Debug.WriteLine(result); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling FakeClassnameTags123Api.TestClassname: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -54,6 +59,7 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **modelClient** | [**ModelClient**](ModelClient.md)| client model | @@ -68,8 +74,16 @@ Name | Type | Description | Notes ### HTTP request headers - - **Content-Type**: application/json - - **Accept**: application/json +- **Content-Type**: application/json +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | - | -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/File.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/File.md index acf85a4c001a..b71051025797 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/File.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/File.md @@ -1,9 +1,13 @@ + # Org.OpenAPITools.Model.File + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **SourceURI** | **string** | Test capitalization | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/FileSchemaTestClass.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/FileSchemaTestClass.md index 244164accbe6..df1453f686bd 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/FileSchemaTestClass.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/FileSchemaTestClass.md @@ -1,4 +1,6 @@ + # Org.OpenAPITools.Model.FileSchemaTestClass + ## Properties Name | Type | Description | Notes @@ -6,5 +8,7 @@ Name | Type | Description | Notes **File** | [**File**](File.md) | | [optional] **Files** | [**List<File>**](File.md) | | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Foo.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Foo.md index fd84dc2038c9..ea6f4245da6e 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Foo.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Foo.md @@ -1,9 +1,13 @@ + # Org.OpenAPITools.Model.Foo + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **Bar** | **string** | | [optional] [default to "bar"] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/FormatTest.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/FormatTest.md index bba9daef559d..6cef48d5b4db 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/FormatTest.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/FormatTest.md @@ -1,23 +1,27 @@ + # Org.OpenAPITools.Model.FormatTest + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Integer** | **int?** | | [optional] -**Int32** | **int?** | | [optional] -**Int64** | **long?** | | [optional] -**Number** | **decimal?** | | -**Float** | **float?** | | [optional] -**Double** | **double?** | | [optional] +**Integer** | **int** | | [optional] +**Int32** | **int** | | [optional] +**Int64** | **long** | | [optional] +**Number** | **decimal** | | +**Float** | **float** | | [optional] +**Double** | **double** | | [optional] **String** | **string** | | [optional] **Byte** | **byte[]** | | **Binary** | **System.IO.Stream** | | [optional] -**Date** | **DateTime?** | | -**DateTime** | **DateTime?** | | [optional] -**Uuid** | **Guid?** | | [optional] +**Date** | **DateTime** | | +**DateTime** | **DateTime** | | [optional] +**Uuid** | **Guid** | | [optional] **Password** | **string** | | **PatternWithDigits** | **string** | A string that is a 10 digit number. Can have leading zeros. | [optional] **PatternWithDigitsAndDelimiter** | **string** | A string starting with 'image_' (case insensitive) and one to three digits following i.e. Image_01. | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/HasOnlyReadOnly.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/HasOnlyReadOnly.md index 95f49de194c1..043d2442b4ea 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/HasOnlyReadOnly.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/HasOnlyReadOnly.md @@ -1,10 +1,14 @@ + # Org.OpenAPITools.Model.HasOnlyReadOnly + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Bar** | **string** | | [optional] -**Foo** | **string** | | [optional] +**Bar** | **string** | | [optional] [readonly] +**Foo** | **string** | | [optional] [readonly] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/HealthCheckResult.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/HealthCheckResult.md index c8f299aaa258..08e5992d20cb 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/HealthCheckResult.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/HealthCheckResult.md @@ -1,9 +1,13 @@ + # Org.OpenAPITools.Model.HealthCheckResult + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **NullableMessage** | **string** | | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/InlineObject.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/InlineObject.md index 40e16da1bb7d..12ec90a8c699 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/InlineObject.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/InlineObject.md @@ -1,4 +1,6 @@ + # Org.OpenAPITools.Model.InlineObject + ## Properties Name | Type | Description | Notes @@ -6,5 +8,7 @@ Name | Type | Description | Notes **Name** | **string** | Updated name of the pet | [optional] **Status** | **string** | Updated status of the pet | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/InlineObject1.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/InlineObject1.md index 2e6d226754e4..581fe20b1e21 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/InlineObject1.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/InlineObject1.md @@ -1,4 +1,6 @@ + # Org.OpenAPITools.Model.InlineObject1 + ## Properties Name | Type | Description | Notes @@ -6,5 +8,7 @@ Name | Type | Description | Notes **AdditionalMetadata** | **string** | Additional data to pass to server | [optional] **File** | **System.IO.Stream** | file to upload | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/InlineObject2.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/InlineObject2.md index c02c78f9b2d0..79abb7a467c4 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/InlineObject2.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/InlineObject2.md @@ -1,4 +1,6 @@ + # Org.OpenAPITools.Model.InlineObject2 + ## Properties Name | Type | Description | Notes @@ -6,5 +8,7 @@ Name | Type | Description | Notes **EnumFormStringArray** | **List<string>** | Form parameter enum test (string array) | [optional] **EnumFormString** | **string** | Form parameter enum test (string) | [optional] [default to EnumFormStringEnum.Efg] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/InlineObject3.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/InlineObject3.md index 192926bbe927..684db7f7227b 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/InlineObject3.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/InlineObject3.md @@ -1,22 +1,26 @@ + # Org.OpenAPITools.Model.InlineObject3 + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Integer** | **int?** | None | [optional] -**Int32** | **int?** | None | [optional] -**Int64** | **long?** | None | [optional] -**Number** | **decimal?** | None | -**Float** | **float?** | None | [optional] -**Double** | **double?** | None | +**Integer** | **int** | None | [optional] +**Int32** | **int** | None | [optional] +**Int64** | **long** | None | [optional] +**Number** | **decimal** | None | +**Float** | **float** | None | [optional] +**Double** | **double** | None | **String** | **string** | None | [optional] **PatternWithoutDelimiter** | **string** | None | **Byte** | **byte[]** | None | **Binary** | **System.IO.Stream** | None | [optional] -**Date** | **DateTime?** | None | [optional] -**DateTime** | **DateTime?** | None | [optional] +**Date** | **DateTime** | None | [optional] +**DateTime** | **DateTime** | None | [optional] **Password** | **string** | None | [optional] **Callback** | **string** | None | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/InlineObject4.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/InlineObject4.md index c8e00663ee88..18e4a1f3ce50 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/InlineObject4.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/InlineObject4.md @@ -1,4 +1,6 @@ + # Org.OpenAPITools.Model.InlineObject4 + ## Properties Name | Type | Description | Notes @@ -6,5 +8,7 @@ Name | Type | Description | Notes **Param** | **string** | field1 | **Param2** | **string** | field2 | -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/InlineObject5.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/InlineObject5.md index a28ff47f2ec0..291c88623eea 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/InlineObject5.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/InlineObject5.md @@ -1,4 +1,6 @@ + # Org.OpenAPITools.Model.InlineObject5 + ## Properties Name | Type | Description | Notes @@ -6,5 +8,7 @@ Name | Type | Description | Notes **AdditionalMetadata** | **string** | Additional data to pass to server | [optional] **RequiredFile** | **System.IO.Stream** | file to upload | -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/InlineResponseDefault.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/InlineResponseDefault.md index 8c96fb62ac88..ecfb254001a2 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/InlineResponseDefault.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/InlineResponseDefault.md @@ -1,9 +1,13 @@ + # Org.OpenAPITools.Model.InlineResponseDefault + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **String** | [**Foo**](Foo.md) | | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/List.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/List.md index 484c2a0992c6..cb41193b43eb 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/List.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/List.md @@ -1,9 +1,13 @@ + # Org.OpenAPITools.Model.List + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **_123List** | **string** | | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/MapTest.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/MapTest.md index 2c44f95808ae..79d499e2cf9a 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/MapTest.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/MapTest.md @@ -1,12 +1,16 @@ + # Org.OpenAPITools.Model.MapTest + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **MapMapOfString** | **Dictionary<string, Dictionary<string, string>>** | | [optional] **MapOfEnumString** | **Dictionary<string, string>** | | [optional] -**DirectMap** | **Dictionary<string, bool?>** | | [optional] -**IndirectMap** | **Dictionary<string, bool?>** | | [optional] +**DirectMap** | **Dictionary<string, bool>** | | [optional] +**IndirectMap** | **Dictionary<string, bool>** | | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/MixedPropertiesAndAdditionalPropertiesClass.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/MixedPropertiesAndAdditionalPropertiesClass.md index 9b8e2e3434c1..dd7b01e49fe9 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/MixedPropertiesAndAdditionalPropertiesClass.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/MixedPropertiesAndAdditionalPropertiesClass.md @@ -1,11 +1,15 @@ + # Org.OpenAPITools.Model.MixedPropertiesAndAdditionalPropertiesClass + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Uuid** | **Guid?** | | [optional] -**DateTime** | **DateTime?** | | [optional] +**Uuid** | **Guid** | | [optional] +**DateTime** | **DateTime** | | [optional] **Map** | [**Dictionary<string, Animal>**](Animal.md) | | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Model200Response.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Model200Response.md index 16337f9b6b2d..7d826bca1ec2 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Model200Response.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Model200Response.md @@ -1,10 +1,14 @@ + # Org.OpenAPITools.Model.Model200Response + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Name** | **int?** | | [optional] +**Name** | **int** | | [optional] **Class** | **string** | | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/ModelClient.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/ModelClient.md index ecc7b60ce558..e36e1fad802f 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/ModelClient.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/ModelClient.md @@ -1,9 +1,13 @@ + # Org.OpenAPITools.Model.ModelClient + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **__Client** | **string** | | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Name.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Name.md index e22fef95673d..bfd7955e5b4c 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Name.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Name.md @@ -1,12 +1,16 @@ + # Org.OpenAPITools.Model.Name + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**_Name** | **int?** | | -**SnakeCase** | **int?** | | [optional] +**_Name** | **int** | | +**SnakeCase** | **int** | | [optional] [readonly] **Property** | **string** | | [optional] -**_123Number** | **int?** | | [optional] +**_123Number** | **int** | | [optional] [readonly] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/NullableClass.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/NullableClass.md index 0ca2455a4ab2..84dd092d8a38 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/NullableClass.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/NullableClass.md @@ -1,4 +1,6 @@ + # Org.OpenAPITools.Model.NullableClass + ## Properties Name | Type | Description | Notes @@ -16,5 +18,7 @@ Name | Type | Description | Notes **ObjectAndItemsNullableProp** | **Dictionary<string, Object>** | | [optional] **ObjectItemsNullable** | **Dictionary<string, Object>** | | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/NumberOnly.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/NumberOnly.md index 5f00dedf1c39..e4b08467e087 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/NumberOnly.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/NumberOnly.md @@ -1,9 +1,13 @@ + # Org.OpenAPITools.Model.NumberOnly + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**JustNumber** | **decimal?** | | [optional] +**JustNumber** | **decimal** | | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Order.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Order.md index 984bd5ca063e..875f43a30e5c 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Order.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Order.md @@ -1,14 +1,18 @@ + # Org.OpenAPITools.Model.Order + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Id** | **long?** | | [optional] -**PetId** | **long?** | | [optional] -**Quantity** | **int?** | | [optional] -**ShipDate** | **DateTime?** | | [optional] +**Id** | **long** | | [optional] +**PetId** | **long** | | [optional] +**Quantity** | **int** | | [optional] +**ShipDate** | **DateTime** | | [optional] **Status** | **string** | Order Status | [optional] -**Complete** | **bool?** | | [optional] [default to false] +**Complete** | **bool** | | [optional] [default to false] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/OuterComposite.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/OuterComposite.md index 4091cd23f2e1..f381fb7fd283 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/OuterComposite.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/OuterComposite.md @@ -1,11 +1,15 @@ + # Org.OpenAPITools.Model.OuterComposite + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**MyNumber** | **decimal?** | | [optional] +**MyNumber** | **decimal** | | [optional] **MyString** | **string** | | [optional] -**MyBoolean** | **bool?** | | [optional] +**MyBoolean** | **bool** | | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/OuterEnum.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/OuterEnum.md index 22713352ca08..edc2300684d9 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/OuterEnum.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/OuterEnum.md @@ -1,8 +1,12 @@ + # Org.OpenAPITools.Model.OuterEnum + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/OuterEnumDefaultValue.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/OuterEnumDefaultValue.md index 09f6b91ee623..41474099f2ee 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/OuterEnumDefaultValue.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/OuterEnumDefaultValue.md @@ -1,8 +1,12 @@ + # Org.OpenAPITools.Model.OuterEnumDefaultValue + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/OuterEnumInteger.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/OuterEnumInteger.md index 149bb5a8dd16..b82abc3adac4 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/OuterEnumInteger.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/OuterEnumInteger.md @@ -1,8 +1,12 @@ + # Org.OpenAPITools.Model.OuterEnumInteger + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/OuterEnumIntegerDefaultValue.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/OuterEnumIntegerDefaultValue.md index 29de71509745..46939d01522e 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/OuterEnumIntegerDefaultValue.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/OuterEnumIntegerDefaultValue.md @@ -1,8 +1,12 @@ + # Org.OpenAPITools.Model.OuterEnumIntegerDefaultValue + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Pet.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Pet.md index 0ac711337aa8..0bd5c40fc993 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Pet.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Pet.md @@ -1,14 +1,18 @@ + # Org.OpenAPITools.Model.Pet + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Id** | **long?** | | [optional] +**Id** | **long** | | [optional] **Category** | [**Category**](Category.md) | | [optional] **Name** | **string** | | **PhotoUrls** | **List<string>** | | **Tags** | [**List<Tag>**](Tag.md) | | [optional] **Status** | **string** | pet status in the store | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/PetApi.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/PetApi.md index dd23df9b3683..5d9c6cb6f791 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/PetApi.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/PetApi.md @@ -15,15 +15,17 @@ Method | HTTP request | Description [**UploadFileWithRequiredFile**](PetApi.md#uploadfilewithrequiredfile) | **POST** /fake/{petId}/uploadImageWithRequiredFile | uploads an image (required) - -# **AddPet** + +## AddPet + > void AddPet (Pet pet) Add a new pet to the store ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -33,12 +35,13 @@ namespace Example { public class AddPetExample { - public void main() + public static void Main() { + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; // Configure OAuth2 access token for authorization: petstore_auth Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN"; - var apiInstance = new PetApi(); + var apiInstance = new PetApi(Configuration.Default); var pet = new Pet(); // Pet | Pet object that needs to be added to the store try @@ -46,9 +49,11 @@ namespace Example // Add a new pet to the store apiInstance.AddPet(pet); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling PetApi.AddPet: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -57,6 +62,7 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **pet** | [**Pet**](Pet.md)| Pet object that needs to be added to the store | @@ -71,20 +77,30 @@ void (empty response body) ### HTTP request headers - - **Content-Type**: application/json, application/xml - - **Accept**: Not defined +- **Content-Type**: application/json, application/xml +- **Accept**: Not defined + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **405** | Invalid input | - | + +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **DeletePet** -> void DeletePet (long? petId, string apiKey = null) +## DeletePet + +> void DeletePet (long petId, string apiKey = null) Deletes a pet ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -94,13 +110,14 @@ namespace Example { public class DeletePetExample { - public void main() + public static void Main() { + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; // Configure OAuth2 access token for authorization: petstore_auth Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN"; - var apiInstance = new PetApi(); - var petId = 789; // long? | Pet id to delete + var apiInstance = new PetApi(Configuration.Default); + var petId = 789; // long | Pet id to delete var apiKey = apiKey_example; // string | (optional) try @@ -108,9 +125,11 @@ namespace Example // Deletes a pet apiInstance.DeletePet(petId, apiKey); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling PetApi.DeletePet: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -119,9 +138,10 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **petId** | **long?**| Pet id to delete | + **petId** | **long**| Pet id to delete | **apiKey** | **string**| | [optional] ### Return type @@ -134,22 +154,32 @@ void (empty response body) ### HTTP request headers - - **Content-Type**: Not defined - - **Accept**: Not defined +- **Content-Type**: Not defined +- **Accept**: Not defined + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **400** | Invalid pet value | - | + +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) + -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +## FindPetsByStatus - -# **FindPetsByStatus** -> List FindPetsByStatus (List status) +> List<Pet> FindPetsByStatus (List status) Finds Pets by status Multiple status values can be provided with comma separated strings ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -159,23 +189,26 @@ namespace Example { public class FindPetsByStatusExample { - public void main() + public static void Main() { + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; // Configure OAuth2 access token for authorization: petstore_auth Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN"; - var apiInstance = new PetApi(); + var apiInstance = new PetApi(Configuration.Default); var status = status_example; // List | Status values that need to be considered for filter try { // Finds Pets by status - List<Pet> result = apiInstance.FindPetsByStatus(status); + List result = apiInstance.FindPetsByStatus(status); Debug.WriteLine(result); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling PetApi.FindPetsByStatus: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -184,13 +217,14 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **status** | **List<string>**| Status values that need to be considered for filter | ### Return type -[**List**](Pet.md) +[**List<Pet>**](Pet.md) ### Authorization @@ -198,22 +232,33 @@ Name | Type | Description | Notes ### HTTP request headers - - **Content-Type**: Not defined - - **Accept**: application/xml, application/json +- **Content-Type**: Not defined +- **Accept**: application/xml, application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | - | +| **400** | Invalid status value | - | -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) - -# **FindPetsByTags** -> List FindPetsByTags (List tags) + +## FindPetsByTags + +> List<Pet> FindPetsByTags (List tags) Finds Pets by tags Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -223,23 +268,26 @@ namespace Example { public class FindPetsByTagsExample { - public void main() + public static void Main() { + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; // Configure OAuth2 access token for authorization: petstore_auth Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN"; - var apiInstance = new PetApi(); + var apiInstance = new PetApi(Configuration.Default); var tags = new List(); // List | Tags to filter by try { // Finds Pets by tags - List<Pet> result = apiInstance.FindPetsByTags(tags); + List result = apiInstance.FindPetsByTags(tags); Debug.WriteLine(result); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling PetApi.FindPetsByTags: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -248,13 +296,14 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **tags** | [**List<string>**](string.md)| Tags to filter by | ### Return type -[**List**](Pet.md) +[**List<Pet>**](Pet.md) ### Authorization @@ -262,22 +311,33 @@ Name | Type | Description | Notes ### HTTP request headers - - **Content-Type**: Not defined - - **Accept**: application/xml, application/json +- **Content-Type**: Not defined +- **Accept**: application/xml, application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | - | +| **400** | Invalid tag value | - | + +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **GetPetById** -> Pet GetPetById (long? petId) +## GetPetById + +> Pet GetPetById (long petId) Find pet by ID Returns a single pet ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -287,15 +347,16 @@ namespace Example { public class GetPetByIdExample { - public void main() + public static void Main() { + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; // Configure API key authorization: api_key Configuration.Default.AddApiKey("api_key", "YOUR_API_KEY"); // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed // Configuration.Default.AddApiKeyPrefix("api_key", "Bearer"); - var apiInstance = new PetApi(); - var petId = 789; // long? | ID of pet to return + var apiInstance = new PetApi(Configuration.Default); + var petId = 789; // long | ID of pet to return try { @@ -303,9 +364,11 @@ namespace Example Pet result = apiInstance.GetPetById(petId); Debug.WriteLine(result); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling PetApi.GetPetById: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -314,9 +377,10 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **petId** | **long?**| ID of pet to return | + **petId** | **long**| ID of pet to return | ### Return type @@ -328,20 +392,32 @@ Name | Type | Description | Notes ### HTTP request headers - - **Content-Type**: Not defined - - **Accept**: application/xml, application/json +- **Content-Type**: Not defined +- **Accept**: application/xml, application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | - | +| **400** | Invalid ID supplied | - | +| **404** | Pet not found | - | + +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **UpdatePet** +## UpdatePet + > void UpdatePet (Pet pet) Update an existing pet ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -351,12 +427,13 @@ namespace Example { public class UpdatePetExample { - public void main() + public static void Main() { + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; // Configure OAuth2 access token for authorization: petstore_auth Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN"; - var apiInstance = new PetApi(); + var apiInstance = new PetApi(Configuration.Default); var pet = new Pet(); // Pet | Pet object that needs to be added to the store try @@ -364,9 +441,11 @@ namespace Example // Update an existing pet apiInstance.UpdatePet(pet); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling PetApi.UpdatePet: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -375,6 +454,7 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **pet** | [**Pet**](Pet.md)| Pet object that needs to be added to the store | @@ -389,20 +469,32 @@ void (empty response body) ### HTTP request headers - - **Content-Type**: application/json, application/xml - - **Accept**: Not defined +- **Content-Type**: application/json, application/xml +- **Accept**: Not defined -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **400** | Invalid ID supplied | - | +| **404** | Pet not found | - | +| **405** | Validation exception | - | - -# **UpdatePetWithForm** -> void UpdatePetWithForm (long? petId, string name = null, string status = null) +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) + + +## UpdatePetWithForm + +> void UpdatePetWithForm (long petId, string name = null, string status = null) Updates a pet in the store with form data ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -412,13 +504,14 @@ namespace Example { public class UpdatePetWithFormExample { - public void main() + public static void Main() { + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; // Configure OAuth2 access token for authorization: petstore_auth Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN"; - var apiInstance = new PetApi(); - var petId = 789; // long? | ID of pet that needs to be updated + var apiInstance = new PetApi(Configuration.Default); + var petId = 789; // long | ID of pet that needs to be updated var name = name_example; // string | Updated name of the pet (optional) var status = status_example; // string | Updated status of the pet (optional) @@ -427,9 +520,11 @@ namespace Example // Updates a pet in the store with form data apiInstance.UpdatePetWithForm(petId, name, status); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling PetApi.UpdatePetWithForm: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -438,9 +533,10 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **petId** | **long?**| ID of pet that needs to be updated | + **petId** | **long**| ID of pet that needs to be updated | **name** | **string**| Updated name of the pet | [optional] **status** | **string**| Updated status of the pet | [optional] @@ -454,20 +550,30 @@ void (empty response body) ### HTTP request headers - - **Content-Type**: application/x-www-form-urlencoded - - **Accept**: Not defined +- **Content-Type**: application/x-www-form-urlencoded +- **Accept**: Not defined -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **405** | Invalid input | - | - -# **UploadFile** -> ApiResponse UploadFile (long? petId, string additionalMetadata = null, System.IO.Stream file = null) +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) + + +## UploadFile + +> ApiResponse UploadFile (long petId, string additionalMetadata = null, System.IO.Stream file = null) uploads an image ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -477,13 +583,14 @@ namespace Example { public class UploadFileExample { - public void main() + public static void Main() { + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; // Configure OAuth2 access token for authorization: petstore_auth Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN"; - var apiInstance = new PetApi(); - var petId = 789; // long? | ID of pet to update + var apiInstance = new PetApi(Configuration.Default); + var petId = 789; // long | ID of pet to update var additionalMetadata = additionalMetadata_example; // string | Additional data to pass to server (optional) var file = BINARY_DATA_HERE; // System.IO.Stream | file to upload (optional) @@ -493,9 +600,11 @@ namespace Example ApiResponse result = apiInstance.UploadFile(petId, additionalMetadata, file); Debug.WriteLine(result); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling PetApi.UploadFile: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -504,9 +613,10 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **petId** | **long?**| ID of pet to update | + **petId** | **long**| ID of pet to update | **additionalMetadata** | **string**| Additional data to pass to server | [optional] **file** | **System.IO.Stream**| file to upload | [optional] @@ -520,20 +630,30 @@ Name | Type | Description | Notes ### HTTP request headers - - **Content-Type**: multipart/form-data - - **Accept**: application/json +- **Content-Type**: multipart/form-data +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | - | -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) - -# **UploadFileWithRequiredFile** -> ApiResponse UploadFileWithRequiredFile (long? petId, System.IO.Stream requiredFile, string additionalMetadata = null) + +## UploadFileWithRequiredFile + +> ApiResponse UploadFileWithRequiredFile (long petId, System.IO.Stream requiredFile, string additionalMetadata = null) uploads an image (required) ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -543,13 +663,14 @@ namespace Example { public class UploadFileWithRequiredFileExample { - public void main() + public static void Main() { + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; // Configure OAuth2 access token for authorization: petstore_auth Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN"; - var apiInstance = new PetApi(); - var petId = 789; // long? | ID of pet to update + var apiInstance = new PetApi(Configuration.Default); + var petId = 789; // long | ID of pet to update var requiredFile = BINARY_DATA_HERE; // System.IO.Stream | file to upload var additionalMetadata = additionalMetadata_example; // string | Additional data to pass to server (optional) @@ -559,9 +680,11 @@ namespace Example ApiResponse result = apiInstance.UploadFileWithRequiredFile(petId, requiredFile, additionalMetadata); Debug.WriteLine(result); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling PetApi.UploadFileWithRequiredFile: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -570,9 +693,10 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **petId** | **long?**| ID of pet to update | + **petId** | **long**| ID of pet to update | **requiredFile** | **System.IO.Stream**| file to upload | **additionalMetadata** | **string**| Additional data to pass to server | [optional] @@ -586,8 +710,16 @@ Name | Type | Description | Notes ### HTTP request headers - - **Content-Type**: multipart/form-data - - **Accept**: application/json +- **Content-Type**: multipart/form-data +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | - | -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/ReadOnlyFirst.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/ReadOnlyFirst.md index 6c2571cb48f5..8ea3b95919bf 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/ReadOnlyFirst.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/ReadOnlyFirst.md @@ -1,10 +1,14 @@ + # Org.OpenAPITools.Model.ReadOnlyFirst + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Bar** | **string** | | [optional] +**Bar** | **string** | | [optional] [readonly] **Baz** | **string** | | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Return.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Return.md index 21a269c63f4b..4761c70748e4 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Return.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Return.md @@ -1,9 +1,13 @@ + # Org.OpenAPITools.Model.Return + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**_Return** | **int?** | | [optional] +**_Return** | **int** | | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/SpecialModelName.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/SpecialModelName.md index 306e65392a2e..ee6489524d09 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/SpecialModelName.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/SpecialModelName.md @@ -1,9 +1,13 @@ + # Org.OpenAPITools.Model.SpecialModelName + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**SpecialPropertyName** | **long?** | | [optional] +**SpecialPropertyName** | **long** | | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/StoreApi.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/StoreApi.md index f8b4d3422db4..d3c3c7c54053 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/StoreApi.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/StoreApi.md @@ -10,8 +10,9 @@ Method | HTTP request | Description [**PlaceOrder**](StoreApi.md#placeorder) | **POST** /store/order | Place an order for a pet - -# **DeleteOrder** + +## DeleteOrder + > void DeleteOrder (string orderId) Delete purchase order by ID @@ -19,8 +20,9 @@ Delete purchase order by ID For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -30,9 +32,10 @@ namespace Example { public class DeleteOrderExample { - public void main() + public static void Main() { - var apiInstance = new StoreApi(); + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new StoreApi(Configuration.Default); var orderId = orderId_example; // string | ID of the order that needs to be deleted try @@ -40,9 +43,11 @@ namespace Example // Delete purchase order by ID apiInstance.DeleteOrder(orderId); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling StoreApi.DeleteOrder: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -51,6 +56,7 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **orderId** | **string**| ID of the order that needs to be deleted | @@ -65,22 +71,33 @@ No authorization required ### HTTP request headers - - **Content-Type**: Not defined - - **Accept**: Not defined +- **Content-Type**: Not defined +- **Accept**: Not defined + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **400** | Invalid ID supplied | - | +| **404** | Order not found | - | -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) - -# **GetInventory** -> Dictionary GetInventory () + +## GetInventory + +> Dictionary<string, int> GetInventory () Returns pet inventories by status Returns a map of status codes to quantities ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -90,24 +107,27 @@ namespace Example { public class GetInventoryExample { - public void main() + public static void Main() { + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; // Configure API key authorization: api_key Configuration.Default.AddApiKey("api_key", "YOUR_API_KEY"); // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed // Configuration.Default.AddApiKeyPrefix("api_key", "Bearer"); - var apiInstance = new StoreApi(); + var apiInstance = new StoreApi(Configuration.Default); try { // Returns pet inventories by status - Dictionary<string, int?> result = apiInstance.GetInventory(); + Dictionary result = apiInstance.GetInventory(); Debug.WriteLine(result); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling StoreApi.GetInventory: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -115,11 +135,12 @@ namespace Example ``` ### Parameters + This endpoint does not need any parameter. ### Return type -**Dictionary** +**Dictionary** ### Authorization @@ -127,22 +148,32 @@ This endpoint does not need any parameter. ### HTTP request headers - - **Content-Type**: Not defined - - **Accept**: application/json +- **Content-Type**: Not defined +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | - | -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) - -# **GetOrderById** -> Order GetOrderById (long? orderId) + +## GetOrderById + +> Order GetOrderById (long orderId) Find purchase order by ID For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -152,10 +183,11 @@ namespace Example { public class GetOrderByIdExample { - public void main() + public static void Main() { - var apiInstance = new StoreApi(); - var orderId = 789; // long? | ID of pet that needs to be fetched + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new StoreApi(Configuration.Default); + var orderId = 789; // long | ID of pet that needs to be fetched try { @@ -163,9 +195,11 @@ namespace Example Order result = apiInstance.GetOrderById(orderId); Debug.WriteLine(result); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling StoreApi.GetOrderById: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -174,9 +208,10 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **orderId** | **long?**| ID of pet that needs to be fetched | + **orderId** | **long**| ID of pet that needs to be fetched | ### Return type @@ -188,20 +223,32 @@ No authorization required ### HTTP request headers - - **Content-Type**: Not defined - - **Accept**: application/xml, application/json +- **Content-Type**: Not defined +- **Accept**: application/xml, application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | - | +| **400** | Invalid ID supplied | - | +| **404** | Order not found | - | -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) + + +## PlaceOrder - -# **PlaceOrder** > Order PlaceOrder (Order order) Place an order for a pet ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -211,9 +258,10 @@ namespace Example { public class PlaceOrderExample { - public void main() + public static void Main() { - var apiInstance = new StoreApi(); + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new StoreApi(Configuration.Default); var order = new Order(); // Order | order placed for purchasing the pet try @@ -222,9 +270,11 @@ namespace Example Order result = apiInstance.PlaceOrder(order); Debug.WriteLine(result); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling StoreApi.PlaceOrder: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -233,6 +283,7 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **order** | [**Order**](Order.md)| order placed for purchasing the pet | @@ -247,8 +298,17 @@ No authorization required ### HTTP request headers - - **Content-Type**: application/json - - **Accept**: application/xml, application/json +- **Content-Type**: application/json +- **Accept**: application/xml, application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | - | +| **400** | Invalid Order | - | -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Tag.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Tag.md index 6a76c28595f7..f781c26f017c 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Tag.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/Tag.md @@ -1,10 +1,14 @@ + # Org.OpenAPITools.Model.Tag + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Id** | **long?** | | [optional] +**Id** | **long** | | [optional] **Name** | **string** | | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/User.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/User.md index 04dd24a3423c..a25c25d1aa0b 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/User.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/User.md @@ -1,16 +1,20 @@ + # Org.OpenAPITools.Model.User + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Id** | **long?** | | [optional] +**Id** | **long** | | [optional] **Username** | **string** | | [optional] **FirstName** | **string** | | [optional] **LastName** | **string** | | [optional] **Email** | **string** | | [optional] **Password** | **string** | | [optional] **Phone** | **string** | | [optional] -**UserStatus** | **int?** | User Status | [optional] +**UserStatus** | **int** | User Status | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/UserApi.md b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/UserApi.md index 2fb4c422cf56..7c37179a9102 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/UserApi.md +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/docs/UserApi.md @@ -14,8 +14,9 @@ Method | HTTP request | Description [**UpdateUser**](UserApi.md#updateuser) | **PUT** /user/{username} | Updated user - -# **CreateUser** + +## CreateUser + > void CreateUser (User user) Create user @@ -23,8 +24,9 @@ Create user This can only be done by the logged in user. ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -34,9 +36,10 @@ namespace Example { public class CreateUserExample { - public void main() + public static void Main() { - var apiInstance = new UserApi(); + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new UserApi(Configuration.Default); var user = new User(); // User | Created user object try @@ -44,9 +47,11 @@ namespace Example // Create user apiInstance.CreateUser(user); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling UserApi.CreateUser: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -55,6 +60,7 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **user** | [**User**](User.md)| Created user object | @@ -69,20 +75,30 @@ No authorization required ### HTTP request headers - - **Content-Type**: application/json - - **Accept**: Not defined +- **Content-Type**: application/json +- **Accept**: Not defined + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **0** | successful operation | - | -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) + + +## CreateUsersWithArrayInput - -# **CreateUsersWithArrayInput** > void CreateUsersWithArrayInput (List user) Creates list of users with given input array ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -92,9 +108,10 @@ namespace Example { public class CreateUsersWithArrayInputExample { - public void main() + public static void Main() { - var apiInstance = new UserApi(); + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new UserApi(Configuration.Default); var user = new List(); // List | List of user object try @@ -102,9 +119,11 @@ namespace Example // Creates list of users with given input array apiInstance.CreateUsersWithArrayInput(user); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling UserApi.CreateUsersWithArrayInput: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -113,9 +132,10 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **user** | [**List<User>**](List.md)| List of user object | + **user** | [**List<User>**](User.md)| List of user object | ### Return type @@ -127,20 +147,30 @@ No authorization required ### HTTP request headers - - **Content-Type**: application/json - - **Accept**: Not defined +- **Content-Type**: application/json +- **Accept**: Not defined + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **0** | successful operation | - | -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) + + +## CreateUsersWithListInput - -# **CreateUsersWithListInput** > void CreateUsersWithListInput (List user) Creates list of users with given input array ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -150,9 +180,10 @@ namespace Example { public class CreateUsersWithListInputExample { - public void main() + public static void Main() { - var apiInstance = new UserApi(); + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new UserApi(Configuration.Default); var user = new List(); // List | List of user object try @@ -160,9 +191,11 @@ namespace Example // Creates list of users with given input array apiInstance.CreateUsersWithListInput(user); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling UserApi.CreateUsersWithListInput: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -171,9 +204,10 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **user** | [**List<User>**](List.md)| List of user object | + **user** | [**List<User>**](User.md)| List of user object | ### Return type @@ -185,13 +219,22 @@ No authorization required ### HTTP request headers - - **Content-Type**: application/json - - **Accept**: Not defined +- **Content-Type**: application/json +- **Accept**: Not defined + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **0** | successful operation | - | -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) + + +## DeleteUser - -# **DeleteUser** > void DeleteUser (string username) Delete user @@ -199,8 +242,9 @@ Delete user This can only be done by the logged in user. ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -210,9 +254,10 @@ namespace Example { public class DeleteUserExample { - public void main() + public static void Main() { - var apiInstance = new UserApi(); + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new UserApi(Configuration.Default); var username = username_example; // string | The name that needs to be deleted try @@ -220,9 +265,11 @@ namespace Example // Delete user apiInstance.DeleteUser(username); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling UserApi.DeleteUser: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -231,6 +278,7 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **username** | **string**| The name that needs to be deleted | @@ -245,20 +293,31 @@ No authorization required ### HTTP request headers - - **Content-Type**: Not defined - - **Accept**: Not defined +- **Content-Type**: Not defined +- **Accept**: Not defined + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **400** | Invalid username supplied | - | +| **404** | User not found | - | -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) + + +## GetUserByName - -# **GetUserByName** > User GetUserByName (string username) Get user by user name ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -268,9 +327,10 @@ namespace Example { public class GetUserByNameExample { - public void main() + public static void Main() { - var apiInstance = new UserApi(); + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new UserApi(Configuration.Default); var username = username_example; // string | The name that needs to be fetched. Use user1 for testing. try @@ -279,9 +339,11 @@ namespace Example User result = apiInstance.GetUserByName(username); Debug.WriteLine(result); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling UserApi.GetUserByName: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -290,6 +352,7 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **username** | **string**| The name that needs to be fetched. Use user1 for testing. | @@ -304,20 +367,32 @@ No authorization required ### HTTP request headers - - **Content-Type**: Not defined - - **Accept**: application/xml, application/json +- **Content-Type**: Not defined +- **Accept**: application/xml, application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | - | +| **400** | Invalid username supplied | - | +| **404** | User not found | - | -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) + + +## LoginUser - -# **LoginUser** > string LoginUser (string username, string password) Logs user into the system ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -327,9 +402,10 @@ namespace Example { public class LoginUserExample { - public void main() + public static void Main() { - var apiInstance = new UserApi(); + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new UserApi(Configuration.Default); var username = username_example; // string | The user name for login var password = password_example; // string | The password for login in clear text @@ -339,9 +415,11 @@ namespace Example string result = apiInstance.LoginUser(username, password); Debug.WriteLine(result); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling UserApi.LoginUser: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -350,6 +428,7 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **username** | **string**| The user name for login | @@ -365,20 +444,31 @@ No authorization required ### HTTP request headers - - **Content-Type**: Not defined - - **Accept**: application/xml, application/json +- **Content-Type**: Not defined +- **Accept**: application/xml, application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | successful operation | * X-Rate-Limit - calls per hour allowed by the user
* X-Expires-After - date in UTC when token expires
| +| **400** | Invalid username/password supplied | - | -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) + + +## LogoutUser - -# **LogoutUser** > void LogoutUser () Logs out current logged in user session ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -388,18 +478,21 @@ namespace Example { public class LogoutUserExample { - public void main() + public static void Main() { - var apiInstance = new UserApi(); + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new UserApi(Configuration.Default); try { // Logs out current logged in user session apiInstance.LogoutUser(); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling UserApi.LogoutUser: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -407,6 +500,7 @@ namespace Example ``` ### Parameters + This endpoint does not need any parameter. ### Return type @@ -419,13 +513,22 @@ No authorization required ### HTTP request headers - - **Content-Type**: Not defined - - **Accept**: Not defined +- **Content-Type**: Not defined +- **Accept**: Not defined + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **0** | successful operation | - | -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) + + +## UpdateUser - -# **UpdateUser** > void UpdateUser (string username, User user) Updated user @@ -433,8 +536,9 @@ Updated user This can only be done by the logged in user. ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -444,9 +548,10 @@ namespace Example { public class UpdateUserExample { - public void main() + public static void Main() { - var apiInstance = new UserApi(); + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new UserApi(Configuration.Default); var username = username_example; // string | name that need to be deleted var user = new User(); // User | Updated user object @@ -455,9 +560,11 @@ namespace Example // Updated user apiInstance.UpdateUser(username, user); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling UserApi.UpdateUser: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -466,6 +573,7 @@ namespace Example ### Parameters + Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **username** | **string**| name that need to be deleted | @@ -481,8 +589,17 @@ No authorization required ### HTTP request headers - - **Content-Type**: application/json - - **Accept**: Not defined +- **Content-Type**: application/json +- **Accept**: Not defined + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **400** | Invalid user supplied | - | +| **404** | User not found | - | -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/git_push.sh b/samples/openapi3/client/petstore/csharp/OpenAPIClient/git_push.sh index 4d22bfef4d71..ced3be2b0c7b 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/git_push.sh +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/git_push.sh @@ -1,11 +1,17 @@ #!/bin/sh # ref: https://help.github.com/articles/adding-an-existing-project-to-github-using-the-command-line/ # -# Usage example: /bin/sh ./git_push.sh wing328 openapi-petstore-perl "minor update" +# Usage example: /bin/sh ./git_push.sh wing328 openapi-pestore-perl "minor update" "gitlab.com" git_user_id=$1 git_repo_id=$2 release_note=$3 +git_host=$4 + +if [ "$git_host" = "" ]; then + git_host="github.com" + echo "[INFO] No command line input provided. Set \$git_host to $git_host" +fi if [ "$git_user_id" = "" ]; then git_user_id="GIT_USER_ID" @@ -37,9 +43,9 @@ if [ "$git_remote" = "" ]; then # git remote not defined if [ "$GIT_TOKEN" = "" ]; then echo "[INFO] \$GIT_TOKEN (environment variable) is not set. Using the git credential in your environment." - git remote add origin https://github.com/${git_user_id}/${git_repo_id}.git + git remote add origin https://${git_host}/${git_user_id}/${git_repo_id}.git else - git remote add origin https://${git_user_id}:${GIT_TOKEN}@github.com/${git_user_id}/${git_repo_id}.git + git remote add origin https://${git_user_id}:${GIT_TOKEN}@${git_host}/${git_user_id}/${git_repo_id}.git fi fi @@ -47,6 +53,6 @@ fi git pull origin master # Pushes (Forces) the changes in the local repository up to the remote repository -echo "Git pushing to https://github.com/${git_user_id}/${git_repo_id}.git" +echo "Git pushing to https://${git_host}/${git_user_id}/${git_repo_id}.git" git push origin master 2>&1 | grep -v 'To https' diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/mono_nunit_test.sh b/samples/openapi3/client/petstore/csharp/OpenAPIClient/mono_nunit_test.sh index 039eba8ed42a..ef4209de27b2 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/mono_nunit_test.sh +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/mono_nunit_test.sh @@ -14,9 +14,9 @@ wget -nc https://dist.nuget.org/win-x86-commandline/latest/nuget.exe mozroots --import --sync mono nuget.exe install src/Org.OpenAPITools.Test/packages.config -o packages -echo "[INFO] Install NUnit runners via NuGet" -mono nuget.exe install NUnit.Runners -Version 2.6.4 -OutputDirectory packages +echo "[INFO] Install NUnit Console 3.x runners via NuGet" +mono nuget.exe install NUnit.ConsoleRunner -Version 3.10.0 -OutputDirectory packages echo "[INFO] Build the solution and run the unit test" xbuild Org.OpenAPITools.sln && \ - mono ./packages/NUnit.Runners.2.6.4/tools/nunit-console.exe src/Org.OpenAPITools.Test/bin/Debug/Org.OpenAPITools.Test.dll + mono ./packages/NUnit.ConsoleRunner.3.10.0/tools/nunit3-console.exe src/Org.OpenAPITools.Test/bin/Debug/Org.OpenAPITools.Test.dll diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools.Test/Model/CatAllOfTests.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools.Test/Model/CatAllOfTests.cs new file mode 100644 index 000000000000..d7afe6310fa7 --- /dev/null +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools.Test/Model/CatAllOfTests.cs @@ -0,0 +1,79 @@ +/* + * OpenAPI Petstore + * + * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ + * + * The version of the OpenAPI document: 1.0.0 + * + * Generated by: https://github.com/openapitools/openapi-generator.git + */ + + +using NUnit.Framework; + +using System; +using System.Linq; +using System.IO; +using System.Collections.Generic; +using Org.OpenAPITools.Api; +using Org.OpenAPITools.Model; +using Org.OpenAPITools.Client; +using System.Reflection; +using Newtonsoft.Json; + +namespace Org.OpenAPITools.Test +{ + /// + /// Class for testing CatAllOf + /// + /// + /// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech). + /// Please update the test case below to test the model. + /// + public class CatAllOfTests + { + // TODO uncomment below to declare an instance variable for CatAllOf + //private CatAllOf instance; + + /// + /// Setup before each test + /// + [SetUp] + public void Init() + { + // TODO uncomment below to create an instance of CatAllOf + //instance = new CatAllOf(); + } + + /// + /// Clean up after each test + /// + [TearDown] + public void Cleanup() + { + + } + + /// + /// Test an instance of CatAllOf + /// + [Test] + public void CatAllOfInstanceTest() + { + // TODO uncomment below to test "IsInstanceOf" CatAllOf + //Assert.IsInstanceOf(typeof(CatAllOf), instance); + } + + + /// + /// Test the property 'Declawed' + /// + [Test] + public void DeclawedTest() + { + // TODO unit test for the property 'Declawed' + } + + } + +} diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools.Test/Model/DogAllOfTests.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools.Test/Model/DogAllOfTests.cs new file mode 100644 index 000000000000..30f5bed38e19 --- /dev/null +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools.Test/Model/DogAllOfTests.cs @@ -0,0 +1,79 @@ +/* + * OpenAPI Petstore + * + * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ + * + * The version of the OpenAPI document: 1.0.0 + * + * Generated by: https://github.com/openapitools/openapi-generator.git + */ + + +using NUnit.Framework; + +using System; +using System.Linq; +using System.IO; +using System.Collections.Generic; +using Org.OpenAPITools.Api; +using Org.OpenAPITools.Model; +using Org.OpenAPITools.Client; +using System.Reflection; +using Newtonsoft.Json; + +namespace Org.OpenAPITools.Test +{ + /// + /// Class for testing DogAllOf + /// + /// + /// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech). + /// Please update the test case below to test the model. + /// + public class DogAllOfTests + { + // TODO uncomment below to declare an instance variable for DogAllOf + //private DogAllOf instance; + + /// + /// Setup before each test + /// + [SetUp] + public void Init() + { + // TODO uncomment below to create an instance of DogAllOf + //instance = new DogAllOf(); + } + + /// + /// Clean up after each test + /// + [TearDown] + public void Cleanup() + { + + } + + /// + /// Test an instance of DogAllOf + /// + [Test] + public void DogAllOfInstanceTest() + { + // TODO uncomment below to test "IsInstanceOf" DogAllOf + //Assert.IsInstanceOf(typeof(DogAllOf), instance); + } + + + /// + /// Test the property 'Breed' + /// + [Test] + public void BreedTest() + { + // TODO unit test for the property 'Breed' + } + + } + +} diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools.Test/Org.OpenAPITools.Test.csproj b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools.Test/Org.OpenAPITools.Test.csproj index 48ec5e0f7c18..4b8e53975129 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools.Test/Org.OpenAPITools.Test.csproj +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools.Test/Org.OpenAPITools.Test.csproj @@ -4,7 +4,7 @@ OpenAPI Petstore This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ -OpenAPI spec version: 1.0.0 +The version of the OpenAPI document: 1.0.0 --> @@ -47,16 +47,16 @@ OpenAPI spec version: 1.0.0 - $(SolutionDir)\packages\Newtonsoft.Json.10.0.3\lib\net45\Newtonsoft.Json.dll - ..\packages\Newtonsoft.Json.10.0.3\lib\net45\Newtonsoft.Json.dll - ..\..\packages\Newtonsoft.Json.10.0.3\lib\net45\Newtonsoft.Json.dll - ..\..\vendor\Newtonsoft.Json.10.0.3\lib\net45\Newtonsoft.Json.dll + $(SolutionDir)\packages\Newtonsoft.Json.12.0.3\lib\net45\Newtonsoft.Json.dll + ..\packages\Newtonsoft.Json.12.0.3\lib\net45\Newtonsoft.Json.dll + ..\..\packages\Newtonsoft.Json.12.0.3\lib\net45\Newtonsoft.Json.dll + ..\..\vendor\Newtonsoft.Json.12.0.3\lib\net45\Newtonsoft.Json.dll - $(SolutionDir)\packages\JsonSubTypes.1.2.0\lib\net45\JsonSubTypes.dll - ..\packages\JsonSubTypes.1.2.0\lib\net45\JsonSubTypes.dll - ..\..\packages\JsonSubTypes.1.2.0\lib\net45\JsonSubTypes.dll - ..\..\vendor\JsonSubTypes.1.2.0\lib\net45\JsonSubTypes.dll + $(SolutionDir)\packages\JsonSubTypes.1.6.0\lib\net45\JsonSubTypes.dll + ..\packages\JsonSubTypes.1.6.0\lib\net45\JsonSubTypes.dll + ..\..\packages\JsonSubTypes.1.6.0\lib\net45\JsonSubTypes.dll + ..\..\vendor\JsonSubTypes.1.6.0\lib\net45\JsonSubTypes.dll $(SolutionDir)\packages\RestSharp.105.1.0\lib\net45\RestSharp.dll @@ -65,10 +65,10 @@ OpenAPI spec version: 1.0.0 ..\..\vendor\RestSharp.105.1.0\lib\net45\RestSharp.dll - $(SolutionDir)\packages\NUnit.2.6.4\lib\nunit.framework.dll - ..\packages\NUnit.2.6.4\lib\nunit.framework.dll - ..\..\packages\NUnit.2.6.4\lib\nunit.framework.dll - ..\..\vendor\NUnit.2.6.4\lib\nunit.framework.dll + $(SolutionDir)\packages\NUnit.3.11.0\lib\net45\nunit.framework.dll + ..\packages\NUnit.3.11.0\lib\net45\nunit.framework.dll + ..\..\packages\NUnit.3.11.0\lib\net45\nunit.framework.dll + ..\..\vendor\NUnit.3.11.0\lib\net45\nunit.framework.dll diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools.Test/packages.config b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools.Test/packages.config index ac390c1dcb3c..a3a1bab35101 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools.Test/packages.config +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools.Test/packages.config @@ -1,7 +1,7 @@ - + - - + + diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Api/AnotherFakeApi.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Api/AnotherFakeApi.cs index 563a1e9f64ab..558709f5d014 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Api/AnotherFakeApi.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Api/AnotherFakeApi.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -197,7 +197,7 @@ public ModelClient Call123TestSpecialTags (ModelClient modelClient) /// Thrown when fails to make API call /// client model /// ApiResponse of ModelClient - public ApiResponse< ModelClient > Call123TestSpecialTagsWithHttpInfo (ModelClient modelClient) + public ApiResponse Call123TestSpecialTagsWithHttpInfo (ModelClient modelClient) { // verify the required parameter 'modelClient' is set if (modelClient == null) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Api/DefaultApi.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Api/DefaultApi.cs index 20e11dbf458e..9a524e2177be 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Api/DefaultApi.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Api/DefaultApi.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -191,7 +191,7 @@ public InlineResponseDefault FooGet () /// /// Thrown when fails to make API call /// ApiResponse of InlineResponseDefault - public ApiResponse< InlineResponseDefault > FooGetWithHttpInfo () + public ApiResponse FooGetWithHttpInfo () { var localVarPath = "/foo"; diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Api/FakeApi.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Api/FakeApi.cs index 22f8ef1bafce..03488173822d 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Api/FakeApi.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Api/FakeApi.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -44,6 +44,31 @@ public interface IFakeApi : IApiAccessor /// ApiResponse of HealthCheckResult ApiResponse FakeHealthGetWithHttpInfo (); /// + /// test http signature authentication + /// + /// + /// + /// + /// Thrown when fails to make API call + /// Pet object that needs to be added to the store + /// query parameter (optional) + /// header parameter (optional) + /// + void FakeHttpSignatureTest (Pet pet, string query1 = default(string), string header1 = default(string)); + + /// + /// test http signature authentication + /// + /// + /// + /// + /// Thrown when fails to make API call + /// Pet object that needs to be added to the store + /// query parameter (optional) + /// header parameter (optional) + /// ApiResponse of Object(void) + ApiResponse FakeHttpSignatureTestWithHttpInfo (Pet pet, string query1 = default(string), string header1 = default(string)); + /// /// /// /// @@ -51,8 +76,8 @@ public interface IFakeApi : IApiAccessor /// /// Thrown when fails to make API call /// Input boolean as post body (optional) - /// bool? - bool? FakeOuterBooleanSerialize (bool? body = null); + /// bool + bool FakeOuterBooleanSerialize (bool? body = default(bool?)); /// /// @@ -62,8 +87,8 @@ public interface IFakeApi : IApiAccessor /// /// Thrown when fails to make API call /// Input boolean as post body (optional) - /// ApiResponse of bool? - ApiResponse FakeOuterBooleanSerializeWithHttpInfo (bool? body = null); + /// ApiResponse of bool + ApiResponse FakeOuterBooleanSerializeWithHttpInfo (bool? body = default(bool?)); /// /// /// @@ -73,7 +98,7 @@ public interface IFakeApi : IApiAccessor /// Thrown when fails to make API call /// Input composite as post body (optional) /// OuterComposite - OuterComposite FakeOuterCompositeSerialize (OuterComposite outerComposite = null); + OuterComposite FakeOuterCompositeSerialize (OuterComposite outerComposite = default(OuterComposite)); /// /// @@ -84,7 +109,7 @@ public interface IFakeApi : IApiAccessor /// Thrown when fails to make API call /// Input composite as post body (optional) /// ApiResponse of OuterComposite - ApiResponse FakeOuterCompositeSerializeWithHttpInfo (OuterComposite outerComposite = null); + ApiResponse FakeOuterCompositeSerializeWithHttpInfo (OuterComposite outerComposite = default(OuterComposite)); /// /// /// @@ -93,8 +118,8 @@ public interface IFakeApi : IApiAccessor /// /// Thrown when fails to make API call /// Input number as post body (optional) - /// decimal? - decimal? FakeOuterNumberSerialize (decimal? body = null); + /// decimal + decimal FakeOuterNumberSerialize (decimal? body = default(decimal?)); /// /// @@ -104,8 +129,8 @@ public interface IFakeApi : IApiAccessor /// /// Thrown when fails to make API call /// Input number as post body (optional) - /// ApiResponse of decimal? - ApiResponse FakeOuterNumberSerializeWithHttpInfo (decimal? body = null); + /// ApiResponse of decimal + ApiResponse FakeOuterNumberSerializeWithHttpInfo (decimal? body = default(decimal?)); /// /// /// @@ -115,7 +140,7 @@ public interface IFakeApi : IApiAccessor /// Thrown when fails to make API call /// Input string as post body (optional) /// string - string FakeOuterStringSerialize (string body = null); + string FakeOuterStringSerialize (string body = default(string)); /// /// @@ -126,7 +151,7 @@ public interface IFakeApi : IApiAccessor /// Thrown when fails to make API call /// Input string as post body (optional) /// ApiResponse of string - ApiResponse FakeOuterStringSerializeWithHttpInfo (string body = null); + ApiResponse FakeOuterStringSerializeWithHttpInfo (string body = default(string)); /// /// /// @@ -214,7 +239,7 @@ public interface IFakeApi : IApiAccessor /// None (optional) /// None (optional) /// - void TestEndpointParameters (decimal? number, double? _double, string patternWithoutDelimiter, byte[] _byte, int? integer = null, int? int32 = null, long? int64 = null, float? _float = null, string _string = null, System.IO.Stream binary = null, DateTime? date = null, DateTime? dateTime = null, string password = null, string callback = null); + void TestEndpointParameters (decimal number, double _double, string patternWithoutDelimiter, byte[] _byte, int? integer = default(int?), int? int32 = default(int?), long? int64 = default(long?), float? _float = default(float?), string _string = default(string), System.IO.Stream binary = default(System.IO.Stream), DateTime? date = default(DateTime?), DateTime? dateTime = default(DateTime?), string password = default(string), string callback = default(string)); /// /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 @@ -238,7 +263,7 @@ public interface IFakeApi : IApiAccessor /// None (optional) /// None (optional) /// ApiResponse of Object(void) - ApiResponse TestEndpointParametersWithHttpInfo (decimal? number, double? _double, string patternWithoutDelimiter, byte[] _byte, int? integer = null, int? int32 = null, long? int64 = null, float? _float = null, string _string = null, System.IO.Stream binary = null, DateTime? date = null, DateTime? dateTime = null, string password = null, string callback = null); + ApiResponse TestEndpointParametersWithHttpInfo (decimal number, double _double, string patternWithoutDelimiter, byte[] _byte, int? integer = default(int?), int? int32 = default(int?), long? int64 = default(long?), float? _float = default(float?), string _string = default(string), System.IO.Stream binary = default(System.IO.Stream), DateTime? date = default(DateTime?), DateTime? dateTime = default(DateTime?), string password = default(string), string callback = default(string)); /// /// To test enum parameters /// @@ -255,7 +280,7 @@ public interface IFakeApi : IApiAccessor /// Form parameter enum test (string array) (optional, default to $) /// Form parameter enum test (string) (optional, default to -efg) /// - void TestEnumParameters (List enumHeaderStringArray = null, string enumHeaderString = null, List enumQueryStringArray = null, string enumQueryString = null, int? enumQueryInteger = null, double? enumQueryDouble = null, List enumFormStringArray = null, string enumFormString = null); + void TestEnumParameters (List enumHeaderStringArray = default(List), string enumHeaderString = default(string), List enumQueryStringArray = default(List), string enumQueryString = default(string), int? enumQueryInteger = default(int?), double? enumQueryDouble = default(double?), List enumFormStringArray = default(List), string enumFormString = default(string)); /// /// To test enum parameters @@ -273,7 +298,7 @@ public interface IFakeApi : IApiAccessor /// Form parameter enum test (string array) (optional, default to $) /// Form parameter enum test (string) (optional, default to -efg) /// ApiResponse of Object(void) - ApiResponse TestEnumParametersWithHttpInfo (List enumHeaderStringArray = null, string enumHeaderString = null, List enumQueryStringArray = null, string enumQueryString = null, int? enumQueryInteger = null, double? enumQueryDouble = null, List enumFormStringArray = null, string enumFormString = null); + ApiResponse TestEnumParametersWithHttpInfo (List enumHeaderStringArray = default(List), string enumHeaderString = default(string), List enumQueryStringArray = default(List), string enumQueryString = default(string), int? enumQueryInteger = default(int?), double? enumQueryDouble = default(double?), List enumFormStringArray = default(List), string enumFormString = default(string)); /// /// Fake endpoint to test group parameters (optional) /// @@ -288,7 +313,7 @@ public interface IFakeApi : IApiAccessor /// Boolean in group parameters (optional) /// Integer in group parameters (optional) /// - void TestGroupParameters (int? requiredStringGroup, bool? requiredBooleanGroup, long? requiredInt64Group, int? stringGroup = null, bool? booleanGroup = null, long? int64Group = null); + void TestGroupParameters (int requiredStringGroup, bool requiredBooleanGroup, long requiredInt64Group, int? stringGroup = default(int?), bool? booleanGroup = default(bool?), long? int64Group = default(long?)); /// /// Fake endpoint to test group parameters (optional) @@ -304,7 +329,7 @@ public interface IFakeApi : IApiAccessor /// Boolean in group parameters (optional) /// Integer in group parameters (optional) /// ApiResponse of Object(void) - ApiResponse TestGroupParametersWithHttpInfo (int? requiredStringGroup, bool? requiredBooleanGroup, long? requiredInt64Group, int? stringGroup = null, bool? booleanGroup = null, long? int64Group = null); + ApiResponse TestGroupParametersWithHttpInfo (int requiredStringGroup, bool requiredBooleanGroup, long requiredInt64Group, int? stringGroup = default(int?), bool? booleanGroup = default(bool?), long? int64Group = default(long?)); /// /// test inline additionalProperties /// @@ -349,6 +374,35 @@ public interface IFakeApi : IApiAccessor /// field2 /// ApiResponse of Object(void) ApiResponse TestJsonFormDataWithHttpInfo (string param, string param2); + /// + /// + /// + /// + /// To test the collection format in query parameters + /// + /// Thrown when fails to make API call + /// + /// + /// + /// + /// + /// + void TestQueryParameterCollectionFormat (List pipe, List ioutil, List http, List url, List context); + + /// + /// + /// + /// + /// To test the collection format in query parameters + /// + /// Thrown when fails to make API call + /// + /// + /// + /// + /// + /// ApiResponse of Object(void) + ApiResponse TestQueryParameterCollectionFormatWithHttpInfo (List pipe, List ioutil, List http, List url, List context); #endregion Synchronous Operations #region Asynchronous Operations /// @@ -371,6 +425,31 @@ public interface IFakeApi : IApiAccessor /// Task of ApiResponse (HealthCheckResult) System.Threading.Tasks.Task> FakeHealthGetAsyncWithHttpInfo (); /// + /// test http signature authentication + /// + /// + /// + /// + /// Thrown when fails to make API call + /// Pet object that needs to be added to the store + /// query parameter (optional) + /// header parameter (optional) + /// Task of void + System.Threading.Tasks.Task FakeHttpSignatureTestAsync (Pet pet, string query1 = default(string), string header1 = default(string)); + + /// + /// test http signature authentication + /// + /// + /// + /// + /// Thrown when fails to make API call + /// Pet object that needs to be added to the store + /// query parameter (optional) + /// header parameter (optional) + /// Task of ApiResponse + System.Threading.Tasks.Task> FakeHttpSignatureTestAsyncWithHttpInfo (Pet pet, string query1 = default(string), string header1 = default(string)); + /// /// /// /// @@ -378,8 +457,8 @@ public interface IFakeApi : IApiAccessor /// /// Thrown when fails to make API call /// Input boolean as post body (optional) - /// Task of bool? - System.Threading.Tasks.Task FakeOuterBooleanSerializeAsync (bool? body = null); + /// Task of bool + System.Threading.Tasks.Task FakeOuterBooleanSerializeAsync (bool? body = default(bool?)); /// /// @@ -389,8 +468,8 @@ public interface IFakeApi : IApiAccessor /// /// Thrown when fails to make API call /// Input boolean as post body (optional) - /// Task of ApiResponse (bool?) - System.Threading.Tasks.Task> FakeOuterBooleanSerializeAsyncWithHttpInfo (bool? body = null); + /// Task of ApiResponse (bool) + System.Threading.Tasks.Task> FakeOuterBooleanSerializeAsyncWithHttpInfo (bool? body = default(bool?)); /// /// /// @@ -400,7 +479,7 @@ public interface IFakeApi : IApiAccessor /// Thrown when fails to make API call /// Input composite as post body (optional) /// Task of OuterComposite - System.Threading.Tasks.Task FakeOuterCompositeSerializeAsync (OuterComposite outerComposite = null); + System.Threading.Tasks.Task FakeOuterCompositeSerializeAsync (OuterComposite outerComposite = default(OuterComposite)); /// /// @@ -411,7 +490,7 @@ public interface IFakeApi : IApiAccessor /// Thrown when fails to make API call /// Input composite as post body (optional) /// Task of ApiResponse (OuterComposite) - System.Threading.Tasks.Task> FakeOuterCompositeSerializeAsyncWithHttpInfo (OuterComposite outerComposite = null); + System.Threading.Tasks.Task> FakeOuterCompositeSerializeAsyncWithHttpInfo (OuterComposite outerComposite = default(OuterComposite)); /// /// /// @@ -420,8 +499,8 @@ public interface IFakeApi : IApiAccessor /// /// Thrown when fails to make API call /// Input number as post body (optional) - /// Task of decimal? - System.Threading.Tasks.Task FakeOuterNumberSerializeAsync (decimal? body = null); + /// Task of decimal + System.Threading.Tasks.Task FakeOuterNumberSerializeAsync (decimal? body = default(decimal?)); /// /// @@ -431,8 +510,8 @@ public interface IFakeApi : IApiAccessor /// /// Thrown when fails to make API call /// Input number as post body (optional) - /// Task of ApiResponse (decimal?) - System.Threading.Tasks.Task> FakeOuterNumberSerializeAsyncWithHttpInfo (decimal? body = null); + /// Task of ApiResponse (decimal) + System.Threading.Tasks.Task> FakeOuterNumberSerializeAsyncWithHttpInfo (decimal? body = default(decimal?)); /// /// /// @@ -442,7 +521,7 @@ public interface IFakeApi : IApiAccessor /// Thrown when fails to make API call /// Input string as post body (optional) /// Task of string - System.Threading.Tasks.Task FakeOuterStringSerializeAsync (string body = null); + System.Threading.Tasks.Task FakeOuterStringSerializeAsync (string body = default(string)); /// /// @@ -453,7 +532,7 @@ public interface IFakeApi : IApiAccessor /// Thrown when fails to make API call /// Input string as post body (optional) /// Task of ApiResponse (string) - System.Threading.Tasks.Task> FakeOuterStringSerializeAsyncWithHttpInfo (string body = null); + System.Threading.Tasks.Task> FakeOuterStringSerializeAsyncWithHttpInfo (string body = default(string)); /// /// /// @@ -541,7 +620,7 @@ public interface IFakeApi : IApiAccessor /// None (optional) /// None (optional) /// Task of void - System.Threading.Tasks.Task TestEndpointParametersAsync (decimal? number, double? _double, string patternWithoutDelimiter, byte[] _byte, int? integer = null, int? int32 = null, long? int64 = null, float? _float = null, string _string = null, System.IO.Stream binary = null, DateTime? date = null, DateTime? dateTime = null, string password = null, string callback = null); + System.Threading.Tasks.Task TestEndpointParametersAsync (decimal number, double _double, string patternWithoutDelimiter, byte[] _byte, int? integer = default(int?), int? int32 = default(int?), long? int64 = default(long?), float? _float = default(float?), string _string = default(string), System.IO.Stream binary = default(System.IO.Stream), DateTime? date = default(DateTime?), DateTime? dateTime = default(DateTime?), string password = default(string), string callback = default(string)); /// /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 @@ -565,7 +644,7 @@ public interface IFakeApi : IApiAccessor /// None (optional) /// None (optional) /// Task of ApiResponse - System.Threading.Tasks.Task> TestEndpointParametersAsyncWithHttpInfo (decimal? number, double? _double, string patternWithoutDelimiter, byte[] _byte, int? integer = null, int? int32 = null, long? int64 = null, float? _float = null, string _string = null, System.IO.Stream binary = null, DateTime? date = null, DateTime? dateTime = null, string password = null, string callback = null); + System.Threading.Tasks.Task> TestEndpointParametersAsyncWithHttpInfo (decimal number, double _double, string patternWithoutDelimiter, byte[] _byte, int? integer = default(int?), int? int32 = default(int?), long? int64 = default(long?), float? _float = default(float?), string _string = default(string), System.IO.Stream binary = default(System.IO.Stream), DateTime? date = default(DateTime?), DateTime? dateTime = default(DateTime?), string password = default(string), string callback = default(string)); /// /// To test enum parameters /// @@ -582,7 +661,7 @@ public interface IFakeApi : IApiAccessor /// Form parameter enum test (string array) (optional, default to $) /// Form parameter enum test (string) (optional, default to -efg) /// Task of void - System.Threading.Tasks.Task TestEnumParametersAsync (List enumHeaderStringArray = null, string enumHeaderString = null, List enumQueryStringArray = null, string enumQueryString = null, int? enumQueryInteger = null, double? enumQueryDouble = null, List enumFormStringArray = null, string enumFormString = null); + System.Threading.Tasks.Task TestEnumParametersAsync (List enumHeaderStringArray = default(List), string enumHeaderString = default(string), List enumQueryStringArray = default(List), string enumQueryString = default(string), int? enumQueryInteger = default(int?), double? enumQueryDouble = default(double?), List enumFormStringArray = default(List), string enumFormString = default(string)); /// /// To test enum parameters @@ -600,7 +679,7 @@ public interface IFakeApi : IApiAccessor /// Form parameter enum test (string array) (optional, default to $) /// Form parameter enum test (string) (optional, default to -efg) /// Task of ApiResponse - System.Threading.Tasks.Task> TestEnumParametersAsyncWithHttpInfo (List enumHeaderStringArray = null, string enumHeaderString = null, List enumQueryStringArray = null, string enumQueryString = null, int? enumQueryInteger = null, double? enumQueryDouble = null, List enumFormStringArray = null, string enumFormString = null); + System.Threading.Tasks.Task> TestEnumParametersAsyncWithHttpInfo (List enumHeaderStringArray = default(List), string enumHeaderString = default(string), List enumQueryStringArray = default(List), string enumQueryString = default(string), int? enumQueryInteger = default(int?), double? enumQueryDouble = default(double?), List enumFormStringArray = default(List), string enumFormString = default(string)); /// /// Fake endpoint to test group parameters (optional) /// @@ -615,7 +694,7 @@ public interface IFakeApi : IApiAccessor /// Boolean in group parameters (optional) /// Integer in group parameters (optional) /// Task of void - System.Threading.Tasks.Task TestGroupParametersAsync (int? requiredStringGroup, bool? requiredBooleanGroup, long? requiredInt64Group, int? stringGroup = null, bool? booleanGroup = null, long? int64Group = null); + System.Threading.Tasks.Task TestGroupParametersAsync (int requiredStringGroup, bool requiredBooleanGroup, long requiredInt64Group, int? stringGroup = default(int?), bool? booleanGroup = default(bool?), long? int64Group = default(long?)); /// /// Fake endpoint to test group parameters (optional) @@ -631,7 +710,7 @@ public interface IFakeApi : IApiAccessor /// Boolean in group parameters (optional) /// Integer in group parameters (optional) /// Task of ApiResponse - System.Threading.Tasks.Task> TestGroupParametersAsyncWithHttpInfo (int? requiredStringGroup, bool? requiredBooleanGroup, long? requiredInt64Group, int? stringGroup = null, bool? booleanGroup = null, long? int64Group = null); + System.Threading.Tasks.Task> TestGroupParametersAsyncWithHttpInfo (int requiredStringGroup, bool requiredBooleanGroup, long requiredInt64Group, int? stringGroup = default(int?), bool? booleanGroup = default(bool?), long? int64Group = default(long?)); /// /// test inline additionalProperties /// @@ -676,6 +755,35 @@ public interface IFakeApi : IApiAccessor /// field2 /// Task of ApiResponse System.Threading.Tasks.Task> TestJsonFormDataAsyncWithHttpInfo (string param, string param2); + /// + /// + /// + /// + /// To test the collection format in query parameters + /// + /// Thrown when fails to make API call + /// + /// + /// + /// + /// + /// Task of void + System.Threading.Tasks.Task TestQueryParameterCollectionFormatAsync (List pipe, List ioutil, List http, List url, List context); + + /// + /// + /// + /// + /// To test the collection format in query parameters + /// + /// Thrown when fails to make API call + /// + /// + /// + /// + /// + /// Task of ApiResponse + System.Threading.Tasks.Task> TestQueryParameterCollectionFormatAsyncWithHttpInfo (List pipe, List ioutil, List http, List url, List context); #endregion Asynchronous Operations } @@ -803,7 +911,7 @@ public HealthCheckResult FakeHealthGet () /// /// Thrown when fails to make API call /// ApiResponse of HealthCheckResult - public ApiResponse< HealthCheckResult > FakeHealthGetWithHttpInfo () + public ApiResponse FakeHealthGetWithHttpInfo () { var localVarPath = "/fake/health"; @@ -908,15 +1016,176 @@ public async System.Threading.Tasks.Task> FakeHea (HealthCheckResult) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(HealthCheckResult))); } + /// + /// test http signature authentication + /// + /// Thrown when fails to make API call + /// Pet object that needs to be added to the store + /// query parameter (optional) + /// header parameter (optional) + /// + public void FakeHttpSignatureTest (Pet pet, string query1 = default(string), string header1 = default(string)) + { + FakeHttpSignatureTestWithHttpInfo(pet, query1, header1); + } + + /// + /// test http signature authentication + /// + /// Thrown when fails to make API call + /// Pet object that needs to be added to the store + /// query parameter (optional) + /// header parameter (optional) + /// ApiResponse of Object(void) + public ApiResponse FakeHttpSignatureTestWithHttpInfo (Pet pet, string query1 = default(string), string header1 = default(string)) + { + // verify the required parameter 'pet' is set + if (pet == null) + throw new ApiException(400, "Missing required parameter 'pet' when calling FakeApi->FakeHttpSignatureTest"); + + var localVarPath = "/fake/http-signature-test"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new List>(); + var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new Dictionary(); + Object localVarPostBody = null; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + "application/json", + "application/xml" + }; + String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + }; + String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + if (query1 != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "query_1", query1)); // query parameter + if (header1 != null) localVarHeaderParams.Add("header_1", this.Configuration.ApiClient.ParameterToString(header1)); // header parameter + if (pet != null && pet.GetType() != typeof(byte[])) + { + localVarPostBody = this.Configuration.ApiClient.Serialize(pet); // http body (model) parameter + } + else + { + localVarPostBody = pet; // byte array + } + + // authentication (http_signature_test) required + + // make the HTTP request + IRestResponse localVarResponse = (IRestResponse) this.Configuration.ApiClient.CallApi(localVarPath, + Method.GET, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, + localVarPathParams, localVarHttpContentType); + + int localVarStatusCode = (int) localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("FakeHttpSignatureTest", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)), + null); + } + + /// + /// test http signature authentication + /// + /// Thrown when fails to make API call + /// Pet object that needs to be added to the store + /// query parameter (optional) + /// header parameter (optional) + /// Task of void + public async System.Threading.Tasks.Task FakeHttpSignatureTestAsync (Pet pet, string query1 = default(string), string header1 = default(string)) + { + await FakeHttpSignatureTestAsyncWithHttpInfo(pet, query1, header1); + + } + + /// + /// test http signature authentication + /// + /// Thrown when fails to make API call + /// Pet object that needs to be added to the store + /// query parameter (optional) + /// header parameter (optional) + /// Task of ApiResponse + public async System.Threading.Tasks.Task> FakeHttpSignatureTestAsyncWithHttpInfo (Pet pet, string query1 = default(string), string header1 = default(string)) + { + // verify the required parameter 'pet' is set + if (pet == null) + throw new ApiException(400, "Missing required parameter 'pet' when calling FakeApi->FakeHttpSignatureTest"); + + var localVarPath = "/fake/http-signature-test"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new List>(); + var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new Dictionary(); + Object localVarPostBody = null; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + "application/json", + "application/xml" + }; + String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + }; + String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + if (query1 != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "query_1", query1)); // query parameter + if (header1 != null) localVarHeaderParams.Add("header_1", this.Configuration.ApiClient.ParameterToString(header1)); // header parameter + if (pet != null && pet.GetType() != typeof(byte[])) + { + localVarPostBody = this.Configuration.ApiClient.Serialize(pet); // http body (model) parameter + } + else + { + localVarPostBody = pet; // byte array + } + + // authentication (http_signature_test) required + + // make the HTTP request + IRestResponse localVarResponse = (IRestResponse) await this.Configuration.ApiClient.CallApiAsync(localVarPath, + Method.GET, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, + localVarPathParams, localVarHttpContentType); + + int localVarStatusCode = (int) localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("FakeHttpSignatureTest", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)), + null); + } + /// /// Test serialization of outer boolean types /// /// Thrown when fails to make API call /// Input boolean as post body (optional) - /// bool? - public bool? FakeOuterBooleanSerialize (bool? body = null) + /// bool + public bool FakeOuterBooleanSerialize (bool? body = default(bool?)) { - ApiResponse localVarResponse = FakeOuterBooleanSerializeWithHttpInfo(body); + ApiResponse localVarResponse = FakeOuterBooleanSerializeWithHttpInfo(body); return localVarResponse.Data; } @@ -925,8 +1194,8 @@ public async System.Threading.Tasks.Task> FakeHea /// /// Thrown when fails to make API call /// Input boolean as post body (optional) - /// ApiResponse of bool? - public ApiResponse< bool? > FakeOuterBooleanSerializeWithHttpInfo (bool? body = null) + /// ApiResponse of bool + public ApiResponse FakeOuterBooleanSerializeWithHttpInfo (bool? body = default(bool?)) { var localVarPath = "/fake/outer/boolean"; @@ -974,9 +1243,9 @@ public async System.Threading.Tasks.Task> FakeHea if (exception != null) throw exception; } - return new ApiResponse(localVarStatusCode, + return new ApiResponse(localVarStatusCode, localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)), - (bool?) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(bool?))); + (bool) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(bool))); } /// @@ -984,10 +1253,10 @@ public async System.Threading.Tasks.Task> FakeHea /// /// Thrown when fails to make API call /// Input boolean as post body (optional) - /// Task of bool? - public async System.Threading.Tasks.Task FakeOuterBooleanSerializeAsync (bool? body = null) + /// Task of bool + public async System.Threading.Tasks.Task FakeOuterBooleanSerializeAsync (bool? body = default(bool?)) { - ApiResponse localVarResponse = await FakeOuterBooleanSerializeAsyncWithHttpInfo(body); + ApiResponse localVarResponse = await FakeOuterBooleanSerializeAsyncWithHttpInfo(body); return localVarResponse.Data; } @@ -997,8 +1266,8 @@ public async System.Threading.Tasks.Task> FakeHea /// /// Thrown when fails to make API call /// Input boolean as post body (optional) - /// Task of ApiResponse (bool?) - public async System.Threading.Tasks.Task> FakeOuterBooleanSerializeAsyncWithHttpInfo (bool? body = null) + /// Task of ApiResponse (bool) + public async System.Threading.Tasks.Task> FakeOuterBooleanSerializeAsyncWithHttpInfo (bool? body = default(bool?)) { var localVarPath = "/fake/outer/boolean"; @@ -1046,9 +1315,9 @@ public async System.Threading.Tasks.Task> FakeHea if (exception != null) throw exception; } - return new ApiResponse(localVarStatusCode, + return new ApiResponse(localVarStatusCode, localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)), - (bool?) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(bool?))); + (bool) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(bool))); } /// @@ -1057,7 +1326,7 @@ public async System.Threading.Tasks.Task> FakeHea /// Thrown when fails to make API call /// Input composite as post body (optional) /// OuterComposite - public OuterComposite FakeOuterCompositeSerialize (OuterComposite outerComposite = null) + public OuterComposite FakeOuterCompositeSerialize (OuterComposite outerComposite = default(OuterComposite)) { ApiResponse localVarResponse = FakeOuterCompositeSerializeWithHttpInfo(outerComposite); return localVarResponse.Data; @@ -1069,7 +1338,7 @@ public OuterComposite FakeOuterCompositeSerialize (OuterComposite outerComposite /// Thrown when fails to make API call /// Input composite as post body (optional) /// ApiResponse of OuterComposite - public ApiResponse< OuterComposite > FakeOuterCompositeSerializeWithHttpInfo (OuterComposite outerComposite = null) + public ApiResponse FakeOuterCompositeSerializeWithHttpInfo (OuterComposite outerComposite = default(OuterComposite)) { var localVarPath = "/fake/outer/composite"; @@ -1128,7 +1397,7 @@ public ApiResponse< OuterComposite > FakeOuterCompositeSerializeWithHttpInfo (Ou /// Thrown when fails to make API call /// Input composite as post body (optional) /// Task of OuterComposite - public async System.Threading.Tasks.Task FakeOuterCompositeSerializeAsync (OuterComposite outerComposite = null) + public async System.Threading.Tasks.Task FakeOuterCompositeSerializeAsync (OuterComposite outerComposite = default(OuterComposite)) { ApiResponse localVarResponse = await FakeOuterCompositeSerializeAsyncWithHttpInfo(outerComposite); return localVarResponse.Data; @@ -1141,7 +1410,7 @@ public async System.Threading.Tasks.Task FakeOuterCompositeSeria /// Thrown when fails to make API call /// Input composite as post body (optional) /// Task of ApiResponse (OuterComposite) - public async System.Threading.Tasks.Task> FakeOuterCompositeSerializeAsyncWithHttpInfo (OuterComposite outerComposite = null) + public async System.Threading.Tasks.Task> FakeOuterCompositeSerializeAsyncWithHttpInfo (OuterComposite outerComposite = default(OuterComposite)) { var localVarPath = "/fake/outer/composite"; @@ -1199,10 +1468,10 @@ public async System.Threading.Tasks.Task> FakeOuterC /// /// Thrown when fails to make API call /// Input number as post body (optional) - /// decimal? - public decimal? FakeOuterNumberSerialize (decimal? body = null) + /// decimal + public decimal FakeOuterNumberSerialize (decimal? body = default(decimal?)) { - ApiResponse localVarResponse = FakeOuterNumberSerializeWithHttpInfo(body); + ApiResponse localVarResponse = FakeOuterNumberSerializeWithHttpInfo(body); return localVarResponse.Data; } @@ -1211,8 +1480,8 @@ public async System.Threading.Tasks.Task> FakeOuterC /// /// Thrown when fails to make API call /// Input number as post body (optional) - /// ApiResponse of decimal? - public ApiResponse< decimal? > FakeOuterNumberSerializeWithHttpInfo (decimal? body = null) + /// ApiResponse of decimal + public ApiResponse FakeOuterNumberSerializeWithHttpInfo (decimal? body = default(decimal?)) { var localVarPath = "/fake/outer/number"; @@ -1260,9 +1529,9 @@ public async System.Threading.Tasks.Task> FakeOuterC if (exception != null) throw exception; } - return new ApiResponse(localVarStatusCode, + return new ApiResponse(localVarStatusCode, localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)), - (decimal?) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(decimal?))); + (decimal) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(decimal))); } /// @@ -1270,10 +1539,10 @@ public async System.Threading.Tasks.Task> FakeOuterC /// /// Thrown when fails to make API call /// Input number as post body (optional) - /// Task of decimal? - public async System.Threading.Tasks.Task FakeOuterNumberSerializeAsync (decimal? body = null) + /// Task of decimal + public async System.Threading.Tasks.Task FakeOuterNumberSerializeAsync (decimal? body = default(decimal?)) { - ApiResponse localVarResponse = await FakeOuterNumberSerializeAsyncWithHttpInfo(body); + ApiResponse localVarResponse = await FakeOuterNumberSerializeAsyncWithHttpInfo(body); return localVarResponse.Data; } @@ -1283,8 +1552,8 @@ public async System.Threading.Tasks.Task> FakeOuterC /// /// Thrown when fails to make API call /// Input number as post body (optional) - /// Task of ApiResponse (decimal?) - public async System.Threading.Tasks.Task> FakeOuterNumberSerializeAsyncWithHttpInfo (decimal? body = null) + /// Task of ApiResponse (decimal) + public async System.Threading.Tasks.Task> FakeOuterNumberSerializeAsyncWithHttpInfo (decimal? body = default(decimal?)) { var localVarPath = "/fake/outer/number"; @@ -1332,9 +1601,9 @@ public async System.Threading.Tasks.Task> FakeOuterC if (exception != null) throw exception; } - return new ApiResponse(localVarStatusCode, + return new ApiResponse(localVarStatusCode, localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)), - (decimal?) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(decimal?))); + (decimal) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(decimal))); } /// @@ -1343,7 +1612,7 @@ public async System.Threading.Tasks.Task> FakeOuterC /// Thrown when fails to make API call /// Input string as post body (optional) /// string - public string FakeOuterStringSerialize (string body = null) + public string FakeOuterStringSerialize (string body = default(string)) { ApiResponse localVarResponse = FakeOuterStringSerializeWithHttpInfo(body); return localVarResponse.Data; @@ -1355,7 +1624,7 @@ public string FakeOuterStringSerialize (string body = null) /// Thrown when fails to make API call /// Input string as post body (optional) /// ApiResponse of string - public ApiResponse< string > FakeOuterStringSerializeWithHttpInfo (string body = null) + public ApiResponse FakeOuterStringSerializeWithHttpInfo (string body = default(string)) { var localVarPath = "/fake/outer/string"; @@ -1414,7 +1683,7 @@ public ApiResponse< string > FakeOuterStringSerializeWithHttpInfo (string body = /// Thrown when fails to make API call /// Input string as post body (optional) /// Task of string - public async System.Threading.Tasks.Task FakeOuterStringSerializeAsync (string body = null) + public async System.Threading.Tasks.Task FakeOuterStringSerializeAsync (string body = default(string)) { ApiResponse localVarResponse = await FakeOuterStringSerializeAsyncWithHttpInfo(body); return localVarResponse.Data; @@ -1427,7 +1696,7 @@ public async System.Threading.Tasks.Task FakeOuterStringSerializeAsync ( /// Thrown when fails to make API call /// Input string as post body (optional) /// Task of ApiResponse (string) - public async System.Threading.Tasks.Task> FakeOuterStringSerializeAsyncWithHttpInfo (string body = null) + public async System.Threading.Tasks.Task> FakeOuterStringSerializeAsyncWithHttpInfo (string body = default(string)) { var localVarPath = "/fake/outer/string"; @@ -1800,7 +2069,7 @@ public ModelClient TestClientModel (ModelClient modelClient) /// Thrown when fails to make API call /// client model /// ApiResponse of ModelClient - public ApiResponse< ModelClient > TestClientModelWithHttpInfo (ModelClient modelClient) + public ApiResponse TestClientModelWithHttpInfo (ModelClient modelClient) { // verify the required parameter 'modelClient' is set if (modelClient == null) @@ -1950,7 +2219,7 @@ public async System.Threading.Tasks.Task> TestClientMod /// None (optional) /// None (optional) /// - public void TestEndpointParameters (decimal? number, double? _double, string patternWithoutDelimiter, byte[] _byte, int? integer = null, int? int32 = null, long? int64 = null, float? _float = null, string _string = null, System.IO.Stream binary = null, DateTime? date = null, DateTime? dateTime = null, string password = null, string callback = null) + public void TestEndpointParameters (decimal number, double _double, string patternWithoutDelimiter, byte[] _byte, int? integer = default(int?), int? int32 = default(int?), long? int64 = default(long?), float? _float = default(float?), string _string = default(string), System.IO.Stream binary = default(System.IO.Stream), DateTime? date = default(DateTime?), DateTime? dateTime = default(DateTime?), string password = default(string), string callback = default(string)) { TestEndpointParametersWithHttpInfo(number, _double, patternWithoutDelimiter, _byte, integer, int32, int64, _float, _string, binary, date, dateTime, password, callback); } @@ -1974,7 +2243,7 @@ public void TestEndpointParameters (decimal? number, double? _double, string pat /// None (optional) /// None (optional) /// ApiResponse of Object(void) - public ApiResponse TestEndpointParametersWithHttpInfo (decimal? number, double? _double, string patternWithoutDelimiter, byte[] _byte, int? integer = null, int? int32 = null, long? int64 = null, float? _float = null, string _string = null, System.IO.Stream binary = null, DateTime? date = null, DateTime? dateTime = null, string password = null, string callback = null) + public ApiResponse TestEndpointParametersWithHttpInfo (decimal number, double _double, string patternWithoutDelimiter, byte[] _byte, int? integer = default(int?), int? int32 = default(int?), long? int64 = default(long?), float? _float = default(float?), string _string = default(string), System.IO.Stream binary = default(System.IO.Stream), DateTime? date = default(DateTime?), DateTime? dateTime = default(DateTime?), string password = default(string), string callback = default(string)) { // verify the required parameter 'number' is set if (number == null) @@ -2069,7 +2338,7 @@ public ApiResponse TestEndpointParametersWithHttpInfo (decimal? number, /// None (optional) /// None (optional) /// Task of void - public async System.Threading.Tasks.Task TestEndpointParametersAsync (decimal? number, double? _double, string patternWithoutDelimiter, byte[] _byte, int? integer = null, int? int32 = null, long? int64 = null, float? _float = null, string _string = null, System.IO.Stream binary = null, DateTime? date = null, DateTime? dateTime = null, string password = null, string callback = null) + public async System.Threading.Tasks.Task TestEndpointParametersAsync (decimal number, double _double, string patternWithoutDelimiter, byte[] _byte, int? integer = default(int?), int? int32 = default(int?), long? int64 = default(long?), float? _float = default(float?), string _string = default(string), System.IO.Stream binary = default(System.IO.Stream), DateTime? date = default(DateTime?), DateTime? dateTime = default(DateTime?), string password = default(string), string callback = default(string)) { await TestEndpointParametersAsyncWithHttpInfo(number, _double, patternWithoutDelimiter, _byte, integer, int32, int64, _float, _string, binary, date, dateTime, password, callback); @@ -2094,7 +2363,7 @@ public async System.Threading.Tasks.Task TestEndpointParametersAsync (decimal? n /// None (optional) /// None (optional) /// Task of ApiResponse - public async System.Threading.Tasks.Task> TestEndpointParametersAsyncWithHttpInfo (decimal? number, double? _double, string patternWithoutDelimiter, byte[] _byte, int? integer = null, int? int32 = null, long? int64 = null, float? _float = null, string _string = null, System.IO.Stream binary = null, DateTime? date = null, DateTime? dateTime = null, string password = null, string callback = null) + public async System.Threading.Tasks.Task> TestEndpointParametersAsyncWithHttpInfo (decimal number, double _double, string patternWithoutDelimiter, byte[] _byte, int? integer = default(int?), int? int32 = default(int?), long? int64 = default(long?), float? _float = default(float?), string _string = default(string), System.IO.Stream binary = default(System.IO.Stream), DateTime? date = default(DateTime?), DateTime? dateTime = default(DateTime?), string password = default(string), string callback = default(string)) { // verify the required parameter 'number' is set if (number == null) @@ -2183,7 +2452,7 @@ public async System.Threading.Tasks.Task> TestEndpointParame /// Form parameter enum test (string array) (optional, default to $) /// Form parameter enum test (string) (optional, default to -efg) /// - public void TestEnumParameters (List enumHeaderStringArray = null, string enumHeaderString = null, List enumQueryStringArray = null, string enumQueryString = null, int? enumQueryInteger = null, double? enumQueryDouble = null, List enumFormStringArray = null, string enumFormString = null) + public void TestEnumParameters (List enumHeaderStringArray = default(List), string enumHeaderString = default(string), List enumQueryStringArray = default(List), string enumQueryString = default(string), int? enumQueryInteger = default(int?), double? enumQueryDouble = default(double?), List enumFormStringArray = default(List), string enumFormString = default(string)) { TestEnumParametersWithHttpInfo(enumHeaderStringArray, enumHeaderString, enumQueryStringArray, enumQueryString, enumQueryInteger, enumQueryDouble, enumFormStringArray, enumFormString); } @@ -2201,7 +2470,7 @@ public void TestEnumParameters (List enumHeaderStringArray = null, strin /// Form parameter enum test (string array) (optional, default to $) /// Form parameter enum test (string) (optional, default to -efg) /// ApiResponse of Object(void) - public ApiResponse TestEnumParametersWithHttpInfo (List enumHeaderStringArray = null, string enumHeaderString = null, List enumQueryStringArray = null, string enumQueryString = null, int? enumQueryInteger = null, double? enumQueryDouble = null, List enumFormStringArray = null, string enumFormString = null) + public ApiResponse TestEnumParametersWithHttpInfo (List enumHeaderStringArray = default(List), string enumHeaderString = default(string), List enumQueryStringArray = default(List), string enumQueryString = default(string), int? enumQueryInteger = default(int?), double? enumQueryDouble = default(double?), List enumFormStringArray = default(List), string enumFormString = default(string)) { var localVarPath = "/fake"; @@ -2231,7 +2500,7 @@ public ApiResponse TestEnumParametersWithHttpInfo (List enumHead if (enumQueryDouble != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "enum_query_double", enumQueryDouble)); // query parameter if (enumHeaderStringArray != null) localVarHeaderParams.Add("enum_header_string_array", this.Configuration.ApiClient.ParameterToString(enumHeaderStringArray)); // header parameter if (enumHeaderString != null) localVarHeaderParams.Add("enum_header_string", this.Configuration.ApiClient.ParameterToString(enumHeaderString)); // header parameter - if (enumFormStringArray != null) localVarFormParams.Add("enum_form_string_array", this.Configuration.ApiClient.ParameterToString(enumFormStringArray)); // form parameter + if (enumFormStringArray != null) localVarFormParams.Add("enum_form_string_array", this.Configuration.ApiClient.Serialize(enumFormStringArray)); // form parameter if (enumFormString != null) localVarFormParams.Add("enum_form_string", this.Configuration.ApiClient.ParameterToString(enumFormString)); // form parameter @@ -2266,7 +2535,7 @@ public ApiResponse TestEnumParametersWithHttpInfo (List enumHead /// Form parameter enum test (string array) (optional, default to $) /// Form parameter enum test (string) (optional, default to -efg) /// Task of void - public async System.Threading.Tasks.Task TestEnumParametersAsync (List enumHeaderStringArray = null, string enumHeaderString = null, List enumQueryStringArray = null, string enumQueryString = null, int? enumQueryInteger = null, double? enumQueryDouble = null, List enumFormStringArray = null, string enumFormString = null) + public async System.Threading.Tasks.Task TestEnumParametersAsync (List enumHeaderStringArray = default(List), string enumHeaderString = default(string), List enumQueryStringArray = default(List), string enumQueryString = default(string), int? enumQueryInteger = default(int?), double? enumQueryDouble = default(double?), List enumFormStringArray = default(List), string enumFormString = default(string)) { await TestEnumParametersAsyncWithHttpInfo(enumHeaderStringArray, enumHeaderString, enumQueryStringArray, enumQueryString, enumQueryInteger, enumQueryDouble, enumFormStringArray, enumFormString); @@ -2285,7 +2554,7 @@ public async System.Threading.Tasks.Task TestEnumParametersAsync (List e /// Form parameter enum test (string array) (optional, default to $) /// Form parameter enum test (string) (optional, default to -efg) /// Task of ApiResponse - public async System.Threading.Tasks.Task> TestEnumParametersAsyncWithHttpInfo (List enumHeaderStringArray = null, string enumHeaderString = null, List enumQueryStringArray = null, string enumQueryString = null, int? enumQueryInteger = null, double? enumQueryDouble = null, List enumFormStringArray = null, string enumFormString = null) + public async System.Threading.Tasks.Task> TestEnumParametersAsyncWithHttpInfo (List enumHeaderStringArray = default(List), string enumHeaderString = default(string), List enumQueryStringArray = default(List), string enumQueryString = default(string), int? enumQueryInteger = default(int?), double? enumQueryDouble = default(double?), List enumFormStringArray = default(List), string enumFormString = default(string)) { var localVarPath = "/fake"; @@ -2315,7 +2584,7 @@ public async System.Threading.Tasks.Task> TestEnumParameters if (enumQueryDouble != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "enum_query_double", enumQueryDouble)); // query parameter if (enumHeaderStringArray != null) localVarHeaderParams.Add("enum_header_string_array", this.Configuration.ApiClient.ParameterToString(enumHeaderStringArray)); // header parameter if (enumHeaderString != null) localVarHeaderParams.Add("enum_header_string", this.Configuration.ApiClient.ParameterToString(enumHeaderString)); // header parameter - if (enumFormStringArray != null) localVarFormParams.Add("enum_form_string_array", this.Configuration.ApiClient.ParameterToString(enumFormStringArray)); // form parameter + if (enumFormStringArray != null) localVarFormParams.Add("enum_form_string_array", this.Configuration.ApiClient.Serialize(enumFormStringArray)); // form parameter if (enumFormString != null) localVarFormParams.Add("enum_form_string", this.Configuration.ApiClient.ParameterToString(enumFormString)); // form parameter @@ -2348,7 +2617,7 @@ public async System.Threading.Tasks.Task> TestEnumParameters /// Boolean in group parameters (optional) /// Integer in group parameters (optional) /// - public void TestGroupParameters (int? requiredStringGroup, bool? requiredBooleanGroup, long? requiredInt64Group, int? stringGroup = null, bool? booleanGroup = null, long? int64Group = null) + public void TestGroupParameters (int requiredStringGroup, bool requiredBooleanGroup, long requiredInt64Group, int? stringGroup = default(int?), bool? booleanGroup = default(bool?), long? int64Group = default(long?)) { TestGroupParametersWithHttpInfo(requiredStringGroup, requiredBooleanGroup, requiredInt64Group, stringGroup, booleanGroup, int64Group); } @@ -2364,7 +2633,7 @@ public void TestGroupParameters (int? requiredStringGroup, bool? requiredBoolean /// Boolean in group parameters (optional) /// Integer in group parameters (optional) /// ApiResponse of Object(void) - public ApiResponse TestGroupParametersWithHttpInfo (int? requiredStringGroup, bool? requiredBooleanGroup, long? requiredInt64Group, int? stringGroup = null, bool? booleanGroup = null, long? int64Group = null) + public ApiResponse TestGroupParametersWithHttpInfo (int requiredStringGroup, bool requiredBooleanGroup, long requiredInt64Group, int? stringGroup = default(int?), bool? booleanGroup = default(bool?), long? int64Group = default(long?)) { // verify the required parameter 'requiredStringGroup' is set if (requiredStringGroup == null) @@ -2404,10 +2673,10 @@ public ApiResponse TestGroupParametersWithHttpInfo (int? requiredStringG if (booleanGroup != null) localVarHeaderParams.Add("boolean_group", this.Configuration.ApiClient.ParameterToString(booleanGroup)); // header parameter // authentication (bearer_test) required - // http basic authentication required - if (!String.IsNullOrEmpty(this.Configuration.Username) || !String.IsNullOrEmpty(this.Configuration.Password)) + // http beerer authentication required + if (!String.IsNullOrEmpty(this.Configuration.AccessToken)) { - localVarHeaderParams["Authorization"] = "Basic " + ApiClient.Base64Encode(this.Configuration.Username + ":" + this.Configuration.Password); + localVarHeaderParams["Authorization"] = "Bearer " + this.Configuration.AccessToken; } // make the HTTP request @@ -2439,7 +2708,7 @@ public ApiResponse TestGroupParametersWithHttpInfo (int? requiredStringG /// Boolean in group parameters (optional) /// Integer in group parameters (optional) /// Task of void - public async System.Threading.Tasks.Task TestGroupParametersAsync (int? requiredStringGroup, bool? requiredBooleanGroup, long? requiredInt64Group, int? stringGroup = null, bool? booleanGroup = null, long? int64Group = null) + public async System.Threading.Tasks.Task TestGroupParametersAsync (int requiredStringGroup, bool requiredBooleanGroup, long requiredInt64Group, int? stringGroup = default(int?), bool? booleanGroup = default(bool?), long? int64Group = default(long?)) { await TestGroupParametersAsyncWithHttpInfo(requiredStringGroup, requiredBooleanGroup, requiredInt64Group, stringGroup, booleanGroup, int64Group); @@ -2456,7 +2725,7 @@ public async System.Threading.Tasks.Task TestGroupParametersAsync (int? required /// Boolean in group parameters (optional) /// Integer in group parameters (optional) /// Task of ApiResponse - public async System.Threading.Tasks.Task> TestGroupParametersAsyncWithHttpInfo (int? requiredStringGroup, bool? requiredBooleanGroup, long? requiredInt64Group, int? stringGroup = null, bool? booleanGroup = null, long? int64Group = null) + public async System.Threading.Tasks.Task> TestGroupParametersAsyncWithHttpInfo (int requiredStringGroup, bool requiredBooleanGroup, long requiredInt64Group, int? stringGroup = default(int?), bool? booleanGroup = default(bool?), long? int64Group = default(long?)) { // verify the required parameter 'requiredStringGroup' is set if (requiredStringGroup == null) @@ -2496,10 +2765,10 @@ public async System.Threading.Tasks.Task> TestGroupParameter if (booleanGroup != null) localVarHeaderParams.Add("boolean_group", this.Configuration.ApiClient.ParameterToString(booleanGroup)); // header parameter // authentication (bearer_test) required - // http basic authentication required - if (!String.IsNullOrEmpty(this.Configuration.Username) || !String.IsNullOrEmpty(this.Configuration.Password)) + // http bearer authentication required + if (!String.IsNullOrEmpty(this.Configuration.AccessToken)) { - localVarHeaderParams["Authorization"] = "Basic " + ApiClient.Base64Encode(this.Configuration.Username + ":" + this.Configuration.Password); + localVarHeaderParams["Authorization"] = "Bearer " + this.Configuration.AccessToken; } // make the HTTP request @@ -2808,5 +3077,182 @@ public async System.Threading.Tasks.Task> TestJsonFormDataAs null); } + /// + /// To test the collection format in query parameters + /// + /// Thrown when fails to make API call + /// + /// + /// + /// + /// + /// + public void TestQueryParameterCollectionFormat (List pipe, List ioutil, List http, List url, List context) + { + TestQueryParameterCollectionFormatWithHttpInfo(pipe, ioutil, http, url, context); + } + + /// + /// To test the collection format in query parameters + /// + /// Thrown when fails to make API call + /// + /// + /// + /// + /// + /// ApiResponse of Object(void) + public ApiResponse TestQueryParameterCollectionFormatWithHttpInfo (List pipe, List ioutil, List http, List url, List context) + { + // verify the required parameter 'pipe' is set + if (pipe == null) + throw new ApiException(400, "Missing required parameter 'pipe' when calling FakeApi->TestQueryParameterCollectionFormat"); + // verify the required parameter 'ioutil' is set + if (ioutil == null) + throw new ApiException(400, "Missing required parameter 'ioutil' when calling FakeApi->TestQueryParameterCollectionFormat"); + // verify the required parameter 'http' is set + if (http == null) + throw new ApiException(400, "Missing required parameter 'http' when calling FakeApi->TestQueryParameterCollectionFormat"); + // verify the required parameter 'url' is set + if (url == null) + throw new ApiException(400, "Missing required parameter 'url' when calling FakeApi->TestQueryParameterCollectionFormat"); + // verify the required parameter 'context' is set + if (context == null) + throw new ApiException(400, "Missing required parameter 'context' when calling FakeApi->TestQueryParameterCollectionFormat"); + + var localVarPath = "/fake/test-query-paramters"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new List>(); + var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new Dictionary(); + Object localVarPostBody = null; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + }; + String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + }; + String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + if (pipe != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("multi", "pipe", pipe)); // query parameter + if (ioutil != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "ioutil", ioutil)); // query parameter + if (http != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("space", "http", http)); // query parameter + if (url != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "url", url)); // query parameter + if (context != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("multi", "context", context)); // query parameter + + + // make the HTTP request + IRestResponse localVarResponse = (IRestResponse) this.Configuration.ApiClient.CallApi(localVarPath, + Method.PUT, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, + localVarPathParams, localVarHttpContentType); + + int localVarStatusCode = (int) localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("TestQueryParameterCollectionFormat", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)), + null); + } + + /// + /// To test the collection format in query parameters + /// + /// Thrown when fails to make API call + /// + /// + /// + /// + /// + /// Task of void + public async System.Threading.Tasks.Task TestQueryParameterCollectionFormatAsync (List pipe, List ioutil, List http, List url, List context) + { + await TestQueryParameterCollectionFormatAsyncWithHttpInfo(pipe, ioutil, http, url, context); + + } + + /// + /// To test the collection format in query parameters + /// + /// Thrown when fails to make API call + /// + /// + /// + /// + /// + /// Task of ApiResponse + public async System.Threading.Tasks.Task> TestQueryParameterCollectionFormatAsyncWithHttpInfo (List pipe, List ioutil, List http, List url, List context) + { + // verify the required parameter 'pipe' is set + if (pipe == null) + throw new ApiException(400, "Missing required parameter 'pipe' when calling FakeApi->TestQueryParameterCollectionFormat"); + // verify the required parameter 'ioutil' is set + if (ioutil == null) + throw new ApiException(400, "Missing required parameter 'ioutil' when calling FakeApi->TestQueryParameterCollectionFormat"); + // verify the required parameter 'http' is set + if (http == null) + throw new ApiException(400, "Missing required parameter 'http' when calling FakeApi->TestQueryParameterCollectionFormat"); + // verify the required parameter 'url' is set + if (url == null) + throw new ApiException(400, "Missing required parameter 'url' when calling FakeApi->TestQueryParameterCollectionFormat"); + // verify the required parameter 'context' is set + if (context == null) + throw new ApiException(400, "Missing required parameter 'context' when calling FakeApi->TestQueryParameterCollectionFormat"); + + var localVarPath = "/fake/test-query-paramters"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new List>(); + var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new Dictionary(); + Object localVarPostBody = null; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + }; + String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + }; + String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + if (pipe != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("multi", "pipe", pipe)); // query parameter + if (ioutil != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "ioutil", ioutil)); // query parameter + if (http != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("space", "http", http)); // query parameter + if (url != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "url", url)); // query parameter + if (context != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("multi", "context", context)); // query parameter + + + // make the HTTP request + IRestResponse localVarResponse = (IRestResponse) await this.Configuration.ApiClient.CallApiAsync(localVarPath, + Method.PUT, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, + localVarPathParams, localVarHttpContentType); + + int localVarStatusCode = (int) localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("TestQueryParameterCollectionFormat", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)), + null); + } + } } diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs index 9ff2cf1d8611..3e40d789b421 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -197,7 +197,7 @@ public ModelClient TestClassname (ModelClient modelClient) /// Thrown when fails to make API call /// client model /// ApiResponse of ModelClient - public ApiResponse< ModelClient > TestClassnameWithHttpInfo (ModelClient modelClient) + public ApiResponse TestClassnameWithHttpInfo (ModelClient modelClient) { // verify the required parameter 'modelClient' is set if (modelClient == null) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Api/PetApi.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Api/PetApi.cs index 2385be9dc63f..06279f072038 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Api/PetApi.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Api/PetApi.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -55,7 +55,7 @@ public interface IPetApi : IApiAccessor /// Pet id to delete /// (optional) /// - void DeletePet (long? petId, string apiKey = null); + void DeletePet (long petId, string apiKey = default(string)); /// /// Deletes a pet @@ -67,7 +67,7 @@ public interface IPetApi : IApiAccessor /// Pet id to delete /// (optional) /// ApiResponse of Object(void) - ApiResponse DeletePetWithHttpInfo (long? petId, string apiKey = null); + ApiResponse DeletePetWithHttpInfo (long petId, string apiKey = default(string)); /// /// Finds Pets by status /// @@ -119,7 +119,7 @@ public interface IPetApi : IApiAccessor /// Thrown when fails to make API call /// ID of pet to return /// Pet - Pet GetPetById (long? petId); + Pet GetPetById (long petId); /// /// Find pet by ID @@ -130,7 +130,7 @@ public interface IPetApi : IApiAccessor /// Thrown when fails to make API call /// ID of pet to return /// ApiResponse of Pet - ApiResponse GetPetByIdWithHttpInfo (long? petId); + ApiResponse GetPetByIdWithHttpInfo (long petId); /// /// Update an existing pet /// @@ -163,7 +163,7 @@ public interface IPetApi : IApiAccessor /// Updated name of the pet (optional) /// Updated status of the pet (optional) /// - void UpdatePetWithForm (long? petId, string name = null, string status = null); + void UpdatePetWithForm (long petId, string name = default(string), string status = default(string)); /// /// Updates a pet in the store with form data @@ -176,7 +176,7 @@ public interface IPetApi : IApiAccessor /// Updated name of the pet (optional) /// Updated status of the pet (optional) /// ApiResponse of Object(void) - ApiResponse UpdatePetWithFormWithHttpInfo (long? petId, string name = null, string status = null); + ApiResponse UpdatePetWithFormWithHttpInfo (long petId, string name = default(string), string status = default(string)); /// /// uploads an image /// @@ -188,7 +188,7 @@ public interface IPetApi : IApiAccessor /// Additional data to pass to server (optional) /// file to upload (optional) /// ApiResponse - ApiResponse UploadFile (long? petId, string additionalMetadata = null, System.IO.Stream file = null); + ApiResponse UploadFile (long petId, string additionalMetadata = default(string), System.IO.Stream file = default(System.IO.Stream)); /// /// uploads an image @@ -201,7 +201,7 @@ public interface IPetApi : IApiAccessor /// Additional data to pass to server (optional) /// file to upload (optional) /// ApiResponse of ApiResponse - ApiResponse UploadFileWithHttpInfo (long? petId, string additionalMetadata = null, System.IO.Stream file = null); + ApiResponse UploadFileWithHttpInfo (long petId, string additionalMetadata = default(string), System.IO.Stream file = default(System.IO.Stream)); /// /// uploads an image (required) /// @@ -213,7 +213,7 @@ public interface IPetApi : IApiAccessor /// file to upload /// Additional data to pass to server (optional) /// ApiResponse - ApiResponse UploadFileWithRequiredFile (long? petId, System.IO.Stream requiredFile, string additionalMetadata = null); + ApiResponse UploadFileWithRequiredFile (long petId, System.IO.Stream requiredFile, string additionalMetadata = default(string)); /// /// uploads an image (required) @@ -226,7 +226,7 @@ public interface IPetApi : IApiAccessor /// file to upload /// Additional data to pass to server (optional) /// ApiResponse of ApiResponse - ApiResponse UploadFileWithRequiredFileWithHttpInfo (long? petId, System.IO.Stream requiredFile, string additionalMetadata = null); + ApiResponse UploadFileWithRequiredFileWithHttpInfo (long petId, System.IO.Stream requiredFile, string additionalMetadata = default(string)); #endregion Synchronous Operations #region Asynchronous Operations /// @@ -260,7 +260,7 @@ public interface IPetApi : IApiAccessor /// Pet id to delete /// (optional) /// Task of void - System.Threading.Tasks.Task DeletePetAsync (long? petId, string apiKey = null); + System.Threading.Tasks.Task DeletePetAsync (long petId, string apiKey = default(string)); /// /// Deletes a pet @@ -272,7 +272,7 @@ public interface IPetApi : IApiAccessor /// Pet id to delete /// (optional) /// Task of ApiResponse - System.Threading.Tasks.Task> DeletePetAsyncWithHttpInfo (long? petId, string apiKey = null); + System.Threading.Tasks.Task> DeletePetAsyncWithHttpInfo (long petId, string apiKey = default(string)); /// /// Finds Pets by status /// @@ -324,7 +324,7 @@ public interface IPetApi : IApiAccessor /// Thrown when fails to make API call /// ID of pet to return /// Task of Pet - System.Threading.Tasks.Task GetPetByIdAsync (long? petId); + System.Threading.Tasks.Task GetPetByIdAsync (long petId); /// /// Find pet by ID @@ -335,7 +335,7 @@ public interface IPetApi : IApiAccessor /// Thrown when fails to make API call /// ID of pet to return /// Task of ApiResponse (Pet) - System.Threading.Tasks.Task> GetPetByIdAsyncWithHttpInfo (long? petId); + System.Threading.Tasks.Task> GetPetByIdAsyncWithHttpInfo (long petId); /// /// Update an existing pet /// @@ -368,7 +368,7 @@ public interface IPetApi : IApiAccessor /// Updated name of the pet (optional) /// Updated status of the pet (optional) /// Task of void - System.Threading.Tasks.Task UpdatePetWithFormAsync (long? petId, string name = null, string status = null); + System.Threading.Tasks.Task UpdatePetWithFormAsync (long petId, string name = default(string), string status = default(string)); /// /// Updates a pet in the store with form data @@ -381,7 +381,7 @@ public interface IPetApi : IApiAccessor /// Updated name of the pet (optional) /// Updated status of the pet (optional) /// Task of ApiResponse - System.Threading.Tasks.Task> UpdatePetWithFormAsyncWithHttpInfo (long? petId, string name = null, string status = null); + System.Threading.Tasks.Task> UpdatePetWithFormAsyncWithHttpInfo (long petId, string name = default(string), string status = default(string)); /// /// uploads an image /// @@ -393,7 +393,7 @@ public interface IPetApi : IApiAccessor /// Additional data to pass to server (optional) /// file to upload (optional) /// Task of ApiResponse - System.Threading.Tasks.Task UploadFileAsync (long? petId, string additionalMetadata = null, System.IO.Stream file = null); + System.Threading.Tasks.Task UploadFileAsync (long petId, string additionalMetadata = default(string), System.IO.Stream file = default(System.IO.Stream)); /// /// uploads an image @@ -406,7 +406,7 @@ public interface IPetApi : IApiAccessor /// Additional data to pass to server (optional) /// file to upload (optional) /// Task of ApiResponse (ApiResponse) - System.Threading.Tasks.Task> UploadFileAsyncWithHttpInfo (long? petId, string additionalMetadata = null, System.IO.Stream file = null); + System.Threading.Tasks.Task> UploadFileAsyncWithHttpInfo (long petId, string additionalMetadata = default(string), System.IO.Stream file = default(System.IO.Stream)); /// /// uploads an image (required) /// @@ -418,7 +418,7 @@ public interface IPetApi : IApiAccessor /// file to upload /// Additional data to pass to server (optional) /// Task of ApiResponse - System.Threading.Tasks.Task UploadFileWithRequiredFileAsync (long? petId, System.IO.Stream requiredFile, string additionalMetadata = null); + System.Threading.Tasks.Task UploadFileWithRequiredFileAsync (long petId, System.IO.Stream requiredFile, string additionalMetadata = default(string)); /// /// uploads an image (required) @@ -431,7 +431,7 @@ public interface IPetApi : IApiAccessor /// file to upload /// Additional data to pass to server (optional) /// Task of ApiResponse (ApiResponse) - System.Threading.Tasks.Task> UploadFileWithRequiredFileAsyncWithHttpInfo (long? petId, System.IO.Stream requiredFile, string additionalMetadata = null); + System.Threading.Tasks.Task> UploadFileWithRequiredFileAsyncWithHttpInfo (long petId, System.IO.Stream requiredFile, string additionalMetadata = default(string)); #endregion Asynchronous Operations } @@ -709,7 +709,7 @@ public async System.Threading.Tasks.Task> AddPetAsyncWithHtt /// Pet id to delete /// (optional) /// - public void DeletePet (long? petId, string apiKey = null) + public void DeletePet (long petId, string apiKey = default(string)) { DeletePetWithHttpInfo(petId, apiKey); } @@ -721,7 +721,7 @@ public void DeletePet (long? petId, string apiKey = null) /// Pet id to delete /// (optional) /// ApiResponse of Object(void) - public ApiResponse DeletePetWithHttpInfo (long? petId, string apiKey = null) + public ApiResponse DeletePetWithHttpInfo (long petId, string apiKey = default(string)) { // verify the required parameter 'petId' is set if (petId == null) @@ -782,7 +782,7 @@ public ApiResponse DeletePetWithHttpInfo (long? petId, string apiKey = n /// Pet id to delete /// (optional) /// Task of void - public async System.Threading.Tasks.Task DeletePetAsync (long? petId, string apiKey = null) + public async System.Threading.Tasks.Task DeletePetAsync (long petId, string apiKey = default(string)) { await DeletePetAsyncWithHttpInfo(petId, apiKey); @@ -795,7 +795,7 @@ public async System.Threading.Tasks.Task DeletePetAsync (long? petId, string api /// Pet id to delete /// (optional) /// Task of ApiResponse - public async System.Threading.Tasks.Task> DeletePetAsyncWithHttpInfo (long? petId, string apiKey = null) + public async System.Threading.Tasks.Task> DeletePetAsyncWithHttpInfo (long petId, string apiKey = default(string)) { // verify the required parameter 'petId' is set if (petId == null) @@ -867,7 +867,7 @@ public List FindPetsByStatus (List status) /// Thrown when fails to make API call /// Status values that need to be considered for filter /// ApiResponse of List<Pet> - public ApiResponse< List > FindPetsByStatusWithHttpInfo (List status) + public ApiResponse> FindPetsByStatusWithHttpInfo (List status) { // verify the required parameter 'status' is set if (status == null) @@ -1014,7 +1014,7 @@ public List FindPetsByTags (List tags) /// Thrown when fails to make API call /// Tags to filter by /// ApiResponse of List<Pet> - public ApiResponse< List > FindPetsByTagsWithHttpInfo (List tags) + public ApiResponse> FindPetsByTagsWithHttpInfo (List tags) { // verify the required parameter 'tags' is set if (tags == null) @@ -1149,7 +1149,7 @@ public async System.Threading.Tasks.Task>> FindPetsByTagsA /// Thrown when fails to make API call /// ID of pet to return /// Pet - public Pet GetPetById (long? petId) + public Pet GetPetById (long petId) { ApiResponse localVarResponse = GetPetByIdWithHttpInfo(petId); return localVarResponse.Data; @@ -1161,7 +1161,7 @@ public Pet GetPetById (long? petId) /// Thrown when fails to make API call /// ID of pet to return /// ApiResponse of Pet - public ApiResponse< Pet > GetPetByIdWithHttpInfo (long? petId) + public ApiResponse GetPetByIdWithHttpInfo (long petId) { // verify the required parameter 'petId' is set if (petId == null) @@ -1221,7 +1221,7 @@ public ApiResponse< Pet > GetPetByIdWithHttpInfo (long? petId) /// Thrown when fails to make API call /// ID of pet to return /// Task of Pet - public async System.Threading.Tasks.Task GetPetByIdAsync (long? petId) + public async System.Threading.Tasks.Task GetPetByIdAsync (long petId) { ApiResponse localVarResponse = await GetPetByIdAsyncWithHttpInfo(petId); return localVarResponse.Data; @@ -1234,7 +1234,7 @@ public async System.Threading.Tasks.Task GetPetByIdAsync (long? petId) /// Thrown when fails to make API call /// ID of pet to return /// Task of ApiResponse (Pet) - public async System.Threading.Tasks.Task> GetPetByIdAsyncWithHttpInfo (long? petId) + public async System.Threading.Tasks.Task> GetPetByIdAsyncWithHttpInfo (long petId) { // verify the required parameter 'petId' is set if (petId == null) @@ -1455,7 +1455,7 @@ public async System.Threading.Tasks.Task> UpdatePetAsyncWith /// Updated name of the pet (optional) /// Updated status of the pet (optional) /// - public void UpdatePetWithForm (long? petId, string name = null, string status = null) + public void UpdatePetWithForm (long petId, string name = default(string), string status = default(string)) { UpdatePetWithFormWithHttpInfo(petId, name, status); } @@ -1468,7 +1468,7 @@ public void UpdatePetWithForm (long? petId, string name = null, string status = /// Updated name of the pet (optional) /// Updated status of the pet (optional) /// ApiResponse of Object(void) - public ApiResponse UpdatePetWithFormWithHttpInfo (long? petId, string name = null, string status = null) + public ApiResponse UpdatePetWithFormWithHttpInfo (long petId, string name = default(string), string status = default(string)) { // verify the required parameter 'petId' is set if (petId == null) @@ -1532,7 +1532,7 @@ public ApiResponse UpdatePetWithFormWithHttpInfo (long? petId, string na /// Updated name of the pet (optional) /// Updated status of the pet (optional) /// Task of void - public async System.Threading.Tasks.Task UpdatePetWithFormAsync (long? petId, string name = null, string status = null) + public async System.Threading.Tasks.Task UpdatePetWithFormAsync (long petId, string name = default(string), string status = default(string)) { await UpdatePetWithFormAsyncWithHttpInfo(petId, name, status); @@ -1546,7 +1546,7 @@ public async System.Threading.Tasks.Task UpdatePetWithFormAsync (long? petId, st /// Updated name of the pet (optional) /// Updated status of the pet (optional) /// Task of ApiResponse - public async System.Threading.Tasks.Task> UpdatePetWithFormAsyncWithHttpInfo (long? petId, string name = null, string status = null) + public async System.Threading.Tasks.Task> UpdatePetWithFormAsyncWithHttpInfo (long petId, string name = default(string), string status = default(string)) { // verify the required parameter 'petId' is set if (petId == null) @@ -1610,7 +1610,7 @@ public async System.Threading.Tasks.Task> UpdatePetWithFormA /// Additional data to pass to server (optional) /// file to upload (optional) /// ApiResponse - public ApiResponse UploadFile (long? petId, string additionalMetadata = null, System.IO.Stream file = null) + public ApiResponse UploadFile (long petId, string additionalMetadata = default(string), System.IO.Stream file = default(System.IO.Stream)) { ApiResponse localVarResponse = UploadFileWithHttpInfo(petId, additionalMetadata, file); return localVarResponse.Data; @@ -1624,7 +1624,7 @@ public ApiResponse UploadFile (long? petId, string additionalMetadata = null, Sy /// Additional data to pass to server (optional) /// file to upload (optional) /// ApiResponse of ApiResponse - public ApiResponse< ApiResponse > UploadFileWithHttpInfo (long? petId, string additionalMetadata = null, System.IO.Stream file = null) + public ApiResponse UploadFileWithHttpInfo (long petId, string additionalMetadata = default(string), System.IO.Stream file = default(System.IO.Stream)) { // verify the required parameter 'petId' is set if (petId == null) @@ -1689,7 +1689,7 @@ public ApiResponse< ApiResponse > UploadFileWithHttpInfo (long? petId, string ad /// Additional data to pass to server (optional) /// file to upload (optional) /// Task of ApiResponse - public async System.Threading.Tasks.Task UploadFileAsync (long? petId, string additionalMetadata = null, System.IO.Stream file = null) + public async System.Threading.Tasks.Task UploadFileAsync (long petId, string additionalMetadata = default(string), System.IO.Stream file = default(System.IO.Stream)) { ApiResponse localVarResponse = await UploadFileAsyncWithHttpInfo(petId, additionalMetadata, file); return localVarResponse.Data; @@ -1704,7 +1704,7 @@ public async System.Threading.Tasks.Task UploadFileAsync (long? pet /// Additional data to pass to server (optional) /// file to upload (optional) /// Task of ApiResponse (ApiResponse) - public async System.Threading.Tasks.Task> UploadFileAsyncWithHttpInfo (long? petId, string additionalMetadata = null, System.IO.Stream file = null) + public async System.Threading.Tasks.Task> UploadFileAsyncWithHttpInfo (long petId, string additionalMetadata = default(string), System.IO.Stream file = default(System.IO.Stream)) { // verify the required parameter 'petId' is set if (petId == null) @@ -1769,7 +1769,7 @@ public async System.Threading.Tasks.Task> UploadFileAsy /// file to upload /// Additional data to pass to server (optional) /// ApiResponse - public ApiResponse UploadFileWithRequiredFile (long? petId, System.IO.Stream requiredFile, string additionalMetadata = null) + public ApiResponse UploadFileWithRequiredFile (long petId, System.IO.Stream requiredFile, string additionalMetadata = default(string)) { ApiResponse localVarResponse = UploadFileWithRequiredFileWithHttpInfo(petId, requiredFile, additionalMetadata); return localVarResponse.Data; @@ -1783,7 +1783,7 @@ public ApiResponse UploadFileWithRequiredFile (long? petId, System.IO.Stream req /// file to upload /// Additional data to pass to server (optional) /// ApiResponse of ApiResponse - public ApiResponse< ApiResponse > UploadFileWithRequiredFileWithHttpInfo (long? petId, System.IO.Stream requiredFile, string additionalMetadata = null) + public ApiResponse UploadFileWithRequiredFileWithHttpInfo (long petId, System.IO.Stream requiredFile, string additionalMetadata = default(string)) { // verify the required parameter 'petId' is set if (petId == null) @@ -1851,7 +1851,7 @@ public ApiResponse< ApiResponse > UploadFileWithRequiredFileWithHttpInfo (long? /// file to upload /// Additional data to pass to server (optional) /// Task of ApiResponse - public async System.Threading.Tasks.Task UploadFileWithRequiredFileAsync (long? petId, System.IO.Stream requiredFile, string additionalMetadata = null) + public async System.Threading.Tasks.Task UploadFileWithRequiredFileAsync (long petId, System.IO.Stream requiredFile, string additionalMetadata = default(string)) { ApiResponse localVarResponse = await UploadFileWithRequiredFileAsyncWithHttpInfo(petId, requiredFile, additionalMetadata); return localVarResponse.Data; @@ -1866,7 +1866,7 @@ public async System.Threading.Tasks.Task UploadFileWithRequiredFile /// file to upload /// Additional data to pass to server (optional) /// Task of ApiResponse (ApiResponse) - public async System.Threading.Tasks.Task> UploadFileWithRequiredFileAsyncWithHttpInfo (long? petId, System.IO.Stream requiredFile, string additionalMetadata = null) + public async System.Threading.Tasks.Task> UploadFileWithRequiredFileAsyncWithHttpInfo (long petId, System.IO.Stream requiredFile, string additionalMetadata = default(string)) { // verify the required parameter 'petId' is set if (petId == null) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Api/StoreApi.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Api/StoreApi.cs index e84290e5a6b9..5929ce68a649 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Api/StoreApi.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Api/StoreApi.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -52,8 +52,8 @@ public interface IStoreApi : IApiAccessor /// Returns a map of status codes to quantities /// /// Thrown when fails to make API call - /// Dictionary<string, int?> - Dictionary GetInventory (); + /// Dictionary<string, int> + Dictionary GetInventory (); /// /// Returns pet inventories by status @@ -62,8 +62,8 @@ public interface IStoreApi : IApiAccessor /// Returns a map of status codes to quantities /// /// Thrown when fails to make API call - /// ApiResponse of Dictionary<string, int?> - ApiResponse> GetInventoryWithHttpInfo (); + /// ApiResponse of Dictionary<string, int> + ApiResponse> GetInventoryWithHttpInfo (); /// /// Find purchase order by ID /// @@ -73,7 +73,7 @@ public interface IStoreApi : IApiAccessor /// Thrown when fails to make API call /// ID of pet that needs to be fetched /// Order - Order GetOrderById (long? orderId); + Order GetOrderById (long orderId); /// /// Find purchase order by ID @@ -84,7 +84,7 @@ public interface IStoreApi : IApiAccessor /// Thrown when fails to make API call /// ID of pet that needs to be fetched /// ApiResponse of Order - ApiResponse GetOrderByIdWithHttpInfo (long? orderId); + ApiResponse GetOrderByIdWithHttpInfo (long orderId); /// /// Place an order for a pet /// @@ -136,8 +136,8 @@ public interface IStoreApi : IApiAccessor /// Returns a map of status codes to quantities /// /// Thrown when fails to make API call - /// Task of Dictionary<string, int?> - System.Threading.Tasks.Task> GetInventoryAsync (); + /// Task of Dictionary<string, int> + System.Threading.Tasks.Task> GetInventoryAsync (); /// /// Returns pet inventories by status @@ -146,8 +146,8 @@ public interface IStoreApi : IApiAccessor /// Returns a map of status codes to quantities /// /// Thrown when fails to make API call - /// Task of ApiResponse (Dictionary<string, int?>) - System.Threading.Tasks.Task>> GetInventoryAsyncWithHttpInfo (); + /// Task of ApiResponse (Dictionary<string, int>) + System.Threading.Tasks.Task>> GetInventoryAsyncWithHttpInfo (); /// /// Find purchase order by ID /// @@ -157,7 +157,7 @@ public interface IStoreApi : IApiAccessor /// Thrown when fails to make API call /// ID of pet that needs to be fetched /// Task of Order - System.Threading.Tasks.Task GetOrderByIdAsync (long? orderId); + System.Threading.Tasks.Task GetOrderByIdAsync (long orderId); /// /// Find purchase order by ID @@ -168,7 +168,7 @@ public interface IStoreApi : IApiAccessor /// Thrown when fails to make API call /// ID of pet that needs to be fetched /// Task of ApiResponse (Order) - System.Threading.Tasks.Task> GetOrderByIdAsyncWithHttpInfo (long? orderId); + System.Threading.Tasks.Task> GetOrderByIdAsyncWithHttpInfo (long orderId); /// /// Place an order for a pet /// @@ -434,10 +434,10 @@ public async System.Threading.Tasks.Task> DeleteOrderAsyncWi /// Returns pet inventories by status Returns a map of status codes to quantities /// /// Thrown when fails to make API call - /// Dictionary<string, int?> - public Dictionary GetInventory () + /// Dictionary<string, int> + public Dictionary GetInventory () { - ApiResponse> localVarResponse = GetInventoryWithHttpInfo(); + ApiResponse> localVarResponse = GetInventoryWithHttpInfo(); return localVarResponse.Data; } @@ -445,8 +445,8 @@ public async System.Threading.Tasks.Task> DeleteOrderAsyncWi /// Returns pet inventories by status Returns a map of status codes to quantities /// /// Thrown when fails to make API call - /// ApiResponse of Dictionary<string, int?> - public ApiResponse< Dictionary > GetInventoryWithHttpInfo () + /// ApiResponse of Dictionary<string, int> + public ApiResponse> GetInventoryWithHttpInfo () { var localVarPath = "/store/inventory"; @@ -490,19 +490,19 @@ public async System.Threading.Tasks.Task> DeleteOrderAsyncWi if (exception != null) throw exception; } - return new ApiResponse>(localVarStatusCode, + return new ApiResponse>(localVarStatusCode, localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)), - (Dictionary) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(Dictionary))); + (Dictionary) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(Dictionary))); } /// /// Returns pet inventories by status Returns a map of status codes to quantities /// /// Thrown when fails to make API call - /// Task of Dictionary<string, int?> - public async System.Threading.Tasks.Task> GetInventoryAsync () + /// Task of Dictionary<string, int> + public async System.Threading.Tasks.Task> GetInventoryAsync () { - ApiResponse> localVarResponse = await GetInventoryAsyncWithHttpInfo(); + ApiResponse> localVarResponse = await GetInventoryAsyncWithHttpInfo(); return localVarResponse.Data; } @@ -511,8 +511,8 @@ public async System.Threading.Tasks.Task> DeleteOrderAsyncWi /// Returns pet inventories by status Returns a map of status codes to quantities /// /// Thrown when fails to make API call - /// Task of ApiResponse (Dictionary<string, int?>) - public async System.Threading.Tasks.Task>> GetInventoryAsyncWithHttpInfo () + /// Task of ApiResponse (Dictionary<string, int>) + public async System.Threading.Tasks.Task>> GetInventoryAsyncWithHttpInfo () { var localVarPath = "/store/inventory"; @@ -556,9 +556,9 @@ public async System.Threading.Tasks.Task> DeleteOrderAsyncWi if (exception != null) throw exception; } - return new ApiResponse>(localVarStatusCode, + return new ApiResponse>(localVarStatusCode, localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)), - (Dictionary) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(Dictionary))); + (Dictionary) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(Dictionary))); } /// @@ -567,7 +567,7 @@ public async System.Threading.Tasks.Task> DeleteOrderAsyncWi /// Thrown when fails to make API call /// ID of pet that needs to be fetched /// Order - public Order GetOrderById (long? orderId) + public Order GetOrderById (long orderId) { ApiResponse localVarResponse = GetOrderByIdWithHttpInfo(orderId); return localVarResponse.Data; @@ -579,7 +579,7 @@ public Order GetOrderById (long? orderId) /// Thrown when fails to make API call /// ID of pet that needs to be fetched /// ApiResponse of Order - public ApiResponse< Order > GetOrderByIdWithHttpInfo (long? orderId) + public ApiResponse GetOrderByIdWithHttpInfo (long orderId) { // verify the required parameter 'orderId' is set if (orderId == null) @@ -634,7 +634,7 @@ public ApiResponse< Order > GetOrderByIdWithHttpInfo (long? orderId) /// Thrown when fails to make API call /// ID of pet that needs to be fetched /// Task of Order - public async System.Threading.Tasks.Task GetOrderByIdAsync (long? orderId) + public async System.Threading.Tasks.Task GetOrderByIdAsync (long orderId) { ApiResponse localVarResponse = await GetOrderByIdAsyncWithHttpInfo(orderId); return localVarResponse.Data; @@ -647,7 +647,7 @@ public async System.Threading.Tasks.Task GetOrderByIdAsync (long? orderId /// Thrown when fails to make API call /// ID of pet that needs to be fetched /// Task of ApiResponse (Order) - public async System.Threading.Tasks.Task> GetOrderByIdAsyncWithHttpInfo (long? orderId) + public async System.Threading.Tasks.Task> GetOrderByIdAsyncWithHttpInfo (long orderId) { // verify the required parameter 'orderId' is set if (orderId == null) @@ -714,7 +714,7 @@ public Order PlaceOrder (Order order) /// Thrown when fails to make API call /// order placed for purchasing the pet /// ApiResponse of Order - public ApiResponse< Order > PlaceOrderWithHttpInfo (Order order) + public ApiResponse PlaceOrderWithHttpInfo (Order order) { // verify the required parameter 'order' is set if (order == null) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Api/UserApi.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Api/UserApi.cs index b2d8fe094c8f..2584bed7b2dd 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Api/UserApi.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Api/UserApi.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -1059,7 +1059,7 @@ public User GetUserByName (string username) /// Thrown when fails to make API call /// The name that needs to be fetched. Use user1 for testing. /// ApiResponse of User - public ApiResponse< User > GetUserByNameWithHttpInfo (string username) + public ApiResponse GetUserByNameWithHttpInfo (string username) { // verify the required parameter 'username' is set if (username == null) @@ -1196,7 +1196,7 @@ public string LoginUser (string username, string password) /// The user name for login /// The password for login in clear text /// ApiResponse of string - public ApiResponse< string > LoginUserWithHttpInfo (string username, string password) + public ApiResponse LoginUserWithHttpInfo (string username, string password) { // verify the required parameter 'username' is set if (username == null) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/ApiClient.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/ApiClient.cs index 030d56543c4b..9ccb39dfeedd 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/ApiClient.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/ApiClient.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -202,6 +202,7 @@ public async System.Threading.Tasks.Task CallApiAsync( var request = PrepareRequest( path, method, queryParams, postBody, headerParams, formParams, fileParams, pathParams, contentType); + RestClient.UserAgent = Configuration.UserAgent; InterceptRequest(request); var response = await RestClient.ExecuteTaskAsync(request); InterceptResponse(request, response); @@ -253,6 +254,8 @@ public string ParameterToString(object obj) // https://msdn.microsoft.com/en-us/library/az4se3k1(v=vs.110).aspx#Anchor_8 // For example: 2009-06-15T13:45:30.0000000 return ((DateTimeOffset)obj).ToString (Configuration.DateTimeFormat); + else if (obj is bool) + return (bool)obj ? "true" : "false"; else if (obj is IList) { var flattenedString = new StringBuilder(); @@ -497,6 +500,7 @@ public static string SanitizeFilename(string filename) /// Convert params to key/value pairs. /// Use collectionFormat to properly format lists and collections. /// + /// Collection format. /// Key name. /// Value object. /// A list of KeyValuePairs diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/ApiException.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/ApiException.cs index 875026e65f41..e7ac15569b93 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/ApiException.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/ApiException.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/ApiResponse.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/ApiResponse.cs index 3e395de9dfbb..4b462cf5424d 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/ApiResponse.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/ApiResponse.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/Configuration.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/Configuration.cs index b530746cb5a1..926007e22caf 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/Configuration.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/Configuration.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/ExceptionFactory.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/ExceptionFactory.cs index 66c4aa3a1408..d855d96821f2 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/ExceptionFactory.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/ExceptionFactory.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/GlobalConfiguration.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/GlobalConfiguration.cs index 309e385f25a7..a79bea966bd5 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/GlobalConfiguration.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/GlobalConfiguration.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/IApiAccessor.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/IApiAccessor.cs index 3b4834c409df..cd03e8c1f975 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/IApiAccessor.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/IApiAccessor.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/IReadableConfiguration.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/IReadableConfiguration.cs index 76a5f5124fdf..23e1a0c2e197 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/IReadableConfiguration.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/IReadableConfiguration.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/OpenAPIDateConverter.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/OpenAPIDateConverter.cs index 4f5c219d5c6e..a1bd6b08f3b1 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/OpenAPIDateConverter.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Client/OpenAPIDateConverter.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/AdditionalPropertiesClass.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/AdditionalPropertiesClass.cs index adafe21ea167..fa5137751772 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/AdditionalPropertiesClass.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/AdditionalPropertiesClass.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -100,11 +100,13 @@ public bool Equals(AdditionalPropertiesClass input) ( this.MapProperty == input.MapProperty || this.MapProperty != null && + input.MapProperty != null && this.MapProperty.SequenceEqual(input.MapProperty) ) && ( this.MapOfMapProperty == input.MapOfMapProperty || this.MapOfMapProperty != null && + input.MapOfMapProperty != null && this.MapOfMapProperty.SequenceEqual(input.MapOfMapProperty) ); } diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Animal.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Animal.cs index 16c89207e31d..fe04c33922f4 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Animal.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Animal.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -29,7 +29,7 @@ namespace Org.OpenAPITools.Model /// Animal /// [DataContract] - [JsonConverter(typeof(JsonSubtypes), "ClassName")] + [JsonConverter(typeof(JsonSubtypes), "className")] [JsonSubtypes.KnownSubType(typeof(Dog), "Dog")] [JsonSubtypes.KnownSubType(typeof(Cat), "Cat")] public partial class Animal : IEquatable, IValidatableObject @@ -55,6 +55,7 @@ protected Animal() { } { this.ClassName = className; } + // use default value if no "color" provided if (color == null) { @@ -69,7 +70,7 @@ protected Animal() { } /// /// Gets or Sets ClassName /// - [DataMember(Name="className", EmitDefaultValue=false)] + [DataMember(Name="className", EmitDefaultValue=true)] public string ClassName { get; set; } /// diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/ApiResponse.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/ApiResponse.cs index da35fa03b6dc..8f5a5a0e5a90 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/ApiResponse.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/ApiResponse.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -36,7 +36,7 @@ public partial class ApiResponse : IEquatable, IValidatableObject /// code. /// type. /// message. - public ApiResponse(int? code = default(int?), string type = default(string), string message = default(string)) + public ApiResponse(int code = default(int), string type = default(string), string message = default(string)) { this.Code = code; this.Type = type; @@ -47,7 +47,7 @@ public partial class ApiResponse : IEquatable, IValidatableObject /// Gets or Sets Code /// [DataMember(Name="code", EmitDefaultValue=false)] - public int? Code { get; set; } + public int Code { get; set; } /// /// Gets or Sets Type diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/ArrayOfArrayOfNumberOnly.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/ArrayOfArrayOfNumberOnly.cs index eb23cf99943f..0342fb2ce660 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/ArrayOfArrayOfNumberOnly.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/ArrayOfArrayOfNumberOnly.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -34,7 +34,7 @@ public partial class ArrayOfArrayOfNumberOnly : IEquatable class. /// /// arrayArrayNumber. - public ArrayOfArrayOfNumberOnly(List> arrayArrayNumber = default(List>)) + public ArrayOfArrayOfNumberOnly(List> arrayArrayNumber = default(List>)) { this.ArrayArrayNumber = arrayArrayNumber; } @@ -43,7 +43,7 @@ public partial class ArrayOfArrayOfNumberOnly : IEquatable [DataMember(Name="ArrayArrayNumber", EmitDefaultValue=false)] - public List> ArrayArrayNumber { get; set; } + public List> ArrayArrayNumber { get; set; } /// /// Returns the string presentation of the object @@ -91,6 +91,7 @@ public bool Equals(ArrayOfArrayOfNumberOnly input) ( this.ArrayArrayNumber == input.ArrayArrayNumber || this.ArrayArrayNumber != null && + input.ArrayArrayNumber != null && this.ArrayArrayNumber.SequenceEqual(input.ArrayArrayNumber) ); } diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/ArrayOfNumberOnly.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/ArrayOfNumberOnly.cs index a1aac93fc2fa..1b87d630d20f 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/ArrayOfNumberOnly.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/ArrayOfNumberOnly.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -34,7 +34,7 @@ public partial class ArrayOfNumberOnly : IEquatable, IValida /// Initializes a new instance of the class. /// /// arrayNumber. - public ArrayOfNumberOnly(List arrayNumber = default(List)) + public ArrayOfNumberOnly(List arrayNumber = default(List)) { this.ArrayNumber = arrayNumber; } @@ -43,7 +43,7 @@ public partial class ArrayOfNumberOnly : IEquatable, IValida /// Gets or Sets ArrayNumber /// [DataMember(Name="ArrayNumber", EmitDefaultValue=false)] - public List ArrayNumber { get; set; } + public List ArrayNumber { get; set; } /// /// Returns the string presentation of the object @@ -91,6 +91,7 @@ public bool Equals(ArrayOfNumberOnly input) ( this.ArrayNumber == input.ArrayNumber || this.ArrayNumber != null && + input.ArrayNumber != null && this.ArrayNumber.SequenceEqual(input.ArrayNumber) ); } diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/ArrayTest.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/ArrayTest.cs index c99d9289344a..10886bb6af62 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/ArrayTest.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/ArrayTest.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -36,7 +36,7 @@ public partial class ArrayTest : IEquatable, IValidatableObject /// arrayOfString. /// arrayArrayOfInteger. /// arrayArrayOfModel. - public ArrayTest(List arrayOfString = default(List), List> arrayArrayOfInteger = default(List>), List> arrayArrayOfModel = default(List>)) + public ArrayTest(List arrayOfString = default(List), List> arrayArrayOfInteger = default(List>), List> arrayArrayOfModel = default(List>)) { this.ArrayOfString = arrayOfString; this.ArrayArrayOfInteger = arrayArrayOfInteger; @@ -53,7 +53,7 @@ public partial class ArrayTest : IEquatable, IValidatableObject /// Gets or Sets ArrayArrayOfInteger /// [DataMember(Name="array_array_of_integer", EmitDefaultValue=false)] - public List> ArrayArrayOfInteger { get; set; } + public List> ArrayArrayOfInteger { get; set; } /// /// Gets or Sets ArrayArrayOfModel @@ -109,16 +109,19 @@ public bool Equals(ArrayTest input) ( this.ArrayOfString == input.ArrayOfString || this.ArrayOfString != null && + input.ArrayOfString != null && this.ArrayOfString.SequenceEqual(input.ArrayOfString) ) && ( this.ArrayArrayOfInteger == input.ArrayArrayOfInteger || this.ArrayArrayOfInteger != null && + input.ArrayArrayOfInteger != null && this.ArrayArrayOfInteger.SequenceEqual(input.ArrayArrayOfInteger) ) && ( this.ArrayArrayOfModel == input.ArrayArrayOfModel || this.ArrayArrayOfModel != null && + input.ArrayArrayOfModel != null && this.ArrayArrayOfModel.SequenceEqual(input.ArrayArrayOfModel) ); } diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Capitalization.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Capitalization.cs index eba3bc685996..058ce89df0d7 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Capitalization.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Capitalization.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Cat.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Cat.cs index 1504638f6f26..e4cfa3fbef4d 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Cat.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Cat.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -39,7 +39,7 @@ protected Cat() { } /// Initializes a new instance of the class. /// /// declawed. - public Cat(bool? declawed = default(bool?), string className = default(string), string color = "red") : base(className, color) + public Cat(bool declawed = default(bool), string className = "Cat", string color = "red") : base(className, color) { this.Declawed = declawed; } @@ -48,7 +48,7 @@ protected Cat() { } /// Gets or Sets Declawed /// [DataMember(Name="declawed", EmitDefaultValue=false)] - public bool? Declawed { get; set; } + public bool Declawed { get; set; } /// /// Returns the string presentation of the object diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/CatAllOf.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/CatAllOf.cs new file mode 100644 index 000000000000..3d452f64b382 --- /dev/null +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/CatAllOf.cs @@ -0,0 +1,124 @@ +/* + * OpenAPI Petstore + * + * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ + * + * The version of the OpenAPI document: 1.0.0 + * + * Generated by: https://github.com/openapitools/openapi-generator.git + */ + +using System; +using System.Linq; +using System.IO; +using System.Text; +using System.Text.RegularExpressions; +using System.Collections; +using System.Collections.Generic; +using System.Collections.ObjectModel; +using System.Runtime.Serialization; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using System.ComponentModel.DataAnnotations; +using OpenAPIDateConverter = Org.OpenAPITools.Client.OpenAPIDateConverter; + +namespace Org.OpenAPITools.Model +{ + /// + /// CatAllOf + /// + [DataContract] + public partial class CatAllOf : IEquatable, IValidatableObject + { + /// + /// Initializes a new instance of the class. + /// + /// declawed. + public CatAllOf(bool declawed = default(bool)) + { + this.Declawed = declawed; + } + + /// + /// Gets or Sets Declawed + /// + [DataMember(Name="declawed", EmitDefaultValue=false)] + public bool Declawed { get; set; } + + /// + /// Returns the string presentation of the object + /// + /// String presentation of the object + public override string ToString() + { + var sb = new StringBuilder(); + sb.Append("class CatAllOf {\n"); + sb.Append(" Declawed: ").Append(Declawed).Append("\n"); + sb.Append("}\n"); + return sb.ToString(); + } + + /// + /// Returns the JSON string presentation of the object + /// + /// JSON string presentation of the object + public virtual string ToJson() + { + return JsonConvert.SerializeObject(this, Formatting.Indented); + } + + /// + /// Returns true if objects are equal + /// + /// Object to be compared + /// Boolean + public override bool Equals(object input) + { + return this.Equals(input as CatAllOf); + } + + /// + /// Returns true if CatAllOf instances are equal + /// + /// Instance of CatAllOf to be compared + /// Boolean + public bool Equals(CatAllOf input) + { + if (input == null) + return false; + + return + ( + this.Declawed == input.Declawed || + (this.Declawed != null && + this.Declawed.Equals(input.Declawed)) + ); + } + + /// + /// Gets the hash code + /// + /// Hash code + public override int GetHashCode() + { + unchecked // Overflow is fine, just wrap + { + int hashCode = 41; + if (this.Declawed != null) + hashCode = hashCode * 59 + this.Declawed.GetHashCode(); + return hashCode; + } + } + + /// + /// To validate all properties of the instance + /// + /// Validation context + /// Validation Result + IEnumerable IValidatableObject.Validate(ValidationContext validationContext) + { + yield break; + } + } + +} diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Category.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Category.cs index a795fc58c582..2901d8bf67c4 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Category.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Category.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -40,7 +40,7 @@ protected Category() { } /// /// id. /// name (required) (default to "default-name"). - public Category(long? id = default(long?), string name = "default-name") + public Category(long id = default(long), string name = "default-name") { // to ensure "name" is required (not null) if (name == null) @@ -51,6 +51,7 @@ protected Category() { } { this.Name = name; } + this.Id = id; } @@ -58,12 +59,12 @@ protected Category() { } /// Gets or Sets Id /// [DataMember(Name="id", EmitDefaultValue=false)] - public long? Id { get; set; } + public long Id { get; set; } /// /// Gets or Sets Name /// - [DataMember(Name="name", EmitDefaultValue=false)] + [DataMember(Name="name", EmitDefaultValue=true)] public string Name { get; set; } /// diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/ClassModel.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/ClassModel.cs index 30753a34e643..4a7d5372a1a8 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/ClassModel.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/ClassModel.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Dog.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Dog.cs index ecd67f40b6e2..b925fb99c324 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Dog.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Dog.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -39,7 +39,7 @@ protected Dog() { } /// Initializes a new instance of the class. /// /// breed. - public Dog(string breed = default(string), string className = default(string), string color = "red") : base(className, color) + public Dog(string breed = default(string), string className = "Dog", string color = "red") : base(className, color) { this.Breed = breed; } diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/DogAllOf.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/DogAllOf.cs new file mode 100644 index 000000000000..24d4b43de854 --- /dev/null +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/DogAllOf.cs @@ -0,0 +1,124 @@ +/* + * OpenAPI Petstore + * + * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ + * + * The version of the OpenAPI document: 1.0.0 + * + * Generated by: https://github.com/openapitools/openapi-generator.git + */ + +using System; +using System.Linq; +using System.IO; +using System.Text; +using System.Text.RegularExpressions; +using System.Collections; +using System.Collections.Generic; +using System.Collections.ObjectModel; +using System.Runtime.Serialization; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using System.ComponentModel.DataAnnotations; +using OpenAPIDateConverter = Org.OpenAPITools.Client.OpenAPIDateConverter; + +namespace Org.OpenAPITools.Model +{ + /// + /// DogAllOf + /// + [DataContract] + public partial class DogAllOf : IEquatable, IValidatableObject + { + /// + /// Initializes a new instance of the class. + /// + /// breed. + public DogAllOf(string breed = default(string)) + { + this.Breed = breed; + } + + /// + /// Gets or Sets Breed + /// + [DataMember(Name="breed", EmitDefaultValue=false)] + public string Breed { get; set; } + + /// + /// Returns the string presentation of the object + /// + /// String presentation of the object + public override string ToString() + { + var sb = new StringBuilder(); + sb.Append("class DogAllOf {\n"); + sb.Append(" Breed: ").Append(Breed).Append("\n"); + sb.Append("}\n"); + return sb.ToString(); + } + + /// + /// Returns the JSON string presentation of the object + /// + /// JSON string presentation of the object + public virtual string ToJson() + { + return JsonConvert.SerializeObject(this, Formatting.Indented); + } + + /// + /// Returns true if objects are equal + /// + /// Object to be compared + /// Boolean + public override bool Equals(object input) + { + return this.Equals(input as DogAllOf); + } + + /// + /// Returns true if DogAllOf instances are equal + /// + /// Instance of DogAllOf to be compared + /// Boolean + public bool Equals(DogAllOf input) + { + if (input == null) + return false; + + return + ( + this.Breed == input.Breed || + (this.Breed != null && + this.Breed.Equals(input.Breed)) + ); + } + + /// + /// Gets the hash code + /// + /// Hash code + public override int GetHashCode() + { + unchecked // Overflow is fine, just wrap + { + int hashCode = 41; + if (this.Breed != null) + hashCode = hashCode * 59 + this.Breed.GetHashCode(); + return hashCode; + } + } + + /// + /// To validate all properties of the instance + /// + /// Validation context + /// Validation Result + IEnumerable IValidatableObject.Validate(ValidationContext validationContext) + { + yield break; + } + } + +} diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/EnumArrays.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/EnumArrays.cs index 567a207068c2..6887c901d117 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/EnumArrays.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/EnumArrays.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -146,6 +146,7 @@ public bool Equals(EnumArrays input) ( this.ArrayEnum == input.ArrayEnum || this.ArrayEnum != null && + input.ArrayEnum != null && this.ArrayEnum.SequenceEqual(input.ArrayEnum) ); } diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/EnumClass.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/EnumClass.cs index 33643e475f51..96e427f9b327 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/EnumClass.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/EnumClass.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/EnumTest.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/EnumTest.cs index 381572d5dfe3..31a584440558 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/EnumTest.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/EnumTest.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -90,7 +90,7 @@ public enum EnumStringRequiredEnum /// /// Gets or Sets EnumStringRequired /// - [DataMember(Name="enum_string_required", EmitDefaultValue=false)] + [DataMember(Name="enum_string_required", EmitDefaultValue=true)] public EnumStringRequiredEnum EnumStringRequired { get; set; } /// /// Defines EnumInteger @@ -140,6 +140,26 @@ public enum EnumNumberEnum [DataMember(Name="enum_number", EmitDefaultValue=false)] public EnumNumberEnum? EnumNumber { get; set; } /// + /// Gets or Sets OuterEnum + /// + [DataMember(Name="outerEnum", EmitDefaultValue=true)] + public OuterEnum? OuterEnum { get; set; } + /// + /// Gets or Sets OuterEnumInteger + /// + [DataMember(Name="outerEnumInteger", EmitDefaultValue=false)] + public OuterEnumInteger? OuterEnumInteger { get; set; } + /// + /// Gets or Sets OuterEnumDefaultValue + /// + [DataMember(Name="outerEnumDefaultValue", EmitDefaultValue=false)] + public OuterEnumDefaultValue? OuterEnumDefaultValue { get; set; } + /// + /// Gets or Sets OuterEnumIntegerDefaultValue + /// + [DataMember(Name="outerEnumIntegerDefaultValue", EmitDefaultValue=false)] + public OuterEnumIntegerDefaultValue? OuterEnumIntegerDefaultValue { get; set; } + /// /// Initializes a new instance of the class. /// [JsonConstructorAttribute] @@ -155,7 +175,7 @@ protected EnumTest() { } /// outerEnumInteger. /// outerEnumDefaultValue. /// outerEnumIntegerDefaultValue. - public EnumTest(EnumStringEnum? enumString = default(EnumStringEnum?), EnumStringRequiredEnum enumStringRequired = default(EnumStringRequiredEnum), EnumIntegerEnum? enumInteger = default(EnumIntegerEnum?), EnumNumberEnum? enumNumber = default(EnumNumberEnum?), OuterEnum outerEnum = default(OuterEnum), OuterEnumInteger outerEnumInteger = default(OuterEnumInteger), OuterEnumDefaultValue outerEnumDefaultValue = default(OuterEnumDefaultValue), OuterEnumIntegerDefaultValue outerEnumIntegerDefaultValue = default(OuterEnumIntegerDefaultValue)) + public EnumTest(EnumStringEnum? enumString = default(EnumStringEnum?), EnumStringRequiredEnum enumStringRequired = default(EnumStringRequiredEnum), EnumIntegerEnum? enumInteger = default(EnumIntegerEnum?), EnumNumberEnum? enumNumber = default(EnumNumberEnum?), OuterEnum? outerEnum = default(OuterEnum?), OuterEnumInteger? outerEnumInteger = default(OuterEnumInteger?), OuterEnumDefaultValue? outerEnumDefaultValue = default(OuterEnumDefaultValue?), OuterEnumIntegerDefaultValue? outerEnumIntegerDefaultValue = default(OuterEnumIntegerDefaultValue?)) { // to ensure "enumStringRequired" is required (not null) if (enumStringRequired == null) @@ -166,6 +186,8 @@ protected EnumTest() { } { this.EnumStringRequired = enumStringRequired; } + + this.OuterEnum = outerEnum; this.EnumString = enumString; this.EnumInteger = enumInteger; this.EnumNumber = enumNumber; @@ -179,29 +201,9 @@ protected EnumTest() { } - /// - /// Gets or Sets OuterEnum - /// - [DataMember(Name="outerEnum", EmitDefaultValue=false)] - public OuterEnum OuterEnum { get; set; } - /// - /// Gets or Sets OuterEnumInteger - /// - [DataMember(Name="outerEnumInteger", EmitDefaultValue=false)] - public OuterEnumInteger OuterEnumInteger { get; set; } - /// - /// Gets or Sets OuterEnumDefaultValue - /// - [DataMember(Name="outerEnumDefaultValue", EmitDefaultValue=false)] - public OuterEnumDefaultValue OuterEnumDefaultValue { get; set; } - /// - /// Gets or Sets OuterEnumIntegerDefaultValue - /// - [DataMember(Name="outerEnumIntegerDefaultValue", EmitDefaultValue=false)] - public OuterEnumIntegerDefaultValue OuterEnumIntegerDefaultValue { get; set; } /// /// Returns the string presentation of the object diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/File.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/File.cs index 68d564d17e72..3cf268524f93 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/File.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/File.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/FileSchemaTestClass.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/FileSchemaTestClass.cs index 7853ca2a0de3..73a8b61aa754 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/FileSchemaTestClass.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/FileSchemaTestClass.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -105,6 +105,7 @@ public bool Equals(FileSchemaTestClass input) ( this.Files == input.Files || this.Files != null && + input.Files != null && this.Files.SequenceEqual(input.Files) ); } diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Foo.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Foo.cs index 394f5adc052a..5f3b3bcd9d52 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Foo.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Foo.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/FormatTest.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/FormatTest.cs index 195270a84710..202bd2d47177 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/FormatTest.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/FormatTest.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -53,7 +53,7 @@ protected FormatTest() { } /// password (required). /// A string that is a 10 digit number. Can have leading zeros.. /// A string starting with 'image_' (case insensitive) and one to three digits following i.e. Image_01.. - public FormatTest(int? integer = default(int?), int? int32 = default(int?), long? int64 = default(long?), decimal? number = default(decimal?), float? _float = default(float?), double? _double = default(double?), string _string = default(string), byte[] _byte = default(byte[]), System.IO.Stream binary = default(System.IO.Stream), DateTime? date = default(DateTime?), DateTime? dateTime = default(DateTime?), Guid? uuid = default(Guid?), string password = default(string), string patternWithDigits = default(string), string patternWithDigitsAndDelimiter = default(string)) + public FormatTest(int integer = default(int), int int32 = default(int), long int64 = default(long), decimal number = default(decimal), float _float = default(float), double _double = default(double), string _string = default(string), byte[] _byte = default(byte[]), System.IO.Stream binary = default(System.IO.Stream), DateTime date = default(DateTime), DateTime dateTime = default(DateTime), Guid uuid = default(Guid), string password = default(string), string patternWithDigits = default(string), string patternWithDigitsAndDelimiter = default(string)) { // to ensure "number" is required (not null) if (number == null) @@ -64,6 +64,7 @@ protected FormatTest() { } { this.Number = number; } + // to ensure "_byte" is required (not null) if (_byte == null) { @@ -73,6 +74,7 @@ protected FormatTest() { } { this.Byte = _byte; } + // to ensure "date" is required (not null) if (date == null) { @@ -82,6 +84,7 @@ protected FormatTest() { } { this.Date = date; } + // to ensure "password" is required (not null) if (password == null) { @@ -91,6 +94,7 @@ protected FormatTest() { } { this.Password = password; } + this.Integer = integer; this.Int32 = int32; this.Int64 = int64; @@ -108,37 +112,37 @@ protected FormatTest() { } /// Gets or Sets Integer /// [DataMember(Name="integer", EmitDefaultValue=false)] - public int? Integer { get; set; } + public int Integer { get; set; } /// /// Gets or Sets Int32 /// [DataMember(Name="int32", EmitDefaultValue=false)] - public int? Int32 { get; set; } + public int Int32 { get; set; } /// /// Gets or Sets Int64 /// [DataMember(Name="int64", EmitDefaultValue=false)] - public long? Int64 { get; set; } + public long Int64 { get; set; } /// /// Gets or Sets Number /// - [DataMember(Name="number", EmitDefaultValue=false)] - public decimal? Number { get; set; } + [DataMember(Name="number", EmitDefaultValue=true)] + public decimal Number { get; set; } /// /// Gets or Sets Float /// [DataMember(Name="float", EmitDefaultValue=false)] - public float? Float { get; set; } + public float Float { get; set; } /// /// Gets or Sets Double /// [DataMember(Name="double", EmitDefaultValue=false)] - public double? Double { get; set; } + public double Double { get; set; } /// /// Gets or Sets String @@ -149,7 +153,7 @@ protected FormatTest() { } /// /// Gets or Sets Byte /// - [DataMember(Name="byte", EmitDefaultValue=false)] + [DataMember(Name="byte", EmitDefaultValue=true)] public byte[] Byte { get; set; } /// @@ -161,26 +165,26 @@ protected FormatTest() { } /// /// Gets or Sets Date /// - [DataMember(Name="date", EmitDefaultValue=false)] + [DataMember(Name="date", EmitDefaultValue=true)] [JsonConverter(typeof(OpenAPIDateConverter))] - public DateTime? Date { get; set; } + public DateTime Date { get; set; } /// /// Gets or Sets DateTime /// [DataMember(Name="dateTime", EmitDefaultValue=false)] - public DateTime? DateTime { get; set; } + public DateTime DateTime { get; set; } /// /// Gets or Sets Uuid /// [DataMember(Name="uuid", EmitDefaultValue=false)] - public Guid? Uuid { get; set; } + public Guid Uuid { get; set; } /// /// Gets or Sets Password /// - [DataMember(Name="password", EmitDefaultValue=false)] + [DataMember(Name="password", EmitDefaultValue=true)] public string Password { get; set; } /// @@ -381,66 +385,78 @@ public override int GetHashCode() /// Validation Result IEnumerable IValidatableObject.Validate(ValidationContext validationContext) { - // Integer (int?) maximum - if(this.Integer > (int?)100) + + + // Integer (int) maximum + if(this.Integer > (int)100) { yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Integer, must be a value less than or equal to 100.", new [] { "Integer" }); } - // Integer (int?) minimum - if(this.Integer < (int?)10) + // Integer (int) minimum + if(this.Integer < (int)10) { yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Integer, must be a value greater than or equal to 10.", new [] { "Integer" }); } - // Int32 (int?) maximum - if(this.Int32 > (int?)200) + + + // Int32 (int) maximum + if(this.Int32 > (int)200) { yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Int32, must be a value less than or equal to 200.", new [] { "Int32" }); } - // Int32 (int?) minimum - if(this.Int32 < (int?)20) + // Int32 (int) minimum + if(this.Int32 < (int)20) { yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Int32, must be a value greater than or equal to 20.", new [] { "Int32" }); } - // Number (decimal?) maximum - if(this.Number > (decimal?)543.2) + + + // Number (decimal) maximum + if(this.Number > (decimal)543.2) { yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Number, must be a value less than or equal to 543.2.", new [] { "Number" }); } - // Number (decimal?) minimum - if(this.Number < (decimal?)32.1) + // Number (decimal) minimum + if(this.Number < (decimal)32.1) { yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Number, must be a value greater than or equal to 32.1.", new [] { "Number" }); } - // Float (float?) maximum - if(this.Float > (float?)987.6) + + + // Float (float) maximum + if(this.Float > (float)987.6) { yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Float, must be a value less than or equal to 987.6.", new [] { "Float" }); } - // Float (float?) minimum - if(this.Float < (float?)54.3) + // Float (float) minimum + if(this.Float < (float)54.3) { yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Float, must be a value greater than or equal to 54.3.", new [] { "Float" }); } - // Double (double?) maximum - if(this.Double > (double?)123.4) + + + // Double (double) maximum + if(this.Double > (double)123.4) { yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Double, must be a value less than or equal to 123.4.", new [] { "Double" }); } - // Double (double?) minimum - if(this.Double < (double?)67.8) + // Double (double) minimum + if(this.Double < (double)67.8) { yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Double, must be a value greater than or equal to 67.8.", new [] { "Double" }); } + + // String (string) pattern Regex regexString = new Regex(@"[a-z]", RegexOptions.CultureInvariant | RegexOptions.IgnoreCase); if (false == regexString.Match(this.String).Success) @@ -459,7 +475,9 @@ public override int GetHashCode() { yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Password, length must be greater than 10.", new [] { "Password" }); } + + // PatternWithDigits (string) pattern Regex regexPatternWithDigits = new Regex(@"^\\d{10}$", RegexOptions.CultureInvariant); if (false == regexPatternWithDigits.Match(this.PatternWithDigits).Success) @@ -467,6 +485,8 @@ public override int GetHashCode() yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for PatternWithDigits, must match a pattern of " + regexPatternWithDigits, new [] { "PatternWithDigits" }); } + + // PatternWithDigitsAndDelimiter (string) pattern Regex regexPatternWithDigitsAndDelimiter = new Regex(@"^image_\\d{1,3}$", RegexOptions.CultureInvariant | RegexOptions.IgnoreCase); if (false == regexPatternWithDigitsAndDelimiter.Match(this.PatternWithDigitsAndDelimiter).Success) diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/HasOnlyReadOnly.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/HasOnlyReadOnly.cs index 520640366921..10b9939f5ad3 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/HasOnlyReadOnly.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/HasOnlyReadOnly.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/HealthCheckResult.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/HealthCheckResult.cs index 08dd777f5b79..dffd3ccfa611 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/HealthCheckResult.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/HealthCheckResult.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -37,12 +37,13 @@ public partial class HealthCheckResult : IEquatable, IValida public HealthCheckResult(string nullableMessage = default(string)) { this.NullableMessage = nullableMessage; + this.NullableMessage = nullableMessage; } /// /// Gets or Sets NullableMessage /// - [DataMember(Name="NullableMessage", EmitDefaultValue=false)] + [DataMember(Name="NullableMessage", EmitDefaultValue=true)] public string NullableMessage { get; set; } /// diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/InlineObject.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/InlineObject.cs index 95ea944a8c61..7a3a6114012c 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/InlineObject.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/InlineObject.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/InlineObject1.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/InlineObject1.cs index 473147e67492..f08aeb4eb375 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/InlineObject1.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/InlineObject1.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/InlineObject2.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/InlineObject2.cs index c354d941f270..5e512e7d3b94 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/InlineObject2.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/InlineObject2.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -158,6 +158,7 @@ public bool Equals(InlineObject2 input) ( this.EnumFormStringArray == input.EnumFormStringArray || this.EnumFormStringArray != null && + input.EnumFormStringArray != null && this.EnumFormStringArray.SequenceEqual(input.EnumFormStringArray) ) && ( diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/InlineObject3.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/InlineObject3.cs index cb7c53f698de..65d38e748173 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/InlineObject3.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/InlineObject3.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -52,7 +52,7 @@ protected InlineObject3() { } /// None. /// None. /// None. - public InlineObject3(int? integer = default(int?), int? int32 = default(int?), long? int64 = default(long?), decimal? number = default(decimal?), float? _float = default(float?), double? _double = default(double?), string _string = default(string), string patternWithoutDelimiter = default(string), byte[] _byte = default(byte[]), System.IO.Stream binary = default(System.IO.Stream), DateTime? date = default(DateTime?), DateTime? dateTime = default(DateTime?), string password = default(string), string callback = default(string)) + public InlineObject3(int integer = default(int), int int32 = default(int), long int64 = default(long), decimal number = default(decimal), float _float = default(float), double _double = default(double), string _string = default(string), string patternWithoutDelimiter = default(string), byte[] _byte = default(byte[]), System.IO.Stream binary = default(System.IO.Stream), DateTime date = default(DateTime), DateTime dateTime = default(DateTime), string password = default(string), string callback = default(string)) { // to ensure "number" is required (not null) if (number == null) @@ -63,6 +63,7 @@ protected InlineObject3() { } { this.Number = number; } + // to ensure "_double" is required (not null) if (_double == null) { @@ -72,6 +73,7 @@ protected InlineObject3() { } { this.Double = _double; } + // to ensure "patternWithoutDelimiter" is required (not null) if (patternWithoutDelimiter == null) { @@ -81,6 +83,7 @@ protected InlineObject3() { } { this.PatternWithoutDelimiter = patternWithoutDelimiter; } + // to ensure "_byte" is required (not null) if (_byte == null) { @@ -90,6 +93,7 @@ protected InlineObject3() { } { this.Byte = _byte; } + this.Integer = integer; this.Int32 = int32; this.Int64 = int64; @@ -107,42 +111,42 @@ protected InlineObject3() { } /// /// None [DataMember(Name="integer", EmitDefaultValue=false)] - public int? Integer { get; set; } + public int Integer { get; set; } /// /// None /// /// None [DataMember(Name="int32", EmitDefaultValue=false)] - public int? Int32 { get; set; } + public int Int32 { get; set; } /// /// None /// /// None [DataMember(Name="int64", EmitDefaultValue=false)] - public long? Int64 { get; set; } + public long Int64 { get; set; } /// /// None /// /// None - [DataMember(Name="number", EmitDefaultValue=false)] - public decimal? Number { get; set; } + [DataMember(Name="number", EmitDefaultValue=true)] + public decimal Number { get; set; } /// /// None /// /// None [DataMember(Name="float", EmitDefaultValue=false)] - public float? Float { get; set; } + public float Float { get; set; } /// /// None /// /// None - [DataMember(Name="double", EmitDefaultValue=false)] - public double? Double { get; set; } + [DataMember(Name="double", EmitDefaultValue=true)] + public double Double { get; set; } /// /// None @@ -155,14 +159,14 @@ protected InlineObject3() { } /// None /// /// None - [DataMember(Name="pattern_without_delimiter", EmitDefaultValue=false)] + [DataMember(Name="pattern_without_delimiter", EmitDefaultValue=true)] public string PatternWithoutDelimiter { get; set; } /// /// None /// /// None - [DataMember(Name="byte", EmitDefaultValue=false)] + [DataMember(Name="byte", EmitDefaultValue=true)] public byte[] Byte { get; set; } /// @@ -178,14 +182,14 @@ protected InlineObject3() { } /// None [DataMember(Name="date", EmitDefaultValue=false)] [JsonConverter(typeof(OpenAPIDateConverter))] - public DateTime? Date { get; set; } + public DateTime Date { get; set; } /// /// None /// /// None [DataMember(Name="dateTime", EmitDefaultValue=false)] - public DateTime? DateTime { get; set; } + public DateTime DateTime { get; set; } /// /// None @@ -377,60 +381,72 @@ public override int GetHashCode() /// Validation Result IEnumerable IValidatableObject.Validate(ValidationContext validationContext) { - // Integer (int?) maximum - if(this.Integer > (int?)100) + + + // Integer (int) maximum + if(this.Integer > (int)100) { yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Integer, must be a value less than or equal to 100.", new [] { "Integer" }); } - // Integer (int?) minimum - if(this.Integer < (int?)10) + // Integer (int) minimum + if(this.Integer < (int)10) { yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Integer, must be a value greater than or equal to 10.", new [] { "Integer" }); } - // Int32 (int?) maximum - if(this.Int32 > (int?)200) + + + // Int32 (int) maximum + if(this.Int32 > (int)200) { yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Int32, must be a value less than or equal to 200.", new [] { "Int32" }); } - // Int32 (int?) minimum - if(this.Int32 < (int?)20) + // Int32 (int) minimum + if(this.Int32 < (int)20) { yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Int32, must be a value greater than or equal to 20.", new [] { "Int32" }); } - // Number (decimal?) maximum - if(this.Number > (decimal?)543.2) + + + // Number (decimal) maximum + if(this.Number > (decimal)543.2) { yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Number, must be a value less than or equal to 543.2.", new [] { "Number" }); } - // Number (decimal?) minimum - if(this.Number < (decimal?)32.1) + // Number (decimal) minimum + if(this.Number < (decimal)32.1) { yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Number, must be a value greater than or equal to 32.1.", new [] { "Number" }); } - // Float (float?) maximum - if(this.Float > (float?)987.6) + + + // Float (float) maximum + if(this.Float > (float)987.6) { yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Float, must be a value less than or equal to 987.6.", new [] { "Float" }); } - // Double (double?) maximum - if(this.Double > (double?)123.4) + + + // Double (double) maximum + if(this.Double > (double)123.4) { yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Double, must be a value less than or equal to 123.4.", new [] { "Double" }); } - // Double (double?) minimum - if(this.Double < (double?)67.8) + // Double (double) minimum + if(this.Double < (double)67.8) { yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Double, must be a value greater than or equal to 67.8.", new [] { "Double" }); } + + // String (string) pattern Regex regexString = new Regex(@"[a-z]", RegexOptions.CultureInvariant | RegexOptions.IgnoreCase); if (false == regexString.Match(this.String).Success) @@ -438,6 +454,8 @@ public override int GetHashCode() yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for String, must match a pattern of " + regexString, new [] { "String" }); } + + // PatternWithoutDelimiter (string) pattern Regex regexPatternWithoutDelimiter = new Regex(@"^[A-Z].*", RegexOptions.CultureInvariant); if (false == regexPatternWithoutDelimiter.Match(this.PatternWithoutDelimiter).Success) @@ -456,7 +474,7 @@ public override int GetHashCode() { yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Password, length must be greater than 10.", new [] { "Password" }); } - + yield break; } } diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/InlineObject4.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/InlineObject4.cs index 70326154bfce..8d3147b9ff1b 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/InlineObject4.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/InlineObject4.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -51,6 +51,7 @@ protected InlineObject4() { } { this.Param = param; } + // to ensure "param2" is required (not null) if (param2 == null) { @@ -60,20 +61,21 @@ protected InlineObject4() { } { this.Param2 = param2; } + } /// /// field1 /// /// field1 - [DataMember(Name="param", EmitDefaultValue=false)] + [DataMember(Name="param", EmitDefaultValue=true)] public string Param { get; set; } /// /// field2 /// /// field2 - [DataMember(Name="param2", EmitDefaultValue=false)] + [DataMember(Name="param2", EmitDefaultValue=true)] public string Param2 { get; set; } /// diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/InlineObject5.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/InlineObject5.cs index 8821e41a8ac7..ef1951597cc1 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/InlineObject5.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/InlineObject5.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -51,6 +51,7 @@ protected InlineObject5() { } { this.RequiredFile = requiredFile; } + this.AdditionalMetadata = additionalMetadata; } @@ -65,7 +66,7 @@ protected InlineObject5() { } /// file to upload /// /// file to upload - [DataMember(Name="requiredFile", EmitDefaultValue=false)] + [DataMember(Name="requiredFile", EmitDefaultValue=true)] public System.IO.Stream RequiredFile { get; set; } /// diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/InlineResponseDefault.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/InlineResponseDefault.cs index a264f2e0b2fb..a553a49ec799 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/InlineResponseDefault.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/InlineResponseDefault.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/List.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/List.cs index 14c7ed746a0e..6b3ace11cf4e 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/List.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/List.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/MapTest.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/MapTest.cs index 3f44bcf22eaa..71368b4b44d6 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/MapTest.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/MapTest.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -63,7 +63,7 @@ public enum InnerEnum /// mapOfEnumString. /// directMap. /// indirectMap. - public MapTest(Dictionary> mapMapOfString = default(Dictionary>), Dictionary mapOfEnumString = default(Dictionary), Dictionary directMap = default(Dictionary), Dictionary indirectMap = default(Dictionary)) + public MapTest(Dictionary> mapMapOfString = default(Dictionary>), Dictionary mapOfEnumString = default(Dictionary), Dictionary directMap = default(Dictionary), Dictionary indirectMap = default(Dictionary)) { this.MapMapOfString = mapMapOfString; this.MapOfEnumString = mapOfEnumString; @@ -82,13 +82,13 @@ public enum InnerEnum /// Gets or Sets DirectMap /// [DataMember(Name="direct_map", EmitDefaultValue=false)] - public Dictionary DirectMap { get; set; } + public Dictionary DirectMap { get; set; } /// /// Gets or Sets IndirectMap /// [DataMember(Name="indirect_map", EmitDefaultValue=false)] - public Dictionary IndirectMap { get; set; } + public Dictionary IndirectMap { get; set; } /// /// Returns the string presentation of the object @@ -139,21 +139,25 @@ public bool Equals(MapTest input) ( this.MapMapOfString == input.MapMapOfString || this.MapMapOfString != null && + input.MapMapOfString != null && this.MapMapOfString.SequenceEqual(input.MapMapOfString) ) && ( this.MapOfEnumString == input.MapOfEnumString || this.MapOfEnumString != null && + input.MapOfEnumString != null && this.MapOfEnumString.SequenceEqual(input.MapOfEnumString) ) && ( this.DirectMap == input.DirectMap || this.DirectMap != null && + input.DirectMap != null && this.DirectMap.SequenceEqual(input.DirectMap) ) && ( this.IndirectMap == input.IndirectMap || this.IndirectMap != null && + input.IndirectMap != null && this.IndirectMap.SequenceEqual(input.IndirectMap) ); } diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/MixedPropertiesAndAdditionalPropertiesClass.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/MixedPropertiesAndAdditionalPropertiesClass.cs index 19df6fd34891..627a4d358b76 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/MixedPropertiesAndAdditionalPropertiesClass.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/MixedPropertiesAndAdditionalPropertiesClass.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -36,7 +36,7 @@ public partial class MixedPropertiesAndAdditionalPropertiesClass : IEquatableuuid. /// dateTime. /// map. - public MixedPropertiesAndAdditionalPropertiesClass(Guid? uuid = default(Guid?), DateTime? dateTime = default(DateTime?), Dictionary map = default(Dictionary)) + public MixedPropertiesAndAdditionalPropertiesClass(Guid uuid = default(Guid), DateTime dateTime = default(DateTime), Dictionary map = default(Dictionary)) { this.Uuid = uuid; this.DateTime = dateTime; @@ -47,13 +47,13 @@ public partial class MixedPropertiesAndAdditionalPropertiesClass : IEquatable [DataMember(Name="uuid", EmitDefaultValue=false)] - public Guid? Uuid { get; set; } + public Guid Uuid { get; set; } /// /// Gets or Sets DateTime /// [DataMember(Name="dateTime", EmitDefaultValue=false)] - public DateTime? DateTime { get; set; } + public DateTime DateTime { get; set; } /// /// Gets or Sets Map @@ -119,6 +119,7 @@ public bool Equals(MixedPropertiesAndAdditionalPropertiesClass input) ( this.Map == input.Map || this.Map != null && + input.Map != null && this.Map.SequenceEqual(input.Map) ); } diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Model200Response.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Model200Response.cs index 69767330c053..58853af412d9 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Model200Response.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Model200Response.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -35,7 +35,7 @@ public partial class Model200Response : IEquatable, IValidata /// /// name. /// _class. - public Model200Response(int? name = default(int?), string _class = default(string)) + public Model200Response(int name = default(int), string _class = default(string)) { this.Name = name; this.Class = _class; @@ -45,7 +45,7 @@ public partial class Model200Response : IEquatable, IValidata /// Gets or Sets Name /// [DataMember(Name="name", EmitDefaultValue=false)] - public int? Name { get; set; } + public int Name { get; set; } /// /// Gets or Sets Class diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/ModelClient.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/ModelClient.cs index 2e9d79ef1419..2d93513c7681 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/ModelClient.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/ModelClient.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Name.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Name.cs index 68f848ca0915..c22d454e1ea4 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Name.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Name.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -40,7 +40,7 @@ protected Name() { } /// /// name (required). /// property. - public Name(int? name = default(int?), string property = default(string)) + public Name(int name = default(int), string property = default(string)) { // to ensure "name" is required (not null) if (name == null) @@ -51,20 +51,21 @@ protected Name() { } { this._Name = name; } + this.Property = property; } /// /// Gets or Sets _Name /// - [DataMember(Name="name", EmitDefaultValue=false)] - public int? _Name { get; set; } + [DataMember(Name="name", EmitDefaultValue=true)] + public int _Name { get; set; } /// /// Gets or Sets SnakeCase /// [DataMember(Name="snake_case", EmitDefaultValue=false)] - public int? SnakeCase { get; private set; } + public int SnakeCase { get; private set; } /// /// Gets or Sets Property @@ -76,7 +77,7 @@ protected Name() { } /// Gets or Sets _123Number /// [DataMember(Name="123Number", EmitDefaultValue=false)] - public int? _123Number { get; private set; } + public int _123Number { get; private set; } /// /// Returns the string presentation of the object diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/NullableClass.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/NullableClass.cs index 2feb2eb9aead..c7aefda57568 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/NullableClass.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/NullableClass.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -47,6 +47,16 @@ public partial class NullableClass : Dictionary, IEquatableobjectItemsNullable. public NullableClass(int? integerProp = default(int?), decimal? numberProp = default(decimal?), bool? booleanProp = default(bool?), string stringProp = default(string), DateTime? dateProp = default(DateTime?), DateTime? datetimeProp = default(DateTime?), List arrayNullableProp = default(List), List arrayAndItemsNullableProp = default(List), List arrayItemsNullable = default(List), Dictionary objectNullableProp = default(Dictionary), Dictionary objectAndItemsNullableProp = default(Dictionary), Dictionary objectItemsNullable = default(Dictionary)) : base() { + this.IntegerProp = integerProp; + this.NumberProp = numberProp; + this.BooleanProp = booleanProp; + this.StringProp = stringProp; + this.DateProp = dateProp; + this.DatetimeProp = datetimeProp; + this.ArrayNullableProp = arrayNullableProp; + this.ArrayAndItemsNullableProp = arrayAndItemsNullableProp; + this.ObjectNullableProp = objectNullableProp; + this.ObjectAndItemsNullableProp = objectAndItemsNullableProp; this.IntegerProp = integerProp; this.NumberProp = numberProp; this.BooleanProp = booleanProp; @@ -64,50 +74,50 @@ public partial class NullableClass : Dictionary, IEquatable /// Gets or Sets IntegerProp /// - [DataMember(Name="integer_prop", EmitDefaultValue=false)] + [DataMember(Name="integer_prop", EmitDefaultValue=true)] public int? IntegerProp { get; set; } /// /// Gets or Sets NumberProp /// - [DataMember(Name="number_prop", EmitDefaultValue=false)] + [DataMember(Name="number_prop", EmitDefaultValue=true)] public decimal? NumberProp { get; set; } /// /// Gets or Sets BooleanProp /// - [DataMember(Name="boolean_prop", EmitDefaultValue=false)] + [DataMember(Name="boolean_prop", EmitDefaultValue=true)] public bool? BooleanProp { get; set; } /// /// Gets or Sets StringProp /// - [DataMember(Name="string_prop", EmitDefaultValue=false)] + [DataMember(Name="string_prop", EmitDefaultValue=true)] public string StringProp { get; set; } /// /// Gets or Sets DateProp /// - [DataMember(Name="date_prop", EmitDefaultValue=false)] + [DataMember(Name="date_prop", EmitDefaultValue=true)] [JsonConverter(typeof(OpenAPIDateConverter))] public DateTime? DateProp { get; set; } /// /// Gets or Sets DatetimeProp /// - [DataMember(Name="datetime_prop", EmitDefaultValue=false)] + [DataMember(Name="datetime_prop", EmitDefaultValue=true)] public DateTime? DatetimeProp { get; set; } /// /// Gets or Sets ArrayNullableProp /// - [DataMember(Name="array_nullable_prop", EmitDefaultValue=false)] + [DataMember(Name="array_nullable_prop", EmitDefaultValue=true)] public List ArrayNullableProp { get; set; } /// /// Gets or Sets ArrayAndItemsNullableProp /// - [DataMember(Name="array_and_items_nullable_prop", EmitDefaultValue=false)] + [DataMember(Name="array_and_items_nullable_prop", EmitDefaultValue=true)] public List ArrayAndItemsNullableProp { get; set; } /// @@ -119,13 +129,13 @@ public partial class NullableClass : Dictionary, IEquatable /// Gets or Sets ObjectNullableProp /// - [DataMember(Name="object_nullable_prop", EmitDefaultValue=false)] + [DataMember(Name="object_nullable_prop", EmitDefaultValue=true)] public Dictionary ObjectNullableProp { get; set; } /// /// Gets or Sets ObjectAndItemsNullableProp /// - [DataMember(Name="object_and_items_nullable_prop", EmitDefaultValue=false)] + [DataMember(Name="object_and_items_nullable_prop", EmitDefaultValue=true)] public Dictionary ObjectAndItemsNullableProp { get; set; } /// @@ -222,31 +232,37 @@ public bool Equals(NullableClass input) ( this.ArrayNullableProp == input.ArrayNullableProp || this.ArrayNullableProp != null && + input.ArrayNullableProp != null && this.ArrayNullableProp.SequenceEqual(input.ArrayNullableProp) ) && base.Equals(input) && ( this.ArrayAndItemsNullableProp == input.ArrayAndItemsNullableProp || this.ArrayAndItemsNullableProp != null && + input.ArrayAndItemsNullableProp != null && this.ArrayAndItemsNullableProp.SequenceEqual(input.ArrayAndItemsNullableProp) ) && base.Equals(input) && ( this.ArrayItemsNullable == input.ArrayItemsNullable || this.ArrayItemsNullable != null && + input.ArrayItemsNullable != null && this.ArrayItemsNullable.SequenceEqual(input.ArrayItemsNullable) ) && base.Equals(input) && ( this.ObjectNullableProp == input.ObjectNullableProp || this.ObjectNullableProp != null && + input.ObjectNullableProp != null && this.ObjectNullableProp.SequenceEqual(input.ObjectNullableProp) ) && base.Equals(input) && ( this.ObjectAndItemsNullableProp == input.ObjectAndItemsNullableProp || this.ObjectAndItemsNullableProp != null && + input.ObjectAndItemsNullableProp != null && this.ObjectAndItemsNullableProp.SequenceEqual(input.ObjectAndItemsNullableProp) ) && base.Equals(input) && ( this.ObjectItemsNullable == input.ObjectItemsNullable || this.ObjectItemsNullable != null && + input.ObjectItemsNullable != null && this.ObjectItemsNullable.SequenceEqual(input.ObjectItemsNullable) ); } diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/NumberOnly.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/NumberOnly.cs index 0d3c613d18bc..62f401d8785f 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/NumberOnly.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/NumberOnly.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -34,7 +34,7 @@ public partial class NumberOnly : IEquatable, IValidatableObject /// Initializes a new instance of the class. /// /// justNumber. - public NumberOnly(decimal? justNumber = default(decimal?)) + public NumberOnly(decimal justNumber = default(decimal)) { this.JustNumber = justNumber; } @@ -43,7 +43,7 @@ public partial class NumberOnly : IEquatable, IValidatableObject /// Gets or Sets JustNumber /// [DataMember(Name="JustNumber", EmitDefaultValue=false)] - public decimal? JustNumber { get; set; } + public decimal JustNumber { get; set; } /// /// Returns the string presentation of the object diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Order.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Order.cs index f895f035192b..c46c951fd30f 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Order.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Order.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -72,7 +72,7 @@ public enum StatusEnum /// shipDate. /// Order Status. /// complete (default to false). - public Order(long? id = default(long?), long? petId = default(long?), int? quantity = default(int?), DateTime? shipDate = default(DateTime?), StatusEnum? status = default(StatusEnum?), bool? complete = false) + public Order(long id = default(long), long petId = default(long), int quantity = default(int), DateTime shipDate = default(DateTime), StatusEnum? status = default(StatusEnum?), bool complete = false) { this.Id = id; this.PetId = petId; @@ -94,32 +94,32 @@ public enum StatusEnum /// Gets or Sets Id /// [DataMember(Name="id", EmitDefaultValue=false)] - public long? Id { get; set; } + public long Id { get; set; } /// /// Gets or Sets PetId /// [DataMember(Name="petId", EmitDefaultValue=false)] - public long? PetId { get; set; } + public long PetId { get; set; } /// /// Gets or Sets Quantity /// [DataMember(Name="quantity", EmitDefaultValue=false)] - public int? Quantity { get; set; } + public int Quantity { get; set; } /// /// Gets or Sets ShipDate /// [DataMember(Name="shipDate", EmitDefaultValue=false)] - public DateTime? ShipDate { get; set; } + public DateTime ShipDate { get; set; } /// /// Gets or Sets Complete /// [DataMember(Name="complete", EmitDefaultValue=false)] - public bool? Complete { get; set; } + public bool Complete { get; set; } /// /// Returns the string presentation of the object diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/OuterComposite.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/OuterComposite.cs index 3bb725402152..eef811e72998 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/OuterComposite.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/OuterComposite.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -36,7 +36,7 @@ public partial class OuterComposite : IEquatable, IValidatableO /// myNumber. /// myString. /// myBoolean. - public OuterComposite(decimal? myNumber = default(decimal?), string myString = default(string), bool? myBoolean = default(bool?)) + public OuterComposite(decimal myNumber = default(decimal), string myString = default(string), bool myBoolean = default(bool)) { this.MyNumber = myNumber; this.MyString = myString; @@ -47,7 +47,7 @@ public partial class OuterComposite : IEquatable, IValidatableO /// Gets or Sets MyNumber /// [DataMember(Name="my_number", EmitDefaultValue=false)] - public decimal? MyNumber { get; set; } + public decimal MyNumber { get; set; } /// /// Gets or Sets MyString @@ -59,7 +59,7 @@ public partial class OuterComposite : IEquatable, IValidatableO /// Gets or Sets MyBoolean /// [DataMember(Name="my_boolean", EmitDefaultValue=false)] - public bool? MyBoolean { get; set; } + public bool MyBoolean { get; set; } /// /// Returns the string presentation of the object diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/OuterEnum.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/OuterEnum.cs index be116aff60ab..e902802e0d60 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/OuterEnum.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/OuterEnum.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/OuterEnumDefaultValue.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/OuterEnumDefaultValue.cs index a49b7640982d..196d097f9584 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/OuterEnumDefaultValue.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/OuterEnumDefaultValue.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/OuterEnumInteger.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/OuterEnumInteger.cs index ea69ed635c87..55aec73401f7 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/OuterEnumInteger.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/OuterEnumInteger.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/OuterEnumIntegerDefaultValue.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/OuterEnumIntegerDefaultValue.cs index c1262d92aa4c..e265103c92a5 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/OuterEnumIntegerDefaultValue.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/OuterEnumIntegerDefaultValue.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Pet.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Pet.cs index 1e213e5006ad..681dccedc28d 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Pet.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Pet.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -77,7 +77,7 @@ protected Pet() { } /// photoUrls (required). /// tags. /// pet status in the store. - public Pet(long? id = default(long?), Category category = default(Category), string name = default(string), List photoUrls = default(List), List tags = default(List), StatusEnum? status = default(StatusEnum?)) + public Pet(long id = default(long), Category category = default(Category), string name = default(string), List photoUrls = default(List), List tags = default(List), StatusEnum? status = default(StatusEnum?)) { // to ensure "name" is required (not null) if (name == null) @@ -88,6 +88,7 @@ protected Pet() { } { this.Name = name; } + // to ensure "photoUrls" is required (not null) if (photoUrls == null) { @@ -97,6 +98,7 @@ protected Pet() { } { this.PhotoUrls = photoUrls; } + this.Id = id; this.Category = category; this.Tags = tags; @@ -107,7 +109,7 @@ protected Pet() { } /// Gets or Sets Id /// [DataMember(Name="id", EmitDefaultValue=false)] - public long? Id { get; set; } + public long Id { get; set; } /// /// Gets or Sets Category @@ -118,13 +120,13 @@ protected Pet() { } /// /// Gets or Sets Name /// - [DataMember(Name="name", EmitDefaultValue=false)] + [DataMember(Name="name", EmitDefaultValue=true)] public string Name { get; set; } /// /// Gets or Sets PhotoUrls /// - [DataMember(Name="photoUrls", EmitDefaultValue=false)] + [DataMember(Name="photoUrls", EmitDefaultValue=true)] public List PhotoUrls { get; set; } /// @@ -200,11 +202,13 @@ public bool Equals(Pet input) ( this.PhotoUrls == input.PhotoUrls || this.PhotoUrls != null && + input.PhotoUrls != null && this.PhotoUrls.SequenceEqual(input.PhotoUrls) ) && ( this.Tags == input.Tags || this.Tags != null && + input.Tags != null && this.Tags.SequenceEqual(input.Tags) ) && ( diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/ReadOnlyFirst.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/ReadOnlyFirst.cs index 6e82eb5819e2..bb1c7edde085 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/ReadOnlyFirst.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/ReadOnlyFirst.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Return.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Return.cs index 401b8e2c70d4..c12d15c0a65e 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Return.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Return.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -34,7 +34,7 @@ public partial class Return : IEquatable, IValidatableObject /// Initializes a new instance of the class. /// /// _return. - public Return(int? _return = default(int?)) + public Return(int _return = default(int)) { this._Return = _return; } @@ -43,7 +43,7 @@ public partial class Return : IEquatable, IValidatableObject /// Gets or Sets _Return /// [DataMember(Name="return", EmitDefaultValue=false)] - public int? _Return { get; set; } + public int _Return { get; set; } /// /// Returns the string presentation of the object diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/SpecialModelName.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/SpecialModelName.cs index 54ea66dd81b2..0cd2939c9e1b 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/SpecialModelName.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/SpecialModelName.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -34,7 +34,7 @@ public partial class SpecialModelName : IEquatable, IValidata /// Initializes a new instance of the class. /// /// specialPropertyName. - public SpecialModelName(long? specialPropertyName = default(long?)) + public SpecialModelName(long specialPropertyName = default(long)) { this.SpecialPropertyName = specialPropertyName; } @@ -43,7 +43,7 @@ public partial class SpecialModelName : IEquatable, IValidata /// Gets or Sets SpecialPropertyName /// [DataMember(Name="$special[property.name]", EmitDefaultValue=false)] - public long? SpecialPropertyName { get; set; } + public long SpecialPropertyName { get; set; } /// /// Returns the string presentation of the object diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Tag.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Tag.cs index f95860219eeb..4ed40c915d2a 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Tag.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/Tag.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -35,7 +35,7 @@ public partial class Tag : IEquatable, IValidatableObject /// /// id. /// name. - public Tag(long? id = default(long?), string name = default(string)) + public Tag(long id = default(long), string name = default(string)) { this.Id = id; this.Name = name; @@ -45,7 +45,7 @@ public partial class Tag : IEquatable, IValidatableObject /// Gets or Sets Id /// [DataMember(Name="id", EmitDefaultValue=false)] - public long? Id { get; set; } + public long Id { get; set; } /// /// Gets or Sets Name diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/User.cs b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/User.cs index cf491294ec95..d59b7b04132f 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/User.cs +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Model/User.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -41,7 +41,7 @@ public partial class User : IEquatable, IValidatableObject /// password. /// phone. /// User Status. - public User(long? id = default(long?), string username = default(string), string firstName = default(string), string lastName = default(string), string email = default(string), string password = default(string), string phone = default(string), int? userStatus = default(int?)) + public User(long id = default(long), string username = default(string), string firstName = default(string), string lastName = default(string), string email = default(string), string password = default(string), string phone = default(string), int userStatus = default(int)) { this.Id = id; this.Username = username; @@ -57,7 +57,7 @@ public partial class User : IEquatable, IValidatableObject /// Gets or Sets Id /// [DataMember(Name="id", EmitDefaultValue=false)] - public long? Id { get; set; } + public long Id { get; set; } /// /// Gets or Sets Username @@ -100,7 +100,7 @@ public partial class User : IEquatable, IValidatableObject /// /// User Status [DataMember(Name="userStatus", EmitDefaultValue=false)] - public int? UserStatus { get; set; } + public int UserStatus { get; set; } /// /// Returns the string presentation of the object diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Org.OpenAPITools.csproj b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Org.OpenAPITools.csproj index af2274727547..6c69e3745f60 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Org.OpenAPITools.csproj +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Org.OpenAPITools.csproj @@ -4,7 +4,7 @@ OpenAPI Petstore This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ -OpenAPI spec version: 1.0.0 +The version of the OpenAPI document: 1.0.0 --> @@ -28,6 +28,7 @@ OpenAPI spec version: 1.0.0 DEBUG;TRACE prompt 4 + bin\Debug\Org.OpenAPITools.xml pdbonly @@ -36,6 +37,7 @@ OpenAPI spec version: 1.0.0 TRACE prompt 4 + bin\Release\Org.OpenAPITools.xml @@ -48,21 +50,21 @@ OpenAPI spec version: 1.0.0 - $(SolutionDir)\packages\Newtonsoft.Json.10.0.3\lib\net45\Newtonsoft.Json.dll - ..\packages\Newtonsoft.Json.10.0.3\lib\net45\Newtonsoft.Json.dll - ..\..\packages\Newtonsoft.Json.10.0.3\lib\net45\Newtonsoft.Json.dll - ..\..\vendor\Newtonsoft.Json.10.0.3\lib\net45\Newtonsoft.Json.dll + $(SolutionDir)\packages\Newtonsoft.Json.12.0.3\lib\net45\Newtonsoft.Json.dll + ..\packages\Newtonsoft.Json.12.0.3\lib\net45\Newtonsoft.Json.dll + ..\..\packages\Newtonsoft.Json.12.0.3\lib\net45\Newtonsoft.Json.dll + ..\..\vendor\Newtonsoft.Json.12.0.3\lib\net45\Newtonsoft.Json.dll - $(SolutionDir)\packages\JsonSubTypes.1.2.0\lib\net45\JsonSubTypes.dll - ..\packages\JsonSubTypes.1.2.0\lib\net45\JsonSubTypes.dll - ..\..\packages\JsonSubTypes.1.2.0\lib\net45\JsonSubTypes.dll - ..\..\vendor\JsonSubTypes.1.2.0\lib\net45\JsonSubTypes.dll + $(SolutionDir)\packages\JsonSubTypes.1.6.0\lib\net45\JsonSubTypes.dll + ..\packages\JsonSubTypes.1.6.0\lib\net45\JsonSubTypes.dll + ..\..\packages\JsonSubTypes.1.6.0\lib\net45\JsonSubTypes.dll + ..\..\vendor\JsonSubTypes.1.6.0\lib\net45\JsonSubTypes.dll - $(SolutionDir)\packages\RestSharp.105.1.0\lib\net45\RestSharp.dll - ..\packages\RestSharp.105.1.0\lib\net45\RestSharp.dll - ..\..\packages\RestSharp.105.1.0\lib\net45\RestSharp.dll + $(SolutionDir)\packages\RestSharp.105.1.0\lib\net45\RestSharp.dll + ..\packages\RestSharp.105.1.0\lib\net45\RestSharp.dll + ..\..\packages\RestSharp.105.1.0\lib\net45\RestSharp.dll ..\..\vendor\RestSharp.105.1.0\lib\net45\RestSharp.dll diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Org.OpenAPITools.nuspec b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Org.OpenAPITools.nuspec index 40ee0ddda055..c9ccbe1a8242 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Org.OpenAPITools.nuspec +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/Org.OpenAPITools.nuspec @@ -25,8 +25,8 @@ - - + + diff --git a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/packages.config b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/packages.config index 3caf34e0d765..a3a1bab35101 100644 --- a/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/packages.config +++ b/samples/openapi3/client/petstore/csharp/OpenAPIClient/src/Org.OpenAPITools/packages.config @@ -1,6 +1,7 @@ + - - + + From 51f4fdc1b6f23b427710d374b505286051229bae Mon Sep 17 00:00:00 2001 From: Tom E <1036527+thommy101@users.noreply.github.com> Date: Sun, 10 May 2020 18:25:34 +0200 Subject: [PATCH 3/4] [c-sharp] Fix #6225 default values with discriminator --- .../codegen/languages/CSharpNetCoreClientCodegen.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/CSharpNetCoreClientCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/CSharpNetCoreClientCodegen.java index 3c8d8a3e33d0..90a3b2464667 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/CSharpNetCoreClientCodegen.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/CSharpNetCoreClientCodegen.java @@ -299,7 +299,7 @@ public CodegenModel fromModel(String name, Schema model) { } for (final CodegenProperty property : codegenModel.readWriteVars) { - if (property.defaultValue == null && parentCodegenModel.discriminator != null && property.baseName.equals(parentCodegenModel.discriminator.getPropertyName())) { + if (property.defaultValue == null && parentCodegenModel.discriminator != null && property.name.equals(parentCodegenModel.discriminator.getPropertyName())) { property.defaultValue = "\"" + name + "\""; } } From e1327ac5ea3fdef7a371fe7cfc4b464a42f38767 Mon Sep 17 00:00:00 2001 From: Tom E <1036527+thommy101@users.noreply.github.com> Date: Sun, 10 May 2020 18:25:47 +0200 Subject: [PATCH 4/4] [c-sharp] Update sample files --- .../OpenAPIClient/.openapi-generator/VERSION | 2 +- .../Lib/OpenAPIClient/README.md | 14 +- .../Lib/OpenAPIClient/docs/InlineObject.md | 10 + .../Lib/OpenAPIClient/docs/InlineObject1.md | 10 + .../Lib/OpenAPIClient/docs/PetApi.md | 26 +- .../Lib/OpenAPIClient/docs/StoreApi.md | 10 +- .../Lib/OpenAPIClient/docs/UserApi.md | 82 ++- .../Org/OpenAPITools/Api/PetApi.cs | 40 +- .../Org/OpenAPITools/Api/StoreApi.cs | 14 +- .../Org/OpenAPITools/Api/UserApi.cs | 68 +- .../Org/OpenAPITools/Client/ApiClient.cs | 2 + .../README.md | 45 +- .../docs/AdditionalPropertiesClass.md | 13 +- .../docs/AnotherFakeApi.md | 8 +- .../docs/DefaultApi.md | 32 +- .../docs/EnumTest.md | 3 + .../docs/FakeApi.md | 162 +++-- .../docs/FakeClassnameTags123Api.md | 8 +- .../docs/Foo.md | 6 +- .../docs/FormatTest.md | 3 +- .../docs/HealthCheckResult.md | 6 +- .../docs/InlineObject.md | 6 +- .../docs/InlineObject1.md | 6 +- .../docs/InlineObject2.md | 6 +- .../docs/InlineObject3.md | 22 +- .../docs/InlineObject4.md | 6 +- .../docs/InlineObject5.md | 6 +- .../docs/InlineResponseDefault.md | 6 +- .../docs/NullableClass.md | 6 +- .../docs/OuterEnumDefaultValue.md | 6 +- .../docs/OuterEnumInteger.md | 6 +- .../docs/OuterEnumIntegerDefaultValue.md | 6 +- .../docs/PetApi.md | 19 +- .../docs/StoreApi.md | 10 +- .../docs/UserApi.md | 40 +- .../Org.OpenAPITools/Api/AnotherFakeApi.cs | 60 +- .../src/Org.OpenAPITools/Api/DefaultApi.cs | 4 +- .../src/Org.OpenAPITools/Api/FakeApi.cs | 633 ++++++++++++------ .../Api/FakeClassnameTags123Api.cs | 60 +- .../src/Org.OpenAPITools/Api/PetApi.cs | 120 ++-- .../src/Org.OpenAPITools/Api/StoreApi.cs | 62 +- .../src/Org.OpenAPITools/Api/UserApi.cs | 248 +++---- .../Model/AdditionalPropertiesClass.cs | 200 +----- .../src/Org.OpenAPITools/Model/Animal.cs | 1 - .../src/Org.OpenAPITools/Model/Cat.cs | 10 - .../src/Org.OpenAPITools/Model/EnumTest.cs | 51 +- .../src/Org.OpenAPITools/Model/Foo.cs | 4 +- .../src/Org.OpenAPITools/Model/FormatTest.cs | 62 +- .../Model/HealthCheckResult.cs | 5 +- .../Org.OpenAPITools/Model/InlineObject.cs | 6 +- .../Org.OpenAPITools/Model/InlineObject1.cs | 6 +- .../Org.OpenAPITools/Model/InlineObject2.cs | 7 +- .../Org.OpenAPITools/Model/InlineObject3.cs | 104 +-- .../Org.OpenAPITools/Model/InlineObject4.cs | 8 +- .../Org.OpenAPITools/Model/InlineObject5.cs | 7 +- .../Model/InlineResponseDefault.cs | 4 +- .../Org.OpenAPITools/Model/NullableClass.cs | 42 +- .../Model/OuterEnumDefaultValue.cs | 2 +- .../Model/OuterEnumInteger.cs | 2 +- .../Model/OuterEnumIntegerDefaultValue.cs | 2 +- 60 files changed, 1400 insertions(+), 1025 deletions(-) create mode 100644 samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/docs/InlineObject.md create mode 100644 samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/docs/InlineObject1.md diff --git a/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/.openapi-generator/VERSION b/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/.openapi-generator/VERSION index b5d898602c2c..d99e7162d01f 100644 --- a/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/.openapi-generator/VERSION +++ b/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/.openapi-generator/VERSION @@ -1 +1 @@ -4.3.1-SNAPSHOT \ No newline at end of file +5.0.0-SNAPSHOT \ No newline at end of file diff --git a/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/README.md b/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/README.md index 5296503208aa..524715fe1424 100644 --- a/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/README.md +++ b/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/README.md @@ -53,12 +53,13 @@ namespace Example Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN"; var apiInstance = new PetApi(); - var body = new Pet(); // Pet | Pet object that needs to be added to the store + var pet = new Pet(); // Pet | Pet object that needs to be added to the store try { // Add a new pet to the store - apiInstance.AddPet(body); + Pet result = apiInstance.AddPet(pet); + Debug.WriteLine(result); } catch (Exception e) { @@ -103,6 +104,8 @@ Class | Method | HTTP request | Description - [Org.OpenAPITools.Model.ApiResponse](docs/ApiResponse.md) - [Org.OpenAPITools.Model.Category](docs/Category.md) + - [Org.OpenAPITools.Model.InlineObject](docs/InlineObject.md) + - [Org.OpenAPITools.Model.InlineObject1](docs/InlineObject1.md) - [Org.OpenAPITools.Model.Order](docs/Order.md) - [Org.OpenAPITools.Model.Pet](docs/Pet.md) - [Org.OpenAPITools.Model.Tag](docs/Tag.md) @@ -120,6 +123,13 @@ Authentication schemes defined for the API: - **API key parameter name**: api_key - **Location**: HTTP header + +### auth_cookie + +- **Type**: API key +- **API key parameter name**: AUTH_KEY +- **Location**: + ### petstore_auth diff --git a/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/docs/InlineObject.md b/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/docs/InlineObject.md new file mode 100644 index 000000000000..40e16da1bb7d --- /dev/null +++ b/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/docs/InlineObject.md @@ -0,0 +1,10 @@ +# Org.OpenAPITools.Model.InlineObject +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Name** | **string** | Updated name of the pet | [optional] +**Status** | **string** | Updated status of the pet | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/docs/InlineObject1.md b/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/docs/InlineObject1.md new file mode 100644 index 000000000000..2e6d226754e4 --- /dev/null +++ b/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/docs/InlineObject1.md @@ -0,0 +1,10 @@ +# Org.OpenAPITools.Model.InlineObject1 +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**AdditionalMetadata** | **string** | Additional data to pass to server | [optional] +**File** | **System.IO.Stream** | file to upload | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/docs/PetApi.md b/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/docs/PetApi.md index 373f0348fe7c..fa74e4fedc70 100644 --- a/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/docs/PetApi.md +++ b/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/docs/PetApi.md @@ -16,7 +16,7 @@ Method | HTTP request | Description # **AddPet** -> void AddPet (Pet body) +> Pet AddPet (Pet pet) Add a new pet to the store @@ -38,12 +38,13 @@ namespace Example Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN"; var apiInstance = new PetApi(); - var body = new Pet(); // Pet | Pet object that needs to be added to the store + var pet = new Pet(); // Pet | Pet object that needs to be added to the store try { // Add a new pet to the store - apiInstance.AddPet(body); + Pet result = apiInstance.AddPet(pet); + Debug.WriteLine(result); } catch (Exception e) { @@ -58,11 +59,11 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**Pet**](Pet.md)| Pet object that needs to be added to the store | + **pet** | [**Pet**](Pet.md)| Pet object that needs to be added to the store | ### Return type -void (empty response body) +[**Pet**](Pet.md) ### Authorization @@ -71,7 +72,7 @@ void (empty response body) ### HTTP request headers - **Content-Type**: application/json, application/xml - - **Accept**: Not defined + - **Accept**: application/xml, application/json [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) @@ -334,7 +335,7 @@ Name | Type | Description | Notes # **UpdatePet** -> void UpdatePet (Pet body) +> Pet UpdatePet (Pet pet) Update an existing pet @@ -356,12 +357,13 @@ namespace Example Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN"; var apiInstance = new PetApi(); - var body = new Pet(); // Pet | Pet object that needs to be added to the store + var pet = new Pet(); // Pet | Pet object that needs to be added to the store try { // Update an existing pet - apiInstance.UpdatePet(body); + Pet result = apiInstance.UpdatePet(pet); + Debug.WriteLine(result); } catch (Exception e) { @@ -376,11 +378,11 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**Pet**](Pet.md)| Pet object that needs to be added to the store | + **pet** | [**Pet**](Pet.md)| Pet object that needs to be added to the store | ### Return type -void (empty response body) +[**Pet**](Pet.md) ### Authorization @@ -389,7 +391,7 @@ void (empty response body) ### HTTP request headers - **Content-Type**: application/json, application/xml - - **Accept**: Not defined + - **Accept**: application/xml, application/json [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) diff --git a/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/docs/StoreApi.md b/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/docs/StoreApi.md index 068cb5419f84..3541dd990ba1 100644 --- a/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/docs/StoreApi.md +++ b/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/docs/StoreApi.md @@ -195,7 +195,7 @@ No authorization required # **PlaceOrder** -> Order PlaceOrder (Order body) +> Order PlaceOrder (Order order) Place an order for a pet @@ -214,12 +214,12 @@ namespace Example public void main() { var apiInstance = new StoreApi(); - var body = new Order(); // Order | order placed for purchasing the pet + var order = new Order(); // Order | order placed for purchasing the pet try { // Place an order for a pet - Order result = apiInstance.PlaceOrder(body); + Order result = apiInstance.PlaceOrder(order); Debug.WriteLine(result); } catch (Exception e) @@ -235,7 +235,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**Order**](Order.md)| order placed for purchasing the pet | + **order** | [**Order**](Order.md)| order placed for purchasing the pet | ### Return type @@ -247,7 +247,7 @@ No authorization required ### HTTP request headers - - **Content-Type**: Not defined + - **Content-Type**: application/json - **Accept**: application/xml, application/json [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) diff --git a/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/docs/UserApi.md b/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/docs/UserApi.md index 74ca98353aa7..a2a2965b19a9 100644 --- a/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/docs/UserApi.md +++ b/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/docs/UserApi.md @@ -16,7 +16,7 @@ Method | HTTP request | Description # **CreateUser** -> void CreateUser (User body) +> void CreateUser (User user) Create user @@ -36,13 +36,18 @@ namespace Example { public void main() { + // Configure API key authorization: auth_cookie + Configuration.Default.ApiKey.Add("AUTH_KEY", "YOUR_API_KEY"); + // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed + // Configuration.Default.ApiKeyPrefix.Add("AUTH_KEY", "Bearer"); + var apiInstance = new UserApi(); - var body = new User(); // User | Created user object + var user = new User(); // User | Created user object try { // Create user - apiInstance.CreateUser(body); + apiInstance.CreateUser(user); } catch (Exception e) { @@ -57,7 +62,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**User**](User.md)| Created user object | + **user** | [**User**](User.md)| Created user object | ### Return type @@ -65,18 +70,18 @@ void (empty response body) ### Authorization -No authorization required +[auth_cookie](../README.md#auth_cookie) ### HTTP request headers - - **Content-Type**: Not defined + - **Content-Type**: application/json - **Accept**: Not defined [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) # **CreateUsersWithArrayInput** -> void CreateUsersWithArrayInput (List body) +> void CreateUsersWithArrayInput (List user) Creates list of users with given input array @@ -94,13 +99,18 @@ namespace Example { public void main() { + // Configure API key authorization: auth_cookie + Configuration.Default.ApiKey.Add("AUTH_KEY", "YOUR_API_KEY"); + // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed + // Configuration.Default.ApiKeyPrefix.Add("AUTH_KEY", "Bearer"); + var apiInstance = new UserApi(); - var body = new List(); // List | List of user object + var user = new List(); // List | List of user object try { // Creates list of users with given input array - apiInstance.CreateUsersWithArrayInput(body); + apiInstance.CreateUsersWithArrayInput(user); } catch (Exception e) { @@ -115,7 +125,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**List**](User.md)| List of user object | + **user** | [**List**](User.md)| List of user object | ### Return type @@ -123,18 +133,18 @@ void (empty response body) ### Authorization -No authorization required +[auth_cookie](../README.md#auth_cookie) ### HTTP request headers - - **Content-Type**: Not defined + - **Content-Type**: application/json - **Accept**: Not defined [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) # **CreateUsersWithListInput** -> void CreateUsersWithListInput (List body) +> void CreateUsersWithListInput (List user) Creates list of users with given input array @@ -152,13 +162,18 @@ namespace Example { public void main() { + // Configure API key authorization: auth_cookie + Configuration.Default.ApiKey.Add("AUTH_KEY", "YOUR_API_KEY"); + // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed + // Configuration.Default.ApiKeyPrefix.Add("AUTH_KEY", "Bearer"); + var apiInstance = new UserApi(); - var body = new List(); // List | List of user object + var user = new List(); // List | List of user object try { // Creates list of users with given input array - apiInstance.CreateUsersWithListInput(body); + apiInstance.CreateUsersWithListInput(user); } catch (Exception e) { @@ -173,7 +188,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**List**](User.md)| List of user object | + **user** | [**List**](User.md)| List of user object | ### Return type @@ -181,11 +196,11 @@ void (empty response body) ### Authorization -No authorization required +[auth_cookie](../README.md#auth_cookie) ### HTTP request headers - - **Content-Type**: Not defined + - **Content-Type**: application/json - **Accept**: Not defined [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) @@ -212,6 +227,11 @@ namespace Example { public void main() { + // Configure API key authorization: auth_cookie + Configuration.Default.ApiKey.Add("AUTH_KEY", "YOUR_API_KEY"); + // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed + // Configuration.Default.ApiKeyPrefix.Add("AUTH_KEY", "Bearer"); + var apiInstance = new UserApi(); var username = username_example; // string | The name that needs to be deleted @@ -241,7 +261,7 @@ void (empty response body) ### Authorization -No authorization required +[auth_cookie](../README.md#auth_cookie) ### HTTP request headers @@ -390,6 +410,11 @@ namespace Example { public void main() { + // Configure API key authorization: auth_cookie + Configuration.Default.ApiKey.Add("AUTH_KEY", "YOUR_API_KEY"); + // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed + // Configuration.Default.ApiKeyPrefix.Add("AUTH_KEY", "Bearer"); + var apiInstance = new UserApi(); try @@ -415,7 +440,7 @@ void (empty response body) ### Authorization -No authorization required +[auth_cookie](../README.md#auth_cookie) ### HTTP request headers @@ -426,7 +451,7 @@ No authorization required # **UpdateUser** -> void UpdateUser (string username, User body) +> void UpdateUser (string username, User user) Updated user @@ -446,14 +471,19 @@ namespace Example { public void main() { + // Configure API key authorization: auth_cookie + Configuration.Default.ApiKey.Add("AUTH_KEY", "YOUR_API_KEY"); + // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed + // Configuration.Default.ApiKeyPrefix.Add("AUTH_KEY", "Bearer"); + var apiInstance = new UserApi(); var username = username_example; // string | name that need to be deleted - var body = new User(); // User | Updated user object + var user = new User(); // User | Updated user object try { // Updated user - apiInstance.UpdateUser(username, body); + apiInstance.UpdateUser(username, user); } catch (Exception e) { @@ -469,7 +499,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **username** | **string**| name that need to be deleted | - **body** | [**User**](User.md)| Updated user object | + **user** | [**User**](User.md)| Updated user object | ### Return type @@ -477,11 +507,11 @@ void (empty response body) ### Authorization -No authorization required +[auth_cookie](../README.md#auth_cookie) ### HTTP request headers - - **Content-Type**: Not defined + - **Content-Type**: application/json - **Accept**: Not defined [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) diff --git a/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/src/main/CsharpDotNet2/Org/OpenAPITools/Api/PetApi.cs b/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/src/main/CsharpDotNet2/Org/OpenAPITools/Api/PetApi.cs index 48b1119b50af..023e23e47626 100644 --- a/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/src/main/CsharpDotNet2/Org/OpenAPITools/Api/PetApi.cs +++ b/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/src/main/CsharpDotNet2/Org/OpenAPITools/Api/PetApi.cs @@ -14,9 +14,9 @@ public interface IPetApi /// /// Add a new pet to the store /// - /// Pet object that needs to be added to the store - /// - void AddPet (Pet body); + /// Pet object that needs to be added to the store + /// Pet + Pet AddPet (Pet pet); /// /// Deletes a pet /// @@ -45,9 +45,9 @@ public interface IPetApi /// /// Update an existing pet /// - /// Pet object that needs to be added to the store - /// - void UpdatePet (Pet body); + /// Pet object that needs to be added to the store + /// Pet + Pet UpdatePet (Pet pet); /// /// Updates a pet in the store with form data /// @@ -122,13 +122,13 @@ public String GetBasePath(String basePath) /// /// Add a new pet to the store /// - /// Pet object that needs to be added to the store - /// - public void AddPet (Pet body) + /// Pet object that needs to be added to the store + /// Pet + public Pet AddPet (Pet pet) { - // verify the required parameter 'body' is set - if (body == null) throw new ApiException(400, "Missing required parameter 'body' when calling AddPet"); + // verify the required parameter 'pet' is set + if (pet == null) throw new ApiException(400, "Missing required parameter 'pet' when calling AddPet"); var path = "/pet"; @@ -140,7 +140,7 @@ public void AddPet (Pet body) var fileParams = new Dictionary(); String postBody = null; - postBody = ApiClient.Serialize(body); // http body (model) parameter + postBody = ApiClient.Serialize(pet); // http body (model) parameter // authentication setting, if any String[] authSettings = new String[] { "petstore_auth" }; @@ -153,7 +153,7 @@ public void AddPet (Pet body) else if (((int)response.StatusCode) == 0) throw new ApiException ((int)response.StatusCode, "Error calling AddPet: " + response.ErrorMessage, response.ErrorMessage); - return; + return (Pet) ApiClient.Deserialize(response.Content, typeof(Pet), response.Headers); } /// @@ -309,13 +309,13 @@ public Pet GetPetById (long? petId) /// /// Update an existing pet /// - /// Pet object that needs to be added to the store - /// - public void UpdatePet (Pet body) + /// Pet object that needs to be added to the store + /// Pet + public Pet UpdatePet (Pet pet) { - // verify the required parameter 'body' is set - if (body == null) throw new ApiException(400, "Missing required parameter 'body' when calling UpdatePet"); + // verify the required parameter 'pet' is set + if (pet == null) throw new ApiException(400, "Missing required parameter 'pet' when calling UpdatePet"); var path = "/pet"; @@ -327,7 +327,7 @@ public void UpdatePet (Pet body) var fileParams = new Dictionary(); String postBody = null; - postBody = ApiClient.Serialize(body); // http body (model) parameter + postBody = ApiClient.Serialize(pet); // http body (model) parameter // authentication setting, if any String[] authSettings = new String[] { "petstore_auth" }; @@ -340,7 +340,7 @@ public void UpdatePet (Pet body) else if (((int)response.StatusCode) == 0) throw new ApiException ((int)response.StatusCode, "Error calling UpdatePet: " + response.ErrorMessage, response.ErrorMessage); - return; + return (Pet) ApiClient.Deserialize(response.Content, typeof(Pet), response.Headers); } /// diff --git a/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/src/main/CsharpDotNet2/Org/OpenAPITools/Api/StoreApi.cs b/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/src/main/CsharpDotNet2/Org/OpenAPITools/Api/StoreApi.cs index df7be44e7b95..3390bbbcaba7 100644 --- a/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/src/main/CsharpDotNet2/Org/OpenAPITools/Api/StoreApi.cs +++ b/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/src/main/CsharpDotNet2/Org/OpenAPITools/Api/StoreApi.cs @@ -31,9 +31,9 @@ public interface IStoreApi /// /// Place an order for a pet /// - /// order placed for purchasing the pet + /// order placed for purchasing the pet /// Order - Order PlaceOrder (Order body); + Order PlaceOrder (Order order); } /// @@ -198,13 +198,13 @@ public Order GetOrderById (long? orderId) /// /// Place an order for a pet /// - /// order placed for purchasing the pet + /// order placed for purchasing the pet /// Order - public Order PlaceOrder (Order body) + public Order PlaceOrder (Order order) { - // verify the required parameter 'body' is set - if (body == null) throw new ApiException(400, "Missing required parameter 'body' when calling PlaceOrder"); + // verify the required parameter 'order' is set + if (order == null) throw new ApiException(400, "Missing required parameter 'order' when calling PlaceOrder"); var path = "/store/order"; @@ -216,7 +216,7 @@ public Order PlaceOrder (Order body) var fileParams = new Dictionary(); String postBody = null; - postBody = ApiClient.Serialize(body); // http body (model) parameter + postBody = ApiClient.Serialize(order); // http body (model) parameter // authentication setting, if any String[] authSettings = new String[] { }; diff --git a/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/src/main/CsharpDotNet2/Org/OpenAPITools/Api/UserApi.cs b/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/src/main/CsharpDotNet2/Org/OpenAPITools/Api/UserApi.cs index 3f453e6b9b21..b05d18104766 100644 --- a/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/src/main/CsharpDotNet2/Org/OpenAPITools/Api/UserApi.cs +++ b/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/src/main/CsharpDotNet2/Org/OpenAPITools/Api/UserApi.cs @@ -14,21 +14,21 @@ public interface IUserApi /// /// Create user This can only be done by the logged in user. /// - /// Created user object + /// Created user object /// - void CreateUser (User body); + void CreateUser (User user); /// /// Creates list of users with given input array /// - /// List of user object + /// List of user object /// - void CreateUsersWithArrayInput (List body); + void CreateUsersWithArrayInput (List user); /// /// Creates list of users with given input array /// - /// List of user object + /// List of user object /// - void CreateUsersWithListInput (List body); + void CreateUsersWithListInput (List user); /// /// Delete user This can only be done by the logged in user. /// @@ -57,9 +57,9 @@ public interface IUserApi /// Updated user This can only be done by the logged in user. /// /// name that need to be deleted - /// Updated user object + /// Updated user object /// - void UpdateUser (string username, User body); + void UpdateUser (string username, User user); } /// @@ -118,13 +118,13 @@ public String GetBasePath(String basePath) /// /// Create user This can only be done by the logged in user. /// - /// Created user object + /// Created user object /// - public void CreateUser (User body) + public void CreateUser (User user) { - // verify the required parameter 'body' is set - if (body == null) throw new ApiException(400, "Missing required parameter 'body' when calling CreateUser"); + // verify the required parameter 'user' is set + if (user == null) throw new ApiException(400, "Missing required parameter 'user' when calling CreateUser"); var path = "/user"; @@ -136,10 +136,10 @@ public void CreateUser (User body) var fileParams = new Dictionary(); String postBody = null; - postBody = ApiClient.Serialize(body); // http body (model) parameter + postBody = ApiClient.Serialize(user); // http body (model) parameter // authentication setting, if any - String[] authSettings = new String[] { }; + String[] authSettings = new String[] { "auth_cookie" }; // make the HTTP request IRestResponse response = (IRestResponse) ApiClient.CallApi(path, Method.POST, queryParams, postBody, headerParams, formParams, fileParams, authSettings); @@ -155,13 +155,13 @@ public void CreateUser (User body) /// /// Creates list of users with given input array /// - /// List of user object + /// List of user object /// - public void CreateUsersWithArrayInput (List body) + public void CreateUsersWithArrayInput (List user) { - // verify the required parameter 'body' is set - if (body == null) throw new ApiException(400, "Missing required parameter 'body' when calling CreateUsersWithArrayInput"); + // verify the required parameter 'user' is set + if (user == null) throw new ApiException(400, "Missing required parameter 'user' when calling CreateUsersWithArrayInput"); var path = "/user/createWithArray"; @@ -173,10 +173,10 @@ public void CreateUsersWithArrayInput (List body) var fileParams = new Dictionary(); String postBody = null; - postBody = ApiClient.Serialize(body); // http body (model) parameter + postBody = ApiClient.Serialize(user); // http body (model) parameter // authentication setting, if any - String[] authSettings = new String[] { }; + String[] authSettings = new String[] { "auth_cookie" }; // make the HTTP request IRestResponse response = (IRestResponse) ApiClient.CallApi(path, Method.POST, queryParams, postBody, headerParams, formParams, fileParams, authSettings); @@ -192,13 +192,13 @@ public void CreateUsersWithArrayInput (List body) /// /// Creates list of users with given input array /// - /// List of user object + /// List of user object /// - public void CreateUsersWithListInput (List body) + public void CreateUsersWithListInput (List user) { - // verify the required parameter 'body' is set - if (body == null) throw new ApiException(400, "Missing required parameter 'body' when calling CreateUsersWithListInput"); + // verify the required parameter 'user' is set + if (user == null) throw new ApiException(400, "Missing required parameter 'user' when calling CreateUsersWithListInput"); var path = "/user/createWithList"; @@ -210,10 +210,10 @@ public void CreateUsersWithListInput (List body) var fileParams = new Dictionary(); String postBody = null; - postBody = ApiClient.Serialize(body); // http body (model) parameter + postBody = ApiClient.Serialize(user); // http body (model) parameter // authentication setting, if any - String[] authSettings = new String[] { }; + String[] authSettings = new String[] { "auth_cookie" }; // make the HTTP request IRestResponse response = (IRestResponse) ApiClient.CallApi(path, Method.POST, queryParams, postBody, headerParams, formParams, fileParams, authSettings); @@ -250,7 +250,7 @@ public void DeleteUser (string username) // authentication setting, if any - String[] authSettings = new String[] { }; + String[] authSettings = new String[] { "auth_cookie" }; // make the HTTP request IRestResponse response = (IRestResponse) ApiClient.CallApi(path, Method.DELETE, queryParams, postBody, headerParams, formParams, fileParams, authSettings); @@ -361,7 +361,7 @@ public void LogoutUser () // authentication setting, if any - String[] authSettings = new String[] { }; + String[] authSettings = new String[] { "auth_cookie" }; // make the HTTP request IRestResponse response = (IRestResponse) ApiClient.CallApi(path, Method.GET, queryParams, postBody, headerParams, formParams, fileParams, authSettings); @@ -378,16 +378,16 @@ public void LogoutUser () /// Updated user This can only be done by the logged in user. /// /// name that need to be deleted - /// Updated user object + /// Updated user object /// - public void UpdateUser (string username, User body) + public void UpdateUser (string username, User user) { // verify the required parameter 'username' is set if (username == null) throw new ApiException(400, "Missing required parameter 'username' when calling UpdateUser"); - // verify the required parameter 'body' is set - if (body == null) throw new ApiException(400, "Missing required parameter 'body' when calling UpdateUser"); + // verify the required parameter 'user' is set + if (user == null) throw new ApiException(400, "Missing required parameter 'user' when calling UpdateUser"); var path = "/user/{username}"; @@ -400,10 +400,10 @@ public void UpdateUser (string username, User body) var fileParams = new Dictionary(); String postBody = null; - postBody = ApiClient.Serialize(body); // http body (model) parameter + postBody = ApiClient.Serialize(user); // http body (model) parameter // authentication setting, if any - String[] authSettings = new String[] { }; + String[] authSettings = new String[] { "auth_cookie" }; // make the HTTP request IRestResponse response = (IRestResponse) ApiClient.CallApi(path, Method.PUT, queryParams, postBody, headerParams, formParams, fileParams, authSettings); diff --git a/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/src/main/CsharpDotNet2/Org/OpenAPITools/Client/ApiClient.cs b/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/src/main/CsharpDotNet2/Org/OpenAPITools/Client/ApiClient.cs index e1d91307dcfe..b92915007284 100644 --- a/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/src/main/CsharpDotNet2/Org/OpenAPITools/Client/ApiClient.cs +++ b/samples/client/petstore/csharp-dotnet2/OpenAPIClientTest/Lib/OpenAPIClient/src/main/CsharpDotNet2/Org/OpenAPITools/Client/ApiClient.cs @@ -262,6 +262,8 @@ public void UpdateParamsForAuth(Dictionary queryParams, Dictiona case "api_key": headerParams["api_key"] = GetApiKeyWithPrefix("api_key"); break; + case "auth_cookie": + break; case "petstore_auth": headerParams["Authorization"] = "Bearer " + Configuration.AccessToken; break; diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/README.md b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/README.md index 2e2e37841c49..4b200ade794d 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/README.md +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/README.md @@ -79,12 +79,12 @@ namespace Example Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; var apiInstance = new AnotherFakeApi(Configuration.Default); - var body = new ModelClient(); // ModelClient | client model + var modelClient = new ModelClient(); // ModelClient | client model try { // To test special tags - ModelClient result = apiInstance.Call123TestSpecialTags(body); + ModelClient result = apiInstance.Call123TestSpecialTags(modelClient); Debug.WriteLine(result); } catch (ApiException e) @@ -106,7 +106,9 @@ All URIs are relative to *http://petstore.swagger.io:80/v2* Class | Method | HTTP request | Description ------------ | ------------- | ------------- | ------------- *AnotherFakeApi* | [**Call123TestSpecialTags**](docs/AnotherFakeApi.md#call123testspecialtags) | **PATCH** /another-fake/dummy | To test special tags -*FakeApi* | [**CreateXmlItem**](docs/FakeApi.md#createxmlitem) | **POST** /fake/create_xml_item | creates an XmlItem +*DefaultApi* | [**FooGet**](docs/DefaultApi.md#fooget) | **GET** /foo | +*FakeApi* | [**FakeHealthGet**](docs/FakeApi.md#fakehealthget) | **GET** /fake/health | Health check endpoint +*FakeApi* | [**FakeHttpSignatureTest**](docs/FakeApi.md#fakehttpsignaturetest) | **GET** /fake/http-signature-test | test http signature authentication *FakeApi* | [**FakeOuterBooleanSerialize**](docs/FakeApi.md#fakeouterbooleanserialize) | **POST** /fake/outer/boolean | *FakeApi* | [**FakeOuterCompositeSerialize**](docs/FakeApi.md#fakeoutercompositeserialize) | **POST** /fake/outer/composite | *FakeApi* | [**FakeOuterNumberSerialize**](docs/FakeApi.md#fakeouternumberserialize) | **POST** /fake/outer/number | @@ -114,7 +116,7 @@ Class | Method | HTTP request | Description *FakeApi* | [**TestBodyWithFileSchema**](docs/FakeApi.md#testbodywithfileschema) | **PUT** /fake/body-with-file-schema | *FakeApi* | [**TestBodyWithQueryParams**](docs/FakeApi.md#testbodywithqueryparams) | **PUT** /fake/body-with-query-params | *FakeApi* | [**TestClientModel**](docs/FakeApi.md#testclientmodel) | **PATCH** /fake | To test \"client\" model -*FakeApi* | [**TestEndpointParameters**](docs/FakeApi.md#testendpointparameters) | **POST** /fake | Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 +*FakeApi* | [**TestEndpointParameters**](docs/FakeApi.md#testendpointparameters) | **POST** /fake | Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 *FakeApi* | [**TestEnumParameters**](docs/FakeApi.md#testenumparameters) | **GET** /fake | To test enum parameters *FakeApi* | [**TestGroupParameters**](docs/FakeApi.md#testgroupparameters) | **DELETE** /fake | Fake endpoint to test group parameters (optional) *FakeApi* | [**TestInlineAdditionalProperties**](docs/FakeApi.md#testinlineadditionalproperties) | **POST** /fake/inline-additionalProperties | test inline additionalProperties @@ -146,21 +148,12 @@ Class | Method | HTTP request | Description ## Documentation for Models - - [Model.AdditionalPropertiesAnyType](docs/AdditionalPropertiesAnyType.md) - - [Model.AdditionalPropertiesArray](docs/AdditionalPropertiesArray.md) - - [Model.AdditionalPropertiesBoolean](docs/AdditionalPropertiesBoolean.md) - [Model.AdditionalPropertiesClass](docs/AdditionalPropertiesClass.md) - - [Model.AdditionalPropertiesInteger](docs/AdditionalPropertiesInteger.md) - - [Model.AdditionalPropertiesNumber](docs/AdditionalPropertiesNumber.md) - - [Model.AdditionalPropertiesObject](docs/AdditionalPropertiesObject.md) - - [Model.AdditionalPropertiesString](docs/AdditionalPropertiesString.md) - [Model.Animal](docs/Animal.md) - [Model.ApiResponse](docs/ApiResponse.md) - [Model.ArrayOfArrayOfNumberOnly](docs/ArrayOfArrayOfNumberOnly.md) - [Model.ArrayOfNumberOnly](docs/ArrayOfNumberOnly.md) - [Model.ArrayTest](docs/ArrayTest.md) - - [Model.BigCat](docs/BigCat.md) - - [Model.BigCatAllOf](docs/BigCatAllOf.md) - [Model.Capitalization](docs/Capitalization.md) - [Model.Cat](docs/Cat.md) - [Model.CatAllOf](docs/CatAllOf.md) @@ -173,27 +166,37 @@ Class | Method | HTTP request | Description - [Model.EnumTest](docs/EnumTest.md) - [Model.File](docs/File.md) - [Model.FileSchemaTestClass](docs/FileSchemaTestClass.md) + - [Model.Foo](docs/Foo.md) - [Model.FormatTest](docs/FormatTest.md) - [Model.HasOnlyReadOnly](docs/HasOnlyReadOnly.md) + - [Model.HealthCheckResult](docs/HealthCheckResult.md) + - [Model.InlineObject](docs/InlineObject.md) + - [Model.InlineObject1](docs/InlineObject1.md) + - [Model.InlineObject2](docs/InlineObject2.md) + - [Model.InlineObject3](docs/InlineObject3.md) + - [Model.InlineObject4](docs/InlineObject4.md) + - [Model.InlineObject5](docs/InlineObject5.md) + - [Model.InlineResponseDefault](docs/InlineResponseDefault.md) - [Model.List](docs/List.md) - [Model.MapTest](docs/MapTest.md) - [Model.MixedPropertiesAndAdditionalPropertiesClass](docs/MixedPropertiesAndAdditionalPropertiesClass.md) - [Model.Model200Response](docs/Model200Response.md) - [Model.ModelClient](docs/ModelClient.md) - [Model.Name](docs/Name.md) + - [Model.NullableClass](docs/NullableClass.md) - [Model.NumberOnly](docs/NumberOnly.md) - [Model.Order](docs/Order.md) - [Model.OuterComposite](docs/OuterComposite.md) - [Model.OuterEnum](docs/OuterEnum.md) + - [Model.OuterEnumDefaultValue](docs/OuterEnumDefaultValue.md) + - [Model.OuterEnumInteger](docs/OuterEnumInteger.md) + - [Model.OuterEnumIntegerDefaultValue](docs/OuterEnumIntegerDefaultValue.md) - [Model.Pet](docs/Pet.md) - [Model.ReadOnlyFirst](docs/ReadOnlyFirst.md) - [Model.Return](docs/Return.md) - [Model.SpecialModelName](docs/SpecialModelName.md) - [Model.Tag](docs/Tag.md) - - [Model.TypeHolderDefault](docs/TypeHolderDefault.md) - - [Model.TypeHolderExample](docs/TypeHolderExample.md) - [Model.User](docs/User.md) - - [Model.XmlItem](docs/XmlItem.md) ## Documentation for Authorization @@ -215,12 +218,22 @@ Class | Method | HTTP request | Description - **Location**: URL query string +### bearer_test + + +- **Type**: HTTP bearer authentication + + ### http_basic_test - **Type**: HTTP basic authentication +### http_signature_test + + + ### petstore_auth diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/AdditionalPropertiesClass.md b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/AdditionalPropertiesClass.md index d07f57619d5e..847bf120968f 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/AdditionalPropertiesClass.md +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/AdditionalPropertiesClass.md @@ -5,17 +5,8 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**MapString** | **Dictionary<string, string>** | | [optional] -**MapNumber** | **Dictionary<string, decimal>** | | [optional] -**MapInteger** | **Dictionary<string, int>** | | [optional] -**MapBoolean** | **Dictionary<string, bool>** | | [optional] -**MapArrayInteger** | **Dictionary<string, List<int>>** | | [optional] -**MapArrayAnytype** | **Dictionary<string, List<Object>>** | | [optional] -**MapMapString** | **Dictionary<string, Dictionary<string, string>>** | | [optional] -**MapMapAnytype** | **Dictionary<string, Dictionary<string, Object>>** | | [optional] -**Anytype1** | [**Object**](.md) | | [optional] -**Anytype2** | [**Object**](.md) | | [optional] -**Anytype3** | [**Object**](.md) | | [optional] +**MapProperty** | **Dictionary<string, string>** | | [optional] +**MapOfMapProperty** | **Dictionary<string, Dictionary<string, string>>** | | [optional] [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/AnotherFakeApi.md b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/AnotherFakeApi.md index 5af41a1862c2..c7cb3d05138b 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/AnotherFakeApi.md +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/AnotherFakeApi.md @@ -10,7 +10,7 @@ Method | HTTP request | Description ## Call123TestSpecialTags -> ModelClient Call123TestSpecialTags (ModelClient body) +> ModelClient Call123TestSpecialTags (ModelClient modelClient) To test special tags @@ -33,12 +33,12 @@ namespace Example { Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; var apiInstance = new AnotherFakeApi(Configuration.Default); - var body = new ModelClient(); // ModelClient | client model + var modelClient = new ModelClient(); // ModelClient | client model try { // To test special tags - ModelClient result = apiInstance.Call123TestSpecialTags(body); + ModelClient result = apiInstance.Call123TestSpecialTags(modelClient); Debug.WriteLine(result); } catch (ApiException e) @@ -57,7 +57,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**ModelClient**](ModelClient.md)| client model | + **modelClient** | [**ModelClient**](ModelClient.md)| client model | ### Return type diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/DefaultApi.md b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/DefaultApi.md index 92f2dc125c04..7ee074eba27c 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/DefaultApi.md +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/DefaultApi.md @@ -7,15 +7,17 @@ Method | HTTP request | Description [**FooGet**](DefaultApi.md#fooget) | **GET** /foo | - -# **FooGet** + +## FooGet + > InlineResponseDefault FooGet () ### Example + ```csharp -using System; +using System.Collections.Generic; using System.Diagnostics; using Org.OpenAPITools.Api; using Org.OpenAPITools.Client; @@ -25,18 +27,21 @@ namespace Example { public class FooGetExample { - public void main() + public static void Main() { - var apiInstance = new DefaultApi(); + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new DefaultApi(Configuration.Default); try { InlineResponseDefault result = apiInstance.FooGet(); Debug.WriteLine(result); } - catch (Exception e) + catch (ApiException e) { Debug.Print("Exception when calling DefaultApi.FooGet: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); } } } @@ -44,6 +49,7 @@ namespace Example ``` ### Parameters + This endpoint does not need any parameter. ### Return type @@ -56,8 +62,16 @@ No authorization required ### HTTP request headers - - **Content-Type**: Not defined - - **Accept**: application/json +- **Content-Type**: Not defined +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **0** | response | - | -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/EnumTest.md b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/EnumTest.md index f8bc67baa6ab..a8a888d45249 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/EnumTest.md +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/EnumTest.md @@ -10,6 +10,9 @@ Name | Type | Description | Notes **EnumInteger** | **int** | | [optional] **EnumNumber** | **double** | | [optional] **OuterEnum** | **OuterEnum** | | [optional] +**OuterEnumInteger** | **OuterEnumInteger** | | [optional] +**OuterEnumDefaultValue** | **OuterEnumDefaultValue** | | [optional] +**OuterEnumIntegerDefaultValue** | **OuterEnumIntegerDefaultValue** | | [optional] [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/FakeApi.md b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/FakeApi.md index 661c2cba6ab3..38ab478e715b 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/FakeApi.md +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/FakeApi.md @@ -4,7 +4,8 @@ All URIs are relative to *http://petstore.swagger.io:80/v2* Method | HTTP request | Description ------------- | ------------- | ------------- -[**CreateXmlItem**](FakeApi.md#createxmlitem) | **POST** /fake/create_xml_item | creates an XmlItem +[**FakeHealthGet**](FakeApi.md#fakehealthget) | **GET** /fake/health | Health check endpoint +[**FakeHttpSignatureTest**](FakeApi.md#fakehttpsignaturetest) | **GET** /fake/http-signature-test | test http signature authentication [**FakeOuterBooleanSerialize**](FakeApi.md#fakeouterbooleanserialize) | **POST** /fake/outer/boolean | [**FakeOuterCompositeSerialize**](FakeApi.md#fakeoutercompositeserialize) | **POST** /fake/outer/composite | [**FakeOuterNumberSerialize**](FakeApi.md#fakeouternumberserialize) | **POST** /fake/outer/number | @@ -12,7 +13,7 @@ Method | HTTP request | Description [**TestBodyWithFileSchema**](FakeApi.md#testbodywithfileschema) | **PUT** /fake/body-with-file-schema | [**TestBodyWithQueryParams**](FakeApi.md#testbodywithqueryparams) | **PUT** /fake/body-with-query-params | [**TestClientModel**](FakeApi.md#testclientmodel) | **PATCH** /fake | To test \"client\" model -[**TestEndpointParameters**](FakeApi.md#testendpointparameters) | **POST** /fake | Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 +[**TestEndpointParameters**](FakeApi.md#testendpointparameters) | **POST** /fake | Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 [**TestEnumParameters**](FakeApi.md#testenumparameters) | **GET** /fake | To test enum parameters [**TestGroupParameters**](FakeApi.md#testgroupparameters) | **DELETE** /fake | Fake endpoint to test group parameters (optional) [**TestInlineAdditionalProperties**](FakeApi.md#testinlineadditionalproperties) | **POST** /fake/inline-additionalProperties | test inline additionalProperties @@ -21,13 +22,80 @@ Method | HTTP request | Description -## CreateXmlItem +## FakeHealthGet -> void CreateXmlItem (XmlItem xmlItem) +> HealthCheckResult FakeHealthGet () -creates an XmlItem +Health check endpoint -this route creates an XmlItem +### Example + +```csharp +using System.Collections.Generic; +using System.Diagnostics; +using Org.OpenAPITools.Api; +using Org.OpenAPITools.Client; +using Org.OpenAPITools.Model; + +namespace Example +{ + public class FakeHealthGetExample + { + public static void Main() + { + Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new FakeApi(Configuration.Default); + + try + { + // Health check endpoint + HealthCheckResult result = apiInstance.FakeHealthGet(); + Debug.WriteLine(result); + } + catch (ApiException e) + { + Debug.Print("Exception when calling FakeApi.FakeHealthGet: " + e.Message ); + Debug.Print("Status Code: "+ e.ErrorCode); + Debug.Print(e.StackTrace); + } + } + } +} +``` + +### Parameters + +This endpoint does not need any parameter. + +### Return type + +[**HealthCheckResult**](HealthCheckResult.md) + +### Authorization + +No authorization required + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +| **200** | The instance started successfully | - | + +[[Back to top]](#) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) + + +## FakeHttpSignatureTest + +> void FakeHttpSignatureTest (Pet pet, string query1 = null, string header1 = null) + +test http signature authentication ### Example @@ -40,22 +108,25 @@ using Org.OpenAPITools.Model; namespace Example { - public class CreateXmlItemExample + public class FakeHttpSignatureTestExample { public static void Main() { Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + var apiInstance = new FakeApi(Configuration.Default); - var xmlItem = new XmlItem(); // XmlItem | XmlItem Body + var pet = new Pet(); // Pet | Pet object that needs to be added to the store + var query1 = query1_example; // string | query parameter (optional) + var header1 = header1_example; // string | header parameter (optional) try { - // creates an XmlItem - apiInstance.CreateXmlItem(xmlItem); + // test http signature authentication + apiInstance.FakeHttpSignatureTest(pet, query1, header1); } catch (ApiException e) { - Debug.Print("Exception when calling FakeApi.CreateXmlItem: " + e.Message ); + Debug.Print("Exception when calling FakeApi.FakeHttpSignatureTest: " + e.Message ); Debug.Print("Status Code: "+ e.ErrorCode); Debug.Print(e.StackTrace); } @@ -69,7 +140,9 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **xmlItem** | [**XmlItem**](XmlItem.md)| XmlItem Body | + **pet** | [**Pet**](Pet.md)| Pet object that needs to be added to the store | + **query1** | **string**| query parameter | [optional] + **header1** | **string**| header parameter | [optional] ### Return type @@ -77,17 +150,17 @@ void (empty response body) ### Authorization -No authorization required +[http_signature_test](../README.md#http_signature_test) ### HTTP request headers -- **Content-Type**: application/xml, application/xml; charset=utf-8, application/xml; charset=utf-16, text/xml, text/xml; charset=utf-8, text/xml; charset=utf-16 +- **Content-Type**: application/json, application/xml - **Accept**: Not defined ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **200** | successful operation | - | +| **200** | The instance started successfully | - | [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) @@ -155,7 +228,7 @@ No authorization required ### HTTP request headers -- **Content-Type**: Not defined +- **Content-Type**: application/json - **Accept**: */* ### HTTP response details @@ -171,7 +244,7 @@ No authorization required ## FakeOuterCompositeSerialize -> OuterComposite FakeOuterCompositeSerialize (OuterComposite body = null) +> OuterComposite FakeOuterCompositeSerialize (OuterComposite outerComposite = null) @@ -194,11 +267,11 @@ namespace Example { Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; var apiInstance = new FakeApi(Configuration.Default); - var body = new OuterComposite(); // OuterComposite | Input composite as post body (optional) + var outerComposite = new OuterComposite(); // OuterComposite | Input composite as post body (optional) try { - OuterComposite result = apiInstance.FakeOuterCompositeSerialize(body); + OuterComposite result = apiInstance.FakeOuterCompositeSerialize(outerComposite); Debug.WriteLine(result); } catch (ApiException e) @@ -217,7 +290,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**OuterComposite**](OuterComposite.md)| Input composite as post body | [optional] + **outerComposite** | [**OuterComposite**](OuterComposite.md)| Input composite as post body | [optional] ### Return type @@ -229,7 +302,7 @@ No authorization required ### HTTP request headers -- **Content-Type**: Not defined +- **Content-Type**: application/json - **Accept**: */* ### HTTP response details @@ -303,7 +376,7 @@ No authorization required ### HTTP request headers -- **Content-Type**: Not defined +- **Content-Type**: application/json - **Accept**: */* ### HTTP response details @@ -377,7 +450,7 @@ No authorization required ### HTTP request headers -- **Content-Type**: Not defined +- **Content-Type**: application/json - **Accept**: */* ### HTTP response details @@ -393,7 +466,7 @@ No authorization required ## TestBodyWithFileSchema -> void TestBodyWithFileSchema (FileSchemaTestClass body) +> void TestBodyWithFileSchema (FileSchemaTestClass fileSchemaTestClass) @@ -416,11 +489,11 @@ namespace Example { Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; var apiInstance = new FakeApi(Configuration.Default); - var body = new FileSchemaTestClass(); // FileSchemaTestClass | + var fileSchemaTestClass = new FileSchemaTestClass(); // FileSchemaTestClass | try { - apiInstance.TestBodyWithFileSchema(body); + apiInstance.TestBodyWithFileSchema(fileSchemaTestClass); } catch (ApiException e) { @@ -438,7 +511,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**FileSchemaTestClass**](FileSchemaTestClass.md)| | + **fileSchemaTestClass** | [**FileSchemaTestClass**](FileSchemaTestClass.md)| | ### Return type @@ -466,7 +539,7 @@ No authorization required ## TestBodyWithQueryParams -> void TestBodyWithQueryParams (string query, User body) +> void TestBodyWithQueryParams (string query, User user) @@ -488,11 +561,11 @@ namespace Example Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; var apiInstance = new FakeApi(Configuration.Default); var query = query_example; // string | - var body = new User(); // User | + var user = new User(); // User | try { - apiInstance.TestBodyWithQueryParams(query, body); + apiInstance.TestBodyWithQueryParams(query, user); } catch (ApiException e) { @@ -511,7 +584,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **query** | **string**| | - **body** | [**User**](User.md)| | + **user** | [**User**](User.md)| | ### Return type @@ -539,7 +612,7 @@ No authorization required ## TestClientModel -> ModelClient TestClientModel (ModelClient body) +> ModelClient TestClientModel (ModelClient modelClient) To test \"client\" model @@ -562,12 +635,12 @@ namespace Example { Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; var apiInstance = new FakeApi(Configuration.Default); - var body = new ModelClient(); // ModelClient | client model + var modelClient = new ModelClient(); // ModelClient | client model try { // To test \"client\" model - ModelClient result = apiInstance.TestClientModel(body); + ModelClient result = apiInstance.TestClientModel(modelClient); Debug.WriteLine(result); } catch (ApiException e) @@ -586,7 +659,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**ModelClient**](ModelClient.md)| client model | + **modelClient** | [**ModelClient**](ModelClient.md)| client model | ### Return type @@ -616,9 +689,9 @@ No authorization required > void TestEndpointParameters (decimal number, double _double, string patternWithoutDelimiter, byte[] _byte, int? integer = null, int? int32 = null, long? int64 = null, float? _float = null, string _string = null, System.IO.Stream binary = null, DateTime? date = null, DateTime? dateTime = null, string password = null, string callback = null) -Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 +Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 -Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 +Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 ### Example @@ -658,7 +731,7 @@ namespace Example try { - // Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + // Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 apiInstance.TestEndpointParameters(number, _double, patternWithoutDelimiter, _byte, integer, int32, int64, _float, _string, binary, date, dateTime, password, callback); } catch (ApiException e) @@ -830,6 +903,9 @@ namespace Example public static void Main() { Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; + // Configure HTTP bearer authorization: bearer_test + Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN"; + var apiInstance = new FakeApi(Configuration.Default); var requiredStringGroup = 56; // int | Required String in group parameters var requiredBooleanGroup = true; // bool | Required Boolean in group parameters @@ -872,7 +948,7 @@ void (empty response body) ### Authorization -No authorization required +[bearer_test](../README.md#bearer_test) ### HTTP request headers @@ -892,7 +968,7 @@ No authorization required ## TestInlineAdditionalProperties -> void TestInlineAdditionalProperties (Dictionary param) +> void TestInlineAdditionalProperties (Dictionary requestBody) test inline additionalProperties @@ -913,12 +989,12 @@ namespace Example { Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; var apiInstance = new FakeApi(Configuration.Default); - var param = new Dictionary(); // Dictionary | request body + var requestBody = new Dictionary(); // Dictionary | request body try { // test inline additionalProperties - apiInstance.TestInlineAdditionalProperties(param); + apiInstance.TestInlineAdditionalProperties(requestBody); } catch (ApiException e) { @@ -936,7 +1012,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **param** | [**Dictionary<string, string>**](string.md)| request body | + **requestBody** | [**Dictionary<string, string>**](string.md)| request body | ### Return type diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/FakeClassnameTags123Api.md b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/FakeClassnameTags123Api.md index deb97a27697f..93eb8b274552 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/FakeClassnameTags123Api.md +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/FakeClassnameTags123Api.md @@ -10,7 +10,7 @@ Method | HTTP request | Description ## TestClassname -> ModelClient TestClassname (ModelClient body) +> ModelClient TestClassname (ModelClient modelClient) To test class name in snake case @@ -38,12 +38,12 @@ namespace Example // Configuration.Default.AddApiKeyPrefix("api_key_query", "Bearer"); var apiInstance = new FakeClassnameTags123Api(Configuration.Default); - var body = new ModelClient(); // ModelClient | client model + var modelClient = new ModelClient(); // ModelClient | client model try { // To test class name in snake case - ModelClient result = apiInstance.TestClassname(body); + ModelClient result = apiInstance.TestClassname(modelClient); Debug.WriteLine(result); } catch (ApiException e) @@ -62,7 +62,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**ModelClient**](ModelClient.md)| client model | + **modelClient** | [**ModelClient**](ModelClient.md)| client model | ### Return type diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/Foo.md b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/Foo.md index fd84dc2038c9..ea6f4245da6e 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/Foo.md +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/Foo.md @@ -1,9 +1,13 @@ + # Org.OpenAPITools.Model.Foo + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **Bar** | **string** | | [optional] [default to "bar"] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/FormatTest.md b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/FormatTest.md index 92d7d1e0104d..6cef48d5b4db 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/FormatTest.md +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/FormatTest.md @@ -18,7 +18,8 @@ Name | Type | Description | Notes **DateTime** | **DateTime** | | [optional] **Uuid** | **Guid** | | [optional] **Password** | **string** | | -**BigDecimal** | **decimal** | | [optional] +**PatternWithDigits** | **string** | A string that is a 10 digit number. Can have leading zeros. | [optional] +**PatternWithDigitsAndDelimiter** | **string** | A string starting with 'image_' (case insensitive) and one to three digits following i.e. Image_01. | [optional] [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/HealthCheckResult.md b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/HealthCheckResult.md index c8f299aaa258..08e5992d20cb 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/HealthCheckResult.md +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/HealthCheckResult.md @@ -1,9 +1,13 @@ + # Org.OpenAPITools.Model.HealthCheckResult + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **NullableMessage** | **string** | | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/InlineObject.md b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/InlineObject.md index 40e16da1bb7d..12ec90a8c699 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/InlineObject.md +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/InlineObject.md @@ -1,4 +1,6 @@ + # Org.OpenAPITools.Model.InlineObject + ## Properties Name | Type | Description | Notes @@ -6,5 +8,7 @@ Name | Type | Description | Notes **Name** | **string** | Updated name of the pet | [optional] **Status** | **string** | Updated status of the pet | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/InlineObject1.md b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/InlineObject1.md index 2e6d226754e4..581fe20b1e21 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/InlineObject1.md +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/InlineObject1.md @@ -1,4 +1,6 @@ + # Org.OpenAPITools.Model.InlineObject1 + ## Properties Name | Type | Description | Notes @@ -6,5 +8,7 @@ Name | Type | Description | Notes **AdditionalMetadata** | **string** | Additional data to pass to server | [optional] **File** | **System.IO.Stream** | file to upload | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/InlineObject2.md b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/InlineObject2.md index c02c78f9b2d0..79abb7a467c4 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/InlineObject2.md +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/InlineObject2.md @@ -1,4 +1,6 @@ + # Org.OpenAPITools.Model.InlineObject2 + ## Properties Name | Type | Description | Notes @@ -6,5 +8,7 @@ Name | Type | Description | Notes **EnumFormStringArray** | **List<string>** | Form parameter enum test (string array) | [optional] **EnumFormString** | **string** | Form parameter enum test (string) | [optional] [default to EnumFormStringEnum.Efg] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/InlineObject3.md b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/InlineObject3.md index 192926bbe927..684db7f7227b 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/InlineObject3.md +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/InlineObject3.md @@ -1,22 +1,26 @@ + # Org.OpenAPITools.Model.InlineObject3 + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Integer** | **int?** | None | [optional] -**Int32** | **int?** | None | [optional] -**Int64** | **long?** | None | [optional] -**Number** | **decimal?** | None | -**Float** | **float?** | None | [optional] -**Double** | **double?** | None | +**Integer** | **int** | None | [optional] +**Int32** | **int** | None | [optional] +**Int64** | **long** | None | [optional] +**Number** | **decimal** | None | +**Float** | **float** | None | [optional] +**Double** | **double** | None | **String** | **string** | None | [optional] **PatternWithoutDelimiter** | **string** | None | **Byte** | **byte[]** | None | **Binary** | **System.IO.Stream** | None | [optional] -**Date** | **DateTime?** | None | [optional] -**DateTime** | **DateTime?** | None | [optional] +**Date** | **DateTime** | None | [optional] +**DateTime** | **DateTime** | None | [optional] **Password** | **string** | None | [optional] **Callback** | **string** | None | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/InlineObject4.md b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/InlineObject4.md index c8e00663ee88..18e4a1f3ce50 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/InlineObject4.md +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/InlineObject4.md @@ -1,4 +1,6 @@ + # Org.OpenAPITools.Model.InlineObject4 + ## Properties Name | Type | Description | Notes @@ -6,5 +8,7 @@ Name | Type | Description | Notes **Param** | **string** | field1 | **Param2** | **string** | field2 | -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/InlineObject5.md b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/InlineObject5.md index a28ff47f2ec0..291c88623eea 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/InlineObject5.md +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/InlineObject5.md @@ -1,4 +1,6 @@ + # Org.OpenAPITools.Model.InlineObject5 + ## Properties Name | Type | Description | Notes @@ -6,5 +8,7 @@ Name | Type | Description | Notes **AdditionalMetadata** | **string** | Additional data to pass to server | [optional] **RequiredFile** | **System.IO.Stream** | file to upload | -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/InlineResponseDefault.md b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/InlineResponseDefault.md index 8c96fb62ac88..ecfb254001a2 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/InlineResponseDefault.md +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/InlineResponseDefault.md @@ -1,9 +1,13 @@ + # Org.OpenAPITools.Model.InlineResponseDefault + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **String** | [**Foo**](Foo.md) | | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/NullableClass.md b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/NullableClass.md index 0ca2455a4ab2..84dd092d8a38 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/NullableClass.md +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/NullableClass.md @@ -1,4 +1,6 @@ + # Org.OpenAPITools.Model.NullableClass + ## Properties Name | Type | Description | Notes @@ -16,5 +18,7 @@ Name | Type | Description | Notes **ObjectAndItemsNullableProp** | **Dictionary<string, Object>** | | [optional] **ObjectItemsNullable** | **Dictionary<string, Object>** | | [optional] -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/OuterEnumDefaultValue.md b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/OuterEnumDefaultValue.md index 09f6b91ee623..41474099f2ee 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/OuterEnumDefaultValue.md +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/OuterEnumDefaultValue.md @@ -1,8 +1,12 @@ + # Org.OpenAPITools.Model.OuterEnumDefaultValue + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/OuterEnumInteger.md b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/OuterEnumInteger.md index 149bb5a8dd16..b82abc3adac4 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/OuterEnumInteger.md +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/OuterEnumInteger.md @@ -1,8 +1,12 @@ + # Org.OpenAPITools.Model.OuterEnumInteger + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/OuterEnumIntegerDefaultValue.md b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/OuterEnumIntegerDefaultValue.md index 29de71509745..46939d01522e 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/OuterEnumIntegerDefaultValue.md +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/OuterEnumIntegerDefaultValue.md @@ -1,8 +1,12 @@ + # Org.OpenAPITools.Model.OuterEnumIntegerDefaultValue + ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to README]](../README.md) diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/PetApi.md b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/PetApi.md index 1a9eba14868f..5d9c6cb6f791 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/PetApi.md +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/PetApi.md @@ -18,7 +18,7 @@ Method | HTTP request | Description ## AddPet -> void AddPet (Pet body) +> void AddPet (Pet pet) Add a new pet to the store @@ -42,12 +42,12 @@ namespace Example Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN"; var apiInstance = new PetApi(Configuration.Default); - var body = new Pet(); // Pet | Pet object that needs to be added to the store + var pet = new Pet(); // Pet | Pet object that needs to be added to the store try { // Add a new pet to the store - apiInstance.AddPet(body); + apiInstance.AddPet(pet); } catch (ApiException e) { @@ -65,7 +65,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**Pet**](Pet.md)| Pet object that needs to be added to the store | + **pet** | [**Pet**](Pet.md)| Pet object that needs to be added to the store | ### Return type @@ -83,7 +83,6 @@ void (empty response body) ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **200** | successful operation | - | | **405** | Invalid input | - | [[Back to top]](#) @@ -161,7 +160,6 @@ void (empty response body) ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **200** | successful operation | - | | **400** | Invalid pet value | - | [[Back to top]](#) @@ -412,7 +410,7 @@ Name | Type | Description | Notes ## UpdatePet -> void UpdatePet (Pet body) +> void UpdatePet (Pet pet) Update an existing pet @@ -436,12 +434,12 @@ namespace Example Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN"; var apiInstance = new PetApi(Configuration.Default); - var body = new Pet(); // Pet | Pet object that needs to be added to the store + var pet = new Pet(); // Pet | Pet object that needs to be added to the store try { // Update an existing pet - apiInstance.UpdatePet(body); + apiInstance.UpdatePet(pet); } catch (ApiException e) { @@ -459,7 +457,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**Pet**](Pet.md)| Pet object that needs to be added to the store | + **pet** | [**Pet**](Pet.md)| Pet object that needs to be added to the store | ### Return type @@ -477,7 +475,6 @@ void (empty response body) ### HTTP response details | Status code | Description | Response headers | |-------------|-------------|------------------| -| **200** | successful operation | - | | **400** | Invalid ID supplied | - | | **404** | Pet not found | - | | **405** | Validation exception | - | diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/StoreApi.md b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/StoreApi.md index 57247772d4ff..d3c3c7c54053 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/StoreApi.md +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/StoreApi.md @@ -241,7 +241,7 @@ No authorization required ## PlaceOrder -> Order PlaceOrder (Order body) +> Order PlaceOrder (Order order) Place an order for a pet @@ -262,12 +262,12 @@ namespace Example { Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; var apiInstance = new StoreApi(Configuration.Default); - var body = new Order(); // Order | order placed for purchasing the pet + var order = new Order(); // Order | order placed for purchasing the pet try { // Place an order for a pet - Order result = apiInstance.PlaceOrder(body); + Order result = apiInstance.PlaceOrder(order); Debug.WriteLine(result); } catch (ApiException e) @@ -286,7 +286,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**Order**](Order.md)| order placed for purchasing the pet | + **order** | [**Order**](Order.md)| order placed for purchasing the pet | ### Return type @@ -298,7 +298,7 @@ No authorization required ### HTTP request headers -- **Content-Type**: Not defined +- **Content-Type**: application/json - **Accept**: application/xml, application/json ### HTTP response details diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/UserApi.md b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/UserApi.md index 1385d840413c..7c37179a9102 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/UserApi.md +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/docs/UserApi.md @@ -17,7 +17,7 @@ Method | HTTP request | Description ## CreateUser -> void CreateUser (User body) +> void CreateUser (User user) Create user @@ -40,12 +40,12 @@ namespace Example { Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; var apiInstance = new UserApi(Configuration.Default); - var body = new User(); // User | Created user object + var user = new User(); // User | Created user object try { // Create user - apiInstance.CreateUser(body); + apiInstance.CreateUser(user); } catch (ApiException e) { @@ -63,7 +63,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**User**](User.md)| Created user object | + **user** | [**User**](User.md)| Created user object | ### Return type @@ -75,7 +75,7 @@ No authorization required ### HTTP request headers -- **Content-Type**: Not defined +- **Content-Type**: application/json - **Accept**: Not defined ### HTTP response details @@ -91,7 +91,7 @@ No authorization required ## CreateUsersWithArrayInput -> void CreateUsersWithArrayInput (List body) +> void CreateUsersWithArrayInput (List user) Creates list of users with given input array @@ -112,12 +112,12 @@ namespace Example { Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; var apiInstance = new UserApi(Configuration.Default); - var body = new List(); // List | List of user object + var user = new List(); // List | List of user object try { // Creates list of users with given input array - apiInstance.CreateUsersWithArrayInput(body); + apiInstance.CreateUsersWithArrayInput(user); } catch (ApiException e) { @@ -135,7 +135,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**List<User>**](User.md)| List of user object | + **user** | [**List<User>**](User.md)| List of user object | ### Return type @@ -147,7 +147,7 @@ No authorization required ### HTTP request headers -- **Content-Type**: Not defined +- **Content-Type**: application/json - **Accept**: Not defined ### HTTP response details @@ -163,7 +163,7 @@ No authorization required ## CreateUsersWithListInput -> void CreateUsersWithListInput (List body) +> void CreateUsersWithListInput (List user) Creates list of users with given input array @@ -184,12 +184,12 @@ namespace Example { Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; var apiInstance = new UserApi(Configuration.Default); - var body = new List(); // List | List of user object + var user = new List(); // List | List of user object try { // Creates list of users with given input array - apiInstance.CreateUsersWithListInput(body); + apiInstance.CreateUsersWithListInput(user); } catch (ApiException e) { @@ -207,7 +207,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**List<User>**](User.md)| List of user object | + **user** | [**List<User>**](User.md)| List of user object | ### Return type @@ -219,7 +219,7 @@ No authorization required ### HTTP request headers -- **Content-Type**: Not defined +- **Content-Type**: application/json - **Accept**: Not defined ### HTTP response details @@ -529,7 +529,7 @@ No authorization required ## UpdateUser -> void UpdateUser (string username, User body) +> void UpdateUser (string username, User user) Updated user @@ -553,12 +553,12 @@ namespace Example Configuration.Default.BasePath = "http://petstore.swagger.io:80/v2"; var apiInstance = new UserApi(Configuration.Default); var username = username_example; // string | name that need to be deleted - var body = new User(); // User | Updated user object + var user = new User(); // User | Updated user object try { // Updated user - apiInstance.UpdateUser(username, body); + apiInstance.UpdateUser(username, user); } catch (ApiException e) { @@ -577,7 +577,7 @@ namespace Example Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **username** | **string**| name that need to be deleted | - **body** | [**User**](User.md)| Updated user object | + **user** | [**User**](User.md)| Updated user object | ### Return type @@ -589,7 +589,7 @@ No authorization required ### HTTP request headers -- **Content-Type**: Not defined +- **Content-Type**: application/json - **Accept**: Not defined ### HTTP response details diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Api/AnotherFakeApi.cs b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Api/AnotherFakeApi.cs index 142c089e7066..558709f5d014 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Api/AnotherFakeApi.cs +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Api/AnotherFakeApi.cs @@ -31,9 +31,9 @@ public interface IAnotherFakeApi : IApiAccessor /// To test special tags and operation ID starting with number /// /// Thrown when fails to make API call - /// client model + /// client model /// ModelClient - ModelClient Call123TestSpecialTags (ModelClient body); + ModelClient Call123TestSpecialTags (ModelClient modelClient); /// /// To test special tags @@ -42,9 +42,9 @@ public interface IAnotherFakeApi : IApiAccessor /// To test special tags and operation ID starting with number /// /// Thrown when fails to make API call - /// client model + /// client model /// ApiResponse of ModelClient - ApiResponse Call123TestSpecialTagsWithHttpInfo (ModelClient body); + ApiResponse Call123TestSpecialTagsWithHttpInfo (ModelClient modelClient); #endregion Synchronous Operations #region Asynchronous Operations /// @@ -54,9 +54,9 @@ public interface IAnotherFakeApi : IApiAccessor /// To test special tags and operation ID starting with number /// /// Thrown when fails to make API call - /// client model + /// client model /// Task of ModelClient - System.Threading.Tasks.Task Call123TestSpecialTagsAsync (ModelClient body); + System.Threading.Tasks.Task Call123TestSpecialTagsAsync (ModelClient modelClient); /// /// To test special tags @@ -65,9 +65,9 @@ public interface IAnotherFakeApi : IApiAccessor /// To test special tags and operation ID starting with number /// /// Thrown when fails to make API call - /// client model + /// client model /// Task of ApiResponse (ModelClient) - System.Threading.Tasks.Task> Call123TestSpecialTagsAsyncWithHttpInfo (ModelClient body); + System.Threading.Tasks.Task> Call123TestSpecialTagsAsyncWithHttpInfo (ModelClient modelClient); #endregion Asynchronous Operations } @@ -183,11 +183,11 @@ public void AddDefaultHeader(string key, string value) /// To test special tags To test special tags and operation ID starting with number /// /// Thrown when fails to make API call - /// client model + /// client model /// ModelClient - public ModelClient Call123TestSpecialTags (ModelClient body) + public ModelClient Call123TestSpecialTags (ModelClient modelClient) { - ApiResponse localVarResponse = Call123TestSpecialTagsWithHttpInfo(body); + ApiResponse localVarResponse = Call123TestSpecialTagsWithHttpInfo(modelClient); return localVarResponse.Data; } @@ -195,13 +195,13 @@ public ModelClient Call123TestSpecialTags (ModelClient body) /// To test special tags To test special tags and operation ID starting with number /// /// Thrown when fails to make API call - /// client model + /// client model /// ApiResponse of ModelClient - public ApiResponse Call123TestSpecialTagsWithHttpInfo (ModelClient body) + public ApiResponse Call123TestSpecialTagsWithHttpInfo (ModelClient modelClient) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling AnotherFakeApi->Call123TestSpecialTags"); + // verify the required parameter 'modelClient' is set + if (modelClient == null) + throw new ApiException(400, "Missing required parameter 'modelClient' when calling AnotherFakeApi->Call123TestSpecialTags"); var localVarPath = "/another-fake/dummy"; var localVarPathParams = new Dictionary(); @@ -225,13 +225,13 @@ public ApiResponse Call123TestSpecialTagsWithHttpInfo (ModelClient if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (modelClient != null && modelClient.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(modelClient); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = modelClient; // byte array } @@ -257,11 +257,11 @@ public ApiResponse Call123TestSpecialTagsWithHttpInfo (ModelClient /// To test special tags To test special tags and operation ID starting with number /// /// Thrown when fails to make API call - /// client model + /// client model /// Task of ModelClient - public async System.Threading.Tasks.Task Call123TestSpecialTagsAsync (ModelClient body) + public async System.Threading.Tasks.Task Call123TestSpecialTagsAsync (ModelClient modelClient) { - ApiResponse localVarResponse = await Call123TestSpecialTagsAsyncWithHttpInfo(body); + ApiResponse localVarResponse = await Call123TestSpecialTagsAsyncWithHttpInfo(modelClient); return localVarResponse.Data; } @@ -270,13 +270,13 @@ public async System.Threading.Tasks.Task Call123TestSpecialTagsAsyn /// To test special tags To test special tags and operation ID starting with number /// /// Thrown when fails to make API call - /// client model + /// client model /// Task of ApiResponse (ModelClient) - public async System.Threading.Tasks.Task> Call123TestSpecialTagsAsyncWithHttpInfo (ModelClient body) + public async System.Threading.Tasks.Task> Call123TestSpecialTagsAsyncWithHttpInfo (ModelClient modelClient) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling AnotherFakeApi->Call123TestSpecialTags"); + // verify the required parameter 'modelClient' is set + if (modelClient == null) + throw new ApiException(400, "Missing required parameter 'modelClient' when calling AnotherFakeApi->Call123TestSpecialTags"); var localVarPath = "/another-fake/dummy"; var localVarPathParams = new Dictionary(); @@ -300,13 +300,13 @@ public async System.Threading.Tasks.Task> Call123TestSp if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (modelClient != null && modelClient.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(modelClient); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = modelClient; // byte array } diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Api/DefaultApi.cs b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Api/DefaultApi.cs index 20e11dbf458e..9a524e2177be 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Api/DefaultApi.cs +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Api/DefaultApi.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -191,7 +191,7 @@ public InlineResponseDefault FooGet () /// /// Thrown when fails to make API call /// ApiResponse of InlineResponseDefault - public ApiResponse< InlineResponseDefault > FooGetWithHttpInfo () + public ApiResponse FooGetWithHttpInfo () { var localVarPath = "/foo"; diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Api/FakeApi.cs b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Api/FakeApi.cs index d739d62f0a98..03488173822d 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Api/FakeApi.cs +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Api/FakeApi.cs @@ -25,26 +25,49 @@ public interface IFakeApi : IApiAccessor { #region Synchronous Operations /// - /// creates an XmlItem + /// Health check endpoint /// /// - /// this route creates an XmlItem + /// + /// + /// Thrown when fails to make API call + /// HealthCheckResult + HealthCheckResult FakeHealthGet (); + + /// + /// Health check endpoint + /// + /// + /// + /// + /// Thrown when fails to make API call + /// ApiResponse of HealthCheckResult + ApiResponse FakeHealthGetWithHttpInfo (); + /// + /// test http signature authentication + /// + /// + /// /// /// Thrown when fails to make API call - /// XmlItem Body + /// Pet object that needs to be added to the store + /// query parameter (optional) + /// header parameter (optional) /// - void CreateXmlItem (XmlItem xmlItem); + void FakeHttpSignatureTest (Pet pet, string query1 = default(string), string header1 = default(string)); /// - /// creates an XmlItem + /// test http signature authentication /// /// - /// this route creates an XmlItem + /// /// /// Thrown when fails to make API call - /// XmlItem Body + /// Pet object that needs to be added to the store + /// query parameter (optional) + /// header parameter (optional) /// ApiResponse of Object(void) - ApiResponse CreateXmlItemWithHttpInfo (XmlItem xmlItem); + ApiResponse FakeHttpSignatureTestWithHttpInfo (Pet pet, string query1 = default(string), string header1 = default(string)); /// /// /// @@ -73,9 +96,9 @@ public interface IFakeApi : IApiAccessor /// Test serialization of object with outer number type /// /// Thrown when fails to make API call - /// Input composite as post body (optional) + /// Input composite as post body (optional) /// OuterComposite - OuterComposite FakeOuterCompositeSerialize (OuterComposite body = default(OuterComposite)); + OuterComposite FakeOuterCompositeSerialize (OuterComposite outerComposite = default(OuterComposite)); /// /// @@ -84,9 +107,9 @@ public interface IFakeApi : IApiAccessor /// Test serialization of object with outer number type /// /// Thrown when fails to make API call - /// Input composite as post body (optional) + /// Input composite as post body (optional) /// ApiResponse of OuterComposite - ApiResponse FakeOuterCompositeSerializeWithHttpInfo (OuterComposite body = default(OuterComposite)); + ApiResponse FakeOuterCompositeSerializeWithHttpInfo (OuterComposite outerComposite = default(OuterComposite)); /// /// /// @@ -136,9 +159,9 @@ public interface IFakeApi : IApiAccessor /// For this test, the body for this request much reference a schema named `File`. /// /// Thrown when fails to make API call - /// + /// /// - void TestBodyWithFileSchema (FileSchemaTestClass body); + void TestBodyWithFileSchema (FileSchemaTestClass fileSchemaTestClass); /// /// @@ -147,9 +170,9 @@ public interface IFakeApi : IApiAccessor /// For this test, the body for this request much reference a schema named `File`. /// /// Thrown when fails to make API call - /// + /// /// ApiResponse of Object(void) - ApiResponse TestBodyWithFileSchemaWithHttpInfo (FileSchemaTestClass body); + ApiResponse TestBodyWithFileSchemaWithHttpInfo (FileSchemaTestClass fileSchemaTestClass); /// /// /// @@ -158,9 +181,9 @@ public interface IFakeApi : IApiAccessor /// /// Thrown when fails to make API call /// - /// + /// /// - void TestBodyWithQueryParams (string query, User body); + void TestBodyWithQueryParams (string query, User user); /// /// @@ -170,9 +193,9 @@ public interface IFakeApi : IApiAccessor /// /// Thrown when fails to make API call /// - /// + /// /// ApiResponse of Object(void) - ApiResponse TestBodyWithQueryParamsWithHttpInfo (string query, User body); + ApiResponse TestBodyWithQueryParamsWithHttpInfo (string query, User user); /// /// To test \"client\" model /// @@ -180,9 +203,9 @@ public interface IFakeApi : IApiAccessor /// To test \"client\" model /// /// Thrown when fails to make API call - /// client model + /// client model /// ModelClient - ModelClient TestClientModel (ModelClient body); + ModelClient TestClientModel (ModelClient modelClient); /// /// To test \"client\" model @@ -191,14 +214,14 @@ public interface IFakeApi : IApiAccessor /// To test \"client\" model /// /// Thrown when fails to make API call - /// client model + /// client model /// ApiResponse of ModelClient - ApiResponse TestClientModelWithHttpInfo (ModelClient body); + ApiResponse TestClientModelWithHttpInfo (ModelClient modelClient); /// - /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 /// /// - /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 /// /// Thrown when fails to make API call /// None @@ -219,10 +242,10 @@ public interface IFakeApi : IApiAccessor void TestEndpointParameters (decimal number, double _double, string patternWithoutDelimiter, byte[] _byte, int? integer = default(int?), int? int32 = default(int?), long? int64 = default(long?), float? _float = default(float?), string _string = default(string), System.IO.Stream binary = default(System.IO.Stream), DateTime? date = default(DateTime?), DateTime? dateTime = default(DateTime?), string password = default(string), string callback = default(string)); /// - /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 /// /// - /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 /// /// Thrown when fails to make API call /// None @@ -314,9 +337,9 @@ public interface IFakeApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// request body + /// request body /// - void TestInlineAdditionalProperties (Dictionary param); + void TestInlineAdditionalProperties (Dictionary requestBody); /// /// test inline additionalProperties @@ -325,9 +348,9 @@ public interface IFakeApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// request body + /// request body /// ApiResponse of Object(void) - ApiResponse TestInlineAdditionalPropertiesWithHttpInfo (Dictionary param); + ApiResponse TestInlineAdditionalPropertiesWithHttpInfo (Dictionary requestBody); /// /// test json serialization of form data /// @@ -383,26 +406,49 @@ public interface IFakeApi : IApiAccessor #endregion Synchronous Operations #region Asynchronous Operations /// - /// creates an XmlItem + /// Health check endpoint + /// + /// + /// + /// + /// Thrown when fails to make API call + /// Task of HealthCheckResult + System.Threading.Tasks.Task FakeHealthGetAsync (); + + /// + /// Health check endpoint /// /// - /// this route creates an XmlItem + /// /// /// Thrown when fails to make API call - /// XmlItem Body + /// Task of ApiResponse (HealthCheckResult) + System.Threading.Tasks.Task> FakeHealthGetAsyncWithHttpInfo (); + /// + /// test http signature authentication + /// + /// + /// + /// + /// Thrown when fails to make API call + /// Pet object that needs to be added to the store + /// query parameter (optional) + /// header parameter (optional) /// Task of void - System.Threading.Tasks.Task CreateXmlItemAsync (XmlItem xmlItem); + System.Threading.Tasks.Task FakeHttpSignatureTestAsync (Pet pet, string query1 = default(string), string header1 = default(string)); /// - /// creates an XmlItem + /// test http signature authentication /// /// - /// this route creates an XmlItem + /// /// /// Thrown when fails to make API call - /// XmlItem Body + /// Pet object that needs to be added to the store + /// query parameter (optional) + /// header parameter (optional) /// Task of ApiResponse - System.Threading.Tasks.Task> CreateXmlItemAsyncWithHttpInfo (XmlItem xmlItem); + System.Threading.Tasks.Task> FakeHttpSignatureTestAsyncWithHttpInfo (Pet pet, string query1 = default(string), string header1 = default(string)); /// /// /// @@ -431,9 +477,9 @@ public interface IFakeApi : IApiAccessor /// Test serialization of object with outer number type /// /// Thrown when fails to make API call - /// Input composite as post body (optional) + /// Input composite as post body (optional) /// Task of OuterComposite - System.Threading.Tasks.Task FakeOuterCompositeSerializeAsync (OuterComposite body = default(OuterComposite)); + System.Threading.Tasks.Task FakeOuterCompositeSerializeAsync (OuterComposite outerComposite = default(OuterComposite)); /// /// @@ -442,9 +488,9 @@ public interface IFakeApi : IApiAccessor /// Test serialization of object with outer number type /// /// Thrown when fails to make API call - /// Input composite as post body (optional) + /// Input composite as post body (optional) /// Task of ApiResponse (OuterComposite) - System.Threading.Tasks.Task> FakeOuterCompositeSerializeAsyncWithHttpInfo (OuterComposite body = default(OuterComposite)); + System.Threading.Tasks.Task> FakeOuterCompositeSerializeAsyncWithHttpInfo (OuterComposite outerComposite = default(OuterComposite)); /// /// /// @@ -494,9 +540,9 @@ public interface IFakeApi : IApiAccessor /// For this test, the body for this request much reference a schema named `File`. /// /// Thrown when fails to make API call - /// + /// /// Task of void - System.Threading.Tasks.Task TestBodyWithFileSchemaAsync (FileSchemaTestClass body); + System.Threading.Tasks.Task TestBodyWithFileSchemaAsync (FileSchemaTestClass fileSchemaTestClass); /// /// @@ -505,9 +551,9 @@ public interface IFakeApi : IApiAccessor /// For this test, the body for this request much reference a schema named `File`. /// /// Thrown when fails to make API call - /// + /// /// Task of ApiResponse - System.Threading.Tasks.Task> TestBodyWithFileSchemaAsyncWithHttpInfo (FileSchemaTestClass body); + System.Threading.Tasks.Task> TestBodyWithFileSchemaAsyncWithHttpInfo (FileSchemaTestClass fileSchemaTestClass); /// /// /// @@ -516,9 +562,9 @@ public interface IFakeApi : IApiAccessor /// /// Thrown when fails to make API call /// - /// + /// /// Task of void - System.Threading.Tasks.Task TestBodyWithQueryParamsAsync (string query, User body); + System.Threading.Tasks.Task TestBodyWithQueryParamsAsync (string query, User user); /// /// @@ -528,9 +574,9 @@ public interface IFakeApi : IApiAccessor /// /// Thrown when fails to make API call /// - /// + /// /// Task of ApiResponse - System.Threading.Tasks.Task> TestBodyWithQueryParamsAsyncWithHttpInfo (string query, User body); + System.Threading.Tasks.Task> TestBodyWithQueryParamsAsyncWithHttpInfo (string query, User user); /// /// To test \"client\" model /// @@ -538,9 +584,9 @@ public interface IFakeApi : IApiAccessor /// To test \"client\" model /// /// Thrown when fails to make API call - /// client model + /// client model /// Task of ModelClient - System.Threading.Tasks.Task TestClientModelAsync (ModelClient body); + System.Threading.Tasks.Task TestClientModelAsync (ModelClient modelClient); /// /// To test \"client\" model @@ -549,14 +595,14 @@ public interface IFakeApi : IApiAccessor /// To test \"client\" model /// /// Thrown when fails to make API call - /// client model + /// client model /// Task of ApiResponse (ModelClient) - System.Threading.Tasks.Task> TestClientModelAsyncWithHttpInfo (ModelClient body); + System.Threading.Tasks.Task> TestClientModelAsyncWithHttpInfo (ModelClient modelClient); /// - /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 /// /// - /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 /// /// Thrown when fails to make API call /// None @@ -577,10 +623,10 @@ public interface IFakeApi : IApiAccessor System.Threading.Tasks.Task TestEndpointParametersAsync (decimal number, double _double, string patternWithoutDelimiter, byte[] _byte, int? integer = default(int?), int? int32 = default(int?), long? int64 = default(long?), float? _float = default(float?), string _string = default(string), System.IO.Stream binary = default(System.IO.Stream), DateTime? date = default(DateTime?), DateTime? dateTime = default(DateTime?), string password = default(string), string callback = default(string)); /// - /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 /// /// - /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 /// /// Thrown when fails to make API call /// None @@ -672,9 +718,9 @@ public interface IFakeApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// request body + /// request body /// Task of void - System.Threading.Tasks.Task TestInlineAdditionalPropertiesAsync (Dictionary param); + System.Threading.Tasks.Task TestInlineAdditionalPropertiesAsync (Dictionary requestBody); /// /// test inline additionalProperties @@ -683,9 +729,9 @@ public interface IFakeApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// request body + /// request body /// Task of ApiResponse - System.Threading.Tasks.Task> TestInlineAdditionalPropertiesAsyncWithHttpInfo (Dictionary param); + System.Threading.Tasks.Task> TestInlineAdditionalPropertiesAsyncWithHttpInfo (Dictionary requestBody); /// /// test json serialization of form data /// @@ -850,29 +896,154 @@ public void AddDefaultHeader(string key, string value) } /// - /// creates an XmlItem this route creates an XmlItem + /// Health check endpoint + /// + /// Thrown when fails to make API call + /// HealthCheckResult + public HealthCheckResult FakeHealthGet () + { + ApiResponse localVarResponse = FakeHealthGetWithHttpInfo(); + return localVarResponse.Data; + } + + /// + /// Health check endpoint + /// + /// Thrown when fails to make API call + /// ApiResponse of HealthCheckResult + public ApiResponse FakeHealthGetWithHttpInfo () + { + + var localVarPath = "/fake/health"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new List>(); + var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new Dictionary(); + Object localVarPostBody = null; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + }; + String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + "application/json" + }; + String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + + + // make the HTTP request + IRestResponse localVarResponse = (IRestResponse) this.Configuration.ApiClient.CallApi(localVarPath, + Method.GET, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, + localVarPathParams, localVarHttpContentType); + + int localVarStatusCode = (int) localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("FakeHealthGet", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)), + (HealthCheckResult) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(HealthCheckResult))); + } + + /// + /// Health check endpoint + /// + /// Thrown when fails to make API call + /// Task of HealthCheckResult + public async System.Threading.Tasks.Task FakeHealthGetAsync () + { + ApiResponse localVarResponse = await FakeHealthGetAsyncWithHttpInfo(); + return localVarResponse.Data; + + } + + /// + /// Health check endpoint /// /// Thrown when fails to make API call - /// XmlItem Body + /// Task of ApiResponse (HealthCheckResult) + public async System.Threading.Tasks.Task> FakeHealthGetAsyncWithHttpInfo () + { + + var localVarPath = "/fake/health"; + var localVarPathParams = new Dictionary(); + var localVarQueryParams = new List>(); + var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader); + var localVarFormParams = new Dictionary(); + var localVarFileParams = new Dictionary(); + Object localVarPostBody = null; + + // to determine the Content-Type header + String[] localVarHttpContentTypes = new String[] { + }; + String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); + + // to determine the Accept header + String[] localVarHttpHeaderAccepts = new String[] { + "application/json" + }; + String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); + if (localVarHttpHeaderAccept != null) + localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); + + + + // make the HTTP request + IRestResponse localVarResponse = (IRestResponse) await this.Configuration.ApiClient.CallApiAsync(localVarPath, + Method.GET, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, + localVarPathParams, localVarHttpContentType); + + int localVarStatusCode = (int) localVarResponse.StatusCode; + + if (ExceptionFactory != null) + { + Exception exception = ExceptionFactory("FakeHealthGet", localVarResponse); + if (exception != null) throw exception; + } + + return new ApiResponse(localVarStatusCode, + localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)), + (HealthCheckResult) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(HealthCheckResult))); + } + + /// + /// test http signature authentication + /// + /// Thrown when fails to make API call + /// Pet object that needs to be added to the store + /// query parameter (optional) + /// header parameter (optional) /// - public void CreateXmlItem (XmlItem xmlItem) + public void FakeHttpSignatureTest (Pet pet, string query1 = default(string), string header1 = default(string)) { - CreateXmlItemWithHttpInfo(xmlItem); + FakeHttpSignatureTestWithHttpInfo(pet, query1, header1); } /// - /// creates an XmlItem this route creates an XmlItem + /// test http signature authentication /// /// Thrown when fails to make API call - /// XmlItem Body + /// Pet object that needs to be added to the store + /// query parameter (optional) + /// header parameter (optional) /// ApiResponse of Object(void) - public ApiResponse CreateXmlItemWithHttpInfo (XmlItem xmlItem) + public ApiResponse FakeHttpSignatureTestWithHttpInfo (Pet pet, string query1 = default(string), string header1 = default(string)) { - // verify the required parameter 'xmlItem' is set - if (xmlItem == null) - throw new ApiException(400, "Missing required parameter 'xmlItem' when calling FakeApi->CreateXmlItem"); + // verify the required parameter 'pet' is set + if (pet == null) + throw new ApiException(400, "Missing required parameter 'pet' when calling FakeApi->FakeHttpSignatureTest"); - var localVarPath = "/fake/create_xml_item"; + var localVarPath = "/fake/http-signature-test"; var localVarPathParams = new Dictionary(); var localVarQueryParams = new List>(); var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader); @@ -882,12 +1053,8 @@ public ApiResponse CreateXmlItemWithHttpInfo (XmlItem xmlItem) // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { - "application/xml", - "application/xml; charset=utf-8", - "application/xml; charset=utf-16", - "text/xml", - "text/xml; charset=utf-8", - "text/xml; charset=utf-16" + "application/json", + "application/xml" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -898,26 +1065,29 @@ public ApiResponse CreateXmlItemWithHttpInfo (XmlItem xmlItem) if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (xmlItem != null && xmlItem.GetType() != typeof(byte[])) + if (query1 != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "query_1", query1)); // query parameter + if (header1 != null) localVarHeaderParams.Add("header_1", this.Configuration.ApiClient.ParameterToString(header1)); // header parameter + if (pet != null && pet.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(xmlItem); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(pet); // http body (model) parameter } else { - localVarPostBody = xmlItem; // byte array + localVarPostBody = pet; // byte array } + // authentication (http_signature_test) required // make the HTTP request IRestResponse localVarResponse = (IRestResponse) this.Configuration.ApiClient.CallApi(localVarPath, - Method.POST, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, + Method.GET, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, localVarPathParams, localVarHttpContentType); int localVarStatusCode = (int) localVarResponse.StatusCode; if (ExceptionFactory != null) { - Exception exception = ExceptionFactory("CreateXmlItem", localVarResponse); + Exception exception = ExceptionFactory("FakeHttpSignatureTest", localVarResponse); if (exception != null) throw exception; } @@ -927,30 +1097,34 @@ public ApiResponse CreateXmlItemWithHttpInfo (XmlItem xmlItem) } /// - /// creates an XmlItem this route creates an XmlItem + /// test http signature authentication /// /// Thrown when fails to make API call - /// XmlItem Body + /// Pet object that needs to be added to the store + /// query parameter (optional) + /// header parameter (optional) /// Task of void - public async System.Threading.Tasks.Task CreateXmlItemAsync (XmlItem xmlItem) + public async System.Threading.Tasks.Task FakeHttpSignatureTestAsync (Pet pet, string query1 = default(string), string header1 = default(string)) { - await CreateXmlItemAsyncWithHttpInfo(xmlItem); + await FakeHttpSignatureTestAsyncWithHttpInfo(pet, query1, header1); } /// - /// creates an XmlItem this route creates an XmlItem + /// test http signature authentication /// /// Thrown when fails to make API call - /// XmlItem Body + /// Pet object that needs to be added to the store + /// query parameter (optional) + /// header parameter (optional) /// Task of ApiResponse - public async System.Threading.Tasks.Task> CreateXmlItemAsyncWithHttpInfo (XmlItem xmlItem) + public async System.Threading.Tasks.Task> FakeHttpSignatureTestAsyncWithHttpInfo (Pet pet, string query1 = default(string), string header1 = default(string)) { - // verify the required parameter 'xmlItem' is set - if (xmlItem == null) - throw new ApiException(400, "Missing required parameter 'xmlItem' when calling FakeApi->CreateXmlItem"); + // verify the required parameter 'pet' is set + if (pet == null) + throw new ApiException(400, "Missing required parameter 'pet' when calling FakeApi->FakeHttpSignatureTest"); - var localVarPath = "/fake/create_xml_item"; + var localVarPath = "/fake/http-signature-test"; var localVarPathParams = new Dictionary(); var localVarQueryParams = new List>(); var localVarHeaderParams = new Dictionary(this.Configuration.DefaultHeader); @@ -960,12 +1134,8 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { - "application/xml", - "application/xml; charset=utf-8", - "application/xml; charset=utf-16", - "text/xml", - "text/xml; charset=utf-8", - "text/xml; charset=utf-16" + "application/json", + "application/xml" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -976,26 +1146,29 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (xmlItem != null && xmlItem.GetType() != typeof(byte[])) + if (query1 != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "query_1", query1)); // query parameter + if (header1 != null) localVarHeaderParams.Add("header_1", this.Configuration.ApiClient.ParameterToString(header1)); // header parameter + if (pet != null && pet.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(xmlItem); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(pet); // http body (model) parameter } else { - localVarPostBody = xmlItem; // byte array + localVarPostBody = pet; // byte array } + // authentication (http_signature_test) required // make the HTTP request IRestResponse localVarResponse = (IRestResponse) await this.Configuration.ApiClient.CallApiAsync(localVarPath, - Method.POST, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, + Method.GET, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, localVarPathParams, localVarHttpContentType); int localVarStatusCode = (int) localVarResponse.StatusCode; if (ExceptionFactory != null) { - Exception exception = ExceptionFactory("CreateXmlItem", localVarResponse); + Exception exception = ExceptionFactory("FakeHttpSignatureTest", localVarResponse); if (exception != null) throw exception; } @@ -1035,6 +1208,7 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -1106,6 +1280,7 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -1149,11 +1324,11 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync /// Test serialization of object with outer number type /// /// Thrown when fails to make API call - /// Input composite as post body (optional) + /// Input composite as post body (optional) /// OuterComposite - public OuterComposite FakeOuterCompositeSerialize (OuterComposite body = default(OuterComposite)) + public OuterComposite FakeOuterCompositeSerialize (OuterComposite outerComposite = default(OuterComposite)) { - ApiResponse localVarResponse = FakeOuterCompositeSerializeWithHttpInfo(body); + ApiResponse localVarResponse = FakeOuterCompositeSerializeWithHttpInfo(outerComposite); return localVarResponse.Data; } @@ -1161,9 +1336,9 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync /// Test serialization of object with outer number type /// /// Thrown when fails to make API call - /// Input composite as post body (optional) + /// Input composite as post body (optional) /// ApiResponse of OuterComposite - public ApiResponse FakeOuterCompositeSerializeWithHttpInfo (OuterComposite body = default(OuterComposite)) + public ApiResponse FakeOuterCompositeSerializeWithHttpInfo (OuterComposite outerComposite = default(OuterComposite)) { var localVarPath = "/fake/outer/composite"; @@ -1176,6 +1351,7 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -1187,13 +1363,13 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (outerComposite != null && outerComposite.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(outerComposite); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = outerComposite; // byte array } @@ -1219,11 +1395,11 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync /// Test serialization of object with outer number type /// /// Thrown when fails to make API call - /// Input composite as post body (optional) + /// Input composite as post body (optional) /// Task of OuterComposite - public async System.Threading.Tasks.Task FakeOuterCompositeSerializeAsync (OuterComposite body = default(OuterComposite)) + public async System.Threading.Tasks.Task FakeOuterCompositeSerializeAsync (OuterComposite outerComposite = default(OuterComposite)) { - ApiResponse localVarResponse = await FakeOuterCompositeSerializeAsyncWithHttpInfo(body); + ApiResponse localVarResponse = await FakeOuterCompositeSerializeAsyncWithHttpInfo(outerComposite); return localVarResponse.Data; } @@ -1232,9 +1408,9 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync /// Test serialization of object with outer number type /// /// Thrown when fails to make API call - /// Input composite as post body (optional) + /// Input composite as post body (optional) /// Task of ApiResponse (OuterComposite) - public async System.Threading.Tasks.Task> FakeOuterCompositeSerializeAsyncWithHttpInfo (OuterComposite body = default(OuterComposite)) + public async System.Threading.Tasks.Task> FakeOuterCompositeSerializeAsyncWithHttpInfo (OuterComposite outerComposite = default(OuterComposite)) { var localVarPath = "/fake/outer/composite"; @@ -1247,6 +1423,7 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -1258,13 +1435,13 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (outerComposite != null && outerComposite.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(outerComposite); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = outerComposite; // byte array } @@ -1317,6 +1494,7 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -1388,6 +1566,7 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -1458,6 +1637,7 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -1529,6 +1709,7 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -1572,24 +1753,24 @@ public async System.Threading.Tasks.Task> CreateXmlItemAsync /// For this test, the body for this request much reference a schema named `File`. /// /// Thrown when fails to make API call - /// + /// /// - public void TestBodyWithFileSchema (FileSchemaTestClass body) + public void TestBodyWithFileSchema (FileSchemaTestClass fileSchemaTestClass) { - TestBodyWithFileSchemaWithHttpInfo(body); + TestBodyWithFileSchemaWithHttpInfo(fileSchemaTestClass); } /// /// For this test, the body for this request much reference a schema named `File`. /// /// Thrown when fails to make API call - /// + /// /// ApiResponse of Object(void) - public ApiResponse TestBodyWithFileSchemaWithHttpInfo (FileSchemaTestClass body) + public ApiResponse TestBodyWithFileSchemaWithHttpInfo (FileSchemaTestClass fileSchemaTestClass) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling FakeApi->TestBodyWithFileSchema"); + // verify the required parameter 'fileSchemaTestClass' is set + if (fileSchemaTestClass == null) + throw new ApiException(400, "Missing required parameter 'fileSchemaTestClass' when calling FakeApi->TestBodyWithFileSchema"); var localVarPath = "/fake/body-with-file-schema"; var localVarPathParams = new Dictionary(); @@ -1612,13 +1793,13 @@ public ApiResponse TestBodyWithFileSchemaWithHttpInfo (FileSchemaTestCla if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (fileSchemaTestClass != null && fileSchemaTestClass.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(fileSchemaTestClass); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = fileSchemaTestClass; // byte array } @@ -1644,11 +1825,11 @@ public ApiResponse TestBodyWithFileSchemaWithHttpInfo (FileSchemaTestCla /// For this test, the body for this request much reference a schema named `File`. /// /// Thrown when fails to make API call - /// + /// /// Task of void - public async System.Threading.Tasks.Task TestBodyWithFileSchemaAsync (FileSchemaTestClass body) + public async System.Threading.Tasks.Task TestBodyWithFileSchemaAsync (FileSchemaTestClass fileSchemaTestClass) { - await TestBodyWithFileSchemaAsyncWithHttpInfo(body); + await TestBodyWithFileSchemaAsyncWithHttpInfo(fileSchemaTestClass); } @@ -1656,13 +1837,13 @@ public async System.Threading.Tasks.Task TestBodyWithFileSchemaAsync (FileSchema /// For this test, the body for this request much reference a schema named `File`. /// /// Thrown when fails to make API call - /// + /// /// Task of ApiResponse - public async System.Threading.Tasks.Task> TestBodyWithFileSchemaAsyncWithHttpInfo (FileSchemaTestClass body) + public async System.Threading.Tasks.Task> TestBodyWithFileSchemaAsyncWithHttpInfo (FileSchemaTestClass fileSchemaTestClass) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling FakeApi->TestBodyWithFileSchema"); + // verify the required parameter 'fileSchemaTestClass' is set + if (fileSchemaTestClass == null) + throw new ApiException(400, "Missing required parameter 'fileSchemaTestClass' when calling FakeApi->TestBodyWithFileSchema"); var localVarPath = "/fake/body-with-file-schema"; var localVarPathParams = new Dictionary(); @@ -1685,13 +1866,13 @@ public async System.Threading.Tasks.Task> TestBodyWithFileSc if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (fileSchemaTestClass != null && fileSchemaTestClass.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(fileSchemaTestClass); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = fileSchemaTestClass; // byte array } @@ -1718,11 +1899,11 @@ public async System.Threading.Tasks.Task> TestBodyWithFileSc /// /// Thrown when fails to make API call /// - /// + /// /// - public void TestBodyWithQueryParams (string query, User body) + public void TestBodyWithQueryParams (string query, User user) { - TestBodyWithQueryParamsWithHttpInfo(query, body); + TestBodyWithQueryParamsWithHttpInfo(query, user); } /// @@ -1730,16 +1911,16 @@ public void TestBodyWithQueryParams (string query, User body) /// /// Thrown when fails to make API call /// - /// + /// /// ApiResponse of Object(void) - public ApiResponse TestBodyWithQueryParamsWithHttpInfo (string query, User body) + public ApiResponse TestBodyWithQueryParamsWithHttpInfo (string query, User user) { // verify the required parameter 'query' is set if (query == null) throw new ApiException(400, "Missing required parameter 'query' when calling FakeApi->TestBodyWithQueryParams"); - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling FakeApi->TestBodyWithQueryParams"); + // verify the required parameter 'user' is set + if (user == null) + throw new ApiException(400, "Missing required parameter 'user' when calling FakeApi->TestBodyWithQueryParams"); var localVarPath = "/fake/body-with-query-params"; var localVarPathParams = new Dictionary(); @@ -1763,13 +1944,13 @@ public ApiResponse TestBodyWithQueryParamsWithHttpInfo (string query, Us localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); if (query != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "query", query)); // query parameter - if (body != null && body.GetType() != typeof(byte[])) + if (user != null && user.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(user); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = user; // byte array } @@ -1796,11 +1977,11 @@ public ApiResponse TestBodyWithQueryParamsWithHttpInfo (string query, Us /// /// Thrown when fails to make API call /// - /// + /// /// Task of void - public async System.Threading.Tasks.Task TestBodyWithQueryParamsAsync (string query, User body) + public async System.Threading.Tasks.Task TestBodyWithQueryParamsAsync (string query, User user) { - await TestBodyWithQueryParamsAsyncWithHttpInfo(query, body); + await TestBodyWithQueryParamsAsyncWithHttpInfo(query, user); } @@ -1809,16 +1990,16 @@ public async System.Threading.Tasks.Task TestBodyWithQueryParamsAsync (string qu /// /// Thrown when fails to make API call /// - /// + /// /// Task of ApiResponse - public async System.Threading.Tasks.Task> TestBodyWithQueryParamsAsyncWithHttpInfo (string query, User body) + public async System.Threading.Tasks.Task> TestBodyWithQueryParamsAsyncWithHttpInfo (string query, User user) { // verify the required parameter 'query' is set if (query == null) throw new ApiException(400, "Missing required parameter 'query' when calling FakeApi->TestBodyWithQueryParams"); - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling FakeApi->TestBodyWithQueryParams"); + // verify the required parameter 'user' is set + if (user == null) + throw new ApiException(400, "Missing required parameter 'user' when calling FakeApi->TestBodyWithQueryParams"); var localVarPath = "/fake/body-with-query-params"; var localVarPathParams = new Dictionary(); @@ -1842,13 +2023,13 @@ public async System.Threading.Tasks.Task> TestBodyWithQueryP localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); if (query != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "query", query)); // query parameter - if (body != null && body.GetType() != typeof(byte[])) + if (user != null && user.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(user); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = user; // byte array } @@ -1874,11 +2055,11 @@ public async System.Threading.Tasks.Task> TestBodyWithQueryP /// To test \"client\" model To test \"client\" model /// /// Thrown when fails to make API call - /// client model + /// client model /// ModelClient - public ModelClient TestClientModel (ModelClient body) + public ModelClient TestClientModel (ModelClient modelClient) { - ApiResponse localVarResponse = TestClientModelWithHttpInfo(body); + ApiResponse localVarResponse = TestClientModelWithHttpInfo(modelClient); return localVarResponse.Data; } @@ -1886,13 +2067,13 @@ public ModelClient TestClientModel (ModelClient body) /// To test \"client\" model To test \"client\" model /// /// Thrown when fails to make API call - /// client model + /// client model /// ApiResponse of ModelClient - public ApiResponse TestClientModelWithHttpInfo (ModelClient body) + public ApiResponse TestClientModelWithHttpInfo (ModelClient modelClient) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling FakeApi->TestClientModel"); + // verify the required parameter 'modelClient' is set + if (modelClient == null) + throw new ApiException(400, "Missing required parameter 'modelClient' when calling FakeApi->TestClientModel"); var localVarPath = "/fake"; var localVarPathParams = new Dictionary(); @@ -1916,13 +2097,13 @@ public ApiResponse TestClientModelWithHttpInfo (ModelClient body) if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (modelClient != null && modelClient.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(modelClient); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = modelClient; // byte array } @@ -1948,11 +2129,11 @@ public ApiResponse TestClientModelWithHttpInfo (ModelClient body) /// To test \"client\" model To test \"client\" model /// /// Thrown when fails to make API call - /// client model + /// client model /// Task of ModelClient - public async System.Threading.Tasks.Task TestClientModelAsync (ModelClient body) + public async System.Threading.Tasks.Task TestClientModelAsync (ModelClient modelClient) { - ApiResponse localVarResponse = await TestClientModelAsyncWithHttpInfo(body); + ApiResponse localVarResponse = await TestClientModelAsyncWithHttpInfo(modelClient); return localVarResponse.Data; } @@ -1961,13 +2142,13 @@ public async System.Threading.Tasks.Task TestClientModelAsync (Mode /// To test \"client\" model To test \"client\" model /// /// Thrown when fails to make API call - /// client model + /// client model /// Task of ApiResponse (ModelClient) - public async System.Threading.Tasks.Task> TestClientModelAsyncWithHttpInfo (ModelClient body) + public async System.Threading.Tasks.Task> TestClientModelAsyncWithHttpInfo (ModelClient modelClient) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling FakeApi->TestClientModel"); + // verify the required parameter 'modelClient' is set + if (modelClient == null) + throw new ApiException(400, "Missing required parameter 'modelClient' when calling FakeApi->TestClientModel"); var localVarPath = "/fake"; var localVarPathParams = new Dictionary(); @@ -1991,13 +2172,13 @@ public async System.Threading.Tasks.Task> TestClientMod if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (modelClient != null && modelClient.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(modelClient); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = modelClient; // byte array } @@ -2020,7 +2201,7 @@ public async System.Threading.Tasks.Task> TestClientMod } /// - /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 /// /// Thrown when fails to make API call /// None @@ -2044,7 +2225,7 @@ public async System.Threading.Tasks.Task> TestClientMod } /// - /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 /// /// Thrown when fails to make API call /// None @@ -2139,7 +2320,7 @@ public async System.Threading.Tasks.Task> TestClientMod } /// - /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 /// /// Thrown when fails to make API call /// None @@ -2164,7 +2345,7 @@ public async System.Threading.Tasks.Task> TestClientMod } /// - /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 /// /// Thrown when fails to make API call /// None @@ -2313,7 +2494,7 @@ public async System.Threading.Tasks.Task> TestClientMod if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (enumQueryStringArray != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "enum_query_string_array", enumQueryStringArray)); // query parameter + if (enumQueryStringArray != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("multi", "enum_query_string_array", enumQueryStringArray)); // query parameter if (enumQueryString != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "enum_query_string", enumQueryString)); // query parameter if (enumQueryInteger != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "enum_query_integer", enumQueryInteger)); // query parameter if (enumQueryDouble != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "enum_query_double", enumQueryDouble)); // query parameter @@ -2397,7 +2578,7 @@ public async System.Threading.Tasks.Task> TestClientMod if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (enumQueryStringArray != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "enum_query_string_array", enumQueryStringArray)); // query parameter + if (enumQueryStringArray != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("multi", "enum_query_string_array", enumQueryStringArray)); // query parameter if (enumQueryString != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "enum_query_string", enumQueryString)); // query parameter if (enumQueryInteger != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "enum_query_integer", enumQueryInteger)); // query parameter if (enumQueryDouble != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("", "enum_query_double", enumQueryDouble)); // query parameter @@ -2491,6 +2672,12 @@ public async System.Threading.Tasks.Task> TestClientMod if (requiredBooleanGroup != null) localVarHeaderParams.Add("required_boolean_group", this.Configuration.ApiClient.ParameterToString(requiredBooleanGroup)); // header parameter if (booleanGroup != null) localVarHeaderParams.Add("boolean_group", this.Configuration.ApiClient.ParameterToString(booleanGroup)); // header parameter + // authentication (bearer_test) required + // http beerer authentication required + if (!String.IsNullOrEmpty(this.Configuration.AccessToken)) + { + localVarHeaderParams["Authorization"] = "Bearer " + this.Configuration.AccessToken; + } // make the HTTP request IRestResponse localVarResponse = (IRestResponse) this.Configuration.ApiClient.CallApi(localVarPath, @@ -2577,6 +2764,12 @@ public async System.Threading.Tasks.Task> TestClientMod if (requiredBooleanGroup != null) localVarHeaderParams.Add("required_boolean_group", this.Configuration.ApiClient.ParameterToString(requiredBooleanGroup)); // header parameter if (booleanGroup != null) localVarHeaderParams.Add("boolean_group", this.Configuration.ApiClient.ParameterToString(booleanGroup)); // header parameter + // authentication (bearer_test) required + // http bearer authentication required + if (!String.IsNullOrEmpty(this.Configuration.AccessToken)) + { + localVarHeaderParams["Authorization"] = "Bearer " + this.Configuration.AccessToken; + } // make the HTTP request IRestResponse localVarResponse = (IRestResponse) await this.Configuration.ApiClient.CallApiAsync(localVarPath, @@ -2600,24 +2793,24 @@ public async System.Threading.Tasks.Task> TestClientMod /// test inline additionalProperties /// /// Thrown when fails to make API call - /// request body + /// request body /// - public void TestInlineAdditionalProperties (Dictionary param) + public void TestInlineAdditionalProperties (Dictionary requestBody) { - TestInlineAdditionalPropertiesWithHttpInfo(param); + TestInlineAdditionalPropertiesWithHttpInfo(requestBody); } /// /// test inline additionalProperties /// /// Thrown when fails to make API call - /// request body + /// request body /// ApiResponse of Object(void) - public ApiResponse TestInlineAdditionalPropertiesWithHttpInfo (Dictionary param) + public ApiResponse TestInlineAdditionalPropertiesWithHttpInfo (Dictionary requestBody) { - // verify the required parameter 'param' is set - if (param == null) - throw new ApiException(400, "Missing required parameter 'param' when calling FakeApi->TestInlineAdditionalProperties"); + // verify the required parameter 'requestBody' is set + if (requestBody == null) + throw new ApiException(400, "Missing required parameter 'requestBody' when calling FakeApi->TestInlineAdditionalProperties"); var localVarPath = "/fake/inline-additionalProperties"; var localVarPathParams = new Dictionary(); @@ -2640,13 +2833,13 @@ public ApiResponse TestInlineAdditionalPropertiesWithHttpInfo (Dictionar if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (param != null && param.GetType() != typeof(byte[])) + if (requestBody != null && requestBody.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(param); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(requestBody); // http body (model) parameter } else { - localVarPostBody = param; // byte array + localVarPostBody = requestBody; // byte array } @@ -2672,11 +2865,11 @@ public ApiResponse TestInlineAdditionalPropertiesWithHttpInfo (Dictionar /// test inline additionalProperties /// /// Thrown when fails to make API call - /// request body + /// request body /// Task of void - public async System.Threading.Tasks.Task TestInlineAdditionalPropertiesAsync (Dictionary param) + public async System.Threading.Tasks.Task TestInlineAdditionalPropertiesAsync (Dictionary requestBody) { - await TestInlineAdditionalPropertiesAsyncWithHttpInfo(param); + await TestInlineAdditionalPropertiesAsyncWithHttpInfo(requestBody); } @@ -2684,13 +2877,13 @@ public async System.Threading.Tasks.Task TestInlineAdditionalPropertiesAsync (Di /// test inline additionalProperties /// /// Thrown when fails to make API call - /// request body + /// request body /// Task of ApiResponse - public async System.Threading.Tasks.Task> TestInlineAdditionalPropertiesAsyncWithHttpInfo (Dictionary param) + public async System.Threading.Tasks.Task> TestInlineAdditionalPropertiesAsyncWithHttpInfo (Dictionary requestBody) { - // verify the required parameter 'param' is set - if (param == null) - throw new ApiException(400, "Missing required parameter 'param' when calling FakeApi->TestInlineAdditionalProperties"); + // verify the required parameter 'requestBody' is set + if (requestBody == null) + throw new ApiException(400, "Missing required parameter 'requestBody' when calling FakeApi->TestInlineAdditionalProperties"); var localVarPath = "/fake/inline-additionalProperties"; var localVarPathParams = new Dictionary(); @@ -2713,13 +2906,13 @@ public async System.Threading.Tasks.Task> TestInlineAddition if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (param != null && param.GetType() != typeof(byte[])) + if (requestBody != null && requestBody.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(param); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(requestBody); // http body (model) parameter } else { - localVarPostBody = param; // byte array + localVarPostBody = requestBody; // byte array } @@ -2947,7 +3140,7 @@ public ApiResponse TestQueryParameterCollectionFormatWithHttpInfo (List< if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (pipe != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "pipe", pipe)); // query parameter + if (pipe != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("multi", "pipe", pipe)); // query parameter if (ioutil != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "ioutil", ioutil)); // query parameter if (http != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("space", "http", http)); // query parameter if (url != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "url", url)); // query parameter @@ -3036,7 +3229,7 @@ public async System.Threading.Tasks.Task> TestQueryParameter if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (pipe != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "pipe", pipe)); // query parameter + if (pipe != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("multi", "pipe", pipe)); // query parameter if (ioutil != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "ioutil", ioutil)); // query parameter if (http != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("space", "http", http)); // query parameter if (url != null) localVarQueryParams.AddRange(this.Configuration.ApiClient.ParameterToKeyValuePairs("csv", "url", url)); // query parameter diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs index ed259e8ef956..3e40d789b421 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs @@ -31,9 +31,9 @@ public interface IFakeClassnameTags123Api : IApiAccessor /// To test class name in snake case /// /// Thrown when fails to make API call - /// client model + /// client model /// ModelClient - ModelClient TestClassname (ModelClient body); + ModelClient TestClassname (ModelClient modelClient); /// /// To test class name in snake case @@ -42,9 +42,9 @@ public interface IFakeClassnameTags123Api : IApiAccessor /// To test class name in snake case /// /// Thrown when fails to make API call - /// client model + /// client model /// ApiResponse of ModelClient - ApiResponse TestClassnameWithHttpInfo (ModelClient body); + ApiResponse TestClassnameWithHttpInfo (ModelClient modelClient); #endregion Synchronous Operations #region Asynchronous Operations /// @@ -54,9 +54,9 @@ public interface IFakeClassnameTags123Api : IApiAccessor /// To test class name in snake case /// /// Thrown when fails to make API call - /// client model + /// client model /// Task of ModelClient - System.Threading.Tasks.Task TestClassnameAsync (ModelClient body); + System.Threading.Tasks.Task TestClassnameAsync (ModelClient modelClient); /// /// To test class name in snake case @@ -65,9 +65,9 @@ public interface IFakeClassnameTags123Api : IApiAccessor /// To test class name in snake case /// /// Thrown when fails to make API call - /// client model + /// client model /// Task of ApiResponse (ModelClient) - System.Threading.Tasks.Task> TestClassnameAsyncWithHttpInfo (ModelClient body); + System.Threading.Tasks.Task> TestClassnameAsyncWithHttpInfo (ModelClient modelClient); #endregion Asynchronous Operations } @@ -183,11 +183,11 @@ public void AddDefaultHeader(string key, string value) /// To test class name in snake case To test class name in snake case /// /// Thrown when fails to make API call - /// client model + /// client model /// ModelClient - public ModelClient TestClassname (ModelClient body) + public ModelClient TestClassname (ModelClient modelClient) { - ApiResponse localVarResponse = TestClassnameWithHttpInfo(body); + ApiResponse localVarResponse = TestClassnameWithHttpInfo(modelClient); return localVarResponse.Data; } @@ -195,13 +195,13 @@ public ModelClient TestClassname (ModelClient body) /// To test class name in snake case To test class name in snake case /// /// Thrown when fails to make API call - /// client model + /// client model /// ApiResponse of ModelClient - public ApiResponse TestClassnameWithHttpInfo (ModelClient body) + public ApiResponse TestClassnameWithHttpInfo (ModelClient modelClient) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling FakeClassnameTags123Api->TestClassname"); + // verify the required parameter 'modelClient' is set + if (modelClient == null) + throw new ApiException(400, "Missing required parameter 'modelClient' when calling FakeClassnameTags123Api->TestClassname"); var localVarPath = "/fake_classname_test"; var localVarPathParams = new Dictionary(); @@ -225,13 +225,13 @@ public ApiResponse TestClassnameWithHttpInfo (ModelClient body) if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (modelClient != null && modelClient.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(modelClient); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = modelClient; // byte array } // authentication (api_key_query) required @@ -262,11 +262,11 @@ public ApiResponse TestClassnameWithHttpInfo (ModelClient body) /// To test class name in snake case To test class name in snake case /// /// Thrown when fails to make API call - /// client model + /// client model /// Task of ModelClient - public async System.Threading.Tasks.Task TestClassnameAsync (ModelClient body) + public async System.Threading.Tasks.Task TestClassnameAsync (ModelClient modelClient) { - ApiResponse localVarResponse = await TestClassnameAsyncWithHttpInfo(body); + ApiResponse localVarResponse = await TestClassnameAsyncWithHttpInfo(modelClient); return localVarResponse.Data; } @@ -275,13 +275,13 @@ public async System.Threading.Tasks.Task TestClassnameAsync (ModelC /// To test class name in snake case To test class name in snake case /// /// Thrown when fails to make API call - /// client model + /// client model /// Task of ApiResponse (ModelClient) - public async System.Threading.Tasks.Task> TestClassnameAsyncWithHttpInfo (ModelClient body) + public async System.Threading.Tasks.Task> TestClassnameAsyncWithHttpInfo (ModelClient modelClient) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling FakeClassnameTags123Api->TestClassname"); + // verify the required parameter 'modelClient' is set + if (modelClient == null) + throw new ApiException(400, "Missing required parameter 'modelClient' when calling FakeClassnameTags123Api->TestClassname"); var localVarPath = "/fake_classname_test"; var localVarPathParams = new Dictionary(); @@ -305,13 +305,13 @@ public async System.Threading.Tasks.Task> TestClassname if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (modelClient != null && modelClient.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(modelClient); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = modelClient; // byte array } // authentication (api_key_query) required diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Api/PetApi.cs b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Api/PetApi.cs index 2b83ede5ea29..06279f072038 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Api/PetApi.cs +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Api/PetApi.cs @@ -31,9 +31,9 @@ public interface IPetApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// - void AddPet (Pet body); + void AddPet (Pet pet); /// /// Add a new pet to the store @@ -42,9 +42,9 @@ public interface IPetApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// ApiResponse of Object(void) - ApiResponse AddPetWithHttpInfo (Pet body); + ApiResponse AddPetWithHttpInfo (Pet pet); /// /// Deletes a pet /// @@ -138,9 +138,9 @@ public interface IPetApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// - void UpdatePet (Pet body); + void UpdatePet (Pet pet); /// /// Update an existing pet @@ -149,9 +149,9 @@ public interface IPetApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// ApiResponse of Object(void) - ApiResponse UpdatePetWithHttpInfo (Pet body); + ApiResponse UpdatePetWithHttpInfo (Pet pet); /// /// Updates a pet in the store with form data /// @@ -236,9 +236,9 @@ public interface IPetApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// Task of void - System.Threading.Tasks.Task AddPetAsync (Pet body); + System.Threading.Tasks.Task AddPetAsync (Pet pet); /// /// Add a new pet to the store @@ -247,9 +247,9 @@ public interface IPetApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// Task of ApiResponse - System.Threading.Tasks.Task> AddPetAsyncWithHttpInfo (Pet body); + System.Threading.Tasks.Task> AddPetAsyncWithHttpInfo (Pet pet); /// /// Deletes a pet /// @@ -343,9 +343,9 @@ public interface IPetApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// Task of void - System.Threading.Tasks.Task UpdatePetAsync (Pet body); + System.Threading.Tasks.Task UpdatePetAsync (Pet pet); /// /// Update an existing pet @@ -354,9 +354,9 @@ public interface IPetApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// Task of ApiResponse - System.Threading.Tasks.Task> UpdatePetAsyncWithHttpInfo (Pet body); + System.Threading.Tasks.Task> UpdatePetAsyncWithHttpInfo (Pet pet); /// /// Updates a pet in the store with form data /// @@ -547,24 +547,24 @@ public void AddDefaultHeader(string key, string value) /// Add a new pet to the store /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// - public void AddPet (Pet body) + public void AddPet (Pet pet) { - AddPetWithHttpInfo(body); + AddPetWithHttpInfo(pet); } /// /// Add a new pet to the store /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// ApiResponse of Object(void) - public ApiResponse AddPetWithHttpInfo (Pet body) + public ApiResponse AddPetWithHttpInfo (Pet pet) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling PetApi->AddPet"); + // verify the required parameter 'pet' is set + if (pet == null) + throw new ApiException(400, "Missing required parameter 'pet' when calling PetApi->AddPet"); var localVarPath = "/pet"; var localVarPathParams = new Dictionary(); @@ -588,13 +588,13 @@ public ApiResponse AddPetWithHttpInfo (Pet body) if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (pet != null && pet.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(pet); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = pet; // byte array } // authentication (petstore_auth) required @@ -626,11 +626,11 @@ public ApiResponse AddPetWithHttpInfo (Pet body) /// Add a new pet to the store /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// Task of void - public async System.Threading.Tasks.Task AddPetAsync (Pet body) + public async System.Threading.Tasks.Task AddPetAsync (Pet pet) { - await AddPetAsyncWithHttpInfo(body); + await AddPetAsyncWithHttpInfo(pet); } @@ -638,13 +638,13 @@ public async System.Threading.Tasks.Task AddPetAsync (Pet body) /// Add a new pet to the store /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// Task of ApiResponse - public async System.Threading.Tasks.Task> AddPetAsyncWithHttpInfo (Pet body) + public async System.Threading.Tasks.Task> AddPetAsyncWithHttpInfo (Pet pet) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling PetApi->AddPet"); + // verify the required parameter 'pet' is set + if (pet == null) + throw new ApiException(400, "Missing required parameter 'pet' when calling PetApi->AddPet"); var localVarPath = "/pet"; var localVarPathParams = new Dictionary(); @@ -668,13 +668,13 @@ public async System.Threading.Tasks.Task> AddPetAsyncWithHtt if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (pet != null && pet.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(pet); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = pet; // byte array } // authentication (petstore_auth) required @@ -1292,24 +1292,24 @@ public async System.Threading.Tasks.Task> GetPetByIdAsyncWithHt /// Update an existing pet /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// - public void UpdatePet (Pet body) + public void UpdatePet (Pet pet) { - UpdatePetWithHttpInfo(body); + UpdatePetWithHttpInfo(pet); } /// /// Update an existing pet /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// ApiResponse of Object(void) - public ApiResponse UpdatePetWithHttpInfo (Pet body) + public ApiResponse UpdatePetWithHttpInfo (Pet pet) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling PetApi->UpdatePet"); + // verify the required parameter 'pet' is set + if (pet == null) + throw new ApiException(400, "Missing required parameter 'pet' when calling PetApi->UpdatePet"); var localVarPath = "/pet"; var localVarPathParams = new Dictionary(); @@ -1333,13 +1333,13 @@ public ApiResponse UpdatePetWithHttpInfo (Pet body) if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (pet != null && pet.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(pet); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = pet; // byte array } // authentication (petstore_auth) required @@ -1371,11 +1371,11 @@ public ApiResponse UpdatePetWithHttpInfo (Pet body) /// Update an existing pet /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// Task of void - public async System.Threading.Tasks.Task UpdatePetAsync (Pet body) + public async System.Threading.Tasks.Task UpdatePetAsync (Pet pet) { - await UpdatePetAsyncWithHttpInfo(body); + await UpdatePetAsyncWithHttpInfo(pet); } @@ -1383,13 +1383,13 @@ public async System.Threading.Tasks.Task UpdatePetAsync (Pet body) /// Update an existing pet /// /// Thrown when fails to make API call - /// Pet object that needs to be added to the store + /// Pet object that needs to be added to the store /// Task of ApiResponse - public async System.Threading.Tasks.Task> UpdatePetAsyncWithHttpInfo (Pet body) + public async System.Threading.Tasks.Task> UpdatePetAsyncWithHttpInfo (Pet pet) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling PetApi->UpdatePet"); + // verify the required parameter 'pet' is set + if (pet == null) + throw new ApiException(400, "Missing required parameter 'pet' when calling PetApi->UpdatePet"); var localVarPath = "/pet"; var localVarPathParams = new Dictionary(); @@ -1413,13 +1413,13 @@ public async System.Threading.Tasks.Task> UpdatePetAsyncWith if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (pet != null && pet.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(pet); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = pet; // byte array } // authentication (petstore_auth) required diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Api/StoreApi.cs b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Api/StoreApi.cs index 18a1678b2596..5929ce68a649 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Api/StoreApi.cs +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Api/StoreApi.cs @@ -92,9 +92,9 @@ public interface IStoreApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// order placed for purchasing the pet + /// order placed for purchasing the pet /// Order - Order PlaceOrder (Order body); + Order PlaceOrder (Order order); /// /// Place an order for a pet @@ -103,9 +103,9 @@ public interface IStoreApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// order placed for purchasing the pet + /// order placed for purchasing the pet /// ApiResponse of Order - ApiResponse PlaceOrderWithHttpInfo (Order body); + ApiResponse PlaceOrderWithHttpInfo (Order order); #endregion Synchronous Operations #region Asynchronous Operations /// @@ -176,9 +176,9 @@ public interface IStoreApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// order placed for purchasing the pet + /// order placed for purchasing the pet /// Task of Order - System.Threading.Tasks.Task PlaceOrderAsync (Order body); + System.Threading.Tasks.Task PlaceOrderAsync (Order order); /// /// Place an order for a pet @@ -187,9 +187,9 @@ public interface IStoreApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// order placed for purchasing the pet + /// order placed for purchasing the pet /// Task of ApiResponse (Order) - System.Threading.Tasks.Task> PlaceOrderAsyncWithHttpInfo (Order body); + System.Threading.Tasks.Task> PlaceOrderAsyncWithHttpInfo (Order order); #endregion Asynchronous Operations } @@ -700,11 +700,11 @@ public async System.Threading.Tasks.Task> GetOrderByIdAsyncWi /// Place an order for a pet /// /// Thrown when fails to make API call - /// order placed for purchasing the pet + /// order placed for purchasing the pet /// Order - public Order PlaceOrder (Order body) + public Order PlaceOrder (Order order) { - ApiResponse localVarResponse = PlaceOrderWithHttpInfo(body); + ApiResponse localVarResponse = PlaceOrderWithHttpInfo(order); return localVarResponse.Data; } @@ -712,13 +712,13 @@ public Order PlaceOrder (Order body) /// Place an order for a pet /// /// Thrown when fails to make API call - /// order placed for purchasing the pet + /// order placed for purchasing the pet /// ApiResponse of Order - public ApiResponse PlaceOrderWithHttpInfo (Order body) + public ApiResponse PlaceOrderWithHttpInfo (Order order) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling StoreApi->PlaceOrder"); + // verify the required parameter 'order' is set + if (order == null) + throw new ApiException(400, "Missing required parameter 'order' when calling StoreApi->PlaceOrder"); var localVarPath = "/store/order"; var localVarPathParams = new Dictionary(); @@ -730,6 +730,7 @@ public ApiResponse PlaceOrderWithHttpInfo (Order body) // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -742,13 +743,13 @@ public ApiResponse PlaceOrderWithHttpInfo (Order body) if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (order != null && order.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(order); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = order; // byte array } @@ -774,11 +775,11 @@ public ApiResponse PlaceOrderWithHttpInfo (Order body) /// Place an order for a pet /// /// Thrown when fails to make API call - /// order placed for purchasing the pet + /// order placed for purchasing the pet /// Task of Order - public async System.Threading.Tasks.Task PlaceOrderAsync (Order body) + public async System.Threading.Tasks.Task PlaceOrderAsync (Order order) { - ApiResponse localVarResponse = await PlaceOrderAsyncWithHttpInfo(body); + ApiResponse localVarResponse = await PlaceOrderAsyncWithHttpInfo(order); return localVarResponse.Data; } @@ -787,13 +788,13 @@ public async System.Threading.Tasks.Task PlaceOrderAsync (Order body) /// Place an order for a pet /// /// Thrown when fails to make API call - /// order placed for purchasing the pet + /// order placed for purchasing the pet /// Task of ApiResponse (Order) - public async System.Threading.Tasks.Task> PlaceOrderAsyncWithHttpInfo (Order body) + public async System.Threading.Tasks.Task> PlaceOrderAsyncWithHttpInfo (Order order) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling StoreApi->PlaceOrder"); + // verify the required parameter 'order' is set + if (order == null) + throw new ApiException(400, "Missing required parameter 'order' when calling StoreApi->PlaceOrder"); var localVarPath = "/store/order"; var localVarPathParams = new Dictionary(); @@ -805,6 +806,7 @@ public async System.Threading.Tasks.Task> PlaceOrderAsyncWith // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -817,13 +819,13 @@ public async System.Threading.Tasks.Task> PlaceOrderAsyncWith if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (order != null && order.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(order); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = order; // byte array } diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Api/UserApi.cs b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Api/UserApi.cs index fa56bb06f5ac..2584bed7b2dd 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Api/UserApi.cs +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Api/UserApi.cs @@ -31,9 +31,9 @@ public interface IUserApi : IApiAccessor /// This can only be done by the logged in user. /// /// Thrown when fails to make API call - /// Created user object + /// Created user object /// - void CreateUser (User body); + void CreateUser (User user); /// /// Create user @@ -42,9 +42,9 @@ public interface IUserApi : IApiAccessor /// This can only be done by the logged in user. /// /// Thrown when fails to make API call - /// Created user object + /// Created user object /// ApiResponse of Object(void) - ApiResponse CreateUserWithHttpInfo (User body); + ApiResponse CreateUserWithHttpInfo (User user); /// /// Creates list of users with given input array /// @@ -52,9 +52,9 @@ public interface IUserApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// List of user object + /// List of user object /// - void CreateUsersWithArrayInput (List body); + void CreateUsersWithArrayInput (List user); /// /// Creates list of users with given input array @@ -63,9 +63,9 @@ public interface IUserApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// List of user object + /// List of user object /// ApiResponse of Object(void) - ApiResponse CreateUsersWithArrayInputWithHttpInfo (List body); + ApiResponse CreateUsersWithArrayInputWithHttpInfo (List user); /// /// Creates list of users with given input array /// @@ -73,9 +73,9 @@ public interface IUserApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// List of user object + /// List of user object /// - void CreateUsersWithListInput (List body); + void CreateUsersWithListInput (List user); /// /// Creates list of users with given input array @@ -84,9 +84,9 @@ public interface IUserApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// List of user object + /// List of user object /// ApiResponse of Object(void) - ApiResponse CreateUsersWithListInputWithHttpInfo (List body); + ApiResponse CreateUsersWithListInputWithHttpInfo (List user); /// /// Delete user /// @@ -179,9 +179,9 @@ public interface IUserApi : IApiAccessor /// /// Thrown when fails to make API call /// name that need to be deleted - /// Updated user object + /// Updated user object /// - void UpdateUser (string username, User body); + void UpdateUser (string username, User user); /// /// Updated user @@ -191,9 +191,9 @@ public interface IUserApi : IApiAccessor /// /// Thrown when fails to make API call /// name that need to be deleted - /// Updated user object + /// Updated user object /// ApiResponse of Object(void) - ApiResponse UpdateUserWithHttpInfo (string username, User body); + ApiResponse UpdateUserWithHttpInfo (string username, User user); #endregion Synchronous Operations #region Asynchronous Operations /// @@ -203,9 +203,9 @@ public interface IUserApi : IApiAccessor /// This can only be done by the logged in user. /// /// Thrown when fails to make API call - /// Created user object + /// Created user object /// Task of void - System.Threading.Tasks.Task CreateUserAsync (User body); + System.Threading.Tasks.Task CreateUserAsync (User user); /// /// Create user @@ -214,9 +214,9 @@ public interface IUserApi : IApiAccessor /// This can only be done by the logged in user. /// /// Thrown when fails to make API call - /// Created user object + /// Created user object /// Task of ApiResponse - System.Threading.Tasks.Task> CreateUserAsyncWithHttpInfo (User body); + System.Threading.Tasks.Task> CreateUserAsyncWithHttpInfo (User user); /// /// Creates list of users with given input array /// @@ -224,9 +224,9 @@ public interface IUserApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// List of user object + /// List of user object /// Task of void - System.Threading.Tasks.Task CreateUsersWithArrayInputAsync (List body); + System.Threading.Tasks.Task CreateUsersWithArrayInputAsync (List user); /// /// Creates list of users with given input array @@ -235,9 +235,9 @@ public interface IUserApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// List of user object + /// List of user object /// Task of ApiResponse - System.Threading.Tasks.Task> CreateUsersWithArrayInputAsyncWithHttpInfo (List body); + System.Threading.Tasks.Task> CreateUsersWithArrayInputAsyncWithHttpInfo (List user); /// /// Creates list of users with given input array /// @@ -245,9 +245,9 @@ public interface IUserApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// List of user object + /// List of user object /// Task of void - System.Threading.Tasks.Task CreateUsersWithListInputAsync (List body); + System.Threading.Tasks.Task CreateUsersWithListInputAsync (List user); /// /// Creates list of users with given input array @@ -256,9 +256,9 @@ public interface IUserApi : IApiAccessor /// /// /// Thrown when fails to make API call - /// List of user object + /// List of user object /// Task of ApiResponse - System.Threading.Tasks.Task> CreateUsersWithListInputAsyncWithHttpInfo (List body); + System.Threading.Tasks.Task> CreateUsersWithListInputAsyncWithHttpInfo (List user); /// /// Delete user /// @@ -351,9 +351,9 @@ public interface IUserApi : IApiAccessor /// /// Thrown when fails to make API call /// name that need to be deleted - /// Updated user object + /// Updated user object /// Task of void - System.Threading.Tasks.Task UpdateUserAsync (string username, User body); + System.Threading.Tasks.Task UpdateUserAsync (string username, User user); /// /// Updated user @@ -363,9 +363,9 @@ public interface IUserApi : IApiAccessor /// /// Thrown when fails to make API call /// name that need to be deleted - /// Updated user object + /// Updated user object /// Task of ApiResponse - System.Threading.Tasks.Task> UpdateUserAsyncWithHttpInfo (string username, User body); + System.Threading.Tasks.Task> UpdateUserAsyncWithHttpInfo (string username, User user); #endregion Asynchronous Operations } @@ -481,24 +481,24 @@ public void AddDefaultHeader(string key, string value) /// Create user This can only be done by the logged in user. /// /// Thrown when fails to make API call - /// Created user object + /// Created user object /// - public void CreateUser (User body) + public void CreateUser (User user) { - CreateUserWithHttpInfo(body); + CreateUserWithHttpInfo(user); } /// /// Create user This can only be done by the logged in user. /// /// Thrown when fails to make API call - /// Created user object + /// Created user object /// ApiResponse of Object(void) - public ApiResponse CreateUserWithHttpInfo (User body) + public ApiResponse CreateUserWithHttpInfo (User user) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling UserApi->CreateUser"); + // verify the required parameter 'user' is set + if (user == null) + throw new ApiException(400, "Missing required parameter 'user' when calling UserApi->CreateUser"); var localVarPath = "/user"; var localVarPathParams = new Dictionary(); @@ -510,6 +510,7 @@ public ApiResponse CreateUserWithHttpInfo (User body) // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -520,13 +521,13 @@ public ApiResponse CreateUserWithHttpInfo (User body) if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (user != null && user.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(user); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = user; // byte array } @@ -552,11 +553,11 @@ public ApiResponse CreateUserWithHttpInfo (User body) /// Create user This can only be done by the logged in user. /// /// Thrown when fails to make API call - /// Created user object + /// Created user object /// Task of void - public async System.Threading.Tasks.Task CreateUserAsync (User body) + public async System.Threading.Tasks.Task CreateUserAsync (User user) { - await CreateUserAsyncWithHttpInfo(body); + await CreateUserAsyncWithHttpInfo(user); } @@ -564,13 +565,13 @@ public async System.Threading.Tasks.Task CreateUserAsync (User body) /// Create user This can only be done by the logged in user. /// /// Thrown when fails to make API call - /// Created user object + /// Created user object /// Task of ApiResponse - public async System.Threading.Tasks.Task> CreateUserAsyncWithHttpInfo (User body) + public async System.Threading.Tasks.Task> CreateUserAsyncWithHttpInfo (User user) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling UserApi->CreateUser"); + // verify the required parameter 'user' is set + if (user == null) + throw new ApiException(400, "Missing required parameter 'user' when calling UserApi->CreateUser"); var localVarPath = "/user"; var localVarPathParams = new Dictionary(); @@ -582,6 +583,7 @@ public async System.Threading.Tasks.Task> CreateUserAsyncWit // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -592,13 +594,13 @@ public async System.Threading.Tasks.Task> CreateUserAsyncWit if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (user != null && user.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(user); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = user; // byte array } @@ -624,24 +626,24 @@ public async System.Threading.Tasks.Task> CreateUserAsyncWit /// Creates list of users with given input array /// /// Thrown when fails to make API call - /// List of user object + /// List of user object /// - public void CreateUsersWithArrayInput (List body) + public void CreateUsersWithArrayInput (List user) { - CreateUsersWithArrayInputWithHttpInfo(body); + CreateUsersWithArrayInputWithHttpInfo(user); } /// /// Creates list of users with given input array /// /// Thrown when fails to make API call - /// List of user object + /// List of user object /// ApiResponse of Object(void) - public ApiResponse CreateUsersWithArrayInputWithHttpInfo (List body) + public ApiResponse CreateUsersWithArrayInputWithHttpInfo (List user) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling UserApi->CreateUsersWithArrayInput"); + // verify the required parameter 'user' is set + if (user == null) + throw new ApiException(400, "Missing required parameter 'user' when calling UserApi->CreateUsersWithArrayInput"); var localVarPath = "/user/createWithArray"; var localVarPathParams = new Dictionary(); @@ -653,6 +655,7 @@ public ApiResponse CreateUsersWithArrayInputWithHttpInfo (List bod // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -663,13 +666,13 @@ public ApiResponse CreateUsersWithArrayInputWithHttpInfo (List bod if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (user != null && user.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(user); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = user; // byte array } @@ -695,11 +698,11 @@ public ApiResponse CreateUsersWithArrayInputWithHttpInfo (List bod /// Creates list of users with given input array /// /// Thrown when fails to make API call - /// List of user object + /// List of user object /// Task of void - public async System.Threading.Tasks.Task CreateUsersWithArrayInputAsync (List body) + public async System.Threading.Tasks.Task CreateUsersWithArrayInputAsync (List user) { - await CreateUsersWithArrayInputAsyncWithHttpInfo(body); + await CreateUsersWithArrayInputAsyncWithHttpInfo(user); } @@ -707,13 +710,13 @@ public async System.Threading.Tasks.Task CreateUsersWithArrayInputAsync (List /// Thrown when fails to make API call - /// List of user object + /// List of user object /// Task of ApiResponse - public async System.Threading.Tasks.Task> CreateUsersWithArrayInputAsyncWithHttpInfo (List body) + public async System.Threading.Tasks.Task> CreateUsersWithArrayInputAsyncWithHttpInfo (List user) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling UserApi->CreateUsersWithArrayInput"); + // verify the required parameter 'user' is set + if (user == null) + throw new ApiException(400, "Missing required parameter 'user' when calling UserApi->CreateUsersWithArrayInput"); var localVarPath = "/user/createWithArray"; var localVarPathParams = new Dictionary(); @@ -725,6 +728,7 @@ public async System.Threading.Tasks.Task> CreateUsersWithArr // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -735,13 +739,13 @@ public async System.Threading.Tasks.Task> CreateUsersWithArr if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (user != null && user.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(user); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = user; // byte array } @@ -767,24 +771,24 @@ public async System.Threading.Tasks.Task> CreateUsersWithArr /// Creates list of users with given input array /// /// Thrown when fails to make API call - /// List of user object + /// List of user object /// - public void CreateUsersWithListInput (List body) + public void CreateUsersWithListInput (List user) { - CreateUsersWithListInputWithHttpInfo(body); + CreateUsersWithListInputWithHttpInfo(user); } /// /// Creates list of users with given input array /// /// Thrown when fails to make API call - /// List of user object + /// List of user object /// ApiResponse of Object(void) - public ApiResponse CreateUsersWithListInputWithHttpInfo (List body) + public ApiResponse CreateUsersWithListInputWithHttpInfo (List user) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling UserApi->CreateUsersWithListInput"); + // verify the required parameter 'user' is set + if (user == null) + throw new ApiException(400, "Missing required parameter 'user' when calling UserApi->CreateUsersWithListInput"); var localVarPath = "/user/createWithList"; var localVarPathParams = new Dictionary(); @@ -796,6 +800,7 @@ public ApiResponse CreateUsersWithListInputWithHttpInfo (List body // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -806,13 +811,13 @@ public ApiResponse CreateUsersWithListInputWithHttpInfo (List body if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (user != null && user.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(user); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = user; // byte array } @@ -838,11 +843,11 @@ public ApiResponse CreateUsersWithListInputWithHttpInfo (List body /// Creates list of users with given input array /// /// Thrown when fails to make API call - /// List of user object + /// List of user object /// Task of void - public async System.Threading.Tasks.Task CreateUsersWithListInputAsync (List body) + public async System.Threading.Tasks.Task CreateUsersWithListInputAsync (List user) { - await CreateUsersWithListInputAsyncWithHttpInfo(body); + await CreateUsersWithListInputAsyncWithHttpInfo(user); } @@ -850,13 +855,13 @@ public async System.Threading.Tasks.Task CreateUsersWithListInputAsync (List /// Thrown when fails to make API call - /// List of user object + /// List of user object /// Task of ApiResponse - public async System.Threading.Tasks.Task> CreateUsersWithListInputAsyncWithHttpInfo (List body) + public async System.Threading.Tasks.Task> CreateUsersWithListInputAsyncWithHttpInfo (List user) { - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling UserApi->CreateUsersWithListInput"); + // verify the required parameter 'user' is set + if (user == null) + throw new ApiException(400, "Missing required parameter 'user' when calling UserApi->CreateUsersWithListInput"); var localVarPath = "/user/createWithList"; var localVarPathParams = new Dictionary(); @@ -868,6 +873,7 @@ public async System.Threading.Tasks.Task> CreateUsersWithLis // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -878,13 +884,13 @@ public async System.Threading.Tasks.Task> CreateUsersWithLis if (localVarHttpHeaderAccept != null) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); - if (body != null && body.GetType() != typeof(byte[])) + if (user != null && user.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(user); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = user; // byte array } @@ -1439,11 +1445,11 @@ public async System.Threading.Tasks.Task> LogoutUserAsyncWit /// /// Thrown when fails to make API call /// name that need to be deleted - /// Updated user object + /// Updated user object /// - public void UpdateUser (string username, User body) + public void UpdateUser (string username, User user) { - UpdateUserWithHttpInfo(username, body); + UpdateUserWithHttpInfo(username, user); } /// @@ -1451,16 +1457,16 @@ public void UpdateUser (string username, User body) /// /// Thrown when fails to make API call /// name that need to be deleted - /// Updated user object + /// Updated user object /// ApiResponse of Object(void) - public ApiResponse UpdateUserWithHttpInfo (string username, User body) + public ApiResponse UpdateUserWithHttpInfo (string username, User user) { // verify the required parameter 'username' is set if (username == null) throw new ApiException(400, "Missing required parameter 'username' when calling UserApi->UpdateUser"); - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling UserApi->UpdateUser"); + // verify the required parameter 'user' is set + if (user == null) + throw new ApiException(400, "Missing required parameter 'user' when calling UserApi->UpdateUser"); var localVarPath = "/user/{username}"; var localVarPathParams = new Dictionary(); @@ -1472,6 +1478,7 @@ public ApiResponse UpdateUserWithHttpInfo (string username, User body) // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -1483,13 +1490,13 @@ public ApiResponse UpdateUserWithHttpInfo (string username, User body) localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); if (username != null) localVarPathParams.Add("username", this.Configuration.ApiClient.ParameterToString(username)); // path parameter - if (body != null && body.GetType() != typeof(byte[])) + if (user != null && user.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(user); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = user; // byte array } @@ -1516,11 +1523,11 @@ public ApiResponse UpdateUserWithHttpInfo (string username, User body) /// /// Thrown when fails to make API call /// name that need to be deleted - /// Updated user object + /// Updated user object /// Task of void - public async System.Threading.Tasks.Task UpdateUserAsync (string username, User body) + public async System.Threading.Tasks.Task UpdateUserAsync (string username, User user) { - await UpdateUserAsyncWithHttpInfo(username, body); + await UpdateUserAsyncWithHttpInfo(username, user); } @@ -1529,16 +1536,16 @@ public async System.Threading.Tasks.Task UpdateUserAsync (string username, User /// /// Thrown when fails to make API call /// name that need to be deleted - /// Updated user object + /// Updated user object /// Task of ApiResponse - public async System.Threading.Tasks.Task> UpdateUserAsyncWithHttpInfo (string username, User body) + public async System.Threading.Tasks.Task> UpdateUserAsyncWithHttpInfo (string username, User user) { // verify the required parameter 'username' is set if (username == null) throw new ApiException(400, "Missing required parameter 'username' when calling UserApi->UpdateUser"); - // verify the required parameter 'body' is set - if (body == null) - throw new ApiException(400, "Missing required parameter 'body' when calling UserApi->UpdateUser"); + // verify the required parameter 'user' is set + if (user == null) + throw new ApiException(400, "Missing required parameter 'user' when calling UserApi->UpdateUser"); var localVarPath = "/user/{username}"; var localVarPathParams = new Dictionary(); @@ -1550,6 +1557,7 @@ public async System.Threading.Tasks.Task> UpdateUserAsyncWit // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { + "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); @@ -1561,13 +1569,13 @@ public async System.Threading.Tasks.Task> UpdateUserAsyncWit localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); if (username != null) localVarPathParams.Add("username", this.Configuration.ApiClient.ParameterToString(username)); // path parameter - if (body != null && body.GetType() != typeof(byte[])) + if (user != null && user.GetType() != typeof(byte[])) { - localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter + localVarPostBody = this.Configuration.ApiClient.Serialize(user); // http body (model) parameter } else { - localVarPostBody = body; // byte array + localVarPostBody = user; // byte array } diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/AdditionalPropertiesClass.cs b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/AdditionalPropertiesClass.cs index 53e2fbc1d03b..85e1d43e84d6 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/AdditionalPropertiesClass.cs +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/AdditionalPropertiesClass.cs @@ -36,97 +36,25 @@ public partial class AdditionalPropertiesClass : IEquatable /// Initializes a new instance of the class. /// - /// mapString. - /// mapNumber. - /// mapInteger. - /// mapBoolean. - /// mapArrayInteger. - /// mapArrayAnytype. - /// mapMapString. - /// mapMapAnytype. - /// anytype1. - /// anytype2. - /// anytype3. - public AdditionalPropertiesClass(Dictionary mapString = default(Dictionary), Dictionary mapNumber = default(Dictionary), Dictionary mapInteger = default(Dictionary), Dictionary mapBoolean = default(Dictionary), Dictionary> mapArrayInteger = default(Dictionary>), Dictionary> mapArrayAnytype = default(Dictionary>), Dictionary> mapMapString = default(Dictionary>), Dictionary> mapMapAnytype = default(Dictionary>), Object anytype1 = default(Object), Object anytype2 = default(Object), Object anytype3 = default(Object)) + /// mapProperty. + /// mapOfMapProperty. + public AdditionalPropertiesClass(Dictionary mapProperty = default(Dictionary), Dictionary> mapOfMapProperty = default(Dictionary>)) { - this.MapString = mapString; - this.MapNumber = mapNumber; - this.MapInteger = mapInteger; - this.MapBoolean = mapBoolean; - this.MapArrayInteger = mapArrayInteger; - this.MapArrayAnytype = mapArrayAnytype; - this.MapMapString = mapMapString; - this.MapMapAnytype = mapMapAnytype; - this.Anytype1 = anytype1; - this.Anytype2 = anytype2; - this.Anytype3 = anytype3; + this.MapProperty = mapProperty; + this.MapOfMapProperty = mapOfMapProperty; } /// - /// Gets or Sets MapString + /// Gets or Sets MapProperty /// - [DataMember(Name="map_string", EmitDefaultValue=true)] - public Dictionary MapString { get; set; } + [DataMember(Name="map_property", EmitDefaultValue=true)] + public Dictionary MapProperty { get; set; } /// - /// Gets or Sets MapNumber + /// Gets or Sets MapOfMapProperty /// - [DataMember(Name="map_number", EmitDefaultValue=true)] - public Dictionary MapNumber { get; set; } - - /// - /// Gets or Sets MapInteger - /// - [DataMember(Name="map_integer", EmitDefaultValue=true)] - public Dictionary MapInteger { get; set; } - - /// - /// Gets or Sets MapBoolean - /// - [DataMember(Name="map_boolean", EmitDefaultValue=true)] - public Dictionary MapBoolean { get; set; } - - /// - /// Gets or Sets MapArrayInteger - /// - [DataMember(Name="map_array_integer", EmitDefaultValue=true)] - public Dictionary> MapArrayInteger { get; set; } - - /// - /// Gets or Sets MapArrayAnytype - /// - [DataMember(Name="map_array_anytype", EmitDefaultValue=true)] - public Dictionary> MapArrayAnytype { get; set; } - - /// - /// Gets or Sets MapMapString - /// - [DataMember(Name="map_map_string", EmitDefaultValue=true)] - public Dictionary> MapMapString { get; set; } - - /// - /// Gets or Sets MapMapAnytype - /// - [DataMember(Name="map_map_anytype", EmitDefaultValue=true)] - public Dictionary> MapMapAnytype { get; set; } - - /// - /// Gets or Sets Anytype1 - /// - [DataMember(Name="anytype_1", EmitDefaultValue=true)] - public Object Anytype1 { get; set; } - - /// - /// Gets or Sets Anytype2 - /// - [DataMember(Name="anytype_2", EmitDefaultValue=true)] - public Object Anytype2 { get; set; } - - /// - /// Gets or Sets Anytype3 - /// - [DataMember(Name="anytype_3", EmitDefaultValue=true)] - public Object Anytype3 { get; set; } + [DataMember(Name="map_of_map_property", EmitDefaultValue=true)] + public Dictionary> MapOfMapProperty { get; set; } /// /// Returns the string presentation of the object @@ -136,17 +64,8 @@ public override string ToString() { var sb = new StringBuilder(); sb.Append("class AdditionalPropertiesClass {\n"); - sb.Append(" MapString: ").Append(MapString).Append("\n"); - sb.Append(" MapNumber: ").Append(MapNumber).Append("\n"); - sb.Append(" MapInteger: ").Append(MapInteger).Append("\n"); - sb.Append(" MapBoolean: ").Append(MapBoolean).Append("\n"); - sb.Append(" MapArrayInteger: ").Append(MapArrayInteger).Append("\n"); - sb.Append(" MapArrayAnytype: ").Append(MapArrayAnytype).Append("\n"); - sb.Append(" MapMapString: ").Append(MapMapString).Append("\n"); - sb.Append(" MapMapAnytype: ").Append(MapMapAnytype).Append("\n"); - sb.Append(" Anytype1: ").Append(Anytype1).Append("\n"); - sb.Append(" Anytype2: ").Append(Anytype2).Append("\n"); - sb.Append(" Anytype3: ").Append(Anytype3).Append("\n"); + sb.Append(" MapProperty: ").Append(MapProperty).Append("\n"); + sb.Append(" MapOfMapProperty: ").Append(MapOfMapProperty).Append("\n"); sb.Append("}\n"); return sb.ToString(); } @@ -182,67 +101,16 @@ public bool Equals(AdditionalPropertiesClass input) return ( - this.MapString == input.MapString || - this.MapString != null && - input.MapString != null && - this.MapString.SequenceEqual(input.MapString) - ) && - ( - this.MapNumber == input.MapNumber || - this.MapNumber != null && - input.MapNumber != null && - this.MapNumber.SequenceEqual(input.MapNumber) - ) && - ( - this.MapInteger == input.MapInteger || - this.MapInteger != null && - input.MapInteger != null && - this.MapInteger.SequenceEqual(input.MapInteger) - ) && - ( - this.MapBoolean == input.MapBoolean || - this.MapBoolean != null && - input.MapBoolean != null && - this.MapBoolean.SequenceEqual(input.MapBoolean) - ) && - ( - this.MapArrayInteger == input.MapArrayInteger || - this.MapArrayInteger != null && - input.MapArrayInteger != null && - this.MapArrayInteger.SequenceEqual(input.MapArrayInteger) - ) && - ( - this.MapArrayAnytype == input.MapArrayAnytype || - this.MapArrayAnytype != null && - input.MapArrayAnytype != null && - this.MapArrayAnytype.SequenceEqual(input.MapArrayAnytype) - ) && - ( - this.MapMapString == input.MapMapString || - this.MapMapString != null && - input.MapMapString != null && - this.MapMapString.SequenceEqual(input.MapMapString) - ) && - ( - this.MapMapAnytype == input.MapMapAnytype || - this.MapMapAnytype != null && - input.MapMapAnytype != null && - this.MapMapAnytype.SequenceEqual(input.MapMapAnytype) - ) && - ( - this.Anytype1 == input.Anytype1 || - (this.Anytype1 != null && - this.Anytype1.Equals(input.Anytype1)) - ) && - ( - this.Anytype2 == input.Anytype2 || - (this.Anytype2 != null && - this.Anytype2.Equals(input.Anytype2)) + this.MapProperty == input.MapProperty || + this.MapProperty != null && + input.MapProperty != null && + this.MapProperty.SequenceEqual(input.MapProperty) ) && ( - this.Anytype3 == input.Anytype3 || - (this.Anytype3 != null && - this.Anytype3.Equals(input.Anytype3)) + this.MapOfMapProperty == input.MapOfMapProperty || + this.MapOfMapProperty != null && + input.MapOfMapProperty != null && + this.MapOfMapProperty.SequenceEqual(input.MapOfMapProperty) ); } @@ -255,28 +123,10 @@ public override int GetHashCode() unchecked // Overflow is fine, just wrap { int hashCode = 41; - if (this.MapString != null) - hashCode = hashCode * 59 + this.MapString.GetHashCode(); - if (this.MapNumber != null) - hashCode = hashCode * 59 + this.MapNumber.GetHashCode(); - if (this.MapInteger != null) - hashCode = hashCode * 59 + this.MapInteger.GetHashCode(); - if (this.MapBoolean != null) - hashCode = hashCode * 59 + this.MapBoolean.GetHashCode(); - if (this.MapArrayInteger != null) - hashCode = hashCode * 59 + this.MapArrayInteger.GetHashCode(); - if (this.MapArrayAnytype != null) - hashCode = hashCode * 59 + this.MapArrayAnytype.GetHashCode(); - if (this.MapMapString != null) - hashCode = hashCode * 59 + this.MapMapString.GetHashCode(); - if (this.MapMapAnytype != null) - hashCode = hashCode * 59 + this.MapMapAnytype.GetHashCode(); - if (this.Anytype1 != null) - hashCode = hashCode * 59 + this.Anytype1.GetHashCode(); - if (this.Anytype2 != null) - hashCode = hashCode * 59 + this.Anytype2.GetHashCode(); - if (this.Anytype3 != null) - hashCode = hashCode * 59 + this.Anytype3.GetHashCode(); + if (this.MapProperty != null) + hashCode = hashCode * 59 + this.MapProperty.GetHashCode(); + if (this.MapOfMapProperty != null) + hashCode = hashCode * 59 + this.MapOfMapProperty.GetHashCode(); return hashCode; } } diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/Animal.cs b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/Animal.cs index e51ad5f9cbb4..8c06aadbbccc 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/Animal.cs +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/Animal.cs @@ -34,7 +34,6 @@ namespace Org.OpenAPITools.Model [JsonConverter(typeof(JsonSubtypes), "className")] [JsonSubtypes.KnownSubType(typeof(Dog), "Dog")] [JsonSubtypes.KnownSubType(typeof(Cat), "Cat")] - [JsonSubtypes.KnownSubType(typeof(BigCat), "BigCat")] [ImplementPropertyChanged] public partial class Animal : IEquatable, IValidatableObject { diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/Cat.cs b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/Cat.cs index 1c2c2baf2976..e0f794c9dbff 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/Cat.cs +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/Cat.cs @@ -145,16 +145,6 @@ public virtual void OnPropertyChanged(string propertyName) /// Validation context /// Validation Result IEnumerable IValidatableObject.Validate(ValidationContext validationContext) - { - return this.BaseValidate(validationContext); - } - - /// - /// To validate all properties of the instance - /// - /// Validation context - /// Validation Result - protected IEnumerable BaseValidate(ValidationContext validationContext) { foreach(var x in base.BaseValidate(validationContext)) yield return x; yield break; diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/EnumTest.cs b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/EnumTest.cs index d8c3e6f1cab9..b64a26bbb21d 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/EnumTest.cs +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/EnumTest.cs @@ -148,6 +148,21 @@ public enum EnumNumberEnum [DataMember(Name="outerEnum", EmitDefaultValue=true)] public OuterEnum? OuterEnum { get; set; } /// + /// Gets or Sets OuterEnumInteger + /// + [DataMember(Name="outerEnumInteger", EmitDefaultValue=true)] + public OuterEnumInteger? OuterEnumInteger { get; set; } + /// + /// Gets or Sets OuterEnumDefaultValue + /// + [DataMember(Name="outerEnumDefaultValue", EmitDefaultValue=true)] + public OuterEnumDefaultValue? OuterEnumDefaultValue { get; set; } + /// + /// Gets or Sets OuterEnumIntegerDefaultValue + /// + [DataMember(Name="outerEnumIntegerDefaultValue", EmitDefaultValue=true)] + public OuterEnumIntegerDefaultValue? OuterEnumIntegerDefaultValue { get; set; } + /// /// Initializes a new instance of the class. /// [JsonConstructorAttribute] @@ -160,7 +175,10 @@ protected EnumTest() { } /// enumInteger. /// enumNumber. /// outerEnum. - public EnumTest(EnumStringEnum? enumString = default(EnumStringEnum?), EnumStringRequiredEnum enumStringRequired = default(EnumStringRequiredEnum), EnumIntegerEnum? enumInteger = default(EnumIntegerEnum?), EnumNumberEnum? enumNumber = default(EnumNumberEnum?), OuterEnum? outerEnum = default(OuterEnum?)) + /// outerEnumInteger. + /// outerEnumDefaultValue. + /// outerEnumIntegerDefaultValue. + public EnumTest(EnumStringEnum? enumString = default(EnumStringEnum?), EnumStringRequiredEnum enumStringRequired = default(EnumStringRequiredEnum), EnumIntegerEnum? enumInteger = default(EnumIntegerEnum?), EnumNumberEnum? enumNumber = default(EnumNumberEnum?), OuterEnum? outerEnum = default(OuterEnum?), OuterEnumInteger? outerEnumInteger = default(OuterEnumInteger?), OuterEnumDefaultValue? outerEnumDefaultValue = default(OuterEnumDefaultValue?), OuterEnumIntegerDefaultValue? outerEnumIntegerDefaultValue = default(OuterEnumIntegerDefaultValue?)) { // to ensure "enumStringRequired" is required (not null) if (enumStringRequired == null) @@ -172,10 +190,14 @@ protected EnumTest() { } this.EnumStringRequired = enumStringRequired; } + this.OuterEnum = outerEnum; this.EnumString = enumString; this.EnumInteger = enumInteger; this.EnumNumber = enumNumber; this.OuterEnum = outerEnum; + this.OuterEnumInteger = outerEnumInteger; + this.OuterEnumDefaultValue = outerEnumDefaultValue; + this.OuterEnumIntegerDefaultValue = outerEnumIntegerDefaultValue; } @@ -183,6 +205,9 @@ protected EnumTest() { } + + + /// /// Returns the string presentation of the object /// @@ -196,6 +221,9 @@ public override string ToString() sb.Append(" EnumInteger: ").Append(EnumInteger).Append("\n"); sb.Append(" EnumNumber: ").Append(EnumNumber).Append("\n"); sb.Append(" OuterEnum: ").Append(OuterEnum).Append("\n"); + sb.Append(" OuterEnumInteger: ").Append(OuterEnumInteger).Append("\n"); + sb.Append(" OuterEnumDefaultValue: ").Append(OuterEnumDefaultValue).Append("\n"); + sb.Append(" OuterEnumIntegerDefaultValue: ").Append(OuterEnumIntegerDefaultValue).Append("\n"); sb.Append("}\n"); return sb.ToString(); } @@ -254,6 +282,21 @@ public bool Equals(EnumTest input) this.OuterEnum == input.OuterEnum || (this.OuterEnum != null && this.OuterEnum.Equals(input.OuterEnum)) + ) && + ( + this.OuterEnumInteger == input.OuterEnumInteger || + (this.OuterEnumInteger != null && + this.OuterEnumInteger.Equals(input.OuterEnumInteger)) + ) && + ( + this.OuterEnumDefaultValue == input.OuterEnumDefaultValue || + (this.OuterEnumDefaultValue != null && + this.OuterEnumDefaultValue.Equals(input.OuterEnumDefaultValue)) + ) && + ( + this.OuterEnumIntegerDefaultValue == input.OuterEnumIntegerDefaultValue || + (this.OuterEnumIntegerDefaultValue != null && + this.OuterEnumIntegerDefaultValue.Equals(input.OuterEnumIntegerDefaultValue)) ); } @@ -276,6 +319,12 @@ public override int GetHashCode() hashCode = hashCode * 59 + this.EnumNumber.GetHashCode(); if (this.OuterEnum != null) hashCode = hashCode * 59 + this.OuterEnum.GetHashCode(); + if (this.OuterEnumInteger != null) + hashCode = hashCode * 59 + this.OuterEnumInteger.GetHashCode(); + if (this.OuterEnumDefaultValue != null) + hashCode = hashCode * 59 + this.OuterEnumDefaultValue.GetHashCode(); + if (this.OuterEnumIntegerDefaultValue != null) + hashCode = hashCode * 59 + this.OuterEnumIntegerDefaultValue.GetHashCode(); return hashCode; } } diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/Foo.cs b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/Foo.cs index c82a275a59bc..a05cfe1cd742 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/Foo.cs +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/Foo.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -53,7 +53,7 @@ public Foo(string bar = "bar") /// /// Gets or Sets Bar /// - [DataMember(Name="bar", EmitDefaultValue=false)] + [DataMember(Name="bar", EmitDefaultValue=true)] public string Bar { get; set; } /// diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/FormatTest.cs b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/FormatTest.cs index b3ebc9f373b9..a2cb72d567f1 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/FormatTest.cs +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/FormatTest.cs @@ -54,8 +54,9 @@ protected FormatTest() { } /// dateTime. /// uuid. /// password (required). - /// bigDecimal. - public FormatTest(int integer = default(int), int int32 = default(int), long int64 = default(long), decimal number = default(decimal), float _float = default(float), double _double = default(double), string _string = default(string), byte[] _byte = default(byte[]), System.IO.Stream binary = default(System.IO.Stream), DateTime date = default(DateTime), DateTime dateTime = default(DateTime), Guid uuid = default(Guid), string password = default(string), decimal bigDecimal = default(decimal)) + /// A string that is a 10 digit number. Can have leading zeros.. + /// A string starting with 'image_' (case insensitive) and one to three digits following i.e. Image_01.. + public FormatTest(int integer = default(int), int int32 = default(int), long int64 = default(long), decimal number = default(decimal), float _float = default(float), double _double = default(double), string _string = default(string), byte[] _byte = default(byte[]), System.IO.Stream binary = default(System.IO.Stream), DateTime date = default(DateTime), DateTime dateTime = default(DateTime), Guid uuid = default(Guid), string password = default(string), string patternWithDigits = default(string), string patternWithDigitsAndDelimiter = default(string)) { // to ensure "number" is required (not null) if (number == null) @@ -106,7 +107,8 @@ protected FormatTest() { } this.Binary = binary; this.DateTime = dateTime; this.Uuid = uuid; - this.BigDecimal = bigDecimal; + this.PatternWithDigits = patternWithDigits; + this.PatternWithDigitsAndDelimiter = patternWithDigitsAndDelimiter; } /// @@ -189,10 +191,18 @@ protected FormatTest() { } public string Password { get; set; } /// - /// Gets or Sets BigDecimal + /// A string that is a 10 digit number. Can have leading zeros. /// - [DataMember(Name="BigDecimal", EmitDefaultValue=true)] - public decimal BigDecimal { get; set; } + /// A string that is a 10 digit number. Can have leading zeros. + [DataMember(Name="pattern_with_digits", EmitDefaultValue=true)] + public string PatternWithDigits { get; set; } + + /// + /// A string starting with 'image_' (case insensitive) and one to three digits following i.e. Image_01. + /// + /// A string starting with 'image_' (case insensitive) and one to three digits following i.e. Image_01. + [DataMember(Name="pattern_with_digits_and_delimiter", EmitDefaultValue=true)] + public string PatternWithDigitsAndDelimiter { get; set; } /// /// Returns the string presentation of the object @@ -215,7 +225,8 @@ public override string ToString() sb.Append(" DateTime: ").Append(DateTime).Append("\n"); sb.Append(" Uuid: ").Append(Uuid).Append("\n"); sb.Append(" Password: ").Append(Password).Append("\n"); - sb.Append(" BigDecimal: ").Append(BigDecimal).Append("\n"); + sb.Append(" PatternWithDigits: ").Append(PatternWithDigits).Append("\n"); + sb.Append(" PatternWithDigitsAndDelimiter: ").Append(PatternWithDigitsAndDelimiter).Append("\n"); sb.Append("}\n"); return sb.ToString(); } @@ -316,9 +327,14 @@ public bool Equals(FormatTest input) this.Password.Equals(input.Password)) ) && ( - this.BigDecimal == input.BigDecimal || - (this.BigDecimal != null && - this.BigDecimal.Equals(input.BigDecimal)) + this.PatternWithDigits == input.PatternWithDigits || + (this.PatternWithDigits != null && + this.PatternWithDigits.Equals(input.PatternWithDigits)) + ) && + ( + this.PatternWithDigitsAndDelimiter == input.PatternWithDigitsAndDelimiter || + (this.PatternWithDigitsAndDelimiter != null && + this.PatternWithDigitsAndDelimiter.Equals(input.PatternWithDigitsAndDelimiter)) ); } @@ -357,8 +373,10 @@ public override int GetHashCode() hashCode = hashCode * 59 + this.Uuid.GetHashCode(); if (this.Password != null) hashCode = hashCode * 59 + this.Password.GetHashCode(); - if (this.BigDecimal != null) - hashCode = hashCode * 59 + this.BigDecimal.GetHashCode(); + if (this.PatternWithDigits != null) + hashCode = hashCode * 59 + this.PatternWithDigits.GetHashCode(); + if (this.PatternWithDigitsAndDelimiter != null) + hashCode = hashCode * 59 + this.PatternWithDigitsAndDelimiter.GetHashCode(); return hashCode; } } @@ -469,8 +487,6 @@ public virtual void OnPropertyChanged(string propertyName) yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for String, must match a pattern of " + regexString, new [] { "String" }); } - - // Password (string) maxLength if(this.Password != null && this.Password.Length > 64) { @@ -483,6 +499,24 @@ public virtual void OnPropertyChanged(string propertyName) yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Password, length must be greater than 10.", new [] { "Password" }); } + + + // PatternWithDigits (string) pattern + Regex regexPatternWithDigits = new Regex(@"^\\d{10}$", RegexOptions.CultureInvariant); + if (false == regexPatternWithDigits.Match(this.PatternWithDigits).Success) + { + yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for PatternWithDigits, must match a pattern of " + regexPatternWithDigits, new [] { "PatternWithDigits" }); + } + + + + // PatternWithDigitsAndDelimiter (string) pattern + Regex regexPatternWithDigitsAndDelimiter = new Regex(@"^image_\\d{1,3}$", RegexOptions.CultureInvariant | RegexOptions.IgnoreCase); + if (false == regexPatternWithDigitsAndDelimiter.Match(this.PatternWithDigitsAndDelimiter).Success) + { + yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for PatternWithDigitsAndDelimiter, must match a pattern of " + regexPatternWithDigitsAndDelimiter, new [] { "PatternWithDigitsAndDelimiter" }); + } + yield break; } } diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/HealthCheckResult.cs b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/HealthCheckResult.cs index cd7c74be882b..46f6afb0ebdc 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/HealthCheckResult.cs +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/HealthCheckResult.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -40,12 +40,13 @@ public partial class HealthCheckResult : IEquatable, IValida public HealthCheckResult(string nullableMessage = default(string)) { this.NullableMessage = nullableMessage; + this.NullableMessage = nullableMessage; } /// /// Gets or Sets NullableMessage /// - [DataMember(Name="NullableMessage", EmitDefaultValue=false)] + [DataMember(Name="NullableMessage", EmitDefaultValue=true)] public string NullableMessage { get; set; } /// diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/InlineObject.cs b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/InlineObject.cs index 4dae13e897f7..83271c2f5d1e 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/InlineObject.cs +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/InlineObject.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -48,14 +48,14 @@ public partial class InlineObject : IEquatable, IValidatableObjec /// Updated name of the pet /// /// Updated name of the pet - [DataMember(Name="name", EmitDefaultValue=false)] + [DataMember(Name="name", EmitDefaultValue=true)] public string Name { get; set; } /// /// Updated status of the pet /// /// Updated status of the pet - [DataMember(Name="status", EmitDefaultValue=false)] + [DataMember(Name="status", EmitDefaultValue=true)] public string Status { get; set; } /// diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/InlineObject1.cs b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/InlineObject1.cs index 073d6102999f..591132a73933 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/InlineObject1.cs +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/InlineObject1.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -48,14 +48,14 @@ public partial class InlineObject1 : IEquatable, IValidatableObj /// Additional data to pass to server /// /// Additional data to pass to server - [DataMember(Name="additionalMetadata", EmitDefaultValue=false)] + [DataMember(Name="additionalMetadata", EmitDefaultValue=true)] public string AdditionalMetadata { get; set; } /// /// file to upload /// /// file to upload - [DataMember(Name="file", EmitDefaultValue=false)] + [DataMember(Name="file", EmitDefaultValue=true)] public System.IO.Stream File { get; set; } /// diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/InlineObject2.cs b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/InlineObject2.cs index e10d573f9e1a..f6b3cdc10d2c 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/InlineObject2.cs +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/InlineObject2.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -58,7 +58,7 @@ public enum EnumFormStringArrayEnum /// Form parameter enum test (string array) /// /// Form parameter enum test (string array) - [DataMember(Name="enum_form_string_array", EmitDefaultValue=false)] + [DataMember(Name="enum_form_string_array", EmitDefaultValue=true)] public List EnumFormStringArray { get; set; } /// /// Form parameter enum test (string) @@ -91,7 +91,7 @@ public enum EnumFormStringEnum /// Form parameter enum test (string) /// /// Form parameter enum test (string) - [DataMember(Name="enum_form_string", EmitDefaultValue=false)] + [DataMember(Name="enum_form_string", EmitDefaultValue=true)] public EnumFormStringEnum? EnumFormString { get; set; } /// /// Initializes a new instance of the class. @@ -161,6 +161,7 @@ public bool Equals(InlineObject2 input) ( this.EnumFormStringArray == input.EnumFormStringArray || this.EnumFormStringArray != null && + input.EnumFormStringArray != null && this.EnumFormStringArray.SequenceEqual(input.EnumFormStringArray) ) && ( diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/InlineObject3.cs b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/InlineObject3.cs index aa6cdeac31b8..57f4bc33ea69 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/InlineObject3.cs +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/InlineObject3.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -55,7 +55,7 @@ protected InlineObject3() { } /// None. /// None. /// None. - public InlineObject3(int? integer = default(int?), int? int32 = default(int?), long? int64 = default(long?), decimal? number = default(decimal?), float? _float = default(float?), double? _double = default(double?), string _string = default(string), string patternWithoutDelimiter = default(string), byte[] _byte = default(byte[]), System.IO.Stream binary = default(System.IO.Stream), DateTime? date = default(DateTime?), DateTime? dateTime = default(DateTime?), string password = default(string), string callback = default(string)) + public InlineObject3(int integer = default(int), int int32 = default(int), long int64 = default(long), decimal number = default(decimal), float _float = default(float), double _double = default(double), string _string = default(string), string patternWithoutDelimiter = default(string), byte[] _byte = default(byte[]), System.IO.Stream binary = default(System.IO.Stream), DateTime date = default(DateTime), DateTime dateTime = default(DateTime), string password = default(string), string callback = default(string)) { // to ensure "number" is required (not null) if (number == null) @@ -66,6 +66,7 @@ protected InlineObject3() { } { this.Number = number; } + // to ensure "_double" is required (not null) if (_double == null) { @@ -75,6 +76,7 @@ protected InlineObject3() { } { this.Double = _double; } + // to ensure "patternWithoutDelimiter" is required (not null) if (patternWithoutDelimiter == null) { @@ -84,6 +86,7 @@ protected InlineObject3() { } { this.PatternWithoutDelimiter = patternWithoutDelimiter; } + // to ensure "_byte" is required (not null) if (_byte == null) { @@ -93,6 +96,7 @@ protected InlineObject3() { } { this.Byte = _byte; } + this.Integer = integer; this.Int32 = int32; this.Int64 = int64; @@ -109,99 +113,99 @@ protected InlineObject3() { } /// None /// /// None - [DataMember(Name="integer", EmitDefaultValue=false)] - public int? Integer { get; set; } + [DataMember(Name="integer", EmitDefaultValue=true)] + public int Integer { get; set; } /// /// None /// /// None - [DataMember(Name="int32", EmitDefaultValue=false)] - public int? Int32 { get; set; } + [DataMember(Name="int32", EmitDefaultValue=true)] + public int Int32 { get; set; } /// /// None /// /// None - [DataMember(Name="int64", EmitDefaultValue=false)] - public long? Int64 { get; set; } + [DataMember(Name="int64", EmitDefaultValue=true)] + public long Int64 { get; set; } /// /// None /// /// None - [DataMember(Name="number", EmitDefaultValue=false)] - public decimal? Number { get; set; } + [DataMember(Name="number", EmitDefaultValue=true)] + public decimal Number { get; set; } /// /// None /// /// None - [DataMember(Name="float", EmitDefaultValue=false)] - public float? Float { get; set; } + [DataMember(Name="float", EmitDefaultValue=true)] + public float Float { get; set; } /// /// None /// /// None - [DataMember(Name="double", EmitDefaultValue=false)] - public double? Double { get; set; } + [DataMember(Name="double", EmitDefaultValue=true)] + public double Double { get; set; } /// /// None /// /// None - [DataMember(Name="string", EmitDefaultValue=false)] + [DataMember(Name="string", EmitDefaultValue=true)] public string String { get; set; } /// /// None /// /// None - [DataMember(Name="pattern_without_delimiter", EmitDefaultValue=false)] + [DataMember(Name="pattern_without_delimiter", EmitDefaultValue=true)] public string PatternWithoutDelimiter { get; set; } /// /// None /// /// None - [DataMember(Name="byte", EmitDefaultValue=false)] + [DataMember(Name="byte", EmitDefaultValue=true)] public byte[] Byte { get; set; } /// /// None /// /// None - [DataMember(Name="binary", EmitDefaultValue=false)] + [DataMember(Name="binary", EmitDefaultValue=true)] public System.IO.Stream Binary { get; set; } /// /// None /// /// None - [DataMember(Name="date", EmitDefaultValue=false)] + [DataMember(Name="date", EmitDefaultValue=true)] [JsonConverter(typeof(OpenAPIDateConverter))] - public DateTime? Date { get; set; } + public DateTime Date { get; set; } /// /// None /// /// None - [DataMember(Name="dateTime", EmitDefaultValue=false)] - public DateTime? DateTime { get; set; } + [DataMember(Name="dateTime", EmitDefaultValue=true)] + public DateTime DateTime { get; set; } /// /// None /// /// None - [DataMember(Name="password", EmitDefaultValue=false)] + [DataMember(Name="password", EmitDefaultValue=true)] public string Password { get; set; } /// /// None /// /// None - [DataMember(Name="callback", EmitDefaultValue=false)] + [DataMember(Name="callback", EmitDefaultValue=true)] public string Callback { get; set; } /// @@ -400,60 +404,72 @@ public virtual void OnPropertyChanged(string propertyName) /// Validation Result IEnumerable IValidatableObject.Validate(ValidationContext validationContext) { - // Integer (int?) maximum - if(this.Integer > (int?)100) + + + // Integer (int) maximum + if(this.Integer > (int)100) { yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Integer, must be a value less than or equal to 100.", new [] { "Integer" }); } - // Integer (int?) minimum - if(this.Integer < (int?)10) + // Integer (int) minimum + if(this.Integer < (int)10) { yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Integer, must be a value greater than or equal to 10.", new [] { "Integer" }); } - // Int32 (int?) maximum - if(this.Int32 > (int?)200) + + + // Int32 (int) maximum + if(this.Int32 > (int)200) { yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Int32, must be a value less than or equal to 200.", new [] { "Int32" }); } - // Int32 (int?) minimum - if(this.Int32 < (int?)20) + // Int32 (int) minimum + if(this.Int32 < (int)20) { yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Int32, must be a value greater than or equal to 20.", new [] { "Int32" }); } - // Number (decimal?) maximum - if(this.Number > (decimal?)543.2) + + + // Number (decimal) maximum + if(this.Number > (decimal)543.2) { yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Number, must be a value less than or equal to 543.2.", new [] { "Number" }); } - // Number (decimal?) minimum - if(this.Number < (decimal?)32.1) + // Number (decimal) minimum + if(this.Number < (decimal)32.1) { yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Number, must be a value greater than or equal to 32.1.", new [] { "Number" }); } - // Float (float?) maximum - if(this.Float > (float?)987.6) + + + // Float (float) maximum + if(this.Float > (float)987.6) { yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Float, must be a value less than or equal to 987.6.", new [] { "Float" }); } - // Double (double?) maximum - if(this.Double > (double?)123.4) + + + // Double (double) maximum + if(this.Double > (double)123.4) { yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Double, must be a value less than or equal to 123.4.", new [] { "Double" }); } - // Double (double?) minimum - if(this.Double < (double?)67.8) + // Double (double) minimum + if(this.Double < (double)67.8) { yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Double, must be a value greater than or equal to 67.8.", new [] { "Double" }); } + + // String (string) pattern Regex regexString = new Regex(@"[a-z]", RegexOptions.CultureInvariant | RegexOptions.IgnoreCase); if (false == regexString.Match(this.String).Success) @@ -461,6 +477,8 @@ public virtual void OnPropertyChanged(string propertyName) yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for String, must match a pattern of " + regexString, new [] { "String" }); } + + // PatternWithoutDelimiter (string) pattern Regex regexPatternWithoutDelimiter = new Regex(@"^[A-Z].*", RegexOptions.CultureInvariant); if (false == regexPatternWithoutDelimiter.Match(this.PatternWithoutDelimiter).Success) @@ -479,7 +497,7 @@ public virtual void OnPropertyChanged(string propertyName) { yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Password, length must be greater than 10.", new [] { "Password" }); } - + yield break; } } diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/InlineObject4.cs b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/InlineObject4.cs index 6d19e0c9ede5..9ada27bd52d0 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/InlineObject4.cs +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/InlineObject4.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -54,6 +54,7 @@ protected InlineObject4() { } { this.Param = param; } + // to ensure "param2" is required (not null) if (param2 == null) { @@ -63,20 +64,21 @@ protected InlineObject4() { } { this.Param2 = param2; } + } /// /// field1 /// /// field1 - [DataMember(Name="param", EmitDefaultValue=false)] + [DataMember(Name="param", EmitDefaultValue=true)] public string Param { get; set; } /// /// field2 /// /// field2 - [DataMember(Name="param2", EmitDefaultValue=false)] + [DataMember(Name="param2", EmitDefaultValue=true)] public string Param2 { get; set; } /// diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/InlineObject5.cs b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/InlineObject5.cs index 45346f6e4c73..3eb8657d9ac8 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/InlineObject5.cs +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/InlineObject5.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -54,6 +54,7 @@ protected InlineObject5() { } { this.RequiredFile = requiredFile; } + this.AdditionalMetadata = additionalMetadata; } @@ -61,14 +62,14 @@ protected InlineObject5() { } /// Additional data to pass to server /// /// Additional data to pass to server - [DataMember(Name="additionalMetadata", EmitDefaultValue=false)] + [DataMember(Name="additionalMetadata", EmitDefaultValue=true)] public string AdditionalMetadata { get; set; } /// /// file to upload /// /// file to upload - [DataMember(Name="requiredFile", EmitDefaultValue=false)] + [DataMember(Name="requiredFile", EmitDefaultValue=true)] public System.IO.Stream RequiredFile { get; set; } /// diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/InlineResponseDefault.cs b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/InlineResponseDefault.cs index 39cff5c0cb14..05e5a889dcd3 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/InlineResponseDefault.cs +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/InlineResponseDefault.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -45,7 +45,7 @@ public partial class InlineResponseDefault : IEquatable, /// /// Gets or Sets String /// - [DataMember(Name="string", EmitDefaultValue=false)] + [DataMember(Name="string", EmitDefaultValue=true)] public Foo String { get; set; } /// diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/NullableClass.cs b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/NullableClass.cs index 5a5488e62f7f..f25680980807 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/NullableClass.cs +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/NullableClass.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ @@ -50,6 +50,16 @@ public partial class NullableClass : Dictionary, IEquatableobjectItemsNullable. public NullableClass(int? integerProp = default(int?), decimal? numberProp = default(decimal?), bool? booleanProp = default(bool?), string stringProp = default(string), DateTime? dateProp = default(DateTime?), DateTime? datetimeProp = default(DateTime?), List arrayNullableProp = default(List), List arrayAndItemsNullableProp = default(List), List arrayItemsNullable = default(List), Dictionary objectNullableProp = default(Dictionary), Dictionary objectAndItemsNullableProp = default(Dictionary), Dictionary objectItemsNullable = default(Dictionary)) : base() { + this.IntegerProp = integerProp; + this.NumberProp = numberProp; + this.BooleanProp = booleanProp; + this.StringProp = stringProp; + this.DateProp = dateProp; + this.DatetimeProp = datetimeProp; + this.ArrayNullableProp = arrayNullableProp; + this.ArrayAndItemsNullableProp = arrayAndItemsNullableProp; + this.ObjectNullableProp = objectNullableProp; + this.ObjectAndItemsNullableProp = objectAndItemsNullableProp; this.IntegerProp = integerProp; this.NumberProp = numberProp; this.BooleanProp = booleanProp; @@ -67,74 +77,74 @@ public partial class NullableClass : Dictionary, IEquatable /// Gets or Sets IntegerProp /// - [DataMember(Name="integer_prop", EmitDefaultValue=false)] + [DataMember(Name="integer_prop", EmitDefaultValue=true)] public int? IntegerProp { get; set; } /// /// Gets or Sets NumberProp /// - [DataMember(Name="number_prop", EmitDefaultValue=false)] + [DataMember(Name="number_prop", EmitDefaultValue=true)] public decimal? NumberProp { get; set; } /// /// Gets or Sets BooleanProp /// - [DataMember(Name="boolean_prop", EmitDefaultValue=false)] + [DataMember(Name="boolean_prop", EmitDefaultValue=true)] public bool? BooleanProp { get; set; } /// /// Gets or Sets StringProp /// - [DataMember(Name="string_prop", EmitDefaultValue=false)] + [DataMember(Name="string_prop", EmitDefaultValue=true)] public string StringProp { get; set; } /// /// Gets or Sets DateProp /// - [DataMember(Name="date_prop", EmitDefaultValue=false)] + [DataMember(Name="date_prop", EmitDefaultValue=true)] [JsonConverter(typeof(OpenAPIDateConverter))] public DateTime? DateProp { get; set; } /// /// Gets or Sets DatetimeProp /// - [DataMember(Name="datetime_prop", EmitDefaultValue=false)] + [DataMember(Name="datetime_prop", EmitDefaultValue=true)] public DateTime? DatetimeProp { get; set; } /// /// Gets or Sets ArrayNullableProp /// - [DataMember(Name="array_nullable_prop", EmitDefaultValue=false)] + [DataMember(Name="array_nullable_prop", EmitDefaultValue=true)] public List ArrayNullableProp { get; set; } /// /// Gets or Sets ArrayAndItemsNullableProp /// - [DataMember(Name="array_and_items_nullable_prop", EmitDefaultValue=false)] + [DataMember(Name="array_and_items_nullable_prop", EmitDefaultValue=true)] public List ArrayAndItemsNullableProp { get; set; } /// /// Gets or Sets ArrayItemsNullable /// - [DataMember(Name="array_items_nullable", EmitDefaultValue=false)] + [DataMember(Name="array_items_nullable", EmitDefaultValue=true)] public List ArrayItemsNullable { get; set; } /// /// Gets or Sets ObjectNullableProp /// - [DataMember(Name="object_nullable_prop", EmitDefaultValue=false)] + [DataMember(Name="object_nullable_prop", EmitDefaultValue=true)] public Dictionary ObjectNullableProp { get; set; } /// /// Gets or Sets ObjectAndItemsNullableProp /// - [DataMember(Name="object_and_items_nullable_prop", EmitDefaultValue=false)] + [DataMember(Name="object_and_items_nullable_prop", EmitDefaultValue=true)] public Dictionary ObjectAndItemsNullableProp { get; set; } /// /// Gets or Sets ObjectItemsNullable /// - [DataMember(Name="object_items_nullable", EmitDefaultValue=false)] + [DataMember(Name="object_items_nullable", EmitDefaultValue=true)] public Dictionary ObjectItemsNullable { get; set; } /// @@ -225,31 +235,37 @@ public bool Equals(NullableClass input) ( this.ArrayNullableProp == input.ArrayNullableProp || this.ArrayNullableProp != null && + input.ArrayNullableProp != null && this.ArrayNullableProp.SequenceEqual(input.ArrayNullableProp) ) && base.Equals(input) && ( this.ArrayAndItemsNullableProp == input.ArrayAndItemsNullableProp || this.ArrayAndItemsNullableProp != null && + input.ArrayAndItemsNullableProp != null && this.ArrayAndItemsNullableProp.SequenceEqual(input.ArrayAndItemsNullableProp) ) && base.Equals(input) && ( this.ArrayItemsNullable == input.ArrayItemsNullable || this.ArrayItemsNullable != null && + input.ArrayItemsNullable != null && this.ArrayItemsNullable.SequenceEqual(input.ArrayItemsNullable) ) && base.Equals(input) && ( this.ObjectNullableProp == input.ObjectNullableProp || this.ObjectNullableProp != null && + input.ObjectNullableProp != null && this.ObjectNullableProp.SequenceEqual(input.ObjectNullableProp) ) && base.Equals(input) && ( this.ObjectAndItemsNullableProp == input.ObjectAndItemsNullableProp || this.ObjectAndItemsNullableProp != null && + input.ObjectAndItemsNullableProp != null && this.ObjectAndItemsNullableProp.SequenceEqual(input.ObjectAndItemsNullableProp) ) && base.Equals(input) && ( this.ObjectItemsNullable == input.ObjectItemsNullable || this.ObjectItemsNullable != null && + input.ObjectItemsNullable != null && this.ObjectItemsNullable.SequenceEqual(input.ObjectItemsNullable) ); } diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/OuterEnumDefaultValue.cs b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/OuterEnumDefaultValue.cs index 747888328380..929ec2f35735 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/OuterEnumDefaultValue.cs +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/OuterEnumDefaultValue.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/OuterEnumInteger.cs b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/OuterEnumInteger.cs index efda7884efb5..17167a170170 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/OuterEnumInteger.cs +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/OuterEnumInteger.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */ diff --git a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/OuterEnumIntegerDefaultValue.cs b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/OuterEnumIntegerDefaultValue.cs index b5420de878c3..7bc889406e4f 100644 --- a/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/OuterEnumIntegerDefaultValue.cs +++ b/samples/client/petstore/csharp/OpenAPIClientWithPropertyChanged/src/Org.OpenAPITools/Model/OuterEnumIntegerDefaultValue.cs @@ -3,7 +3,7 @@ * * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * Generated by: https://github.com/openapitools/openapi-generator.git */