diff --git a/modules/openapi-generator/src/main/resources/rust/reqwest/api.mustache b/modules/openapi-generator/src/main/resources/rust/reqwest/api.mustache index f15dd0b61b2c..60337d143ef0 100644 --- a/modules/openapi-generator/src/main/resources/rust/reqwest/api.mustache +++ b/modules/openapi-generator/src/main/resources/rust/reqwest/api.mustache @@ -99,6 +99,9 @@ pub enum {{{operationIdCamelCase}}}Error { {{#notes}} /// {{{.}}} {{/notes}} +{{#isDeprecated}} +#[deprecated] +{{/isDeprecated}} {{#vendorExtensions.x-group-parameters}} pub {{#supportAsync}}async {{/supportAsync}}fn {{{operationId}}}(configuration: &configuration::Configuration{{#allParams}}{{#-first}}, {{! ### Params diff --git a/samples/client/petstore/rust/reqwest/petstore-async-middleware/src/apis/pet_api.rs b/samples/client/petstore/rust/reqwest/petstore-async-middleware/src/apis/pet_api.rs index 587f56393813..7fc32c38810e 100644 --- a/samples/client/petstore/rust/reqwest/petstore-async-middleware/src/apis/pet_api.rs +++ b/samples/client/petstore/rust/reqwest/petstore-async-middleware/src/apis/pet_api.rs @@ -359,6 +359,7 @@ pub async fn find_pets_by_status(configuration: &configuration::Configuration, p } /// Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. +#[deprecated] pub async fn find_pets_by_tags(configuration: &configuration::Configuration, params: FindPetsByTagsParams) -> Result, Error> { let uri_str = format!("{}/pet/findByTags", configuration.base_path); diff --git a/samples/client/petstore/rust/reqwest/petstore-async-tokensource/src/apis/pet_api.rs b/samples/client/petstore/rust/reqwest/petstore-async-tokensource/src/apis/pet_api.rs index b7e3167dc5dd..b45357f33a7b 100644 --- a/samples/client/petstore/rust/reqwest/petstore-async-tokensource/src/apis/pet_api.rs +++ b/samples/client/petstore/rust/reqwest/petstore-async-tokensource/src/apis/pet_api.rs @@ -365,6 +365,7 @@ pub async fn find_pets_by_status(configuration: &configuration::Configuration, p } /// Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. +#[deprecated] pub async fn find_pets_by_tags(configuration: &configuration::Configuration, params: FindPetsByTagsParams) -> Result, Error> { let uri_str = format!("{}/pet/findByTags", configuration.base_path); diff --git a/samples/client/petstore/rust/reqwest/petstore-async/src/apis/pet_api.rs b/samples/client/petstore/rust/reqwest/petstore-async/src/apis/pet_api.rs index 587f56393813..7fc32c38810e 100644 --- a/samples/client/petstore/rust/reqwest/petstore-async/src/apis/pet_api.rs +++ b/samples/client/petstore/rust/reqwest/petstore-async/src/apis/pet_api.rs @@ -359,6 +359,7 @@ pub async fn find_pets_by_status(configuration: &configuration::Configuration, p } /// Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. +#[deprecated] pub async fn find_pets_by_tags(configuration: &configuration::Configuration, params: FindPetsByTagsParams) -> Result, Error> { let uri_str = format!("{}/pet/findByTags", configuration.base_path); diff --git a/samples/client/petstore/rust/reqwest/petstore-avoid-box/src/apis/pet_api.rs b/samples/client/petstore/rust/reqwest/petstore-avoid-box/src/apis/pet_api.rs index 587f56393813..7fc32c38810e 100644 --- a/samples/client/petstore/rust/reqwest/petstore-avoid-box/src/apis/pet_api.rs +++ b/samples/client/petstore/rust/reqwest/petstore-avoid-box/src/apis/pet_api.rs @@ -359,6 +359,7 @@ pub async fn find_pets_by_status(configuration: &configuration::Configuration, p } /// Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. +#[deprecated] pub async fn find_pets_by_tags(configuration: &configuration::Configuration, params: FindPetsByTagsParams) -> Result, Error> { let uri_str = format!("{}/pet/findByTags", configuration.base_path); diff --git a/samples/client/petstore/rust/reqwest/petstore-awsv4signature/src/apis/pet_api.rs b/samples/client/petstore/rust/reqwest/petstore-awsv4signature/src/apis/pet_api.rs index d075b93b211a..8e5e914c8669 100644 --- a/samples/client/petstore/rust/reqwest/petstore-awsv4signature/src/apis/pet_api.rs +++ b/samples/client/petstore/rust/reqwest/petstore-awsv4signature/src/apis/pet_api.rs @@ -263,6 +263,7 @@ pub fn find_pets_by_status(configuration: &configuration::Configuration, status: } /// Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. +#[deprecated] pub fn find_pets_by_tags(configuration: &configuration::Configuration, tags: Vec) -> Result, Error> { // add a prefix to parameters to efficiently prevent name collisions let p_query_tags = tags; diff --git a/samples/client/petstore/rust/reqwest/petstore-model-name-prefix/src/apis/pet_api.rs b/samples/client/petstore/rust/reqwest/petstore-model-name-prefix/src/apis/pet_api.rs index e8b2edc55733..da2c44352b41 100644 --- a/samples/client/petstore/rust/reqwest/petstore-model-name-prefix/src/apis/pet_api.rs +++ b/samples/client/petstore/rust/reqwest/petstore-model-name-prefix/src/apis/pet_api.rs @@ -224,6 +224,7 @@ pub fn find_pets_by_status(configuration: &configuration::Configuration, status: } /// Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. +#[deprecated] pub fn find_pets_by_tags(configuration: &configuration::Configuration, tags: Vec) -> Result, Error> { // add a prefix to parameters to efficiently prevent name collisions let p_query_tags = tags; diff --git a/samples/client/petstore/rust/reqwest/petstore/src/apis/pet_api.rs b/samples/client/petstore/rust/reqwest/petstore/src/apis/pet_api.rs index 77a70ebe47d5..10c473c38c28 100644 --- a/samples/client/petstore/rust/reqwest/petstore/src/apis/pet_api.rs +++ b/samples/client/petstore/rust/reqwest/petstore/src/apis/pet_api.rs @@ -224,6 +224,7 @@ pub fn find_pets_by_status(configuration: &configuration::Configuration, status: } /// Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. +#[deprecated] pub fn find_pets_by_tags(configuration: &configuration::Configuration, tags: Vec) -> Result, Error> { // add a prefix to parameters to efficiently prevent name collisions let p_query_tags = tags;