GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - codotech/contractual: Schema contract lifecycle CLI and GitHub Action for OpenAPI and JSON Schema

BranchesTags
Open more actions menu

Latest commit

 

History

111 Commits
111 Commits

Folders and files

NameName
Last commit message
Last commit date
.github
.github
 
 
.husky
.husky
 
 
e2e
e2e
 
 
packages
packages
 
 
tests
tests
 
 
.gitattributes
.gitattributes
 
 
.gitignore
.gitignore
 
 
.lintstagedrc.json
.lintstagedrc.json
 
 
.npmignore
.npmignore
 
 
.prettierrc
.prettierrc
 
 
AGENTS.md
AGENTS.md
 
 
CODE_OF_CONDUCT.md
CODE_OF_CONDUCT.md
 
 
CONTRIBUTING.md
CONTRIBUTING.md
 
 
LICENSE
LICENSE
 
 
README.md
README.md
 
 
RELEASING.md
RELEASING.md
 
 
SECURITY.md
SECURITY.md
 
 
codecov.yml
codecov.yml
 
 
eslint.config.js
eslint.config.js
 
 
lerna.json
lerna.json
 
 
local-e2e.docker-compose.yaml
local-e2e.docker-compose.yaml
 
 
logo.png
logo.png
 
 
package.json
package.json
 
 
pnpm-lock.yaml
pnpm-lock.yaml
 
 
pnpm-workspace.yaml
pnpm-workspace.yaml
 
 
tsconfig.build.json
tsconfig.build.json
 
 
tsconfig.json
tsconfig.json
 
 
vitest.config.e2e.ts
vitest.config.e2e.ts
 
 
vitest.config.ts
vitest.config.ts
 
 

Repository files navigation

Contractual

Contractual

Schema contract lifecycle for OpenAPI and JSON Schema
Linting • Breaking change detection • Versioning • Release automation

license PRs welcome npm downloads

Docs   •   Quickstart   •   Breaking Detection   •   GitHub Action

Supported Formats: OpenAPI, JSON Schema

Features

  • Structural Breaking Change Detection - Compares specs against versioned snapshots using structural diffing, not string comparison. Catches removed fields, type changes, and endpoint deletions.

  • Automated Versioning - Changesets declare bump levels (major/minor/patch). contractual version consumes them, bumps versions, updates snapshots, and generates changelogs.

  • CI Integration - GitHub Action posts diff tables on PRs, auto-generates changesets, and opens Version PRs for release automation.

  • Format Agnostic - Works with OpenAPI and JSON Schema. Custom linters and differs can be configured per contract.

Quick Example

Detect changes

$ contractual diff

orders-api: 3 changes (2 breaking, 1 non-breaking) — suggested bump: major

  BREAKING     Removed endpoint GET /orders/{id}/details
  BREAKING     Changed type of field 'amount': string → number
  non-breaking Added optional field 'tracking_url'

Generate a changeset

$ contractual changeset

? Bump type for orders-api: major
? Summary: Remove deprecated endpoint, change amount type

Wrote .contractual/changesets/fuzzy-lion-dances.md

Bump versions

$ contractual version

orders-api  1.4.2 → 2.0.0 (major)

Updated .contractual/versions.json
Updated CHANGELOG.md

Installation

Beta releases are currently available under the npm beta tag. There is no stable release yet. Built-in linting and diffing support OpenAPI and JSON Schema; AsyncAPI and ODCS require custom engines. AI, fixed versioning, and generation hooks are planned. See release scope and contributing.

npm install -g @contractual/cli@beta

Or with other package managers:

pnpm add -g @contractual/cli@beta
yarn global add @contractual/cli@beta

Getting Started

  1. Initialize - contractual init scans for specs and creates contractual.yaml
  2. Lint - contractual lint validates specs
  3. Detect changes - contractual diff shows all changes classified
  4. CI gate - contractual breaking fails if breaking changes exist
  5. Version - contractual changeset + contractual version for releases

→ Full Quickstart Guide

Community

  • Documentation
  • GitHub Issues

License

MIT

About

Schema contract lifecycle CLI and GitHub Action for OpenAPI and JSON Schema

contractual.dev

Topics

breaking-changeschangesetscicontractcontractsdevtoolsgithub-actionsjson-schemajsonschemaopenapiopenapi3release-automationrestrest-apischemaspecvalidationsversioning

Resources

Readme
MIT license

Code of conduct

Code of conduct

Contributing

Contributing

Security policy

Security policy
Activity
Custom properties

Stars

38 stars

Watchers

3 watching

Forks

0 forks
Report repository

Releases

Used by

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.