A complete, self-contained OpenAPI toolkit for Go with minimal dependencies.
Parse, validate, fix, convert, diff, join, generate, and build OpenAPI specs (2.0–3.2) — all in one tool.
Spec Lifecycle — parser · validator · fixer · converter
Multi-Spec Ops — joiner · differ · overlay
Code & Query — generator · builder · walker
Runtime — httpvalidator · oaserrors
12 packages covering the full OpenAPI lifecycle. See full details →
- 📦 Minimal Dependencies — Only
go.yaml.in/yaml,golang.org/x/tools,golang.org/x/text, and the MCP Go SDK at runtime - ✅ Battle-Tested — 11,000+ tests against 10 production APIs (Stripe, GitHub, Discord, MS Graph 34MB)
- ⚡ Performance — Pre-parsed workflows 11–150x faster; 370+ benchmarks
- 📋 OAS 2.0–3.2 — Full JSON Schema Draft 2020-12 for OAS 3.1+; automatic format detection and preservation
- 🤖 AI-Ready — Built-in MCP server exposes all capabilities to LLM agents
- 🌐 Try Online — oastools.robnrob.com — no install required
oastools validate openapi.yaml # Validate a spec
oastools convert -t 3.0.3 -o openapi.yaml swagger.yaml # Convert versions
oastools diff --breaking v1.yaml v2.yaml # Detect breaking changes
oastools fix -o fixed.yaml api.yaml # Auto-fix errors
oastools join -o merged.yaml base.yaml ext.yaml # Merge specs
oastools generate --client --server -o ./gen -p api openapi.yaml # Generate Go code// Parse, validate, and fix — consistent functional options API
result, _ := parser.ParseWithOptions(parser.WithFilePath("api.yaml"))
vResult, _ := validator.ValidateWithOptions(validator.WithParsed(*result))
fResult, _ := fixer.FixWithOptions(fixer.WithParsed(*result))brew install erraggy/oastools/oastools # Homebrew (macOS/Linux)
go install github.com/erraggy/oastools/cmd/oastools@latest # Go installPre-built binaries for macOS, Linux, and Windows on the Releases page.
go get github.com/erraggy/oastools@latestRequires Go 1.26+.
📚 Documentation Site — Guides, examples, and package deep dives
📖 CLI Reference — All commands, flags, and output formats
🤖 MCP Server — LLM agent integration via Model Context Protocol
📦 API Reference — Go package documentation with runnable examples
Fork, branch, make check, conventional commits. See CONTRIBUTING.md for the guide and WORKFLOW.md for the full process.
MIT
Initial code was generated by Claude Code using sonnet/opus with minor edits and full control by @erraggy.