OpenAPI Spec Validator & Mock Server
Validates OpenAPI 3.x specifications using the swagger-parser library and generates Prism mock servers. Detects schema inconsistencies, missing examples, and generates SDK client stubs via openapi-generator.
npx skills add agentskillexchange/skills --skill openapi-spec-validator-mock-server-2
The OpenAPI Spec Validator & Mock Server skill provides comprehensive API specification analysis and testing infrastructure. It validates OpenAPI 3.0 and 3.1 documents using swagger-parser for structural validation and spectral for style guide enforcement with custom rulesets. The skill detects common issues like missing response examples, inconsistent error schemas, undocumented query parameters, and circular reference problems. It launches Stoplight Prism mock servers from validated specs, enabling frontend teams to develop against realistic API responses with dynamic example generation. The skill generates client SDKs using openapi-generator-cli for TypeScript, Python, and Go targets with custom template overrides, produces Postman collection exports via the openapi-to-postman converter, and creates API changelog diffs between spec versions using openapi-diff. Output includes validation reports with severity-ranked issues, mock server URLs, and generated SDK packages.