docs: add SDK configuration example

Add sdk-full.yaml example showing full SDK generation configuration
including spec path, languages, package naming, diff detection,
and publish settings.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
Snider 2026-01-29 01:24:41 +00:00
parent 7970e984e4
commit f70c6fb1c1

View file

@ -0,0 +1,43 @@
# Example: Full SDK Configuration
# Generate typed API clients from OpenAPI specs
sdk:
# OpenAPI spec source (auto-detected if omitted)
spec: api/openapi.yaml
# Languages to generate
languages:
- typescript
- python
- go
- php
# Output directory (default: sdk/)
output: sdk/
# Package naming
package:
name: myapi
version: "{{.Version}}"
# Breaking change detection
diff:
enabled: true
fail_on_breaking: true # CI fails on breaking changes
# Optional: publish to monorepo
publish:
repo: myorg/sdks
path: packages/myapi
# Required tools (install one per language):
# TypeScript: npm i -g openapi-typescript-codegen (or Docker)
# Python: pip install openapi-python-client (or Docker)
# Go: go install github.com/oapi-codegen/oapi-codegen/v2/cmd/oapi-codegen@latest
# PHP: Docker required
#
# Usage:
# core sdk generate # Generate all configured languages
# core sdk generate --lang go # Generate single language
# core sdk diff --base v1.0.0 # Check for breaking changes
# core sdk validate # Validate spec