oapi-codegen icon indicating copy to clipboard operation
oapi-codegen copied to clipboard

Generate Go client and server boilerplate from OpenAPI 3 specifications

Results 633 oapi-codegen issues
Sort by recently updated
recently updated
newest added

A first attempt at resolving https://github.com/oapi-codegen/oapi-codegen/issues/1696 As request in that issue, I made it with yaml disabled by default, but could be enabled in `output-options`. I explored making a CLI...

As a common pattern seen across codebases Note that we need to make sure the slice is new each time, to make sure it can be modified by a caller.

enhancement
area:enums

Hi all, I am attempting to generate a struct type that includes an embedded field from an imported type. However, I am not achieving the desired result. Here is the...

Basically `x-internal` but for individual responses, so they can be documented but handled by middleware

Sample `api.yml`: ``` openapi: "3.0.0" info: version: 0.0.1 title: example paths: /object: get: responses: '200': content: "application/ld+json; profile=\"https://www.w3.org/ns/activitystreams\"": schema: type: string ``` Sample `config.yml`: ``` package: main generate: gorilla-server: true...

How do we provide a custom template to have `json` and `yaml` tags to the generated structs? I am aware that I can use `x-oapi-codegen-extra-tags` to add custom tags but...

enhancement

I am using a middleware for injecting context values, but when dealing with the error handler, I don't have access to the modified request context with the injected values. I...

enhancement
server:echo
server:fiber

I am trying to generate the code for [netbox](https://github.com/netbox-community/netbox), and it has a few schemas like this : ```yaml components: schemas: ConsolePort: type: object speed: type: object properties: value: enum:...

🧠 needs more thinking
spec-issue

Hi, I am new to this project and tried to create a Go server from a simple OpenAPI specification. But I didn't get what I wanted for a file upload....