From 4e24cf53f5492caee31566d13766b78137515901 Mon Sep 17 00:00:00 2001 From: "Cymanski, Maciej" Date: Wed, 11 Dec 2024 09:00:53 +0100 Subject: [PATCH] [CSHARP] Default headers overwritten instead of duplicated | Body parameter in post request serialized --- docs/generators/fsharp-functions.md | 2 +- docs/generators/fsharp-giraffe-server.md | 2 +- docs/generators/java-inflector.md | 2 +- docs/generators/jaxrs-cxf-client.md | 2 +- docs/generators/swift5.md | 4 +- docs/generators/swift6.md | 4 +- .../main/resources/csharp/ApiClient.mustache | 2 +- .../src/main/resources/csharp/api.mustache | 4 +- .../src/Org.OpenAPITools/Api/BodyApi.cs | 28 ++++++------ .../src/Org.OpenAPITools/Client/ApiClient.cs | 2 +- .../php-nextgen-streaming/phpunit.xml.dist | 4 +- .../echo_api/php-nextgen/phpunit.xml.dist | 4 +- .../src/Org.OpenAPITools/Client/ApiClient.cs | 2 +- .../src/Org.OpenAPITools/Api/PetApi.cs | 8 ++-- .../src/Org.OpenAPITools/Api/StoreApi.cs | 4 +- .../src/Org.OpenAPITools/Api/UserApi.cs | 16 +++---- .../src/Org.OpenAPITools/Client/ApiClient.cs | 2 +- .../Org.OpenAPITools/Api/AnotherFakeApi.cs | 4 +- .../src/Org.OpenAPITools/Api/FakeApi.cs | 44 +++++++++---------- .../Api/FakeClassnameTags123Api.cs | 4 +- .../src/Org.OpenAPITools/Api/PetApi.cs | 8 ++-- .../src/Org.OpenAPITools/Api/StoreApi.cs | 4 +- .../src/Org.OpenAPITools/Api/UserApi.cs | 16 +++---- .../src/Org.OpenAPITools/Client/ApiClient.cs | 2 +- .../Org.OpenAPITools/Api/AnotherFakeApi.cs | 4 +- .../src/Org.OpenAPITools/Api/FakeApi.cs | 44 +++++++++---------- .../Api/FakeClassnameTags123Api.cs | 4 +- .../src/Org.OpenAPITools/Api/PetApi.cs | 8 ++-- .../src/Org.OpenAPITools/Api/StoreApi.cs | 4 +- .../src/Org.OpenAPITools/Api/UserApi.cs | 16 +++---- .../src/Org.OpenAPITools/Client/ApiClient.cs | 2 +- .../src/Org.OpenAPITools/Client/ApiClient.cs | 2 +- .../Org.OpenAPITools/Api/AnotherFakeApi.cs | 4 +- .../src/Org.OpenAPITools/Api/FakeApi.cs | 44 +++++++++---------- .../Api/FakeClassnameTags123Api.cs | 4 +- .../src/Org.OpenAPITools/Api/PetApi.cs | 8 ++-- .../src/Org.OpenAPITools/Api/StoreApi.cs | 4 +- .../src/Org.OpenAPITools/Api/UserApi.cs | 16 +++---- .../src/Org.OpenAPITools/Client/ApiClient.cs | 2 +- .../Org.OpenAPITools/Api/AnotherFakeApi.cs | 4 +- .../src/Org.OpenAPITools/Api/FakeApi.cs | 44 +++++++++---------- .../Api/FakeClassnameTags123Api.cs | 4 +- .../src/Org.OpenAPITools/Api/PetApi.cs | 8 ++-- .../src/Org.OpenAPITools/Api/StoreApi.cs | 4 +- .../src/Org.OpenAPITools/Api/UserApi.cs | 16 +++---- .../src/Org.OpenAPITools/Client/ApiClient.cs | 2 +- .../src/Org.OpenAPITools/Client/ApiClient.cs | 2 +- .../Org.OpenAPITools/Api/AnotherFakeApi.cs | 4 +- .../src/Org.OpenAPITools/Api/FakeApi.cs | 44 +++++++++---------- .../Api/FakeClassnameTags123Api.cs | 4 +- .../src/Org.OpenAPITools/Api/PetApi.cs | 8 ++-- .../src/Org.OpenAPITools/Api/StoreApi.cs | 4 +- .../src/Org.OpenAPITools/Api/UserApi.cs | 16 +++---- .../src/Org.OpenAPITools/Client/ApiClient.cs | 2 +- .../Org.OpenAPITools/Api/AnotherFakeApi.cs | 4 +- .../src/Org.OpenAPITools/Api/FakeApi.cs | 44 +++++++++---------- .../Api/FakeClassnameTags123Api.cs | 4 +- .../src/Org.OpenAPITools/Api/PetApi.cs | 8 ++-- .../src/Org.OpenAPITools/Api/StoreApi.cs | 4 +- .../src/Org.OpenAPITools/Api/UserApi.cs | 16 +++---- .../src/Org.OpenAPITools/Client/ApiClient.cs | 2 +- .../OpenAPIClient-php/phpunit.xml.dist | 4 +- .../Org.OpenAPITools/Controllers/FakeApi.cs | 2 +- .../Org.OpenAPITools/Controllers/PetApi.cs | 12 ++--- .../Org.OpenAPITools/Controllers/StoreApi.cs | 4 +- .../Org.OpenAPITools/Controllers/UserApi.cs | 2 +- .../Org.OpenAPITools/Controllers/FakeApi.cs | 2 +- .../Org.OpenAPITools/Controllers/PetApi.cs | 12 ++--- .../Org.OpenAPITools/Controllers/StoreApi.cs | 4 +- .../Org.OpenAPITools/Controllers/UserApi.cs | 2 +- .../Org.OpenAPITools/Controllers/FakeApi.cs | 2 +- .../Org.OpenAPITools/Controllers/PetApi.cs | 12 ++--- .../Org.OpenAPITools/Controllers/StoreApi.cs | 4 +- .../Org.OpenAPITools/Controllers/UserApi.cs | 2 +- .../Org.OpenAPITools/Controllers/FakeApi.cs | 2 +- .../Org.OpenAPITools/Controllers/PetApi.cs | 12 ++--- .../Org.OpenAPITools/Controllers/StoreApi.cs | 4 +- .../Org.OpenAPITools/Controllers/UserApi.cs | 2 +- .../Org.OpenAPITools/Controllers/FakeApi.cs | 2 +- .../Org.OpenAPITools/Controllers/PetApi.cs | 12 ++--- .../Org.OpenAPITools/Controllers/StoreApi.cs | 4 +- .../Org.OpenAPITools/Controllers/UserApi.cs | 2 +- .../Org.OpenAPITools/Controllers/FakeApi.cs | 2 +- .../Org.OpenAPITools/Controllers/PetApi.cs | 12 ++--- .../Org.OpenAPITools/Controllers/StoreApi.cs | 4 +- .../Org.OpenAPITools/Controllers/UserApi.cs | 2 +- .../Org.OpenAPITools/Controllers/FakeApi.cs | 2 +- .../Org.OpenAPITools/Controllers/PetApi.cs | 12 ++--- .../Org.OpenAPITools/Controllers/StoreApi.cs | 4 +- .../Org.OpenAPITools/Controllers/UserApi.cs | 2 +- .../Org.OpenAPITools/Controllers/FakeApi.cs | 2 +- .../Org.OpenAPITools/Controllers/PetApi.cs | 12 ++--- .../Org.OpenAPITools/Controllers/StoreApi.cs | 4 +- .../Org.OpenAPITools/Controllers/UserApi.cs | 2 +- .../Org.OpenAPITools/Controllers/FakeApi.cs | 2 +- .../Org.OpenAPITools/Controllers/PetApi.cs | 12 ++--- .../Org.OpenAPITools/Controllers/StoreApi.cs | 4 +- .../Org.OpenAPITools/Controllers/UserApi.cs | 2 +- .../Org.OpenAPITools/Controllers/FakeApi.cs | 2 +- .../Org.OpenAPITools/Controllers/PetApi.cs | 12 ++--- .../Org.OpenAPITools/Controllers/StoreApi.cs | 4 +- .../Org.OpenAPITools/Controllers/UserApi.cs | 2 +- .../Org.OpenAPITools/Controllers/FakeApi.cs | 2 +- .../Org.OpenAPITools/Controllers/PetApi.cs | 12 ++--- .../Org.OpenAPITools/Controllers/StoreApi.cs | 4 +- .../Org.OpenAPITools/Controllers/UserApi.cs | 2 +- .../Org.OpenAPITools/Controllers/FakeApi.cs | 2 +- .../Org.OpenAPITools/Controllers/PetApi.cs | 12 ++--- .../Org.OpenAPITools/Controllers/StoreApi.cs | 4 +- .../Org.OpenAPITools/Controllers/UserApi.cs | 2 +- .../Org.OpenAPITools/Controllers/FakeApi.cs | 2 +- .../Org.OpenAPITools/Controllers/PetApi.cs | 12 ++--- .../Org.OpenAPITools/Controllers/StoreApi.cs | 4 +- .../Org.OpenAPITools/Controllers/UserApi.cs | 2 +- .../Org.OpenAPITools/Controllers/PetApi.cs | 8 ++-- .../Org.OpenAPITools/Controllers/StoreApi.cs | 4 +- .../Org.OpenAPITools/Controllers/UserApi.cs | 2 +- 117 files changed, 433 insertions(+), 433 deletions(-) diff --git a/docs/generators/fsharp-functions.md b/docs/generators/fsharp-functions.md index a20382152aab..33bd1f1c2922 100644 --- a/docs/generators/fsharp-functions.md +++ b/docs/generators/fsharp-functions.md @@ -34,7 +34,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |prependFormOrBodyParameters|Add form or body parameters to the beginning of the parameter list.| |false| |sortModelPropertiesByRequiredFlag|Sort model properties to place required parameters before optional parameters.| |true| |sortParamsByRequiredFlag|Sort method arguments to place required parameters before optional parameters.| |true| -|sourceFolder|source folder for generated code| |OpenAPI/src| +|sourceFolder|source folder for generated code| |OpenAPI\src| ## IMPORT MAPPING diff --git a/docs/generators/fsharp-giraffe-server.md b/docs/generators/fsharp-giraffe-server.md index abe079e504fa..fb3e25b3d776 100644 --- a/docs/generators/fsharp-giraffe-server.md +++ b/docs/generators/fsharp-giraffe-server.md @@ -30,7 +30,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |packageVersion|F# package version.| |1.0.0| |returnICollection|Return ICollection<T> instead of the concrete type.| |false| |sortParamsByRequiredFlag|Sort method arguments to place required parameters before optional parameters.| |true| -|sourceFolder|source folder for generated code| |OpenAPI/src| +|sourceFolder|source folder for generated code| |OpenAPI\src| |useCollection|Deserialize array types to Collection<T> instead of List<T>.| |false| |useDateTimeOffset|Use DateTimeOffset to model date-time properties| |false| |useSwashbuckle|Uses the Swashbuckle.AspNetCore NuGet package for documentation.| |false| diff --git a/docs/generators/java-inflector.md b/docs/generators/java-inflector.md index 210db1efcb9a..6fa2edb47f90 100644 --- a/docs/generators/java-inflector.md +++ b/docs/generators/java-inflector.md @@ -66,7 +66,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |snapshotVersion|Uses a SNAPSHOT version.|
**true**
Use a SnapShot Version
**false**
Use a Release Version
|null| |sortModelPropertiesByRequiredFlag|Sort model properties to place required parameters before optional parameters.| |true| |sortParamsByRequiredFlag|Sort method arguments to place required parameters before optional parameters.| |true| -|sourceFolder|source folder for generated code| |src/gen/java| +|sourceFolder|source folder for generated code| |src\gen\java| |testOutput|Set output folder for models and APIs tests| |${project.build.directory}/generated-test-sources/openapi| |useJakartaEe|whether to use Jakarta EE namespace instead of javax| |false| |useOneOfInterfaces|whether to use a java interface to describe a set of oneOf options, where each option is a class that implements the interface| |false| diff --git a/docs/generators/jaxrs-cxf-client.md b/docs/generators/jaxrs-cxf-client.md index 29a7923078b0..d89f12fbf3ab 100644 --- a/docs/generators/jaxrs-cxf-client.md +++ b/docs/generators/jaxrs-cxf-client.md @@ -66,7 +66,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |snapshotVersion|Uses a SNAPSHOT version.|
**true**
Use a SnapShot Version
**false**
Use a Release Version
|null| |sortModelPropertiesByRequiredFlag|Sort model properties to place required parameters before optional parameters.| |true| |sortParamsByRequiredFlag|Sort method arguments to place required parameters before optional parameters.| |true| -|sourceFolder|source folder for generated code| |src/gen/java| +|sourceFolder|source folder for generated code| |src\gen\java| |testOutput|Set output folder for models and APIs tests| |${project.build.directory}/generated-test-sources/openapi| |useAbstractionForFiles|Use alternative types instead of java.io.File to allow passing bytes without a file on disk.| |false| |useBeanValidation|Use BeanValidation API annotations| |false| diff --git a/docs/generators/swift5.md b/docs/generators/swift5.md index a46bd33730f3..d2784f45409e 100644 --- a/docs/generators/swift5.md +++ b/docs/generators/swift5.md @@ -49,13 +49,13 @@ These options may be applied as additional-properties (cli) or configOptions (pl |responseAs|Optionally use libraries to manage response. Currently PromiseKit, RxSwift, Result, Combine, AsyncAwait are available.| |null| |sortModelPropertiesByRequiredFlag|Sort model properties to place required parameters before optional parameters.| |true| |sortParamsByRequiredFlag|Sort method arguments to place required parameters before optional parameters.| |true| -|swiftPackagePath|Set a custom source path instead of OpenAPIClient/Classes/OpenAPIs.| |null| +|swiftPackagePath|Set a custom source path instead of OpenAPIClient\Classes\OpenAPIs.| |null| |swiftUseApiNamespace|Flag to make all the API classes inner-class of {{projectName}}API| |null| |useBacktickEscapes|Escape reserved words using backticks (default: false)| |false| |useClasses|Use final classes for models instead of structs (default: false)| |false| |useCustomDateWithoutTime|Uses a custom type to decode and encode dates without time information to support OpenAPIs date format (default: false)| |false| |useJsonEncodable|Make models conform to JSONEncodable protocol (default: true)| |true| -|useSPMFileStructure|Use SPM file structure and set the source path to Sources/{{projectName}} (default: false).| |null| +|useSPMFileStructure|Use SPM file structure and set the source path to Sources\{{projectName}} (default: false).| |null| |validatable|Make validation rules and validator for model properies (default: true)| |true| ## IMPORT MAPPING diff --git a/docs/generators/swift6.md b/docs/generators/swift6.md index b80a1d7996ab..a03f58beb357 100644 --- a/docs/generators/swift6.md +++ b/docs/generators/swift6.md @@ -51,13 +51,13 @@ These options may be applied as additional-properties (cli) or configOptions (pl |responseAs|Optionally use libraries to manage response. Currently AsyncAwait, Combine, Result, RxSwift, ObjcBlock, PromiseKit are available.| |null| |sortModelPropertiesByRequiredFlag|Sort model properties to place required parameters before optional parameters.| |true| |sortParamsByRequiredFlag|Sort method arguments to place required parameters before optional parameters.| |true| -|swiftPackagePath|Set a custom source path instead of Sources/{{projectName}}.| |null| +|swiftPackagePath|Set a custom source path instead of Sources\{{projectName}}.| |null| |swiftUseApiNamespace|Flag to make all the API classes inner-class of {{projectName}}API| |null| |useBacktickEscapes|Escape reserved words using backticks (default: false)| |false| |useClasses|Use final classes for models instead of structs (default: false)| |false| |useCustomDateWithoutTime|Uses a custom type to decode and encode dates without time information to support OpenAPIs date format (default: false)| |false| |useJsonEncodable|Make models conform to JSONEncodable protocol (default: true)| |true| -|useSPMFileStructure|Use SPM file structure and set the source path to Sources/{{projectName}} (default: true).| |null| +|useSPMFileStructure|Use SPM file structure and set the source path to Sources\{{projectName}} (default: true).| |null| |validatable|Make validation rules and validator for model properies (default: true)| |true| ## IMPORT MAPPING diff --git a/modules/openapi-generator/src/main/resources/csharp/ApiClient.mustache b/modules/openapi-generator/src/main/resources/csharp/ApiClient.mustache index 91ea70055b06..d20141a77138 100644 --- a/modules/openapi-generator/src/main/resources/csharp/ApiClient.mustache +++ b/modules/openapi-generator/src/main/resources/csharp/ApiClient.mustache @@ -317,7 +317,7 @@ namespace {{packageName}}.Client { foreach (var value in headerParam.Value) { - request.AddHeader(headerParam.Key, value); + request.AddOrUpdateHeader(headerParam.Key, value); } } } diff --git a/modules/openapi-generator/src/main/resources/csharp/api.mustache b/modules/openapi-generator/src/main/resources/csharp/api.mustache index fae106702fd5..a58a8537b889 100644 --- a/modules/openapi-generator/src/main/resources/csharp/api.mustache +++ b/modules/openapi-generator/src/main/resources/csharp/api.mustache @@ -403,7 +403,7 @@ namespace {{packageName}}.{{apiPackage}} {{/required}} {{/formParams}} {{#bodyParam}} - localVarRequestOptions.Data = {{paramName}}; + localVarRequestOptions.Data = {{packageName}}.Client.ClientUtils.Serialize({{paramName}}); {{/bodyParam}} localVarRequestOptions.Operation = "{{classname}}.{{operationId}}"; @@ -693,7 +693,7 @@ namespace {{packageName}}.{{apiPackage}} {{/required}} {{/formParams}} {{#bodyParam}} - localVarRequestOptions.Data = {{paramName}}; + localVarRequestOptions.Data = {{packageName}}.Client.ClientUtils.Serialize({{paramName}}); {{/bodyParam}} localVarRequestOptions.Operation = "{{classname}}.{{operationId}}"; diff --git a/samples/client/echo_api/csharp-restsharp/src/Org.OpenAPITools/Api/BodyApi.cs b/samples/client/echo_api/csharp-restsharp/src/Org.OpenAPITools/Api/BodyApi.cs index 159ebbd2542f..91a5a291fa5a 100644 --- a/samples/client/echo_api/csharp-restsharp/src/Org.OpenAPITools/Api/BodyApi.cs +++ b/samples/client/echo_api/csharp-restsharp/src/Org.OpenAPITools/Api/BodyApi.cs @@ -803,7 +803,7 @@ public System.IO.Stream TestBinaryGif(int operationIndex = 0) localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "BodyApi.TestBodyApplicationOctetstreamBinary"; localVarRequestOptions.OperationIndex = operationIndex; @@ -871,7 +871,7 @@ public System.IO.Stream TestBinaryGif(int operationIndex = 0) localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "BodyApi.TestBodyApplicationOctetstreamBinary"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1229,7 +1229,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyMultipartFormdataArra localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "BodyApi.TestEchoBodyAllOfPet"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1297,7 +1297,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyMultipartFormdataArra localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "BodyApi.TestEchoBodyAllOfPet"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1363,7 +1363,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyMultipartFormdataArra localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "BodyApi.TestEchoBodyFreeFormObjectResponseString"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1431,7 +1431,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyMultipartFormdataArra localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "BodyApi.TestEchoBodyFreeFormObjectResponseString"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1497,7 +1497,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyMultipartFormdataArra localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "BodyApi.TestEchoBodyPet"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1565,7 +1565,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyMultipartFormdataArra localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "BodyApi.TestEchoBodyPet"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1631,7 +1631,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyMultipartFormdataArra localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "BodyApi.TestEchoBodyPetResponseString"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1699,7 +1699,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyMultipartFormdataArra localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "BodyApi.TestEchoBodyPetResponseString"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1765,7 +1765,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyMultipartFormdataArra localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "BodyApi.TestEchoBodyStringEnum"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1833,7 +1833,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyMultipartFormdataArra localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "BodyApi.TestEchoBodyStringEnum"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1899,7 +1899,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyMultipartFormdataArra localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = tag; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(tag); localVarRequestOptions.Operation = "BodyApi.TestEchoBodyTagResponseString"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1967,7 +1967,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyMultipartFormdataArra localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = tag; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(tag); localVarRequestOptions.Operation = "BodyApi.TestEchoBodyTagResponseString"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/echo_api/csharp-restsharp/src/Org.OpenAPITools/Client/ApiClient.cs b/samples/client/echo_api/csharp-restsharp/src/Org.OpenAPITools/Client/ApiClient.cs index 655b101ecf78..2313090500a1 100644 --- a/samples/client/echo_api/csharp-restsharp/src/Org.OpenAPITools/Client/ApiClient.cs +++ b/samples/client/echo_api/csharp-restsharp/src/Org.OpenAPITools/Client/ApiClient.cs @@ -317,7 +317,7 @@ private RestRequest NewRequest( { foreach (var value in headerParam.Value) { - request.AddHeader(headerParam.Key, value); + request.AddOrUpdateHeader(headerParam.Key, value); } } } diff --git a/samples/client/echo_api/php-nextgen-streaming/phpunit.xml.dist b/samples/client/echo_api/php-nextgen-streaming/phpunit.xml.dist index 1135449a8d9b..cba878f52707 100644 --- a/samples/client/echo_api/php-nextgen-streaming/phpunit.xml.dist +++ b/samples/client/echo_api/php-nextgen-streaming/phpunit.xml.dist @@ -2,8 +2,8 @@ - ./src/Api - ./src/Model + ./src\/Api + ./src\/Model diff --git a/samples/client/echo_api/php-nextgen/phpunit.xml.dist b/samples/client/echo_api/php-nextgen/phpunit.xml.dist index 1135449a8d9b..cba878f52707 100644 --- a/samples/client/echo_api/php-nextgen/phpunit.xml.dist +++ b/samples/client/echo_api/php-nextgen/phpunit.xml.dist @@ -2,8 +2,8 @@ - ./src/Api - ./src/Model + ./src\/Api + ./src\/Model diff --git a/samples/client/others/csharp-complex-files/src/Org.OpenAPITools/Client/ApiClient.cs b/samples/client/others/csharp-complex-files/src/Org.OpenAPITools/Client/ApiClient.cs index 91b7422b713e..5d7a2a7960db 100644 --- a/samples/client/others/csharp-complex-files/src/Org.OpenAPITools/Client/ApiClient.cs +++ b/samples/client/others/csharp-complex-files/src/Org.OpenAPITools/Client/ApiClient.cs @@ -317,7 +317,7 @@ private RestRequest NewRequest( { foreach (var value in headerParam.Value) { - request.AddHeader(headerParam.Key, value); + request.AddOrUpdateHeader(headerParam.Key, value); } } } diff --git a/samples/client/petstore/csharp/restsharp/net4.7/MultipleFrameworks/src/Org.OpenAPITools/Api/PetApi.cs b/samples/client/petstore/csharp/restsharp/net4.7/MultipleFrameworks/src/Org.OpenAPITools/Api/PetApi.cs index a268ca3af4d6..1b5161f2f37b 100644 --- a/samples/client/petstore/csharp/restsharp/net4.7/MultipleFrameworks/src/Org.OpenAPITools/Api/PetApi.cs +++ b/samples/client/petstore/csharp/restsharp/net4.7/MultipleFrameworks/src/Org.OpenAPITools/Api/PetApi.cs @@ -602,7 +602,7 @@ public Org.OpenAPITools.Client.ApiResponse AddPetWithHttpInfo(Pet pet, int localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "PetApi.AddPet"; localVarRequestOptions.OperationIndex = operationIndex; @@ -694,7 +694,7 @@ public Org.OpenAPITools.Client.ApiResponse AddPetWithHttpInfo(Pet pet, int localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "PetApi.AddPet"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1460,7 +1460,7 @@ public Org.OpenAPITools.Client.ApiResponse UpdatePetWithHttpInfo(Pet pet, i localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "PetApi.UpdatePet"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1552,7 +1552,7 @@ public Org.OpenAPITools.Client.ApiResponse UpdatePetWithHttpInfo(Pet pet, i localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "PetApi.UpdatePet"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/net4.7/MultipleFrameworks/src/Org.OpenAPITools/Api/StoreApi.cs b/samples/client/petstore/csharp/restsharp/net4.7/MultipleFrameworks/src/Org.OpenAPITools/Api/StoreApi.cs index 27d50bc9bdc8..9fc447accbe7 100644 --- a/samples/client/petstore/csharp/restsharp/net4.7/MultipleFrameworks/src/Org.OpenAPITools/Api/StoreApi.cs +++ b/samples/client/petstore/csharp/restsharp/net4.7/MultipleFrameworks/src/Org.OpenAPITools/Api/StoreApi.cs @@ -803,7 +803,7 @@ public Org.OpenAPITools.Client.ApiResponse PlaceOrderWithHttpInfo(Order o localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = order; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(order); localVarRequestOptions.Operation = "StoreApi.PlaceOrder"; localVarRequestOptions.OperationIndex = operationIndex; @@ -878,7 +878,7 @@ public Org.OpenAPITools.Client.ApiResponse PlaceOrderWithHttpInfo(Order o localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = order; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(order); localVarRequestOptions.Operation = "StoreApi.PlaceOrder"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/net4.7/MultipleFrameworks/src/Org.OpenAPITools/Api/UserApi.cs b/samples/client/petstore/csharp/restsharp/net4.7/MultipleFrameworks/src/Org.OpenAPITools/Api/UserApi.cs index 3f99b38d1ed1..df3bc1fcd5e1 100644 --- a/samples/client/petstore/csharp/restsharp/net4.7/MultipleFrameworks/src/Org.OpenAPITools/Api/UserApi.cs +++ b/samples/client/petstore/csharp/restsharp/net4.7/MultipleFrameworks/src/Org.OpenAPITools/Api/UserApi.cs @@ -578,7 +578,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUserWithHttpInfo(User u localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUser"; localVarRequestOptions.OperationIndex = operationIndex; @@ -655,7 +655,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUserWithHttpInfo(User u localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUser"; localVarRequestOptions.OperationIndex = operationIndex; @@ -730,7 +730,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUsersWithArrayInputWith localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUsersWithArrayInput"; localVarRequestOptions.OperationIndex = operationIndex; @@ -807,7 +807,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUsersWithArrayInputWith localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUsersWithArrayInput"; localVarRequestOptions.OperationIndex = operationIndex; @@ -882,7 +882,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUsersWithListInputWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUsersWithListInput"; localVarRequestOptions.OperationIndex = operationIndex; @@ -959,7 +959,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUsersWithListInputWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUsersWithListInput"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1635,7 +1635,7 @@ public Org.OpenAPITools.Client.ApiResponse UpdateUserWithHttpInfo(string } localVarRequestOptions.PathParameters.Add("username", Org.OpenAPITools.Client.ClientUtils.ParameterToString(username)); // path parameter - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.UpdateUser"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1721,7 +1721,7 @@ public Org.OpenAPITools.Client.ApiResponse UpdateUserWithHttpInfo(string } localVarRequestOptions.PathParameters.Add("username", Org.OpenAPITools.Client.ClientUtils.ParameterToString(username)); // path parameter - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.UpdateUser"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/net4.7/MultipleFrameworks/src/Org.OpenAPITools/Client/ApiClient.cs b/samples/client/petstore/csharp/restsharp/net4.7/MultipleFrameworks/src/Org.OpenAPITools/Client/ApiClient.cs index 38ba17f24b23..6b4b0afd05ad 100644 --- a/samples/client/petstore/csharp/restsharp/net4.7/MultipleFrameworks/src/Org.OpenAPITools/Client/ApiClient.cs +++ b/samples/client/petstore/csharp/restsharp/net4.7/MultipleFrameworks/src/Org.OpenAPITools/Client/ApiClient.cs @@ -318,7 +318,7 @@ private RestRequest NewRequest( { foreach (var value in headerParam.Value) { - request.AddHeader(headerParam.Key, value); + request.AddOrUpdateHeader(headerParam.Key, value); } } } diff --git a/samples/client/petstore/csharp/restsharp/net4.7/Petstore/src/Org.OpenAPITools/Api/AnotherFakeApi.cs b/samples/client/petstore/csharp/restsharp/net4.7/Petstore/src/Org.OpenAPITools/Api/AnotherFakeApi.cs index 9ccd159a44f9..7026453735e3 100644 --- a/samples/client/petstore/csharp/restsharp/net4.7/Petstore/src/Org.OpenAPITools/Api/AnotherFakeApi.cs +++ b/samples/client/petstore/csharp/restsharp/net4.7/Petstore/src/Org.OpenAPITools/Api/AnotherFakeApi.cs @@ -255,7 +255,7 @@ public Org.OpenAPITools.Client.ApiResponse Call123TestSpecialTagsWi localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "AnotherFakeApi.Call123TestSpecialTags"; localVarRequestOptions.OperationIndex = operationIndex; @@ -329,7 +329,7 @@ public Org.OpenAPITools.Client.ApiResponse Call123TestSpecialTagsWi localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "AnotherFakeApi.Call123TestSpecialTags"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/net4.7/Petstore/src/Org.OpenAPITools/Api/FakeApi.cs b/samples/client/petstore/csharp/restsharp/net4.7/Petstore/src/Org.OpenAPITools/Api/FakeApi.cs index a61c5d240e23..635af7389f4d 100644 --- a/samples/client/petstore/csharp/restsharp/net4.7/Petstore/src/Org.OpenAPITools/Api/FakeApi.cs +++ b/samples/client/petstore/csharp/restsharp/net4.7/Petstore/src/Org.OpenAPITools/Api/FakeApi.cs @@ -1385,7 +1385,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterBooleanSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1453,7 +1453,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterBooleanSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1519,7 +1519,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = outerComposite; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(outerComposite); localVarRequestOptions.Operation = "FakeApi.FakeOuterCompositeSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1587,7 +1587,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = outerComposite; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(outerComposite); localVarRequestOptions.Operation = "FakeApi.FakeOuterCompositeSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1653,7 +1653,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterNumberSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1721,7 +1721,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterNumberSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1790,7 +1790,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH } localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("", "required_string_uuid", requiredStringUuid)); - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterStringSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1861,7 +1861,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH } localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("", "required_string_uuid", requiredStringUuid)); - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterStringSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2309,7 +2309,7 @@ public Org.OpenAPITools.Client.ApiResponse TestAdditionalPropertiesRefer localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestAdditionalPropertiesReference"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2381,7 +2381,7 @@ public Org.OpenAPITools.Client.ApiResponse TestAdditionalPropertiesRefer localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestAdditionalPropertiesReference"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2451,7 +2451,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyWithFileSchemaWithHtt localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = fileSchemaTestClass; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(fileSchemaTestClass); localVarRequestOptions.Operation = "FakeApi.TestBodyWithFileSchema"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2523,7 +2523,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyWithFileSchemaWithHtt localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = fileSchemaTestClass; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(fileSchemaTestClass); localVarRequestOptions.Operation = "FakeApi.TestBodyWithFileSchema"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2602,7 +2602,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyWithQueryParamsWithHt } localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("", "query", query)); - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "FakeApi.TestBodyWithQueryParams"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2683,7 +2683,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyWithQueryParamsWithHt } localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("", "query", query)); - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "FakeApi.TestBodyWithQueryParams"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2755,7 +2755,7 @@ public Org.OpenAPITools.Client.ApiResponse TestClientModelWithHttpI localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "FakeApi.TestClientModel"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2829,7 +2829,7 @@ public Org.OpenAPITools.Client.ApiResponse TestClientModelWithHttpI localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "FakeApi.TestClientModel"; localVarRequestOptions.OperationIndex = operationIndex; @@ -3611,7 +3611,7 @@ public Org.OpenAPITools.Client.ApiResponse TestInlineAdditionalPropertie localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestInlineAdditionalProperties"; localVarRequestOptions.OperationIndex = operationIndex; @@ -3683,7 +3683,7 @@ public Org.OpenAPITools.Client.ApiResponse TestInlineAdditionalPropertie localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestInlineAdditionalProperties"; localVarRequestOptions.OperationIndex = operationIndex; @@ -3753,7 +3753,7 @@ public Org.OpenAPITools.Client.ApiResponse TestInlineFreeformAdditionalP localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = testInlineFreeformAdditionalPropertiesRequest; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(testInlineFreeformAdditionalPropertiesRequest); localVarRequestOptions.Operation = "FakeApi.TestInlineFreeformAdditionalProperties"; localVarRequestOptions.OperationIndex = operationIndex; @@ -3825,7 +3825,7 @@ public Org.OpenAPITools.Client.ApiResponse TestInlineFreeformAdditionalP localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = testInlineFreeformAdditionalPropertiesRequest; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(testInlineFreeformAdditionalPropertiesRequest); localVarRequestOptions.Operation = "FakeApi.TestInlineFreeformAdditionalProperties"; localVarRequestOptions.OperationIndex = operationIndex; @@ -4327,7 +4327,7 @@ public Org.OpenAPITools.Client.ApiResponse TestStringMapReferenceWithHtt localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestStringMapReference"; localVarRequestOptions.OperationIndex = operationIndex; @@ -4399,7 +4399,7 @@ public Org.OpenAPITools.Client.ApiResponse TestStringMapReferenceWithHtt localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestStringMapReference"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/net4.7/Petstore/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs b/samples/client/petstore/csharp/restsharp/net4.7/Petstore/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs index b0e5066eef8f..1c6ac47fed5e 100644 --- a/samples/client/petstore/csharp/restsharp/net4.7/Petstore/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs +++ b/samples/client/petstore/csharp/restsharp/net4.7/Petstore/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs @@ -255,7 +255,7 @@ public Org.OpenAPITools.Client.ApiResponse TestClassnameWithHttpInf localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "FakeClassnameTags123Api.TestClassname"; localVarRequestOptions.OperationIndex = operationIndex; @@ -334,7 +334,7 @@ public Org.OpenAPITools.Client.ApiResponse TestClassnameWithHttpInf localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "FakeClassnameTags123Api.TestClassname"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/net4.7/Petstore/src/Org.OpenAPITools/Api/PetApi.cs b/samples/client/petstore/csharp/restsharp/net4.7/Petstore/src/Org.OpenAPITools/Api/PetApi.cs index 8db5fd36849d..678d0c001cbd 100644 --- a/samples/client/petstore/csharp/restsharp/net4.7/Petstore/src/Org.OpenAPITools/Api/PetApi.cs +++ b/samples/client/petstore/csharp/restsharp/net4.7/Petstore/src/Org.OpenAPITools/Api/PetApi.cs @@ -652,7 +652,7 @@ public Org.OpenAPITools.Client.ApiResponse AddPetWithHttpInfo(Pet pet, i localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "PetApi.AddPet"; localVarRequestOptions.OperationIndex = operationIndex; @@ -757,7 +757,7 @@ public Org.OpenAPITools.Client.ApiResponse AddPetWithHttpInfo(Pet pet, i localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "PetApi.AddPet"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1610,7 +1610,7 @@ public Org.OpenAPITools.Client.ApiResponse UpdatePetWithHttpInfo(Pet pet localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "PetApi.UpdatePet"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1715,7 +1715,7 @@ public Org.OpenAPITools.Client.ApiResponse UpdatePetWithHttpInfo(Pet pet localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "PetApi.UpdatePet"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/net4.7/Petstore/src/Org.OpenAPITools/Api/StoreApi.cs b/samples/client/petstore/csharp/restsharp/net4.7/Petstore/src/Org.OpenAPITools/Api/StoreApi.cs index e8882b0fc2e4..616d3228e602 100644 --- a/samples/client/petstore/csharp/restsharp/net4.7/Petstore/src/Org.OpenAPITools/Api/StoreApi.cs +++ b/samples/client/petstore/csharp/restsharp/net4.7/Petstore/src/Org.OpenAPITools/Api/StoreApi.cs @@ -803,7 +803,7 @@ public Org.OpenAPITools.Client.ApiResponse PlaceOrderWithHttpInfo(Order o localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = order; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(order); localVarRequestOptions.Operation = "StoreApi.PlaceOrder"; localVarRequestOptions.OperationIndex = operationIndex; @@ -878,7 +878,7 @@ public Org.OpenAPITools.Client.ApiResponse PlaceOrderWithHttpInfo(Order o localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = order; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(order); localVarRequestOptions.Operation = "StoreApi.PlaceOrder"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/net4.7/Petstore/src/Org.OpenAPITools/Api/UserApi.cs b/samples/client/petstore/csharp/restsharp/net4.7/Petstore/src/Org.OpenAPITools/Api/UserApi.cs index 174d0572e677..dfdd55bed5ba 100644 --- a/samples/client/petstore/csharp/restsharp/net4.7/Petstore/src/Org.OpenAPITools/Api/UserApi.cs +++ b/samples/client/petstore/csharp/restsharp/net4.7/Petstore/src/Org.OpenAPITools/Api/UserApi.cs @@ -578,7 +578,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUserWithHttpInfo(User u localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUser"; localVarRequestOptions.OperationIndex = operationIndex; @@ -650,7 +650,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUserWithHttpInfo(User u localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUser"; localVarRequestOptions.OperationIndex = operationIndex; @@ -720,7 +720,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUsersWithArrayInputWith localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUsersWithArrayInput"; localVarRequestOptions.OperationIndex = operationIndex; @@ -792,7 +792,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUsersWithArrayInputWith localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUsersWithArrayInput"; localVarRequestOptions.OperationIndex = operationIndex; @@ -862,7 +862,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUsersWithListInputWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUsersWithListInput"; localVarRequestOptions.OperationIndex = operationIndex; @@ -934,7 +934,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUsersWithListInputWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUsersWithListInput"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1585,7 +1585,7 @@ public Org.OpenAPITools.Client.ApiResponse UpdateUserWithHttpInfo(string } localVarRequestOptions.PathParameters.Add("username", Org.OpenAPITools.Client.ClientUtils.ParameterToString(username)); // path parameter - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.UpdateUser"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1666,7 +1666,7 @@ public Org.OpenAPITools.Client.ApiResponse UpdateUserWithHttpInfo(string } localVarRequestOptions.PathParameters.Add("username", Org.OpenAPITools.Client.ClientUtils.ParameterToString(username)); // path parameter - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.UpdateUser"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/net4.7/Petstore/src/Org.OpenAPITools/Client/ApiClient.cs b/samples/client/petstore/csharp/restsharp/net4.7/Petstore/src/Org.OpenAPITools/Client/ApiClient.cs index a0a43ea74aeb..39facdbcf94f 100644 --- a/samples/client/petstore/csharp/restsharp/net4.7/Petstore/src/Org.OpenAPITools/Client/ApiClient.cs +++ b/samples/client/petstore/csharp/restsharp/net4.7/Petstore/src/Org.OpenAPITools/Client/ApiClient.cs @@ -318,7 +318,7 @@ private RestRequest NewRequest( { foreach (var value in headerParam.Value) { - request.AddHeader(headerParam.Key, value); + request.AddOrUpdateHeader(headerParam.Key, value); } } } diff --git a/samples/client/petstore/csharp/restsharp/net4.8/Petstore/src/Org.OpenAPITools/Api/AnotherFakeApi.cs b/samples/client/petstore/csharp/restsharp/net4.8/Petstore/src/Org.OpenAPITools/Api/AnotherFakeApi.cs index 9ccd159a44f9..7026453735e3 100644 --- a/samples/client/petstore/csharp/restsharp/net4.8/Petstore/src/Org.OpenAPITools/Api/AnotherFakeApi.cs +++ b/samples/client/petstore/csharp/restsharp/net4.8/Petstore/src/Org.OpenAPITools/Api/AnotherFakeApi.cs @@ -255,7 +255,7 @@ public Org.OpenAPITools.Client.ApiResponse Call123TestSpecialTagsWi localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "AnotherFakeApi.Call123TestSpecialTags"; localVarRequestOptions.OperationIndex = operationIndex; @@ -329,7 +329,7 @@ public Org.OpenAPITools.Client.ApiResponse Call123TestSpecialTagsWi localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "AnotherFakeApi.Call123TestSpecialTags"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/net4.8/Petstore/src/Org.OpenAPITools/Api/FakeApi.cs b/samples/client/petstore/csharp/restsharp/net4.8/Petstore/src/Org.OpenAPITools/Api/FakeApi.cs index a61c5d240e23..635af7389f4d 100644 --- a/samples/client/petstore/csharp/restsharp/net4.8/Petstore/src/Org.OpenAPITools/Api/FakeApi.cs +++ b/samples/client/petstore/csharp/restsharp/net4.8/Petstore/src/Org.OpenAPITools/Api/FakeApi.cs @@ -1385,7 +1385,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterBooleanSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1453,7 +1453,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterBooleanSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1519,7 +1519,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = outerComposite; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(outerComposite); localVarRequestOptions.Operation = "FakeApi.FakeOuterCompositeSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1587,7 +1587,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = outerComposite; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(outerComposite); localVarRequestOptions.Operation = "FakeApi.FakeOuterCompositeSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1653,7 +1653,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterNumberSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1721,7 +1721,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterNumberSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1790,7 +1790,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH } localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("", "required_string_uuid", requiredStringUuid)); - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterStringSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1861,7 +1861,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH } localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("", "required_string_uuid", requiredStringUuid)); - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterStringSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2309,7 +2309,7 @@ public Org.OpenAPITools.Client.ApiResponse TestAdditionalPropertiesRefer localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestAdditionalPropertiesReference"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2381,7 +2381,7 @@ public Org.OpenAPITools.Client.ApiResponse TestAdditionalPropertiesRefer localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestAdditionalPropertiesReference"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2451,7 +2451,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyWithFileSchemaWithHtt localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = fileSchemaTestClass; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(fileSchemaTestClass); localVarRequestOptions.Operation = "FakeApi.TestBodyWithFileSchema"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2523,7 +2523,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyWithFileSchemaWithHtt localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = fileSchemaTestClass; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(fileSchemaTestClass); localVarRequestOptions.Operation = "FakeApi.TestBodyWithFileSchema"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2602,7 +2602,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyWithQueryParamsWithHt } localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("", "query", query)); - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "FakeApi.TestBodyWithQueryParams"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2683,7 +2683,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyWithQueryParamsWithHt } localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("", "query", query)); - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "FakeApi.TestBodyWithQueryParams"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2755,7 +2755,7 @@ public Org.OpenAPITools.Client.ApiResponse TestClientModelWithHttpI localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "FakeApi.TestClientModel"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2829,7 +2829,7 @@ public Org.OpenAPITools.Client.ApiResponse TestClientModelWithHttpI localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "FakeApi.TestClientModel"; localVarRequestOptions.OperationIndex = operationIndex; @@ -3611,7 +3611,7 @@ public Org.OpenAPITools.Client.ApiResponse TestInlineAdditionalPropertie localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestInlineAdditionalProperties"; localVarRequestOptions.OperationIndex = operationIndex; @@ -3683,7 +3683,7 @@ public Org.OpenAPITools.Client.ApiResponse TestInlineAdditionalPropertie localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestInlineAdditionalProperties"; localVarRequestOptions.OperationIndex = operationIndex; @@ -3753,7 +3753,7 @@ public Org.OpenAPITools.Client.ApiResponse TestInlineFreeformAdditionalP localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = testInlineFreeformAdditionalPropertiesRequest; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(testInlineFreeformAdditionalPropertiesRequest); localVarRequestOptions.Operation = "FakeApi.TestInlineFreeformAdditionalProperties"; localVarRequestOptions.OperationIndex = operationIndex; @@ -3825,7 +3825,7 @@ public Org.OpenAPITools.Client.ApiResponse TestInlineFreeformAdditionalP localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = testInlineFreeformAdditionalPropertiesRequest; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(testInlineFreeformAdditionalPropertiesRequest); localVarRequestOptions.Operation = "FakeApi.TestInlineFreeformAdditionalProperties"; localVarRequestOptions.OperationIndex = operationIndex; @@ -4327,7 +4327,7 @@ public Org.OpenAPITools.Client.ApiResponse TestStringMapReferenceWithHtt localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestStringMapReference"; localVarRequestOptions.OperationIndex = operationIndex; @@ -4399,7 +4399,7 @@ public Org.OpenAPITools.Client.ApiResponse TestStringMapReferenceWithHtt localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestStringMapReference"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/net4.8/Petstore/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs b/samples/client/petstore/csharp/restsharp/net4.8/Petstore/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs index b0e5066eef8f..1c6ac47fed5e 100644 --- a/samples/client/petstore/csharp/restsharp/net4.8/Petstore/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs +++ b/samples/client/petstore/csharp/restsharp/net4.8/Petstore/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs @@ -255,7 +255,7 @@ public Org.OpenAPITools.Client.ApiResponse TestClassnameWithHttpInf localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "FakeClassnameTags123Api.TestClassname"; localVarRequestOptions.OperationIndex = operationIndex; @@ -334,7 +334,7 @@ public Org.OpenAPITools.Client.ApiResponse TestClassnameWithHttpInf localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "FakeClassnameTags123Api.TestClassname"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/net4.8/Petstore/src/Org.OpenAPITools/Api/PetApi.cs b/samples/client/petstore/csharp/restsharp/net4.8/Petstore/src/Org.OpenAPITools/Api/PetApi.cs index 8db5fd36849d..678d0c001cbd 100644 --- a/samples/client/petstore/csharp/restsharp/net4.8/Petstore/src/Org.OpenAPITools/Api/PetApi.cs +++ b/samples/client/petstore/csharp/restsharp/net4.8/Petstore/src/Org.OpenAPITools/Api/PetApi.cs @@ -652,7 +652,7 @@ public Org.OpenAPITools.Client.ApiResponse AddPetWithHttpInfo(Pet pet, i localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "PetApi.AddPet"; localVarRequestOptions.OperationIndex = operationIndex; @@ -757,7 +757,7 @@ public Org.OpenAPITools.Client.ApiResponse AddPetWithHttpInfo(Pet pet, i localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "PetApi.AddPet"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1610,7 +1610,7 @@ public Org.OpenAPITools.Client.ApiResponse UpdatePetWithHttpInfo(Pet pet localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "PetApi.UpdatePet"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1715,7 +1715,7 @@ public Org.OpenAPITools.Client.ApiResponse UpdatePetWithHttpInfo(Pet pet localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "PetApi.UpdatePet"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/net4.8/Petstore/src/Org.OpenAPITools/Api/StoreApi.cs b/samples/client/petstore/csharp/restsharp/net4.8/Petstore/src/Org.OpenAPITools/Api/StoreApi.cs index e8882b0fc2e4..616d3228e602 100644 --- a/samples/client/petstore/csharp/restsharp/net4.8/Petstore/src/Org.OpenAPITools/Api/StoreApi.cs +++ b/samples/client/petstore/csharp/restsharp/net4.8/Petstore/src/Org.OpenAPITools/Api/StoreApi.cs @@ -803,7 +803,7 @@ public Org.OpenAPITools.Client.ApiResponse PlaceOrderWithHttpInfo(Order o localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = order; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(order); localVarRequestOptions.Operation = "StoreApi.PlaceOrder"; localVarRequestOptions.OperationIndex = operationIndex; @@ -878,7 +878,7 @@ public Org.OpenAPITools.Client.ApiResponse PlaceOrderWithHttpInfo(Order o localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = order; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(order); localVarRequestOptions.Operation = "StoreApi.PlaceOrder"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/net4.8/Petstore/src/Org.OpenAPITools/Api/UserApi.cs b/samples/client/petstore/csharp/restsharp/net4.8/Petstore/src/Org.OpenAPITools/Api/UserApi.cs index 174d0572e677..dfdd55bed5ba 100644 --- a/samples/client/petstore/csharp/restsharp/net4.8/Petstore/src/Org.OpenAPITools/Api/UserApi.cs +++ b/samples/client/petstore/csharp/restsharp/net4.8/Petstore/src/Org.OpenAPITools/Api/UserApi.cs @@ -578,7 +578,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUserWithHttpInfo(User u localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUser"; localVarRequestOptions.OperationIndex = operationIndex; @@ -650,7 +650,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUserWithHttpInfo(User u localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUser"; localVarRequestOptions.OperationIndex = operationIndex; @@ -720,7 +720,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUsersWithArrayInputWith localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUsersWithArrayInput"; localVarRequestOptions.OperationIndex = operationIndex; @@ -792,7 +792,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUsersWithArrayInputWith localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUsersWithArrayInput"; localVarRequestOptions.OperationIndex = operationIndex; @@ -862,7 +862,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUsersWithListInputWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUsersWithListInput"; localVarRequestOptions.OperationIndex = operationIndex; @@ -934,7 +934,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUsersWithListInputWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUsersWithListInput"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1585,7 +1585,7 @@ public Org.OpenAPITools.Client.ApiResponse UpdateUserWithHttpInfo(string } localVarRequestOptions.PathParameters.Add("username", Org.OpenAPITools.Client.ClientUtils.ParameterToString(username)); // path parameter - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.UpdateUser"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1666,7 +1666,7 @@ public Org.OpenAPITools.Client.ApiResponse UpdateUserWithHttpInfo(string } localVarRequestOptions.PathParameters.Add("username", Org.OpenAPITools.Client.ClientUtils.ParameterToString(username)); // path parameter - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.UpdateUser"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/net4.8/Petstore/src/Org.OpenAPITools/Client/ApiClient.cs b/samples/client/petstore/csharp/restsharp/net4.8/Petstore/src/Org.OpenAPITools/Client/ApiClient.cs index a0a43ea74aeb..39facdbcf94f 100644 --- a/samples/client/petstore/csharp/restsharp/net4.8/Petstore/src/Org.OpenAPITools/Client/ApiClient.cs +++ b/samples/client/petstore/csharp/restsharp/net4.8/Petstore/src/Org.OpenAPITools/Client/ApiClient.cs @@ -318,7 +318,7 @@ private RestRequest NewRequest( { foreach (var value in headerParam.Value) { - request.AddHeader(headerParam.Key, value); + request.AddOrUpdateHeader(headerParam.Key, value); } } } diff --git a/samples/client/petstore/csharp/restsharp/net6/ParameterMappings/src/Org.OpenAPITools/Client/ApiClient.cs b/samples/client/petstore/csharp/restsharp/net6/ParameterMappings/src/Org.OpenAPITools/Client/ApiClient.cs index 841ef8cadece..a5eb7b6e96dd 100644 --- a/samples/client/petstore/csharp/restsharp/net6/ParameterMappings/src/Org.OpenAPITools/Client/ApiClient.cs +++ b/samples/client/petstore/csharp/restsharp/net6/ParameterMappings/src/Org.OpenAPITools/Client/ApiClient.cs @@ -316,7 +316,7 @@ private RestRequest NewRequest( { foreach (var value in headerParam.Value) { - request.AddHeader(headerParam.Key, value); + request.AddOrUpdateHeader(headerParam.Key, value); } } } diff --git a/samples/client/petstore/csharp/restsharp/net7/EnumMappings/src/Org.OpenAPITools/Api/AnotherFakeApi.cs b/samples/client/petstore/csharp/restsharp/net7/EnumMappings/src/Org.OpenAPITools/Api/AnotherFakeApi.cs index 9ccd159a44f9..7026453735e3 100644 --- a/samples/client/petstore/csharp/restsharp/net7/EnumMappings/src/Org.OpenAPITools/Api/AnotherFakeApi.cs +++ b/samples/client/petstore/csharp/restsharp/net7/EnumMappings/src/Org.OpenAPITools/Api/AnotherFakeApi.cs @@ -255,7 +255,7 @@ public Org.OpenAPITools.Client.ApiResponse Call123TestSpecialTagsWi localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "AnotherFakeApi.Call123TestSpecialTags"; localVarRequestOptions.OperationIndex = operationIndex; @@ -329,7 +329,7 @@ public Org.OpenAPITools.Client.ApiResponse Call123TestSpecialTagsWi localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "AnotherFakeApi.Call123TestSpecialTags"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/net7/EnumMappings/src/Org.OpenAPITools/Api/FakeApi.cs b/samples/client/petstore/csharp/restsharp/net7/EnumMappings/src/Org.OpenAPITools/Api/FakeApi.cs index 8fc96497aa05..b1d251d758e0 100644 --- a/samples/client/petstore/csharp/restsharp/net7/EnumMappings/src/Org.OpenAPITools/Api/FakeApi.cs +++ b/samples/client/petstore/csharp/restsharp/net7/EnumMappings/src/Org.OpenAPITools/Api/FakeApi.cs @@ -1385,7 +1385,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterBooleanSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1453,7 +1453,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterBooleanSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1519,7 +1519,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = outerComposite; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(outerComposite); localVarRequestOptions.Operation = "FakeApi.FakeOuterCompositeSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1587,7 +1587,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = outerComposite; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(outerComposite); localVarRequestOptions.Operation = "FakeApi.FakeOuterCompositeSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1653,7 +1653,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterNumberSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1721,7 +1721,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterNumberSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1790,7 +1790,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH } localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("", "required_string_uuid", requiredStringUuid)); - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterStringSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1861,7 +1861,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH } localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("", "required_string_uuid", requiredStringUuid)); - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterStringSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2309,7 +2309,7 @@ public Org.OpenAPITools.Client.ApiResponse TestAdditionalPropertiesRefer localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestAdditionalPropertiesReference"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2381,7 +2381,7 @@ public Org.OpenAPITools.Client.ApiResponse TestAdditionalPropertiesRefer localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestAdditionalPropertiesReference"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2451,7 +2451,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyWithFileSchemaWithHtt localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = fileSchemaTestClass; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(fileSchemaTestClass); localVarRequestOptions.Operation = "FakeApi.TestBodyWithFileSchema"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2523,7 +2523,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyWithFileSchemaWithHtt localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = fileSchemaTestClass; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(fileSchemaTestClass); localVarRequestOptions.Operation = "FakeApi.TestBodyWithFileSchema"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2602,7 +2602,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyWithQueryParamsWithHt } localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("", "query", query)); - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "FakeApi.TestBodyWithQueryParams"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2683,7 +2683,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyWithQueryParamsWithHt } localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("", "query", query)); - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "FakeApi.TestBodyWithQueryParams"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2755,7 +2755,7 @@ public Org.OpenAPITools.Client.ApiResponse TestClientModelWithHttpI localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "FakeApi.TestClientModel"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2829,7 +2829,7 @@ public Org.OpenAPITools.Client.ApiResponse TestClientModelWithHttpI localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "FakeApi.TestClientModel"; localVarRequestOptions.OperationIndex = operationIndex; @@ -3611,7 +3611,7 @@ public Org.OpenAPITools.Client.ApiResponse TestInlineAdditionalPropertie localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestInlineAdditionalProperties"; localVarRequestOptions.OperationIndex = operationIndex; @@ -3683,7 +3683,7 @@ public Org.OpenAPITools.Client.ApiResponse TestInlineAdditionalPropertie localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestInlineAdditionalProperties"; localVarRequestOptions.OperationIndex = operationIndex; @@ -3753,7 +3753,7 @@ public Org.OpenAPITools.Client.ApiResponse TestInlineFreeformAdditionalP localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = testInlineFreeformAdditionalPropertiesRequest; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(testInlineFreeformAdditionalPropertiesRequest); localVarRequestOptions.Operation = "FakeApi.TestInlineFreeformAdditionalProperties"; localVarRequestOptions.OperationIndex = operationIndex; @@ -3825,7 +3825,7 @@ public Org.OpenAPITools.Client.ApiResponse TestInlineFreeformAdditionalP localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = testInlineFreeformAdditionalPropertiesRequest; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(testInlineFreeformAdditionalPropertiesRequest); localVarRequestOptions.Operation = "FakeApi.TestInlineFreeformAdditionalProperties"; localVarRequestOptions.OperationIndex = operationIndex; @@ -4327,7 +4327,7 @@ public Org.OpenAPITools.Client.ApiResponse TestStringMapReferenceWithHtt localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestStringMapReference"; localVarRequestOptions.OperationIndex = operationIndex; @@ -4399,7 +4399,7 @@ public Org.OpenAPITools.Client.ApiResponse TestStringMapReferenceWithHtt localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestStringMapReference"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/net7/EnumMappings/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs b/samples/client/petstore/csharp/restsharp/net7/EnumMappings/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs index b0e5066eef8f..1c6ac47fed5e 100644 --- a/samples/client/petstore/csharp/restsharp/net7/EnumMappings/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs +++ b/samples/client/petstore/csharp/restsharp/net7/EnumMappings/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs @@ -255,7 +255,7 @@ public Org.OpenAPITools.Client.ApiResponse TestClassnameWithHttpInf localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "FakeClassnameTags123Api.TestClassname"; localVarRequestOptions.OperationIndex = operationIndex; @@ -334,7 +334,7 @@ public Org.OpenAPITools.Client.ApiResponse TestClassnameWithHttpInf localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "FakeClassnameTags123Api.TestClassname"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/net7/EnumMappings/src/Org.OpenAPITools/Api/PetApi.cs b/samples/client/petstore/csharp/restsharp/net7/EnumMappings/src/Org.OpenAPITools/Api/PetApi.cs index 848cd61975b4..fd44779a2d90 100644 --- a/samples/client/petstore/csharp/restsharp/net7/EnumMappings/src/Org.OpenAPITools/Api/PetApi.cs +++ b/samples/client/petstore/csharp/restsharp/net7/EnumMappings/src/Org.OpenAPITools/Api/PetApi.cs @@ -652,7 +652,7 @@ public Org.OpenAPITools.Client.ApiResponse AddPetWithHttpInfo(Pet pet, i localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "PetApi.AddPet"; localVarRequestOptions.OperationIndex = operationIndex; @@ -757,7 +757,7 @@ public Org.OpenAPITools.Client.ApiResponse AddPetWithHttpInfo(Pet pet, i localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "PetApi.AddPet"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1610,7 +1610,7 @@ public Org.OpenAPITools.Client.ApiResponse UpdatePetWithHttpInfo(Pet pet localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "PetApi.UpdatePet"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1715,7 +1715,7 @@ public Org.OpenAPITools.Client.ApiResponse UpdatePetWithHttpInfo(Pet pet localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "PetApi.UpdatePet"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/net7/EnumMappings/src/Org.OpenAPITools/Api/StoreApi.cs b/samples/client/petstore/csharp/restsharp/net7/EnumMappings/src/Org.OpenAPITools/Api/StoreApi.cs index e8882b0fc2e4..616d3228e602 100644 --- a/samples/client/petstore/csharp/restsharp/net7/EnumMappings/src/Org.OpenAPITools/Api/StoreApi.cs +++ b/samples/client/petstore/csharp/restsharp/net7/EnumMappings/src/Org.OpenAPITools/Api/StoreApi.cs @@ -803,7 +803,7 @@ public Org.OpenAPITools.Client.ApiResponse PlaceOrderWithHttpInfo(Order o localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = order; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(order); localVarRequestOptions.Operation = "StoreApi.PlaceOrder"; localVarRequestOptions.OperationIndex = operationIndex; @@ -878,7 +878,7 @@ public Org.OpenAPITools.Client.ApiResponse PlaceOrderWithHttpInfo(Order o localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = order; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(order); localVarRequestOptions.Operation = "StoreApi.PlaceOrder"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/net7/EnumMappings/src/Org.OpenAPITools/Api/UserApi.cs b/samples/client/petstore/csharp/restsharp/net7/EnumMappings/src/Org.OpenAPITools/Api/UserApi.cs index 174d0572e677..dfdd55bed5ba 100644 --- a/samples/client/petstore/csharp/restsharp/net7/EnumMappings/src/Org.OpenAPITools/Api/UserApi.cs +++ b/samples/client/petstore/csharp/restsharp/net7/EnumMappings/src/Org.OpenAPITools/Api/UserApi.cs @@ -578,7 +578,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUserWithHttpInfo(User u localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUser"; localVarRequestOptions.OperationIndex = operationIndex; @@ -650,7 +650,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUserWithHttpInfo(User u localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUser"; localVarRequestOptions.OperationIndex = operationIndex; @@ -720,7 +720,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUsersWithArrayInputWith localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUsersWithArrayInput"; localVarRequestOptions.OperationIndex = operationIndex; @@ -792,7 +792,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUsersWithArrayInputWith localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUsersWithArrayInput"; localVarRequestOptions.OperationIndex = operationIndex; @@ -862,7 +862,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUsersWithListInputWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUsersWithListInput"; localVarRequestOptions.OperationIndex = operationIndex; @@ -934,7 +934,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUsersWithListInputWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUsersWithListInput"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1585,7 +1585,7 @@ public Org.OpenAPITools.Client.ApiResponse UpdateUserWithHttpInfo(string } localVarRequestOptions.PathParameters.Add("username", Org.OpenAPITools.Client.ClientUtils.ParameterToString(username)); // path parameter - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.UpdateUser"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1666,7 +1666,7 @@ public Org.OpenAPITools.Client.ApiResponse UpdateUserWithHttpInfo(string } localVarRequestOptions.PathParameters.Add("username", Org.OpenAPITools.Client.ClientUtils.ParameterToString(username)); // path parameter - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.UpdateUser"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/net7/EnumMappings/src/Org.OpenAPITools/Client/ApiClient.cs b/samples/client/petstore/csharp/restsharp/net7/EnumMappings/src/Org.OpenAPITools/Client/ApiClient.cs index 8431e531175d..e6b3b79f39fb 100644 --- a/samples/client/petstore/csharp/restsharp/net7/EnumMappings/src/Org.OpenAPITools/Client/ApiClient.cs +++ b/samples/client/petstore/csharp/restsharp/net7/EnumMappings/src/Org.OpenAPITools/Client/ApiClient.cs @@ -317,7 +317,7 @@ private RestRequest NewRequest( { foreach (var value in headerParam.Value) { - request.AddHeader(headerParam.Key, value); + request.AddOrUpdateHeader(headerParam.Key, value); } } } diff --git a/samples/client/petstore/csharp/restsharp/net7/Petstore/src/Org.OpenAPITools/Api/AnotherFakeApi.cs b/samples/client/petstore/csharp/restsharp/net7/Petstore/src/Org.OpenAPITools/Api/AnotherFakeApi.cs index 9ccd159a44f9..7026453735e3 100644 --- a/samples/client/petstore/csharp/restsharp/net7/Petstore/src/Org.OpenAPITools/Api/AnotherFakeApi.cs +++ b/samples/client/petstore/csharp/restsharp/net7/Petstore/src/Org.OpenAPITools/Api/AnotherFakeApi.cs @@ -255,7 +255,7 @@ public Org.OpenAPITools.Client.ApiResponse Call123TestSpecialTagsWi localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "AnotherFakeApi.Call123TestSpecialTags"; localVarRequestOptions.OperationIndex = operationIndex; @@ -329,7 +329,7 @@ public Org.OpenAPITools.Client.ApiResponse Call123TestSpecialTagsWi localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "AnotherFakeApi.Call123TestSpecialTags"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/net7/Petstore/src/Org.OpenAPITools/Api/FakeApi.cs b/samples/client/petstore/csharp/restsharp/net7/Petstore/src/Org.OpenAPITools/Api/FakeApi.cs index 8fc96497aa05..b1d251d758e0 100644 --- a/samples/client/petstore/csharp/restsharp/net7/Petstore/src/Org.OpenAPITools/Api/FakeApi.cs +++ b/samples/client/petstore/csharp/restsharp/net7/Petstore/src/Org.OpenAPITools/Api/FakeApi.cs @@ -1385,7 +1385,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterBooleanSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1453,7 +1453,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterBooleanSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1519,7 +1519,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = outerComposite; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(outerComposite); localVarRequestOptions.Operation = "FakeApi.FakeOuterCompositeSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1587,7 +1587,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = outerComposite; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(outerComposite); localVarRequestOptions.Operation = "FakeApi.FakeOuterCompositeSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1653,7 +1653,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterNumberSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1721,7 +1721,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterNumberSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1790,7 +1790,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH } localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("", "required_string_uuid", requiredStringUuid)); - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterStringSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1861,7 +1861,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH } localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("", "required_string_uuid", requiredStringUuid)); - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterStringSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2309,7 +2309,7 @@ public Org.OpenAPITools.Client.ApiResponse TestAdditionalPropertiesRefer localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestAdditionalPropertiesReference"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2381,7 +2381,7 @@ public Org.OpenAPITools.Client.ApiResponse TestAdditionalPropertiesRefer localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestAdditionalPropertiesReference"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2451,7 +2451,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyWithFileSchemaWithHtt localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = fileSchemaTestClass; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(fileSchemaTestClass); localVarRequestOptions.Operation = "FakeApi.TestBodyWithFileSchema"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2523,7 +2523,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyWithFileSchemaWithHtt localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = fileSchemaTestClass; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(fileSchemaTestClass); localVarRequestOptions.Operation = "FakeApi.TestBodyWithFileSchema"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2602,7 +2602,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyWithQueryParamsWithHt } localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("", "query", query)); - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "FakeApi.TestBodyWithQueryParams"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2683,7 +2683,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyWithQueryParamsWithHt } localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("", "query", query)); - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "FakeApi.TestBodyWithQueryParams"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2755,7 +2755,7 @@ public Org.OpenAPITools.Client.ApiResponse TestClientModelWithHttpI localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "FakeApi.TestClientModel"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2829,7 +2829,7 @@ public Org.OpenAPITools.Client.ApiResponse TestClientModelWithHttpI localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "FakeApi.TestClientModel"; localVarRequestOptions.OperationIndex = operationIndex; @@ -3611,7 +3611,7 @@ public Org.OpenAPITools.Client.ApiResponse TestInlineAdditionalPropertie localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestInlineAdditionalProperties"; localVarRequestOptions.OperationIndex = operationIndex; @@ -3683,7 +3683,7 @@ public Org.OpenAPITools.Client.ApiResponse TestInlineAdditionalPropertie localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestInlineAdditionalProperties"; localVarRequestOptions.OperationIndex = operationIndex; @@ -3753,7 +3753,7 @@ public Org.OpenAPITools.Client.ApiResponse TestInlineFreeformAdditionalP localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = testInlineFreeformAdditionalPropertiesRequest; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(testInlineFreeformAdditionalPropertiesRequest); localVarRequestOptions.Operation = "FakeApi.TestInlineFreeformAdditionalProperties"; localVarRequestOptions.OperationIndex = operationIndex; @@ -3825,7 +3825,7 @@ public Org.OpenAPITools.Client.ApiResponse TestInlineFreeformAdditionalP localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = testInlineFreeformAdditionalPropertiesRequest; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(testInlineFreeformAdditionalPropertiesRequest); localVarRequestOptions.Operation = "FakeApi.TestInlineFreeformAdditionalProperties"; localVarRequestOptions.OperationIndex = operationIndex; @@ -4327,7 +4327,7 @@ public Org.OpenAPITools.Client.ApiResponse TestStringMapReferenceWithHtt localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestStringMapReference"; localVarRequestOptions.OperationIndex = operationIndex; @@ -4399,7 +4399,7 @@ public Org.OpenAPITools.Client.ApiResponse TestStringMapReferenceWithHtt localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestStringMapReference"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/net7/Petstore/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs b/samples/client/petstore/csharp/restsharp/net7/Petstore/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs index b0e5066eef8f..1c6ac47fed5e 100644 --- a/samples/client/petstore/csharp/restsharp/net7/Petstore/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs +++ b/samples/client/petstore/csharp/restsharp/net7/Petstore/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs @@ -255,7 +255,7 @@ public Org.OpenAPITools.Client.ApiResponse TestClassnameWithHttpInf localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "FakeClassnameTags123Api.TestClassname"; localVarRequestOptions.OperationIndex = operationIndex; @@ -334,7 +334,7 @@ public Org.OpenAPITools.Client.ApiResponse TestClassnameWithHttpInf localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "FakeClassnameTags123Api.TestClassname"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/net7/Petstore/src/Org.OpenAPITools/Api/PetApi.cs b/samples/client/petstore/csharp/restsharp/net7/Petstore/src/Org.OpenAPITools/Api/PetApi.cs index 96d721326221..3dcb4ebec74d 100644 --- a/samples/client/petstore/csharp/restsharp/net7/Petstore/src/Org.OpenAPITools/Api/PetApi.cs +++ b/samples/client/petstore/csharp/restsharp/net7/Petstore/src/Org.OpenAPITools/Api/PetApi.cs @@ -652,7 +652,7 @@ public Org.OpenAPITools.Client.ApiResponse AddPetWithHttpInfo(Pet pet, i localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "PetApi.AddPet"; localVarRequestOptions.OperationIndex = operationIndex; @@ -757,7 +757,7 @@ public Org.OpenAPITools.Client.ApiResponse AddPetWithHttpInfo(Pet pet, i localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "PetApi.AddPet"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1610,7 +1610,7 @@ public Org.OpenAPITools.Client.ApiResponse UpdatePetWithHttpInfo(Pet pet localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "PetApi.UpdatePet"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1715,7 +1715,7 @@ public Org.OpenAPITools.Client.ApiResponse UpdatePetWithHttpInfo(Pet pet localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "PetApi.UpdatePet"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/net7/Petstore/src/Org.OpenAPITools/Api/StoreApi.cs b/samples/client/petstore/csharp/restsharp/net7/Petstore/src/Org.OpenAPITools/Api/StoreApi.cs index 57193a85d293..dcb8dfa281ad 100644 --- a/samples/client/petstore/csharp/restsharp/net7/Petstore/src/Org.OpenAPITools/Api/StoreApi.cs +++ b/samples/client/petstore/csharp/restsharp/net7/Petstore/src/Org.OpenAPITools/Api/StoreApi.cs @@ -803,7 +803,7 @@ public Org.OpenAPITools.Client.ApiResponse PlaceOrderWithHttpInfo(Order o localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = order; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(order); localVarRequestOptions.Operation = "StoreApi.PlaceOrder"; localVarRequestOptions.OperationIndex = operationIndex; @@ -878,7 +878,7 @@ public Org.OpenAPITools.Client.ApiResponse PlaceOrderWithHttpInfo(Order o localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = order; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(order); localVarRequestOptions.Operation = "StoreApi.PlaceOrder"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/net7/Petstore/src/Org.OpenAPITools/Api/UserApi.cs b/samples/client/petstore/csharp/restsharp/net7/Petstore/src/Org.OpenAPITools/Api/UserApi.cs index 174d0572e677..dfdd55bed5ba 100644 --- a/samples/client/petstore/csharp/restsharp/net7/Petstore/src/Org.OpenAPITools/Api/UserApi.cs +++ b/samples/client/petstore/csharp/restsharp/net7/Petstore/src/Org.OpenAPITools/Api/UserApi.cs @@ -578,7 +578,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUserWithHttpInfo(User u localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUser"; localVarRequestOptions.OperationIndex = operationIndex; @@ -650,7 +650,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUserWithHttpInfo(User u localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUser"; localVarRequestOptions.OperationIndex = operationIndex; @@ -720,7 +720,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUsersWithArrayInputWith localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUsersWithArrayInput"; localVarRequestOptions.OperationIndex = operationIndex; @@ -792,7 +792,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUsersWithArrayInputWith localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUsersWithArrayInput"; localVarRequestOptions.OperationIndex = operationIndex; @@ -862,7 +862,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUsersWithListInputWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUsersWithListInput"; localVarRequestOptions.OperationIndex = operationIndex; @@ -934,7 +934,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUsersWithListInputWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUsersWithListInput"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1585,7 +1585,7 @@ public Org.OpenAPITools.Client.ApiResponse UpdateUserWithHttpInfo(string } localVarRequestOptions.PathParameters.Add("username", Org.OpenAPITools.Client.ClientUtils.ParameterToString(username)); // path parameter - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.UpdateUser"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1666,7 +1666,7 @@ public Org.OpenAPITools.Client.ApiResponse UpdateUserWithHttpInfo(string } localVarRequestOptions.PathParameters.Add("username", Org.OpenAPITools.Client.ClientUtils.ParameterToString(username)); // path parameter - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.UpdateUser"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/net7/Petstore/src/Org.OpenAPITools/Client/ApiClient.cs b/samples/client/petstore/csharp/restsharp/net7/Petstore/src/Org.OpenAPITools/Client/ApiClient.cs index 8431e531175d..e6b3b79f39fb 100644 --- a/samples/client/petstore/csharp/restsharp/net7/Petstore/src/Org.OpenAPITools/Client/ApiClient.cs +++ b/samples/client/petstore/csharp/restsharp/net7/Petstore/src/Org.OpenAPITools/Client/ApiClient.cs @@ -317,7 +317,7 @@ private RestRequest NewRequest( { foreach (var value in headerParam.Value) { - request.AddHeader(headerParam.Key, value); + request.AddOrUpdateHeader(headerParam.Key, value); } } } diff --git a/samples/client/petstore/csharp/restsharp/net7/UseDateTimeForDate/src/Org.OpenAPITools/Client/ApiClient.cs b/samples/client/petstore/csharp/restsharp/net7/UseDateTimeForDate/src/Org.OpenAPITools/Client/ApiClient.cs index bc3f8ca8e981..ee05b787a8eb 100644 --- a/samples/client/petstore/csharp/restsharp/net7/UseDateTimeForDate/src/Org.OpenAPITools/Client/ApiClient.cs +++ b/samples/client/petstore/csharp/restsharp/net7/UseDateTimeForDate/src/Org.OpenAPITools/Client/ApiClient.cs @@ -316,7 +316,7 @@ private RestRequest NewRequest( { foreach (var value in headerParam.Value) { - request.AddHeader(headerParam.Key, value); + request.AddOrUpdateHeader(headerParam.Key, value); } } } diff --git a/samples/client/petstore/csharp/restsharp/standard2.0/ConditionalSerialization/src/Org.OpenAPITools/Api/AnotherFakeApi.cs b/samples/client/petstore/csharp/restsharp/standard2.0/ConditionalSerialization/src/Org.OpenAPITools/Api/AnotherFakeApi.cs index 9ccd159a44f9..7026453735e3 100644 --- a/samples/client/petstore/csharp/restsharp/standard2.0/ConditionalSerialization/src/Org.OpenAPITools/Api/AnotherFakeApi.cs +++ b/samples/client/petstore/csharp/restsharp/standard2.0/ConditionalSerialization/src/Org.OpenAPITools/Api/AnotherFakeApi.cs @@ -255,7 +255,7 @@ public Org.OpenAPITools.Client.ApiResponse Call123TestSpecialTagsWi localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "AnotherFakeApi.Call123TestSpecialTags"; localVarRequestOptions.OperationIndex = operationIndex; @@ -329,7 +329,7 @@ public Org.OpenAPITools.Client.ApiResponse Call123TestSpecialTagsWi localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "AnotherFakeApi.Call123TestSpecialTags"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/standard2.0/ConditionalSerialization/src/Org.OpenAPITools/Api/FakeApi.cs b/samples/client/petstore/csharp/restsharp/standard2.0/ConditionalSerialization/src/Org.OpenAPITools/Api/FakeApi.cs index a61c5d240e23..635af7389f4d 100644 --- a/samples/client/petstore/csharp/restsharp/standard2.0/ConditionalSerialization/src/Org.OpenAPITools/Api/FakeApi.cs +++ b/samples/client/petstore/csharp/restsharp/standard2.0/ConditionalSerialization/src/Org.OpenAPITools/Api/FakeApi.cs @@ -1385,7 +1385,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterBooleanSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1453,7 +1453,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterBooleanSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1519,7 +1519,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = outerComposite; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(outerComposite); localVarRequestOptions.Operation = "FakeApi.FakeOuterCompositeSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1587,7 +1587,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = outerComposite; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(outerComposite); localVarRequestOptions.Operation = "FakeApi.FakeOuterCompositeSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1653,7 +1653,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterNumberSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1721,7 +1721,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterNumberSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1790,7 +1790,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH } localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("", "required_string_uuid", requiredStringUuid)); - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterStringSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1861,7 +1861,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH } localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("", "required_string_uuid", requiredStringUuid)); - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterStringSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2309,7 +2309,7 @@ public Org.OpenAPITools.Client.ApiResponse TestAdditionalPropertiesRefer localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestAdditionalPropertiesReference"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2381,7 +2381,7 @@ public Org.OpenAPITools.Client.ApiResponse TestAdditionalPropertiesRefer localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestAdditionalPropertiesReference"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2451,7 +2451,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyWithFileSchemaWithHtt localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = fileSchemaTestClass; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(fileSchemaTestClass); localVarRequestOptions.Operation = "FakeApi.TestBodyWithFileSchema"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2523,7 +2523,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyWithFileSchemaWithHtt localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = fileSchemaTestClass; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(fileSchemaTestClass); localVarRequestOptions.Operation = "FakeApi.TestBodyWithFileSchema"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2602,7 +2602,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyWithQueryParamsWithHt } localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("", "query", query)); - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "FakeApi.TestBodyWithQueryParams"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2683,7 +2683,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyWithQueryParamsWithHt } localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("", "query", query)); - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "FakeApi.TestBodyWithQueryParams"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2755,7 +2755,7 @@ public Org.OpenAPITools.Client.ApiResponse TestClientModelWithHttpI localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "FakeApi.TestClientModel"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2829,7 +2829,7 @@ public Org.OpenAPITools.Client.ApiResponse TestClientModelWithHttpI localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "FakeApi.TestClientModel"; localVarRequestOptions.OperationIndex = operationIndex; @@ -3611,7 +3611,7 @@ public Org.OpenAPITools.Client.ApiResponse TestInlineAdditionalPropertie localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestInlineAdditionalProperties"; localVarRequestOptions.OperationIndex = operationIndex; @@ -3683,7 +3683,7 @@ public Org.OpenAPITools.Client.ApiResponse TestInlineAdditionalPropertie localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestInlineAdditionalProperties"; localVarRequestOptions.OperationIndex = operationIndex; @@ -3753,7 +3753,7 @@ public Org.OpenAPITools.Client.ApiResponse TestInlineFreeformAdditionalP localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = testInlineFreeformAdditionalPropertiesRequest; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(testInlineFreeformAdditionalPropertiesRequest); localVarRequestOptions.Operation = "FakeApi.TestInlineFreeformAdditionalProperties"; localVarRequestOptions.OperationIndex = operationIndex; @@ -3825,7 +3825,7 @@ public Org.OpenAPITools.Client.ApiResponse TestInlineFreeformAdditionalP localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = testInlineFreeformAdditionalPropertiesRequest; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(testInlineFreeformAdditionalPropertiesRequest); localVarRequestOptions.Operation = "FakeApi.TestInlineFreeformAdditionalProperties"; localVarRequestOptions.OperationIndex = operationIndex; @@ -4327,7 +4327,7 @@ public Org.OpenAPITools.Client.ApiResponse TestStringMapReferenceWithHtt localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestStringMapReference"; localVarRequestOptions.OperationIndex = operationIndex; @@ -4399,7 +4399,7 @@ public Org.OpenAPITools.Client.ApiResponse TestStringMapReferenceWithHtt localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestStringMapReference"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/standard2.0/ConditionalSerialization/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs b/samples/client/petstore/csharp/restsharp/standard2.0/ConditionalSerialization/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs index b0e5066eef8f..1c6ac47fed5e 100644 --- a/samples/client/petstore/csharp/restsharp/standard2.0/ConditionalSerialization/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs +++ b/samples/client/petstore/csharp/restsharp/standard2.0/ConditionalSerialization/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs @@ -255,7 +255,7 @@ public Org.OpenAPITools.Client.ApiResponse TestClassnameWithHttpInf localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "FakeClassnameTags123Api.TestClassname"; localVarRequestOptions.OperationIndex = operationIndex; @@ -334,7 +334,7 @@ public Org.OpenAPITools.Client.ApiResponse TestClassnameWithHttpInf localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "FakeClassnameTags123Api.TestClassname"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/standard2.0/ConditionalSerialization/src/Org.OpenAPITools/Api/PetApi.cs b/samples/client/petstore/csharp/restsharp/standard2.0/ConditionalSerialization/src/Org.OpenAPITools/Api/PetApi.cs index 086ecc412983..1a9174c8b731 100644 --- a/samples/client/petstore/csharp/restsharp/standard2.0/ConditionalSerialization/src/Org.OpenAPITools/Api/PetApi.cs +++ b/samples/client/petstore/csharp/restsharp/standard2.0/ConditionalSerialization/src/Org.OpenAPITools/Api/PetApi.cs @@ -652,7 +652,7 @@ public Org.OpenAPITools.Client.ApiResponse AddPetWithHttpInfo(Pet pet, i localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "PetApi.AddPet"; localVarRequestOptions.OperationIndex = operationIndex; @@ -757,7 +757,7 @@ public Org.OpenAPITools.Client.ApiResponse AddPetWithHttpInfo(Pet pet, i localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "PetApi.AddPet"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1610,7 +1610,7 @@ public Org.OpenAPITools.Client.ApiResponse UpdatePetWithHttpInfo(Pet pet localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "PetApi.UpdatePet"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1715,7 +1715,7 @@ public Org.OpenAPITools.Client.ApiResponse UpdatePetWithHttpInfo(Pet pet localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "PetApi.UpdatePet"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/standard2.0/ConditionalSerialization/src/Org.OpenAPITools/Api/StoreApi.cs b/samples/client/petstore/csharp/restsharp/standard2.0/ConditionalSerialization/src/Org.OpenAPITools/Api/StoreApi.cs index 57193a85d293..dcb8dfa281ad 100644 --- a/samples/client/petstore/csharp/restsharp/standard2.0/ConditionalSerialization/src/Org.OpenAPITools/Api/StoreApi.cs +++ b/samples/client/petstore/csharp/restsharp/standard2.0/ConditionalSerialization/src/Org.OpenAPITools/Api/StoreApi.cs @@ -803,7 +803,7 @@ public Org.OpenAPITools.Client.ApiResponse PlaceOrderWithHttpInfo(Order o localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = order; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(order); localVarRequestOptions.Operation = "StoreApi.PlaceOrder"; localVarRequestOptions.OperationIndex = operationIndex; @@ -878,7 +878,7 @@ public Org.OpenAPITools.Client.ApiResponse PlaceOrderWithHttpInfo(Order o localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = order; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(order); localVarRequestOptions.Operation = "StoreApi.PlaceOrder"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/standard2.0/ConditionalSerialization/src/Org.OpenAPITools/Api/UserApi.cs b/samples/client/petstore/csharp/restsharp/standard2.0/ConditionalSerialization/src/Org.OpenAPITools/Api/UserApi.cs index 174d0572e677..dfdd55bed5ba 100644 --- a/samples/client/petstore/csharp/restsharp/standard2.0/ConditionalSerialization/src/Org.OpenAPITools/Api/UserApi.cs +++ b/samples/client/petstore/csharp/restsharp/standard2.0/ConditionalSerialization/src/Org.OpenAPITools/Api/UserApi.cs @@ -578,7 +578,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUserWithHttpInfo(User u localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUser"; localVarRequestOptions.OperationIndex = operationIndex; @@ -650,7 +650,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUserWithHttpInfo(User u localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUser"; localVarRequestOptions.OperationIndex = operationIndex; @@ -720,7 +720,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUsersWithArrayInputWith localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUsersWithArrayInput"; localVarRequestOptions.OperationIndex = operationIndex; @@ -792,7 +792,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUsersWithArrayInputWith localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUsersWithArrayInput"; localVarRequestOptions.OperationIndex = operationIndex; @@ -862,7 +862,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUsersWithListInputWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUsersWithListInput"; localVarRequestOptions.OperationIndex = operationIndex; @@ -934,7 +934,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUsersWithListInputWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUsersWithListInput"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1585,7 +1585,7 @@ public Org.OpenAPITools.Client.ApiResponse UpdateUserWithHttpInfo(string } localVarRequestOptions.PathParameters.Add("username", Org.OpenAPITools.Client.ClientUtils.ParameterToString(username)); // path parameter - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.UpdateUser"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1666,7 +1666,7 @@ public Org.OpenAPITools.Client.ApiResponse UpdateUserWithHttpInfo(string } localVarRequestOptions.PathParameters.Add("username", Org.OpenAPITools.Client.ClientUtils.ParameterToString(username)); // path parameter - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.UpdateUser"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/standard2.0/ConditionalSerialization/src/Org.OpenAPITools/Client/ApiClient.cs b/samples/client/petstore/csharp/restsharp/standard2.0/ConditionalSerialization/src/Org.OpenAPITools/Client/ApiClient.cs index a0a43ea74aeb..39facdbcf94f 100644 --- a/samples/client/petstore/csharp/restsharp/standard2.0/ConditionalSerialization/src/Org.OpenAPITools/Client/ApiClient.cs +++ b/samples/client/petstore/csharp/restsharp/standard2.0/ConditionalSerialization/src/Org.OpenAPITools/Client/ApiClient.cs @@ -318,7 +318,7 @@ private RestRequest NewRequest( { foreach (var value in headerParam.Value) { - request.AddHeader(headerParam.Key, value); + request.AddOrUpdateHeader(headerParam.Key, value); } } } diff --git a/samples/client/petstore/csharp/restsharp/standard2.0/Petstore/src/Org.OpenAPITools/Api/AnotherFakeApi.cs b/samples/client/petstore/csharp/restsharp/standard2.0/Petstore/src/Org.OpenAPITools/Api/AnotherFakeApi.cs index 9ccd159a44f9..7026453735e3 100644 --- a/samples/client/petstore/csharp/restsharp/standard2.0/Petstore/src/Org.OpenAPITools/Api/AnotherFakeApi.cs +++ b/samples/client/petstore/csharp/restsharp/standard2.0/Petstore/src/Org.OpenAPITools/Api/AnotherFakeApi.cs @@ -255,7 +255,7 @@ public Org.OpenAPITools.Client.ApiResponse Call123TestSpecialTagsWi localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "AnotherFakeApi.Call123TestSpecialTags"; localVarRequestOptions.OperationIndex = operationIndex; @@ -329,7 +329,7 @@ public Org.OpenAPITools.Client.ApiResponse Call123TestSpecialTagsWi localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "AnotherFakeApi.Call123TestSpecialTags"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/standard2.0/Petstore/src/Org.OpenAPITools/Api/FakeApi.cs b/samples/client/petstore/csharp/restsharp/standard2.0/Petstore/src/Org.OpenAPITools/Api/FakeApi.cs index a61c5d240e23..635af7389f4d 100644 --- a/samples/client/petstore/csharp/restsharp/standard2.0/Petstore/src/Org.OpenAPITools/Api/FakeApi.cs +++ b/samples/client/petstore/csharp/restsharp/standard2.0/Petstore/src/Org.OpenAPITools/Api/FakeApi.cs @@ -1385,7 +1385,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterBooleanSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1453,7 +1453,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterBooleanSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1519,7 +1519,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = outerComposite; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(outerComposite); localVarRequestOptions.Operation = "FakeApi.FakeOuterCompositeSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1587,7 +1587,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = outerComposite; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(outerComposite); localVarRequestOptions.Operation = "FakeApi.FakeOuterCompositeSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1653,7 +1653,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterNumberSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1721,7 +1721,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterNumberSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1790,7 +1790,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH } localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("", "required_string_uuid", requiredStringUuid)); - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterStringSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1861,7 +1861,7 @@ public Org.OpenAPITools.Client.ApiResponse FakeHealthGetWithH } localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("", "required_string_uuid", requiredStringUuid)); - localVarRequestOptions.Data = body; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(body); localVarRequestOptions.Operation = "FakeApi.FakeOuterStringSerialize"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2309,7 +2309,7 @@ public Org.OpenAPITools.Client.ApiResponse TestAdditionalPropertiesRefer localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestAdditionalPropertiesReference"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2381,7 +2381,7 @@ public Org.OpenAPITools.Client.ApiResponse TestAdditionalPropertiesRefer localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestAdditionalPropertiesReference"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2451,7 +2451,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyWithFileSchemaWithHtt localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = fileSchemaTestClass; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(fileSchemaTestClass); localVarRequestOptions.Operation = "FakeApi.TestBodyWithFileSchema"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2523,7 +2523,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyWithFileSchemaWithHtt localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = fileSchemaTestClass; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(fileSchemaTestClass); localVarRequestOptions.Operation = "FakeApi.TestBodyWithFileSchema"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2602,7 +2602,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyWithQueryParamsWithHt } localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("", "query", query)); - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "FakeApi.TestBodyWithQueryParams"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2683,7 +2683,7 @@ public Org.OpenAPITools.Client.ApiResponse TestBodyWithQueryParamsWithHt } localVarRequestOptions.QueryParameters.Add(Org.OpenAPITools.Client.ClientUtils.ParameterToMultiMap("", "query", query)); - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "FakeApi.TestBodyWithQueryParams"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2755,7 +2755,7 @@ public Org.OpenAPITools.Client.ApiResponse TestClientModelWithHttpI localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "FakeApi.TestClientModel"; localVarRequestOptions.OperationIndex = operationIndex; @@ -2829,7 +2829,7 @@ public Org.OpenAPITools.Client.ApiResponse TestClientModelWithHttpI localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "FakeApi.TestClientModel"; localVarRequestOptions.OperationIndex = operationIndex; @@ -3611,7 +3611,7 @@ public Org.OpenAPITools.Client.ApiResponse TestInlineAdditionalPropertie localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestInlineAdditionalProperties"; localVarRequestOptions.OperationIndex = operationIndex; @@ -3683,7 +3683,7 @@ public Org.OpenAPITools.Client.ApiResponse TestInlineAdditionalPropertie localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestInlineAdditionalProperties"; localVarRequestOptions.OperationIndex = operationIndex; @@ -3753,7 +3753,7 @@ public Org.OpenAPITools.Client.ApiResponse TestInlineFreeformAdditionalP localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = testInlineFreeformAdditionalPropertiesRequest; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(testInlineFreeformAdditionalPropertiesRequest); localVarRequestOptions.Operation = "FakeApi.TestInlineFreeformAdditionalProperties"; localVarRequestOptions.OperationIndex = operationIndex; @@ -3825,7 +3825,7 @@ public Org.OpenAPITools.Client.ApiResponse TestInlineFreeformAdditionalP localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = testInlineFreeformAdditionalPropertiesRequest; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(testInlineFreeformAdditionalPropertiesRequest); localVarRequestOptions.Operation = "FakeApi.TestInlineFreeformAdditionalProperties"; localVarRequestOptions.OperationIndex = operationIndex; @@ -4327,7 +4327,7 @@ public Org.OpenAPITools.Client.ApiResponse TestStringMapReferenceWithHtt localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestStringMapReference"; localVarRequestOptions.OperationIndex = operationIndex; @@ -4399,7 +4399,7 @@ public Org.OpenAPITools.Client.ApiResponse TestStringMapReferenceWithHtt localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = requestBody; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(requestBody); localVarRequestOptions.Operation = "FakeApi.TestStringMapReference"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/standard2.0/Petstore/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs b/samples/client/petstore/csharp/restsharp/standard2.0/Petstore/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs index b0e5066eef8f..1c6ac47fed5e 100644 --- a/samples/client/petstore/csharp/restsharp/standard2.0/Petstore/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs +++ b/samples/client/petstore/csharp/restsharp/standard2.0/Petstore/src/Org.OpenAPITools/Api/FakeClassnameTags123Api.cs @@ -255,7 +255,7 @@ public Org.OpenAPITools.Client.ApiResponse TestClassnameWithHttpInf localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "FakeClassnameTags123Api.TestClassname"; localVarRequestOptions.OperationIndex = operationIndex; @@ -334,7 +334,7 @@ public Org.OpenAPITools.Client.ApiResponse TestClassnameWithHttpInf localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = modelClient; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(modelClient); localVarRequestOptions.Operation = "FakeClassnameTags123Api.TestClassname"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/standard2.0/Petstore/src/Org.OpenAPITools/Api/PetApi.cs b/samples/client/petstore/csharp/restsharp/standard2.0/Petstore/src/Org.OpenAPITools/Api/PetApi.cs index 8db5fd36849d..678d0c001cbd 100644 --- a/samples/client/petstore/csharp/restsharp/standard2.0/Petstore/src/Org.OpenAPITools/Api/PetApi.cs +++ b/samples/client/petstore/csharp/restsharp/standard2.0/Petstore/src/Org.OpenAPITools/Api/PetApi.cs @@ -652,7 +652,7 @@ public Org.OpenAPITools.Client.ApiResponse AddPetWithHttpInfo(Pet pet, i localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "PetApi.AddPet"; localVarRequestOptions.OperationIndex = operationIndex; @@ -757,7 +757,7 @@ public Org.OpenAPITools.Client.ApiResponse AddPetWithHttpInfo(Pet pet, i localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "PetApi.AddPet"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1610,7 +1610,7 @@ public Org.OpenAPITools.Client.ApiResponse UpdatePetWithHttpInfo(Pet pet localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "PetApi.UpdatePet"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1715,7 +1715,7 @@ public Org.OpenAPITools.Client.ApiResponse UpdatePetWithHttpInfo(Pet pet localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = pet; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(pet); localVarRequestOptions.Operation = "PetApi.UpdatePet"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/standard2.0/Petstore/src/Org.OpenAPITools/Api/StoreApi.cs b/samples/client/petstore/csharp/restsharp/standard2.0/Petstore/src/Org.OpenAPITools/Api/StoreApi.cs index e8882b0fc2e4..616d3228e602 100644 --- a/samples/client/petstore/csharp/restsharp/standard2.0/Petstore/src/Org.OpenAPITools/Api/StoreApi.cs +++ b/samples/client/petstore/csharp/restsharp/standard2.0/Petstore/src/Org.OpenAPITools/Api/StoreApi.cs @@ -803,7 +803,7 @@ public Org.OpenAPITools.Client.ApiResponse PlaceOrderWithHttpInfo(Order o localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = order; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(order); localVarRequestOptions.Operation = "StoreApi.PlaceOrder"; localVarRequestOptions.OperationIndex = operationIndex; @@ -878,7 +878,7 @@ public Org.OpenAPITools.Client.ApiResponse PlaceOrderWithHttpInfo(Order o localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = order; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(order); localVarRequestOptions.Operation = "StoreApi.PlaceOrder"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/standard2.0/Petstore/src/Org.OpenAPITools/Api/UserApi.cs b/samples/client/petstore/csharp/restsharp/standard2.0/Petstore/src/Org.OpenAPITools/Api/UserApi.cs index 174d0572e677..dfdd55bed5ba 100644 --- a/samples/client/petstore/csharp/restsharp/standard2.0/Petstore/src/Org.OpenAPITools/Api/UserApi.cs +++ b/samples/client/petstore/csharp/restsharp/standard2.0/Petstore/src/Org.OpenAPITools/Api/UserApi.cs @@ -578,7 +578,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUserWithHttpInfo(User u localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUser"; localVarRequestOptions.OperationIndex = operationIndex; @@ -650,7 +650,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUserWithHttpInfo(User u localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUser"; localVarRequestOptions.OperationIndex = operationIndex; @@ -720,7 +720,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUsersWithArrayInputWith localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUsersWithArrayInput"; localVarRequestOptions.OperationIndex = operationIndex; @@ -792,7 +792,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUsersWithArrayInputWith localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUsersWithArrayInput"; localVarRequestOptions.OperationIndex = operationIndex; @@ -862,7 +862,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUsersWithListInputWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUsersWithListInput"; localVarRequestOptions.OperationIndex = operationIndex; @@ -934,7 +934,7 @@ public Org.OpenAPITools.Client.ApiResponse CreateUsersWithListInputWithH localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); } - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.CreateUsersWithListInput"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1585,7 +1585,7 @@ public Org.OpenAPITools.Client.ApiResponse UpdateUserWithHttpInfo(string } localVarRequestOptions.PathParameters.Add("username", Org.OpenAPITools.Client.ClientUtils.ParameterToString(username)); // path parameter - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.UpdateUser"; localVarRequestOptions.OperationIndex = operationIndex; @@ -1666,7 +1666,7 @@ public Org.OpenAPITools.Client.ApiResponse UpdateUserWithHttpInfo(string } localVarRequestOptions.PathParameters.Add("username", Org.OpenAPITools.Client.ClientUtils.ParameterToString(username)); // path parameter - localVarRequestOptions.Data = user; + localVarRequestOptions.Data = Org.OpenAPITools.Client.ClientUtils.Serialize(user); localVarRequestOptions.Operation = "UserApi.UpdateUser"; localVarRequestOptions.OperationIndex = operationIndex; diff --git a/samples/client/petstore/csharp/restsharp/standard2.0/Petstore/src/Org.OpenAPITools/Client/ApiClient.cs b/samples/client/petstore/csharp/restsharp/standard2.0/Petstore/src/Org.OpenAPITools/Client/ApiClient.cs index a0a43ea74aeb..39facdbcf94f 100644 --- a/samples/client/petstore/csharp/restsharp/standard2.0/Petstore/src/Org.OpenAPITools/Client/ApiClient.cs +++ b/samples/client/petstore/csharp/restsharp/standard2.0/Petstore/src/Org.OpenAPITools/Client/ApiClient.cs @@ -318,7 +318,7 @@ private RestRequest NewRequest( { foreach (var value in headerParam.Value) { - request.AddHeader(headerParam.Key, value); + request.AddOrUpdateHeader(headerParam.Key, value); } } } diff --git a/samples/client/petstore/php-nextgen/OpenAPIClient-php/phpunit.xml.dist b/samples/client/petstore/php-nextgen/OpenAPIClient-php/phpunit.xml.dist index 1135449a8d9b..cba878f52707 100644 --- a/samples/client/petstore/php-nextgen/OpenAPIClient-php/phpunit.xml.dist +++ b/samples/client/petstore/php-nextgen/OpenAPIClient-php/phpunit.xml.dist @@ -2,8 +2,8 @@ - ./src/Api - ./src/Model + ./src\/Api + ./src\/Model diff --git a/samples/server/petstore/aspnetcore-3.0/src/Org.OpenAPITools/Controllers/FakeApi.cs b/samples/server/petstore/aspnetcore-3.0/src/Org.OpenAPITools/Controllers/FakeApi.cs index a0f2bd3b2315..eccd3a3006a6 100644 --- a/samples/server/petstore/aspnetcore-3.0/src/Org.OpenAPITools/Controllers/FakeApi.cs +++ b/samples/server/petstore/aspnetcore-3.0/src/Org.OpenAPITools/Controllers/FakeApi.cs @@ -43,7 +43,7 @@ public virtual IActionResult FakeNullableExampleTest() //TODO: Uncomment the next line to return response 200 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(200, default(TestNullable)); string exampleJson = null; - exampleJson = "{\n \"nullableName\" : \"nullableName\",\n \"name\" : \"name\"\n}"; + exampleJson = "{\r\n \"nullableName\" : \"nullableName\",\r\n \"name\" : \"name\"\r\n}"; var example = exampleJson != null ? JsonConvert.DeserializeObject(exampleJson) diff --git a/samples/server/petstore/aspnetcore-3.0/src/Org.OpenAPITools/Controllers/PetApi.cs b/samples/server/petstore/aspnetcore-3.0/src/Org.OpenAPITools/Controllers/PetApi.cs index 7dded4e0f16a..5a197da3156e 100644 --- a/samples/server/petstore/aspnetcore-3.0/src/Org.OpenAPITools/Controllers/PetApi.cs +++ b/samples/server/petstore/aspnetcore-3.0/src/Org.OpenAPITools/Controllers/PetApi.cs @@ -48,7 +48,7 @@ public virtual IActionResult AddPet([FromBody]Pet pet) //TODO: Uncomment the next line to return response 405 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(405); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -97,7 +97,7 @@ public virtual IActionResult FindPetsByStatus([FromQuery (Name = "status")][Requ //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "[ {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}, {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n} ]"; + exampleJson = "[ {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}, {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n} ]"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -128,7 +128,7 @@ public virtual IActionResult FindPetsByTags([FromQuery (Name = "tags")][Required //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "[ {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}, {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n} ]"; + exampleJson = "[ {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}, {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n} ]"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -162,7 +162,7 @@ public virtual IActionResult GetPetById([FromRoute (Name = "petId")][Required]lo //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -198,7 +198,7 @@ public virtual IActionResult UpdatePet([FromBody]Pet pet) //TODO: Uncomment the next line to return response 405 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(405); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n doggie\n \n aeiou\n \n \n \n aeiou\n"; var example = exampleJson != null @@ -248,7 +248,7 @@ public virtual IActionResult UploadFile([FromRoute (Name = "petId")][Required]lo //TODO: Uncomment the next line to return response 200 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(200, default(ApiResponse)); string exampleJson = null; - exampleJson = "{\n \"code\" : 0,\n \"type\" : \"type\",\n \"message\" : \"message\"\n}"; + exampleJson = "{\r\n \"code\" : 0,\r\n \"type\" : \"type\",\r\n \"message\" : \"message\"\r\n}"; var example = exampleJson != null ? JsonConvert.DeserializeObject(exampleJson) diff --git a/samples/server/petstore/aspnetcore-3.0/src/Org.OpenAPITools/Controllers/StoreApi.cs b/samples/server/petstore/aspnetcore-3.0/src/Org.OpenAPITools/Controllers/StoreApi.cs index b925426c761d..c57b5fb3bd16 100644 --- a/samples/server/petstore/aspnetcore-3.0/src/Org.OpenAPITools/Controllers/StoreApi.cs +++ b/samples/server/petstore/aspnetcore-3.0/src/Org.OpenAPITools/Controllers/StoreApi.cs @@ -98,7 +98,7 @@ public virtual IActionResult GetOrderById([FromRoute (Name = "orderId")][Require //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"petId\" : 6,\n \"quantity\" : 1,\n \"id\" : 0,\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\n \"complete\" : false,\n \"status\" : \"placed\"\n}"; + exampleJson = "{\r\n \"petId\" : 6,\r\n \"quantity\" : 1,\r\n \"id\" : 0,\r\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\r\n \"complete\" : false,\r\n \"status\" : \"placed\"\r\n}"; exampleJson = "\n 123456789\n 123456789\n 123\n 2000-01-23T04:56:07.000Z\n aeiou\n true\n"; var example = exampleJson != null @@ -128,7 +128,7 @@ public virtual IActionResult PlaceOrder([FromBody]Order order) //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "{\n \"petId\" : 6,\n \"quantity\" : 1,\n \"id\" : 0,\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\n \"complete\" : false,\n \"status\" : \"placed\"\n}"; + exampleJson = "{\r\n \"petId\" : 6,\r\n \"quantity\" : 1,\r\n \"id\" : 0,\r\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\r\n \"complete\" : false,\r\n \"status\" : \"placed\"\r\n}"; exampleJson = "\n 123456789\n 123456789\n 123\n 2000-01-23T04:56:07.000Z\n aeiou\n true\n"; var example = exampleJson != null diff --git a/samples/server/petstore/aspnetcore-3.0/src/Org.OpenAPITools/Controllers/UserApi.cs b/samples/server/petstore/aspnetcore-3.0/src/Org.OpenAPITools/Controllers/UserApi.cs index 6d7094c81a9d..3277ae43fcfd 100644 --- a/samples/server/petstore/aspnetcore-3.0/src/Org.OpenAPITools/Controllers/UserApi.cs +++ b/samples/server/petstore/aspnetcore-3.0/src/Org.OpenAPITools/Controllers/UserApi.cs @@ -134,7 +134,7 @@ public virtual IActionResult GetUserByName([FromRoute (Name = "username")][Requi //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"firstName\" : \"firstName\",\n \"lastName\" : \"lastName\",\n \"password\" : \"password\",\n \"userStatus\" : 6,\n \"phone\" : \"phone\",\n \"id\" : 0,\n \"email\" : \"email\",\n \"username\" : \"username\"\n}"; + exampleJson = "{\r\n \"firstName\" : \"firstName\",\r\n \"lastName\" : \"lastName\",\r\n \"password\" : \"password\",\r\n \"userStatus\" : 6,\r\n \"phone\" : \"phone\",\r\n \"id\" : 0,\r\n \"email\" : \"email\",\r\n \"username\" : \"username\"\r\n}"; exampleJson = "\n 123456789\n aeiou\n aeiou\n aeiou\n aeiou\n aeiou\n aeiou\n 123\n"; var example = exampleJson != null diff --git a/samples/server/petstore/aspnetcore-3.1/src/Org.OpenAPITools/Controllers/FakeApi.cs b/samples/server/petstore/aspnetcore-3.1/src/Org.OpenAPITools/Controllers/FakeApi.cs index a0f2bd3b2315..eccd3a3006a6 100644 --- a/samples/server/petstore/aspnetcore-3.1/src/Org.OpenAPITools/Controllers/FakeApi.cs +++ b/samples/server/petstore/aspnetcore-3.1/src/Org.OpenAPITools/Controllers/FakeApi.cs @@ -43,7 +43,7 @@ public virtual IActionResult FakeNullableExampleTest() //TODO: Uncomment the next line to return response 200 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(200, default(TestNullable)); string exampleJson = null; - exampleJson = "{\n \"nullableName\" : \"nullableName\",\n \"name\" : \"name\"\n}"; + exampleJson = "{\r\n \"nullableName\" : \"nullableName\",\r\n \"name\" : \"name\"\r\n}"; var example = exampleJson != null ? JsonConvert.DeserializeObject(exampleJson) diff --git a/samples/server/petstore/aspnetcore-3.1/src/Org.OpenAPITools/Controllers/PetApi.cs b/samples/server/petstore/aspnetcore-3.1/src/Org.OpenAPITools/Controllers/PetApi.cs index 7dded4e0f16a..5a197da3156e 100644 --- a/samples/server/petstore/aspnetcore-3.1/src/Org.OpenAPITools/Controllers/PetApi.cs +++ b/samples/server/petstore/aspnetcore-3.1/src/Org.OpenAPITools/Controllers/PetApi.cs @@ -48,7 +48,7 @@ public virtual IActionResult AddPet([FromBody]Pet pet) //TODO: Uncomment the next line to return response 405 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(405); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -97,7 +97,7 @@ public virtual IActionResult FindPetsByStatus([FromQuery (Name = "status")][Requ //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "[ {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}, {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n} ]"; + exampleJson = "[ {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}, {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n} ]"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -128,7 +128,7 @@ public virtual IActionResult FindPetsByTags([FromQuery (Name = "tags")][Required //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "[ {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}, {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n} ]"; + exampleJson = "[ {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}, {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n} ]"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -162,7 +162,7 @@ public virtual IActionResult GetPetById([FromRoute (Name = "petId")][Required]lo //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -198,7 +198,7 @@ public virtual IActionResult UpdatePet([FromBody]Pet pet) //TODO: Uncomment the next line to return response 405 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(405); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n doggie\n \n aeiou\n \n \n \n aeiou\n"; var example = exampleJson != null @@ -248,7 +248,7 @@ public virtual IActionResult UploadFile([FromRoute (Name = "petId")][Required]lo //TODO: Uncomment the next line to return response 200 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(200, default(ApiResponse)); string exampleJson = null; - exampleJson = "{\n \"code\" : 0,\n \"type\" : \"type\",\n \"message\" : \"message\"\n}"; + exampleJson = "{\r\n \"code\" : 0,\r\n \"type\" : \"type\",\r\n \"message\" : \"message\"\r\n}"; var example = exampleJson != null ? JsonConvert.DeserializeObject(exampleJson) diff --git a/samples/server/petstore/aspnetcore-3.1/src/Org.OpenAPITools/Controllers/StoreApi.cs b/samples/server/petstore/aspnetcore-3.1/src/Org.OpenAPITools/Controllers/StoreApi.cs index b925426c761d..c57b5fb3bd16 100644 --- a/samples/server/petstore/aspnetcore-3.1/src/Org.OpenAPITools/Controllers/StoreApi.cs +++ b/samples/server/petstore/aspnetcore-3.1/src/Org.OpenAPITools/Controllers/StoreApi.cs @@ -98,7 +98,7 @@ public virtual IActionResult GetOrderById([FromRoute (Name = "orderId")][Require //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"petId\" : 6,\n \"quantity\" : 1,\n \"id\" : 0,\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\n \"complete\" : false,\n \"status\" : \"placed\"\n}"; + exampleJson = "{\r\n \"petId\" : 6,\r\n \"quantity\" : 1,\r\n \"id\" : 0,\r\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\r\n \"complete\" : false,\r\n \"status\" : \"placed\"\r\n}"; exampleJson = "\n 123456789\n 123456789\n 123\n 2000-01-23T04:56:07.000Z\n aeiou\n true\n"; var example = exampleJson != null @@ -128,7 +128,7 @@ public virtual IActionResult PlaceOrder([FromBody]Order order) //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "{\n \"petId\" : 6,\n \"quantity\" : 1,\n \"id\" : 0,\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\n \"complete\" : false,\n \"status\" : \"placed\"\n}"; + exampleJson = "{\r\n \"petId\" : 6,\r\n \"quantity\" : 1,\r\n \"id\" : 0,\r\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\r\n \"complete\" : false,\r\n \"status\" : \"placed\"\r\n}"; exampleJson = "\n 123456789\n 123456789\n 123\n 2000-01-23T04:56:07.000Z\n aeiou\n true\n"; var example = exampleJson != null diff --git a/samples/server/petstore/aspnetcore-3.1/src/Org.OpenAPITools/Controllers/UserApi.cs b/samples/server/petstore/aspnetcore-3.1/src/Org.OpenAPITools/Controllers/UserApi.cs index 6d7094c81a9d..3277ae43fcfd 100644 --- a/samples/server/petstore/aspnetcore-3.1/src/Org.OpenAPITools/Controllers/UserApi.cs +++ b/samples/server/petstore/aspnetcore-3.1/src/Org.OpenAPITools/Controllers/UserApi.cs @@ -134,7 +134,7 @@ public virtual IActionResult GetUserByName([FromRoute (Name = "username")][Requi //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"firstName\" : \"firstName\",\n \"lastName\" : \"lastName\",\n \"password\" : \"password\",\n \"userStatus\" : 6,\n \"phone\" : \"phone\",\n \"id\" : 0,\n \"email\" : \"email\",\n \"username\" : \"username\"\n}"; + exampleJson = "{\r\n \"firstName\" : \"firstName\",\r\n \"lastName\" : \"lastName\",\r\n \"password\" : \"password\",\r\n \"userStatus\" : 6,\r\n \"phone\" : \"phone\",\r\n \"id\" : 0,\r\n \"email\" : \"email\",\r\n \"username\" : \"username\"\r\n}"; exampleJson = "\n 123456789\n aeiou\n aeiou\n aeiou\n aeiou\n aeiou\n aeiou\n 123\n"; var example = exampleJson != null diff --git a/samples/server/petstore/aspnetcore-5.0/src/Org.OpenAPITools/Controllers/FakeApi.cs b/samples/server/petstore/aspnetcore-5.0/src/Org.OpenAPITools/Controllers/FakeApi.cs index a0f2bd3b2315..eccd3a3006a6 100644 --- a/samples/server/petstore/aspnetcore-5.0/src/Org.OpenAPITools/Controllers/FakeApi.cs +++ b/samples/server/petstore/aspnetcore-5.0/src/Org.OpenAPITools/Controllers/FakeApi.cs @@ -43,7 +43,7 @@ public virtual IActionResult FakeNullableExampleTest() //TODO: Uncomment the next line to return response 200 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(200, default(TestNullable)); string exampleJson = null; - exampleJson = "{\n \"nullableName\" : \"nullableName\",\n \"name\" : \"name\"\n}"; + exampleJson = "{\r\n \"nullableName\" : \"nullableName\",\r\n \"name\" : \"name\"\r\n}"; var example = exampleJson != null ? JsonConvert.DeserializeObject(exampleJson) diff --git a/samples/server/petstore/aspnetcore-5.0/src/Org.OpenAPITools/Controllers/PetApi.cs b/samples/server/petstore/aspnetcore-5.0/src/Org.OpenAPITools/Controllers/PetApi.cs index 7dded4e0f16a..5a197da3156e 100644 --- a/samples/server/petstore/aspnetcore-5.0/src/Org.OpenAPITools/Controllers/PetApi.cs +++ b/samples/server/petstore/aspnetcore-5.0/src/Org.OpenAPITools/Controllers/PetApi.cs @@ -48,7 +48,7 @@ public virtual IActionResult AddPet([FromBody]Pet pet) //TODO: Uncomment the next line to return response 405 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(405); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -97,7 +97,7 @@ public virtual IActionResult FindPetsByStatus([FromQuery (Name = "status")][Requ //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "[ {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}, {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n} ]"; + exampleJson = "[ {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}, {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n} ]"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -128,7 +128,7 @@ public virtual IActionResult FindPetsByTags([FromQuery (Name = "tags")][Required //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "[ {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}, {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n} ]"; + exampleJson = "[ {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}, {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n} ]"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -162,7 +162,7 @@ public virtual IActionResult GetPetById([FromRoute (Name = "petId")][Required]lo //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -198,7 +198,7 @@ public virtual IActionResult UpdatePet([FromBody]Pet pet) //TODO: Uncomment the next line to return response 405 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(405); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n doggie\n \n aeiou\n \n \n \n aeiou\n"; var example = exampleJson != null @@ -248,7 +248,7 @@ public virtual IActionResult UploadFile([FromRoute (Name = "petId")][Required]lo //TODO: Uncomment the next line to return response 200 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(200, default(ApiResponse)); string exampleJson = null; - exampleJson = "{\n \"code\" : 0,\n \"type\" : \"type\",\n \"message\" : \"message\"\n}"; + exampleJson = "{\r\n \"code\" : 0,\r\n \"type\" : \"type\",\r\n \"message\" : \"message\"\r\n}"; var example = exampleJson != null ? JsonConvert.DeserializeObject(exampleJson) diff --git a/samples/server/petstore/aspnetcore-5.0/src/Org.OpenAPITools/Controllers/StoreApi.cs b/samples/server/petstore/aspnetcore-5.0/src/Org.OpenAPITools/Controllers/StoreApi.cs index b925426c761d..c57b5fb3bd16 100644 --- a/samples/server/petstore/aspnetcore-5.0/src/Org.OpenAPITools/Controllers/StoreApi.cs +++ b/samples/server/petstore/aspnetcore-5.0/src/Org.OpenAPITools/Controllers/StoreApi.cs @@ -98,7 +98,7 @@ public virtual IActionResult GetOrderById([FromRoute (Name = "orderId")][Require //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"petId\" : 6,\n \"quantity\" : 1,\n \"id\" : 0,\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\n \"complete\" : false,\n \"status\" : \"placed\"\n}"; + exampleJson = "{\r\n \"petId\" : 6,\r\n \"quantity\" : 1,\r\n \"id\" : 0,\r\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\r\n \"complete\" : false,\r\n \"status\" : \"placed\"\r\n}"; exampleJson = "\n 123456789\n 123456789\n 123\n 2000-01-23T04:56:07.000Z\n aeiou\n true\n"; var example = exampleJson != null @@ -128,7 +128,7 @@ public virtual IActionResult PlaceOrder([FromBody]Order order) //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "{\n \"petId\" : 6,\n \"quantity\" : 1,\n \"id\" : 0,\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\n \"complete\" : false,\n \"status\" : \"placed\"\n}"; + exampleJson = "{\r\n \"petId\" : 6,\r\n \"quantity\" : 1,\r\n \"id\" : 0,\r\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\r\n \"complete\" : false,\r\n \"status\" : \"placed\"\r\n}"; exampleJson = "\n 123456789\n 123456789\n 123\n 2000-01-23T04:56:07.000Z\n aeiou\n true\n"; var example = exampleJson != null diff --git a/samples/server/petstore/aspnetcore-5.0/src/Org.OpenAPITools/Controllers/UserApi.cs b/samples/server/petstore/aspnetcore-5.0/src/Org.OpenAPITools/Controllers/UserApi.cs index 6d7094c81a9d..3277ae43fcfd 100644 --- a/samples/server/petstore/aspnetcore-5.0/src/Org.OpenAPITools/Controllers/UserApi.cs +++ b/samples/server/petstore/aspnetcore-5.0/src/Org.OpenAPITools/Controllers/UserApi.cs @@ -134,7 +134,7 @@ public virtual IActionResult GetUserByName([FromRoute (Name = "username")][Requi //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"firstName\" : \"firstName\",\n \"lastName\" : \"lastName\",\n \"password\" : \"password\",\n \"userStatus\" : 6,\n \"phone\" : \"phone\",\n \"id\" : 0,\n \"email\" : \"email\",\n \"username\" : \"username\"\n}"; + exampleJson = "{\r\n \"firstName\" : \"firstName\",\r\n \"lastName\" : \"lastName\",\r\n \"password\" : \"password\",\r\n \"userStatus\" : 6,\r\n \"phone\" : \"phone\",\r\n \"id\" : 0,\r\n \"email\" : \"email\",\r\n \"username\" : \"username\"\r\n}"; exampleJson = "\n 123456789\n aeiou\n aeiou\n aeiou\n aeiou\n aeiou\n aeiou\n 123\n"; var example = exampleJson != null diff --git a/samples/server/petstore/aspnetcore-6.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/FakeApi.cs b/samples/server/petstore/aspnetcore-6.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/FakeApi.cs index 6dd12a5fd682..47afda960757 100644 --- a/samples/server/petstore/aspnetcore-6.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/FakeApi.cs +++ b/samples/server/petstore/aspnetcore-6.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/FakeApi.cs @@ -43,7 +43,7 @@ public virtual IActionResult FakeNullableExampleTest() //TODO: Uncomment the next line to return response 200 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(200, default(TestNullable)); string exampleJson = null; - exampleJson = "{\n \"nullableName\" : \"nullableName\",\n \"name\" : \"name\"\n}"; + exampleJson = "{\r\n \"nullableName\" : \"nullableName\",\r\n \"name\" : \"name\"\r\n}"; var example = exampleJson != null ? JsonSerializer.Deserialize(exampleJson) diff --git a/samples/server/petstore/aspnetcore-6.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/PetApi.cs b/samples/server/petstore/aspnetcore-6.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/PetApi.cs index d4230ca5a4c5..9aa7c62b8e82 100644 --- a/samples/server/petstore/aspnetcore-6.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/PetApi.cs +++ b/samples/server/petstore/aspnetcore-6.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/PetApi.cs @@ -48,7 +48,7 @@ public virtual IActionResult AddPet([FromBody]Pet pet) //TODO: Uncomment the next line to return response 405 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(405); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -97,7 +97,7 @@ public virtual IActionResult FindPetsByStatus([FromQuery (Name = "status")][Requ //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "[ {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}, {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n} ]"; + exampleJson = "[ {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}, {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n} ]"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -128,7 +128,7 @@ public virtual IActionResult FindPetsByTags([FromQuery (Name = "tags")][Required //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "[ {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}, {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n} ]"; + exampleJson = "[ {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}, {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n} ]"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -162,7 +162,7 @@ public virtual IActionResult GetPetById([FromRoute (Name = "petId")][Required]lo //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -198,7 +198,7 @@ public virtual IActionResult UpdatePet([FromBody]Pet pet) //TODO: Uncomment the next line to return response 405 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(405); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n doggie\n \n aeiou\n \n \n \n aeiou\n"; var example = exampleJson != null @@ -248,7 +248,7 @@ public virtual IActionResult UploadFile([FromRoute (Name = "petId")][Required]lo //TODO: Uncomment the next line to return response 200 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(200, default(ApiResponse)); string exampleJson = null; - exampleJson = "{\n \"code\" : 0,\n \"type\" : \"type\",\n \"message\" : \"message\"\n}"; + exampleJson = "{\r\n \"code\" : 0,\r\n \"type\" : \"type\",\r\n \"message\" : \"message\"\r\n}"; var example = exampleJson != null ? JsonSerializer.Deserialize(exampleJson) diff --git a/samples/server/petstore/aspnetcore-6.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/StoreApi.cs b/samples/server/petstore/aspnetcore-6.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/StoreApi.cs index 2c52f026791d..edb6042856df 100644 --- a/samples/server/petstore/aspnetcore-6.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/StoreApi.cs +++ b/samples/server/petstore/aspnetcore-6.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/StoreApi.cs @@ -98,7 +98,7 @@ public virtual IActionResult GetOrderById([FromRoute (Name = "orderId")][Require //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"petId\" : 6,\n \"quantity\" : 1,\n \"id\" : 0,\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\n \"complete\" : false,\n \"status\" : \"placed\"\n}"; + exampleJson = "{\r\n \"petId\" : 6,\r\n \"quantity\" : 1,\r\n \"id\" : 0,\r\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\r\n \"complete\" : false,\r\n \"status\" : \"placed\"\r\n}"; exampleJson = "\n 123456789\n 123456789\n 123\n 2000-01-23T04:56:07.000Z\n aeiou\n true\n"; var example = exampleJson != null @@ -128,7 +128,7 @@ public virtual IActionResult PlaceOrder([FromBody]Order order) //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "{\n \"petId\" : 6,\n \"quantity\" : 1,\n \"id\" : 0,\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\n \"complete\" : false,\n \"status\" : \"placed\"\n}"; + exampleJson = "{\r\n \"petId\" : 6,\r\n \"quantity\" : 1,\r\n \"id\" : 0,\r\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\r\n \"complete\" : false,\r\n \"status\" : \"placed\"\r\n}"; exampleJson = "\n 123456789\n 123456789\n 123\n 2000-01-23T04:56:07.000Z\n aeiou\n true\n"; var example = exampleJson != null diff --git a/samples/server/petstore/aspnetcore-6.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/UserApi.cs b/samples/server/petstore/aspnetcore-6.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/UserApi.cs index 5a0951513f3d..98e67314721d 100644 --- a/samples/server/petstore/aspnetcore-6.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/UserApi.cs +++ b/samples/server/petstore/aspnetcore-6.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/UserApi.cs @@ -134,7 +134,7 @@ public virtual IActionResult GetUserByName([FromRoute (Name = "username")][Requi //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"firstName\" : \"firstName\",\n \"lastName\" : \"lastName\",\n \"password\" : \"password\",\n \"userStatus\" : 6,\n \"phone\" : \"phone\",\n \"id\" : 0,\n \"email\" : \"email\",\n \"username\" : \"username\"\n}"; + exampleJson = "{\r\n \"firstName\" : \"firstName\",\r\n \"lastName\" : \"lastName\",\r\n \"password\" : \"password\",\r\n \"userStatus\" : 6,\r\n \"phone\" : \"phone\",\r\n \"id\" : 0,\r\n \"email\" : \"email\",\r\n \"username\" : \"username\"\r\n}"; exampleJson = "\n 123456789\n aeiou\n aeiou\n aeiou\n aeiou\n aeiou\n aeiou\n 123\n"; var example = exampleJson != null diff --git a/samples/server/petstore/aspnetcore-6.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/FakeApi.cs b/samples/server/petstore/aspnetcore-6.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/FakeApi.cs index a0f2bd3b2315..eccd3a3006a6 100644 --- a/samples/server/petstore/aspnetcore-6.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/FakeApi.cs +++ b/samples/server/petstore/aspnetcore-6.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/FakeApi.cs @@ -43,7 +43,7 @@ public virtual IActionResult FakeNullableExampleTest() //TODO: Uncomment the next line to return response 200 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(200, default(TestNullable)); string exampleJson = null; - exampleJson = "{\n \"nullableName\" : \"nullableName\",\n \"name\" : \"name\"\n}"; + exampleJson = "{\r\n \"nullableName\" : \"nullableName\",\r\n \"name\" : \"name\"\r\n}"; var example = exampleJson != null ? JsonConvert.DeserializeObject(exampleJson) diff --git a/samples/server/petstore/aspnetcore-6.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/PetApi.cs b/samples/server/petstore/aspnetcore-6.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/PetApi.cs index fae01d29a624..64c652ea1875 100644 --- a/samples/server/petstore/aspnetcore-6.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/PetApi.cs +++ b/samples/server/petstore/aspnetcore-6.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/PetApi.cs @@ -48,7 +48,7 @@ public virtual IActionResult AddPet([FromBody]Pet pet) //TODO: Uncomment the next line to return response 405 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(405); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -97,7 +97,7 @@ public virtual IActionResult FindPetsByStatus([FromQuery (Name = "status")][Requ //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "[ {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}, {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n} ]"; + exampleJson = "[ {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}, {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n} ]"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -128,7 +128,7 @@ public virtual IActionResult FindPetsByTags([FromQuery (Name = "tags")][Required //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "[ {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}, {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n} ]"; + exampleJson = "[ {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}, {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n} ]"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -162,7 +162,7 @@ public virtual IActionResult GetPetById([FromRoute (Name = "petId")][Required]lo //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -198,7 +198,7 @@ public virtual IActionResult UpdatePet([FromBody]Pet pet) //TODO: Uncomment the next line to return response 405 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(405); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n doggie\n \n aeiou\n \n \n \n aeiou\n"; var example = exampleJson != null @@ -248,7 +248,7 @@ public virtual IActionResult UploadFile([FromRoute (Name = "petId")][Required]lo //TODO: Uncomment the next line to return response 200 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(200, default(ApiResponse)); string exampleJson = null; - exampleJson = "{\n \"code\" : 0,\n \"type\" : \"type\",\n \"message\" : \"message\"\n}"; + exampleJson = "{\r\n \"code\" : 0,\r\n \"type\" : \"type\",\r\n \"message\" : \"message\"\r\n}"; var example = exampleJson != null ? JsonConvert.DeserializeObject(exampleJson) diff --git a/samples/server/petstore/aspnetcore-6.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/StoreApi.cs b/samples/server/petstore/aspnetcore-6.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/StoreApi.cs index b925426c761d..c57b5fb3bd16 100644 --- a/samples/server/petstore/aspnetcore-6.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/StoreApi.cs +++ b/samples/server/petstore/aspnetcore-6.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/StoreApi.cs @@ -98,7 +98,7 @@ public virtual IActionResult GetOrderById([FromRoute (Name = "orderId")][Require //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"petId\" : 6,\n \"quantity\" : 1,\n \"id\" : 0,\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\n \"complete\" : false,\n \"status\" : \"placed\"\n}"; + exampleJson = "{\r\n \"petId\" : 6,\r\n \"quantity\" : 1,\r\n \"id\" : 0,\r\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\r\n \"complete\" : false,\r\n \"status\" : \"placed\"\r\n}"; exampleJson = "\n 123456789\n 123456789\n 123\n 2000-01-23T04:56:07.000Z\n aeiou\n true\n"; var example = exampleJson != null @@ -128,7 +128,7 @@ public virtual IActionResult PlaceOrder([FromBody]Order order) //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "{\n \"petId\" : 6,\n \"quantity\" : 1,\n \"id\" : 0,\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\n \"complete\" : false,\n \"status\" : \"placed\"\n}"; + exampleJson = "{\r\n \"petId\" : 6,\r\n \"quantity\" : 1,\r\n \"id\" : 0,\r\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\r\n \"complete\" : false,\r\n \"status\" : \"placed\"\r\n}"; exampleJson = "\n 123456789\n 123456789\n 123\n 2000-01-23T04:56:07.000Z\n aeiou\n true\n"; var example = exampleJson != null diff --git a/samples/server/petstore/aspnetcore-6.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/UserApi.cs b/samples/server/petstore/aspnetcore-6.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/UserApi.cs index 6d7094c81a9d..3277ae43fcfd 100644 --- a/samples/server/petstore/aspnetcore-6.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/UserApi.cs +++ b/samples/server/petstore/aspnetcore-6.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/UserApi.cs @@ -134,7 +134,7 @@ public virtual IActionResult GetUserByName([FromRoute (Name = "username")][Requi //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"firstName\" : \"firstName\",\n \"lastName\" : \"lastName\",\n \"password\" : \"password\",\n \"userStatus\" : 6,\n \"phone\" : \"phone\",\n \"id\" : 0,\n \"email\" : \"email\",\n \"username\" : \"username\"\n}"; + exampleJson = "{\r\n \"firstName\" : \"firstName\",\r\n \"lastName\" : \"lastName\",\r\n \"password\" : \"password\",\r\n \"userStatus\" : 6,\r\n \"phone\" : \"phone\",\r\n \"id\" : 0,\r\n \"email\" : \"email\",\r\n \"username\" : \"username\"\r\n}"; exampleJson = "\n 123456789\n aeiou\n aeiou\n aeiou\n aeiou\n aeiou\n aeiou\n 123\n"; var example = exampleJson != null diff --git a/samples/server/petstore/aspnetcore-6.0-pocoModels/src/Org.OpenAPITools/Controllers/FakeApi.cs b/samples/server/petstore/aspnetcore-6.0-pocoModels/src/Org.OpenAPITools/Controllers/FakeApi.cs index a0f2bd3b2315..eccd3a3006a6 100644 --- a/samples/server/petstore/aspnetcore-6.0-pocoModels/src/Org.OpenAPITools/Controllers/FakeApi.cs +++ b/samples/server/petstore/aspnetcore-6.0-pocoModels/src/Org.OpenAPITools/Controllers/FakeApi.cs @@ -43,7 +43,7 @@ public virtual IActionResult FakeNullableExampleTest() //TODO: Uncomment the next line to return response 200 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(200, default(TestNullable)); string exampleJson = null; - exampleJson = "{\n \"nullableName\" : \"nullableName\",\n \"name\" : \"name\"\n}"; + exampleJson = "{\r\n \"nullableName\" : \"nullableName\",\r\n \"name\" : \"name\"\r\n}"; var example = exampleJson != null ? JsonConvert.DeserializeObject(exampleJson) diff --git a/samples/server/petstore/aspnetcore-6.0-pocoModels/src/Org.OpenAPITools/Controllers/PetApi.cs b/samples/server/petstore/aspnetcore-6.0-pocoModels/src/Org.OpenAPITools/Controllers/PetApi.cs index 7dded4e0f16a..5a197da3156e 100644 --- a/samples/server/petstore/aspnetcore-6.0-pocoModels/src/Org.OpenAPITools/Controllers/PetApi.cs +++ b/samples/server/petstore/aspnetcore-6.0-pocoModels/src/Org.OpenAPITools/Controllers/PetApi.cs @@ -48,7 +48,7 @@ public virtual IActionResult AddPet([FromBody]Pet pet) //TODO: Uncomment the next line to return response 405 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(405); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -97,7 +97,7 @@ public virtual IActionResult FindPetsByStatus([FromQuery (Name = "status")][Requ //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "[ {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}, {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n} ]"; + exampleJson = "[ {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}, {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n} ]"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -128,7 +128,7 @@ public virtual IActionResult FindPetsByTags([FromQuery (Name = "tags")][Required //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "[ {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}, {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n} ]"; + exampleJson = "[ {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}, {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n} ]"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -162,7 +162,7 @@ public virtual IActionResult GetPetById([FromRoute (Name = "petId")][Required]lo //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -198,7 +198,7 @@ public virtual IActionResult UpdatePet([FromBody]Pet pet) //TODO: Uncomment the next line to return response 405 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(405); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n doggie\n \n aeiou\n \n \n \n aeiou\n"; var example = exampleJson != null @@ -248,7 +248,7 @@ public virtual IActionResult UploadFile([FromRoute (Name = "petId")][Required]lo //TODO: Uncomment the next line to return response 200 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(200, default(ApiResponse)); string exampleJson = null; - exampleJson = "{\n \"code\" : 0,\n \"type\" : \"type\",\n \"message\" : \"message\"\n}"; + exampleJson = "{\r\n \"code\" : 0,\r\n \"type\" : \"type\",\r\n \"message\" : \"message\"\r\n}"; var example = exampleJson != null ? JsonConvert.DeserializeObject(exampleJson) diff --git a/samples/server/petstore/aspnetcore-6.0-pocoModels/src/Org.OpenAPITools/Controllers/StoreApi.cs b/samples/server/petstore/aspnetcore-6.0-pocoModels/src/Org.OpenAPITools/Controllers/StoreApi.cs index b925426c761d..c57b5fb3bd16 100644 --- a/samples/server/petstore/aspnetcore-6.0-pocoModels/src/Org.OpenAPITools/Controllers/StoreApi.cs +++ b/samples/server/petstore/aspnetcore-6.0-pocoModels/src/Org.OpenAPITools/Controllers/StoreApi.cs @@ -98,7 +98,7 @@ public virtual IActionResult GetOrderById([FromRoute (Name = "orderId")][Require //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"petId\" : 6,\n \"quantity\" : 1,\n \"id\" : 0,\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\n \"complete\" : false,\n \"status\" : \"placed\"\n}"; + exampleJson = "{\r\n \"petId\" : 6,\r\n \"quantity\" : 1,\r\n \"id\" : 0,\r\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\r\n \"complete\" : false,\r\n \"status\" : \"placed\"\r\n}"; exampleJson = "\n 123456789\n 123456789\n 123\n 2000-01-23T04:56:07.000Z\n aeiou\n true\n"; var example = exampleJson != null @@ -128,7 +128,7 @@ public virtual IActionResult PlaceOrder([FromBody]Order order) //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "{\n \"petId\" : 6,\n \"quantity\" : 1,\n \"id\" : 0,\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\n \"complete\" : false,\n \"status\" : \"placed\"\n}"; + exampleJson = "{\r\n \"petId\" : 6,\r\n \"quantity\" : 1,\r\n \"id\" : 0,\r\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\r\n \"complete\" : false,\r\n \"status\" : \"placed\"\r\n}"; exampleJson = "\n 123456789\n 123456789\n 123\n 2000-01-23T04:56:07.000Z\n aeiou\n true\n"; var example = exampleJson != null diff --git a/samples/server/petstore/aspnetcore-6.0-pocoModels/src/Org.OpenAPITools/Controllers/UserApi.cs b/samples/server/petstore/aspnetcore-6.0-pocoModels/src/Org.OpenAPITools/Controllers/UserApi.cs index 6d7094c81a9d..3277ae43fcfd 100644 --- a/samples/server/petstore/aspnetcore-6.0-pocoModels/src/Org.OpenAPITools/Controllers/UserApi.cs +++ b/samples/server/petstore/aspnetcore-6.0-pocoModels/src/Org.OpenAPITools/Controllers/UserApi.cs @@ -134,7 +134,7 @@ public virtual IActionResult GetUserByName([FromRoute (Name = "username")][Requi //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"firstName\" : \"firstName\",\n \"lastName\" : \"lastName\",\n \"password\" : \"password\",\n \"userStatus\" : 6,\n \"phone\" : \"phone\",\n \"id\" : 0,\n \"email\" : \"email\",\n \"username\" : \"username\"\n}"; + exampleJson = "{\r\n \"firstName\" : \"firstName\",\r\n \"lastName\" : \"lastName\",\r\n \"password\" : \"password\",\r\n \"userStatus\" : 6,\r\n \"phone\" : \"phone\",\r\n \"id\" : 0,\r\n \"email\" : \"email\",\r\n \"username\" : \"username\"\r\n}"; exampleJson = "\n 123456789\n aeiou\n aeiou\n aeiou\n aeiou\n aeiou\n aeiou\n 123\n"; var example = exampleJson != null diff --git a/samples/server/petstore/aspnetcore-6.0-project4Models/src/Org.OpenAPITools/Controllers/FakeApi.cs b/samples/server/petstore/aspnetcore-6.0-project4Models/src/Org.OpenAPITools/Controllers/FakeApi.cs index a0f2bd3b2315..eccd3a3006a6 100644 --- a/samples/server/petstore/aspnetcore-6.0-project4Models/src/Org.OpenAPITools/Controllers/FakeApi.cs +++ b/samples/server/petstore/aspnetcore-6.0-project4Models/src/Org.OpenAPITools/Controllers/FakeApi.cs @@ -43,7 +43,7 @@ public virtual IActionResult FakeNullableExampleTest() //TODO: Uncomment the next line to return response 200 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(200, default(TestNullable)); string exampleJson = null; - exampleJson = "{\n \"nullableName\" : \"nullableName\",\n \"name\" : \"name\"\n}"; + exampleJson = "{\r\n \"nullableName\" : \"nullableName\",\r\n \"name\" : \"name\"\r\n}"; var example = exampleJson != null ? JsonConvert.DeserializeObject(exampleJson) diff --git a/samples/server/petstore/aspnetcore-6.0-project4Models/src/Org.OpenAPITools/Controllers/PetApi.cs b/samples/server/petstore/aspnetcore-6.0-project4Models/src/Org.OpenAPITools/Controllers/PetApi.cs index 7dded4e0f16a..5a197da3156e 100644 --- a/samples/server/petstore/aspnetcore-6.0-project4Models/src/Org.OpenAPITools/Controllers/PetApi.cs +++ b/samples/server/petstore/aspnetcore-6.0-project4Models/src/Org.OpenAPITools/Controllers/PetApi.cs @@ -48,7 +48,7 @@ public virtual IActionResult AddPet([FromBody]Pet pet) //TODO: Uncomment the next line to return response 405 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(405); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -97,7 +97,7 @@ public virtual IActionResult FindPetsByStatus([FromQuery (Name = "status")][Requ //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "[ {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}, {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n} ]"; + exampleJson = "[ {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}, {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n} ]"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -128,7 +128,7 @@ public virtual IActionResult FindPetsByTags([FromQuery (Name = "tags")][Required //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "[ {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}, {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n} ]"; + exampleJson = "[ {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}, {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n} ]"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -162,7 +162,7 @@ public virtual IActionResult GetPetById([FromRoute (Name = "petId")][Required]lo //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -198,7 +198,7 @@ public virtual IActionResult UpdatePet([FromBody]Pet pet) //TODO: Uncomment the next line to return response 405 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(405); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n doggie\n \n aeiou\n \n \n \n aeiou\n"; var example = exampleJson != null @@ -248,7 +248,7 @@ public virtual IActionResult UploadFile([FromRoute (Name = "petId")][Required]lo //TODO: Uncomment the next line to return response 200 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(200, default(ApiResponse)); string exampleJson = null; - exampleJson = "{\n \"code\" : 0,\n \"type\" : \"type\",\n \"message\" : \"message\"\n}"; + exampleJson = "{\r\n \"code\" : 0,\r\n \"type\" : \"type\",\r\n \"message\" : \"message\"\r\n}"; var example = exampleJson != null ? JsonConvert.DeserializeObject(exampleJson) diff --git a/samples/server/petstore/aspnetcore-6.0-project4Models/src/Org.OpenAPITools/Controllers/StoreApi.cs b/samples/server/petstore/aspnetcore-6.0-project4Models/src/Org.OpenAPITools/Controllers/StoreApi.cs index b925426c761d..c57b5fb3bd16 100644 --- a/samples/server/petstore/aspnetcore-6.0-project4Models/src/Org.OpenAPITools/Controllers/StoreApi.cs +++ b/samples/server/petstore/aspnetcore-6.0-project4Models/src/Org.OpenAPITools/Controllers/StoreApi.cs @@ -98,7 +98,7 @@ public virtual IActionResult GetOrderById([FromRoute (Name = "orderId")][Require //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"petId\" : 6,\n \"quantity\" : 1,\n \"id\" : 0,\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\n \"complete\" : false,\n \"status\" : \"placed\"\n}"; + exampleJson = "{\r\n \"petId\" : 6,\r\n \"quantity\" : 1,\r\n \"id\" : 0,\r\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\r\n \"complete\" : false,\r\n \"status\" : \"placed\"\r\n}"; exampleJson = "\n 123456789\n 123456789\n 123\n 2000-01-23T04:56:07.000Z\n aeiou\n true\n"; var example = exampleJson != null @@ -128,7 +128,7 @@ public virtual IActionResult PlaceOrder([FromBody]Order order) //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "{\n \"petId\" : 6,\n \"quantity\" : 1,\n \"id\" : 0,\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\n \"complete\" : false,\n \"status\" : \"placed\"\n}"; + exampleJson = "{\r\n \"petId\" : 6,\r\n \"quantity\" : 1,\r\n \"id\" : 0,\r\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\r\n \"complete\" : false,\r\n \"status\" : \"placed\"\r\n}"; exampleJson = "\n 123456789\n 123456789\n 123\n 2000-01-23T04:56:07.000Z\n aeiou\n true\n"; var example = exampleJson != null diff --git a/samples/server/petstore/aspnetcore-6.0-project4Models/src/Org.OpenAPITools/Controllers/UserApi.cs b/samples/server/petstore/aspnetcore-6.0-project4Models/src/Org.OpenAPITools/Controllers/UserApi.cs index 6d7094c81a9d..3277ae43fcfd 100644 --- a/samples/server/petstore/aspnetcore-6.0-project4Models/src/Org.OpenAPITools/Controllers/UserApi.cs +++ b/samples/server/petstore/aspnetcore-6.0-project4Models/src/Org.OpenAPITools/Controllers/UserApi.cs @@ -134,7 +134,7 @@ public virtual IActionResult GetUserByName([FromRoute (Name = "username")][Requi //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"firstName\" : \"firstName\",\n \"lastName\" : \"lastName\",\n \"password\" : \"password\",\n \"userStatus\" : 6,\n \"phone\" : \"phone\",\n \"id\" : 0,\n \"email\" : \"email\",\n \"username\" : \"username\"\n}"; + exampleJson = "{\r\n \"firstName\" : \"firstName\",\r\n \"lastName\" : \"lastName\",\r\n \"password\" : \"password\",\r\n \"userStatus\" : 6,\r\n \"phone\" : \"phone\",\r\n \"id\" : 0,\r\n \"email\" : \"email\",\r\n \"username\" : \"username\"\r\n}"; exampleJson = "\n 123456789\n aeiou\n aeiou\n aeiou\n aeiou\n aeiou\n aeiou\n 123\n"; var example = exampleJson != null diff --git a/samples/server/petstore/aspnetcore-6.0/src/Org.OpenAPITools/Controllers/FakeApi.cs b/samples/server/petstore/aspnetcore-6.0/src/Org.OpenAPITools/Controllers/FakeApi.cs index a0f2bd3b2315..eccd3a3006a6 100644 --- a/samples/server/petstore/aspnetcore-6.0/src/Org.OpenAPITools/Controllers/FakeApi.cs +++ b/samples/server/petstore/aspnetcore-6.0/src/Org.OpenAPITools/Controllers/FakeApi.cs @@ -43,7 +43,7 @@ public virtual IActionResult FakeNullableExampleTest() //TODO: Uncomment the next line to return response 200 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(200, default(TestNullable)); string exampleJson = null; - exampleJson = "{\n \"nullableName\" : \"nullableName\",\n \"name\" : \"name\"\n}"; + exampleJson = "{\r\n \"nullableName\" : \"nullableName\",\r\n \"name\" : \"name\"\r\n}"; var example = exampleJson != null ? JsonConvert.DeserializeObject(exampleJson) diff --git a/samples/server/petstore/aspnetcore-6.0/src/Org.OpenAPITools/Controllers/PetApi.cs b/samples/server/petstore/aspnetcore-6.0/src/Org.OpenAPITools/Controllers/PetApi.cs index 7dded4e0f16a..5a197da3156e 100644 --- a/samples/server/petstore/aspnetcore-6.0/src/Org.OpenAPITools/Controllers/PetApi.cs +++ b/samples/server/petstore/aspnetcore-6.0/src/Org.OpenAPITools/Controllers/PetApi.cs @@ -48,7 +48,7 @@ public virtual IActionResult AddPet([FromBody]Pet pet) //TODO: Uncomment the next line to return response 405 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(405); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -97,7 +97,7 @@ public virtual IActionResult FindPetsByStatus([FromQuery (Name = "status")][Requ //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "[ {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}, {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n} ]"; + exampleJson = "[ {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}, {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n} ]"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -128,7 +128,7 @@ public virtual IActionResult FindPetsByTags([FromQuery (Name = "tags")][Required //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "[ {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}, {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n} ]"; + exampleJson = "[ {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}, {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n} ]"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -162,7 +162,7 @@ public virtual IActionResult GetPetById([FromRoute (Name = "petId")][Required]lo //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -198,7 +198,7 @@ public virtual IActionResult UpdatePet([FromBody]Pet pet) //TODO: Uncomment the next line to return response 405 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(405); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n doggie\n \n aeiou\n \n \n \n aeiou\n"; var example = exampleJson != null @@ -248,7 +248,7 @@ public virtual IActionResult UploadFile([FromRoute (Name = "petId")][Required]lo //TODO: Uncomment the next line to return response 200 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(200, default(ApiResponse)); string exampleJson = null; - exampleJson = "{\n \"code\" : 0,\n \"type\" : \"type\",\n \"message\" : \"message\"\n}"; + exampleJson = "{\r\n \"code\" : 0,\r\n \"type\" : \"type\",\r\n \"message\" : \"message\"\r\n}"; var example = exampleJson != null ? JsonConvert.DeserializeObject(exampleJson) diff --git a/samples/server/petstore/aspnetcore-6.0/src/Org.OpenAPITools/Controllers/StoreApi.cs b/samples/server/petstore/aspnetcore-6.0/src/Org.OpenAPITools/Controllers/StoreApi.cs index b925426c761d..c57b5fb3bd16 100644 --- a/samples/server/petstore/aspnetcore-6.0/src/Org.OpenAPITools/Controllers/StoreApi.cs +++ b/samples/server/petstore/aspnetcore-6.0/src/Org.OpenAPITools/Controllers/StoreApi.cs @@ -98,7 +98,7 @@ public virtual IActionResult GetOrderById([FromRoute (Name = "orderId")][Require //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"petId\" : 6,\n \"quantity\" : 1,\n \"id\" : 0,\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\n \"complete\" : false,\n \"status\" : \"placed\"\n}"; + exampleJson = "{\r\n \"petId\" : 6,\r\n \"quantity\" : 1,\r\n \"id\" : 0,\r\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\r\n \"complete\" : false,\r\n \"status\" : \"placed\"\r\n}"; exampleJson = "\n 123456789\n 123456789\n 123\n 2000-01-23T04:56:07.000Z\n aeiou\n true\n"; var example = exampleJson != null @@ -128,7 +128,7 @@ public virtual IActionResult PlaceOrder([FromBody]Order order) //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "{\n \"petId\" : 6,\n \"quantity\" : 1,\n \"id\" : 0,\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\n \"complete\" : false,\n \"status\" : \"placed\"\n}"; + exampleJson = "{\r\n \"petId\" : 6,\r\n \"quantity\" : 1,\r\n \"id\" : 0,\r\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\r\n \"complete\" : false,\r\n \"status\" : \"placed\"\r\n}"; exampleJson = "\n 123456789\n 123456789\n 123\n 2000-01-23T04:56:07.000Z\n aeiou\n true\n"; var example = exampleJson != null diff --git a/samples/server/petstore/aspnetcore-6.0/src/Org.OpenAPITools/Controllers/UserApi.cs b/samples/server/petstore/aspnetcore-6.0/src/Org.OpenAPITools/Controllers/UserApi.cs index 6d7094c81a9d..3277ae43fcfd 100644 --- a/samples/server/petstore/aspnetcore-6.0/src/Org.OpenAPITools/Controllers/UserApi.cs +++ b/samples/server/petstore/aspnetcore-6.0/src/Org.OpenAPITools/Controllers/UserApi.cs @@ -134,7 +134,7 @@ public virtual IActionResult GetUserByName([FromRoute (Name = "username")][Requi //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"firstName\" : \"firstName\",\n \"lastName\" : \"lastName\",\n \"password\" : \"password\",\n \"userStatus\" : 6,\n \"phone\" : \"phone\",\n \"id\" : 0,\n \"email\" : \"email\",\n \"username\" : \"username\"\n}"; + exampleJson = "{\r\n \"firstName\" : \"firstName\",\r\n \"lastName\" : \"lastName\",\r\n \"password\" : \"password\",\r\n \"userStatus\" : 6,\r\n \"phone\" : \"phone\",\r\n \"id\" : 0,\r\n \"email\" : \"email\",\r\n \"username\" : \"username\"\r\n}"; exampleJson = "\n 123456789\n aeiou\n aeiou\n aeiou\n aeiou\n aeiou\n aeiou\n 123\n"; var example = exampleJson != null diff --git a/samples/server/petstore/aspnetcore-8.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/FakeApi.cs b/samples/server/petstore/aspnetcore-8.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/FakeApi.cs index 6dd12a5fd682..47afda960757 100644 --- a/samples/server/petstore/aspnetcore-8.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/FakeApi.cs +++ b/samples/server/petstore/aspnetcore-8.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/FakeApi.cs @@ -43,7 +43,7 @@ public virtual IActionResult FakeNullableExampleTest() //TODO: Uncomment the next line to return response 200 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(200, default(TestNullable)); string exampleJson = null; - exampleJson = "{\n \"nullableName\" : \"nullableName\",\n \"name\" : \"name\"\n}"; + exampleJson = "{\r\n \"nullableName\" : \"nullableName\",\r\n \"name\" : \"name\"\r\n}"; var example = exampleJson != null ? JsonSerializer.Deserialize(exampleJson) diff --git a/samples/server/petstore/aspnetcore-8.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/PetApi.cs b/samples/server/petstore/aspnetcore-8.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/PetApi.cs index d4230ca5a4c5..9aa7c62b8e82 100644 --- a/samples/server/petstore/aspnetcore-8.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/PetApi.cs +++ b/samples/server/petstore/aspnetcore-8.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/PetApi.cs @@ -48,7 +48,7 @@ public virtual IActionResult AddPet([FromBody]Pet pet) //TODO: Uncomment the next line to return response 405 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(405); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -97,7 +97,7 @@ public virtual IActionResult FindPetsByStatus([FromQuery (Name = "status")][Requ //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "[ {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}, {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n} ]"; + exampleJson = "[ {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}, {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n} ]"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -128,7 +128,7 @@ public virtual IActionResult FindPetsByTags([FromQuery (Name = "tags")][Required //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "[ {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}, {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n} ]"; + exampleJson = "[ {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}, {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n} ]"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -162,7 +162,7 @@ public virtual IActionResult GetPetById([FromRoute (Name = "petId")][Required]lo //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -198,7 +198,7 @@ public virtual IActionResult UpdatePet([FromBody]Pet pet) //TODO: Uncomment the next line to return response 405 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(405); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n doggie\n \n aeiou\n \n \n \n aeiou\n"; var example = exampleJson != null @@ -248,7 +248,7 @@ public virtual IActionResult UploadFile([FromRoute (Name = "petId")][Required]lo //TODO: Uncomment the next line to return response 200 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(200, default(ApiResponse)); string exampleJson = null; - exampleJson = "{\n \"code\" : 0,\n \"type\" : \"type\",\n \"message\" : \"message\"\n}"; + exampleJson = "{\r\n \"code\" : 0,\r\n \"type\" : \"type\",\r\n \"message\" : \"message\"\r\n}"; var example = exampleJson != null ? JsonSerializer.Deserialize(exampleJson) diff --git a/samples/server/petstore/aspnetcore-8.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/StoreApi.cs b/samples/server/petstore/aspnetcore-8.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/StoreApi.cs index 2c52f026791d..edb6042856df 100644 --- a/samples/server/petstore/aspnetcore-8.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/StoreApi.cs +++ b/samples/server/petstore/aspnetcore-8.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/StoreApi.cs @@ -98,7 +98,7 @@ public virtual IActionResult GetOrderById([FromRoute (Name = "orderId")][Require //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"petId\" : 6,\n \"quantity\" : 1,\n \"id\" : 0,\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\n \"complete\" : false,\n \"status\" : \"placed\"\n}"; + exampleJson = "{\r\n \"petId\" : 6,\r\n \"quantity\" : 1,\r\n \"id\" : 0,\r\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\r\n \"complete\" : false,\r\n \"status\" : \"placed\"\r\n}"; exampleJson = "\n 123456789\n 123456789\n 123\n 2000-01-23T04:56:07.000Z\n aeiou\n true\n"; var example = exampleJson != null @@ -128,7 +128,7 @@ public virtual IActionResult PlaceOrder([FromBody]Order order) //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "{\n \"petId\" : 6,\n \"quantity\" : 1,\n \"id\" : 0,\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\n \"complete\" : false,\n \"status\" : \"placed\"\n}"; + exampleJson = "{\r\n \"petId\" : 6,\r\n \"quantity\" : 1,\r\n \"id\" : 0,\r\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\r\n \"complete\" : false,\r\n \"status\" : \"placed\"\r\n}"; exampleJson = "\n 123456789\n 123456789\n 123\n 2000-01-23T04:56:07.000Z\n aeiou\n true\n"; var example = exampleJson != null diff --git a/samples/server/petstore/aspnetcore-8.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/UserApi.cs b/samples/server/petstore/aspnetcore-8.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/UserApi.cs index 5a0951513f3d..98e67314721d 100644 --- a/samples/server/petstore/aspnetcore-8.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/UserApi.cs +++ b/samples/server/petstore/aspnetcore-8.0-NewtonsoftFalse/src/Org.OpenAPITools/Controllers/UserApi.cs @@ -134,7 +134,7 @@ public virtual IActionResult GetUserByName([FromRoute (Name = "username")][Requi //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"firstName\" : \"firstName\",\n \"lastName\" : \"lastName\",\n \"password\" : \"password\",\n \"userStatus\" : 6,\n \"phone\" : \"phone\",\n \"id\" : 0,\n \"email\" : \"email\",\n \"username\" : \"username\"\n}"; + exampleJson = "{\r\n \"firstName\" : \"firstName\",\r\n \"lastName\" : \"lastName\",\r\n \"password\" : \"password\",\r\n \"userStatus\" : 6,\r\n \"phone\" : \"phone\",\r\n \"id\" : 0,\r\n \"email\" : \"email\",\r\n \"username\" : \"username\"\r\n}"; exampleJson = "\n 123456789\n aeiou\n aeiou\n aeiou\n aeiou\n aeiou\n aeiou\n 123\n"; var example = exampleJson != null diff --git a/samples/server/petstore/aspnetcore-8.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/FakeApi.cs b/samples/server/petstore/aspnetcore-8.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/FakeApi.cs index a0f2bd3b2315..eccd3a3006a6 100644 --- a/samples/server/petstore/aspnetcore-8.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/FakeApi.cs +++ b/samples/server/petstore/aspnetcore-8.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/FakeApi.cs @@ -43,7 +43,7 @@ public virtual IActionResult FakeNullableExampleTest() //TODO: Uncomment the next line to return response 200 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(200, default(TestNullable)); string exampleJson = null; - exampleJson = "{\n \"nullableName\" : \"nullableName\",\n \"name\" : \"name\"\n}"; + exampleJson = "{\r\n \"nullableName\" : \"nullableName\",\r\n \"name\" : \"name\"\r\n}"; var example = exampleJson != null ? JsonConvert.DeserializeObject(exampleJson) diff --git a/samples/server/petstore/aspnetcore-8.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/PetApi.cs b/samples/server/petstore/aspnetcore-8.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/PetApi.cs index fae01d29a624..64c652ea1875 100644 --- a/samples/server/petstore/aspnetcore-8.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/PetApi.cs +++ b/samples/server/petstore/aspnetcore-8.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/PetApi.cs @@ -48,7 +48,7 @@ public virtual IActionResult AddPet([FromBody]Pet pet) //TODO: Uncomment the next line to return response 405 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(405); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -97,7 +97,7 @@ public virtual IActionResult FindPetsByStatus([FromQuery (Name = "status")][Requ //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "[ {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}, {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n} ]"; + exampleJson = "[ {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}, {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n} ]"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -128,7 +128,7 @@ public virtual IActionResult FindPetsByTags([FromQuery (Name = "tags")][Required //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "[ {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}, {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n} ]"; + exampleJson = "[ {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}, {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n} ]"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -162,7 +162,7 @@ public virtual IActionResult GetPetById([FromRoute (Name = "petId")][Required]lo //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -198,7 +198,7 @@ public virtual IActionResult UpdatePet([FromBody]Pet pet) //TODO: Uncomment the next line to return response 405 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(405); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n doggie\n \n aeiou\n \n \n \n aeiou\n"; var example = exampleJson != null @@ -248,7 +248,7 @@ public virtual IActionResult UploadFile([FromRoute (Name = "petId")][Required]lo //TODO: Uncomment the next line to return response 200 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(200, default(ApiResponse)); string exampleJson = null; - exampleJson = "{\n \"code\" : 0,\n \"type\" : \"type\",\n \"message\" : \"message\"\n}"; + exampleJson = "{\r\n \"code\" : 0,\r\n \"type\" : \"type\",\r\n \"message\" : \"message\"\r\n}"; var example = exampleJson != null ? JsonConvert.DeserializeObject(exampleJson) diff --git a/samples/server/petstore/aspnetcore-8.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/StoreApi.cs b/samples/server/petstore/aspnetcore-8.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/StoreApi.cs index b925426c761d..c57b5fb3bd16 100644 --- a/samples/server/petstore/aspnetcore-8.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/StoreApi.cs +++ b/samples/server/petstore/aspnetcore-8.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/StoreApi.cs @@ -98,7 +98,7 @@ public virtual IActionResult GetOrderById([FromRoute (Name = "orderId")][Require //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"petId\" : 6,\n \"quantity\" : 1,\n \"id\" : 0,\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\n \"complete\" : false,\n \"status\" : \"placed\"\n}"; + exampleJson = "{\r\n \"petId\" : 6,\r\n \"quantity\" : 1,\r\n \"id\" : 0,\r\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\r\n \"complete\" : false,\r\n \"status\" : \"placed\"\r\n}"; exampleJson = "\n 123456789\n 123456789\n 123\n 2000-01-23T04:56:07.000Z\n aeiou\n true\n"; var example = exampleJson != null @@ -128,7 +128,7 @@ public virtual IActionResult PlaceOrder([FromBody]Order order) //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "{\n \"petId\" : 6,\n \"quantity\" : 1,\n \"id\" : 0,\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\n \"complete\" : false,\n \"status\" : \"placed\"\n}"; + exampleJson = "{\r\n \"petId\" : 6,\r\n \"quantity\" : 1,\r\n \"id\" : 0,\r\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\r\n \"complete\" : false,\r\n \"status\" : \"placed\"\r\n}"; exampleJson = "\n 123456789\n 123456789\n 123\n 2000-01-23T04:56:07.000Z\n aeiou\n true\n"; var example = exampleJson != null diff --git a/samples/server/petstore/aspnetcore-8.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/UserApi.cs b/samples/server/petstore/aspnetcore-8.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/UserApi.cs index 6d7094c81a9d..3277ae43fcfd 100644 --- a/samples/server/petstore/aspnetcore-8.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/UserApi.cs +++ b/samples/server/petstore/aspnetcore-8.0-nullableReferenceTypes/src/Org.OpenAPITools/Controllers/UserApi.cs @@ -134,7 +134,7 @@ public virtual IActionResult GetUserByName([FromRoute (Name = "username")][Requi //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"firstName\" : \"firstName\",\n \"lastName\" : \"lastName\",\n \"password\" : \"password\",\n \"userStatus\" : 6,\n \"phone\" : \"phone\",\n \"id\" : 0,\n \"email\" : \"email\",\n \"username\" : \"username\"\n}"; + exampleJson = "{\r\n \"firstName\" : \"firstName\",\r\n \"lastName\" : \"lastName\",\r\n \"password\" : \"password\",\r\n \"userStatus\" : 6,\r\n \"phone\" : \"phone\",\r\n \"id\" : 0,\r\n \"email\" : \"email\",\r\n \"username\" : \"username\"\r\n}"; exampleJson = "\n 123456789\n aeiou\n aeiou\n aeiou\n aeiou\n aeiou\n aeiou\n 123\n"; var example = exampleJson != null diff --git a/samples/server/petstore/aspnetcore-8.0-pocoModels/src/Org.OpenAPITools/Controllers/FakeApi.cs b/samples/server/petstore/aspnetcore-8.0-pocoModels/src/Org.OpenAPITools/Controllers/FakeApi.cs index a0f2bd3b2315..eccd3a3006a6 100644 --- a/samples/server/petstore/aspnetcore-8.0-pocoModels/src/Org.OpenAPITools/Controllers/FakeApi.cs +++ b/samples/server/petstore/aspnetcore-8.0-pocoModels/src/Org.OpenAPITools/Controllers/FakeApi.cs @@ -43,7 +43,7 @@ public virtual IActionResult FakeNullableExampleTest() //TODO: Uncomment the next line to return response 200 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(200, default(TestNullable)); string exampleJson = null; - exampleJson = "{\n \"nullableName\" : \"nullableName\",\n \"name\" : \"name\"\n}"; + exampleJson = "{\r\n \"nullableName\" : \"nullableName\",\r\n \"name\" : \"name\"\r\n}"; var example = exampleJson != null ? JsonConvert.DeserializeObject(exampleJson) diff --git a/samples/server/petstore/aspnetcore-8.0-pocoModels/src/Org.OpenAPITools/Controllers/PetApi.cs b/samples/server/petstore/aspnetcore-8.0-pocoModels/src/Org.OpenAPITools/Controllers/PetApi.cs index 7dded4e0f16a..5a197da3156e 100644 --- a/samples/server/petstore/aspnetcore-8.0-pocoModels/src/Org.OpenAPITools/Controllers/PetApi.cs +++ b/samples/server/petstore/aspnetcore-8.0-pocoModels/src/Org.OpenAPITools/Controllers/PetApi.cs @@ -48,7 +48,7 @@ public virtual IActionResult AddPet([FromBody]Pet pet) //TODO: Uncomment the next line to return response 405 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(405); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -97,7 +97,7 @@ public virtual IActionResult FindPetsByStatus([FromQuery (Name = "status")][Requ //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "[ {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}, {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n} ]"; + exampleJson = "[ {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}, {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n} ]"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -128,7 +128,7 @@ public virtual IActionResult FindPetsByTags([FromQuery (Name = "tags")][Required //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "[ {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}, {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n} ]"; + exampleJson = "[ {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}, {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n} ]"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -162,7 +162,7 @@ public virtual IActionResult GetPetById([FromRoute (Name = "petId")][Required]lo //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -198,7 +198,7 @@ public virtual IActionResult UpdatePet([FromBody]Pet pet) //TODO: Uncomment the next line to return response 405 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(405); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n doggie\n \n aeiou\n \n \n \n aeiou\n"; var example = exampleJson != null @@ -248,7 +248,7 @@ public virtual IActionResult UploadFile([FromRoute (Name = "petId")][Required]lo //TODO: Uncomment the next line to return response 200 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(200, default(ApiResponse)); string exampleJson = null; - exampleJson = "{\n \"code\" : 0,\n \"type\" : \"type\",\n \"message\" : \"message\"\n}"; + exampleJson = "{\r\n \"code\" : 0,\r\n \"type\" : \"type\",\r\n \"message\" : \"message\"\r\n}"; var example = exampleJson != null ? JsonConvert.DeserializeObject(exampleJson) diff --git a/samples/server/petstore/aspnetcore-8.0-pocoModels/src/Org.OpenAPITools/Controllers/StoreApi.cs b/samples/server/petstore/aspnetcore-8.0-pocoModels/src/Org.OpenAPITools/Controllers/StoreApi.cs index b925426c761d..c57b5fb3bd16 100644 --- a/samples/server/petstore/aspnetcore-8.0-pocoModels/src/Org.OpenAPITools/Controllers/StoreApi.cs +++ b/samples/server/petstore/aspnetcore-8.0-pocoModels/src/Org.OpenAPITools/Controllers/StoreApi.cs @@ -98,7 +98,7 @@ public virtual IActionResult GetOrderById([FromRoute (Name = "orderId")][Require //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"petId\" : 6,\n \"quantity\" : 1,\n \"id\" : 0,\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\n \"complete\" : false,\n \"status\" : \"placed\"\n}"; + exampleJson = "{\r\n \"petId\" : 6,\r\n \"quantity\" : 1,\r\n \"id\" : 0,\r\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\r\n \"complete\" : false,\r\n \"status\" : \"placed\"\r\n}"; exampleJson = "\n 123456789\n 123456789\n 123\n 2000-01-23T04:56:07.000Z\n aeiou\n true\n"; var example = exampleJson != null @@ -128,7 +128,7 @@ public virtual IActionResult PlaceOrder([FromBody]Order order) //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "{\n \"petId\" : 6,\n \"quantity\" : 1,\n \"id\" : 0,\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\n \"complete\" : false,\n \"status\" : \"placed\"\n}"; + exampleJson = "{\r\n \"petId\" : 6,\r\n \"quantity\" : 1,\r\n \"id\" : 0,\r\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\r\n \"complete\" : false,\r\n \"status\" : \"placed\"\r\n}"; exampleJson = "\n 123456789\n 123456789\n 123\n 2000-01-23T04:56:07.000Z\n aeiou\n true\n"; var example = exampleJson != null diff --git a/samples/server/petstore/aspnetcore-8.0-pocoModels/src/Org.OpenAPITools/Controllers/UserApi.cs b/samples/server/petstore/aspnetcore-8.0-pocoModels/src/Org.OpenAPITools/Controllers/UserApi.cs index 6d7094c81a9d..3277ae43fcfd 100644 --- a/samples/server/petstore/aspnetcore-8.0-pocoModels/src/Org.OpenAPITools/Controllers/UserApi.cs +++ b/samples/server/petstore/aspnetcore-8.0-pocoModels/src/Org.OpenAPITools/Controllers/UserApi.cs @@ -134,7 +134,7 @@ public virtual IActionResult GetUserByName([FromRoute (Name = "username")][Requi //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"firstName\" : \"firstName\",\n \"lastName\" : \"lastName\",\n \"password\" : \"password\",\n \"userStatus\" : 6,\n \"phone\" : \"phone\",\n \"id\" : 0,\n \"email\" : \"email\",\n \"username\" : \"username\"\n}"; + exampleJson = "{\r\n \"firstName\" : \"firstName\",\r\n \"lastName\" : \"lastName\",\r\n \"password\" : \"password\",\r\n \"userStatus\" : 6,\r\n \"phone\" : \"phone\",\r\n \"id\" : 0,\r\n \"email\" : \"email\",\r\n \"username\" : \"username\"\r\n}"; exampleJson = "\n 123456789\n aeiou\n aeiou\n aeiou\n aeiou\n aeiou\n aeiou\n 123\n"; var example = exampleJson != null diff --git a/samples/server/petstore/aspnetcore-8.0-project4Models/src/Org.OpenAPITools/Controllers/FakeApi.cs b/samples/server/petstore/aspnetcore-8.0-project4Models/src/Org.OpenAPITools/Controllers/FakeApi.cs index a0f2bd3b2315..eccd3a3006a6 100644 --- a/samples/server/petstore/aspnetcore-8.0-project4Models/src/Org.OpenAPITools/Controllers/FakeApi.cs +++ b/samples/server/petstore/aspnetcore-8.0-project4Models/src/Org.OpenAPITools/Controllers/FakeApi.cs @@ -43,7 +43,7 @@ public virtual IActionResult FakeNullableExampleTest() //TODO: Uncomment the next line to return response 200 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(200, default(TestNullable)); string exampleJson = null; - exampleJson = "{\n \"nullableName\" : \"nullableName\",\n \"name\" : \"name\"\n}"; + exampleJson = "{\r\n \"nullableName\" : \"nullableName\",\r\n \"name\" : \"name\"\r\n}"; var example = exampleJson != null ? JsonConvert.DeserializeObject(exampleJson) diff --git a/samples/server/petstore/aspnetcore-8.0-project4Models/src/Org.OpenAPITools/Controllers/PetApi.cs b/samples/server/petstore/aspnetcore-8.0-project4Models/src/Org.OpenAPITools/Controllers/PetApi.cs index 7dded4e0f16a..5a197da3156e 100644 --- a/samples/server/petstore/aspnetcore-8.0-project4Models/src/Org.OpenAPITools/Controllers/PetApi.cs +++ b/samples/server/petstore/aspnetcore-8.0-project4Models/src/Org.OpenAPITools/Controllers/PetApi.cs @@ -48,7 +48,7 @@ public virtual IActionResult AddPet([FromBody]Pet pet) //TODO: Uncomment the next line to return response 405 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(405); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -97,7 +97,7 @@ public virtual IActionResult FindPetsByStatus([FromQuery (Name = "status")][Requ //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "[ {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}, {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n} ]"; + exampleJson = "[ {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}, {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n} ]"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -128,7 +128,7 @@ public virtual IActionResult FindPetsByTags([FromQuery (Name = "tags")][Required //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "[ {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}, {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n} ]"; + exampleJson = "[ {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}, {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n} ]"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -162,7 +162,7 @@ public virtual IActionResult GetPetById([FromRoute (Name = "petId")][Required]lo //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -198,7 +198,7 @@ public virtual IActionResult UpdatePet([FromBody]Pet pet) //TODO: Uncomment the next line to return response 405 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(405); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n doggie\n \n aeiou\n \n \n \n aeiou\n"; var example = exampleJson != null @@ -248,7 +248,7 @@ public virtual IActionResult UploadFile([FromRoute (Name = "petId")][Required]lo //TODO: Uncomment the next line to return response 200 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(200, default(ApiResponse)); string exampleJson = null; - exampleJson = "{\n \"code\" : 0,\n \"type\" : \"type\",\n \"message\" : \"message\"\n}"; + exampleJson = "{\r\n \"code\" : 0,\r\n \"type\" : \"type\",\r\n \"message\" : \"message\"\r\n}"; var example = exampleJson != null ? JsonConvert.DeserializeObject(exampleJson) diff --git a/samples/server/petstore/aspnetcore-8.0-project4Models/src/Org.OpenAPITools/Controllers/StoreApi.cs b/samples/server/petstore/aspnetcore-8.0-project4Models/src/Org.OpenAPITools/Controllers/StoreApi.cs index b925426c761d..c57b5fb3bd16 100644 --- a/samples/server/petstore/aspnetcore-8.0-project4Models/src/Org.OpenAPITools/Controllers/StoreApi.cs +++ b/samples/server/petstore/aspnetcore-8.0-project4Models/src/Org.OpenAPITools/Controllers/StoreApi.cs @@ -98,7 +98,7 @@ public virtual IActionResult GetOrderById([FromRoute (Name = "orderId")][Require //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"petId\" : 6,\n \"quantity\" : 1,\n \"id\" : 0,\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\n \"complete\" : false,\n \"status\" : \"placed\"\n}"; + exampleJson = "{\r\n \"petId\" : 6,\r\n \"quantity\" : 1,\r\n \"id\" : 0,\r\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\r\n \"complete\" : false,\r\n \"status\" : \"placed\"\r\n}"; exampleJson = "\n 123456789\n 123456789\n 123\n 2000-01-23T04:56:07.000Z\n aeiou\n true\n"; var example = exampleJson != null @@ -128,7 +128,7 @@ public virtual IActionResult PlaceOrder([FromBody]Order order) //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "{\n \"petId\" : 6,\n \"quantity\" : 1,\n \"id\" : 0,\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\n \"complete\" : false,\n \"status\" : \"placed\"\n}"; + exampleJson = "{\r\n \"petId\" : 6,\r\n \"quantity\" : 1,\r\n \"id\" : 0,\r\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\r\n \"complete\" : false,\r\n \"status\" : \"placed\"\r\n}"; exampleJson = "\n 123456789\n 123456789\n 123\n 2000-01-23T04:56:07.000Z\n aeiou\n true\n"; var example = exampleJson != null diff --git a/samples/server/petstore/aspnetcore-8.0-project4Models/src/Org.OpenAPITools/Controllers/UserApi.cs b/samples/server/petstore/aspnetcore-8.0-project4Models/src/Org.OpenAPITools/Controllers/UserApi.cs index 6d7094c81a9d..3277ae43fcfd 100644 --- a/samples/server/petstore/aspnetcore-8.0-project4Models/src/Org.OpenAPITools/Controllers/UserApi.cs +++ b/samples/server/petstore/aspnetcore-8.0-project4Models/src/Org.OpenAPITools/Controllers/UserApi.cs @@ -134,7 +134,7 @@ public virtual IActionResult GetUserByName([FromRoute (Name = "username")][Requi //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"firstName\" : \"firstName\",\n \"lastName\" : \"lastName\",\n \"password\" : \"password\",\n \"userStatus\" : 6,\n \"phone\" : \"phone\",\n \"id\" : 0,\n \"email\" : \"email\",\n \"username\" : \"username\"\n}"; + exampleJson = "{\r\n \"firstName\" : \"firstName\",\r\n \"lastName\" : \"lastName\",\r\n \"password\" : \"password\",\r\n \"userStatus\" : 6,\r\n \"phone\" : \"phone\",\r\n \"id\" : 0,\r\n \"email\" : \"email\",\r\n \"username\" : \"username\"\r\n}"; exampleJson = "\n 123456789\n aeiou\n aeiou\n aeiou\n aeiou\n aeiou\n aeiou\n 123\n"; var example = exampleJson != null diff --git a/samples/server/petstore/aspnetcore-8.0/src/Org.OpenAPITools/Controllers/FakeApi.cs b/samples/server/petstore/aspnetcore-8.0/src/Org.OpenAPITools/Controllers/FakeApi.cs index a0f2bd3b2315..eccd3a3006a6 100644 --- a/samples/server/petstore/aspnetcore-8.0/src/Org.OpenAPITools/Controllers/FakeApi.cs +++ b/samples/server/petstore/aspnetcore-8.0/src/Org.OpenAPITools/Controllers/FakeApi.cs @@ -43,7 +43,7 @@ public virtual IActionResult FakeNullableExampleTest() //TODO: Uncomment the next line to return response 200 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(200, default(TestNullable)); string exampleJson = null; - exampleJson = "{\n \"nullableName\" : \"nullableName\",\n \"name\" : \"name\"\n}"; + exampleJson = "{\r\n \"nullableName\" : \"nullableName\",\r\n \"name\" : \"name\"\r\n}"; var example = exampleJson != null ? JsonConvert.DeserializeObject(exampleJson) diff --git a/samples/server/petstore/aspnetcore-8.0/src/Org.OpenAPITools/Controllers/PetApi.cs b/samples/server/petstore/aspnetcore-8.0/src/Org.OpenAPITools/Controllers/PetApi.cs index 7dded4e0f16a..5a197da3156e 100644 --- a/samples/server/petstore/aspnetcore-8.0/src/Org.OpenAPITools/Controllers/PetApi.cs +++ b/samples/server/petstore/aspnetcore-8.0/src/Org.OpenAPITools/Controllers/PetApi.cs @@ -48,7 +48,7 @@ public virtual IActionResult AddPet([FromBody]Pet pet) //TODO: Uncomment the next line to return response 405 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(405); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -97,7 +97,7 @@ public virtual IActionResult FindPetsByStatus([FromQuery (Name = "status")][Requ //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "[ {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}, {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n} ]"; + exampleJson = "[ {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}, {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n} ]"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -128,7 +128,7 @@ public virtual IActionResult FindPetsByTags([FromQuery (Name = "tags")][Required //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "[ {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}, {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n} ]"; + exampleJson = "[ {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}, {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n} ]"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -162,7 +162,7 @@ public virtual IActionResult GetPetById([FromRoute (Name = "petId")][Required]lo //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -198,7 +198,7 @@ public virtual IActionResult UpdatePet([FromBody]Pet pet) //TODO: Uncomment the next line to return response 405 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(405); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n doggie\n \n aeiou\n \n \n \n aeiou\n"; var example = exampleJson != null @@ -248,7 +248,7 @@ public virtual IActionResult UploadFile([FromRoute (Name = "petId")][Required]lo //TODO: Uncomment the next line to return response 200 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(200, default(ApiResponse)); string exampleJson = null; - exampleJson = "{\n \"code\" : 0,\n \"type\" : \"type\",\n \"message\" : \"message\"\n}"; + exampleJson = "{\r\n \"code\" : 0,\r\n \"type\" : \"type\",\r\n \"message\" : \"message\"\r\n}"; var example = exampleJson != null ? JsonConvert.DeserializeObject(exampleJson) diff --git a/samples/server/petstore/aspnetcore-8.0/src/Org.OpenAPITools/Controllers/StoreApi.cs b/samples/server/petstore/aspnetcore-8.0/src/Org.OpenAPITools/Controllers/StoreApi.cs index b925426c761d..c57b5fb3bd16 100644 --- a/samples/server/petstore/aspnetcore-8.0/src/Org.OpenAPITools/Controllers/StoreApi.cs +++ b/samples/server/petstore/aspnetcore-8.0/src/Org.OpenAPITools/Controllers/StoreApi.cs @@ -98,7 +98,7 @@ public virtual IActionResult GetOrderById([FromRoute (Name = "orderId")][Require //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"petId\" : 6,\n \"quantity\" : 1,\n \"id\" : 0,\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\n \"complete\" : false,\n \"status\" : \"placed\"\n}"; + exampleJson = "{\r\n \"petId\" : 6,\r\n \"quantity\" : 1,\r\n \"id\" : 0,\r\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\r\n \"complete\" : false,\r\n \"status\" : \"placed\"\r\n}"; exampleJson = "\n 123456789\n 123456789\n 123\n 2000-01-23T04:56:07.000Z\n aeiou\n true\n"; var example = exampleJson != null @@ -128,7 +128,7 @@ public virtual IActionResult PlaceOrder([FromBody]Order order) //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "{\n \"petId\" : 6,\n \"quantity\" : 1,\n \"id\" : 0,\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\n \"complete\" : false,\n \"status\" : \"placed\"\n}"; + exampleJson = "{\r\n \"petId\" : 6,\r\n \"quantity\" : 1,\r\n \"id\" : 0,\r\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\r\n \"complete\" : false,\r\n \"status\" : \"placed\"\r\n}"; exampleJson = "\n 123456789\n 123456789\n 123\n 2000-01-23T04:56:07.000Z\n aeiou\n true\n"; var example = exampleJson != null diff --git a/samples/server/petstore/aspnetcore-8.0/src/Org.OpenAPITools/Controllers/UserApi.cs b/samples/server/petstore/aspnetcore-8.0/src/Org.OpenAPITools/Controllers/UserApi.cs index 6d7094c81a9d..3277ae43fcfd 100644 --- a/samples/server/petstore/aspnetcore-8.0/src/Org.OpenAPITools/Controllers/UserApi.cs +++ b/samples/server/petstore/aspnetcore-8.0/src/Org.OpenAPITools/Controllers/UserApi.cs @@ -134,7 +134,7 @@ public virtual IActionResult GetUserByName([FromRoute (Name = "username")][Requi //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"firstName\" : \"firstName\",\n \"lastName\" : \"lastName\",\n \"password\" : \"password\",\n \"userStatus\" : 6,\n \"phone\" : \"phone\",\n \"id\" : 0,\n \"email\" : \"email\",\n \"username\" : \"username\"\n}"; + exampleJson = "{\r\n \"firstName\" : \"firstName\",\r\n \"lastName\" : \"lastName\",\r\n \"password\" : \"password\",\r\n \"userStatus\" : 6,\r\n \"phone\" : \"phone\",\r\n \"id\" : 0,\r\n \"email\" : \"email\",\r\n \"username\" : \"username\"\r\n}"; exampleJson = "\n 123456789\n aeiou\n aeiou\n aeiou\n aeiou\n aeiou\n aeiou\n 123\n"; var example = exampleJson != null diff --git a/samples/server/petstore/aspnetcore/src/Org.OpenAPITools/Controllers/PetApi.cs b/samples/server/petstore/aspnetcore/src/Org.OpenAPITools/Controllers/PetApi.cs index 419bab14d099..562ee1b0ff43 100644 --- a/samples/server/petstore/aspnetcore/src/Org.OpenAPITools/Controllers/PetApi.cs +++ b/samples/server/petstore/aspnetcore/src/Org.OpenAPITools/Controllers/PetApi.cs @@ -86,7 +86,7 @@ public virtual IActionResult FindPetsByStatus([FromQuery (Name = "status")][Requ //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "[ {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}, {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n} ]"; + exampleJson = "[ {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}, {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n} ]"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -117,7 +117,7 @@ public virtual IActionResult FindPetsByTags([FromQuery (Name = "tags")][Required //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "[ {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}, {\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n} ]"; + exampleJson = "[ {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}, {\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n} ]"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -151,7 +151,7 @@ public virtual IActionResult GetPetById([FromRoute (Name = "petId")][Required]lo //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\n \"name\" : \"doggie\",\n \"id\" : 0,\n \"category\" : {\n \"name\" : \"name\",\n \"id\" : 6\n },\n \"tags\" : [ {\n \"name\" : \"name\",\n \"id\" : 1\n }, {\n \"name\" : \"name\",\n \"id\" : 1\n } ],\n \"status\" : \"available\"\n}"; + exampleJson = "{\r\n \"photoUrls\" : [ \"photoUrls\", \"photoUrls\" ],\r\n \"name\" : \"doggie\",\r\n \"id\" : 0,\r\n \"category\" : {\r\n \"name\" : \"name\",\r\n \"id\" : 6\r\n },\r\n \"tags\" : [ {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n }, {\r\n \"name\" : \"name\",\r\n \"id\" : 1\r\n } ],\r\n \"status\" : \"available\"\r\n}"; exampleJson = "\n 123456789\n \n 123456789\n aeiou\n \n doggie\n \n aeiou\n \n \n \n 123456789\n aeiou\n \n \n aeiou\n"; var example = exampleJson != null @@ -226,7 +226,7 @@ public virtual IActionResult UploadFile([FromRoute (Name = "petId")][Required]lo //TODO: Uncomment the next line to return response 200 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(200, default(ApiResponse)); string exampleJson = null; - exampleJson = "{\n \"code\" : 0,\n \"type\" : \"type\",\n \"message\" : \"message\"\n}"; + exampleJson = "{\r\n \"code\" : 0,\r\n \"type\" : \"type\",\r\n \"message\" : \"message\"\r\n}"; var example = exampleJson != null ? JsonConvert.DeserializeObject(exampleJson) diff --git a/samples/server/petstore/aspnetcore/src/Org.OpenAPITools/Controllers/StoreApi.cs b/samples/server/petstore/aspnetcore/src/Org.OpenAPITools/Controllers/StoreApi.cs index 8e493e399264..8dc20ddadfc4 100644 --- a/samples/server/petstore/aspnetcore/src/Org.OpenAPITools/Controllers/StoreApi.cs +++ b/samples/server/petstore/aspnetcore/src/Org.OpenAPITools/Controllers/StoreApi.cs @@ -98,7 +98,7 @@ public virtual IActionResult GetOrderById([FromRoute (Name = "orderId")][Require //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"petId\" : 6,\n \"quantity\" : 1,\n \"id\" : 0,\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\n \"complete\" : false,\n \"status\" : \"placed\"\n}"; + exampleJson = "{\r\n \"petId\" : 6,\r\n \"quantity\" : 1,\r\n \"id\" : 0,\r\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\r\n \"complete\" : false,\r\n \"status\" : \"placed\"\r\n}"; exampleJson = "\n 123456789\n 123456789\n 123\n 2000-01-23T04:56:07.000Z\n aeiou\n true\n"; var example = exampleJson != null @@ -127,7 +127,7 @@ public virtual IActionResult PlaceOrder([FromBody]Order body) //TODO: Uncomment the next line to return response 400 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(400); string exampleJson = null; - exampleJson = "{\n \"petId\" : 6,\n \"quantity\" : 1,\n \"id\" : 0,\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\n \"complete\" : false,\n \"status\" : \"placed\"\n}"; + exampleJson = "{\r\n \"petId\" : 6,\r\n \"quantity\" : 1,\r\n \"id\" : 0,\r\n \"shipDate\" : \"2000-01-23T04:56:07.000+00:00\",\r\n \"complete\" : false,\r\n \"status\" : \"placed\"\r\n}"; exampleJson = "\n 123456789\n 123456789\n 123\n 2000-01-23T04:56:07.000Z\n aeiou\n true\n"; var example = exampleJson != null diff --git a/samples/server/petstore/aspnetcore/src/Org.OpenAPITools/Controllers/UserApi.cs b/samples/server/petstore/aspnetcore/src/Org.OpenAPITools/Controllers/UserApi.cs index 6669f0418cee..d1d13530b839 100644 --- a/samples/server/petstore/aspnetcore/src/Org.OpenAPITools/Controllers/UserApi.cs +++ b/samples/server/petstore/aspnetcore/src/Org.OpenAPITools/Controllers/UserApi.cs @@ -127,7 +127,7 @@ public virtual IActionResult GetUserByName([FromRoute (Name = "username")][Requi //TODO: Uncomment the next line to return response 404 or use other options such as return this.NotFound(), return this.BadRequest(..), ... // return StatusCode(404); string exampleJson = null; - exampleJson = "{\n \"firstName\" : \"firstName\",\n \"lastName\" : \"lastName\",\n \"password\" : \"password\",\n \"userStatus\" : 6,\n \"phone\" : \"phone\",\n \"id\" : 0,\n \"email\" : \"email\",\n \"username\" : \"username\"\n}"; + exampleJson = "{\r\n \"firstName\" : \"firstName\",\r\n \"lastName\" : \"lastName\",\r\n \"password\" : \"password\",\r\n \"userStatus\" : 6,\r\n \"phone\" : \"phone\",\r\n \"id\" : 0,\r\n \"email\" : \"email\",\r\n \"username\" : \"username\"\r\n}"; exampleJson = "\n 123456789\n aeiou\n aeiou\n aeiou\n aeiou\n aeiou\n aeiou\n 123\n"; var example = exampleJson != null