contract-compatibility-gate
БесплатноБез исполняемых скриптовНе проверенUse when a deploy should be blocked by any incompatible API contract across protocols. Combines Pact can-i-deploy, oasdiff for OpenAPI, graphql-inspector for…
от testland★ 18 звёзд на GitHubОб этом скилле
contract-compatibility-gate
Overview
Modern services rarely speak just one protocol. A single deployment might depend on Pact verifications (consumer/provider HTTP), OpenAPI compatibility for an external REST surface, GraphQL schema regressions for a public graph, and Protobuf breaking-change checks for internal gRPC. Each tool has its own exit code, its own severity levels, and its own concept of "breaking":
| Tool | Verdict surface |
|---|---|
Pact can-i-deploy |
Exit 0 = yes / 1 = no (can-i-deploy) |
oasdiff breaking |
Exit driven by --fail-on ERR/WARN/INFO (oasdiff-breaking) |
graphql-inspector diff |
Non-zero on BREAKING; zero on DANGEROUS / NON_BREAKING (gqi-diff) |
buf breaking |
Non-zero on any rule violation in active categories (buf-breaking) |
This skill defines a unified gate: collect each tool's structured output, normalize to one record shape, apply a single severity rule, emit one verdict.
When to use
- A deployment depends on more than one protocol (typical for a service exposing both gRPC + REST, or a frontend consuming both GraphQL and REST).
- The team wants the verdict in
$GITHUB_STEP_SUMMARY(or equivalent) rather than four separate "❌ pact" / "❌ oasdiff" CI badges. - Some checks should be advisory rather than blocking - e.g. block on oasdiff ERR but let WARN pass with a comment.
- The team wants per-tool ratchet behavior (existing failures grandfathered, new failures block).
If the project uses one protocol only, defer this gate - use the matching per-tool SKILL.md's "CI integration" section directly.
How to use
- Identify each protocol's source. For every protocol the deployment consumes, run the matching per-tool skill and capture its output as a CI artifact (see Identify your sources below).
- Normalize findings. Flatten every tool's per-finding output into the one record shape (see The unified record).
- Classify severity. Map each tool's native severity onto
blocker/warn/info(see Severity normalization). - Apply the gate rule. Any non-ratcheted
blockermakes the verdictno-go; warnings report but do not block by default (see The gate decision rule). - Emit one artifact and exit. Write a single markdown + JSON summary; a
no-goexits non-zero so CI halts. The full gate script, CI wiring, and artifact format live in references/gate-implementation-and-ci.md.
Identify your sources
For each protocol the deployment consumes, pick the tool from the
matching plugin skill and ensure its output is captured as a CI
artifact (always with if: always() on the upload):
| Tool | Skill | Artifact |
|---|---|---|
| Pact | pact-contract-testing |
can-i-deploy exit code + matrix |
| oasdiff | openapi-contract-diff |
--format json array |
| GraphQL | graphql-schema-regression |
grep-parsed text or JSON action |
| Protobuf | protobuf-compat-checking |
--error-format json array |
The unified record
Flatten every tool's per-finding output into one shape:
{
"tool": "oasdiff",
"protocol": "openapi",
"finding": "response-success-status-removed",
"severity": "blocker",
"subject": "GET /pets",
"message": "the success response status '200' was removed",
"ratchet": false,
"owner": "@api-platform"
}
| Field | Source |
|---|---|
tool |
pact / oasdiff / graphql-inspector / buf. |
protocol |
pact / openapi / graphql / protobuf. |
finding |
tool-specific rule ID (oasdiff id, graphql-inspector change type, buf rule like FIELD_NO_DELETE). |
severity |
normalized - blocker / warn / info. |
Установить contract-compatibility-gate в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
FAQ
Что делает скилл contract-compatibility-gate?
Use when a deploy should be blocked by any incompatible API contract across protocols. Combines Pact can-i-deploy, oasdiff for OpenAPI, graphql-inspector for GraphQL and buf breaking for Protobuf into one go/no-go CI step with severity thresholds and a reason per finding.
Как установить скилл contract-compatibility-gate?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл contract-compatibility-gate запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
mcp-builder
Guide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when…
от Anthropicclaude-api
Reference for the Claude API / Anthropic SDK — model ids, pricing, params, streaming, tool use, MCP, agents, caching, token counting, model migration. TRIGGER…
от Anthropicalgorithmic-art
Creating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code…
от Anthropicmcp-integration
This skill should be used when the user asks to "add MCP server", "integrate MCP", "configure MCP in plugin", "use .mcp.json", "set up Model Context…
от Anthropic