Closed tpl996 closed 4 months ago
Types that allow custom extensions (x-
), usually have a WithMapOfAnythingItem
method available (like this).
perfect - thank you for the prompt response
For openapi31 operations you would do:
oc, err := reflector.NewOperationContext(http.MethodGet, "/api/v4/endpoint/{id}")
oc.(openapi31.OperationExposer).Operation().WithMapOfAnythingItem("x-api-name", "getEndpointByID")
If a schema like
components: schemas: CreateSomethingRequest: type: object required:
was required, how can this x-oapi-codegen-extra-tags field be specified?