Documentation
¶
Overview ¶
Command azure-codegen reads an Azure OpenAPI v2 (Swagger) JSON spec, converts it to OpenAPI v3 in memory, and runs `oapi-codegen` as a library to emit Go types + std-net-http server stubs.
Azure publishes data-plane specs as Swagger 2.0 today (https://github.com/Azure/azure-rest-api-specs). oapi-codegen consumes only OpenAPI v3, so the conversion step is required before generation. `kin-openapi/openapi2conv.ToV3` does that conversion canonically — same path the OpenAPI tooling ecosystem uses.
Usage:
azure-codegen \ -spec=services/secrets/spec/azure-keyvault-secrets.json \ -out=services/secrets/gen/azure_keyvault.gen.go \ -pkg=gen
Phase 11.4 pilot. Single-service driver for now (Key Vault secrets surface). When the pattern proves out across additional Azure services, this command's flags can grow a manifest input the way cmd/codegen does.