api-contract-auditor
审查 API 文档、示例和字段定义是否一致,输出 breaking change 风险。;use for api, contract, audit workflows;do not use for 直接改线上接口, 替代契约测试平台.
Install via CLI (Recommended)
clawhub install openclaw/skills/skills/52yuanchangxing/api-contract-auditorWhat This Skill Does
The api-contract-auditor is a specialized OpenClaw agent skill designed to act as a rigorous quality gate for API lifecycle management. Its core function is to systematically audit API documentation, request/response examples, and schema definitions to ensure internal consistency. By leveraging predefined standards (spec.json) and flexible templates (template.md), it identifies discrepancies before they reach the development or testing phase. The skill focuses on detecting breaking changes, verifying schema adherence, and ensuring that documentation accurately reflects the underlying API contract. It serves as an essential tool for architects and developers to maintain documentation integrity and avoid costly runtime errors caused by unexpected schema deviations.
Installation
To install this skill, use the ClawHub command-line tool within your OpenClaw environment:
clawhub install openclaw/skills/skills/52yuanchangxing/api-contract-auditor
Ensure your working directory has access to the standard {baseDir}/resources/ structure, as the auditor relies on the included spec.json and template.md files to generate its reports.
Use Cases
This skill is ideal for:
- Pre-deployment audit: Scanning updated OpenAPI specifications to identify potential breaking changes before they are committed.
- Documentation validation: Ensuring that manual API document updates match the implemented field types, required constraints, and example payloads.
- Team standard enforcement: Automatically checking if new API definitions comply with company-wide architectural standards defined in the resources folder.
- Change impact analysis: Assessing how a proposed field change in a service impact downstream consumers by checking against existing documentation.
Example Prompts
- "Audit the following OpenAPI YAML against our team standard: [Paste YAML content]. Focus specifically on breaking changes for existing fields."
- "Compare the API response example provided at [URL/Path] with the field definitions in our swagger file. Are there any missing fields or type mismatches?"
- "Run a full contract audit for the user service based on the current spec.json and provide a list of high-risk breaking changes."
Tips & Limitations
- Safety First: This tool is a read-only auditor. It does not possess the authority to modify production code, update live API gateways, or push changes to configuration files.
- Context is Key: The accuracy of the auditor depends on the quality of your
{baseDir}/resources/spec.json. Keep this file updated to reflect your current API standards. - Not a Test Runner: While it identifies risks, it does not replace functional contract testing. Use this skill as a static analysis phase in your pipeline, followed by dynamic contract testing.
- Partial Data: If you provide incomplete documentation, the skill will output a list of '待确认项' (Items to Confirm) rather than guessing, ensuring you maintain control over the audit results.
Metadata
Not sure this is the right skill?
Describe what you want to build — we'll match you to the best skill from 16,000+ options.
Find the right skillPaste this into your clawhub.json to enable this plugin.
{
"plugins": {
"official-52yuanchangxing-api-contract-auditor": {
"enabled": true,
"auto_update": true
}
}
}Tags
Flags: file-read
Related Skills
securityvitals
Security vitals checker for OpenClaw. Scans your installation, scores your setup, and shows you exactly what to fix. First scan in seconds.
sealvera
Tamper-evident audit trail for AI agent decisions. Use when logging LLM decisions, setting up AI compliance, auditing agents for EU AI Act, HIPAA, GDPR or SOC 2, or when a user asks about AI decision audit trails, explainability, or SealVera.
doc-gap-finder
扫描文档目录、标题结构与文件分布,找缺失章节、重复内容和过时区域。;use for docs, audit, knowledge workflows;do not use for 读取无权限目录, 直接修改原文档.
cron-job-guardian
检查 cron 或 timer 配置中的频率、幂等、重试、日志与并发风险。;use for cron, timer, ops workflows;do not use for 直接启停生产任务, 替代真正监控.
scrapebadger
Web scraping platform — Twitter/X data, Vinted marketplace, and general web scraping API