# Contract auditor

> Contract auditor is an open-source agent skill for developer tools. Audits code against integration contracts to find mismatches before runtime tests. It is available on Claude Code.

- **Kind:** Skill
- **Pricing:** Open source
- **Platforms:** Claude Code
- **Website:** https://github.com/ivy00johns/Skill-Madness/tree/main/skills/contracts/contract-auditor
- **Repository:** https://github.com/ivy00johns/skill-madness
- **GitHub stars:** 12
- **License:** MIT
- **Skill name:** contract-auditor
- **Collection:** https://github.com/ivy00johns/Skill-Madness
- **Categories:** [developer tools](https://ai-powered.com/categories/developer-tools)
- **Listing updated:** 2026-12-03

## About

This skill has the agent compare implementation code against the integration contracts written for a multi-agent build, covering API endpoints, data layer functions, and shared types. It walks through route definitions, frontend API calls, and backend-to-frontend agreement, then checks that domain rules such as null handling, transactions, and idempotency are enforced in the code.

The workflow is static: the agent reads code and contracts with search and file tools rather than running the application. Findings are written to a contract-audit.md report at the repo root with severity levels from critical to low, listing each mismatch with the contracted behavior, the actual behavior, the responsible agent, and the file location. It also flags contradictions inside the contracts themselves so they can be resolved before testing starts.

It expects contract files in a contracts/ folder, such as an OpenAPI spec, a data layer spec, and a flat shared types file, along with an ownership map and the project's tech stack. Its prompts are oriented toward a contract-first pipeline where a separate contract author, implementation agents and a QE agent work together.

## When your agent uses it

> Audit implementations against integration contracts before runtime integration testing, in native orchestrator dispatch or explicitly requested solo static review. Read code/contracts and report mismatches; never run the app or change implementation.

## What it can access

From a static check of the files on GitHub; nothing was run.

- [Instructions only, no scripts](https://github.com/ivy00johns/Skill-Madness/tree/HEAD/skills/contracts/contract-auditor)
- [Asks for: Read, Write, Grep, Glob, Bash](https://github.com/ivy00johns/Skill-Madness/blob/HEAD/skills/contracts/contract-auditor/SKILL.md)
- [License: MIT](https://github.com/ivy00johns/Skill-Madness/tree/HEAD/skills/contracts/contract-auditor)

## Features

- **API endpoint verification:** Checks routes, methods, request and response shapes, status codes and error envelopes against the OpenAPI contract.
- **Frontend call cross-check:** Compares URLs, methods and response parsing in client code with what the backend exposes.
- **Data layer conformance:** Confirms exported function names, parameter and return types, and storage semantics match the contract.
- **Shared types audit:** Looks for naming drift, enum mismatches, and manual dict construction instead of importing shared models.
- **Domain rule checks:** Verifies invariants, nullable PATCH handling, transactional writes and idempotent endpoints are enforced.
- **Severity-ranked audit report:** Writes a markdown report grading each mismatch from critical to low with file references.

## Good for

- Check that backend routes match the OpenAPI spec before integration testing
- Find frontend fetch calls that use the wrong URL or response fields
- Verify shared TypeScript or Python types are imported rather than duplicated
- Spot contradictions between contract README and shared type definitions
- Confirm nullable fields can be cleared through PATCH requests

## Install

### Claude Code

This skill ships in the `skill-madness` plugin. In Claude Code, add the marketplace and install the plugin (it may include other skills too):

```sh
/plugin marketplace add ivy00johns/Skill-Madness
/plugin install skill-madness@skill-madness
```

Or copy only this skill to `~/.claude/skills/contract-auditor`:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/ivy00johns/Skill-Madness.git "$tmp" &&
mkdir -p ~/.claude/skills &&
rm -rf ~/.claude/skills/contract-auditor &&
cp -R "$tmp/skills/contracts/contract-auditor" ~/.claude/skills/contract-auditor &&
rm -rf "$tmp"
```

For one project only, put the folder in `.claude/skills/contract-auditor` inside it instead.

### Codex

Copy the skill folder to `~/.agents/skills/contract-auditor` to use it in every repository:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/ivy00johns/Skill-Madness.git "$tmp" &&
mkdir -p ~/.agents/skills &&
rm -rf ~/.agents/skills/contract-auditor &&
cp -R "$tmp/skills/contracts/contract-auditor" ~/.agents/skills/contract-auditor &&
rm -rf "$tmp"
```

For one repository only, put the folder in `.agents/skills/contract-auditor` inside it instead.

### Cursor

Copy the skill folder to `~/.cursor/skills/contract-auditor` to use it in every project:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/ivy00johns/Skill-Madness.git "$tmp" &&
mkdir -p ~/.cursor/skills &&
rm -rf ~/.cursor/skills/contract-auditor &&
cp -R "$tmp/skills/contracts/contract-auditor" ~/.cursor/skills/contract-auditor &&
rm -rf "$tmp"
```

For one project only, put the folder in `.cursor/skills/contract-auditor` inside it instead.

### Gemini CLI

Run in a terminal (add `--scope workspace` to install it for the current workspace only):

```sh
gemini skills install https://github.com/ivy00johns/Skill-Madness.git --path skills/contracts/contract-auditor
```

Or copy the folder to `~/.gemini/skills/contract-auditor` yourself.

### VS Code

For GitHub Copilot in VS Code, copy the skill folder to `~/.copilot/skills/contract-auditor`:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/ivy00johns/Skill-Madness.git "$tmp" &&
mkdir -p ~/.copilot/skills &&
rm -rf ~/.copilot/skills/contract-auditor &&
cp -R "$tmp/skills/contracts/contract-auditor" ~/.copilot/skills/contract-auditor &&
rm -rf "$tmp"
```

For one project only, put the folder in `.github/skills/contract-auditor` inside it instead.

### Other agents

Get the folder:

```sh
git clone --depth 1 https://github.com/ivy00johns/Skill-Madness.git
```

Then copy `Skill-Madness/skills/contracts/contract-auditor` into your agent's skills folder as `contract-auditor`. Agents that support SKILL.md read one folder per skill.

## FAQ

### Does Contract auditor run the application?

No. It is a static analysis pass that reads code and contracts and does not execute the app or change implementation.

### Where does the report go?

Findings are written to contract-audit.md at the repo root, which the QE agent reads before integration testing.

### What inputs does Contract auditor need?

Contract files from a contracts/ folder, an agent ownership map, the tech stack, and a service map of source directories.

### Can Contract auditor be used on its own?

Yes, for an explicitly requested solo static review where the user supplies scope, contracts and an output path. Missing contracts block conformance claims.

### How do I install Contract auditor in Claude Code?

Copy the skill folder from GitHub to ~/.claude/skills/contract-auditor to use it in all your projects, or to .claude/skills/contract-auditor in one project. Or install the skill-madness plugin, which includes it: /plugin marketplace add ivy00johns/Skill-Madness, then /plugin install skill-madness@skill-madness.

### Does Contract auditor run scripts?

No. It is instructions only, with no scripts. This comes from a static check of the files on GitHub; nothing was run. Read the files before you install it.

### Which AI agents can use Contract auditor?

Claude Code. It reads skills in the SKILL.md format; the install steps on this page show where to put the folder.

### What are the best alternatives to Contract auditor?

The closest alternatives to Contract auditor are Qe agent, Testing audit, Axiom audit testing, Test gap audit and Audit prep assistant.

## Where this comes from

- Description: from the skill's own SKILL.md.

## Alternatives

- [Qe agent](https://ai-powered.com/skills/qe-agent): Qe agent is an open-source agent skill for developer tools.
- [Testing audit](https://ai-powered.com/skills/testing-audit): Testing audit is an open-source agent skill for developer tools.
- [Axiom audit testing](https://ai-powered.com/skills/axiom-audit-testing): Axiom audit testing is an open-source agent skill for developer tools.
- [Test gap audit](https://ai-powered.com/skills/test-gap-audit): Test gap audit is an open-source agent skill for developer tools.
- [Audit prep assistant](https://ai-powered.com/skills/audit-prep-assistant): Audit prep assistant is an open-source agent skill for security.
- [Contract author](https://ai-powered.com/skills/contract-author): Contract author is an open-source agent skill for developer tools.
- [API breaking change detector](https://ai-powered.com/skills/api-breaking-change-detector): API breaking change detector is an open-source agent skill for developer tools.
- [API contract review](https://ai-powered.com/skills/api-contract-review): API contract review is an open-source agent skill for developer tools.

---
Source: https://ai-powered.com/skills/contract-auditor
