Open catalinaperalta opened 1 day ago
I agree, and other design thoughts:
@apiVersion(boolean)
is a good name for the decoratorapi-version
have the @apiVersion
decorator applied by default. If you want a parameter called api-version
that isn't an @apiVersion
parameter, you have to add @apiVersion(false)
api-version: string
Clear and concise description of the problem
For brownfield services with non-standard api version patterns we need a way to signal that the parameter or header is specifying the api version for the service in the generated code. We typically default api version parameters to the latest version in generated code, I would like a tcgc decorator that will signal when client libraries should treat a parameter or header like this.
For example, the storage blob service specifies and
x-ms-version
header on all requests for api versions.cc @iscai-msft
Checklist