Package Exports
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (delimit-cli) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
delimit
Catch breaking API changes before they ship.
Deterministic diff engine for OpenAPI specs. Detects breaking changes, classifies semver, enforces policy, and posts PR comments with migration guides. No API keys, no external services.
GitHub Action (recommended)
name: API Contract Check
on: pull_request
jobs:
delimit:
runs-on: ubuntu-latest
permissions:
pull-requests: write
steps:
- uses: actions/checkout@v4
- uses: delimit-ai/delimit-action@v1
with:
spec: api/openapi.yamlOne input. Delimit fetches the base branch version automatically. Runs in advisory mode by default -- posts a PR comment but does not fail your build. Set mode: enforce to block merges on breaking changes.
CLI
npx delimit-cli lint api/openapi.yaml
npx delimit-cli diff old.yaml new.yaml
npx delimit-cli explain old.yaml new.yaml --template migrationOr install globally:
npm install -g delimit-cli
delimit init --preset default
delimit lint api/openapi.yamlCommands
| Command | What it does |
|---|---|
delimit init [--preset] |
Create .delimit/policies.yml with a policy preset |
delimit lint <spec> |
Diff + policy check. Exit 1 on violations. |
delimit diff <old> <new> |
Raw diff with [BREAKING] / [safe] tags |
delimit explain <old> <new> |
Human-readable summary (7 templates) |
Policy presets
delimit init --preset strict # All breaking changes are errors
delimit init --preset default # Breaking = error, type changes = warn
delimit init --preset relaxed # Everything is a warningOr inline: delimit lint --policy strict api/openapi.yaml
What it catches
10 breaking change types (endpoint removed, method removed, required param added, param removed, response removed, required field added, response field removed, type changed, format changed, enum value removed) plus 7 non-breaking types for full visibility. Every change classified as MAJOR, MINOR, PATCH, or NONE.
Supports OpenAPI 3.0, 3.1, and Swagger 2.0 in YAML or JSON.
Links
License
MIT