diff --git a/modules/openapi-json-schema-generator/src/main/java/org/openapitools/codegen/CodegenOperation.java b/modules/openapi-json-schema-generator/src/main/java/org/openapitools/codegen/CodegenOperation.java index cb787030786..2672a1709a3 100644 --- a/modules/openapi-json-schema-generator/src/main/java/org/openapitools/codegen/CodegenOperation.java +++ b/modules/openapi-json-schema-generator/src/main/java/org/openapitools/codegen/CodegenOperation.java @@ -197,6 +197,23 @@ public boolean getAllResponsesAreErrors() { return responses.stream().allMatch(response -> response.is4xx || response.is5xx); } + /** + * @return contentTypeToOperation + * returns a map where the key is the request body content type and the value is the current CodegenOperation + * this is needed by templates when a different signature is needed for each request body content type + */ + public Map getContentTypeToOperation() { + LinkedHashMap contentTypeToOperation = new LinkedHashMap<>(); + if (bodyParam == null) { + return null; + } + LinkedHashMap content = bodyParam.getContent(); + for (String contentType: content.keySet()) { + contentTypeToOperation.put(contentType, this); + } + return contentTypeToOperation; + } + /** * Check if there's at least one vendor extension * diff --git a/modules/openapi-json-schema-generator/src/main/resources/python/endpoint.handlebars b/modules/openapi-json-schema-generator/src/main/resources/python/endpoint.handlebars index 03cbafd018f..43d2aafb2d1 100644 --- a/modules/openapi-json-schema-generator/src/main/resources/python/endpoint.handlebars +++ b/modules/openapi-json-schema-generator/src/main/resources/python/endpoint.handlebars @@ -373,21 +373,29 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): +{{#if bodyParam}} + {{#each getContentTypeToOperation}} + {{> endpoint_args_baseapi_wrapper contentType=@key this=this}} + {{/each}} + {{> endpoint_args_baseapi_wrapper contentType="null" this=this}} + +{{else}} @typing.overload def _{{operationId}}_oapg( - {{> endpoint_args isOverload=true skipDeserialization="False"}} + {{> endpoint_args isOverload=true skipDeserialization="False" contentType="null"}} +{{/if}} @typing.overload def _{{operationId}}_oapg( - {{> endpoint_args isOverload=true skipDeserialization="True"}} + {{> endpoint_args isOverload=true skipDeserialization="True" contentType="null"}} @typing.overload def _{{operationId}}_oapg( - {{> endpoint_args isOverload=true skipDeserialization="null"}} + {{> endpoint_args isOverload=true skipDeserialization="null" contentType="null"}} def _{{operationId}}_oapg( - {{> endpoint_args isOverload=false skipDeserialization="null"}} + {{> endpoint_args isOverload=false skipDeserialization="null" contentType="null"}} """ {{#if summary}} {{summary}} @@ -533,20 +541,29 @@ class BaseApi(api_client.Api): class {{operationIdCamelCase}}(BaseApi): # this class is used by api classes that refer to endpoints with operationId fn names +{{#if bodyParam}} + {{#each getContentTypeToOperation}} + {{> endpoint_args_operationid_wrapper contentType=@key this=this}} + + {{/each}} + {{> endpoint_args_operationid_wrapper contentType="null" this=this}} + +{{else}} @typing.overload def {{operationId}}( - {{> endpoint_args isOverload=true skipDeserialization="False"}} + {{> endpoint_args isOverload=true skipDeserialization="False" contentType="null"}} +{{/if}} @typing.overload def {{operationId}}( - {{> endpoint_args isOverload=true skipDeserialization="True"}} + {{> endpoint_args isOverload=true skipDeserialization="True" contentType="null"}} @typing.overload def {{operationId}}( - {{> endpoint_args isOverload=true skipDeserialization="null"}} + {{> endpoint_args isOverload=true skipDeserialization="null" contentType="null"}} def {{operationId}}( - {{> endpoint_args isOverload=false skipDeserialization="null"}} + {{> endpoint_args isOverload=false skipDeserialization="null" contentType="null"}} return self._{{operationId}}_oapg( {{> endpoint_args_passed }} ) @@ -555,20 +572,29 @@ class {{operationIdCamelCase}}(BaseApi): class ApiFor{{httpMethod}}(BaseApi): # this class is used by api classes that refer to endpoints by path and http method names +{{#if bodyParam}} + {{#each getContentTypeToOperation}} + {{> endpoint_args_httpmethod_wrapper contentType=@key this=this}} + + {{/each}} + {{> endpoint_args_httpmethod_wrapper contentType="null" this=this}} + +{{else}} @typing.overload def {{httpMethod}}( - {{> endpoint_args isOverload=true skipDeserialization="False"}} + {{> endpoint_args isOverload=true skipDeserialization="False" contentType="null"}} +{{/if}} @typing.overload def {{httpMethod}}( - {{> endpoint_args isOverload=true skipDeserialization="True"}} + {{> endpoint_args isOverload=true skipDeserialization="True" contentType="null"}} @typing.overload def {{httpMethod}}( - {{> endpoint_args isOverload=true skipDeserialization="null"}} + {{> endpoint_args isOverload=true skipDeserialization="null" contentType="null"}} def {{httpMethod}}( - {{> endpoint_args isOverload=false skipDeserialization="null"}} + {{> endpoint_args isOverload=false skipDeserialization="null" contentType="null"}} return self._{{operationId}}_oapg( {{> endpoint_args_passed }} ) diff --git a/modules/openapi-json-schema-generator/src/main/resources/python/endpoint_args.handlebars b/modules/openapi-json-schema-generator/src/main/resources/python/endpoint_args.handlebars index 306a507f2a9..bff216a72fb 100644 --- a/modules/openapi-json-schema-generator/src/main/resources/python/endpoint_args.handlebars +++ b/modules/openapi-json-schema-generator/src/main/resources/python/endpoint_args.handlebars @@ -2,21 +2,75 @@ {{#if bodyParam}} {{#if bodyParam.required}} {{#with bodyParam}} - body: typing.Union[{{#each content}}{{#with this.schema}}{{baseName}},{{> model_templates/schema_python_types }}{{/with}}{{/each}}], + {{#eq ../contentType "null"}} + body: typing.Union[{{#each getContent}}{{#with this.schema}}{{baseName}},{{> model_templates/schema_python_types }}{{/with}}{{/each}}], + {{else}} + body: typing.Union[{{#each getContent}}{{#eq @key ../../contentType }}{{#with this.schema}}{{baseName}},{{> model_templates/schema_python_types }}{{/with}}{{/eq}}{{/each}}], + {{/eq}} {{/with}} {{#if isOverload}} {{#eq skipDeserialization "True"}} skip_deserialization: typing_extensions.Literal[True], {{/eq}} + {{#neq contentType "null"}} + {{#with bodyParam}} + {{#each content}} + {{#eq @key ../../contentType}} + {{#if @first}} + content_type: typing_extensions.Literal["{{{@key}}}"] = ..., + {{else}} + content_type: typing_extensions.Literal["{{{@key}}}"], + {{/if}} + {{/eq}} + {{/each}} + {{/with}} + {{else}} + content_type: str = ..., + {{/neq}} + {{else}} + {{#with bodyParam}} + {{#each getContent}} + {{#if @first}} + content_type: str = '{{{@key}}}', + {{/if}} + {{/each}} + {{/with}} {{/if}} {{else}} {{#if isOverload}} {{#eq skipDeserialization "True"}} skip_deserialization: typing_extensions.Literal[True], {{/eq}} + {{#neq contentType "null"}} + {{#with bodyParam}} + {{#each getContent}} + {{#eq @key ../../contentType}} + {{#if @first}} + content_type: typing_extensions.Literal["{{{@key}}}"] = ..., + {{else}} + content_type: typing_extensions.Literal["{{{@key}}}"], + {{/if}} + {{/eq}} + {{/each}} + {{/with}} + {{else}} + content_type: str = ..., + {{/neq}} + {{else}} + {{#with bodyParam}} + {{#each getContent}} + {{#if @first}} + content_type: str = '{{{@key}}}', + {{/if}} + {{/each}} + {{/with}} {{/if}} {{#with bodyParam}} - body: typing.Union[{{#each content}}{{#with this.schema}}{{baseName}}, {{> model_templates/schema_python_types }}{{/with}}{{/each}}schemas.Unset] = schemas.unset, + {{#eq ../contentType "null"}} + body: typing.Union[{{#each getContent}}{{#with this.schema}}{{baseName}}, {{> model_templates/schema_python_types }}{{/with}}{{/each}}schemas.Unset] = schemas.unset, + {{else}} + body: typing.Union[{{#each getContent}}{{#eq @key ../../contentType }}{{#with this.schema}}{{baseName}}, {{> model_templates/schema_python_types }}{{/with}}{{/eq}}{{/each}}schemas.Unset] = schemas.unset, + {{/eq}} {{/with}} {{/if}} {{/if}} @@ -32,13 +86,6 @@ {{#if cookieParams}} cookie_params: RequestCookieParams = frozendict.frozendict(), {{/if}} -{{#with bodyParam}} - {{#each content}} - {{#if @first}} - content_type: str = '{{{@key}}}', - {{/if}} - {{/each}} -{{/with}} {{#if produces}} accept_content_types: typing.Tuple[str] = _all_accept_content_types, {{/if}} diff --git a/modules/openapi-json-schema-generator/src/main/resources/python/endpoint_args_baseapi_wrapper.handlebars b/modules/openapi-json-schema-generator/src/main/resources/python/endpoint_args_baseapi_wrapper.handlebars new file mode 100644 index 00000000000..cd73d02e9c8 --- /dev/null +++ b/modules/openapi-json-schema-generator/src/main/resources/python/endpoint_args_baseapi_wrapper.handlebars @@ -0,0 +1,5 @@ +@typing.overload +{{#with this}} +def _{{operationId}}_oapg( +{{> endpoint_args isOverload=true skipDeserialization="False" contentType=contentType}} +{{/with}} \ No newline at end of file diff --git a/modules/openapi-json-schema-generator/src/main/resources/python/endpoint_args_httpmethod_wrapper.handlebars b/modules/openapi-json-schema-generator/src/main/resources/python/endpoint_args_httpmethod_wrapper.handlebars new file mode 100644 index 00000000000..f28bd735a54 --- /dev/null +++ b/modules/openapi-json-schema-generator/src/main/resources/python/endpoint_args_httpmethod_wrapper.handlebars @@ -0,0 +1,5 @@ +@typing.overload +{{#with this}} +def {{httpMethod}}( +{{> endpoint_args isOverload=true skipDeserialization="False" contentType=contentType}} +{{/with}} \ No newline at end of file diff --git a/modules/openapi-json-schema-generator/src/main/resources/python/endpoint_args_operationid_wrapper.handlebars b/modules/openapi-json-schema-generator/src/main/resources/python/endpoint_args_operationid_wrapper.handlebars new file mode 100644 index 00000000000..47b5ea64ca5 --- /dev/null +++ b/modules/openapi-json-schema-generator/src/main/resources/python/endpoint_args_operationid_wrapper.handlebars @@ -0,0 +1,5 @@ +@typing.overload +{{#with this}} +def {{operationId}}( +{{> endpoint_args isOverload=true skipDeserialization="False" contentType=contentType}} +{{/with}} \ No newline at end of file diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_allows_a_schema_which_should_validate_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_allows_a_schema_which_should_validate_request_body/post.py index 4cb91d3d774..51f747166d0 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_allows_a_schema_which_should_validate_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_allows_a_schema_which_should_validate_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_additionalproperties_allows_a_schema_which_should_validate_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_additionalproperties_allows_a_schema_which_should_validate_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_additionalproperties_allows_a_schema_which_should_validate_request_bod ApiResponseFor200, ]: ... + @typing.overload def _post_additionalproperties_allows_a_schema_which_should_validate_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_additionalproperties_allows_a_schema_which_should_validate_request_bod def _post_additionalproperties_allows_a_schema_which_should_validate_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostAdditionalpropertiesAllowsASchemaWhichShouldValidateRequestBody(BaseAp def post_additionalproperties_allows_a_schema_which_should_validate_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_additionalproperties_allows_a_schema_which_should_validate_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_additionalproperties_allows_a_schema_which_should_validate_request_body ApiResponseFor200, ]: ... + @typing.overload def post_additionalproperties_allows_a_schema_which_should_validate_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_additionalproperties_allows_a_schema_which_should_validate_request_body def post_additionalproperties_allows_a_schema_which_should_validate_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_allows_a_schema_which_should_validate_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_allows_a_schema_which_should_validate_request_body/post.pyi index 27842691aac..fb323cc1c83 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_allows_a_schema_which_should_validate_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_allows_a_schema_which_should_validate_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_additionalproperties_allows_a_schema_which_should_validate_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_additionalproperties_allows_a_schema_which_should_validate_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_additionalproperties_allows_a_schema_which_should_validate_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_additionalproperties_allows_a_schema_which_should_validate_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostAdditionalpropertiesAllowsASchemaWhichShouldValidateRequestBody(BaseAp def post_additionalproperties_allows_a_schema_which_should_validate_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_additionalproperties_allows_a_schema_which_should_validate_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostAdditionalpropertiesAllowsASchemaWhichShouldValidateRequestBody(BaseAp ApiResponseFor200, ]: ... + @typing.overload def post_additionalproperties_allows_a_schema_which_should_validate_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostAdditionalpropertiesAllowsASchemaWhichShouldValidateRequestBody(BaseAp def post_additionalproperties_allows_a_schema_which_should_validate_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_are_allowed_by_default_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_are_allowed_by_default_request_body/post.py index c81991bc601..7be02743e60 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_are_allowed_by_default_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_are_allowed_by_default_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_additionalproperties_are_allowed_by_default_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_additionalproperties_are_allowed_by_default_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_additionalproperties_are_allowed_by_default_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_additionalproperties_are_allowed_by_default_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_additionalproperties_are_allowed_by_default_request_body_oapg( def _post_additionalproperties_are_allowed_by_default_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostAdditionalpropertiesAreAllowedByDefaultRequestBody(BaseApi): def post_additionalproperties_are_allowed_by_default_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_additionalproperties_are_allowed_by_default_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_additionalproperties_are_allowed_by_default_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_additionalproperties_are_allowed_by_default_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_additionalproperties_are_allowed_by_default_request_body( def post_additionalproperties_are_allowed_by_default_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_are_allowed_by_default_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_are_allowed_by_default_request_body/post.pyi index f8109fdbc55..8155ff2963b 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_are_allowed_by_default_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_are_allowed_by_default_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_additionalproperties_are_allowed_by_default_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_additionalproperties_are_allowed_by_default_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_additionalproperties_are_allowed_by_default_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_additionalproperties_are_allowed_by_default_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostAdditionalpropertiesAreAllowedByDefaultRequestBody(BaseApi): def post_additionalproperties_are_allowed_by_default_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_additionalproperties_are_allowed_by_default_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostAdditionalpropertiesAreAllowedByDefaultRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_additionalproperties_are_allowed_by_default_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostAdditionalpropertiesAreAllowedByDefaultRequestBody(BaseApi): def post_additionalproperties_are_allowed_by_default_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_can_exist_by_itself_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_can_exist_by_itself_request_body/post.py index 3a8ae2c6350..f561016356e 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_can_exist_by_itself_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_can_exist_by_itself_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_additionalproperties_can_exist_by_itself_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_additionalproperties_can_exist_by_itself_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_additionalproperties_can_exist_by_itself_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_additionalproperties_can_exist_by_itself_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_additionalproperties_can_exist_by_itself_request_body_oapg( def _post_additionalproperties_can_exist_by_itself_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostAdditionalpropertiesCanExistByItselfRequestBody(BaseApi): def post_additionalproperties_can_exist_by_itself_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_additionalproperties_can_exist_by_itself_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_additionalproperties_can_exist_by_itself_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_additionalproperties_can_exist_by_itself_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_additionalproperties_can_exist_by_itself_request_body( def post_additionalproperties_can_exist_by_itself_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_can_exist_by_itself_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_can_exist_by_itself_request_body/post.pyi index f05dec30b78..6ba0464fbda 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_can_exist_by_itself_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_can_exist_by_itself_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_additionalproperties_can_exist_by_itself_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_additionalproperties_can_exist_by_itself_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_additionalproperties_can_exist_by_itself_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_additionalproperties_can_exist_by_itself_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostAdditionalpropertiesCanExistByItselfRequestBody(BaseApi): def post_additionalproperties_can_exist_by_itself_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_additionalproperties_can_exist_by_itself_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostAdditionalpropertiesCanExistByItselfRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_additionalproperties_can_exist_by_itself_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostAdditionalpropertiesCanExistByItselfRequestBody(BaseApi): def post_additionalproperties_can_exist_by_itself_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_should_not_look_in_applicators_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_should_not_look_in_applicators_request_body/post.py index 1092f071a34..0e3ae3974b9 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_should_not_look_in_applicators_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_should_not_look_in_applicators_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_additionalproperties_should_not_look_in_applicators_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_additionalproperties_should_not_look_in_applicators_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_additionalproperties_should_not_look_in_applicators_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_additionalproperties_should_not_look_in_applicators_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_additionalproperties_should_not_look_in_applicators_request_body_oapg( def _post_additionalproperties_should_not_look_in_applicators_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostAdditionalpropertiesShouldNotLookInApplicatorsRequestBody(BaseApi): def post_additionalproperties_should_not_look_in_applicators_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_additionalproperties_should_not_look_in_applicators_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_additionalproperties_should_not_look_in_applicators_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_additionalproperties_should_not_look_in_applicators_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_additionalproperties_should_not_look_in_applicators_request_body( def post_additionalproperties_should_not_look_in_applicators_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_should_not_look_in_applicators_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_should_not_look_in_applicators_request_body/post.pyi index 94ad8c0eac4..fea43428f8b 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_should_not_look_in_applicators_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_additionalproperties_should_not_look_in_applicators_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_additionalproperties_should_not_look_in_applicators_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_additionalproperties_should_not_look_in_applicators_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_additionalproperties_should_not_look_in_applicators_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_additionalproperties_should_not_look_in_applicators_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostAdditionalpropertiesShouldNotLookInApplicatorsRequestBody(BaseApi): def post_additionalproperties_should_not_look_in_applicators_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_additionalproperties_should_not_look_in_applicators_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostAdditionalpropertiesShouldNotLookInApplicatorsRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_additionalproperties_should_not_look_in_applicators_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostAdditionalpropertiesShouldNotLookInApplicatorsRequestBody(BaseApi): def post_additionalproperties_should_not_look_in_applicators_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_combined_with_anyof_oneof_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_combined_with_anyof_oneof_request_body/post.py index 56cf0d553d6..053e2d964a8 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_combined_with_anyof_oneof_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_combined_with_anyof_oneof_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_allof_combined_with_anyof_oneof_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_allof_combined_with_anyof_oneof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_allof_combined_with_anyof_oneof_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_allof_combined_with_anyof_oneof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_allof_combined_with_anyof_oneof_request_body_oapg( def _post_allof_combined_with_anyof_oneof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostAllofCombinedWithAnyofOneofRequestBody(BaseApi): def post_allof_combined_with_anyof_oneof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_allof_combined_with_anyof_oneof_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_allof_combined_with_anyof_oneof_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_allof_combined_with_anyof_oneof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_allof_combined_with_anyof_oneof_request_body( def post_allof_combined_with_anyof_oneof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_combined_with_anyof_oneof_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_combined_with_anyof_oneof_request_body/post.pyi index 124c2af4fe1..e62508b3e27 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_combined_with_anyof_oneof_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_combined_with_anyof_oneof_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_allof_combined_with_anyof_oneof_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_allof_combined_with_anyof_oneof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_allof_combined_with_anyof_oneof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_allof_combined_with_anyof_oneof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostAllofCombinedWithAnyofOneofRequestBody(BaseApi): def post_allof_combined_with_anyof_oneof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_allof_combined_with_anyof_oneof_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostAllofCombinedWithAnyofOneofRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_allof_combined_with_anyof_oneof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostAllofCombinedWithAnyofOneofRequestBody(BaseApi): def post_allof_combined_with_anyof_oneof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_request_body/post.py index 4eb7aeb807e..89a3a940196 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_allof_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_allof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_allof_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_allof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_allof_request_body_oapg( def _post_allof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostAllofRequestBody(BaseApi): def post_allof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_allof_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_allof_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_allof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_allof_request_body( def post_allof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_request_body/post.pyi index a0a918e51c1..4deddd781e7 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_allof_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_allof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_allof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_allof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostAllofRequestBody(BaseApi): def post_allof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_allof_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostAllofRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_allof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostAllofRequestBody(BaseApi): def post_allof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_simple_types_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_simple_types_request_body/post.py index 5b7ae1335b7..5bc90d06c4c 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_simple_types_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_simple_types_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_allof_simple_types_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_allof_simple_types_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_allof_simple_types_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_allof_simple_types_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_allof_simple_types_request_body_oapg( def _post_allof_simple_types_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostAllofSimpleTypesRequestBody(BaseApi): def post_allof_simple_types_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_allof_simple_types_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_allof_simple_types_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_allof_simple_types_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_allof_simple_types_request_body( def post_allof_simple_types_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_simple_types_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_simple_types_request_body/post.pyi index afa98972037..f334d8eeb46 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_simple_types_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_simple_types_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_allof_simple_types_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_allof_simple_types_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_allof_simple_types_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_allof_simple_types_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostAllofSimpleTypesRequestBody(BaseApi): def post_allof_simple_types_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_allof_simple_types_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostAllofSimpleTypesRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_allof_simple_types_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostAllofSimpleTypesRequestBody(BaseApi): def post_allof_simple_types_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_base_schema_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_base_schema_request_body/post.py index 3806907878c..0af6bbed3ee 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_base_schema_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_base_schema_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_allof_with_base_schema_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_allof_with_base_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_allof_with_base_schema_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_allof_with_base_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_allof_with_base_schema_request_body_oapg( def _post_allof_with_base_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostAllofWithBaseSchemaRequestBody(BaseApi): def post_allof_with_base_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_allof_with_base_schema_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_allof_with_base_schema_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_allof_with_base_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_allof_with_base_schema_request_body( def post_allof_with_base_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_base_schema_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_base_schema_request_body/post.pyi index 5b1b10197b6..b973fab5af3 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_base_schema_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_base_schema_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_allof_with_base_schema_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_allof_with_base_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_allof_with_base_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_allof_with_base_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostAllofWithBaseSchemaRequestBody(BaseApi): def post_allof_with_base_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_allof_with_base_schema_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostAllofWithBaseSchemaRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_allof_with_base_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostAllofWithBaseSchemaRequestBody(BaseApi): def post_allof_with_base_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_one_empty_schema_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_one_empty_schema_request_body/post.py index 412803c6726..05980415518 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_one_empty_schema_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_one_empty_schema_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_allof_with_one_empty_schema_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_allof_with_one_empty_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_allof_with_one_empty_schema_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_allof_with_one_empty_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_allof_with_one_empty_schema_request_body_oapg( def _post_allof_with_one_empty_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostAllofWithOneEmptySchemaRequestBody(BaseApi): def post_allof_with_one_empty_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_allof_with_one_empty_schema_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_allof_with_one_empty_schema_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_allof_with_one_empty_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_allof_with_one_empty_schema_request_body( def post_allof_with_one_empty_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_one_empty_schema_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_one_empty_schema_request_body/post.pyi index 7eac5497ac9..19358a62aea 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_one_empty_schema_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_one_empty_schema_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_allof_with_one_empty_schema_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_allof_with_one_empty_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_allof_with_one_empty_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_allof_with_one_empty_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostAllofWithOneEmptySchemaRequestBody(BaseApi): def post_allof_with_one_empty_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_allof_with_one_empty_schema_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostAllofWithOneEmptySchemaRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_allof_with_one_empty_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostAllofWithOneEmptySchemaRequestBody(BaseApi): def post_allof_with_one_empty_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_the_first_empty_schema_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_the_first_empty_schema_request_body/post.py index 19c821583ea..3d2e11c3469 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_the_first_empty_schema_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_the_first_empty_schema_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_allof_with_the_first_empty_schema_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_allof_with_the_first_empty_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_allof_with_the_first_empty_schema_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_allof_with_the_first_empty_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_allof_with_the_first_empty_schema_request_body_oapg( def _post_allof_with_the_first_empty_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostAllofWithTheFirstEmptySchemaRequestBody(BaseApi): def post_allof_with_the_first_empty_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_allof_with_the_first_empty_schema_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_allof_with_the_first_empty_schema_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_allof_with_the_first_empty_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_allof_with_the_first_empty_schema_request_body( def post_allof_with_the_first_empty_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_the_first_empty_schema_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_the_first_empty_schema_request_body/post.pyi index 7b9bdc283cc..9094994b1f1 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_the_first_empty_schema_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_the_first_empty_schema_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_allof_with_the_first_empty_schema_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_allof_with_the_first_empty_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_allof_with_the_first_empty_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_allof_with_the_first_empty_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostAllofWithTheFirstEmptySchemaRequestBody(BaseApi): def post_allof_with_the_first_empty_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_allof_with_the_first_empty_schema_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostAllofWithTheFirstEmptySchemaRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_allof_with_the_first_empty_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostAllofWithTheFirstEmptySchemaRequestBody(BaseApi): def post_allof_with_the_first_empty_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_the_last_empty_schema_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_the_last_empty_schema_request_body/post.py index a2d33c3ca37..427873e4714 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_the_last_empty_schema_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_the_last_empty_schema_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_allof_with_the_last_empty_schema_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_allof_with_the_last_empty_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_allof_with_the_last_empty_schema_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_allof_with_the_last_empty_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_allof_with_the_last_empty_schema_request_body_oapg( def _post_allof_with_the_last_empty_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostAllofWithTheLastEmptySchemaRequestBody(BaseApi): def post_allof_with_the_last_empty_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_allof_with_the_last_empty_schema_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_allof_with_the_last_empty_schema_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_allof_with_the_last_empty_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_allof_with_the_last_empty_schema_request_body( def post_allof_with_the_last_empty_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_the_last_empty_schema_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_the_last_empty_schema_request_body/post.pyi index a864c3918b8..fa64bb7f00e 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_the_last_empty_schema_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_the_last_empty_schema_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_allof_with_the_last_empty_schema_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_allof_with_the_last_empty_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_allof_with_the_last_empty_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_allof_with_the_last_empty_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostAllofWithTheLastEmptySchemaRequestBody(BaseApi): def post_allof_with_the_last_empty_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_allof_with_the_last_empty_schema_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostAllofWithTheLastEmptySchemaRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_allof_with_the_last_empty_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostAllofWithTheLastEmptySchemaRequestBody(BaseApi): def post_allof_with_the_last_empty_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_two_empty_schemas_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_two_empty_schemas_request_body/post.py index ba21d6b1ed5..c47e5a94113 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_two_empty_schemas_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_two_empty_schemas_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_allof_with_two_empty_schemas_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_allof_with_two_empty_schemas_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_allof_with_two_empty_schemas_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_allof_with_two_empty_schemas_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_allof_with_two_empty_schemas_request_body_oapg( def _post_allof_with_two_empty_schemas_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostAllofWithTwoEmptySchemasRequestBody(BaseApi): def post_allof_with_two_empty_schemas_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_allof_with_two_empty_schemas_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_allof_with_two_empty_schemas_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_allof_with_two_empty_schemas_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_allof_with_two_empty_schemas_request_body( def post_allof_with_two_empty_schemas_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_two_empty_schemas_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_two_empty_schemas_request_body/post.pyi index a70e4100336..3f4116de0f3 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_two_empty_schemas_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_allof_with_two_empty_schemas_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_allof_with_two_empty_schemas_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_allof_with_two_empty_schemas_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_allof_with_two_empty_schemas_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_allof_with_two_empty_schemas_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostAllofWithTwoEmptySchemasRequestBody(BaseApi): def post_allof_with_two_empty_schemas_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_allof_with_two_empty_schemas_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostAllofWithTwoEmptySchemasRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_allof_with_two_empty_schemas_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostAllofWithTwoEmptySchemasRequestBody(BaseApi): def post_allof_with_two_empty_schemas_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_complex_types_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_complex_types_request_body/post.py index 1c4b328dcc1..bc529f7e117 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_complex_types_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_complex_types_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_anyof_complex_types_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_anyof_complex_types_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_anyof_complex_types_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_anyof_complex_types_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_anyof_complex_types_request_body_oapg( def _post_anyof_complex_types_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostAnyofComplexTypesRequestBody(BaseApi): def post_anyof_complex_types_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_anyof_complex_types_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_anyof_complex_types_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_anyof_complex_types_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_anyof_complex_types_request_body( def post_anyof_complex_types_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_complex_types_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_complex_types_request_body/post.pyi index e2841a2bd53..8b1ea8f8ca4 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_complex_types_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_complex_types_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_anyof_complex_types_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_anyof_complex_types_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_anyof_complex_types_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_anyof_complex_types_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostAnyofComplexTypesRequestBody(BaseApi): def post_anyof_complex_types_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_anyof_complex_types_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostAnyofComplexTypesRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_anyof_complex_types_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostAnyofComplexTypesRequestBody(BaseApi): def post_anyof_complex_types_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_request_body/post.py index dd05bf98bc0..8e99ee7a3c2 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_anyof_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_anyof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_anyof_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_anyof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_anyof_request_body_oapg( def _post_anyof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostAnyofRequestBody(BaseApi): def post_anyof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_anyof_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_anyof_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_anyof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_anyof_request_body( def post_anyof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_request_body/post.pyi index d78c1dc140c..69a0a26d932 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_anyof_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_anyof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_anyof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_anyof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostAnyofRequestBody(BaseApi): def post_anyof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_anyof_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostAnyofRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_anyof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostAnyofRequestBody(BaseApi): def post_anyof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_with_base_schema_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_with_base_schema_request_body/post.py index 92d3119ae38..217369cd910 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_with_base_schema_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_with_base_schema_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_anyof_with_base_schema_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_anyof_with_base_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_anyof_with_base_schema_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_anyof_with_base_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_anyof_with_base_schema_request_body_oapg( def _post_anyof_with_base_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostAnyofWithBaseSchemaRequestBody(BaseApi): def post_anyof_with_base_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_anyof_with_base_schema_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_anyof_with_base_schema_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_anyof_with_base_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_anyof_with_base_schema_request_body( def post_anyof_with_base_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_with_base_schema_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_with_base_schema_request_body/post.pyi index e76d9fd5e5e..bc85fc6cd10 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_with_base_schema_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_with_base_schema_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_anyof_with_base_schema_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_anyof_with_base_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_anyof_with_base_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_anyof_with_base_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostAnyofWithBaseSchemaRequestBody(BaseApi): def post_anyof_with_base_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_anyof_with_base_schema_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostAnyofWithBaseSchemaRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_anyof_with_base_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostAnyofWithBaseSchemaRequestBody(BaseApi): def post_anyof_with_base_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_with_one_empty_schema_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_with_one_empty_schema_request_body/post.py index 0566aef4521..f08f875b413 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_with_one_empty_schema_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_with_one_empty_schema_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_anyof_with_one_empty_schema_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_anyof_with_one_empty_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_anyof_with_one_empty_schema_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_anyof_with_one_empty_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_anyof_with_one_empty_schema_request_body_oapg( def _post_anyof_with_one_empty_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostAnyofWithOneEmptySchemaRequestBody(BaseApi): def post_anyof_with_one_empty_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_anyof_with_one_empty_schema_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_anyof_with_one_empty_schema_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_anyof_with_one_empty_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_anyof_with_one_empty_schema_request_body( def post_anyof_with_one_empty_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_with_one_empty_schema_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_with_one_empty_schema_request_body/post.pyi index d24cf3db91a..fdd3f85a03f 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_with_one_empty_schema_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_anyof_with_one_empty_schema_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_anyof_with_one_empty_schema_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_anyof_with_one_empty_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_anyof_with_one_empty_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_anyof_with_one_empty_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostAnyofWithOneEmptySchemaRequestBody(BaseApi): def post_anyof_with_one_empty_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_anyof_with_one_empty_schema_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostAnyofWithOneEmptySchemaRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_anyof_with_one_empty_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostAnyofWithOneEmptySchemaRequestBody(BaseApi): def post_anyof_with_one_empty_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_array_type_matches_arrays_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_array_type_matches_arrays_request_body/post.py index 4a2b70e3b09..7511003b1d1 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_array_type_matches_arrays_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_array_type_matches_arrays_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_array_type_matches_arrays_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_array_type_matches_arrays_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_array_type_matches_arrays_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_array_type_matches_arrays_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_array_type_matches_arrays_request_body_oapg( def _post_array_type_matches_arrays_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostArrayTypeMatchesArraysRequestBody(BaseApi): def post_array_type_matches_arrays_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_array_type_matches_arrays_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_array_type_matches_arrays_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_array_type_matches_arrays_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_array_type_matches_arrays_request_body( def post_array_type_matches_arrays_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_array_type_matches_arrays_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_array_type_matches_arrays_request_body/post.pyi index c4cc3cf6531..672a3a3a6a4 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_array_type_matches_arrays_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_array_type_matches_arrays_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_array_type_matches_arrays_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_array_type_matches_arrays_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_array_type_matches_arrays_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_array_type_matches_arrays_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostArrayTypeMatchesArraysRequestBody(BaseApi): def post_array_type_matches_arrays_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_array_type_matches_arrays_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostArrayTypeMatchesArraysRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_array_type_matches_arrays_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostArrayTypeMatchesArraysRequestBody(BaseApi): def post_array_type_matches_arrays_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_boolean_type_matches_booleans_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_boolean_type_matches_booleans_request_body/post.py index 4eb1775046a..db22058d0fe 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_boolean_type_matches_booleans_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_boolean_type_matches_booleans_request_body/post.py @@ -56,12 +56,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_boolean_type_matches_booleans_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,bool, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_boolean_type_matches_booleans_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,bool, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -69,12 +80,13 @@ def _post_boolean_type_matches_booleans_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_boolean_type_matches_booleans_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,bool, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -83,7 +95,7 @@ def _post_boolean_type_matches_booleans_request_body_oapg( def _post_boolean_type_matches_booleans_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,bool, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -153,7 +165,19 @@ class PostBooleanTypeMatchesBooleansRequestBody(BaseApi): def post_boolean_type_matches_booleans_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,bool, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_boolean_type_matches_booleans_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,bool, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -161,12 +185,13 @@ def post_boolean_type_matches_booleans_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_boolean_type_matches_booleans_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,bool, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -175,7 +200,7 @@ def post_boolean_type_matches_booleans_request_body( def post_boolean_type_matches_booleans_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,bool, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -208,7 +233,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,bool, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,bool, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -216,12 +253,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,bool, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -230,7 +268,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,bool, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_boolean_type_matches_booleans_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_boolean_type_matches_booleans_request_body/post.pyi index 6cb81ad3d3b..b30d7be40c5 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_boolean_type_matches_booleans_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_boolean_type_matches_booleans_request_body/post.pyi @@ -51,12 +51,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_boolean_type_matches_booleans_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,bool, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_boolean_type_matches_booleans_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,bool, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -64,12 +75,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_boolean_type_matches_booleans_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,bool, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -78,7 +90,7 @@ class BaseApi(api_client.Api): def _post_boolean_type_matches_booleans_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,bool, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -148,7 +160,19 @@ class PostBooleanTypeMatchesBooleansRequestBody(BaseApi): def post_boolean_type_matches_booleans_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,bool, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_boolean_type_matches_booleans_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,bool, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -156,12 +180,13 @@ class PostBooleanTypeMatchesBooleansRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_boolean_type_matches_booleans_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,bool, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -170,7 +195,7 @@ class PostBooleanTypeMatchesBooleansRequestBody(BaseApi): def post_boolean_type_matches_booleans_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,bool, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -203,7 +228,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,bool, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,bool, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -211,12 +248,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,bool, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -225,7 +263,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,bool, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_by_int_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_by_int_request_body/post.py index 2a11818332d..5d69029a348 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_by_int_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_by_int_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_by_int_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_by_int_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_by_int_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_by_int_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_by_int_request_body_oapg( def _post_by_int_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostByIntRequestBody(BaseApi): def post_by_int_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_by_int_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_by_int_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_by_int_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_by_int_request_body( def post_by_int_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_by_int_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_by_int_request_body/post.pyi index a06077f3c03..599b4979b68 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_by_int_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_by_int_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_by_int_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_by_int_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_by_int_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_by_int_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostByIntRequestBody(BaseApi): def post_by_int_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_by_int_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostByIntRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_by_int_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostByIntRequestBody(BaseApi): def post_by_int_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_by_number_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_by_number_request_body/post.py index a40eed50486..8e84300e738 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_by_number_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_by_number_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_by_number_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_by_number_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_by_number_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_by_number_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_by_number_request_body_oapg( def _post_by_number_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostByNumberRequestBody(BaseApi): def post_by_number_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_by_number_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_by_number_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_by_number_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_by_number_request_body( def post_by_number_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_by_number_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_by_number_request_body/post.pyi index c1c0ac47c69..2965ae19194 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_by_number_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_by_number_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_by_number_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_by_number_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_by_number_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_by_number_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostByNumberRequestBody(BaseApi): def post_by_number_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_by_number_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostByNumberRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_by_number_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostByNumberRequestBody(BaseApi): def post_by_number_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_by_small_number_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_by_small_number_request_body/post.py index 2cf41b1a1a9..668ee59186b 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_by_small_number_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_by_small_number_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_by_small_number_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_by_small_number_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_by_small_number_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_by_small_number_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_by_small_number_request_body_oapg( def _post_by_small_number_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostBySmallNumberRequestBody(BaseApi): def post_by_small_number_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_by_small_number_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_by_small_number_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_by_small_number_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_by_small_number_request_body( def post_by_small_number_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_by_small_number_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_by_small_number_request_body/post.pyi index e1d704462ff..adc387a8ea6 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_by_small_number_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_by_small_number_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_by_small_number_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_by_small_number_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_by_small_number_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_by_small_number_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostBySmallNumberRequestBody(BaseApi): def post_by_small_number_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_by_small_number_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostBySmallNumberRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_by_small_number_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostBySmallNumberRequestBody(BaseApi): def post_by_small_number_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_date_time_format_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_date_time_format_request_body/post.py index 08113cf81f4..9499c4998d1 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_date_time_format_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_date_time_format_request_body/post.py @@ -79,12 +79,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_date_time_format_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_date_time_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -92,12 +103,13 @@ def _post_date_time_format_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_date_time_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -106,7 +118,7 @@ def _post_date_time_format_request_body_oapg( def _post_date_time_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -176,7 +188,19 @@ class PostDateTimeFormatRequestBody(BaseApi): def post_date_time_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_date_time_format_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -184,12 +208,13 @@ def post_date_time_format_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_date_time_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -198,7 +223,7 @@ def post_date_time_format_request_body( def post_date_time_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -231,7 +256,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -239,12 +276,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -253,7 +291,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_date_time_format_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_date_time_format_request_body/post.pyi index d89730fbf4a..e75c82d05ca 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_date_time_format_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_date_time_format_request_body/post.pyi @@ -74,12 +74,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_date_time_format_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_date_time_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -87,12 +98,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_date_time_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -101,7 +113,7 @@ class BaseApi(api_client.Api): def _post_date_time_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -171,7 +183,19 @@ class PostDateTimeFormatRequestBody(BaseApi): def post_date_time_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_date_time_format_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -179,12 +203,13 @@ class PostDateTimeFormatRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_date_time_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -193,7 +218,7 @@ class PostDateTimeFormatRequestBody(BaseApi): def post_date_time_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -226,7 +251,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -234,12 +271,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -248,7 +286,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_email_format_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_email_format_request_body/post.py index 3f308e7aa19..61c0e558b28 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_email_format_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_email_format_request_body/post.py @@ -78,12 +78,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_email_format_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_email_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -91,12 +102,13 @@ def _post_email_format_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_email_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -105,7 +117,7 @@ def _post_email_format_request_body_oapg( def _post_email_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -175,7 +187,19 @@ class PostEmailFormatRequestBody(BaseApi): def post_email_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_email_format_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -183,12 +207,13 @@ def post_email_format_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_email_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -197,7 +222,7 @@ def post_email_format_request_body( def post_email_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -230,7 +255,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -238,12 +275,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -252,7 +290,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_email_format_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_email_format_request_body/post.pyi index 03b471390b4..624a2c83bd0 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_email_format_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_email_format_request_body/post.pyi @@ -73,12 +73,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_email_format_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_email_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -86,12 +97,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_email_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -100,7 +112,7 @@ class BaseApi(api_client.Api): def _post_email_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -170,7 +182,19 @@ class PostEmailFormatRequestBody(BaseApi): def post_email_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_email_format_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -178,12 +202,13 @@ class PostEmailFormatRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_email_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -192,7 +217,7 @@ class PostEmailFormatRequestBody(BaseApi): def post_email_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -225,7 +250,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -233,12 +270,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -247,7 +285,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with0_does_not_match_false_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with0_does_not_match_false_request_body/post.py index 699d0fe72d7..1d6fde1b757 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with0_does_not_match_false_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with0_does_not_match_false_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_enum_with0_does_not_match_false_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_enum_with0_does_not_match_false_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_enum_with0_does_not_match_false_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_enum_with0_does_not_match_false_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_enum_with0_does_not_match_false_request_body_oapg( def _post_enum_with0_does_not_match_false_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostEnumWith0DoesNotMatchFalseRequestBody(BaseApi): def post_enum_with0_does_not_match_false_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_enum_with0_does_not_match_false_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_enum_with0_does_not_match_false_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_enum_with0_does_not_match_false_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_enum_with0_does_not_match_false_request_body( def post_enum_with0_does_not_match_false_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with0_does_not_match_false_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with0_does_not_match_false_request_body/post.pyi index e8d1cbbe36f..fc3b37cec26 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with0_does_not_match_false_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with0_does_not_match_false_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_enum_with0_does_not_match_false_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_enum_with0_does_not_match_false_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_enum_with0_does_not_match_false_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_enum_with0_does_not_match_false_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostEnumWith0DoesNotMatchFalseRequestBody(BaseApi): def post_enum_with0_does_not_match_false_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_enum_with0_does_not_match_false_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostEnumWith0DoesNotMatchFalseRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_enum_with0_does_not_match_false_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostEnumWith0DoesNotMatchFalseRequestBody(BaseApi): def post_enum_with0_does_not_match_false_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with1_does_not_match_true_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with1_does_not_match_true_request_body/post.py index 7ba0df0f982..e54e98dc389 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with1_does_not_match_true_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with1_does_not_match_true_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_enum_with1_does_not_match_true_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_enum_with1_does_not_match_true_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_enum_with1_does_not_match_true_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_enum_with1_does_not_match_true_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_enum_with1_does_not_match_true_request_body_oapg( def _post_enum_with1_does_not_match_true_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostEnumWith1DoesNotMatchTrueRequestBody(BaseApi): def post_enum_with1_does_not_match_true_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_enum_with1_does_not_match_true_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_enum_with1_does_not_match_true_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_enum_with1_does_not_match_true_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_enum_with1_does_not_match_true_request_body( def post_enum_with1_does_not_match_true_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with1_does_not_match_true_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with1_does_not_match_true_request_body/post.pyi index 5ed59ee40f1..5dfa978e1f2 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with1_does_not_match_true_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with1_does_not_match_true_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_enum_with1_does_not_match_true_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_enum_with1_does_not_match_true_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_enum_with1_does_not_match_true_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_enum_with1_does_not_match_true_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostEnumWith1DoesNotMatchTrueRequestBody(BaseApi): def post_enum_with1_does_not_match_true_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_enum_with1_does_not_match_true_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostEnumWith1DoesNotMatchTrueRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_enum_with1_does_not_match_true_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostEnumWith1DoesNotMatchTrueRequestBody(BaseApi): def post_enum_with1_does_not_match_true_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with_escaped_characters_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with_escaped_characters_request_body/post.py index f902ab5341d..abf4252d662 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with_escaped_characters_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with_escaped_characters_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_enum_with_escaped_characters_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_enum_with_escaped_characters_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_enum_with_escaped_characters_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_enum_with_escaped_characters_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_enum_with_escaped_characters_request_body_oapg( def _post_enum_with_escaped_characters_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostEnumWithEscapedCharactersRequestBody(BaseApi): def post_enum_with_escaped_characters_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_enum_with_escaped_characters_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_enum_with_escaped_characters_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_enum_with_escaped_characters_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_enum_with_escaped_characters_request_body( def post_enum_with_escaped_characters_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with_escaped_characters_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with_escaped_characters_request_body/post.pyi index bd1ad98fbda..ae3cd9c56a5 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with_escaped_characters_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with_escaped_characters_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_enum_with_escaped_characters_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_enum_with_escaped_characters_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_enum_with_escaped_characters_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_enum_with_escaped_characters_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostEnumWithEscapedCharactersRequestBody(BaseApi): def post_enum_with_escaped_characters_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_enum_with_escaped_characters_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostEnumWithEscapedCharactersRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_enum_with_escaped_characters_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostEnumWithEscapedCharactersRequestBody(BaseApi): def post_enum_with_escaped_characters_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with_false_does_not_match0_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with_false_does_not_match0_request_body/post.py index e8bd11931d4..f13496bc396 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with_false_does_not_match0_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with_false_does_not_match0_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_enum_with_false_does_not_match0_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_enum_with_false_does_not_match0_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_enum_with_false_does_not_match0_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_enum_with_false_does_not_match0_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_enum_with_false_does_not_match0_request_body_oapg( def _post_enum_with_false_does_not_match0_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostEnumWithFalseDoesNotMatch0RequestBody(BaseApi): def post_enum_with_false_does_not_match0_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_enum_with_false_does_not_match0_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_enum_with_false_does_not_match0_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_enum_with_false_does_not_match0_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_enum_with_false_does_not_match0_request_body( def post_enum_with_false_does_not_match0_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with_false_does_not_match0_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with_false_does_not_match0_request_body/post.pyi index ef8bd5a7739..d2a2fb5b1a7 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with_false_does_not_match0_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with_false_does_not_match0_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_enum_with_false_does_not_match0_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_enum_with_false_does_not_match0_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_enum_with_false_does_not_match0_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_enum_with_false_does_not_match0_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostEnumWithFalseDoesNotMatch0RequestBody(BaseApi): def post_enum_with_false_does_not_match0_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_enum_with_false_does_not_match0_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostEnumWithFalseDoesNotMatch0RequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_enum_with_false_does_not_match0_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostEnumWithFalseDoesNotMatch0RequestBody(BaseApi): def post_enum_with_false_does_not_match0_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with_true_does_not_match1_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with_true_does_not_match1_request_body/post.py index e27e29bcfb2..cdda0d34c52 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with_true_does_not_match1_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with_true_does_not_match1_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_enum_with_true_does_not_match1_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_enum_with_true_does_not_match1_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_enum_with_true_does_not_match1_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_enum_with_true_does_not_match1_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_enum_with_true_does_not_match1_request_body_oapg( def _post_enum_with_true_does_not_match1_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostEnumWithTrueDoesNotMatch1RequestBody(BaseApi): def post_enum_with_true_does_not_match1_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_enum_with_true_does_not_match1_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_enum_with_true_does_not_match1_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_enum_with_true_does_not_match1_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_enum_with_true_does_not_match1_request_body( def post_enum_with_true_does_not_match1_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with_true_does_not_match1_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with_true_does_not_match1_request_body/post.pyi index 37e3e9d2bed..ede86715a92 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with_true_does_not_match1_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enum_with_true_does_not_match1_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_enum_with_true_does_not_match1_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_enum_with_true_does_not_match1_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_enum_with_true_does_not_match1_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_enum_with_true_does_not_match1_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostEnumWithTrueDoesNotMatch1RequestBody(BaseApi): def post_enum_with_true_does_not_match1_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_enum_with_true_does_not_match1_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostEnumWithTrueDoesNotMatch1RequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_enum_with_true_does_not_match1_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostEnumWithTrueDoesNotMatch1RequestBody(BaseApi): def post_enum_with_true_does_not_match1_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enums_in_properties_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enums_in_properties_request_body/post.py index 58d7d8f8867..dc053602f57 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enums_in_properties_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enums_in_properties_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_enums_in_properties_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_enums_in_properties_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_enums_in_properties_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_enums_in_properties_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_enums_in_properties_request_body_oapg( def _post_enums_in_properties_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostEnumsInPropertiesRequestBody(BaseApi): def post_enums_in_properties_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_enums_in_properties_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_enums_in_properties_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_enums_in_properties_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_enums_in_properties_request_body( def post_enums_in_properties_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enums_in_properties_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enums_in_properties_request_body/post.pyi index fe081d2131f..082bb8a018e 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enums_in_properties_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_enums_in_properties_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_enums_in_properties_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_enums_in_properties_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_enums_in_properties_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_enums_in_properties_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostEnumsInPropertiesRequestBody(BaseApi): def post_enums_in_properties_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_enums_in_properties_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostEnumsInPropertiesRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_enums_in_properties_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostEnumsInPropertiesRequestBody(BaseApi): def post_enums_in_properties_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_forbidden_property_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_forbidden_property_request_body/post.py index bc8dc103fca..e1e44621625 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_forbidden_property_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_forbidden_property_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_forbidden_property_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_forbidden_property_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_forbidden_property_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_forbidden_property_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_forbidden_property_request_body_oapg( def _post_forbidden_property_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostForbiddenPropertyRequestBody(BaseApi): def post_forbidden_property_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_forbidden_property_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_forbidden_property_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_forbidden_property_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_forbidden_property_request_body( def post_forbidden_property_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_forbidden_property_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_forbidden_property_request_body/post.pyi index 04a1eb3df97..688fcb76f94 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_forbidden_property_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_forbidden_property_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_forbidden_property_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_forbidden_property_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_forbidden_property_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_forbidden_property_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostForbiddenPropertyRequestBody(BaseApi): def post_forbidden_property_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_forbidden_property_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostForbiddenPropertyRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_forbidden_property_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostForbiddenPropertyRequestBody(BaseApi): def post_forbidden_property_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_hostname_format_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_hostname_format_request_body/post.py index c7fc1f6b6d1..531dc56c32a 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_hostname_format_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_hostname_format_request_body/post.py @@ -78,12 +78,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_hostname_format_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_hostname_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -91,12 +102,13 @@ def _post_hostname_format_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_hostname_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -105,7 +117,7 @@ def _post_hostname_format_request_body_oapg( def _post_hostname_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -175,7 +187,19 @@ class PostHostnameFormatRequestBody(BaseApi): def post_hostname_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_hostname_format_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -183,12 +207,13 @@ def post_hostname_format_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_hostname_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -197,7 +222,7 @@ def post_hostname_format_request_body( def post_hostname_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -230,7 +255,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -238,12 +275,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -252,7 +290,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_hostname_format_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_hostname_format_request_body/post.pyi index 40cb9266eca..96b59201e87 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_hostname_format_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_hostname_format_request_body/post.pyi @@ -73,12 +73,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_hostname_format_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_hostname_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -86,12 +97,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_hostname_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -100,7 +112,7 @@ class BaseApi(api_client.Api): def _post_hostname_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -170,7 +182,19 @@ class PostHostnameFormatRequestBody(BaseApi): def post_hostname_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_hostname_format_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -178,12 +202,13 @@ class PostHostnameFormatRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_hostname_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -192,7 +217,7 @@ class PostHostnameFormatRequestBody(BaseApi): def post_hostname_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -225,7 +250,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -233,12 +270,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -247,7 +285,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_integer_type_matches_integers_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_integer_type_matches_integers_request_body/post.py index ad60e5452dd..746839d1cdf 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_integer_type_matches_integers_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_integer_type_matches_integers_request_body/post.py @@ -56,12 +56,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_integer_type_matches_integers_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_integer_type_matches_integers_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -69,12 +80,13 @@ def _post_integer_type_matches_integers_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_integer_type_matches_integers_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -83,7 +95,7 @@ def _post_integer_type_matches_integers_request_body_oapg( def _post_integer_type_matches_integers_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -153,7 +165,19 @@ class PostIntegerTypeMatchesIntegersRequestBody(BaseApi): def post_integer_type_matches_integers_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_integer_type_matches_integers_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -161,12 +185,13 @@ def post_integer_type_matches_integers_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_integer_type_matches_integers_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -175,7 +200,7 @@ def post_integer_type_matches_integers_request_body( def post_integer_type_matches_integers_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -208,7 +233,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -216,12 +253,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -230,7 +268,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_integer_type_matches_integers_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_integer_type_matches_integers_request_body/post.pyi index 58018bb60b5..a2d00a4f70c 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_integer_type_matches_integers_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_integer_type_matches_integers_request_body/post.pyi @@ -51,12 +51,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_integer_type_matches_integers_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_integer_type_matches_integers_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -64,12 +75,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_integer_type_matches_integers_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -78,7 +90,7 @@ class BaseApi(api_client.Api): def _post_integer_type_matches_integers_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -148,7 +160,19 @@ class PostIntegerTypeMatchesIntegersRequestBody(BaseApi): def post_integer_type_matches_integers_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_integer_type_matches_integers_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -156,12 +180,13 @@ class PostIntegerTypeMatchesIntegersRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_integer_type_matches_integers_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -170,7 +195,7 @@ class PostIntegerTypeMatchesIntegersRequestBody(BaseApi): def post_integer_type_matches_integers_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -203,7 +228,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -211,12 +248,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -225,7 +263,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_invalid_instance_should_not_raise_error_when_float_division_inf_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_invalid_instance_should_not_raise_error_when_float_division_inf_request_body/post.py index 4aaace39bdc..a4373898774 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_invalid_instance_should_not_raise_error_when_float_division_inf_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_invalid_instance_should_not_raise_error_when_float_division_inf_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_invalid_instance_should_not_raise_error_when_float_division_inf_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_invalid_instance_should_not_raise_error_when_float_division_inf_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_invalid_instance_should_not_raise_error_when_float_division_inf_reques ApiResponseFor200, ]: ... + @typing.overload def _post_invalid_instance_should_not_raise_error_when_float_division_inf_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_invalid_instance_should_not_raise_error_when_float_division_inf_reques def _post_invalid_instance_should_not_raise_error_when_float_division_inf_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostInvalidInstanceShouldNotRaiseErrorWhenFloatDivisionInfRequestBody(Base def post_invalid_instance_should_not_raise_error_when_float_division_inf_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_invalid_instance_should_not_raise_error_when_float_division_inf_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_invalid_instance_should_not_raise_error_when_float_division_inf_request ApiResponseFor200, ]: ... + @typing.overload def post_invalid_instance_should_not_raise_error_when_float_division_inf_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_invalid_instance_should_not_raise_error_when_float_division_inf_request def post_invalid_instance_should_not_raise_error_when_float_division_inf_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_invalid_instance_should_not_raise_error_when_float_division_inf_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_invalid_instance_should_not_raise_error_when_float_division_inf_request_body/post.pyi index 0f57a780b70..15c6c301222 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_invalid_instance_should_not_raise_error_when_float_division_inf_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_invalid_instance_should_not_raise_error_when_float_division_inf_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_invalid_instance_should_not_raise_error_when_float_division_inf_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_invalid_instance_should_not_raise_error_when_float_division_inf_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_invalid_instance_should_not_raise_error_when_float_division_inf_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_invalid_instance_should_not_raise_error_when_float_division_inf_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostInvalidInstanceShouldNotRaiseErrorWhenFloatDivisionInfRequestBody(Base def post_invalid_instance_should_not_raise_error_when_float_division_inf_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_invalid_instance_should_not_raise_error_when_float_division_inf_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostInvalidInstanceShouldNotRaiseErrorWhenFloatDivisionInfRequestBody(Base ApiResponseFor200, ]: ... + @typing.overload def post_invalid_instance_should_not_raise_error_when_float_division_inf_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostInvalidInstanceShouldNotRaiseErrorWhenFloatDivisionInfRequestBody(Base def post_invalid_instance_should_not_raise_error_when_float_division_inf_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_invalid_string_value_for_default_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_invalid_string_value_for_default_request_body/post.py index 4c79329c468..27ac8568811 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_invalid_string_value_for_default_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_invalid_string_value_for_default_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_invalid_string_value_for_default_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_invalid_string_value_for_default_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_invalid_string_value_for_default_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_invalid_string_value_for_default_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_invalid_string_value_for_default_request_body_oapg( def _post_invalid_string_value_for_default_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostInvalidStringValueForDefaultRequestBody(BaseApi): def post_invalid_string_value_for_default_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_invalid_string_value_for_default_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_invalid_string_value_for_default_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_invalid_string_value_for_default_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_invalid_string_value_for_default_request_body( def post_invalid_string_value_for_default_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_invalid_string_value_for_default_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_invalid_string_value_for_default_request_body/post.pyi index bdca22f2bd9..00c9f71b026 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_invalid_string_value_for_default_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_invalid_string_value_for_default_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_invalid_string_value_for_default_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_invalid_string_value_for_default_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_invalid_string_value_for_default_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_invalid_string_value_for_default_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostInvalidStringValueForDefaultRequestBody(BaseApi): def post_invalid_string_value_for_default_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_invalid_string_value_for_default_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostInvalidStringValueForDefaultRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_invalid_string_value_for_default_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostInvalidStringValueForDefaultRequestBody(BaseApi): def post_invalid_string_value_for_default_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ipv4_format_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ipv4_format_request_body/post.py index a251a71281c..9ffdb8d5be0 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ipv4_format_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ipv4_format_request_body/post.py @@ -78,12 +78,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_ipv4_format_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_ipv4_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -91,12 +102,13 @@ def _post_ipv4_format_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_ipv4_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -105,7 +117,7 @@ def _post_ipv4_format_request_body_oapg( def _post_ipv4_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -175,7 +187,19 @@ class PostIpv4FormatRequestBody(BaseApi): def post_ipv4_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_ipv4_format_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -183,12 +207,13 @@ def post_ipv4_format_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_ipv4_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -197,7 +222,7 @@ def post_ipv4_format_request_body( def post_ipv4_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -230,7 +255,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -238,12 +275,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -252,7 +290,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ipv4_format_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ipv4_format_request_body/post.pyi index 264e5d956fb..21a1c8c5040 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ipv4_format_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ipv4_format_request_body/post.pyi @@ -73,12 +73,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_ipv4_format_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_ipv4_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -86,12 +97,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_ipv4_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -100,7 +112,7 @@ class BaseApi(api_client.Api): def _post_ipv4_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -170,7 +182,19 @@ class PostIpv4FormatRequestBody(BaseApi): def post_ipv4_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_ipv4_format_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -178,12 +202,13 @@ class PostIpv4FormatRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_ipv4_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -192,7 +217,7 @@ class PostIpv4FormatRequestBody(BaseApi): def post_ipv4_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -225,7 +250,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -233,12 +270,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -247,7 +285,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ipv6_format_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ipv6_format_request_body/post.py index d23013575b5..8fb701cc61f 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ipv6_format_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ipv6_format_request_body/post.py @@ -78,12 +78,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_ipv6_format_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_ipv6_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -91,12 +102,13 @@ def _post_ipv6_format_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_ipv6_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -105,7 +117,7 @@ def _post_ipv6_format_request_body_oapg( def _post_ipv6_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -175,7 +187,19 @@ class PostIpv6FormatRequestBody(BaseApi): def post_ipv6_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_ipv6_format_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -183,12 +207,13 @@ def post_ipv6_format_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_ipv6_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -197,7 +222,7 @@ def post_ipv6_format_request_body( def post_ipv6_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -230,7 +255,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -238,12 +275,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -252,7 +290,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ipv6_format_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ipv6_format_request_body/post.pyi index b58f69a4ffc..b50a09052e9 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ipv6_format_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ipv6_format_request_body/post.pyi @@ -73,12 +73,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_ipv6_format_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_ipv6_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -86,12 +97,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_ipv6_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -100,7 +112,7 @@ class BaseApi(api_client.Api): def _post_ipv6_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -170,7 +182,19 @@ class PostIpv6FormatRequestBody(BaseApi): def post_ipv6_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_ipv6_format_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -178,12 +202,13 @@ class PostIpv6FormatRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_ipv6_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -192,7 +217,7 @@ class PostIpv6FormatRequestBody(BaseApi): def post_ipv6_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -225,7 +250,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -233,12 +270,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -247,7 +285,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_json_pointer_format_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_json_pointer_format_request_body/post.py index 4d96c7e6424..1ad92bc8258 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_json_pointer_format_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_json_pointer_format_request_body/post.py @@ -78,12 +78,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_json_pointer_format_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_json_pointer_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -91,12 +102,13 @@ def _post_json_pointer_format_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_json_pointer_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -105,7 +117,7 @@ def _post_json_pointer_format_request_body_oapg( def _post_json_pointer_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -175,7 +187,19 @@ class PostJsonPointerFormatRequestBody(BaseApi): def post_json_pointer_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_json_pointer_format_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -183,12 +207,13 @@ def post_json_pointer_format_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_json_pointer_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -197,7 +222,7 @@ def post_json_pointer_format_request_body( def post_json_pointer_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -230,7 +255,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -238,12 +275,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -252,7 +290,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_json_pointer_format_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_json_pointer_format_request_body/post.pyi index 32d0e18c545..4e2d9ef6c59 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_json_pointer_format_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_json_pointer_format_request_body/post.pyi @@ -73,12 +73,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_json_pointer_format_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_json_pointer_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -86,12 +97,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_json_pointer_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -100,7 +112,7 @@ class BaseApi(api_client.Api): def _post_json_pointer_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -170,7 +182,19 @@ class PostJsonPointerFormatRequestBody(BaseApi): def post_json_pointer_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_json_pointer_format_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -178,12 +202,13 @@ class PostJsonPointerFormatRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_json_pointer_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -192,7 +217,7 @@ class PostJsonPointerFormatRequestBody(BaseApi): def post_json_pointer_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -225,7 +250,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -233,12 +270,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -247,7 +285,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maximum_validation_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maximum_validation_request_body/post.py index 222f1bfde43..982f83c735b 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maximum_validation_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maximum_validation_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_maximum_validation_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_maximum_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_maximum_validation_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_maximum_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_maximum_validation_request_body_oapg( def _post_maximum_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostMaximumValidationRequestBody(BaseApi): def post_maximum_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_maximum_validation_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_maximum_validation_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_maximum_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_maximum_validation_request_body( def post_maximum_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maximum_validation_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maximum_validation_request_body/post.pyi index caac310267c..a0723cca701 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maximum_validation_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maximum_validation_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_maximum_validation_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_maximum_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_maximum_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_maximum_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostMaximumValidationRequestBody(BaseApi): def post_maximum_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_maximum_validation_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostMaximumValidationRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_maximum_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostMaximumValidationRequestBody(BaseApi): def post_maximum_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maximum_validation_with_unsigned_integer_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maximum_validation_with_unsigned_integer_request_body/post.py index 085ec76befd..fcf0f9c4e2d 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maximum_validation_with_unsigned_integer_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maximum_validation_with_unsigned_integer_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_maximum_validation_with_unsigned_integer_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_maximum_validation_with_unsigned_integer_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_maximum_validation_with_unsigned_integer_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_maximum_validation_with_unsigned_integer_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_maximum_validation_with_unsigned_integer_request_body_oapg( def _post_maximum_validation_with_unsigned_integer_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostMaximumValidationWithUnsignedIntegerRequestBody(BaseApi): def post_maximum_validation_with_unsigned_integer_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_maximum_validation_with_unsigned_integer_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_maximum_validation_with_unsigned_integer_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_maximum_validation_with_unsigned_integer_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_maximum_validation_with_unsigned_integer_request_body( def post_maximum_validation_with_unsigned_integer_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maximum_validation_with_unsigned_integer_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maximum_validation_with_unsigned_integer_request_body/post.pyi index a6a5a4f2f94..4e5c945af52 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maximum_validation_with_unsigned_integer_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maximum_validation_with_unsigned_integer_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_maximum_validation_with_unsigned_integer_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_maximum_validation_with_unsigned_integer_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_maximum_validation_with_unsigned_integer_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_maximum_validation_with_unsigned_integer_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostMaximumValidationWithUnsignedIntegerRequestBody(BaseApi): def post_maximum_validation_with_unsigned_integer_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_maximum_validation_with_unsigned_integer_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostMaximumValidationWithUnsignedIntegerRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_maximum_validation_with_unsigned_integer_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostMaximumValidationWithUnsignedIntegerRequestBody(BaseApi): def post_maximum_validation_with_unsigned_integer_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxitems_validation_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxitems_validation_request_body/post.py index 5682ce926a9..08f984ff02d 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxitems_validation_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxitems_validation_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_maxitems_validation_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_maxitems_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_maxitems_validation_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_maxitems_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_maxitems_validation_request_body_oapg( def _post_maxitems_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostMaxitemsValidationRequestBody(BaseApi): def post_maxitems_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_maxitems_validation_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_maxitems_validation_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_maxitems_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_maxitems_validation_request_body( def post_maxitems_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxitems_validation_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxitems_validation_request_body/post.pyi index 17ce0f4d262..a42d2f09c2f 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxitems_validation_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxitems_validation_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_maxitems_validation_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_maxitems_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_maxitems_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_maxitems_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostMaxitemsValidationRequestBody(BaseApi): def post_maxitems_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_maxitems_validation_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostMaxitemsValidationRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_maxitems_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostMaxitemsValidationRequestBody(BaseApi): def post_maxitems_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxlength_validation_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxlength_validation_request_body/post.py index 5cbc8e84a52..d9f0c7ca462 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxlength_validation_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxlength_validation_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_maxlength_validation_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_maxlength_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_maxlength_validation_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_maxlength_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_maxlength_validation_request_body_oapg( def _post_maxlength_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostMaxlengthValidationRequestBody(BaseApi): def post_maxlength_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_maxlength_validation_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_maxlength_validation_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_maxlength_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_maxlength_validation_request_body( def post_maxlength_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxlength_validation_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxlength_validation_request_body/post.pyi index f496f78ec48..b2e42052a3a 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxlength_validation_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxlength_validation_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_maxlength_validation_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_maxlength_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_maxlength_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_maxlength_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostMaxlengthValidationRequestBody(BaseApi): def post_maxlength_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_maxlength_validation_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostMaxlengthValidationRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_maxlength_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostMaxlengthValidationRequestBody(BaseApi): def post_maxlength_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxproperties0_means_the_object_is_empty_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxproperties0_means_the_object_is_empty_request_body/post.py index 4ae66d5280d..8df9e45dde1 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxproperties0_means_the_object_is_empty_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxproperties0_means_the_object_is_empty_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_maxproperties0_means_the_object_is_empty_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_maxproperties0_means_the_object_is_empty_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_maxproperties0_means_the_object_is_empty_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_maxproperties0_means_the_object_is_empty_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_maxproperties0_means_the_object_is_empty_request_body_oapg( def _post_maxproperties0_means_the_object_is_empty_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostMaxproperties0MeansTheObjectIsEmptyRequestBody(BaseApi): def post_maxproperties0_means_the_object_is_empty_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_maxproperties0_means_the_object_is_empty_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_maxproperties0_means_the_object_is_empty_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_maxproperties0_means_the_object_is_empty_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_maxproperties0_means_the_object_is_empty_request_body( def post_maxproperties0_means_the_object_is_empty_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxproperties0_means_the_object_is_empty_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxproperties0_means_the_object_is_empty_request_body/post.pyi index 107782d6ca6..544af50745a 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxproperties0_means_the_object_is_empty_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxproperties0_means_the_object_is_empty_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_maxproperties0_means_the_object_is_empty_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_maxproperties0_means_the_object_is_empty_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_maxproperties0_means_the_object_is_empty_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_maxproperties0_means_the_object_is_empty_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostMaxproperties0MeansTheObjectIsEmptyRequestBody(BaseApi): def post_maxproperties0_means_the_object_is_empty_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_maxproperties0_means_the_object_is_empty_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostMaxproperties0MeansTheObjectIsEmptyRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_maxproperties0_means_the_object_is_empty_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostMaxproperties0MeansTheObjectIsEmptyRequestBody(BaseApi): def post_maxproperties0_means_the_object_is_empty_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxproperties_validation_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxproperties_validation_request_body/post.py index 967602b5298..67fd2d8ab4d 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxproperties_validation_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxproperties_validation_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_maxproperties_validation_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_maxproperties_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_maxproperties_validation_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_maxproperties_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_maxproperties_validation_request_body_oapg( def _post_maxproperties_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostMaxpropertiesValidationRequestBody(BaseApi): def post_maxproperties_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_maxproperties_validation_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_maxproperties_validation_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_maxproperties_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_maxproperties_validation_request_body( def post_maxproperties_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxproperties_validation_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxproperties_validation_request_body/post.pyi index 536d34f987d..5119d69b5ed 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxproperties_validation_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_maxproperties_validation_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_maxproperties_validation_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_maxproperties_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_maxproperties_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_maxproperties_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostMaxpropertiesValidationRequestBody(BaseApi): def post_maxproperties_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_maxproperties_validation_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostMaxpropertiesValidationRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_maxproperties_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostMaxpropertiesValidationRequestBody(BaseApi): def post_maxproperties_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minimum_validation_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minimum_validation_request_body/post.py index 820677d72b7..b1e1c0d2275 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minimum_validation_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minimum_validation_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_minimum_validation_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_minimum_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_minimum_validation_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_minimum_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_minimum_validation_request_body_oapg( def _post_minimum_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostMinimumValidationRequestBody(BaseApi): def post_minimum_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_minimum_validation_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_minimum_validation_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_minimum_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_minimum_validation_request_body( def post_minimum_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minimum_validation_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minimum_validation_request_body/post.pyi index e5ee56cd3d5..0e7fa1996fa 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minimum_validation_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minimum_validation_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_minimum_validation_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_minimum_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_minimum_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_minimum_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostMinimumValidationRequestBody(BaseApi): def post_minimum_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_minimum_validation_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostMinimumValidationRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_minimum_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostMinimumValidationRequestBody(BaseApi): def post_minimum_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minimum_validation_with_signed_integer_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minimum_validation_with_signed_integer_request_body/post.py index a18b547d1e9..78129065be1 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minimum_validation_with_signed_integer_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minimum_validation_with_signed_integer_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_minimum_validation_with_signed_integer_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_minimum_validation_with_signed_integer_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_minimum_validation_with_signed_integer_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_minimum_validation_with_signed_integer_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_minimum_validation_with_signed_integer_request_body_oapg( def _post_minimum_validation_with_signed_integer_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostMinimumValidationWithSignedIntegerRequestBody(BaseApi): def post_minimum_validation_with_signed_integer_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_minimum_validation_with_signed_integer_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_minimum_validation_with_signed_integer_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_minimum_validation_with_signed_integer_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_minimum_validation_with_signed_integer_request_body( def post_minimum_validation_with_signed_integer_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minimum_validation_with_signed_integer_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minimum_validation_with_signed_integer_request_body/post.pyi index bd695aed39f..c8539721b25 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minimum_validation_with_signed_integer_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minimum_validation_with_signed_integer_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_minimum_validation_with_signed_integer_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_minimum_validation_with_signed_integer_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_minimum_validation_with_signed_integer_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_minimum_validation_with_signed_integer_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostMinimumValidationWithSignedIntegerRequestBody(BaseApi): def post_minimum_validation_with_signed_integer_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_minimum_validation_with_signed_integer_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostMinimumValidationWithSignedIntegerRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_minimum_validation_with_signed_integer_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostMinimumValidationWithSignedIntegerRequestBody(BaseApi): def post_minimum_validation_with_signed_integer_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minitems_validation_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minitems_validation_request_body/post.py index 85ae74df63b..e6282c3f44e 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minitems_validation_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minitems_validation_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_minitems_validation_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_minitems_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_minitems_validation_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_minitems_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_minitems_validation_request_body_oapg( def _post_minitems_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostMinitemsValidationRequestBody(BaseApi): def post_minitems_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_minitems_validation_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_minitems_validation_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_minitems_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_minitems_validation_request_body( def post_minitems_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minitems_validation_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minitems_validation_request_body/post.pyi index 740eceac806..d755c0d7557 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minitems_validation_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minitems_validation_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_minitems_validation_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_minitems_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_minitems_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_minitems_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostMinitemsValidationRequestBody(BaseApi): def post_minitems_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_minitems_validation_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostMinitemsValidationRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_minitems_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostMinitemsValidationRequestBody(BaseApi): def post_minitems_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minlength_validation_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minlength_validation_request_body/post.py index 552dfce75e2..192b4f1d158 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minlength_validation_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minlength_validation_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_minlength_validation_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_minlength_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_minlength_validation_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_minlength_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_minlength_validation_request_body_oapg( def _post_minlength_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostMinlengthValidationRequestBody(BaseApi): def post_minlength_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_minlength_validation_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_minlength_validation_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_minlength_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_minlength_validation_request_body( def post_minlength_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minlength_validation_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minlength_validation_request_body/post.pyi index 5ff41dbd920..7436c84bb26 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minlength_validation_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minlength_validation_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_minlength_validation_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_minlength_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_minlength_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_minlength_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostMinlengthValidationRequestBody(BaseApi): def post_minlength_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_minlength_validation_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostMinlengthValidationRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_minlength_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostMinlengthValidationRequestBody(BaseApi): def post_minlength_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minproperties_validation_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minproperties_validation_request_body/post.py index 605cde33b14..e6162712122 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minproperties_validation_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minproperties_validation_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_minproperties_validation_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_minproperties_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_minproperties_validation_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_minproperties_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_minproperties_validation_request_body_oapg( def _post_minproperties_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostMinpropertiesValidationRequestBody(BaseApi): def post_minproperties_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_minproperties_validation_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_minproperties_validation_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_minproperties_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_minproperties_validation_request_body( def post_minproperties_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minproperties_validation_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minproperties_validation_request_body/post.pyi index e03c5f01c8b..2d4602b4aaf 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minproperties_validation_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_minproperties_validation_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_minproperties_validation_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_minproperties_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_minproperties_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_minproperties_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostMinpropertiesValidationRequestBody(BaseApi): def post_minproperties_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_minproperties_validation_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostMinpropertiesValidationRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_minproperties_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostMinpropertiesValidationRequestBody(BaseApi): def post_minproperties_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_allof_to_check_validation_semantics_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_allof_to_check_validation_semantics_request_body/post.py index 8dd4b438317..04886b3f9f7 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_allof_to_check_validation_semantics_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_allof_to_check_validation_semantics_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_nested_allof_to_check_validation_semantics_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_nested_allof_to_check_validation_semantics_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_nested_allof_to_check_validation_semantics_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_nested_allof_to_check_validation_semantics_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_nested_allof_to_check_validation_semantics_request_body_oapg( def _post_nested_allof_to_check_validation_semantics_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostNestedAllofToCheckValidationSemanticsRequestBody(BaseApi): def post_nested_allof_to_check_validation_semantics_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_nested_allof_to_check_validation_semantics_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_nested_allof_to_check_validation_semantics_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_nested_allof_to_check_validation_semantics_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_nested_allof_to_check_validation_semantics_request_body( def post_nested_allof_to_check_validation_semantics_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_allof_to_check_validation_semantics_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_allof_to_check_validation_semantics_request_body/post.pyi index 5887ac4d330..ba2e00fa218 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_allof_to_check_validation_semantics_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_allof_to_check_validation_semantics_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_nested_allof_to_check_validation_semantics_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_nested_allof_to_check_validation_semantics_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_nested_allof_to_check_validation_semantics_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_nested_allof_to_check_validation_semantics_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostNestedAllofToCheckValidationSemanticsRequestBody(BaseApi): def post_nested_allof_to_check_validation_semantics_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_nested_allof_to_check_validation_semantics_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostNestedAllofToCheckValidationSemanticsRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_nested_allof_to_check_validation_semantics_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostNestedAllofToCheckValidationSemanticsRequestBody(BaseApi): def post_nested_allof_to_check_validation_semantics_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_anyof_to_check_validation_semantics_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_anyof_to_check_validation_semantics_request_body/post.py index fe387bed9b4..ddfa4e71d84 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_anyof_to_check_validation_semantics_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_anyof_to_check_validation_semantics_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_nested_anyof_to_check_validation_semantics_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_nested_anyof_to_check_validation_semantics_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_nested_anyof_to_check_validation_semantics_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_nested_anyof_to_check_validation_semantics_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_nested_anyof_to_check_validation_semantics_request_body_oapg( def _post_nested_anyof_to_check_validation_semantics_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostNestedAnyofToCheckValidationSemanticsRequestBody(BaseApi): def post_nested_anyof_to_check_validation_semantics_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_nested_anyof_to_check_validation_semantics_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_nested_anyof_to_check_validation_semantics_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_nested_anyof_to_check_validation_semantics_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_nested_anyof_to_check_validation_semantics_request_body( def post_nested_anyof_to_check_validation_semantics_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_anyof_to_check_validation_semantics_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_anyof_to_check_validation_semantics_request_body/post.pyi index 4eb5b160e21..b660117c48b 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_anyof_to_check_validation_semantics_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_anyof_to_check_validation_semantics_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_nested_anyof_to_check_validation_semantics_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_nested_anyof_to_check_validation_semantics_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_nested_anyof_to_check_validation_semantics_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_nested_anyof_to_check_validation_semantics_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostNestedAnyofToCheckValidationSemanticsRequestBody(BaseApi): def post_nested_anyof_to_check_validation_semantics_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_nested_anyof_to_check_validation_semantics_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostNestedAnyofToCheckValidationSemanticsRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_nested_anyof_to_check_validation_semantics_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostNestedAnyofToCheckValidationSemanticsRequestBody(BaseApi): def post_nested_anyof_to_check_validation_semantics_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_items_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_items_request_body/post.py index 77acaa62c45..2072cebde77 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_items_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_items_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_nested_items_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_nested_items_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_nested_items_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_nested_items_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_nested_items_request_body_oapg( def _post_nested_items_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostNestedItemsRequestBody(BaseApi): def post_nested_items_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_nested_items_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_nested_items_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_nested_items_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_nested_items_request_body( def post_nested_items_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_items_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_items_request_body/post.pyi index 41453d267da..f46fe5841fc 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_items_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_items_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_nested_items_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_nested_items_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_nested_items_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_nested_items_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostNestedItemsRequestBody(BaseApi): def post_nested_items_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_nested_items_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostNestedItemsRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_nested_items_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostNestedItemsRequestBody(BaseApi): def post_nested_items_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_oneof_to_check_validation_semantics_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_oneof_to_check_validation_semantics_request_body/post.py index e29a37851a5..eeeb6bfee2f 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_oneof_to_check_validation_semantics_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_oneof_to_check_validation_semantics_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_nested_oneof_to_check_validation_semantics_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_nested_oneof_to_check_validation_semantics_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_nested_oneof_to_check_validation_semantics_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_nested_oneof_to_check_validation_semantics_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_nested_oneof_to_check_validation_semantics_request_body_oapg( def _post_nested_oneof_to_check_validation_semantics_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostNestedOneofToCheckValidationSemanticsRequestBody(BaseApi): def post_nested_oneof_to_check_validation_semantics_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_nested_oneof_to_check_validation_semantics_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_nested_oneof_to_check_validation_semantics_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_nested_oneof_to_check_validation_semantics_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_nested_oneof_to_check_validation_semantics_request_body( def post_nested_oneof_to_check_validation_semantics_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_oneof_to_check_validation_semantics_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_oneof_to_check_validation_semantics_request_body/post.pyi index 79ff55401ca..fa49ae4894c 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_oneof_to_check_validation_semantics_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nested_oneof_to_check_validation_semantics_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_nested_oneof_to_check_validation_semantics_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_nested_oneof_to_check_validation_semantics_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_nested_oneof_to_check_validation_semantics_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_nested_oneof_to_check_validation_semantics_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostNestedOneofToCheckValidationSemanticsRequestBody(BaseApi): def post_nested_oneof_to_check_validation_semantics_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_nested_oneof_to_check_validation_semantics_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostNestedOneofToCheckValidationSemanticsRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_nested_oneof_to_check_validation_semantics_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostNestedOneofToCheckValidationSemanticsRequestBody(BaseApi): def post_nested_oneof_to_check_validation_semantics_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_not_more_complex_schema_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_not_more_complex_schema_request_body/post.py index 2c2fe381ed1..7d44a344cc2 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_not_more_complex_schema_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_not_more_complex_schema_request_body/post.py @@ -127,12 +127,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_not_more_complex_schema_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_not_more_complex_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -140,12 +151,13 @@ def _post_not_more_complex_schema_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_not_more_complex_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -154,7 +166,7 @@ def _post_not_more_complex_schema_request_body_oapg( def _post_not_more_complex_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -224,7 +236,19 @@ class PostNotMoreComplexSchemaRequestBody(BaseApi): def post_not_more_complex_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_not_more_complex_schema_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -232,12 +256,13 @@ def post_not_more_complex_schema_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_not_more_complex_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -246,7 +271,7 @@ def post_not_more_complex_schema_request_body( def post_not_more_complex_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -279,7 +304,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -287,12 +324,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -301,7 +339,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_not_more_complex_schema_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_not_more_complex_schema_request_body/post.pyi index 9468538912b..5f1d96b0b86 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_not_more_complex_schema_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_not_more_complex_schema_request_body/post.pyi @@ -122,12 +122,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_not_more_complex_schema_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_not_more_complex_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -135,12 +146,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_not_more_complex_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -149,7 +161,7 @@ class BaseApi(api_client.Api): def _post_not_more_complex_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -219,7 +231,19 @@ class PostNotMoreComplexSchemaRequestBody(BaseApi): def post_not_more_complex_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_not_more_complex_schema_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -227,12 +251,13 @@ class PostNotMoreComplexSchemaRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_not_more_complex_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -241,7 +266,7 @@ class PostNotMoreComplexSchemaRequestBody(BaseApi): def post_not_more_complex_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -274,7 +299,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -282,12 +319,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -296,7 +334,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_not_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_not_request_body/post.py index 6cb8918e276..1fdc4937405 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_not_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_not_request_body/post.py @@ -78,12 +78,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_not_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_not_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -91,12 +102,13 @@ def _post_not_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_not_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -105,7 +117,7 @@ def _post_not_request_body_oapg( def _post_not_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -175,7 +187,19 @@ class PostNotRequestBody(BaseApi): def post_not_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_not_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -183,12 +207,13 @@ def post_not_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_not_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -197,7 +222,7 @@ def post_not_request_body( def post_not_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -230,7 +255,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -238,12 +275,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -252,7 +290,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_not_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_not_request_body/post.pyi index 4ce42063404..ef2e02253ee 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_not_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_not_request_body/post.pyi @@ -73,12 +73,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_not_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_not_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -86,12 +97,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_not_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -100,7 +112,7 @@ class BaseApi(api_client.Api): def _post_not_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -170,7 +182,19 @@ class PostNotRequestBody(BaseApi): def post_not_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_not_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -178,12 +202,13 @@ class PostNotRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_not_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -192,7 +217,7 @@ class PostNotRequestBody(BaseApi): def post_not_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -225,7 +250,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -233,12 +270,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -247,7 +285,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nul_characters_in_strings_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nul_characters_in_strings_request_body/post.py index 629d2c7e575..d4b9e53a033 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nul_characters_in_strings_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nul_characters_in_strings_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_nul_characters_in_strings_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_nul_characters_in_strings_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_nul_characters_in_strings_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_nul_characters_in_strings_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_nul_characters_in_strings_request_body_oapg( def _post_nul_characters_in_strings_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostNulCharactersInStringsRequestBody(BaseApi): def post_nul_characters_in_strings_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_nul_characters_in_strings_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_nul_characters_in_strings_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_nul_characters_in_strings_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_nul_characters_in_strings_request_body( def post_nul_characters_in_strings_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nul_characters_in_strings_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nul_characters_in_strings_request_body/post.pyi index 5046f720311..7445caa5a56 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nul_characters_in_strings_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_nul_characters_in_strings_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_nul_characters_in_strings_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_nul_characters_in_strings_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_nul_characters_in_strings_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_nul_characters_in_strings_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostNulCharactersInStringsRequestBody(BaseApi): def post_nul_characters_in_strings_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_nul_characters_in_strings_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostNulCharactersInStringsRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_nul_characters_in_strings_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostNulCharactersInStringsRequestBody(BaseApi): def post_nul_characters_in_strings_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_null_type_matches_only_the_null_object_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_null_type_matches_only_the_null_object_request_body/post.py index e71755ab06d..c94d8b66af9 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_null_type_matches_only_the_null_object_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_null_type_matches_only_the_null_object_request_body/post.py @@ -56,12 +56,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_null_type_matches_only_the_null_object_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,None, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_null_type_matches_only_the_null_object_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,None, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -69,12 +80,13 @@ def _post_null_type_matches_only_the_null_object_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_null_type_matches_only_the_null_object_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,None, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -83,7 +95,7 @@ def _post_null_type_matches_only_the_null_object_request_body_oapg( def _post_null_type_matches_only_the_null_object_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,None, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -153,7 +165,19 @@ class PostNullTypeMatchesOnlyTheNullObjectRequestBody(BaseApi): def post_null_type_matches_only_the_null_object_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,None, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_null_type_matches_only_the_null_object_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,None, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -161,12 +185,13 @@ def post_null_type_matches_only_the_null_object_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_null_type_matches_only_the_null_object_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,None, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -175,7 +200,7 @@ def post_null_type_matches_only_the_null_object_request_body( def post_null_type_matches_only_the_null_object_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,None, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -208,7 +233,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,None, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,None, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -216,12 +253,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,None, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -230,7 +268,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,None, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_null_type_matches_only_the_null_object_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_null_type_matches_only_the_null_object_request_body/post.pyi index 44020e33771..6adc097d24b 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_null_type_matches_only_the_null_object_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_null_type_matches_only_the_null_object_request_body/post.pyi @@ -51,12 +51,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_null_type_matches_only_the_null_object_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,None, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_null_type_matches_only_the_null_object_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,None, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -64,12 +75,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_null_type_matches_only_the_null_object_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,None, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -78,7 +90,7 @@ class BaseApi(api_client.Api): def _post_null_type_matches_only_the_null_object_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,None, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -148,7 +160,19 @@ class PostNullTypeMatchesOnlyTheNullObjectRequestBody(BaseApi): def post_null_type_matches_only_the_null_object_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,None, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_null_type_matches_only_the_null_object_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,None, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -156,12 +180,13 @@ class PostNullTypeMatchesOnlyTheNullObjectRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_null_type_matches_only_the_null_object_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,None, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -170,7 +195,7 @@ class PostNullTypeMatchesOnlyTheNullObjectRequestBody(BaseApi): def post_null_type_matches_only_the_null_object_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,None, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -203,7 +228,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,None, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,None, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -211,12 +248,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,None, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -225,7 +263,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,None, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_number_type_matches_numbers_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_number_type_matches_numbers_request_body/post.py index 1b56d5ecb9a..1ca41209480 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_number_type_matches_numbers_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_number_type_matches_numbers_request_body/post.py @@ -56,12 +56,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_number_type_matches_numbers_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, float, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_number_type_matches_numbers_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, float, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -69,12 +80,13 @@ def _post_number_type_matches_numbers_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_number_type_matches_numbers_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, float, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -83,7 +95,7 @@ def _post_number_type_matches_numbers_request_body_oapg( def _post_number_type_matches_numbers_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, float, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -153,7 +165,19 @@ class PostNumberTypeMatchesNumbersRequestBody(BaseApi): def post_number_type_matches_numbers_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, float, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_number_type_matches_numbers_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, float, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -161,12 +185,13 @@ def post_number_type_matches_numbers_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_number_type_matches_numbers_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, float, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -175,7 +200,7 @@ def post_number_type_matches_numbers_request_body( def post_number_type_matches_numbers_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, float, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -208,7 +233,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, float, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, float, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -216,12 +253,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, float, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -230,7 +268,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, float, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_number_type_matches_numbers_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_number_type_matches_numbers_request_body/post.pyi index a7e58dd1c00..f4f08b5ead6 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_number_type_matches_numbers_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_number_type_matches_numbers_request_body/post.pyi @@ -51,12 +51,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_number_type_matches_numbers_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, float, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_number_type_matches_numbers_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, float, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -64,12 +75,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_number_type_matches_numbers_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, float, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -78,7 +90,7 @@ class BaseApi(api_client.Api): def _post_number_type_matches_numbers_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, float, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -148,7 +160,19 @@ class PostNumberTypeMatchesNumbersRequestBody(BaseApi): def post_number_type_matches_numbers_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, float, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_number_type_matches_numbers_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, float, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -156,12 +180,13 @@ class PostNumberTypeMatchesNumbersRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_number_type_matches_numbers_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, float, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -170,7 +195,7 @@ class PostNumberTypeMatchesNumbersRequestBody(BaseApi): def post_number_type_matches_numbers_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, float, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -203,7 +228,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, float, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, float, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -211,12 +248,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, float, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -225,7 +263,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,decimal.Decimal, int, float, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_object_properties_validation_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_object_properties_validation_request_body/post.py index a64b665f23b..6b2af7b5d7a 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_object_properties_validation_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_object_properties_validation_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_object_properties_validation_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_object_properties_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_object_properties_validation_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_object_properties_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_object_properties_validation_request_body_oapg( def _post_object_properties_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostObjectPropertiesValidationRequestBody(BaseApi): def post_object_properties_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_object_properties_validation_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_object_properties_validation_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_object_properties_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_object_properties_validation_request_body( def post_object_properties_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_object_properties_validation_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_object_properties_validation_request_body/post.pyi index f75e4ad9042..0a0ecb89fee 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_object_properties_validation_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_object_properties_validation_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_object_properties_validation_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_object_properties_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_object_properties_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_object_properties_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostObjectPropertiesValidationRequestBody(BaseApi): def post_object_properties_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_object_properties_validation_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostObjectPropertiesValidationRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_object_properties_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostObjectPropertiesValidationRequestBody(BaseApi): def post_object_properties_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_object_type_matches_objects_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_object_type_matches_objects_request_body/post.py index 50cdeeda98e..9458ed3bdbb 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_object_type_matches_objects_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_object_type_matches_objects_request_body/post.py @@ -56,12 +56,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_object_type_matches_objects_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_object_type_matches_objects_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -69,12 +80,13 @@ def _post_object_type_matches_objects_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_object_type_matches_objects_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -83,7 +95,7 @@ def _post_object_type_matches_objects_request_body_oapg( def _post_object_type_matches_objects_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -153,7 +165,19 @@ class PostObjectTypeMatchesObjectsRequestBody(BaseApi): def post_object_type_matches_objects_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_object_type_matches_objects_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -161,12 +185,13 @@ def post_object_type_matches_objects_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_object_type_matches_objects_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -175,7 +200,7 @@ def post_object_type_matches_objects_request_body( def post_object_type_matches_objects_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -208,7 +233,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -216,12 +253,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -230,7 +268,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_object_type_matches_objects_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_object_type_matches_objects_request_body/post.pyi index 0e1ff6ed772..26a3aa0e9d7 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_object_type_matches_objects_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_object_type_matches_objects_request_body/post.pyi @@ -51,12 +51,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_object_type_matches_objects_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_object_type_matches_objects_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -64,12 +75,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_object_type_matches_objects_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -78,7 +90,7 @@ class BaseApi(api_client.Api): def _post_object_type_matches_objects_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -148,7 +160,19 @@ class PostObjectTypeMatchesObjectsRequestBody(BaseApi): def post_object_type_matches_objects_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_object_type_matches_objects_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -156,12 +180,13 @@ class PostObjectTypeMatchesObjectsRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_object_type_matches_objects_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -170,7 +195,7 @@ class PostObjectTypeMatchesObjectsRequestBody(BaseApi): def post_object_type_matches_objects_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -203,7 +228,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -211,12 +248,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -225,7 +263,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_complex_types_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_complex_types_request_body/post.py index d6e37b96a56..1e9c85a757b 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_complex_types_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_complex_types_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_oneof_complex_types_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_oneof_complex_types_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_oneof_complex_types_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_oneof_complex_types_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_oneof_complex_types_request_body_oapg( def _post_oneof_complex_types_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostOneofComplexTypesRequestBody(BaseApi): def post_oneof_complex_types_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_oneof_complex_types_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_oneof_complex_types_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_oneof_complex_types_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_oneof_complex_types_request_body( def post_oneof_complex_types_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_complex_types_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_complex_types_request_body/post.pyi index d94b43b2b8a..5c61455e783 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_complex_types_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_complex_types_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_oneof_complex_types_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_oneof_complex_types_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_oneof_complex_types_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_oneof_complex_types_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostOneofComplexTypesRequestBody(BaseApi): def post_oneof_complex_types_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_oneof_complex_types_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostOneofComplexTypesRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_oneof_complex_types_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostOneofComplexTypesRequestBody(BaseApi): def post_oneof_complex_types_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_request_body/post.py index 173dd96a325..bc372832e58 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_oneof_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_oneof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_oneof_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_oneof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_oneof_request_body_oapg( def _post_oneof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostOneofRequestBody(BaseApi): def post_oneof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_oneof_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_oneof_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_oneof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_oneof_request_body( def post_oneof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_request_body/post.pyi index b5a10aa392f..78a9a83c941 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_oneof_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_oneof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_oneof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_oneof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostOneofRequestBody(BaseApi): def post_oneof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_oneof_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostOneofRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_oneof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostOneofRequestBody(BaseApi): def post_oneof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_with_base_schema_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_with_base_schema_request_body/post.py index 6e2a8070516..8d00db16b53 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_with_base_schema_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_with_base_schema_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_oneof_with_base_schema_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_oneof_with_base_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_oneof_with_base_schema_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_oneof_with_base_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_oneof_with_base_schema_request_body_oapg( def _post_oneof_with_base_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostOneofWithBaseSchemaRequestBody(BaseApi): def post_oneof_with_base_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_oneof_with_base_schema_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_oneof_with_base_schema_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_oneof_with_base_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_oneof_with_base_schema_request_body( def post_oneof_with_base_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_with_base_schema_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_with_base_schema_request_body/post.pyi index 3c925a0472e..0d4fe45599d 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_with_base_schema_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_with_base_schema_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_oneof_with_base_schema_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_oneof_with_base_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_oneof_with_base_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_oneof_with_base_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostOneofWithBaseSchemaRequestBody(BaseApi): def post_oneof_with_base_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_oneof_with_base_schema_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostOneofWithBaseSchemaRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_oneof_with_base_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostOneofWithBaseSchemaRequestBody(BaseApi): def post_oneof_with_base_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_with_empty_schema_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_with_empty_schema_request_body/post.py index b8c90b8951c..de00a1e19e9 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_with_empty_schema_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_with_empty_schema_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_oneof_with_empty_schema_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_oneof_with_empty_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_oneof_with_empty_schema_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_oneof_with_empty_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_oneof_with_empty_schema_request_body_oapg( def _post_oneof_with_empty_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostOneofWithEmptySchemaRequestBody(BaseApi): def post_oneof_with_empty_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_oneof_with_empty_schema_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_oneof_with_empty_schema_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_oneof_with_empty_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_oneof_with_empty_schema_request_body( def post_oneof_with_empty_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_with_empty_schema_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_with_empty_schema_request_body/post.pyi index 7bc026aeee4..2d419104035 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_with_empty_schema_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_with_empty_schema_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_oneof_with_empty_schema_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_oneof_with_empty_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_oneof_with_empty_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_oneof_with_empty_schema_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostOneofWithEmptySchemaRequestBody(BaseApi): def post_oneof_with_empty_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_oneof_with_empty_schema_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostOneofWithEmptySchemaRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_oneof_with_empty_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostOneofWithEmptySchemaRequestBody(BaseApi): def post_oneof_with_empty_schema_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_with_required_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_with_required_request_body/post.py index 2360d791ba7..e32e6df399a 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_with_required_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_with_required_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_oneof_with_required_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_oneof_with_required_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_oneof_with_required_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_oneof_with_required_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_oneof_with_required_request_body_oapg( def _post_oneof_with_required_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostOneofWithRequiredRequestBody(BaseApi): def post_oneof_with_required_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_oneof_with_required_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_oneof_with_required_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_oneof_with_required_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_oneof_with_required_request_body( def post_oneof_with_required_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_with_required_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_with_required_request_body/post.pyi index e1a567e5906..b75ad8f9a94 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_with_required_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_oneof_with_required_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_oneof_with_required_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_oneof_with_required_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_oneof_with_required_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_oneof_with_required_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostOneofWithRequiredRequestBody(BaseApi): def post_oneof_with_required_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_oneof_with_required_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostOneofWithRequiredRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_oneof_with_required_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostOneofWithRequiredRequestBody(BaseApi): def post_oneof_with_required_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_pattern_is_not_anchored_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_pattern_is_not_anchored_request_body/post.py index 3db1f3865f9..c5120a7acd7 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_pattern_is_not_anchored_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_pattern_is_not_anchored_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_pattern_is_not_anchored_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_pattern_is_not_anchored_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_pattern_is_not_anchored_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_pattern_is_not_anchored_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_pattern_is_not_anchored_request_body_oapg( def _post_pattern_is_not_anchored_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostPatternIsNotAnchoredRequestBody(BaseApi): def post_pattern_is_not_anchored_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_pattern_is_not_anchored_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_pattern_is_not_anchored_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_pattern_is_not_anchored_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_pattern_is_not_anchored_request_body( def post_pattern_is_not_anchored_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_pattern_is_not_anchored_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_pattern_is_not_anchored_request_body/post.pyi index ae58792b58a..1848470356a 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_pattern_is_not_anchored_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_pattern_is_not_anchored_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_pattern_is_not_anchored_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_pattern_is_not_anchored_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_pattern_is_not_anchored_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_pattern_is_not_anchored_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostPatternIsNotAnchoredRequestBody(BaseApi): def post_pattern_is_not_anchored_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_pattern_is_not_anchored_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostPatternIsNotAnchoredRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_pattern_is_not_anchored_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostPatternIsNotAnchoredRequestBody(BaseApi): def post_pattern_is_not_anchored_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_pattern_validation_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_pattern_validation_request_body/post.py index e9629cb6f62..422b433e46e 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_pattern_validation_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_pattern_validation_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_pattern_validation_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_pattern_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_pattern_validation_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_pattern_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_pattern_validation_request_body_oapg( def _post_pattern_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostPatternValidationRequestBody(BaseApi): def post_pattern_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_pattern_validation_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_pattern_validation_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_pattern_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_pattern_validation_request_body( def post_pattern_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_pattern_validation_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_pattern_validation_request_body/post.pyi index 1974f67e70b..d8126709666 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_pattern_validation_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_pattern_validation_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_pattern_validation_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_pattern_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_pattern_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_pattern_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostPatternValidationRequestBody(BaseApi): def post_pattern_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_pattern_validation_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostPatternValidationRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_pattern_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostPatternValidationRequestBody(BaseApi): def post_pattern_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_properties_with_escaped_characters_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_properties_with_escaped_characters_request_body/post.py index 5a8c2490cb7..bcc74a2ae9f 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_properties_with_escaped_characters_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_properties_with_escaped_characters_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_properties_with_escaped_characters_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_properties_with_escaped_characters_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_properties_with_escaped_characters_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_properties_with_escaped_characters_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_properties_with_escaped_characters_request_body_oapg( def _post_properties_with_escaped_characters_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostPropertiesWithEscapedCharactersRequestBody(BaseApi): def post_properties_with_escaped_characters_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_properties_with_escaped_characters_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_properties_with_escaped_characters_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_properties_with_escaped_characters_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_properties_with_escaped_characters_request_body( def post_properties_with_escaped_characters_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_properties_with_escaped_characters_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_properties_with_escaped_characters_request_body/post.pyi index 97edc8083f5..1bab1c15f17 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_properties_with_escaped_characters_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_properties_with_escaped_characters_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_properties_with_escaped_characters_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_properties_with_escaped_characters_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_properties_with_escaped_characters_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_properties_with_escaped_characters_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostPropertiesWithEscapedCharactersRequestBody(BaseApi): def post_properties_with_escaped_characters_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_properties_with_escaped_characters_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostPropertiesWithEscapedCharactersRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_properties_with_escaped_characters_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostPropertiesWithEscapedCharactersRequestBody(BaseApi): def post_properties_with_escaped_characters_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_property_named_ref_that_is_not_a_reference_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_property_named_ref_that_is_not_a_reference_request_body/post.py index ed971775015..a176ec4b34e 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_property_named_ref_that_is_not_a_reference_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_property_named_ref_that_is_not_a_reference_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_property_named_ref_that_is_not_a_reference_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_property_named_ref_that_is_not_a_reference_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_property_named_ref_that_is_not_a_reference_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_property_named_ref_that_is_not_a_reference_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_property_named_ref_that_is_not_a_reference_request_body_oapg( def _post_property_named_ref_that_is_not_a_reference_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostPropertyNamedRefThatIsNotAReferenceRequestBody(BaseApi): def post_property_named_ref_that_is_not_a_reference_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_property_named_ref_that_is_not_a_reference_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_property_named_ref_that_is_not_a_reference_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_property_named_ref_that_is_not_a_reference_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_property_named_ref_that_is_not_a_reference_request_body( def post_property_named_ref_that_is_not_a_reference_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_property_named_ref_that_is_not_a_reference_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_property_named_ref_that_is_not_a_reference_request_body/post.pyi index 268ca56dfc3..ff3985bce85 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_property_named_ref_that_is_not_a_reference_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_property_named_ref_that_is_not_a_reference_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_property_named_ref_that_is_not_a_reference_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_property_named_ref_that_is_not_a_reference_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_property_named_ref_that_is_not_a_reference_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_property_named_ref_that_is_not_a_reference_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostPropertyNamedRefThatIsNotAReferenceRequestBody(BaseApi): def post_property_named_ref_that_is_not_a_reference_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_property_named_ref_that_is_not_a_reference_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostPropertyNamedRefThatIsNotAReferenceRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_property_named_ref_that_is_not_a_reference_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostPropertyNamedRefThatIsNotAReferenceRequestBody(BaseApi): def post_property_named_ref_that_is_not_a_reference_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_additionalproperties_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_additionalproperties_request_body/post.py index 9cd3bb014ec..baae0992b51 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_additionalproperties_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_additionalproperties_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_ref_in_additionalproperties_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_ref_in_additionalproperties_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_ref_in_additionalproperties_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_ref_in_additionalproperties_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_ref_in_additionalproperties_request_body_oapg( def _post_ref_in_additionalproperties_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostRefInAdditionalpropertiesRequestBody(BaseApi): def post_ref_in_additionalproperties_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_ref_in_additionalproperties_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_ref_in_additionalproperties_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_ref_in_additionalproperties_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_ref_in_additionalproperties_request_body( def post_ref_in_additionalproperties_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_additionalproperties_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_additionalproperties_request_body/post.pyi index 47c68cbdaf9..ae66e236baa 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_additionalproperties_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_additionalproperties_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_ref_in_additionalproperties_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_ref_in_additionalproperties_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_ref_in_additionalproperties_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_ref_in_additionalproperties_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostRefInAdditionalpropertiesRequestBody(BaseApi): def post_ref_in_additionalproperties_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_ref_in_additionalproperties_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostRefInAdditionalpropertiesRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_ref_in_additionalproperties_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostRefInAdditionalpropertiesRequestBody(BaseApi): def post_ref_in_additionalproperties_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_allof_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_allof_request_body/post.py index 232a19b5601..32d5d6cba98 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_allof_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_allof_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_ref_in_allof_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_ref_in_allof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_ref_in_allof_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_ref_in_allof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_ref_in_allof_request_body_oapg( def _post_ref_in_allof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostRefInAllofRequestBody(BaseApi): def post_ref_in_allof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_ref_in_allof_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_ref_in_allof_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_ref_in_allof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_ref_in_allof_request_body( def post_ref_in_allof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_allof_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_allof_request_body/post.pyi index 08ed46860d9..6eddfe043b5 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_allof_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_allof_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_ref_in_allof_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_ref_in_allof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_ref_in_allof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_ref_in_allof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostRefInAllofRequestBody(BaseApi): def post_ref_in_allof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_ref_in_allof_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostRefInAllofRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_ref_in_allof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostRefInAllofRequestBody(BaseApi): def post_ref_in_allof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_anyof_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_anyof_request_body/post.py index c5fef8df9ff..c61b0c03460 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_anyof_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_anyof_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_ref_in_anyof_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_ref_in_anyof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_ref_in_anyof_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_ref_in_anyof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_ref_in_anyof_request_body_oapg( def _post_ref_in_anyof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostRefInAnyofRequestBody(BaseApi): def post_ref_in_anyof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_ref_in_anyof_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_ref_in_anyof_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_ref_in_anyof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_ref_in_anyof_request_body( def post_ref_in_anyof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_anyof_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_anyof_request_body/post.pyi index 65e74720209..61d129a8cd2 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_anyof_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_anyof_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_ref_in_anyof_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_ref_in_anyof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_ref_in_anyof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_ref_in_anyof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostRefInAnyofRequestBody(BaseApi): def post_ref_in_anyof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_ref_in_anyof_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostRefInAnyofRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_ref_in_anyof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostRefInAnyofRequestBody(BaseApi): def post_ref_in_anyof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_items_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_items_request_body/post.py index 218b3e6114d..3cf5261cef9 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_items_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_items_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_ref_in_items_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_ref_in_items_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_ref_in_items_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_ref_in_items_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_ref_in_items_request_body_oapg( def _post_ref_in_items_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostRefInItemsRequestBody(BaseApi): def post_ref_in_items_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_ref_in_items_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_ref_in_items_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_ref_in_items_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_ref_in_items_request_body( def post_ref_in_items_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_items_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_items_request_body/post.pyi index 6b226043a31..b41e000b84b 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_items_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_items_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_ref_in_items_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_ref_in_items_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_ref_in_items_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_ref_in_items_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostRefInItemsRequestBody(BaseApi): def post_ref_in_items_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_ref_in_items_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostRefInItemsRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_ref_in_items_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostRefInItemsRequestBody(BaseApi): def post_ref_in_items_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_not_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_not_request_body/post.py index a301f82abf1..16778e01bf1 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_not_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_not_request_body/post.py @@ -83,12 +83,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_ref_in_not_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_ref_in_not_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -96,12 +107,13 @@ def _post_ref_in_not_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_ref_in_not_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -110,7 +122,7 @@ def _post_ref_in_not_request_body_oapg( def _post_ref_in_not_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -180,7 +192,19 @@ class PostRefInNotRequestBody(BaseApi): def post_ref_in_not_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_ref_in_not_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -188,12 +212,13 @@ def post_ref_in_not_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_ref_in_not_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -202,7 +227,7 @@ def post_ref_in_not_request_body( def post_ref_in_not_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -235,7 +260,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -243,12 +280,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -257,7 +295,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_not_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_not_request_body/post.pyi index 05467bf42ba..18e7489d24a 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_not_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_not_request_body/post.pyi @@ -78,12 +78,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_ref_in_not_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_ref_in_not_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -91,12 +102,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_ref_in_not_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -105,7 +117,7 @@ class BaseApi(api_client.Api): def _post_ref_in_not_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -175,7 +187,19 @@ class PostRefInNotRequestBody(BaseApi): def post_ref_in_not_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_ref_in_not_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -183,12 +207,13 @@ class PostRefInNotRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_ref_in_not_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -197,7 +222,7 @@ class PostRefInNotRequestBody(BaseApi): def post_ref_in_not_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -230,7 +255,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -238,12 +275,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -252,7 +290,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_oneof_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_oneof_request_body/post.py index 1bbd37a6163..f1dc48460c4 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_oneof_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_oneof_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_ref_in_oneof_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_ref_in_oneof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_ref_in_oneof_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_ref_in_oneof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_ref_in_oneof_request_body_oapg( def _post_ref_in_oneof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostRefInOneofRequestBody(BaseApi): def post_ref_in_oneof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_ref_in_oneof_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_ref_in_oneof_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_ref_in_oneof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_ref_in_oneof_request_body( def post_ref_in_oneof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_oneof_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_oneof_request_body/post.pyi index 607ece661a1..e3ca8f0a1bc 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_oneof_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_oneof_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_ref_in_oneof_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_ref_in_oneof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_ref_in_oneof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_ref_in_oneof_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostRefInOneofRequestBody(BaseApi): def post_ref_in_oneof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_ref_in_oneof_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostRefInOneofRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_ref_in_oneof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostRefInOneofRequestBody(BaseApi): def post_ref_in_oneof_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_property_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_property_request_body/post.py index b1818bfb1d3..bc58c723b40 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_property_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_property_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_ref_in_property_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_ref_in_property_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_ref_in_property_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_ref_in_property_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_ref_in_property_request_body_oapg( def _post_ref_in_property_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostRefInPropertyRequestBody(BaseApi): def post_ref_in_property_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_ref_in_property_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_ref_in_property_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_ref_in_property_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_ref_in_property_request_body( def post_ref_in_property_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_property_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_property_request_body/post.pyi index d0671e63c79..105713baa0e 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_property_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_ref_in_property_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_ref_in_property_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_ref_in_property_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_ref_in_property_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_ref_in_property_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostRefInPropertyRequestBody(BaseApi): def post_ref_in_property_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_ref_in_property_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostRefInPropertyRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_ref_in_property_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostRefInPropertyRequestBody(BaseApi): def post_ref_in_property_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_default_validation_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_default_validation_request_body/post.py index 1a6c126ed80..b290ef0c3c6 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_default_validation_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_default_validation_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_required_default_validation_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_required_default_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_required_default_validation_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_required_default_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_required_default_validation_request_body_oapg( def _post_required_default_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostRequiredDefaultValidationRequestBody(BaseApi): def post_required_default_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_required_default_validation_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_required_default_validation_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_required_default_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_required_default_validation_request_body( def post_required_default_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_default_validation_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_default_validation_request_body/post.pyi index 888b1a186d0..78d8bb0262a 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_default_validation_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_default_validation_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_required_default_validation_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_required_default_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_required_default_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_required_default_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostRequiredDefaultValidationRequestBody(BaseApi): def post_required_default_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_required_default_validation_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostRequiredDefaultValidationRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_required_default_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostRequiredDefaultValidationRequestBody(BaseApi): def post_required_default_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_validation_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_validation_request_body/post.py index 33331c7cf2c..31366c3fd8b 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_validation_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_validation_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_required_validation_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_required_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_required_validation_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_required_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_required_validation_request_body_oapg( def _post_required_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostRequiredValidationRequestBody(BaseApi): def post_required_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_required_validation_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_required_validation_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_required_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_required_validation_request_body( def post_required_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_validation_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_validation_request_body/post.pyi index 9d4f459f1ea..a0149cd11b1 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_validation_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_validation_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_required_validation_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_required_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_required_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_required_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostRequiredValidationRequestBody(BaseApi): def post_required_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_required_validation_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostRequiredValidationRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_required_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostRequiredValidationRequestBody(BaseApi): def post_required_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_with_empty_array_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_with_empty_array_request_body/post.py index 126abd32a33..828d01bed20 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_with_empty_array_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_with_empty_array_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_required_with_empty_array_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_required_with_empty_array_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_required_with_empty_array_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_required_with_empty_array_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_required_with_empty_array_request_body_oapg( def _post_required_with_empty_array_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostRequiredWithEmptyArrayRequestBody(BaseApi): def post_required_with_empty_array_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_required_with_empty_array_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_required_with_empty_array_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_required_with_empty_array_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_required_with_empty_array_request_body( def post_required_with_empty_array_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_with_empty_array_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_with_empty_array_request_body/post.pyi index 2963071c401..6490beb525f 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_with_empty_array_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_with_empty_array_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_required_with_empty_array_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_required_with_empty_array_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_required_with_empty_array_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_required_with_empty_array_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostRequiredWithEmptyArrayRequestBody(BaseApi): def post_required_with_empty_array_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_required_with_empty_array_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostRequiredWithEmptyArrayRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_required_with_empty_array_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostRequiredWithEmptyArrayRequestBody(BaseApi): def post_required_with_empty_array_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_with_escaped_characters_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_with_escaped_characters_request_body/post.py index a072dc49ec7..5546b1c7222 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_with_escaped_characters_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_with_escaped_characters_request_body/post.py @@ -86,12 +86,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_required_with_escaped_characters_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_required_with_escaped_characters_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -99,12 +110,13 @@ def _post_required_with_escaped_characters_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_required_with_escaped_characters_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -113,7 +125,7 @@ def _post_required_with_escaped_characters_request_body_oapg( def _post_required_with_escaped_characters_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -183,7 +195,19 @@ class PostRequiredWithEscapedCharactersRequestBody(BaseApi): def post_required_with_escaped_characters_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_required_with_escaped_characters_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -191,12 +215,13 @@ def post_required_with_escaped_characters_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_required_with_escaped_characters_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -205,7 +230,7 @@ def post_required_with_escaped_characters_request_body( def post_required_with_escaped_characters_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -238,7 +263,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -246,12 +283,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -260,7 +298,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_with_escaped_characters_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_with_escaped_characters_request_body/post.pyi index 4b7986bab52..4b9319331a9 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_with_escaped_characters_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_required_with_escaped_characters_request_body/post.pyi @@ -81,12 +81,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_required_with_escaped_characters_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_required_with_escaped_characters_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -94,12 +105,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_required_with_escaped_characters_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -108,7 +120,7 @@ class BaseApi(api_client.Api): def _post_required_with_escaped_characters_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -178,7 +190,19 @@ class PostRequiredWithEscapedCharactersRequestBody(BaseApi): def post_required_with_escaped_characters_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_required_with_escaped_characters_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -186,12 +210,13 @@ class PostRequiredWithEscapedCharactersRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_required_with_escaped_characters_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -200,7 +225,7 @@ class PostRequiredWithEscapedCharactersRequestBody(BaseApi): def post_required_with_escaped_characters_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -233,7 +258,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -241,12 +278,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -255,7 +293,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_simple_enum_validation_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_simple_enum_validation_request_body/post.py index 5b858fea214..48ce45ab21c 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_simple_enum_validation_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_simple_enum_validation_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_simple_enum_validation_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_simple_enum_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_simple_enum_validation_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_simple_enum_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_simple_enum_validation_request_body_oapg( def _post_simple_enum_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostSimpleEnumValidationRequestBody(BaseApi): def post_simple_enum_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_simple_enum_validation_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_simple_enum_validation_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_simple_enum_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_simple_enum_validation_request_body( def post_simple_enum_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_simple_enum_validation_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_simple_enum_validation_request_body/post.pyi index 2169b573b32..b0ba5e5753f 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_simple_enum_validation_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_simple_enum_validation_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_simple_enum_validation_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_simple_enum_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_simple_enum_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_simple_enum_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostSimpleEnumValidationRequestBody(BaseApi): def post_simple_enum_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_simple_enum_validation_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostSimpleEnumValidationRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_simple_enum_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostSimpleEnumValidationRequestBody(BaseApi): def post_simple_enum_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_string_type_matches_strings_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_string_type_matches_strings_request_body/post.py index 4c1eb834534..6db3472e65c 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_string_type_matches_strings_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_string_type_matches_strings_request_body/post.py @@ -56,12 +56,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_string_type_matches_strings_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,str, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_string_type_matches_strings_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,str, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -69,12 +80,13 @@ def _post_string_type_matches_strings_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_string_type_matches_strings_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,str, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -83,7 +95,7 @@ def _post_string_type_matches_strings_request_body_oapg( def _post_string_type_matches_strings_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,str, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -153,7 +165,19 @@ class PostStringTypeMatchesStringsRequestBody(BaseApi): def post_string_type_matches_strings_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,str, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_string_type_matches_strings_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,str, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -161,12 +185,13 @@ def post_string_type_matches_strings_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_string_type_matches_strings_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,str, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -175,7 +200,7 @@ def post_string_type_matches_strings_request_body( def post_string_type_matches_strings_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,str, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -208,7 +233,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,str, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,str, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -216,12 +253,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,str, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -230,7 +268,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,str, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_string_type_matches_strings_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_string_type_matches_strings_request_body/post.pyi index 616fe4240fb..241d59964c4 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_string_type_matches_strings_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_string_type_matches_strings_request_body/post.pyi @@ -51,12 +51,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_string_type_matches_strings_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,str, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_string_type_matches_strings_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,str, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -64,12 +75,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_string_type_matches_strings_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,str, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -78,7 +90,7 @@ class BaseApi(api_client.Api): def _post_string_type_matches_strings_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,str, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -148,7 +160,19 @@ class PostStringTypeMatchesStringsRequestBody(BaseApi): def post_string_type_matches_strings_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,str, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_string_type_matches_strings_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,str, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -156,12 +180,13 @@ class PostStringTypeMatchesStringsRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_string_type_matches_strings_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,str, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -170,7 +195,7 @@ class PostStringTypeMatchesStringsRequestBody(BaseApi): def post_string_type_matches_strings_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,str, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -203,7 +228,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,str, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,str, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -211,12 +248,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,str, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -225,7 +263,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,str, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_request_body/post.py index 05e8a4d75c9..baaf238e68f 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_re ApiResponseFor200, ]: ... + @typing.overload def _post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_re def _post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostTheDefaultKeywordDoesNotDoAnythingIfThePropertyIsMissingRequestBody(Ba def post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_req ApiResponseFor200, ]: ... + @typing.overload def post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_req def post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_request_body/post.pyi index df00d506b89..50cbe145335 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostTheDefaultKeywordDoesNotDoAnythingIfThePropertyIsMissingRequestBody(Ba def post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostTheDefaultKeywordDoesNotDoAnythingIfThePropertyIsMissingRequestBody(Ba ApiResponseFor200, ]: ... + @typing.overload def post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostTheDefaultKeywordDoesNotDoAnythingIfThePropertyIsMissingRequestBody(Ba def post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uniqueitems_false_validation_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uniqueitems_false_validation_request_body/post.py index e16787335e5..2d9e8e8482d 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uniqueitems_false_validation_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uniqueitems_false_validation_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_uniqueitems_false_validation_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_uniqueitems_false_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_uniqueitems_false_validation_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_uniqueitems_false_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_uniqueitems_false_validation_request_body_oapg( def _post_uniqueitems_false_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostUniqueitemsFalseValidationRequestBody(BaseApi): def post_uniqueitems_false_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_uniqueitems_false_validation_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_uniqueitems_false_validation_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_uniqueitems_false_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_uniqueitems_false_validation_request_body( def post_uniqueitems_false_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uniqueitems_false_validation_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uniqueitems_false_validation_request_body/post.pyi index 1e3fb428d83..f1cb3b3ce33 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uniqueitems_false_validation_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uniqueitems_false_validation_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_uniqueitems_false_validation_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_uniqueitems_false_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_uniqueitems_false_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_uniqueitems_false_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostUniqueitemsFalseValidationRequestBody(BaseApi): def post_uniqueitems_false_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_uniqueitems_false_validation_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostUniqueitemsFalseValidationRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_uniqueitems_false_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostUniqueitemsFalseValidationRequestBody(BaseApi): def post_uniqueitems_false_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uniqueitems_validation_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uniqueitems_validation_request_body/post.py index 2383bc22689..75738c89064 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uniqueitems_validation_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uniqueitems_validation_request_body/post.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_uniqueitems_validation_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_uniqueitems_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _post_uniqueitems_validation_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_uniqueitems_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _post_uniqueitems_validation_request_body_oapg( def _post_uniqueitems_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class PostUniqueitemsValidationRequestBody(BaseApi): def post_uniqueitems_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_uniqueitems_validation_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def post_uniqueitems_validation_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_uniqueitems_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def post_uniqueitems_validation_request_body( def post_uniqueitems_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uniqueitems_validation_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uniqueitems_validation_request_body/post.pyi index 5b9af332a04..471f7aa06b0 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uniqueitems_validation_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uniqueitems_validation_request_body/post.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_uniqueitems_validation_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_uniqueitems_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_uniqueitems_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _post_uniqueitems_validation_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class PostUniqueitemsValidationRequestBody(BaseApi): def post_uniqueitems_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_uniqueitems_validation_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class PostUniqueitemsValidationRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_uniqueitems_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class PostUniqueitemsValidationRequestBody(BaseApi): def post_uniqueitems_validation_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uri_format_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uri_format_request_body/post.py index 377fac0268e..01f1e01a381 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uri_format_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uri_format_request_body/post.py @@ -78,12 +78,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_uri_format_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_uri_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -91,12 +102,13 @@ def _post_uri_format_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_uri_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -105,7 +117,7 @@ def _post_uri_format_request_body_oapg( def _post_uri_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -175,7 +187,19 @@ class PostUriFormatRequestBody(BaseApi): def post_uri_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_uri_format_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -183,12 +207,13 @@ def post_uri_format_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_uri_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -197,7 +222,7 @@ def post_uri_format_request_body( def post_uri_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -230,7 +255,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -238,12 +275,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -252,7 +290,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uri_format_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uri_format_request_body/post.pyi index f9e1209a407..bd57141d4ff 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uri_format_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uri_format_request_body/post.pyi @@ -73,12 +73,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_uri_format_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_uri_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -86,12 +97,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_uri_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -100,7 +112,7 @@ class BaseApi(api_client.Api): def _post_uri_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -170,7 +182,19 @@ class PostUriFormatRequestBody(BaseApi): def post_uri_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_uri_format_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -178,12 +202,13 @@ class PostUriFormatRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_uri_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -192,7 +217,7 @@ class PostUriFormatRequestBody(BaseApi): def post_uri_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -225,7 +250,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -233,12 +270,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -247,7 +285,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uri_reference_format_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uri_reference_format_request_body/post.py index 91e5b1f3f66..ac7b2ca12ed 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uri_reference_format_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uri_reference_format_request_body/post.py @@ -78,12 +78,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_uri_reference_format_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_uri_reference_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -91,12 +102,13 @@ def _post_uri_reference_format_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_uri_reference_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -105,7 +117,7 @@ def _post_uri_reference_format_request_body_oapg( def _post_uri_reference_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -175,7 +187,19 @@ class PostUriReferenceFormatRequestBody(BaseApi): def post_uri_reference_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_uri_reference_format_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -183,12 +207,13 @@ def post_uri_reference_format_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_uri_reference_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -197,7 +222,7 @@ def post_uri_reference_format_request_body( def post_uri_reference_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -230,7 +255,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -238,12 +275,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -252,7 +290,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uri_reference_format_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uri_reference_format_request_body/post.pyi index f882bc6d3a5..32efe64f381 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uri_reference_format_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uri_reference_format_request_body/post.pyi @@ -73,12 +73,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_uri_reference_format_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_uri_reference_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -86,12 +97,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_uri_reference_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -100,7 +112,7 @@ class BaseApi(api_client.Api): def _post_uri_reference_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -170,7 +182,19 @@ class PostUriReferenceFormatRequestBody(BaseApi): def post_uri_reference_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_uri_reference_format_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -178,12 +202,13 @@ class PostUriReferenceFormatRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_uri_reference_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -192,7 +217,7 @@ class PostUriReferenceFormatRequestBody(BaseApi): def post_uri_reference_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -225,7 +250,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -233,12 +270,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -247,7 +285,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uri_template_format_request_body/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uri_template_format_request_body/post.py index ff5298c479c..ecbb8a59927 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uri_template_format_request_body/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uri_template_format_request_body/post.py @@ -78,12 +78,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_uri_template_format_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_uri_template_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -91,12 +102,13 @@ def _post_uri_template_format_request_body_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_uri_template_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -105,7 +117,7 @@ def _post_uri_template_format_request_body_oapg( def _post_uri_template_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -175,7 +187,19 @@ class PostUriTemplateFormatRequestBody(BaseApi): def post_uri_template_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_uri_template_format_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -183,12 +207,13 @@ def post_uri_template_format_request_body( ApiResponseFor200, ]: ... + @typing.overload def post_uri_template_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -197,7 +222,7 @@ def post_uri_template_format_request_body( def post_uri_template_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -230,7 +255,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -238,12 +275,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -252,7 +290,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uri_template_format_request_body/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uri_template_format_request_body/post.pyi index acfa09c9eb1..c11c280ca84 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uri_template_format_request_body/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/request_body_post_uri_template_format_request_body/post.pyi @@ -73,12 +73,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_uri_template_format_request_body_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_uri_template_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -86,12 +97,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_uri_template_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -100,7 +112,7 @@ class BaseApi(api_client.Api): def _post_uri_template_format_request_body_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -170,7 +182,19 @@ class PostUriTemplateFormatRequestBody(BaseApi): def post_uri_template_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_uri_template_format_request_body( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -178,12 +202,13 @@ class PostUriTemplateFormatRequestBody(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_uri_template_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -192,7 +217,7 @@ class PostUriTemplateFormatRequestBody(BaseApi): def post_uri_template_format_request_body( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -225,7 +250,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -233,12 +270,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -247,7 +285,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_allows_a_schema_which_should_validate_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_allows_a_schema_which_should_validate_response_body_for_content_types/post.py index a4fce955938..a26ef4d234b 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_allows_a_schema_which_should_validate_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_allows_a_schema_which_should_validate_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_additionalproperties_allows_a_schema_which_should_validate_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_allows_a_schema_which_should_validate_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_allows_a_schema_which_should_validate_response_body_for_content_types/post.pyi index dd7bfb3d9f1..d1507bf9f24 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_allows_a_schema_which_should_validate_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_allows_a_schema_which_should_validate_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_additionalproperties_allows_a_schema_which_should_validate_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_are_allowed_by_default_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_are_allowed_by_default_response_body_for_content_types/post.py index 67a6b75bfcf..dbe7ce6e679 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_are_allowed_by_default_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_are_allowed_by_default_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_additionalproperties_are_allowed_by_default_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_are_allowed_by_default_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_are_allowed_by_default_response_body_for_content_types/post.pyi index b89b8ec5e75..c248434a477 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_are_allowed_by_default_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_are_allowed_by_default_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_additionalproperties_are_allowed_by_default_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_can_exist_by_itself_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_can_exist_by_itself_response_body_for_content_types/post.py index b9606896680..a4195f8bec5 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_can_exist_by_itself_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_can_exist_by_itself_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_additionalproperties_can_exist_by_itself_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_can_exist_by_itself_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_can_exist_by_itself_response_body_for_content_types/post.pyi index dad941f6e07..82150f4679c 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_can_exist_by_itself_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_can_exist_by_itself_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_additionalproperties_can_exist_by_itself_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_should_not_look_in_applicators_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_should_not_look_in_applicators_response_body_for_content_types/post.py index 44fdcd70d12..3783c4bff5d 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_should_not_look_in_applicators_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_should_not_look_in_applicators_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_additionalproperties_should_not_look_in_applicators_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_should_not_look_in_applicators_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_should_not_look_in_applicators_response_body_for_content_types/post.pyi index b6645ca129f..901c227bbb0 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_should_not_look_in_applicators_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_additionalproperties_should_not_look_in_applicators_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_additionalproperties_should_not_look_in_applicators_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_combined_with_anyof_oneof_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_combined_with_anyof_oneof_response_body_for_content_types/post.py index af5644f8d9e..ea702207499 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_combined_with_anyof_oneof_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_combined_with_anyof_oneof_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_allof_combined_with_anyof_oneof_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_combined_with_anyof_oneof_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_combined_with_anyof_oneof_response_body_for_content_types/post.pyi index 2de2260002c..966c85fbffb 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_combined_with_anyof_oneof_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_combined_with_anyof_oneof_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_allof_combined_with_anyof_oneof_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_response_body_for_content_types/post.py index 0e81babeed2..4c7e1485151 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_allof_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_response_body_for_content_types/post.pyi index 2858896ccac..983e72c0242 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_allof_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_simple_types_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_simple_types_response_body_for_content_types/post.py index 20e5974ab28..04dc25c28db 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_simple_types_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_simple_types_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_allof_simple_types_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_simple_types_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_simple_types_response_body_for_content_types/post.pyi index 17a6e8b36bc..17fb582dc3f 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_simple_types_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_simple_types_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_allof_simple_types_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_base_schema_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_base_schema_response_body_for_content_types/post.py index 9fb797e257b..e0ec00ff541 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_base_schema_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_base_schema_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_allof_with_base_schema_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_base_schema_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_base_schema_response_body_for_content_types/post.pyi index 20dbbfe98ae..203f7e98338 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_base_schema_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_base_schema_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_allof_with_base_schema_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_one_empty_schema_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_one_empty_schema_response_body_for_content_types/post.py index 339898a0925..db5c47fe161 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_one_empty_schema_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_one_empty_schema_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_allof_with_one_empty_schema_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_one_empty_schema_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_one_empty_schema_response_body_for_content_types/post.pyi index 0c08d5de599..6458869c87e 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_one_empty_schema_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_one_empty_schema_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_allof_with_one_empty_schema_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_the_first_empty_schema_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_the_first_empty_schema_response_body_for_content_types/post.py index 65b2de3865c..1cc370ae259 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_the_first_empty_schema_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_the_first_empty_schema_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_allof_with_the_first_empty_schema_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_the_first_empty_schema_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_the_first_empty_schema_response_body_for_content_types/post.pyi index 94b7f7600d2..885e09eaa56 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_the_first_empty_schema_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_the_first_empty_schema_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_allof_with_the_first_empty_schema_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_the_last_empty_schema_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_the_last_empty_schema_response_body_for_content_types/post.py index ee10cc74fd7..8e550c0e2a1 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_the_last_empty_schema_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_the_last_empty_schema_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_allof_with_the_last_empty_schema_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_the_last_empty_schema_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_the_last_empty_schema_response_body_for_content_types/post.pyi index 4153299ab06..7ce32b96232 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_the_last_empty_schema_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_the_last_empty_schema_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_allof_with_the_last_empty_schema_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_two_empty_schemas_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_two_empty_schemas_response_body_for_content_types/post.py index 3f3adc32020..a8336a12848 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_two_empty_schemas_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_two_empty_schemas_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_allof_with_two_empty_schemas_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_two_empty_schemas_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_two_empty_schemas_response_body_for_content_types/post.pyi index 59481dcfd02..ad1d6400634 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_two_empty_schemas_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_allof_with_two_empty_schemas_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_allof_with_two_empty_schemas_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_complex_types_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_complex_types_response_body_for_content_types/post.py index c3fc01e8290..61104a1a4b7 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_complex_types_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_complex_types_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_anyof_complex_types_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_complex_types_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_complex_types_response_body_for_content_types/post.pyi index 2accabaa58a..686b9db9f72 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_complex_types_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_complex_types_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_anyof_complex_types_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_response_body_for_content_types/post.py index 4b59b7ea4f8..4f1056d49ae 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_anyof_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_response_body_for_content_types/post.pyi index 895e25c6d8f..d95e2fb2699 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_anyof_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_with_base_schema_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_with_base_schema_response_body_for_content_types/post.py index 0b5930c63a3..cb7e1a5bdb0 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_with_base_schema_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_with_base_schema_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_anyof_with_base_schema_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_with_base_schema_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_with_base_schema_response_body_for_content_types/post.pyi index 044069f7040..4a1ef408783 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_with_base_schema_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_with_base_schema_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_anyof_with_base_schema_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_with_one_empty_schema_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_with_one_empty_schema_response_body_for_content_types/post.py index b8a2df79626..dc5293f4aa8 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_with_one_empty_schema_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_with_one_empty_schema_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_anyof_with_one_empty_schema_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_with_one_empty_schema_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_with_one_empty_schema_response_body_for_content_types/post.pyi index a47b76ce5ef..2937f62ea24 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_with_one_empty_schema_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_anyof_with_one_empty_schema_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_anyof_with_one_empty_schema_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_array_type_matches_arrays_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_array_type_matches_arrays_response_body_for_content_types/post.py index e0716ea5554..5cc8abd84ad 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_array_type_matches_arrays_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_array_type_matches_arrays_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_array_type_matches_arrays_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_array_type_matches_arrays_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_array_type_matches_arrays_response_body_for_content_types/post.pyi index 73dd699826b..de0a2d58659 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_array_type_matches_arrays_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_array_type_matches_arrays_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_array_type_matches_arrays_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_boolean_type_matches_booleans_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_boolean_type_matches_booleans_response_body_for_content_types/post.py index 6b3f79115f4..db449dae16c 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_boolean_type_matches_booleans_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_boolean_type_matches_booleans_response_body_for_content_types/post.py @@ -55,7 +55,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_boolean_type_matches_booleans_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_boolean_type_matches_booleans_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_boolean_type_matches_booleans_response_body_for_content_types/post.pyi index 08c7936ce58..8a82428ed25 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_boolean_type_matches_booleans_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_boolean_type_matches_booleans_response_body_for_content_types/post.pyi @@ -50,7 +50,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_boolean_type_matches_booleans_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_by_int_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_by_int_response_body_for_content_types/post.py index 7c2ee69ec3c..7b335897403 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_by_int_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_by_int_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_by_int_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_by_int_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_by_int_response_body_for_content_types/post.pyi index addcd1abf57..ddbd6265458 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_by_int_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_by_int_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_by_int_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_by_number_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_by_number_response_body_for_content_types/post.py index b809067ac12..5ca4e97bda4 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_by_number_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_by_number_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_by_number_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_by_number_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_by_number_response_body_for_content_types/post.pyi index afa0f1dc0c8..3b889482a1b 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_by_number_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_by_number_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_by_number_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_by_small_number_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_by_small_number_response_body_for_content_types/post.py index c3eb14e08e7..919173804ef 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_by_small_number_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_by_small_number_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_by_small_number_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_by_small_number_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_by_small_number_response_body_for_content_types/post.pyi index 676d91afc69..624538655e4 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_by_small_number_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_by_small_number_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_by_small_number_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_date_time_format_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_date_time_format_response_body_for_content_types/post.py index 8a5c34274aa..76717401070 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_date_time_format_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_date_time_format_response_body_for_content_types/post.py @@ -78,7 +78,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_date_time_format_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_date_time_format_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_date_time_format_response_body_for_content_types/post.pyi index 104a7d80759..af7e94cd9ac 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_date_time_format_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_date_time_format_response_body_for_content_types/post.pyi @@ -73,7 +73,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_date_time_format_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_email_format_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_email_format_response_body_for_content_types/post.py index 6a0e73ced24..84ceb9f8533 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_email_format_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_email_format_response_body_for_content_types/post.py @@ -77,7 +77,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_email_format_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_email_format_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_email_format_response_body_for_content_types/post.pyi index e3a24a4cc60..873bf916764 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_email_format_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_email_format_response_body_for_content_types/post.pyi @@ -72,7 +72,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_email_format_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with0_does_not_match_false_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with0_does_not_match_false_response_body_for_content_types/post.py index f60d95ad68f..b5b4c1392aa 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with0_does_not_match_false_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with0_does_not_match_false_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_enum_with0_does_not_match_false_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with0_does_not_match_false_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with0_does_not_match_false_response_body_for_content_types/post.pyi index 95877a21de8..3bafefb7aac 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with0_does_not_match_false_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with0_does_not_match_false_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_enum_with0_does_not_match_false_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with1_does_not_match_true_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with1_does_not_match_true_response_body_for_content_types/post.py index 5719084c266..2b2e15e491a 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with1_does_not_match_true_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with1_does_not_match_true_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_enum_with1_does_not_match_true_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with1_does_not_match_true_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with1_does_not_match_true_response_body_for_content_types/post.pyi index 377f896797b..207a6acb0c4 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with1_does_not_match_true_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with1_does_not_match_true_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_enum_with1_does_not_match_true_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with_escaped_characters_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with_escaped_characters_response_body_for_content_types/post.py index 89b12b34cef..c3a46becdda 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with_escaped_characters_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with_escaped_characters_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_enum_with_escaped_characters_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with_escaped_characters_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with_escaped_characters_response_body_for_content_types/post.pyi index b5259eb1795..1f98603a736 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with_escaped_characters_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with_escaped_characters_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_enum_with_escaped_characters_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with_false_does_not_match0_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with_false_does_not_match0_response_body_for_content_types/post.py index c27a69bfc8a..7230c68ea2b 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with_false_does_not_match0_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with_false_does_not_match0_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_enum_with_false_does_not_match0_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with_false_does_not_match0_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with_false_does_not_match0_response_body_for_content_types/post.pyi index 4fb38e01bf8..8c5611e6ecd 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with_false_does_not_match0_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with_false_does_not_match0_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_enum_with_false_does_not_match0_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with_true_does_not_match1_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with_true_does_not_match1_response_body_for_content_types/post.py index b91786b58c2..fef0e8c61e7 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with_true_does_not_match1_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with_true_does_not_match1_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_enum_with_true_does_not_match1_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with_true_does_not_match1_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with_true_does_not_match1_response_body_for_content_types/post.pyi index 3d1f4949a55..fdcec3d0b31 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with_true_does_not_match1_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enum_with_true_does_not_match1_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_enum_with_true_does_not_match1_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enums_in_properties_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enums_in_properties_response_body_for_content_types/post.py index bac39f05d5d..ad9d8983425 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enums_in_properties_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enums_in_properties_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_enums_in_properties_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enums_in_properties_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enums_in_properties_response_body_for_content_types/post.pyi index f18c9afc385..f3e7352a9d7 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enums_in_properties_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_enums_in_properties_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_enums_in_properties_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_forbidden_property_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_forbidden_property_response_body_for_content_types/post.py index 9cee19dea85..0d7ba92648f 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_forbidden_property_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_forbidden_property_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_forbidden_property_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_forbidden_property_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_forbidden_property_response_body_for_content_types/post.pyi index 3b627f2de3f..fdb543ed0c2 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_forbidden_property_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_forbidden_property_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_forbidden_property_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_hostname_format_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_hostname_format_response_body_for_content_types/post.py index 1c0a302d3f0..db717448660 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_hostname_format_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_hostname_format_response_body_for_content_types/post.py @@ -77,7 +77,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_hostname_format_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_hostname_format_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_hostname_format_response_body_for_content_types/post.pyi index 6582ffad60b..5e743f86d85 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_hostname_format_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_hostname_format_response_body_for_content_types/post.pyi @@ -72,7 +72,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_hostname_format_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_integer_type_matches_integers_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_integer_type_matches_integers_response_body_for_content_types/post.py index d556598db22..9c89b09ba74 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_integer_type_matches_integers_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_integer_type_matches_integers_response_body_for_content_types/post.py @@ -55,7 +55,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_integer_type_matches_integers_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_integer_type_matches_integers_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_integer_type_matches_integers_response_body_for_content_types/post.pyi index e4d260abe89..d8c15f8b3e1 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_integer_type_matches_integers_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_integer_type_matches_integers_response_body_for_content_types/post.pyi @@ -50,7 +50,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_integer_type_matches_integers_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_invalid_instance_should_not_raise_error_when_float_division_inf_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_invalid_instance_should_not_raise_error_when_float_division_inf_response_body_for_content_types/post.py index 3fd5e788ae5..42efb7a3b98 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_invalid_instance_should_not_raise_error_when_float_division_inf_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_invalid_instance_should_not_raise_error_when_float_division_inf_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_invalid_instance_should_not_raise_error_when_float_division_inf_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_invalid_instance_should_not_raise_error_when_float_division_inf_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_invalid_instance_should_not_raise_error_when_float_division_inf_response_body_for_content_types/post.pyi index 5bab32fbb27..e9a1d5381c3 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_invalid_instance_should_not_raise_error_when_float_division_inf_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_invalid_instance_should_not_raise_error_when_float_division_inf_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_invalid_instance_should_not_raise_error_when_float_division_inf_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_invalid_string_value_for_default_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_invalid_string_value_for_default_response_body_for_content_types/post.py index cc0a71c0f74..3efddb842f9 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_invalid_string_value_for_default_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_invalid_string_value_for_default_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_invalid_string_value_for_default_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_invalid_string_value_for_default_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_invalid_string_value_for_default_response_body_for_content_types/post.pyi index 9862a525fa9..3ddd4b967da 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_invalid_string_value_for_default_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_invalid_string_value_for_default_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_invalid_string_value_for_default_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ipv4_format_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ipv4_format_response_body_for_content_types/post.py index 34d2875cdea..3a909408c19 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ipv4_format_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ipv4_format_response_body_for_content_types/post.py @@ -77,7 +77,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_ipv4_format_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ipv4_format_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ipv4_format_response_body_for_content_types/post.pyi index d6301f16128..c33a67b7687 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ipv4_format_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ipv4_format_response_body_for_content_types/post.pyi @@ -72,7 +72,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_ipv4_format_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ipv6_format_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ipv6_format_response_body_for_content_types/post.py index 993ebdf637f..50675e49758 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ipv6_format_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ipv6_format_response_body_for_content_types/post.py @@ -77,7 +77,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_ipv6_format_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ipv6_format_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ipv6_format_response_body_for_content_types/post.pyi index e02230c1df7..671be4e1b40 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ipv6_format_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ipv6_format_response_body_for_content_types/post.pyi @@ -72,7 +72,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_ipv6_format_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_json_pointer_format_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_json_pointer_format_response_body_for_content_types/post.py index 996e2bb7c48..e14fec5a329 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_json_pointer_format_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_json_pointer_format_response_body_for_content_types/post.py @@ -77,7 +77,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_json_pointer_format_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_json_pointer_format_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_json_pointer_format_response_body_for_content_types/post.pyi index 7134bbb7a89..b15178f375e 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_json_pointer_format_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_json_pointer_format_response_body_for_content_types/post.pyi @@ -72,7 +72,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_json_pointer_format_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maximum_validation_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maximum_validation_response_body_for_content_types/post.py index 14300882a84..014815369da 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maximum_validation_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maximum_validation_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_maximum_validation_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maximum_validation_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maximum_validation_response_body_for_content_types/post.pyi index aa2fdab0ce0..67f10e833cb 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maximum_validation_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maximum_validation_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_maximum_validation_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maximum_validation_with_unsigned_integer_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maximum_validation_with_unsigned_integer_response_body_for_content_types/post.py index 2ebe8142c82..2d6a599008a 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maximum_validation_with_unsigned_integer_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maximum_validation_with_unsigned_integer_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_maximum_validation_with_unsigned_integer_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maximum_validation_with_unsigned_integer_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maximum_validation_with_unsigned_integer_response_body_for_content_types/post.pyi index 4ff0e55f28a..7dc51f79d71 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maximum_validation_with_unsigned_integer_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maximum_validation_with_unsigned_integer_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_maximum_validation_with_unsigned_integer_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxitems_validation_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxitems_validation_response_body_for_content_types/post.py index 426643ab35b..49228378831 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxitems_validation_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxitems_validation_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_maxitems_validation_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxitems_validation_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxitems_validation_response_body_for_content_types/post.pyi index 53dccdaea37..7976bfe5b8c 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxitems_validation_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxitems_validation_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_maxitems_validation_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxlength_validation_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxlength_validation_response_body_for_content_types/post.py index ae55d9f879a..857194aeddd 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxlength_validation_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxlength_validation_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_maxlength_validation_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxlength_validation_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxlength_validation_response_body_for_content_types/post.pyi index 5397cd27f51..722b3231719 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxlength_validation_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxlength_validation_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_maxlength_validation_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxproperties0_means_the_object_is_empty_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxproperties0_means_the_object_is_empty_response_body_for_content_types/post.py index a6932e641cd..2f1fe908a90 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxproperties0_means_the_object_is_empty_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxproperties0_means_the_object_is_empty_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_maxproperties0_means_the_object_is_empty_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxproperties0_means_the_object_is_empty_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxproperties0_means_the_object_is_empty_response_body_for_content_types/post.pyi index 19f6a382852..906b57dca17 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxproperties0_means_the_object_is_empty_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxproperties0_means_the_object_is_empty_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_maxproperties0_means_the_object_is_empty_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxproperties_validation_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxproperties_validation_response_body_for_content_types/post.py index c6d9b304737..caef224ec89 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxproperties_validation_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxproperties_validation_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_maxproperties_validation_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxproperties_validation_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxproperties_validation_response_body_for_content_types/post.pyi index 3d1bf1fc840..a12bafc0241 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxproperties_validation_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_maxproperties_validation_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_maxproperties_validation_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minimum_validation_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minimum_validation_response_body_for_content_types/post.py index edd802c2eff..455b40680e6 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minimum_validation_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minimum_validation_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_minimum_validation_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minimum_validation_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minimum_validation_response_body_for_content_types/post.pyi index 81ea328602b..3ecf130dc09 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minimum_validation_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minimum_validation_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_minimum_validation_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minimum_validation_with_signed_integer_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minimum_validation_with_signed_integer_response_body_for_content_types/post.py index 0c63844c862..c7dbae7b649 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minimum_validation_with_signed_integer_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minimum_validation_with_signed_integer_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_minimum_validation_with_signed_integer_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minimum_validation_with_signed_integer_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minimum_validation_with_signed_integer_response_body_for_content_types/post.pyi index b6663d01b4c..4a94bf8db0d 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minimum_validation_with_signed_integer_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minimum_validation_with_signed_integer_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_minimum_validation_with_signed_integer_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minitems_validation_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minitems_validation_response_body_for_content_types/post.py index b542660d9d9..05ed4ee8bb9 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minitems_validation_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minitems_validation_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_minitems_validation_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minitems_validation_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minitems_validation_response_body_for_content_types/post.pyi index 76ad4f7c9f4..c9e8bb7a6f0 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minitems_validation_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minitems_validation_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_minitems_validation_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minlength_validation_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minlength_validation_response_body_for_content_types/post.py index 6f4f8ca13e2..fd1d4f2d1a7 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minlength_validation_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minlength_validation_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_minlength_validation_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minlength_validation_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minlength_validation_response_body_for_content_types/post.pyi index bbb09d39560..a67f5177d9c 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minlength_validation_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minlength_validation_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_minlength_validation_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minproperties_validation_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minproperties_validation_response_body_for_content_types/post.py index 4c27bd27fc5..7fe9a3c69b5 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minproperties_validation_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minproperties_validation_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_minproperties_validation_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minproperties_validation_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minproperties_validation_response_body_for_content_types/post.pyi index 8c044c7e180..9684d044456 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minproperties_validation_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_minproperties_validation_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_minproperties_validation_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_allof_to_check_validation_semantics_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_allof_to_check_validation_semantics_response_body_for_content_types/post.py index 94e734fed10..e29ea0fbc53 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_allof_to_check_validation_semantics_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_allof_to_check_validation_semantics_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_nested_allof_to_check_validation_semantics_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_allof_to_check_validation_semantics_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_allof_to_check_validation_semantics_response_body_for_content_types/post.pyi index 37fbaf3798c..4810724d1d9 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_allof_to_check_validation_semantics_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_allof_to_check_validation_semantics_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_nested_allof_to_check_validation_semantics_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_anyof_to_check_validation_semantics_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_anyof_to_check_validation_semantics_response_body_for_content_types/post.py index d8febc187d4..3489d664010 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_anyof_to_check_validation_semantics_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_anyof_to_check_validation_semantics_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_nested_anyof_to_check_validation_semantics_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_anyof_to_check_validation_semantics_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_anyof_to_check_validation_semantics_response_body_for_content_types/post.pyi index b3278861b4a..80692348d73 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_anyof_to_check_validation_semantics_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_anyof_to_check_validation_semantics_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_nested_anyof_to_check_validation_semantics_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_items_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_items_response_body_for_content_types/post.py index d3c7737bc7c..492ff134548 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_items_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_items_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_nested_items_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_items_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_items_response_body_for_content_types/post.pyi index a64b5554fe3..df06609b95b 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_items_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_items_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_nested_items_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_oneof_to_check_validation_semantics_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_oneof_to_check_validation_semantics_response_body_for_content_types/post.py index 37976c8537e..d4e48876658 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_oneof_to_check_validation_semantics_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_oneof_to_check_validation_semantics_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_nested_oneof_to_check_validation_semantics_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_oneof_to_check_validation_semantics_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_oneof_to_check_validation_semantics_response_body_for_content_types/post.pyi index 53b41b27e80..7d498d603bf 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_oneof_to_check_validation_semantics_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nested_oneof_to_check_validation_semantics_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_nested_oneof_to_check_validation_semantics_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_not_more_complex_schema_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_not_more_complex_schema_response_body_for_content_types/post.py index d1fda38fd5f..6bc017808ff 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_not_more_complex_schema_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_not_more_complex_schema_response_body_for_content_types/post.py @@ -126,7 +126,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_not_more_complex_schema_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_not_more_complex_schema_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_not_more_complex_schema_response_body_for_content_types/post.pyi index e554e672090..3957b33cb1e 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_not_more_complex_schema_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_not_more_complex_schema_response_body_for_content_types/post.pyi @@ -121,7 +121,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_not_more_complex_schema_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_not_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_not_response_body_for_content_types/post.py index 380a954c526..03d9ffcda13 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_not_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_not_response_body_for_content_types/post.py @@ -77,7 +77,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_not_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_not_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_not_response_body_for_content_types/post.pyi index 0f34de828ea..7b2fa049cad 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_not_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_not_response_body_for_content_types/post.pyi @@ -72,7 +72,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_not_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nul_characters_in_strings_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nul_characters_in_strings_response_body_for_content_types/post.py index eaa2a879113..8337995803a 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nul_characters_in_strings_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nul_characters_in_strings_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_nul_characters_in_strings_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nul_characters_in_strings_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nul_characters_in_strings_response_body_for_content_types/post.pyi index cab45ab2bb6..017495d5d2d 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nul_characters_in_strings_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_nul_characters_in_strings_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_nul_characters_in_strings_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_null_type_matches_only_the_null_object_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_null_type_matches_only_the_null_object_response_body_for_content_types/post.py index 74598300ebd..3ad92b9b8fd 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_null_type_matches_only_the_null_object_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_null_type_matches_only_the_null_object_response_body_for_content_types/post.py @@ -55,7 +55,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_null_type_matches_only_the_null_object_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_null_type_matches_only_the_null_object_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_null_type_matches_only_the_null_object_response_body_for_content_types/post.pyi index bcfb6dbefe2..199f916cee0 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_null_type_matches_only_the_null_object_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_null_type_matches_only_the_null_object_response_body_for_content_types/post.pyi @@ -50,7 +50,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_null_type_matches_only_the_null_object_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_number_type_matches_numbers_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_number_type_matches_numbers_response_body_for_content_types/post.py index ff7c49de7ed..cde93c72ce8 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_number_type_matches_numbers_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_number_type_matches_numbers_response_body_for_content_types/post.py @@ -55,7 +55,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_number_type_matches_numbers_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_number_type_matches_numbers_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_number_type_matches_numbers_response_body_for_content_types/post.pyi index 75dc5cac5bf..6e88c42dd67 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_number_type_matches_numbers_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_number_type_matches_numbers_response_body_for_content_types/post.pyi @@ -50,7 +50,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_number_type_matches_numbers_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_object_properties_validation_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_object_properties_validation_response_body_for_content_types/post.py index dc5dd3056c8..e5e9f0db802 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_object_properties_validation_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_object_properties_validation_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_object_properties_validation_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_object_properties_validation_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_object_properties_validation_response_body_for_content_types/post.pyi index aa52d6b84ee..47259e1d4e8 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_object_properties_validation_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_object_properties_validation_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_object_properties_validation_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_object_type_matches_objects_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_object_type_matches_objects_response_body_for_content_types/post.py index 1e86462b997..4637ea3d380 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_object_type_matches_objects_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_object_type_matches_objects_response_body_for_content_types/post.py @@ -55,7 +55,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_object_type_matches_objects_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_object_type_matches_objects_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_object_type_matches_objects_response_body_for_content_types/post.pyi index b104583deb2..5c554c8ce2e 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_object_type_matches_objects_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_object_type_matches_objects_response_body_for_content_types/post.pyi @@ -50,7 +50,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_object_type_matches_objects_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_complex_types_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_complex_types_response_body_for_content_types/post.py index 379fd5f27cd..0670aeb2be1 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_complex_types_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_complex_types_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_oneof_complex_types_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_complex_types_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_complex_types_response_body_for_content_types/post.pyi index fc9761d3916..a3801d37e45 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_complex_types_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_complex_types_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_oneof_complex_types_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_response_body_for_content_types/post.py index ff1c22c6c0c..473bcca1fe8 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_oneof_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_response_body_for_content_types/post.pyi index 914f28c7c00..ef5fdf6e1c0 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_oneof_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_with_base_schema_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_with_base_schema_response_body_for_content_types/post.py index 42912de5669..ad589370336 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_with_base_schema_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_with_base_schema_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_oneof_with_base_schema_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_with_base_schema_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_with_base_schema_response_body_for_content_types/post.pyi index aa7c01064c1..95e8f8bff40 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_with_base_schema_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_with_base_schema_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_oneof_with_base_schema_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_with_empty_schema_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_with_empty_schema_response_body_for_content_types/post.py index 8bb9a051c1e..a2936bd0d66 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_with_empty_schema_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_with_empty_schema_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_oneof_with_empty_schema_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_with_empty_schema_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_with_empty_schema_response_body_for_content_types/post.pyi index fdcb1e6a712..de60f66e0b5 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_with_empty_schema_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_with_empty_schema_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_oneof_with_empty_schema_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_with_required_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_with_required_response_body_for_content_types/post.py index b7d7673174c..a05894d4011 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_with_required_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_with_required_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_oneof_with_required_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_with_required_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_with_required_response_body_for_content_types/post.pyi index 2686459a6c1..f48e1c66e4b 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_with_required_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_oneof_with_required_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_oneof_with_required_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_pattern_is_not_anchored_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_pattern_is_not_anchored_response_body_for_content_types/post.py index 31a8e9b8d02..e1274eb0039 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_pattern_is_not_anchored_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_pattern_is_not_anchored_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_pattern_is_not_anchored_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_pattern_is_not_anchored_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_pattern_is_not_anchored_response_body_for_content_types/post.pyi index ab8b26a7664..128e1246fff 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_pattern_is_not_anchored_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_pattern_is_not_anchored_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_pattern_is_not_anchored_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_pattern_validation_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_pattern_validation_response_body_for_content_types/post.py index cdc863a2275..a12b35e1675 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_pattern_validation_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_pattern_validation_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_pattern_validation_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_pattern_validation_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_pattern_validation_response_body_for_content_types/post.pyi index 703ba013ddb..2e1b4cbec54 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_pattern_validation_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_pattern_validation_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_pattern_validation_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_properties_with_escaped_characters_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_properties_with_escaped_characters_response_body_for_content_types/post.py index 14323da278b..936ad666576 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_properties_with_escaped_characters_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_properties_with_escaped_characters_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_properties_with_escaped_characters_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_properties_with_escaped_characters_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_properties_with_escaped_characters_response_body_for_content_types/post.pyi index 4db0f2051ff..7e41369c861 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_properties_with_escaped_characters_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_properties_with_escaped_characters_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_properties_with_escaped_characters_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_property_named_ref_that_is_not_a_reference_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_property_named_ref_that_is_not_a_reference_response_body_for_content_types/post.py index 1045352e756..d05ed431c86 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_property_named_ref_that_is_not_a_reference_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_property_named_ref_that_is_not_a_reference_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_property_named_ref_that_is_not_a_reference_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_property_named_ref_that_is_not_a_reference_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_property_named_ref_that_is_not_a_reference_response_body_for_content_types/post.pyi index f9a5f42c237..8bb97630bc7 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_property_named_ref_that_is_not_a_reference_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_property_named_ref_that_is_not_a_reference_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_property_named_ref_that_is_not_a_reference_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_additionalproperties_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_additionalproperties_response_body_for_content_types/post.py index 736b54f3570..a91f8813a7b 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_additionalproperties_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_additionalproperties_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_ref_in_additionalproperties_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_additionalproperties_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_additionalproperties_response_body_for_content_types/post.pyi index cabd4dd9306..900f5554218 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_additionalproperties_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_additionalproperties_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_ref_in_additionalproperties_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_allof_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_allof_response_body_for_content_types/post.py index c9395cdf64e..fcae793b616 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_allof_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_allof_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_ref_in_allof_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_allof_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_allof_response_body_for_content_types/post.pyi index cc12ee2eb78..265a672db3c 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_allof_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_allof_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_ref_in_allof_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_anyof_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_anyof_response_body_for_content_types/post.py index 60df41a1555..8e4026bb2fd 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_anyof_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_anyof_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_ref_in_anyof_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_anyof_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_anyof_response_body_for_content_types/post.pyi index 9b659f61ef9..a2d53f3dad4 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_anyof_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_anyof_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_ref_in_anyof_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_items_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_items_response_body_for_content_types/post.py index 17fbc457ab4..d6faf25623c 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_items_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_items_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_ref_in_items_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_items_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_items_response_body_for_content_types/post.pyi index 7fd4b1140e8..7ac9c2f3dcb 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_items_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_items_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_ref_in_items_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_not_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_not_response_body_for_content_types/post.py index 731ed686fdf..d289f34e4c4 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_not_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_not_response_body_for_content_types/post.py @@ -82,7 +82,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_ref_in_not_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_not_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_not_response_body_for_content_types/post.pyi index 0d4292196da..3b8376118f2 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_not_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_not_response_body_for_content_types/post.pyi @@ -77,7 +77,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_ref_in_not_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_oneof_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_oneof_response_body_for_content_types/post.py index bfed6956112..c4173c7164b 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_oneof_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_oneof_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_ref_in_oneof_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_oneof_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_oneof_response_body_for_content_types/post.pyi index f6c494ce124..78aec765441 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_oneof_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_oneof_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_ref_in_oneof_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_property_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_property_response_body_for_content_types/post.py index 61824a3e934..8c919aea71c 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_property_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_property_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_ref_in_property_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_property_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_property_response_body_for_content_types/post.pyi index 6b0f19eaa42..87b6d585960 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_property_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_ref_in_property_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_ref_in_property_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_default_validation_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_default_validation_response_body_for_content_types/post.py index 31edb96fc03..2f071fcad98 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_default_validation_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_default_validation_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_required_default_validation_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_default_validation_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_default_validation_response_body_for_content_types/post.pyi index 9ab3d7feb3b..ba9ce4b930f 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_default_validation_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_default_validation_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_required_default_validation_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_validation_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_validation_response_body_for_content_types/post.py index 51a2ce5fae1..feece12371f 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_validation_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_validation_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_required_validation_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_validation_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_validation_response_body_for_content_types/post.pyi index 4e6a7b165fa..0c226b3e2e7 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_validation_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_validation_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_required_validation_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_with_empty_array_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_with_empty_array_response_body_for_content_types/post.py index 787b06abe54..ae3f890c1b0 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_with_empty_array_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_with_empty_array_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_required_with_empty_array_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_with_empty_array_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_with_empty_array_response_body_for_content_types/post.pyi index 710a4e311da..550654feff6 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_with_empty_array_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_with_empty_array_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_required_with_empty_array_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_with_escaped_characters_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_with_escaped_characters_response_body_for_content_types/post.py index a0ac47dc7c8..837f66395ac 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_with_escaped_characters_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_with_escaped_characters_response_body_for_content_types/post.py @@ -85,7 +85,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_required_with_escaped_characters_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_with_escaped_characters_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_with_escaped_characters_response_body_for_content_types/post.pyi index 70c1f73f14c..38ff81848c9 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_with_escaped_characters_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_required_with_escaped_characters_response_body_for_content_types/post.pyi @@ -80,7 +80,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_required_with_escaped_characters_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_simple_enum_validation_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_simple_enum_validation_response_body_for_content_types/post.py index f4ce8e29cb5..f33666b2d9b 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_simple_enum_validation_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_simple_enum_validation_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_simple_enum_validation_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_simple_enum_validation_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_simple_enum_validation_response_body_for_content_types/post.pyi index f3f23ad05e7..525cc8b4279 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_simple_enum_validation_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_simple_enum_validation_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_simple_enum_validation_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_string_type_matches_strings_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_string_type_matches_strings_response_body_for_content_types/post.py index 7662aacbb03..232e64e2fd7 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_string_type_matches_strings_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_string_type_matches_strings_response_body_for_content_types/post.py @@ -55,7 +55,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_string_type_matches_strings_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_string_type_matches_strings_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_string_type_matches_strings_response_body_for_content_types/post.pyi index 6ce3ad6cc46..92cb39e7f99 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_string_type_matches_strings_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_string_type_matches_strings_response_body_for_content_types/post.pyi @@ -50,7 +50,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_string_type_matches_strings_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_response_body_for_content_types/post.py index 881d8af5576..7ec32ffcd59 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_response_body_for_content_types/post.pyi index c219477657c..5e4fef20acd 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_the_default_keyword_does_not_do_anything_if_the_property_is_missing_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uniqueitems_false_validation_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uniqueitems_false_validation_response_body_for_content_types/post.py index 740d329081a..2ca6488bc1a 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uniqueitems_false_validation_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uniqueitems_false_validation_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_uniqueitems_false_validation_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uniqueitems_false_validation_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uniqueitems_false_validation_response_body_for_content_types/post.pyi index 26b110ed033..3054b495166 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uniqueitems_false_validation_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uniqueitems_false_validation_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_uniqueitems_false_validation_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uniqueitems_validation_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uniqueitems_validation_response_body_for_content_types/post.py index 3e5c0afa887..c4f75d43a8a 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uniqueitems_validation_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uniqueitems_validation_response_body_for_content_types/post.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_uniqueitems_validation_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uniqueitems_validation_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uniqueitems_validation_response_body_for_content_types/post.pyi index 09e7bcb611a..b8d23d3e76e 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uniqueitems_validation_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uniqueitems_validation_response_body_for_content_types/post.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_uniqueitems_validation_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uri_format_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uri_format_response_body_for_content_types/post.py index fc566c0148b..b0bb6afea94 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uri_format_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uri_format_response_body_for_content_types/post.py @@ -77,7 +77,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_uri_format_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uri_format_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uri_format_response_body_for_content_types/post.pyi index 6792bcb6ec7..aec6e6c16f0 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uri_format_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uri_format_response_body_for_content_types/post.pyi @@ -72,7 +72,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_uri_format_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uri_reference_format_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uri_reference_format_response_body_for_content_types/post.py index 9b386c3d4da..b0f93102472 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uri_reference_format_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uri_reference_format_response_body_for_content_types/post.py @@ -77,7 +77,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_uri_reference_format_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uri_reference_format_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uri_reference_format_response_body_for_content_types/post.pyi index a0ad8c0782d..3de5191676e 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uri_reference_format_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uri_reference_format_response_body_for_content_types/post.pyi @@ -72,7 +72,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_uri_reference_format_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uri_template_format_response_body_for_content_types/post.py b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uri_template_format_response_body_for_content_types/post.py index 97686114363..1eea3901e94 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uri_template_format_response_body_for_content_types/post.py +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uri_template_format_response_body_for_content_types/post.py @@ -77,7 +77,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _post_uri_template_format_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uri_template_format_response_body_for_content_types/post.pyi b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uri_template_format_response_body_for_content_types/post.pyi index 58c0382c63f..06064e29e7b 100644 --- a/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uri_template_format_response_body_for_content_types/post.pyi +++ b/samples/openapi3/client/3_0_3_unit_test/python/unit_test_api/paths/response_body_post_uri_template_format_response_body_for_content_types/post.pyi @@ -72,7 +72,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _post_uri_template_format_response_body_for_content_types_oapg( self, diff --git a/samples/openapi3/client/features/nonCompliantUseDiscriminatorIfCompositionFails/python/this_package/paths/operators/post.py b/samples/openapi3/client/features/nonCompliantUseDiscriminatorIfCompositionFails/python/this_package/paths/operators/post.py index fb7938065a2..e6ec8da5ab5 100644 --- a/samples/openapi3/client/features/nonCompliantUseDiscriminatorIfCompositionFails/python/this_package/paths/operators/post.py +++ b/samples/openapi3/client/features/nonCompliantUseDiscriminatorIfCompositionFails/python/this_package/paths/operators/post.py @@ -57,12 +57,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _post_operators_oapg( + self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_operators_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -70,12 +81,13 @@ def _post_operators_oapg( ApiResponseFor200, ]: ... + @typing.overload def _post_operators_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -83,8 +95,8 @@ def _post_operators_oapg( @typing.overload def _post_operators_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -95,8 +107,8 @@ def _post_operators_oapg( def _post_operators_oapg( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -151,8 +163,20 @@ class PostOperators(BaseApi): @typing.overload def post_operators( self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_operators( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -160,12 +184,13 @@ def post_operators( ApiResponseFor200, ]: ... + @typing.overload def post_operators( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -173,8 +198,8 @@ def post_operators( @typing.overload def post_operators( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -185,8 +210,8 @@ def post_operators( def post_operators( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -206,8 +231,8 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["application/json"] = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -215,12 +240,25 @@ def post( ApiResponseFor200, ]: ... + @typing.overload + def post( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -228,8 +266,8 @@ def post( @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -240,8 +278,8 @@ def post( def post( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, diff --git a/samples/openapi3/client/features/nonCompliantUseDiscriminatorIfCompositionFails/python/this_package/paths/operators/post.pyi b/samples/openapi3/client/features/nonCompliantUseDiscriminatorIfCompositionFails/python/this_package/paths/operators/post.pyi index a765b866c88..3c4515d0d82 100644 --- a/samples/openapi3/client/features/nonCompliantUseDiscriminatorIfCompositionFails/python/this_package/paths/operators/post.pyi +++ b/samples/openapi3/client/features/nonCompliantUseDiscriminatorIfCompositionFails/python/this_package/paths/operators/post.pyi @@ -52,12 +52,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _post_operators_oapg( + self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _post_operators_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -65,12 +76,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _post_operators_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -78,8 +90,8 @@ class BaseApi(api_client.Api): @typing.overload def _post_operators_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -90,8 +102,8 @@ class BaseApi(api_client.Api): def _post_operators_oapg( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -146,8 +158,20 @@ class PostOperators(BaseApi): @typing.overload def post_operators( self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post_operators( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -155,12 +179,13 @@ class PostOperators(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post_operators( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -168,8 +193,8 @@ class PostOperators(BaseApi): @typing.overload def post_operators( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -180,8 +205,8 @@ class PostOperators(BaseApi): def post_operators( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -201,8 +226,8 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["application/json"] = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -210,12 +235,25 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload + def post( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -223,8 +261,8 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -235,8 +273,8 @@ class ApiForpost(BaseApi): def post( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/another_fake_dummy/patch.py b/samples/openapi3/client/petstore/python/petstore_api/paths/another_fake_dummy/patch.py index 7a1f9544926..35b18c4fde2 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/another_fake_dummy/patch.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/another_fake_dummy/patch.py @@ -68,12 +68,24 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _call_123_test_special_tags_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _call_123_test_special_tags_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -82,12 +94,13 @@ def _call_123_test_special_tags_oapg( ApiResponseFor200, ]: ... + @typing.overload def _call_123_test_special_tags_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -97,7 +110,7 @@ def _call_123_test_special_tags_oapg( def _call_123_test_special_tags_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -173,7 +186,7 @@ class Call123TestSpecialTags(BaseApi): def call_123_test_special_tags( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -182,12 +195,26 @@ def call_123_test_special_tags( ApiResponseFor200, ]: ... + @typing.overload + def call_123_test_special_tags( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def call_123_test_special_tags( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -197,7 +224,7 @@ def call_123_test_special_tags( def call_123_test_special_tags( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -233,7 +260,7 @@ class ApiForpatch(BaseApi): def patch( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -242,12 +269,26 @@ def patch( ApiResponseFor200, ]: ... + @typing.overload + def patch( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def patch( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -257,7 +298,7 @@ def patch( def patch( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/another_fake_dummy/patch.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/another_fake_dummy/patch.pyi index 92881f361da..5c7dfa48515 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/another_fake_dummy/patch.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/another_fake_dummy/patch.pyi @@ -63,12 +63,24 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): + @typing.overload + def _call_123_test_special_tags_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _call_123_test_special_tags_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -77,12 +89,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _call_123_test_special_tags_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -92,7 +105,7 @@ class BaseApi(api_client.Api): def _call_123_test_special_tags_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -168,7 +181,7 @@ class Call123TestSpecialTags(BaseApi): def call_123_test_special_tags( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -177,12 +190,26 @@ class Call123TestSpecialTags(BaseApi): ApiResponseFor200, ]: ... + @typing.overload + def call_123_test_special_tags( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def call_123_test_special_tags( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -192,7 +219,7 @@ class Call123TestSpecialTags(BaseApi): def call_123_test_special_tags( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -228,7 +255,7 @@ class ApiForpatch(BaseApi): def patch( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -237,12 +264,26 @@ class ApiForpatch(BaseApi): ApiResponseFor200, ]: ... + @typing.overload + def patch( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def patch( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -252,7 +293,7 @@ class ApiForpatch(BaseApi): def patch( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake/delete.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake/delete.py index 2cec561ac0e..41ca014a2a0 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake/delete.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake/delete.py @@ -133,7 +133,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _group_parameters_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake/delete.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake/delete.pyi index 710ed92b779..bb7b72a2b51 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake/delete.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake/delete.pyi @@ -125,7 +125,6 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): - @typing.overload def _group_parameters_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake/get.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake/get.py index 35e450a3756..f81d9a01d24 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake/get.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake/get.py @@ -452,14 +452,27 @@ class ApiResponseFor404(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _enum_parameters_oapg( + self, + content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + query_params: RequestQueryParams = frozendict.frozendict(), + header_params: RequestHeaderParams = frozendict.frozendict(), + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _enum_parameters_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -467,14 +480,15 @@ def _enum_parameters_oapg( ApiResponseFor200, ]: ... + @typing.overload def _enum_parameters_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -482,10 +496,10 @@ def _enum_parameters_oapg( @typing.overload def _enum_parameters_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -496,10 +510,10 @@ def _enum_parameters_oapg( def _enum_parameters_oapg( self, + content_type: str = 'application/x-www-form-urlencoded', body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -582,10 +596,24 @@ class EnumParameters(BaseApi): @typing.overload def enum_parameters( self, + content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + query_params: RequestQueryParams = frozendict.frozendict(), + header_params: RequestHeaderParams = frozendict.frozendict(), + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def enum_parameters( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -593,14 +621,15 @@ def enum_parameters( ApiResponseFor200, ]: ... + @typing.overload def enum_parameters( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -608,10 +637,10 @@ def enum_parameters( @typing.overload def enum_parameters( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -622,10 +651,10 @@ def enum_parameters( def enum_parameters( self, + content_type: str = 'application/x-www-form-urlencoded', body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -647,10 +676,24 @@ class ApiForget(BaseApi): @typing.overload def get( self, + content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + query_params: RequestQueryParams = frozendict.frozendict(), + header_params: RequestHeaderParams = frozendict.frozendict(), + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -658,14 +701,15 @@ def get( ApiResponseFor200, ]: ... + @typing.overload def get( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -673,10 +717,10 @@ def get( @typing.overload def get( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -687,10 +731,10 @@ def get( def get( self, + content_type: str = 'application/x-www-form-urlencoded', body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake/get.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake/get.pyi index 3753364e14e..485ae52b7ff 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake/get.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake/get.pyi @@ -385,14 +385,27 @@ _response_for_404 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _enum_parameters_oapg( + self, + content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + query_params: RequestQueryParams = frozendict.frozendict(), + header_params: RequestHeaderParams = frozendict.frozendict(), + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _enum_parameters_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -400,14 +413,15 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _enum_parameters_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -415,10 +429,10 @@ class BaseApi(api_client.Api): @typing.overload def _enum_parameters_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -429,10 +443,10 @@ class BaseApi(api_client.Api): def _enum_parameters_oapg( self, + content_type: str = 'application/x-www-form-urlencoded', body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -515,10 +529,24 @@ class EnumParameters(BaseApi): @typing.overload def enum_parameters( self, + content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + query_params: RequestQueryParams = frozendict.frozendict(), + header_params: RequestHeaderParams = frozendict.frozendict(), + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def enum_parameters( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -526,14 +554,15 @@ class EnumParameters(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def enum_parameters( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -541,10 +570,10 @@ class EnumParameters(BaseApi): @typing.overload def enum_parameters( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -555,10 +584,10 @@ class EnumParameters(BaseApi): def enum_parameters( self, + content_type: str = 'application/x-www-form-urlencoded', body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -580,10 +609,24 @@ class ApiForget(BaseApi): @typing.overload def get( self, + content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + query_params: RequestQueryParams = frozendict.frozendict(), + header_params: RequestHeaderParams = frozendict.frozendict(), + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -591,14 +634,15 @@ class ApiForget(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def get( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -606,10 +650,10 @@ class ApiForget(BaseApi): @typing.overload def get( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -620,10 +664,10 @@ class ApiForget(BaseApi): def get( self, + content_type: str = 'application/x-www-form-urlencoded', body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake/patch.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake/patch.py index 0a41eedc003..5a5927a2b09 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake/patch.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake/patch.py @@ -68,12 +68,24 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _client_model_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _client_model_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -82,12 +94,13 @@ def _client_model_oapg( ApiResponseFor200, ]: ... + @typing.overload def _client_model_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -97,7 +110,7 @@ def _client_model_oapg( def _client_model_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -173,7 +186,7 @@ class ClientModel(BaseApi): def client_model( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -182,12 +195,26 @@ def client_model( ApiResponseFor200, ]: ... + @typing.overload + def client_model( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def client_model( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -197,7 +224,7 @@ def client_model( def client_model( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -233,7 +260,7 @@ class ApiForpatch(BaseApi): def patch( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -242,12 +269,26 @@ def patch( ApiResponseFor200, ]: ... + @typing.overload + def patch( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def patch( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -257,7 +298,7 @@ def patch( def patch( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake/patch.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake/patch.pyi index bd1f3fbc3b5..1cd6c453775 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake/patch.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake/patch.pyi @@ -63,12 +63,24 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): + @typing.overload + def _client_model_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _client_model_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -77,12 +89,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _client_model_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -92,7 +105,7 @@ class BaseApi(api_client.Api): def _client_model_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -168,7 +181,7 @@ class ClientModel(BaseApi): def client_model( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -177,12 +190,26 @@ class ClientModel(BaseApi): ApiResponseFor200, ]: ... + @typing.overload + def client_model( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def client_model( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -192,7 +219,7 @@ class ClientModel(BaseApi): def client_model( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -228,7 +255,7 @@ class ApiForpatch(BaseApi): def patch( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -237,12 +264,26 @@ class ApiForpatch(BaseApi): ApiResponseFor200, ]: ... + @typing.overload + def patch( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def patch( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -252,7 +293,7 @@ class ApiForpatch(BaseApi): def patch( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake/post.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake/post.py index 889f3af945f..5bded5d3e06 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake/post.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake/post.py @@ -339,12 +339,23 @@ class ApiResponseFor404(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _endpoint_parameters_oapg( + self, + content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _endpoint_parameters_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -352,12 +363,13 @@ def _endpoint_parameters_oapg( ApiResponseFor200, ]: ... + @typing.overload def _endpoint_parameters_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -365,8 +377,8 @@ def _endpoint_parameters_oapg( @typing.overload def _endpoint_parameters_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -377,8 +389,8 @@ def _endpoint_parameters_oapg( def _endpoint_parameters_oapg( self, - body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, content_type: str = 'application/x-www-form-urlencoded', + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -435,8 +447,20 @@ class EndpointParameters(BaseApi): @typing.overload def endpoint_parameters( self, + content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def endpoint_parameters( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -444,12 +468,13 @@ def endpoint_parameters( ApiResponseFor200, ]: ... + @typing.overload def endpoint_parameters( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -457,8 +482,8 @@ def endpoint_parameters( @typing.overload def endpoint_parameters( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -469,8 +494,8 @@ def endpoint_parameters( def endpoint_parameters( self, - body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, content_type: str = 'application/x-www-form-urlencoded', + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -490,8 +515,8 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -499,12 +524,25 @@ def post( ApiResponseFor200, ]: ... + @typing.overload + def post( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -512,8 +550,8 @@ def post( @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -524,8 +562,8 @@ def post( def post( self, - body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, content_type: str = 'application/x-www-form-urlencoded', + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake/post.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake/post.pyi index ec73b17d28d..a7dc2f6decd 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake/post.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake/post.pyi @@ -290,12 +290,23 @@ _response_for_404 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _endpoint_parameters_oapg( + self, + content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _endpoint_parameters_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -303,12 +314,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _endpoint_parameters_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -316,8 +328,8 @@ class BaseApi(api_client.Api): @typing.overload def _endpoint_parameters_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -328,8 +340,8 @@ class BaseApi(api_client.Api): def _endpoint_parameters_oapg( self, - body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, content_type: str = 'application/x-www-form-urlencoded', + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -386,8 +398,20 @@ class EndpointParameters(BaseApi): @typing.overload def endpoint_parameters( self, + content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def endpoint_parameters( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -395,12 +419,13 @@ class EndpointParameters(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def endpoint_parameters( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -408,8 +433,8 @@ class EndpointParameters(BaseApi): @typing.overload def endpoint_parameters( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -420,8 +445,8 @@ class EndpointParameters(BaseApi): def endpoint_parameters( self, - body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, content_type: str = 'application/x-www-form-urlencoded', + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -441,8 +466,8 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -450,12 +475,25 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload + def post( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -463,8 +501,8 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -475,8 +513,8 @@ class ApiForpost(BaseApi): def post( self, - body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, content_type: str = 'application/x-www-form-urlencoded', + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_additional_properties_with_array_of_enums/get.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_additional_properties_with_array_of_enums/get.py index 6bd65335cc8..c76f1c57987 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_additional_properties_with_array_of_enums/get.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_additional_properties_with_array_of_enums/get.py @@ -67,12 +67,24 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _additional_properties_with_array_of_enums_oapg( + self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _additional_properties_with_array_of_enums_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -81,12 +93,13 @@ def _additional_properties_with_array_of_enums_oapg( ApiResponseFor200, ]: ... + @typing.overload def _additional_properties_with_array_of_enums_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -95,8 +108,8 @@ def _additional_properties_with_array_of_enums_oapg( @typing.overload def _additional_properties_with_array_of_enums_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -108,8 +121,8 @@ def _additional_properties_with_array_of_enums_oapg( def _additional_properties_with_array_of_enums_oapg( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -169,8 +182,8 @@ class AdditionalPropertiesWithArrayOfEnums(BaseApi): @typing.overload def additional_properties_with_array_of_enums( self, + content_type: typing_extensions.Literal["application/json"] = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -179,12 +192,26 @@ def additional_properties_with_array_of_enums( ApiResponseFor200, ]: ... + @typing.overload + def additional_properties_with_array_of_enums( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def additional_properties_with_array_of_enums( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -193,8 +220,8 @@ def additional_properties_with_array_of_enums( @typing.overload def additional_properties_with_array_of_enums( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -206,8 +233,8 @@ def additional_properties_with_array_of_enums( def additional_properties_with_array_of_enums( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -229,8 +256,21 @@ class ApiForget(BaseApi): @typing.overload def get( self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -239,12 +279,13 @@ def get( ApiResponseFor200, ]: ... + @typing.overload def get( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -253,8 +294,8 @@ def get( @typing.overload def get( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -266,8 +307,8 @@ def get( def get( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_additional_properties_with_array_of_enums/get.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_additional_properties_with_array_of_enums/get.pyi index c96ac4022c6..13981bf4750 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_additional_properties_with_array_of_enums/get.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_additional_properties_with_array_of_enums/get.pyi @@ -62,12 +62,24 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): + @typing.overload + def _additional_properties_with_array_of_enums_oapg( + self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _additional_properties_with_array_of_enums_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -76,12 +88,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _additional_properties_with_array_of_enums_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -90,8 +103,8 @@ class BaseApi(api_client.Api): @typing.overload def _additional_properties_with_array_of_enums_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -103,8 +116,8 @@ class BaseApi(api_client.Api): def _additional_properties_with_array_of_enums_oapg( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -164,8 +177,8 @@ class AdditionalPropertiesWithArrayOfEnums(BaseApi): @typing.overload def additional_properties_with_array_of_enums( self, + content_type: typing_extensions.Literal["application/json"] = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -174,12 +187,26 @@ class AdditionalPropertiesWithArrayOfEnums(BaseApi): ApiResponseFor200, ]: ... + @typing.overload + def additional_properties_with_array_of_enums( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def additional_properties_with_array_of_enums( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -188,8 +215,8 @@ class AdditionalPropertiesWithArrayOfEnums(BaseApi): @typing.overload def additional_properties_with_array_of_enums( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -201,8 +228,8 @@ class AdditionalPropertiesWithArrayOfEnums(BaseApi): def additional_properties_with_array_of_enums( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -224,8 +251,21 @@ class ApiForget(BaseApi): @typing.overload def get( self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def get( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -234,12 +274,13 @@ class ApiForget(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def get( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -248,8 +289,8 @@ class ApiForget(BaseApi): @typing.overload def get( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -261,8 +302,8 @@ class ApiForget(BaseApi): def get( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_body_with_file_schema/put.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_body_with_file_schema/put.py index 5bd57e218bb..481882c97fa 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_body_with_file_schema/put.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_body_with_file_schema/put.py @@ -58,12 +58,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _body_with_file_schema_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _body_with_file_schema_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _body_with_file_schema_oapg( ApiResponseFor200, ]: ... + @typing.overload def _body_with_file_schema_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _body_with_file_schema_oapg( def _body_with_file_schema_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class BodyWithFileSchema(BaseApi): def body_with_file_schema( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def body_with_file_schema( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ def body_with_file_schema( ApiResponseFor200, ]: ... + @typing.overload def body_with_file_schema( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ def body_with_file_schema( def body_with_file_schema( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForput(BaseApi): def put( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def put( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ def put( ApiResponseFor200, ]: ... + @typing.overload def put( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ def put( def put( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_body_with_file_schema/put.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_body_with_file_schema/put.pyi index 4f986b2fd88..7785729eb28 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_body_with_file_schema/put.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_body_with_file_schema/put.pyi @@ -53,12 +53,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _body_with_file_schema_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _body_with_file_schema_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _body_with_file_schema_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _body_with_file_schema_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -150,7 +162,19 @@ class BodyWithFileSchema(BaseApi): def body_with_file_schema( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def body_with_file_schema( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -158,12 +182,13 @@ class BodyWithFileSchema(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def body_with_file_schema( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -172,7 +197,7 @@ class BodyWithFileSchema(BaseApi): def body_with_file_schema( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -205,7 +230,19 @@ class ApiForput(BaseApi): def put( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def put( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -213,12 +250,13 @@ class ApiForput(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def put( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -227,7 +265,7 @@ class ApiForput(BaseApi): def put( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_body_with_query_params/put.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_body_with_query_params/put.py index 2434a818efa..b2312bc30ee 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_body_with_query_params/put.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_body_with_query_params/put.py @@ -85,13 +85,25 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _body_with_query_params_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + query_params: RequestQueryParams = frozendict.frozendict(), + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _body_with_query_params_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -99,13 +111,14 @@ def _body_with_query_params_oapg( ApiResponseFor200, ]: ... + @typing.overload def _body_with_query_params_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -114,8 +127,8 @@ def _body_with_query_params_oapg( def _body_with_query_params_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -127,8 +140,8 @@ def _body_with_query_params_oapg( def _body_with_query_params_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - query_params: RequestQueryParams = frozendict.frozendict(), content_type: str = 'application/json', + query_params: RequestQueryParams = frozendict.frozendict(), stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -200,8 +213,8 @@ class BodyWithQueryParams(BaseApi): def body_with_query_params( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -209,13 +222,27 @@ def body_with_query_params( ApiResponseFor200, ]: ... + @typing.overload + def body_with_query_params( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., + query_params: RequestQueryParams = frozendict.frozendict(), + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def body_with_query_params( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -224,8 +251,8 @@ def body_with_query_params( def body_with_query_params( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -237,8 +264,8 @@ def body_with_query_params( def body_with_query_params( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - query_params: RequestQueryParams = frozendict.frozendict(), content_type: str = 'application/json', + query_params: RequestQueryParams = frozendict.frozendict(), stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -260,8 +287,21 @@ class ApiForput(BaseApi): def put( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + query_params: RequestQueryParams = frozendict.frozendict(), + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def put( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -269,13 +309,14 @@ def put( ApiResponseFor200, ]: ... + @typing.overload def put( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -284,8 +325,8 @@ def put( def put( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -297,8 +338,8 @@ def put( def put( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - query_params: RequestQueryParams = frozendict.frozendict(), content_type: str = 'application/json', + query_params: RequestQueryParams = frozendict.frozendict(), stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_body_with_query_params/put.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_body_with_query_params/put.pyi index a8d151fbd01..99caf0b15e2 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_body_with_query_params/put.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_body_with_query_params/put.pyi @@ -80,13 +80,25 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _body_with_query_params_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + query_params: RequestQueryParams = frozendict.frozendict(), + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _body_with_query_params_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -94,13 +106,14 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _body_with_query_params_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -109,8 +122,8 @@ class BaseApi(api_client.Api): def _body_with_query_params_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -122,8 +135,8 @@ class BaseApi(api_client.Api): def _body_with_query_params_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - query_params: RequestQueryParams = frozendict.frozendict(), content_type: str = 'application/json', + query_params: RequestQueryParams = frozendict.frozendict(), stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -195,8 +208,8 @@ class BodyWithQueryParams(BaseApi): def body_with_query_params( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -204,13 +217,27 @@ class BodyWithQueryParams(BaseApi): ApiResponseFor200, ]: ... + @typing.overload + def body_with_query_params( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., + query_params: RequestQueryParams = frozendict.frozendict(), + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def body_with_query_params( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -219,8 +246,8 @@ class BodyWithQueryParams(BaseApi): def body_with_query_params( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -232,8 +259,8 @@ class BodyWithQueryParams(BaseApi): def body_with_query_params( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - query_params: RequestQueryParams = frozendict.frozendict(), content_type: str = 'application/json', + query_params: RequestQueryParams = frozendict.frozendict(), stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -255,8 +282,21 @@ class ApiForput(BaseApi): def put( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + query_params: RequestQueryParams = frozendict.frozendict(), + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def put( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -264,13 +304,14 @@ class ApiForput(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def put( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -279,8 +320,8 @@ class ApiForput(BaseApi): def put( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -292,8 +333,8 @@ class ApiForput(BaseApi): def put( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - query_params: RequestQueryParams = frozendict.frozendict(), content_type: str = 'application/json', + query_params: RequestQueryParams = frozendict.frozendict(), stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_case_sensitive_params/put.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_case_sensitive_params/put.py index f73a9bd471d..99bda7a0d4d 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_case_sensitive_params/put.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_case_sensitive_params/put.py @@ -89,7 +89,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _case_sensitive_params_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_case_sensitive_params/put.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_case_sensitive_params/put.pyi index 5f3f819b5cd..12913bdbb12 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_case_sensitive_params/put.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_case_sensitive_params/put.pyi @@ -84,7 +84,6 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): - @typing.overload def _case_sensitive_params_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_classname_test/patch.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_classname_test/patch.py index 7f4e4b9c2d6..72a085dbaf5 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_classname_test/patch.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_classname_test/patch.py @@ -71,12 +71,24 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _classname_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _classname_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -85,12 +97,13 @@ def _classname_oapg( ApiResponseFor200, ]: ... + @typing.overload def _classname_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -100,7 +113,7 @@ def _classname_oapg( def _classname_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -177,7 +190,7 @@ class Classname(BaseApi): def classname( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -186,12 +199,26 @@ def classname( ApiResponseFor200, ]: ... + @typing.overload + def classname( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def classname( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -201,7 +228,7 @@ def classname( def classname( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -237,7 +264,7 @@ class ApiForpatch(BaseApi): def patch( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -246,12 +273,26 @@ def patch( ApiResponseFor200, ]: ... + @typing.overload + def patch( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def patch( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -261,7 +302,7 @@ def patch( def patch( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_classname_test/patch.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_classname_test/patch.pyi index a262a57741d..055301928b9 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_classname_test/patch.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_classname_test/patch.pyi @@ -63,12 +63,24 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): + @typing.overload + def _classname_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _classname_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -77,12 +89,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _classname_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -92,7 +105,7 @@ class BaseApi(api_client.Api): def _classname_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -169,7 +182,7 @@ class Classname(BaseApi): def classname( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -178,12 +191,26 @@ class Classname(BaseApi): ApiResponseFor200, ]: ... + @typing.overload + def classname( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def classname( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -193,7 +220,7 @@ class Classname(BaseApi): def classname( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -229,7 +256,7 @@ class ApiForpatch(BaseApi): def patch( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -238,12 +265,26 @@ class ApiForpatch(BaseApi): ApiResponseFor200, ]: ... + @typing.overload + def patch( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def patch( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -253,7 +294,7 @@ class ApiForpatch(BaseApi): def patch( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_delete_coffee_id/delete.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_delete_coffee_id/delete.py index 4645054df51..ce7aa70a3f2 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_delete_coffee_id/delete.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_delete_coffee_id/delete.py @@ -83,7 +83,6 @@ class ApiResponseForDefault(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _delete_coffee_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_delete_coffee_id/delete.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_delete_coffee_id/delete.pyi index b3678a7e0b9..a335ef11adb 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_delete_coffee_id/delete.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_delete_coffee_id/delete.pyi @@ -77,7 +77,6 @@ _response_for_default = api_client.OpenApiResponse( class BaseApi(api_client.Api): - @typing.overload def _delete_coffee_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_health/get.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_health/get.py index 5a0ba828386..f3ebfb0b65b 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_health/get.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_health/get.py @@ -57,7 +57,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _fake_health_get_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_health/get.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_health/get.pyi index 04696ab5edf..f63161e2d2c 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_health/get.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_health/get.pyi @@ -52,7 +52,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _fake_health_get_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_inline_additional_properties/post.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_inline_additional_properties/post.py index 5f4cdb416bf..2363305f7cb 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_inline_additional_properties/post.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_inline_additional_properties/post.py @@ -84,12 +84,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _inline_additional_properties_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _inline_additional_properties_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -97,12 +108,13 @@ def _inline_additional_properties_oapg( ApiResponseFor200, ]: ... + @typing.overload def _inline_additional_properties_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -111,7 +123,7 @@ def _inline_additional_properties_oapg( def _inline_additional_properties_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -182,7 +194,19 @@ class InlineAdditionalProperties(BaseApi): def inline_additional_properties( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def inline_additional_properties( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -190,12 +214,13 @@ def inline_additional_properties( ApiResponseFor200, ]: ... + @typing.overload def inline_additional_properties( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -204,7 +229,7 @@ def inline_additional_properties( def inline_additional_properties( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -237,7 +262,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -245,12 +282,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -259,7 +297,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_inline_additional_properties/post.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_inline_additional_properties/post.pyi index 5e38441b49e..71113ab91af 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_inline_additional_properties/post.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_inline_additional_properties/post.pyi @@ -79,12 +79,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _inline_additional_properties_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _inline_additional_properties_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -92,12 +103,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _inline_additional_properties_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -106,7 +118,7 @@ class BaseApi(api_client.Api): def _inline_additional_properties_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -177,7 +189,19 @@ class InlineAdditionalProperties(BaseApi): def inline_additional_properties( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def inline_additional_properties( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -185,12 +209,13 @@ class InlineAdditionalProperties(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def inline_additional_properties( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -199,7 +224,7 @@ class InlineAdditionalProperties(BaseApi): def inline_additional_properties( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -232,7 +257,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -240,12 +277,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -254,7 +292,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,dict, frozendict.frozendict, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_inline_composition_/post.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_inline_composition_/post.py index d6eb6aba43e..773cb9e68dc 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_inline_composition_/post.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_inline_composition_/post.py @@ -518,13 +518,40 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _inline_composition_oapg( + self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, + query_params: RequestQueryParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def _inline_composition_oapg( + self, + content_type: typing_extensions.Literal["multipart/form-data"], + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + query_params: RequestQueryParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _inline_composition_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -533,13 +560,14 @@ def _inline_composition_oapg( ApiResponseFor200, ]: ... + @typing.overload def _inline_composition_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -548,9 +576,9 @@ def _inline_composition_oapg( @typing.overload def _inline_composition_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -562,9 +590,9 @@ def _inline_composition_oapg( def _inline_composition_oapg( self, + content_type: str = 'application/json', body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -639,9 +667,37 @@ class InlineComposition(BaseApi): @typing.overload def inline_composition( self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, + query_params: RequestQueryParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def inline_composition( + self, + content_type: typing_extensions.Literal["multipart/form-data"], + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + query_params: RequestQueryParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def inline_composition( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -650,13 +706,14 @@ def inline_composition( ApiResponseFor200, ]: ... + @typing.overload def inline_composition( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -665,9 +722,9 @@ def inline_composition( @typing.overload def inline_composition( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -679,9 +736,9 @@ def inline_composition( def inline_composition( self, + content_type: str = 'application/json', body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -704,9 +761,37 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, + query_params: RequestQueryParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: typing_extensions.Literal["multipart/form-data"], + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + query_params: RequestQueryParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -715,13 +800,14 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -730,9 +816,9 @@ def post( @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -744,9 +830,9 @@ def post( def post( self, + content_type: str = 'application/json', body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_inline_composition_/post.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_inline_composition_/post.pyi index ed24c47b463..792a56b9523 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_inline_composition_/post.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_inline_composition_/post.pyi @@ -495,13 +495,40 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): + @typing.overload + def _inline_composition_oapg( + self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, + query_params: RequestQueryParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def _inline_composition_oapg( + self, + content_type: typing_extensions.Literal["multipart/form-data"], + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + query_params: RequestQueryParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _inline_composition_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -510,13 +537,14 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _inline_composition_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -525,9 +553,9 @@ class BaseApi(api_client.Api): @typing.overload def _inline_composition_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -539,9 +567,9 @@ class BaseApi(api_client.Api): def _inline_composition_oapg( self, + content_type: str = 'application/json', body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -616,9 +644,37 @@ class InlineComposition(BaseApi): @typing.overload def inline_composition( self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, + query_params: RequestQueryParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def inline_composition( + self, + content_type: typing_extensions.Literal["multipart/form-data"], + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + query_params: RequestQueryParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def inline_composition( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -627,13 +683,14 @@ class InlineComposition(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def inline_composition( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -642,9 +699,9 @@ class InlineComposition(BaseApi): @typing.overload def inline_composition( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -656,9 +713,9 @@ class InlineComposition(BaseApi): def inline_composition( self, + content_type: str = 'application/json', body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -681,9 +738,37 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, + query_params: RequestQueryParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: typing_extensions.Literal["multipart/form-data"], + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + query_params: RequestQueryParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -692,13 +777,14 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -707,9 +793,9 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -721,9 +807,9 @@ class ApiForpost(BaseApi): def post( self, + content_type: str = 'application/json', body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_json_form_data/get.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_json_form_data/get.py index 6c1d665e721..262f5e3a77a 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_json_form_data/get.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_json_form_data/get.py @@ -121,12 +121,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _json_form_data_oapg( + self, + content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _json_form_data_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -134,12 +145,13 @@ def _json_form_data_oapg( ApiResponseFor200, ]: ... + @typing.overload def _json_form_data_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -147,8 +159,8 @@ def _json_form_data_oapg( @typing.overload def _json_form_data_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -159,8 +171,8 @@ def _json_form_data_oapg( def _json_form_data_oapg( self, - body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, content_type: str = 'application/x-www-form-urlencoded', + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -216,8 +228,20 @@ class JsonFormData(BaseApi): @typing.overload def json_form_data( self, + content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def json_form_data( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -225,12 +249,13 @@ def json_form_data( ApiResponseFor200, ]: ... + @typing.overload def json_form_data( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -238,8 +263,8 @@ def json_form_data( @typing.overload def json_form_data( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -250,8 +275,8 @@ def json_form_data( def json_form_data( self, - body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, content_type: str = 'application/x-www-form-urlencoded', + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -271,8 +296,8 @@ class ApiForget(BaseApi): @typing.overload def get( self, + content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -280,12 +305,25 @@ def get( ApiResponseFor200, ]: ... + @typing.overload + def get( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def get( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -293,8 +331,8 @@ def get( @typing.overload def get( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -305,8 +343,8 @@ def get( def get( self, - body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, content_type: str = 'application/x-www-form-urlencoded', + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_json_form_data/get.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_json_form_data/get.pyi index 000a4ac2134..e1ce6578278 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_json_form_data/get.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_json_form_data/get.pyi @@ -116,12 +116,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _json_form_data_oapg( + self, + content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _json_form_data_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -129,12 +140,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _json_form_data_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -142,8 +154,8 @@ class BaseApi(api_client.Api): @typing.overload def _json_form_data_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -154,8 +166,8 @@ class BaseApi(api_client.Api): def _json_form_data_oapg( self, - body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, content_type: str = 'application/x-www-form-urlencoded', + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -211,8 +223,20 @@ class JsonFormData(BaseApi): @typing.overload def json_form_data( self, + content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def json_form_data( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -220,12 +244,13 @@ class JsonFormData(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def json_form_data( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -233,8 +258,8 @@ class JsonFormData(BaseApi): @typing.overload def json_form_data( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -245,8 +270,8 @@ class JsonFormData(BaseApi): def json_form_data( self, - body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, content_type: str = 'application/x-www-form-urlencoded', + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -266,8 +291,8 @@ class ApiForget(BaseApi): @typing.overload def get( self, + content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -275,12 +300,25 @@ class ApiForget(BaseApi): ApiResponseFor200, ]: ... + @typing.overload + def get( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def get( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -288,8 +326,8 @@ class ApiForget(BaseApi): @typing.overload def get( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -300,8 +338,8 @@ class ApiForget(BaseApi): def get( self, - body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, content_type: str = 'application/x-www-form-urlencoded', + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_json_patch/patch.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_json_patch/patch.py index c2df40d52a4..d55867cd112 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_json_patch/patch.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_json_patch/patch.py @@ -57,12 +57,23 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _json_patch_oapg( + self, + content_type: typing_extensions.Literal["application/json-patch+json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _json_patch_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json-patch+json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -70,12 +81,13 @@ def _json_patch_oapg( ApiResponseFor200, ]: ... + @typing.overload def _json_patch_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json-patch+json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -83,8 +95,8 @@ def _json_patch_oapg( @typing.overload def _json_patch_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json-patch+json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -95,8 +107,8 @@ def _json_patch_oapg( def _json_patch_oapg( self, - body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, content_type: str = 'application/json-patch+json', + body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -152,8 +164,20 @@ class JsonPatch(BaseApi): @typing.overload def json_patch( self, + content_type: typing_extensions.Literal["application/json-patch+json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def json_patch( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json-patch+json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -161,12 +185,13 @@ def json_patch( ApiResponseFor200, ]: ... + @typing.overload def json_patch( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json-patch+json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -174,8 +199,8 @@ def json_patch( @typing.overload def json_patch( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json-patch+json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -186,8 +211,8 @@ def json_patch( def json_patch( self, - body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, content_type: str = 'application/json-patch+json', + body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -207,8 +232,8 @@ class ApiForpatch(BaseApi): @typing.overload def patch( self, + content_type: typing_extensions.Literal["application/json-patch+json"] = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json-patch+json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -216,12 +241,25 @@ def patch( ApiResponseFor200, ]: ... + @typing.overload + def patch( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def patch( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json-patch+json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -229,8 +267,8 @@ def patch( @typing.overload def patch( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json-patch+json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -241,8 +279,8 @@ def patch( def patch( self, - body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, content_type: str = 'application/json-patch+json', + body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_json_patch/patch.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_json_patch/patch.pyi index 1fa03d3a3f7..3322e593ccd 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_json_patch/patch.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_json_patch/patch.pyi @@ -52,12 +52,23 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _json_patch_oapg( + self, + content_type: typing_extensions.Literal["application/json-patch+json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _json_patch_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json-patch+json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -65,12 +76,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _json_patch_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json-patch+json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -78,8 +90,8 @@ class BaseApi(api_client.Api): @typing.overload def _json_patch_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json-patch+json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -90,8 +102,8 @@ class BaseApi(api_client.Api): def _json_patch_oapg( self, - body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, content_type: str = 'application/json-patch+json', + body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -147,8 +159,20 @@ class JsonPatch(BaseApi): @typing.overload def json_patch( self, + content_type: typing_extensions.Literal["application/json-patch+json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def json_patch( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json-patch+json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -156,12 +180,13 @@ class JsonPatch(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def json_patch( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json-patch+json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -169,8 +194,8 @@ class JsonPatch(BaseApi): @typing.overload def json_patch( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json-patch+json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -181,8 +206,8 @@ class JsonPatch(BaseApi): def json_patch( self, - body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, content_type: str = 'application/json-patch+json', + body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -202,8 +227,8 @@ class ApiForpatch(BaseApi): @typing.overload def patch( self, + content_type: typing_extensions.Literal["application/json-patch+json"] = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json-patch+json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -211,12 +236,25 @@ class ApiForpatch(BaseApi): ApiResponseFor200, ]: ... + @typing.overload + def patch( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def patch( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json-patch+json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -224,8 +262,8 @@ class ApiForpatch(BaseApi): @typing.overload def patch( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json-patch+json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -236,8 +274,8 @@ class ApiForpatch(BaseApi): def patch( self, - body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, content_type: str = 'application/json-patch+json', + body: typing.Union[SchemaForRequestBodyApplicationJsonPatchjson, schemas.Unset] = schemas.unset, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_json_with_charset/post.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_json_with_charset/post.py index 6652669e7ef..7e075373a3e 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_json_with_charset/post.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_json_with_charset/post.py @@ -65,12 +65,24 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _json_with_charset_oapg( + self, + content_type: typing_extensions.Literal["application/json; charset=utf-8"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _json_with_charset_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, - content_type: str = 'application/json; charset=utf-8', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -79,12 +91,13 @@ def _json_with_charset_oapg( ApiResponseFor200, ]: ... + @typing.overload def _json_with_charset_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, - content_type: str = 'application/json; charset=utf-8', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -93,8 +106,8 @@ def _json_with_charset_oapg( @typing.overload def _json_with_charset_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, - content_type: str = 'application/json; charset=utf-8', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -106,8 +119,8 @@ def _json_with_charset_oapg( def _json_with_charset_oapg( self, - body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, content_type: str = 'application/json; charset=utf-8', + body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -167,8 +180,8 @@ class JsonWithCharset(BaseApi): @typing.overload def json_with_charset( self, + content_type: typing_extensions.Literal["application/json; charset=utf-8"] = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, - content_type: str = 'application/json; charset=utf-8', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -177,12 +190,26 @@ def json_with_charset( ApiResponseFor200, ]: ... + @typing.overload + def json_with_charset( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def json_with_charset( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, - content_type: str = 'application/json; charset=utf-8', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -191,8 +218,8 @@ def json_with_charset( @typing.overload def json_with_charset( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, - content_type: str = 'application/json; charset=utf-8', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -204,8 +231,8 @@ def json_with_charset( def json_with_charset( self, - body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, content_type: str = 'application/json; charset=utf-8', + body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -227,8 +254,21 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["application/json; charset=utf-8"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, - content_type: str = 'application/json; charset=utf-8', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -237,12 +277,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, - content_type: str = 'application/json; charset=utf-8', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -251,8 +292,8 @@ def post( @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, - content_type: str = 'application/json; charset=utf-8', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -264,8 +305,8 @@ def post( def post( self, - body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, content_type: str = 'application/json; charset=utf-8', + body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_json_with_charset/post.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_json_with_charset/post.pyi index b26dc03bf19..5246ee555a8 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_json_with_charset/post.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_json_with_charset/post.pyi @@ -60,12 +60,24 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): + @typing.overload + def _json_with_charset_oapg( + self, + content_type: typing_extensions.Literal["application/json; charset=utf-8"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _json_with_charset_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, - content_type: str = 'application/json; charset=utf-8', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -74,12 +86,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _json_with_charset_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, - content_type: str = 'application/json; charset=utf-8', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -88,8 +101,8 @@ class BaseApi(api_client.Api): @typing.overload def _json_with_charset_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, - content_type: str = 'application/json; charset=utf-8', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -101,8 +114,8 @@ class BaseApi(api_client.Api): def _json_with_charset_oapg( self, - body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, content_type: str = 'application/json; charset=utf-8', + body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -162,8 +175,8 @@ class JsonWithCharset(BaseApi): @typing.overload def json_with_charset( self, + content_type: typing_extensions.Literal["application/json; charset=utf-8"] = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, - content_type: str = 'application/json; charset=utf-8', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -172,12 +185,26 @@ class JsonWithCharset(BaseApi): ApiResponseFor200, ]: ... + @typing.overload + def json_with_charset( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def json_with_charset( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, - content_type: str = 'application/json; charset=utf-8', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -186,8 +213,8 @@ class JsonWithCharset(BaseApi): @typing.overload def json_with_charset( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, - content_type: str = 'application/json; charset=utf-8', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -199,8 +226,8 @@ class JsonWithCharset(BaseApi): def json_with_charset( self, - body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, content_type: str = 'application/json; charset=utf-8', + body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -222,8 +249,21 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["application/json; charset=utf-8"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, - content_type: str = 'application/json; charset=utf-8', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -232,12 +272,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, - content_type: str = 'application/json; charset=utf-8', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -246,8 +287,8 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, - content_type: str = 'application/json; charset=utf-8', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -259,8 +300,8 @@ class ApiForpost(BaseApi): def post( self, - body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, content_type: str = 'application/json; charset=utf-8', + body: typing.Union[SchemaForRequestBodyApplicationJsonCharsetutf8, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_obj_in_query/get.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_obj_in_query/get.py index 27f838479ad..42f84efdab3 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_obj_in_query/get.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_obj_in_query/get.py @@ -119,7 +119,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _object_in_query_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_obj_in_query/get.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_obj_in_query/get.pyi index b8309d1900e..430110a4c5d 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_obj_in_query/get.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_obj_in_query/get.pyi @@ -114,7 +114,6 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): - @typing.overload def _object_in_query_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_parameter_collisions_1_a_b_ab_self_a_b_/post.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_parameter_collisions_1_a_b_ab_self_a_b_/post.py index 89397f85e1a..2066984b82f 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_parameter_collisions_1_a_b_ab_self_a_b_/post.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_parameter_collisions_1_a_b_ab_self_a_b_/post.py @@ -285,16 +285,32 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _parameter_collisions_oapg( + self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, + query_params: RequestQueryParams = frozendict.frozendict(), + header_params: RequestHeaderParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + cookie_params: RequestCookieParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _parameter_collisions_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), cookie_params: RequestCookieParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -303,16 +319,17 @@ def _parameter_collisions_oapg( ApiResponseFor200, ]: ... + @typing.overload def _parameter_collisions_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), cookie_params: RequestCookieParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -321,12 +338,12 @@ def _parameter_collisions_oapg( @typing.overload def _parameter_collisions_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), cookie_params: RequestCookieParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -338,12 +355,12 @@ def _parameter_collisions_oapg( def _parameter_collisions_oapg( self, + content_type: str = 'application/json', body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), cookie_params: RequestCookieParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -452,12 +469,12 @@ class ParameterCollisions(BaseApi): @typing.overload def parameter_collisions( self, + content_type: typing_extensions.Literal["application/json"] = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), cookie_params: RequestCookieParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -466,16 +483,34 @@ def parameter_collisions( ApiResponseFor200, ]: ... + @typing.overload + def parameter_collisions( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, + query_params: RequestQueryParams = frozendict.frozendict(), + header_params: RequestHeaderParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + cookie_params: RequestCookieParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def parameter_collisions( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), cookie_params: RequestCookieParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -484,12 +519,12 @@ def parameter_collisions( @typing.overload def parameter_collisions( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), cookie_params: RequestCookieParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -501,12 +536,12 @@ def parameter_collisions( def parameter_collisions( self, + content_type: str = 'application/json', body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), cookie_params: RequestCookieParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -532,12 +567,29 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, + query_params: RequestQueryParams = frozendict.frozendict(), + header_params: RequestHeaderParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + cookie_params: RequestCookieParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), cookie_params: RequestCookieParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -546,16 +598,17 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), cookie_params: RequestCookieParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -564,12 +617,12 @@ def post( @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), cookie_params: RequestCookieParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -581,12 +634,12 @@ def post( def post( self, + content_type: str = 'application/json', body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), cookie_params: RequestCookieParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_parameter_collisions_1_a_b_ab_self_a_b_/post.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_parameter_collisions_1_a_b_ab_self_a_b_/post.pyi index b2ea31c6e42..54afd52d1ab 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_parameter_collisions_1_a_b_ab_self_a_b_/post.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_parameter_collisions_1_a_b_ab_self_a_b_/post.pyi @@ -280,16 +280,32 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): + @typing.overload + def _parameter_collisions_oapg( + self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, + query_params: RequestQueryParams = frozendict.frozendict(), + header_params: RequestHeaderParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + cookie_params: RequestCookieParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _parameter_collisions_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), cookie_params: RequestCookieParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -298,16 +314,17 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _parameter_collisions_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), cookie_params: RequestCookieParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -316,12 +333,12 @@ class BaseApi(api_client.Api): @typing.overload def _parameter_collisions_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), cookie_params: RequestCookieParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -333,12 +350,12 @@ class BaseApi(api_client.Api): def _parameter_collisions_oapg( self, + content_type: str = 'application/json', body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), cookie_params: RequestCookieParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -447,12 +464,12 @@ class ParameterCollisions(BaseApi): @typing.overload def parameter_collisions( self, + content_type: typing_extensions.Literal["application/json"] = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), cookie_params: RequestCookieParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -461,16 +478,34 @@ class ParameterCollisions(BaseApi): ApiResponseFor200, ]: ... + @typing.overload + def parameter_collisions( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, + query_params: RequestQueryParams = frozendict.frozendict(), + header_params: RequestHeaderParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + cookie_params: RequestCookieParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def parameter_collisions( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), cookie_params: RequestCookieParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -479,12 +514,12 @@ class ParameterCollisions(BaseApi): @typing.overload def parameter_collisions( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), cookie_params: RequestCookieParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -496,12 +531,12 @@ class ParameterCollisions(BaseApi): def parameter_collisions( self, + content_type: str = 'application/json', body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), cookie_params: RequestCookieParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -527,12 +562,29 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, + query_params: RequestQueryParams = frozendict.frozendict(), + header_params: RequestHeaderParams = frozendict.frozendict(), + path_params: RequestPathParams = frozendict.frozendict(), + cookie_params: RequestCookieParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), cookie_params: RequestCookieParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -541,16 +593,17 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), cookie_params: RequestCookieParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -559,12 +612,12 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), cookie_params: RequestCookieParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -576,12 +629,12 @@ class ApiForpost(BaseApi): def post( self, + content_type: str = 'application/json', body: typing.Union[SchemaForRequestBodyApplicationJson, dict, frozendict.frozendict, str, date, datetime, uuid.UUID, int, float, decimal.Decimal, bool, None, list, tuple, bytes, io.FileIO, io.BufferedReader, schemas.Unset] = schemas.unset, query_params: RequestQueryParams = frozendict.frozendict(), header_params: RequestHeaderParams = frozendict.frozendict(), path_params: RequestPathParams = frozendict.frozendict(), cookie_params: RequestCookieParams = frozendict.frozendict(), - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_pet_id_upload_image_with_required_file/post.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_pet_id_upload_image_with_required_file/post.py index 44b42b04cf2..b03e10437be 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_pet_id_upload_image_with_required_file/post.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_pet_id_upload_image_with_required_file/post.py @@ -160,13 +160,26 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _upload_file_with_required_file_oapg( + self, + content_type: typing_extensions.Literal["multipart/form-data"] = ..., + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _upload_file_with_required_file_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -175,13 +188,14 @@ def _upload_file_with_required_file_oapg( ApiResponseFor200, ]: ... + @typing.overload def _upload_file_with_required_file_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -190,9 +204,9 @@ def _upload_file_with_required_file_oapg( @typing.overload def _upload_file_with_required_file_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -204,9 +218,9 @@ def _upload_file_with_required_file_oapg( def _upload_file_with_required_file_oapg( self, + content_type: str = 'multipart/form-data', body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -281,9 +295,23 @@ class UploadFileWithRequiredFile(BaseApi): @typing.overload def upload_file_with_required_file( self, + content_type: typing_extensions.Literal["multipart/form-data"] = ..., + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def upload_file_with_required_file( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -292,13 +320,14 @@ def upload_file_with_required_file( ApiResponseFor200, ]: ... + @typing.overload def upload_file_with_required_file( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -307,9 +336,9 @@ def upload_file_with_required_file( @typing.overload def upload_file_with_required_file( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -321,9 +350,9 @@ def upload_file_with_required_file( def upload_file_with_required_file( self, + content_type: str = 'multipart/form-data', body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -346,9 +375,23 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["multipart/form-data"] = ..., + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -357,13 +400,14 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -372,9 +416,9 @@ def post( @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -386,9 +430,9 @@ def post( def post( self, + content_type: str = 'multipart/form-data', body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_pet_id_upload_image_with_required_file/post.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_pet_id_upload_image_with_required_file/post.pyi index bc6c996b924..13dbfef9b5d 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_pet_id_upload_image_with_required_file/post.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_pet_id_upload_image_with_required_file/post.pyi @@ -152,13 +152,26 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): + @typing.overload + def _upload_file_with_required_file_oapg( + self, + content_type: typing_extensions.Literal["multipart/form-data"] = ..., + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _upload_file_with_required_file_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -167,13 +180,14 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _upload_file_with_required_file_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -182,9 +196,9 @@ class BaseApi(api_client.Api): @typing.overload def _upload_file_with_required_file_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -196,9 +210,9 @@ class BaseApi(api_client.Api): def _upload_file_with_required_file_oapg( self, + content_type: str = 'multipart/form-data', body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -273,9 +287,23 @@ class UploadFileWithRequiredFile(BaseApi): @typing.overload def upload_file_with_required_file( self, + content_type: typing_extensions.Literal["multipart/form-data"] = ..., + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def upload_file_with_required_file( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -284,13 +312,14 @@ class UploadFileWithRequiredFile(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def upload_file_with_required_file( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -299,9 +328,9 @@ class UploadFileWithRequiredFile(BaseApi): @typing.overload def upload_file_with_required_file( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -313,9 +342,9 @@ class UploadFileWithRequiredFile(BaseApi): def upload_file_with_required_file( self, + content_type: str = 'multipart/form-data', body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -338,9 +367,23 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["multipart/form-data"] = ..., + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -349,13 +392,14 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -364,9 +408,9 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -378,9 +422,9 @@ class ApiForpost(BaseApi): def post( self, + content_type: str = 'multipart/form-data', body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_ref_obj_in_query/get.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_ref_obj_in_query/get.py index 0deeba048af..d2dc38fb58f 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_ref_obj_in_query/get.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_ref_obj_in_query/get.py @@ -72,7 +72,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _ref_object_in_query_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_ref_obj_in_query/get.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_ref_obj_in_query/get.pyi index ad881f57572..1e1cc7a0caa 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_ref_obj_in_query/get.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_ref_obj_in_query/get.pyi @@ -67,7 +67,6 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): - @typing.overload def _ref_object_in_query_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_array_of_enums/post.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_array_of_enums/post.py index 47215d62abd..f8ec75ce3ef 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_array_of_enums/post.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_array_of_enums/post.py @@ -67,12 +67,24 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _array_of_enums_oapg( + self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _array_of_enums_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -81,12 +93,13 @@ def _array_of_enums_oapg( ApiResponseFor200, ]: ... + @typing.overload def _array_of_enums_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -95,8 +108,8 @@ def _array_of_enums_oapg( @typing.overload def _array_of_enums_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -108,8 +121,8 @@ def _array_of_enums_oapg( def _array_of_enums_oapg( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -169,8 +182,8 @@ class ArrayOfEnums(BaseApi): @typing.overload def array_of_enums( self, + content_type: typing_extensions.Literal["application/json"] = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -179,12 +192,26 @@ def array_of_enums( ApiResponseFor200, ]: ... + @typing.overload + def array_of_enums( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def array_of_enums( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -193,8 +220,8 @@ def array_of_enums( @typing.overload def array_of_enums( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -206,8 +233,8 @@ def array_of_enums( def array_of_enums( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -229,8 +256,21 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -239,12 +279,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -253,8 +294,8 @@ def post( @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -266,8 +307,8 @@ def post( def post( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_array_of_enums/post.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_array_of_enums/post.pyi index 9acdbc3afa9..ac0fb2920f3 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_array_of_enums/post.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_array_of_enums/post.pyi @@ -62,12 +62,24 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): + @typing.overload + def _array_of_enums_oapg( + self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _array_of_enums_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -76,12 +88,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _array_of_enums_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -90,8 +103,8 @@ class BaseApi(api_client.Api): @typing.overload def _array_of_enums_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -103,8 +116,8 @@ class BaseApi(api_client.Api): def _array_of_enums_oapg( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -164,8 +177,8 @@ class ArrayOfEnums(BaseApi): @typing.overload def array_of_enums( self, + content_type: typing_extensions.Literal["application/json"] = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -174,12 +187,26 @@ class ArrayOfEnums(BaseApi): ApiResponseFor200, ]: ... + @typing.overload + def array_of_enums( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def array_of_enums( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -188,8 +215,8 @@ class ArrayOfEnums(BaseApi): @typing.overload def array_of_enums( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -201,8 +228,8 @@ class ArrayOfEnums(BaseApi): def array_of_enums( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -224,8 +251,21 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -234,12 +274,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -248,8 +289,8 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -261,8 +302,8 @@ class ApiForpost(BaseApi): def post( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_arraymodel/post.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_arraymodel/post.py index 3dda054f6ae..cebbb40e5fc 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_arraymodel/post.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_arraymodel/post.py @@ -67,12 +67,24 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _array_model_oapg( + self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _array_model_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -81,12 +93,13 @@ def _array_model_oapg( ApiResponseFor200, ]: ... + @typing.overload def _array_model_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -95,8 +108,8 @@ def _array_model_oapg( @typing.overload def _array_model_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -108,8 +121,8 @@ def _array_model_oapg( def _array_model_oapg( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -168,8 +181,8 @@ class ArrayModel(BaseApi): @typing.overload def array_model( self, + content_type: typing_extensions.Literal["application/json"] = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -178,12 +191,26 @@ def array_model( ApiResponseFor200, ]: ... + @typing.overload + def array_model( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def array_model( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -192,8 +219,8 @@ def array_model( @typing.overload def array_model( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -205,8 +232,8 @@ def array_model( def array_model( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -228,8 +255,21 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -238,12 +278,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -252,8 +293,8 @@ def post( @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -265,8 +306,8 @@ def post( def post( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_arraymodel/post.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_arraymodel/post.pyi index d94579a5906..ed802fd8c6f 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_arraymodel/post.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_arraymodel/post.pyi @@ -62,12 +62,24 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): + @typing.overload + def _array_model_oapg( + self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _array_model_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -76,12 +88,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _array_model_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -90,8 +103,8 @@ class BaseApi(api_client.Api): @typing.overload def _array_model_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -103,8 +116,8 @@ class BaseApi(api_client.Api): def _array_model_oapg( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -163,8 +176,8 @@ class ArrayModel(BaseApi): @typing.overload def array_model( self, + content_type: typing_extensions.Literal["application/json"] = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -173,12 +186,26 @@ class ArrayModel(BaseApi): ApiResponseFor200, ]: ... + @typing.overload + def array_model( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def array_model( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -187,8 +214,8 @@ class ArrayModel(BaseApi): @typing.overload def array_model( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -200,8 +227,8 @@ class ArrayModel(BaseApi): def array_model( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -223,8 +250,21 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -233,12 +273,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -247,8 +288,8 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -260,8 +301,8 @@ class ApiForpost(BaseApi): def post( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_boolean/post.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_boolean/post.py index 778fe07c0af..6eee57e2c63 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_boolean/post.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_boolean/post.py @@ -65,12 +65,24 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _boolean_oapg( + self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _boolean_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -79,12 +91,13 @@ def _boolean_oapg( ApiResponseFor200, ]: ... + @typing.overload def _boolean_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -93,8 +106,8 @@ def _boolean_oapg( @typing.overload def _boolean_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -106,8 +119,8 @@ def _boolean_oapg( def _boolean_oapg( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -166,8 +179,8 @@ class Boolean(BaseApi): @typing.overload def boolean( self, + content_type: typing_extensions.Literal["application/json"] = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -176,12 +189,26 @@ def boolean( ApiResponseFor200, ]: ... + @typing.overload + def boolean( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def boolean( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -190,8 +217,8 @@ def boolean( @typing.overload def boolean( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -203,8 +230,8 @@ def boolean( def boolean( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -226,8 +253,21 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -236,12 +276,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -250,8 +291,8 @@ def post( @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -263,8 +304,8 @@ def post( def post( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_boolean/post.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_boolean/post.pyi index 339139bd41d..7a975a27bc9 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_boolean/post.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_boolean/post.pyi @@ -60,12 +60,24 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): + @typing.overload + def _boolean_oapg( + self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _boolean_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -74,12 +86,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _boolean_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -88,8 +101,8 @@ class BaseApi(api_client.Api): @typing.overload def _boolean_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -101,8 +114,8 @@ class BaseApi(api_client.Api): def _boolean_oapg( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -161,8 +174,8 @@ class Boolean(BaseApi): @typing.overload def boolean( self, + content_type: typing_extensions.Literal["application/json"] = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -171,12 +184,26 @@ class Boolean(BaseApi): ApiResponseFor200, ]: ... + @typing.overload + def boolean( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def boolean( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -185,8 +212,8 @@ class Boolean(BaseApi): @typing.overload def boolean( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -198,8 +225,8 @@ class Boolean(BaseApi): def boolean( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -221,8 +248,21 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -231,12 +271,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -245,8 +286,8 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -258,8 +299,8 @@ class ApiForpost(BaseApi): def post( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, bool, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_composed_one_of_number_with_validations/post.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_composed_one_of_number_with_validations/post.py index c4ab0e08b36..84acaf17020 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_composed_one_of_number_with_validations/post.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_composed_one_of_number_with_validations/post.py @@ -67,12 +67,24 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _composed_one_of_different_types_oapg( + self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _composed_one_of_different_types_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -81,12 +93,13 @@ def _composed_one_of_different_types_oapg( ApiResponseFor200, ]: ... + @typing.overload def _composed_one_of_different_types_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -95,8 +108,8 @@ def _composed_one_of_different_types_oapg( @typing.overload def _composed_one_of_different_types_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -108,8 +121,8 @@ def _composed_one_of_different_types_oapg( def _composed_one_of_different_types_oapg( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -168,8 +181,8 @@ class ComposedOneOfDifferentTypes(BaseApi): @typing.overload def composed_one_of_different_types( self, + content_type: typing_extensions.Literal["application/json"] = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -178,12 +191,26 @@ def composed_one_of_different_types( ApiResponseFor200, ]: ... + @typing.overload + def composed_one_of_different_types( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def composed_one_of_different_types( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -192,8 +219,8 @@ def composed_one_of_different_types( @typing.overload def composed_one_of_different_types( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -205,8 +232,8 @@ def composed_one_of_different_types( def composed_one_of_different_types( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -228,8 +255,21 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -238,12 +278,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -252,8 +293,8 @@ def post( @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -265,8 +306,8 @@ def post( def post( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_composed_one_of_number_with_validations/post.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_composed_one_of_number_with_validations/post.pyi index cf56e95993e..30d5f91dba2 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_composed_one_of_number_with_validations/post.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_composed_one_of_number_with_validations/post.pyi @@ -62,12 +62,24 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): + @typing.overload + def _composed_one_of_different_types_oapg( + self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _composed_one_of_different_types_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -76,12 +88,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _composed_one_of_different_types_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -90,8 +103,8 @@ class BaseApi(api_client.Api): @typing.overload def _composed_one_of_different_types_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -103,8 +116,8 @@ class BaseApi(api_client.Api): def _composed_one_of_different_types_oapg( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -163,8 +176,8 @@ class ComposedOneOfDifferentTypes(BaseApi): @typing.overload def composed_one_of_different_types( self, + content_type: typing_extensions.Literal["application/json"] = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -173,12 +186,26 @@ class ComposedOneOfDifferentTypes(BaseApi): ApiResponseFor200, ]: ... + @typing.overload + def composed_one_of_different_types( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def composed_one_of_different_types( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -187,8 +214,8 @@ class ComposedOneOfDifferentTypes(BaseApi): @typing.overload def composed_one_of_different_types( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -200,8 +227,8 @@ class ComposedOneOfDifferentTypes(BaseApi): def composed_one_of_different_types( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -223,8 +250,21 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -233,12 +273,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -247,8 +288,8 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -260,8 +301,8 @@ class ApiForpost(BaseApi): def post( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_enum/post.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_enum/post.py index 2f2da667354..4b953d05000 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_enum/post.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_enum/post.py @@ -67,12 +67,24 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _string_enum_oapg( + self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _string_enum_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -81,12 +93,13 @@ def _string_enum_oapg( ApiResponseFor200, ]: ... + @typing.overload def _string_enum_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -95,8 +108,8 @@ def _string_enum_oapg( @typing.overload def _string_enum_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -108,8 +121,8 @@ def _string_enum_oapg( def _string_enum_oapg( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -168,8 +181,8 @@ class StringEnum(BaseApi): @typing.overload def string_enum( self, + content_type: typing_extensions.Literal["application/json"] = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -178,12 +191,26 @@ def string_enum( ApiResponseFor200, ]: ... + @typing.overload + def string_enum( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def string_enum( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -192,8 +219,8 @@ def string_enum( @typing.overload def string_enum( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -205,8 +232,8 @@ def string_enum( def string_enum( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -228,8 +255,21 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -238,12 +278,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -252,8 +293,8 @@ def post( @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -265,8 +306,8 @@ def post( def post( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_enum/post.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_enum/post.pyi index 72660dc0b3f..ea4b1fe2ff5 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_enum/post.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_enum/post.pyi @@ -62,12 +62,24 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): + @typing.overload + def _string_enum_oapg( + self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _string_enum_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -76,12 +88,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _string_enum_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -90,8 +103,8 @@ class BaseApi(api_client.Api): @typing.overload def _string_enum_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -103,8 +116,8 @@ class BaseApi(api_client.Api): def _string_enum_oapg( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -163,8 +176,8 @@ class StringEnum(BaseApi): @typing.overload def string_enum( self, + content_type: typing_extensions.Literal["application/json"] = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -173,12 +186,26 @@ class StringEnum(BaseApi): ApiResponseFor200, ]: ... + @typing.overload + def string_enum( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def string_enum( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -187,8 +214,8 @@ class StringEnum(BaseApi): @typing.overload def string_enum( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -200,8 +227,8 @@ class StringEnum(BaseApi): def string_enum( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -223,8 +250,21 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -233,12 +273,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -247,8 +288,8 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -260,8 +301,8 @@ class ApiForpost(BaseApi): def post( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_mammal/post.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_mammal/post.py index 8bd4e36b483..dfeb527472f 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_mammal/post.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_mammal/post.py @@ -68,12 +68,24 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _mammal_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _mammal_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -82,12 +94,13 @@ def _mammal_oapg( ApiResponseFor200, ]: ... + @typing.overload def _mammal_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -97,7 +110,7 @@ def _mammal_oapg( def _mammal_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -172,7 +185,7 @@ class Mammal(BaseApi): def mammal( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -181,12 +194,26 @@ def mammal( ApiResponseFor200, ]: ... + @typing.overload + def mammal( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def mammal( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -196,7 +223,7 @@ def mammal( def mammal( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -232,7 +259,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -241,12 +268,26 @@ def post( ApiResponseFor200, ]: ... + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -256,7 +297,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_mammal/post.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_mammal/post.pyi index 1fee5a169af..24137e6fa53 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_mammal/post.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_mammal/post.pyi @@ -63,12 +63,24 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): + @typing.overload + def _mammal_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _mammal_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -77,12 +89,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _mammal_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -92,7 +105,7 @@ class BaseApi(api_client.Api): def _mammal_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -167,7 +180,7 @@ class Mammal(BaseApi): def mammal( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -176,12 +189,26 @@ class Mammal(BaseApi): ApiResponseFor200, ]: ... + @typing.overload + def mammal( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def mammal( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -191,7 +218,7 @@ class Mammal(BaseApi): def mammal( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -227,7 +254,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -236,12 +263,26 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -251,7 +292,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_number/post.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_number/post.py index b47abb72511..ab8e5088e51 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_number/post.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_number/post.py @@ -67,12 +67,24 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _number_with_validations_oapg( + self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _number_with_validations_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -81,12 +93,13 @@ def _number_with_validations_oapg( ApiResponseFor200, ]: ... + @typing.overload def _number_with_validations_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -95,8 +108,8 @@ def _number_with_validations_oapg( @typing.overload def _number_with_validations_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -108,8 +121,8 @@ def _number_with_validations_oapg( def _number_with_validations_oapg( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -168,8 +181,8 @@ class NumberWithValidations(BaseApi): @typing.overload def number_with_validations( self, + content_type: typing_extensions.Literal["application/json"] = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -178,12 +191,26 @@ def number_with_validations( ApiResponseFor200, ]: ... + @typing.overload + def number_with_validations( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def number_with_validations( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -192,8 +219,8 @@ def number_with_validations( @typing.overload def number_with_validations( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -205,8 +232,8 @@ def number_with_validations( def number_with_validations( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -228,8 +255,21 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -238,12 +278,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -252,8 +293,8 @@ def post( @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -265,8 +306,8 @@ def post( def post( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_number/post.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_number/post.pyi index 02688717625..8fb5defd566 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_number/post.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_number/post.pyi @@ -62,12 +62,24 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): + @typing.overload + def _number_with_validations_oapg( + self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _number_with_validations_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -76,12 +88,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _number_with_validations_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -90,8 +103,8 @@ class BaseApi(api_client.Api): @typing.overload def _number_with_validations_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -103,8 +116,8 @@ class BaseApi(api_client.Api): def _number_with_validations_oapg( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -163,8 +176,8 @@ class NumberWithValidations(BaseApi): @typing.overload def number_with_validations( self, + content_type: typing_extensions.Literal["application/json"] = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -173,12 +186,26 @@ class NumberWithValidations(BaseApi): ApiResponseFor200, ]: ... + @typing.overload + def number_with_validations( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def number_with_validations( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -187,8 +214,8 @@ class NumberWithValidations(BaseApi): @typing.overload def number_with_validations( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -200,8 +227,8 @@ class NumberWithValidations(BaseApi): def number_with_validations( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -223,8 +250,21 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -233,12 +273,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -247,8 +288,8 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -260,8 +301,8 @@ class ApiForpost(BaseApi): def post( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_object_model_with_ref_props/post.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_object_model_with_ref_props/post.py index 5565305ece0..9df4ea7f154 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_object_model_with_ref_props/post.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_object_model_with_ref_props/post.py @@ -67,12 +67,24 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _object_model_with_ref_props_oapg( + self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _object_model_with_ref_props_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -81,12 +93,13 @@ def _object_model_with_ref_props_oapg( ApiResponseFor200, ]: ... + @typing.overload def _object_model_with_ref_props_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -95,8 +108,8 @@ def _object_model_with_ref_props_oapg( @typing.overload def _object_model_with_ref_props_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -108,8 +121,8 @@ def _object_model_with_ref_props_oapg( def _object_model_with_ref_props_oapg( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -168,8 +181,8 @@ class ObjectModelWithRefProps(BaseApi): @typing.overload def object_model_with_ref_props( self, + content_type: typing_extensions.Literal["application/json"] = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -178,12 +191,26 @@ def object_model_with_ref_props( ApiResponseFor200, ]: ... + @typing.overload + def object_model_with_ref_props( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def object_model_with_ref_props( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -192,8 +219,8 @@ def object_model_with_ref_props( @typing.overload def object_model_with_ref_props( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -205,8 +232,8 @@ def object_model_with_ref_props( def object_model_with_ref_props( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -228,8 +255,21 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -238,12 +278,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -252,8 +293,8 @@ def post( @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -265,8 +306,8 @@ def post( def post( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_object_model_with_ref_props/post.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_object_model_with_ref_props/post.pyi index c3ea0c5a205..7ad3021226b 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_object_model_with_ref_props/post.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_object_model_with_ref_props/post.pyi @@ -62,12 +62,24 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): + @typing.overload + def _object_model_with_ref_props_oapg( + self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _object_model_with_ref_props_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -76,12 +88,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _object_model_with_ref_props_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -90,8 +103,8 @@ class BaseApi(api_client.Api): @typing.overload def _object_model_with_ref_props_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -103,8 +116,8 @@ class BaseApi(api_client.Api): def _object_model_with_ref_props_oapg( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -163,8 +176,8 @@ class ObjectModelWithRefProps(BaseApi): @typing.overload def object_model_with_ref_props( self, + content_type: typing_extensions.Literal["application/json"] = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -173,12 +186,26 @@ class ObjectModelWithRefProps(BaseApi): ApiResponseFor200, ]: ... + @typing.overload + def object_model_with_ref_props( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def object_model_with_ref_props( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -187,8 +214,8 @@ class ObjectModelWithRefProps(BaseApi): @typing.overload def object_model_with_ref_props( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -200,8 +227,8 @@ class ObjectModelWithRefProps(BaseApi): def object_model_with_ref_props( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -223,8 +250,21 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -233,12 +273,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -247,8 +288,8 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -260,8 +301,8 @@ class ApiForpost(BaseApi): def post( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_string/post.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_string/post.py index 01894f86a25..6e12c6a77c7 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_string/post.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_string/post.py @@ -65,12 +65,24 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _string_oapg( + self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _string_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -79,12 +91,13 @@ def _string_oapg( ApiResponseFor200, ]: ... + @typing.overload def _string_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -93,8 +106,8 @@ def _string_oapg( @typing.overload def _string_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -106,8 +119,8 @@ def _string_oapg( def _string_oapg( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -166,8 +179,8 @@ class String(BaseApi): @typing.overload def string( self, + content_type: typing_extensions.Literal["application/json"] = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -176,12 +189,26 @@ def string( ApiResponseFor200, ]: ... + @typing.overload + def string( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def string( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -190,8 +217,8 @@ def string( @typing.overload def string( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -203,8 +230,8 @@ def string( def string( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -226,8 +253,21 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -236,12 +276,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -250,8 +291,8 @@ def post( @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -263,8 +304,8 @@ def post( def post( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_string/post.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_string/post.pyi index da9236bb844..0e7d1fb36c1 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_string/post.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_refs_string/post.pyi @@ -60,12 +60,24 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): + @typing.overload + def _string_oapg( + self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _string_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -74,12 +86,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _string_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -88,8 +101,8 @@ class BaseApi(api_client.Api): @typing.overload def _string_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -101,8 +114,8 @@ class BaseApi(api_client.Api): def _string_oapg( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -161,8 +174,8 @@ class String(BaseApi): @typing.overload def string( self, + content_type: typing_extensions.Literal["application/json"] = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -171,12 +184,26 @@ class String(BaseApi): ApiResponseFor200, ]: ... + @typing.overload + def string( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def string( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -185,8 +212,8 @@ class String(BaseApi): @typing.overload def string( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -198,8 +225,8 @@ class String(BaseApi): def string( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -221,8 +248,21 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["application/json"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -231,12 +271,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -245,8 +286,8 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, - content_type: str = 'application/json', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -258,8 +299,8 @@ class ApiForpost(BaseApi): def post( self, - body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, content_type: str = 'application/json', + body: typing.Union[SchemaForRequestBodyApplicationJson, str, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_response_without_schema/get.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_response_without_schema/get.py index 8a7f5385316..f286d0d05aa 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_response_without_schema/get.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_response_without_schema/get.py @@ -56,7 +56,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _response_without_schema_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_response_without_schema/get.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_response_without_schema/get.pyi index 8a41e99f0c5..e562a50173d 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_response_without_schema/get.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_response_without_schema/get.pyi @@ -51,7 +51,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _response_without_schema_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_test_query_paramters/put.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_test_query_paramters/put.py index ef000abd788..df758a42fdb 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_test_query_paramters/put.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_test_query_paramters/put.py @@ -225,7 +225,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _query_parameter_collection_format_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_test_query_paramters/put.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_test_query_paramters/put.pyi index 4930676630f..d55cc258a7d 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_test_query_paramters/put.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_test_query_paramters/put.pyi @@ -220,7 +220,6 @@ _response_for_200 = api_client.OpenApiResponse( class BaseApi(api_client.Api): - @typing.overload def _query_parameter_collection_format_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_upload_download_file/post.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_upload_download_file/post.py index 7e2efb443bb..9686e6ede5c 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_upload_download_file/post.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_upload_download_file/post.py @@ -66,12 +66,24 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _upload_download_file_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationOctetStream,bytes, io.FileIO, io.BufferedReader, ], + content_type: typing_extensions.Literal["application/octet-stream"] = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _upload_download_file_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationOctetStream,bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/octet-stream', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -80,12 +92,13 @@ def _upload_download_file_oapg( ApiResponseFor200, ]: ... + @typing.overload def _upload_download_file_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationOctetStream,bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/octet-stream', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -95,7 +108,7 @@ def _upload_download_file_oapg( def _upload_download_file_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationOctetStream,bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/octet-stream', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -171,7 +184,7 @@ class UploadDownloadFile(BaseApi): def upload_download_file( self, body: typing.Union[SchemaForRequestBodyApplicationOctetStream,bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/octet-stream', + content_type: typing_extensions.Literal["application/octet-stream"] = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -180,12 +193,26 @@ def upload_download_file( ApiResponseFor200, ]: ... + @typing.overload + def upload_download_file( + self, + body: typing.Union[SchemaForRequestBodyApplicationOctetStream,bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def upload_download_file( self, body: typing.Union[SchemaForRequestBodyApplicationOctetStream,bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/octet-stream', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -195,7 +222,7 @@ def upload_download_file( def upload_download_file( self, body: typing.Union[SchemaForRequestBodyApplicationOctetStream,bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/octet-stream', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -231,7 +258,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationOctetStream,bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/octet-stream', + content_type: typing_extensions.Literal["application/octet-stream"] = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -240,12 +267,26 @@ def post( ApiResponseFor200, ]: ... + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationOctetStream,bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationOctetStream,bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/octet-stream', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -255,7 +296,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationOctetStream,bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/octet-stream', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_upload_download_file/post.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_upload_download_file/post.pyi index f4082d8cef7..a6086fbd0d9 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_upload_download_file/post.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_upload_download_file/post.pyi @@ -61,12 +61,24 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): + @typing.overload + def _upload_download_file_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationOctetStream,bytes, io.FileIO, io.BufferedReader, ], + content_type: typing_extensions.Literal["application/octet-stream"] = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _upload_download_file_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationOctetStream,bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/octet-stream', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -75,12 +87,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _upload_download_file_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationOctetStream,bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/octet-stream', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -90,7 +103,7 @@ class BaseApi(api_client.Api): def _upload_download_file_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationOctetStream,bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/octet-stream', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -166,7 +179,7 @@ class UploadDownloadFile(BaseApi): def upload_download_file( self, body: typing.Union[SchemaForRequestBodyApplicationOctetStream,bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/octet-stream', + content_type: typing_extensions.Literal["application/octet-stream"] = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -175,12 +188,26 @@ class UploadDownloadFile(BaseApi): ApiResponseFor200, ]: ... + @typing.overload + def upload_download_file( + self, + body: typing.Union[SchemaForRequestBodyApplicationOctetStream,bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def upload_download_file( self, body: typing.Union[SchemaForRequestBodyApplicationOctetStream,bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/octet-stream', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -190,7 +217,7 @@ class UploadDownloadFile(BaseApi): def upload_download_file( self, body: typing.Union[SchemaForRequestBodyApplicationOctetStream,bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/octet-stream', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -226,7 +253,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationOctetStream,bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/octet-stream', + content_type: typing_extensions.Literal["application/octet-stream"] = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -235,12 +262,26 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationOctetStream,bytes, io.FileIO, io.BufferedReader, ], + content_type: str = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationOctetStream,bytes, io.FileIO, io.BufferedReader, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/octet-stream', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -250,7 +291,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationOctetStream,bytes, io.FileIO, io.BufferedReader, ], - content_type: str = 'application/octet-stream', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_upload_file/post.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_upload_file/post.py index f788bceedc6..867654e95f3 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_upload_file/post.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_upload_file/post.py @@ -131,12 +131,24 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _upload_file_oapg( + self, + content_type: typing_extensions.Literal["multipart/form-data"] = ..., + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _upload_file_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -145,12 +157,13 @@ def _upload_file_oapg( ApiResponseFor200, ]: ... + @typing.overload def _upload_file_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -159,8 +172,8 @@ def _upload_file_oapg( @typing.overload def _upload_file_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -172,8 +185,8 @@ def _upload_file_oapg( def _upload_file_oapg( self, - body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, content_type: str = 'multipart/form-data', + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -233,8 +246,8 @@ class UploadFile(BaseApi): @typing.overload def upload_file( self, + content_type: typing_extensions.Literal["multipart/form-data"] = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -243,12 +256,26 @@ def upload_file( ApiResponseFor200, ]: ... + @typing.overload + def upload_file( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def upload_file( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -257,8 +284,8 @@ def upload_file( @typing.overload def upload_file( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -270,8 +297,8 @@ def upload_file( def upload_file( self, - body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, content_type: str = 'multipart/form-data', + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -293,8 +320,21 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["multipart/form-data"] = ..., + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -303,12 +343,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -317,8 +358,8 @@ def post( @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -330,8 +371,8 @@ def post( def post( self, - body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, content_type: str = 'multipart/form-data', + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_upload_file/post.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_upload_file/post.pyi index 15d68e25ee2..c77969fbf70 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_upload_file/post.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_upload_file/post.pyi @@ -126,12 +126,24 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): + @typing.overload + def _upload_file_oapg( + self, + content_type: typing_extensions.Literal["multipart/form-data"] = ..., + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _upload_file_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -140,12 +152,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _upload_file_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -154,8 +167,8 @@ class BaseApi(api_client.Api): @typing.overload def _upload_file_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -167,8 +180,8 @@ class BaseApi(api_client.Api): def _upload_file_oapg( self, - body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, content_type: str = 'multipart/form-data', + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -228,8 +241,8 @@ class UploadFile(BaseApi): @typing.overload def upload_file( self, + content_type: typing_extensions.Literal["multipart/form-data"] = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -238,12 +251,26 @@ class UploadFile(BaseApi): ApiResponseFor200, ]: ... + @typing.overload + def upload_file( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def upload_file( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -252,8 +279,8 @@ class UploadFile(BaseApi): @typing.overload def upload_file( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -265,8 +292,8 @@ class UploadFile(BaseApi): def upload_file( self, - body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, content_type: str = 'multipart/form-data', + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -288,8 +315,21 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["multipart/form-data"] = ..., + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -298,12 +338,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -312,8 +353,8 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -325,8 +366,8 @@ class ApiForpost(BaseApi): def post( self, - body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, content_type: str = 'multipart/form-data', + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_upload_files/post.py b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_upload_files/post.py index 103249e9fee..4284b0119ce 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_upload_files/post.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_upload_files/post.py @@ -138,12 +138,24 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _upload_files_oapg( + self, + content_type: typing_extensions.Literal["multipart/form-data"] = ..., + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _upload_files_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -152,12 +164,13 @@ def _upload_files_oapg( ApiResponseFor200, ]: ... + @typing.overload def _upload_files_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -166,8 +179,8 @@ def _upload_files_oapg( @typing.overload def _upload_files_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -179,8 +192,8 @@ def _upload_files_oapg( def _upload_files_oapg( self, - body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, content_type: str = 'multipart/form-data', + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -240,8 +253,8 @@ class UploadFiles(BaseApi): @typing.overload def upload_files( self, + content_type: typing_extensions.Literal["multipart/form-data"] = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -250,12 +263,26 @@ def upload_files( ApiResponseFor200, ]: ... + @typing.overload + def upload_files( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def upload_files( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -264,8 +291,8 @@ def upload_files( @typing.overload def upload_files( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -277,8 +304,8 @@ def upload_files( def upload_files( self, - body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, content_type: str = 'multipart/form-data', + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -300,8 +327,21 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["multipart/form-data"] = ..., + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -310,12 +350,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -324,8 +365,8 @@ def post( @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -337,8 +378,8 @@ def post( def post( self, - body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, content_type: str = 'multipart/form-data', + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_upload_files/post.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_upload_files/post.pyi index 07b03c5d345..2b1e1f508f3 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/fake_upload_files/post.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/fake_upload_files/post.pyi @@ -133,12 +133,24 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): + @typing.overload + def _upload_files_oapg( + self, + content_type: typing_extensions.Literal["multipart/form-data"] = ..., + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _upload_files_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -147,12 +159,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _upload_files_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -161,8 +174,8 @@ class BaseApi(api_client.Api): @typing.overload def _upload_files_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -174,8 +187,8 @@ class BaseApi(api_client.Api): def _upload_files_oapg( self, - body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, content_type: str = 'multipart/form-data', + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -235,8 +248,8 @@ class UploadFiles(BaseApi): @typing.overload def upload_files( self, + content_type: typing_extensions.Literal["multipart/form-data"] = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -245,12 +258,26 @@ class UploadFiles(BaseApi): ApiResponseFor200, ]: ... + @typing.overload + def upload_files( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def upload_files( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -259,8 +286,8 @@ class UploadFiles(BaseApi): @typing.overload def upload_files( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -272,8 +299,8 @@ class UploadFiles(BaseApi): def upload_files( self, - body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, content_type: str = 'multipart/form-data', + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -295,8 +322,21 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["multipart/form-data"] = ..., + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -305,12 +345,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -319,8 +360,8 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -332,8 +373,8 @@ class ApiForpost(BaseApi): def post( self, - body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, content_type: str = 'multipart/form-data', + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/foo/get.py b/samples/openapi3/client/petstore/python/petstore_api/paths/foo/get.py index 578fdc34dc0..bde734e7581 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/foo/get.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/foo/get.py @@ -109,7 +109,6 @@ class ApiResponseForDefault(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _foo_get_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/foo/get.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/foo/get.pyi index 39f6edca411..4c5f088f788 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/foo/get.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/foo/get.pyi @@ -104,7 +104,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _foo_get_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/pet/post.py b/samples/openapi3/client/petstore/python/petstore_api/paths/pet/post.py index b829c0872ce..eab76eab725 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/pet/post.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/pet/post.py @@ -88,12 +88,37 @@ class ApiResponseFor405(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _add_pet_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + host_index: typing.Optional[int] = None, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def _add_pet_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationXml,], + content_type: typing_extensions.Literal["application/xml"], + host_index: typing.Optional[int] = None, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _add_pet_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -102,12 +127,13 @@ def _add_pet_oapg( ApiResponseFor200, ]: ... + @typing.overload def _add_pet_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -117,7 +143,7 @@ def _add_pet_oapg( def _add_pet_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -190,11 +216,37 @@ class instances class AddPet(BaseApi): # this class is used by api classes that refer to endpoints with operationId fn names + @typing.overload + def add_pet( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + host_index: typing.Optional[int] = None, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def add_pet( + self, + body: typing.Union[SchemaForRequestBodyApplicationXml,], + content_type: typing_extensions.Literal["application/xml"], + host_index: typing.Optional[int] = None, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + @typing.overload def add_pet( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -203,12 +255,13 @@ def add_pet( ApiResponseFor200, ]: ... + @typing.overload def add_pet( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -218,7 +271,7 @@ def add_pet( def add_pet( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -250,11 +303,37 @@ def add_pet( class ApiForpost(BaseApi): # this class is used by api classes that refer to endpoints by path and http method names + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + host_index: typing.Optional[int] = None, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationXml,], + content_type: typing_extensions.Literal["application/xml"], + host_index: typing.Optional[int] = None, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -263,12 +342,13 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -278,7 +358,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/pet/post.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/pet/post.pyi index 7b6483c76b9..844a49f7094 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/pet/post.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/pet/post.pyi @@ -68,12 +68,37 @@ _response_for_405 = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _add_pet_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + host_index: typing.Optional[int] = None, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def _add_pet_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationXml,], + content_type: typing_extensions.Literal["application/xml"], + host_index: typing.Optional[int] = None, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _add_pet_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -82,12 +107,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _add_pet_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -97,7 +123,7 @@ class BaseApi(api_client.Api): def _add_pet_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -170,11 +196,37 @@ class BaseApi(api_client.Api): class AddPet(BaseApi): # this class is used by api classes that refer to endpoints with operationId fn names + @typing.overload + def add_pet( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + host_index: typing.Optional[int] = None, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def add_pet( + self, + body: typing.Union[SchemaForRequestBodyApplicationXml,], + content_type: typing_extensions.Literal["application/xml"], + host_index: typing.Optional[int] = None, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + @typing.overload def add_pet( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -183,12 +235,13 @@ class AddPet(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def add_pet( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -198,7 +251,7 @@ class AddPet(BaseApi): def add_pet( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -230,11 +283,37 @@ class AddPet(BaseApi): class ApiForpost(BaseApi): # this class is used by api classes that refer to endpoints by path and http method names + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + host_index: typing.Optional[int] = None, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationXml,], + content_type: typing_extensions.Literal["application/xml"], + host_index: typing.Optional[int] = None, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -243,12 +322,13 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -258,7 +338,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/pet/put.py b/samples/openapi3/client/petstore/python/petstore_api/paths/pet/put.py index cf1b5e55446..455320b56c9 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/pet/put.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/pet/put.py @@ -101,23 +101,43 @@ class ApiResponseFor405(api_client.ApiResponse): class BaseApi(api_client.Api): - + @typing.overload + def _update_pet_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + host_index: typing.Optional[int] = None, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload + def _update_pet_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationXml,], + content_type: typing_extensions.Literal["application/xml"], + host_index: typing.Optional[int] = None, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> api_client.ApiResponseWithoutDeserialization: ... @typing.overload def _update_pet_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload def _update_pet_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -127,7 +147,7 @@ def _update_pet_oapg( def _update_pet_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -199,22 +219,43 @@ class instances class UpdatePet(BaseApi): # this class is used by api classes that refer to endpoints with operationId fn names + @typing.overload + def update_pet( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + host_index: typing.Optional[int] = None, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload + def update_pet( + self, + body: typing.Union[SchemaForRequestBodyApplicationXml,], + content_type: typing_extensions.Literal["application/xml"], + host_index: typing.Optional[int] = None, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> api_client.ApiResponseWithoutDeserialization: ... @typing.overload def update_pet( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload def update_pet( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -224,7 +265,7 @@ def update_pet( def update_pet( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -255,22 +296,43 @@ def update_pet( class ApiForput(BaseApi): # this class is used by api classes that refer to endpoints by path and http method names + @typing.overload + def put( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + host_index: typing.Optional[int] = None, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload + def put( + self, + body: typing.Union[SchemaForRequestBodyApplicationXml,], + content_type: typing_extensions.Literal["application/xml"], + host_index: typing.Optional[int] = None, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> api_client.ApiResponseWithoutDeserialization: ... @typing.overload def put( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload def put( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -280,7 +342,7 @@ def put( def put( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/pet/put.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/pet/put.pyi index 8dc827f4536..925cf095100 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/pet/put.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/pet/put.pyi @@ -80,23 +80,43 @@ _response_for_405 = api_client.OpenApiResponse( class BaseApi(api_client.Api): - + @typing.overload + def _update_pet_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + host_index: typing.Optional[int] = None, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload + def _update_pet_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationXml,], + content_type: typing_extensions.Literal["application/xml"], + host_index: typing.Optional[int] = None, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> api_client.ApiResponseWithoutDeserialization: ... @typing.overload def _update_pet_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload def _update_pet_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -106,7 +126,7 @@ class BaseApi(api_client.Api): def _update_pet_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -178,22 +198,43 @@ class BaseApi(api_client.Api): class UpdatePet(BaseApi): # this class is used by api classes that refer to endpoints with operationId fn names + @typing.overload + def update_pet( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + host_index: typing.Optional[int] = None, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload + def update_pet( + self, + body: typing.Union[SchemaForRequestBodyApplicationXml,], + content_type: typing_extensions.Literal["application/xml"], + host_index: typing.Optional[int] = None, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> api_client.ApiResponseWithoutDeserialization: ... @typing.overload def update_pet( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload def update_pet( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -203,7 +244,7 @@ class UpdatePet(BaseApi): def update_pet( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -234,22 +275,43 @@ class UpdatePet(BaseApi): class ApiForput(BaseApi): # this class is used by api classes that refer to endpoints by path and http method names + @typing.overload + def put( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + host_index: typing.Optional[int] = None, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload + def put( + self, + body: typing.Union[SchemaForRequestBodyApplicationXml,], + content_type: typing_extensions.Literal["application/xml"], + host_index: typing.Optional[int] = None, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> api_client.ApiResponseWithoutDeserialization: ... @typing.overload def put( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload def put( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -259,7 +321,7 @@ class ApiForput(BaseApi): def put( self, body: typing.Union[SchemaForRequestBodyApplicationJson,SchemaForRequestBodyApplicationXml,], - content_type: str = 'application/json', + content_type: str = ..., host_index: typing.Optional[int] = None, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/pet_find_by_status/get.py b/samples/openapi3/client/petstore/python/petstore_api/paths/pet_find_by_status/get.py index cabe5eb65e7..ef1040f29b3 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/pet_find_by_status/get.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/pet_find_by_status/get.py @@ -202,7 +202,6 @@ class ApiResponseFor400(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _find_pets_by_status_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/pet_find_by_status/get.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/pet_find_by_status/get.pyi index 3a8d54f1561..6c99d25befe 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/pet_find_by_status/get.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/pet_find_by_status/get.pyi @@ -184,7 +184,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _find_pets_by_status_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/pet_find_by_tags/get.py b/samples/openapi3/client/petstore/python/petstore_api/paths/pet_find_by_tags/get.py index e9e6dfac934..71986296717 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/pet_find_by_tags/get.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/pet_find_by_tags/get.py @@ -177,7 +177,6 @@ class ApiResponseFor400(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _find_pets_by_tags_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/pet_find_by_tags/get.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/pet_find_by_tags/get.pyi index f886213afdb..0a6c7544c3c 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/pet_find_by_tags/get.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/pet_find_by_tags/get.pyi @@ -167,7 +167,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _find_pets_by_tags_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id/delete.py b/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id/delete.py index f291324aaf3..a3a4c0b05f6 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id/delete.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id/delete.py @@ -99,7 +99,6 @@ class ApiResponseFor400(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _delete_pet_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id/delete.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id/delete.pyi index 33ff8733ce8..fc52876c19a 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id/delete.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id/delete.pyi @@ -91,7 +91,6 @@ _response_for_400 = api_client.OpenApiResponse( class BaseApi(api_client.Api): - @typing.overload def _delete_pet_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id/get.py b/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id/get.py index 4515a274324..df9855c97f1 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id/get.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id/get.py @@ -117,7 +117,6 @@ class ApiResponseFor404(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _get_pet_by_id_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id/get.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id/get.pyi index 524b12c74b0..fcb2def9898 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id/get.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id/get.pyi @@ -107,7 +107,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _get_pet_by_id_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id/post.py b/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id/post.py index e476437873f..c7f2a3080bc 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id/post.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id/post.py @@ -143,24 +143,34 @@ class ApiResponseFor405(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _update_pet_with_form_oapg( self, + content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + path_params: RequestPathParams = frozendict.frozendict(), + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload + def _update_pet_with_form_oapg( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload def _update_pet_with_form_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -168,9 +178,9 @@ def _update_pet_with_form_oapg( @typing.overload def _update_pet_with_form_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -180,9 +190,9 @@ def _update_pet_with_form_oapg( def _update_pet_with_form_oapg( self, + content_type: str = 'application/x-www-form-urlencoded', body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -253,20 +263,31 @@ class UpdatePetWithForm(BaseApi): @typing.overload def update_pet_with_form( self, + content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + path_params: RequestPathParams = frozendict.frozendict(), + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload + def update_pet_with_form( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload def update_pet_with_form( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -274,9 +295,9 @@ def update_pet_with_form( @typing.overload def update_pet_with_form( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -286,9 +307,9 @@ def update_pet_with_form( def update_pet_with_form( self, + content_type: str = 'application/x-www-form-urlencoded', body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -309,20 +330,31 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload + def post( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + path_params: RequestPathParams = frozendict.frozendict(), + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -330,9 +362,9 @@ def post( @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -342,9 +374,9 @@ def post( def post( self, + content_type: str = 'application/x-www-form-urlencoded', body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id/post.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id/post.pyi index 6a919fb5eed..cd02580c59c 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id/post.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id/post.pyi @@ -135,24 +135,34 @@ _response_for_405 = api_client.OpenApiResponse( class BaseApi(api_client.Api): - @typing.overload def _update_pet_with_form_oapg( self, + content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + path_params: RequestPathParams = frozendict.frozendict(), + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload + def _update_pet_with_form_oapg( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload def _update_pet_with_form_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -160,9 +170,9 @@ class BaseApi(api_client.Api): @typing.overload def _update_pet_with_form_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -172,9 +182,9 @@ class BaseApi(api_client.Api): def _update_pet_with_form_oapg( self, + content_type: str = 'application/x-www-form-urlencoded', body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -245,20 +255,31 @@ class UpdatePetWithForm(BaseApi): @typing.overload def update_pet_with_form( self, + content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = ..., + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + path_params: RequestPathParams = frozendict.frozendict(), + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload + def update_pet_with_form( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload def update_pet_with_form( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -266,9 +287,9 @@ class UpdatePetWithForm(BaseApi): @typing.overload def update_pet_with_form( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -278,9 +299,9 @@ class UpdatePetWithForm(BaseApi): def update_pet_with_form( self, + content_type: str = 'application/x-www-form-urlencoded', body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -301,20 +322,31 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload + def post( + self, + content_type: str = ..., + body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + path_params: RequestPathParams = frozendict.frozendict(), + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -322,9 +354,9 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -334,9 +366,9 @@ class ApiForpost(BaseApi): def post( self, + content_type: str = 'application/x-www-form-urlencoded', body: typing.Union[SchemaForRequestBodyApplicationXWwwFormUrlencoded, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/x-www-form-urlencoded', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id_upload_image/post.py b/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id_upload_image/post.py index f663410e354..38675f3ee75 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id_upload_image/post.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id_upload_image/post.py @@ -155,13 +155,26 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _upload_image_oapg( + self, + content_type: typing_extensions.Literal["multipart/form-data"] = ..., + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _upload_image_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -170,13 +183,14 @@ def _upload_image_oapg( ApiResponseFor200, ]: ... + @typing.overload def _upload_image_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -185,9 +199,9 @@ def _upload_image_oapg( @typing.overload def _upload_image_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -199,9 +213,9 @@ def _upload_image_oapg( def _upload_image_oapg( self, + content_type: str = 'multipart/form-data', body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -276,9 +290,23 @@ class UploadImage(BaseApi): @typing.overload def upload_image( self, + content_type: typing_extensions.Literal["multipart/form-data"] = ..., + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def upload_image( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -287,13 +315,14 @@ def upload_image( ApiResponseFor200, ]: ... + @typing.overload def upload_image( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -302,9 +331,9 @@ def upload_image( @typing.overload def upload_image( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -316,9 +345,9 @@ def upload_image( def upload_image( self, + content_type: str = 'multipart/form-data', body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -341,9 +370,23 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["multipart/form-data"] = ..., + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -352,13 +395,14 @@ def post( ApiResponseFor200, ]: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -367,9 +411,9 @@ def post( @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -381,9 +425,9 @@ def post( def post( self, + content_type: str = 'multipart/form-data', body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id_upload_image/post.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id_upload_image/post.pyi index d5436eabf0c..f445437853d 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id_upload_image/post.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/pet_pet_id_upload_image/post.pyi @@ -147,13 +147,26 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): + @typing.overload + def _upload_image_oapg( + self, + content_type: typing_extensions.Literal["multipart/form-data"] = ..., + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _upload_image_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -162,13 +175,14 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _upload_image_oapg( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -177,9 +191,9 @@ class BaseApi(api_client.Api): @typing.overload def _upload_image_oapg( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -191,9 +205,9 @@ class BaseApi(api_client.Api): def _upload_image_oapg( self, + content_type: str = 'multipart/form-data', body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -268,9 +282,23 @@ class UploadImage(BaseApi): @typing.overload def upload_image( self, + content_type: typing_extensions.Literal["multipart/form-data"] = ..., + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def upload_image( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -279,13 +307,14 @@ class UploadImage(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def upload_image( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -294,9 +323,9 @@ class UploadImage(BaseApi): @typing.overload def upload_image( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -308,9 +337,9 @@ class UploadImage(BaseApi): def upload_image( self, + content_type: str = 'multipart/form-data', body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -333,9 +362,23 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: typing_extensions.Literal["multipart/form-data"] = ..., + body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, + path_params: RequestPathParams = frozendict.frozendict(), + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload + def post( + self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -344,13 +387,14 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload def post( self, skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -359,9 +403,9 @@ class ApiForpost(BaseApi): @typing.overload def post( self, + content_type: str = ..., body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -373,9 +417,9 @@ class ApiForpost(BaseApi): def post( self, + content_type: str = 'multipart/form-data', body: typing.Union[SchemaForRequestBodyMultipartFormData, dict, frozendict.frozendict, schemas.Unset] = schemas.unset, path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'multipart/form-data', accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/store_inventory/get.py b/samples/openapi3/client/petstore/python/petstore_api/paths/store_inventory/get.py index 744c20807a4..4f9f0eb1f7a 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/store_inventory/get.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/store_inventory/get.py @@ -86,7 +86,6 @@ class ApiResponseFor200(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _get_inventory_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/store_inventory/get.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/store_inventory/get.pyi index 251a2cf7997..30d769a9d31 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/store_inventory/get.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/store_inventory/get.pyi @@ -78,7 +78,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _get_inventory_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/store_order/post.py b/samples/openapi3/client/petstore/python/petstore_api/paths/store_order/post.py index aa4d453d5ca..a92da10efbd 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/store_order/post.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/store_order/post.py @@ -86,12 +86,24 @@ class ApiResponseFor400(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _place_order_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _place_order_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -100,12 +112,13 @@ def _place_order_oapg( ApiResponseFor200, ]: ... + @typing.overload def _place_order_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -115,7 +128,7 @@ def _place_order_oapg( def _place_order_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -191,7 +204,7 @@ class PlaceOrder(BaseApi): def place_order( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -200,12 +213,26 @@ def place_order( ApiResponseFor200, ]: ... + @typing.overload + def place_order( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def place_order( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -215,7 +242,7 @@ def place_order( def place_order( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -251,7 +278,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -260,12 +287,26 @@ def post( ApiResponseFor200, ]: ... + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -275,7 +316,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/store_order/post.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/store_order/post.pyi index 834ca77e843..20ad57939b0 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/store_order/post.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/store_order/post.pyi @@ -80,12 +80,24 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): + @typing.overload + def _place_order_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... @typing.overload def _place_order_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -94,12 +106,13 @@ class BaseApi(api_client.Api): ApiResponseFor200, ]: ... + @typing.overload def _place_order_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -109,7 +122,7 @@ class BaseApi(api_client.Api): def _place_order_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -185,7 +198,7 @@ class PlaceOrder(BaseApi): def place_order( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -194,12 +207,26 @@ class PlaceOrder(BaseApi): ApiResponseFor200, ]: ... + @typing.overload + def place_order( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def place_order( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -209,7 +236,7 @@ class PlaceOrder(BaseApi): def place_order( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -245,7 +272,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -254,12 +281,26 @@ class ApiForpost(BaseApi): ApiResponseFor200, ]: ... + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., + accept_content_types: typing.Tuple[str] = _all_accept_content_types, + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseFor200, + ]: ... + + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, @@ -269,7 +310,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., accept_content_types: typing.Tuple[str] = _all_accept_content_types, stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/store_order_order_id/delete.py b/samples/openapi3/client/petstore/python/petstore_api/paths/store_order_order_id/delete.py index 284fca11571..150c926cca7 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/store_order_order_id/delete.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/store_order_order_id/delete.py @@ -83,7 +83,6 @@ class ApiResponseFor404(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _delete_order_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/store_order_order_id/delete.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/store_order_order_id/delete.pyi index 95061f5b4c7..f5798947e70 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/store_order_order_id/delete.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/store_order_order_id/delete.pyi @@ -77,7 +77,6 @@ _response_for_404 = api_client.OpenApiResponse( class BaseApi(api_client.Api): - @typing.overload def _delete_order_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/store_order_order_id/get.py b/samples/openapi3/client/petstore/python/petstore_api/paths/store_order_order_id/get.py index dac3de535c9..324c915ee58 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/store_order_order_id/get.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/store_order_order_id/get.py @@ -124,7 +124,6 @@ class ApiResponseFor404(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _get_order_by_id_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/store_order_order_id/get.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/store_order_order_id/get.pyi index 47bfb02e088..448b3f0e686 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/store_order_order_id/get.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/store_order_order_id/get.pyi @@ -112,7 +112,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _get_order_by_id_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/user/post.py b/samples/openapi3/client/petstore/python/petstore_api/paths/user/post.py index 7b149f3c2d9..08cfcc902cd 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/user/post.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/user/post.py @@ -58,12 +58,23 @@ class ApiResponseForDefault(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _create_user_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseForDefault, + ]: ... @typing.overload def _create_user_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -71,12 +82,13 @@ def _create_user_oapg( ApiResponseForDefault, ]: ... + @typing.overload def _create_user_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -85,7 +97,7 @@ def _create_user_oapg( def _create_user_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -160,7 +172,19 @@ class CreateUser(BaseApi): def create_user( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseForDefault, + ]: ... + + @typing.overload + def create_user( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -168,12 +192,13 @@ def create_user( ApiResponseForDefault, ]: ... + @typing.overload def create_user( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -182,7 +207,7 @@ def create_user( def create_user( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -215,7 +240,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseForDefault, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -223,12 +260,13 @@ def post( ApiResponseForDefault, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -237,7 +275,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/user/post.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/user/post.pyi index 16e628184f5..df85a246c2c 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/user/post.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/user/post.pyi @@ -53,12 +53,23 @@ _response_for_default = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _create_user_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseForDefault, + ]: ... @typing.overload def _create_user_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -66,12 +77,13 @@ class BaseApi(api_client.Api): ApiResponseForDefault, ]: ... + @typing.overload def _create_user_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -80,7 +92,7 @@ class BaseApi(api_client.Api): def _create_user_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -155,7 +167,19 @@ class CreateUser(BaseApi): def create_user( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseForDefault, + ]: ... + + @typing.overload + def create_user( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -163,12 +187,13 @@ class CreateUser(BaseApi): ApiResponseForDefault, ]: ... + @typing.overload def create_user( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -177,7 +202,7 @@ class CreateUser(BaseApi): def create_user( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -210,7 +235,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseForDefault, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -218,12 +255,13 @@ class ApiForpost(BaseApi): ApiResponseForDefault, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -232,7 +270,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/user_create_with_array/post.py b/samples/openapi3/client/petstore/python/petstore_api/paths/user_create_with_array/post.py index 19438e871a3..d596822b475 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/user_create_with_array/post.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/user_create_with_array/post.py @@ -83,12 +83,23 @@ class ApiResponseForDefault(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _create_users_with_array_input_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseForDefault, + ]: ... @typing.overload def _create_users_with_array_input_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -96,12 +107,13 @@ def _create_users_with_array_input_oapg( ApiResponseForDefault, ]: ... + @typing.overload def _create_users_with_array_input_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -110,7 +122,7 @@ def _create_users_with_array_input_oapg( def _create_users_with_array_input_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -185,7 +197,19 @@ class CreateUsersWithArrayInput(BaseApi): def create_users_with_array_input( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseForDefault, + ]: ... + + @typing.overload + def create_users_with_array_input( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -193,12 +217,13 @@ def create_users_with_array_input( ApiResponseForDefault, ]: ... + @typing.overload def create_users_with_array_input( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -207,7 +232,7 @@ def create_users_with_array_input( def create_users_with_array_input( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -240,7 +265,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseForDefault, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -248,12 +285,13 @@ def post( ApiResponseForDefault, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -262,7 +300,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/user_create_with_array/post.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/user_create_with_array/post.pyi index 426bfcd89c4..6c83bb4f8b0 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/user_create_with_array/post.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/user_create_with_array/post.pyi @@ -78,12 +78,23 @@ _response_for_default = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _create_users_with_array_input_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseForDefault, + ]: ... @typing.overload def _create_users_with_array_input_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -91,12 +102,13 @@ class BaseApi(api_client.Api): ApiResponseForDefault, ]: ... + @typing.overload def _create_users_with_array_input_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -105,7 +117,7 @@ class BaseApi(api_client.Api): def _create_users_with_array_input_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -180,7 +192,19 @@ class CreateUsersWithArrayInput(BaseApi): def create_users_with_array_input( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseForDefault, + ]: ... + + @typing.overload + def create_users_with_array_input( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -188,12 +212,13 @@ class CreateUsersWithArrayInput(BaseApi): ApiResponseForDefault, ]: ... + @typing.overload def create_users_with_array_input( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -202,7 +227,7 @@ class CreateUsersWithArrayInput(BaseApi): def create_users_with_array_input( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -235,7 +260,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseForDefault, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -243,12 +280,13 @@ class ApiForpost(BaseApi): ApiResponseForDefault, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -257,7 +295,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/user_create_with_list/post.py b/samples/openapi3/client/petstore/python/petstore_api/paths/user_create_with_list/post.py index d8dbfc2d2d8..fd0fe46f1b4 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/user_create_with_list/post.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/user_create_with_list/post.py @@ -83,12 +83,23 @@ class ApiResponseForDefault(api_client.ApiResponse): class BaseApi(api_client.Api): + @typing.overload + def _create_users_with_list_input_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseForDefault, + ]: ... @typing.overload def _create_users_with_list_input_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -96,12 +107,13 @@ def _create_users_with_list_input_oapg( ApiResponseForDefault, ]: ... + @typing.overload def _create_users_with_list_input_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -110,7 +122,7 @@ def _create_users_with_list_input_oapg( def _create_users_with_list_input_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -185,7 +197,19 @@ class CreateUsersWithListInput(BaseApi): def create_users_with_list_input( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseForDefault, + ]: ... + + @typing.overload + def create_users_with_list_input( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -193,12 +217,13 @@ def create_users_with_list_input( ApiResponseForDefault, ]: ... + @typing.overload def create_users_with_list_input( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -207,7 +232,7 @@ def create_users_with_list_input( def create_users_with_list_input( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -240,7 +265,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseForDefault, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -248,12 +285,13 @@ def post( ApiResponseForDefault, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -262,7 +300,7 @@ def post( def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/user_create_with_list/post.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/user_create_with_list/post.pyi index 899fd50057c..ef9c94f6225 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/user_create_with_list/post.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/user_create_with_list/post.pyi @@ -78,12 +78,23 @@ _response_for_default = api_client.OpenApiResponse( class BaseApi(api_client.Api): + @typing.overload + def _create_users_with_list_input_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseForDefault, + ]: ... @typing.overload def _create_users_with_list_input_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -91,12 +102,13 @@ class BaseApi(api_client.Api): ApiResponseForDefault, ]: ... + @typing.overload def _create_users_with_list_input_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -105,7 +117,7 @@ class BaseApi(api_client.Api): def _create_users_with_list_input_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -180,7 +192,19 @@ class CreateUsersWithListInput(BaseApi): def create_users_with_list_input( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseForDefault, + ]: ... + + @typing.overload + def create_users_with_list_input( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -188,12 +212,13 @@ class CreateUsersWithListInput(BaseApi): ApiResponseForDefault, ]: ... + @typing.overload def create_users_with_list_input( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -202,7 +227,7 @@ class CreateUsersWithListInput(BaseApi): def create_users_with_list_input( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -235,7 +260,19 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], - content_type: str = 'application/json', + content_type: typing_extensions.Literal["application/json"] = ..., + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> typing.Union[ + ApiResponseForDefault, + ]: ... + + @typing.overload + def post( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., @@ -243,12 +280,13 @@ class ApiForpost(BaseApi): ApiResponseForDefault, ]: ... + @typing.overload def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], skip_deserialization: typing_extensions.Literal[True], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -257,7 +295,7 @@ class ApiForpost(BaseApi): def post( self, body: typing.Union[SchemaForRequestBodyApplicationJson,list, tuple, ], - content_type: str = 'application/json', + content_type: str = ..., stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/user_login/get.py b/samples/openapi3/client/petstore/python/petstore_api/paths/user_login/get.py index 32576079f29..5d1f05bc4cd 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/user_login/get.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/user_login/get.py @@ -132,7 +132,6 @@ class ApiResponseFor400(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _login_user_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/user_login/get.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/user_login/get.pyi index 48dd3699983..2ab0d10e8ee 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/user_login/get.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/user_login/get.pyi @@ -116,7 +116,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _login_user_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/user_logout/get.py b/samples/openapi3/client/petstore/python/petstore_api/paths/user_logout/get.py index 12a0fdeb207..085a4ba6750 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/user_logout/get.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/user_logout/get.py @@ -44,7 +44,6 @@ class ApiResponseForDefault(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _logout_user_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/user_logout/get.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/user_logout/get.pyi index 8dd9db1530d..52192b64068 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/user_logout/get.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/user_logout/get.pyi @@ -39,7 +39,6 @@ _response_for_default = api_client.OpenApiResponse( class BaseApi(api_client.Api): - @typing.overload def _logout_user_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/user_username/delete.py b/samples/openapi3/client/petstore/python/petstore_api/paths/user_username/delete.py index a06c6c138a3..a72e73b7777 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/user_username/delete.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/user_username/delete.py @@ -83,7 +83,6 @@ class ApiResponseFor404(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _delete_user_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/user_username/delete.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/user_username/delete.pyi index 6a535cc6d2f..1f0953b10da 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/user_username/delete.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/user_username/delete.pyi @@ -77,7 +77,6 @@ _response_for_404 = api_client.OpenApiResponse( class BaseApi(api_client.Api): - @typing.overload def _delete_user_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/user_username/get.py b/samples/openapi3/client/petstore/python/petstore_api/paths/user_username/get.py index 4c3c8005fbf..1a7ee25830b 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/user_username/get.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/user_username/get.py @@ -114,7 +114,6 @@ class ApiResponseFor404(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _get_user_by_name_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/user_username/get.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/user_username/get.pyi index 4fbca07f4d7..3cf5890e196 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/user_username/get.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/user_username/get.pyi @@ -107,7 +107,6 @@ _all_accept_content_types = ( class BaseApi(api_client.Api): - @typing.overload def _get_user_by_name_oapg( self, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/user_username/put.py b/samples/openapi3/client/petstore/python/petstore_api/paths/user_username/put.py index b9bd73f8479..a36b06bdef1 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/user_username/put.py +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/user_username/put.py @@ -97,24 +97,34 @@ class ApiResponseFor404(api_client.ApiResponse): class BaseApi(api_client.Api): - @typing.overload def _update_user_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + path_params: RequestPathParams = frozendict.frozendict(), + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload + def _update_user_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload def _update_user_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -123,8 +133,8 @@ def _update_user_oapg( def _update_user_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -135,8 +145,8 @@ def _update_user_oapg( def _update_user_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - path_params: RequestPathParams = frozendict.frozendict(), content_type: str = 'application/json', + path_params: RequestPathParams = frozendict.frozendict(), stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -209,19 +219,30 @@ class UpdateUser(BaseApi): def update_user( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + path_params: RequestPathParams = frozendict.frozendict(), + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload + def update_user( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload def update_user( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -230,8 +251,8 @@ def update_user( def update_user( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -242,8 +263,8 @@ def update_user( def update_user( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - path_params: RequestPathParams = frozendict.frozendict(), content_type: str = 'application/json', + path_params: RequestPathParams = frozendict.frozendict(), stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -265,19 +286,30 @@ class ApiForput(BaseApi): def put( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload + def put( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., + path_params: RequestPathParams = frozendict.frozendict(), + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload def put( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -286,8 +318,8 @@ def put( def put( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -298,8 +330,8 @@ def put( def put( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - path_params: RequestPathParams = frozendict.frozendict(), content_type: str = 'application/json', + path_params: RequestPathParams = frozendict.frozendict(), stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, diff --git a/samples/openapi3/client/petstore/python/petstore_api/paths/user_username/put.pyi b/samples/openapi3/client/petstore/python/petstore_api/paths/user_username/put.pyi index db9f19cac6c..a541a6dead9 100644 --- a/samples/openapi3/client/petstore/python/petstore_api/paths/user_username/put.pyi +++ b/samples/openapi3/client/petstore/python/petstore_api/paths/user_username/put.pyi @@ -91,24 +91,34 @@ _response_for_404 = api_client.OpenApiResponse( class BaseApi(api_client.Api): - @typing.overload def _update_user_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + path_params: RequestPathParams = frozendict.frozendict(), + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload + def _update_user_oapg( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload def _update_user_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -117,8 +127,8 @@ class BaseApi(api_client.Api): def _update_user_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -129,8 +139,8 @@ class BaseApi(api_client.Api): def _update_user_oapg( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - path_params: RequestPathParams = frozendict.frozendict(), content_type: str = 'application/json', + path_params: RequestPathParams = frozendict.frozendict(), stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -203,19 +213,30 @@ class UpdateUser(BaseApi): def update_user( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., + path_params: RequestPathParams = frozendict.frozendict(), + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload + def update_user( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload def update_user( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -224,8 +245,8 @@ class UpdateUser(BaseApi): def update_user( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -236,8 +257,8 @@ class UpdateUser(BaseApi): def update_user( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - path_params: RequestPathParams = frozendict.frozendict(), content_type: str = 'application/json', + path_params: RequestPathParams = frozendict.frozendict(), stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, @@ -259,19 +280,30 @@ class ApiForput(BaseApi): def put( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: typing_extensions.Literal["application/json"] = ..., path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: typing_extensions.Literal[False] = ..., ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload + def put( + self, + body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., + path_params: RequestPathParams = frozendict.frozendict(), + stream: bool = False, + timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, + skip_deserialization: typing_extensions.Literal[False] = ..., + ) -> api_client.ApiResponseWithoutDeserialization: ... + @typing.overload def put( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], skip_deserialization: typing_extensions.Literal[True], + content_type: str = ..., path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, ) -> api_client.ApiResponseWithoutDeserialization: ... @@ -280,8 +312,8 @@ class ApiForput(BaseApi): def put( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], + content_type: str = ..., path_params: RequestPathParams = frozendict.frozendict(), - content_type: str = 'application/json', stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = ..., @@ -292,8 +324,8 @@ class ApiForput(BaseApi): def put( self, body: typing.Union[SchemaForRequestBodyApplicationJson,], - path_params: RequestPathParams = frozendict.frozendict(), content_type: str = 'application/json', + path_params: RequestPathParams = frozendict.frozendict(), stream: bool = False, timeout: typing.Optional[typing.Union[int, typing.Tuple]] = None, skip_deserialization: bool = False, diff --git a/samples/openapi3/client/petstore/python/tests_manual/test_fake_api.py b/samples/openapi3/client/petstore/python/tests_manual/test_fake_api.py index 4c2132ae3d8..7ce4a60e8f7 100644 --- a/samples/openapi3/client/petstore/python/tests_manual/test_fake_api.py +++ b/samples/openapi3/client/petstore/python/tests_manual/test_fake_api.py @@ -778,7 +778,7 @@ def test_json_patch(self): ) ] ) - api_response = self.api.json_patch(body) + api_response = self.api.json_patch(body=body) json_body = [ { 'op': 'add',