MarkRosemaker/openapi-enrich
Build up an OpenAPI specification in Go from observed HTTP traffic, inferring paths, operations, parameters, request bodies, response schemas, and string formats from real requests and responses.
Build up an OpenAPI specification in Go from observed HTTP traffic, inferring paths, operations, parameters, request bodies, response schemas, and string formats from real requests and responses.
Eliminate nesting in an OpenAPI specification in Go by promoting inline schemas, responses, request bodies, and parameters into named entries under components, replacing each with a $ref reference.
Remove redundancy from an OpenAPI specification in Go by merging component schemas that describe the same thing, rewriting every $ref that pointed at the copies, and shortening the resulting names.
Safely make structural edits to an OpenAPI specification in Go, such as renaming a schema and rewriting every $ref that points to it, so that the document still resolves afterwards.
Compare objects in an OpenAPI specification in Go. Offers both exact equality and shape equivalence, which ignores documentation-only fields such as title and description to report whether two schemas accept the same JSON.
Merge two OpenAPI objects into one that covers both, reconciling schemas inferred from independent samples of real data. Handles partial evidence such as values observed only as null, integer and number widening, and dates encoded either as strings or as timestamps.
Parse, validate, format, and write OpenAPI specifications in Go. The foundation of a family of composable tools for comparing, editing, flattening, deduplicating, enriching, and generating code from specs.
Provides a generic ordered map implementation, primarily designed for JSON v2 marshalling and unmarshalling. Includes helper functions to easily define your own custom ordered maps with minimal boilerplate code.
Provides custom JSON v2 marshaling and unmarshaling functions for specific data types, e.g. JSON encoding and decoding for types like time.Duration and url.URL.
Utilities for creating and managing detailed error paths, allowing users to construct error messages that include the full path to the error. Useful when traversing complex data structures such as JSON or YAML files. Example: components.schemas["Pet"].allOf[0]: invalid schema
Generate idiomatic Go code from an OpenAPI specification: types, a typed HTTP client, an http.Handler server scaffold, and tests. Flattens and compresses the spec first, so that generated types are named and free of duplicates.