Endpoint macro should support `deprecated`
Closed this issue · 0 comments
zephraph commented
The openapi spec supports a boolean
field on the operation object that signifies the operation is deprecated. We should allow that to be specified via the endpoint macro.
Example
#[endpoint {
method = GET,
path = "/organizations/{organization_name}/projects/{project_name}/instances",
tags = ["instances"],
deprecated = true,
}]
One thing to consider is that if we deprecate something we should always provide documentation to the user on what to use instead. That could either be baked in to the api by having deprecated
actually take a string or enforced later via a lint rule.