Skip to main content

type: overview status: active authority: informative criticality: low review: status: unreviewed

CodaPact

CodaPact wordmark

Contracts into callable tools. Read an API contract (OpenAPI 3.0/3.1 or GraphQL), generate a typed library, then generate a CLI on top of that library.

contract ──► sources ──► semantic model ──► shaping ──► library surface ──► command model
 (OpenAPI,     (L1)          (L2)            (L3)          (L4)              (L5)
  GraphQL)                                                   │                 │
                                                             ▼                 ▼
                                                   library targets      CLI targets
                                                   (Python, TS, plugin) (Python CLI)

Try it

Prerequisites: Git and uv.

git clone https://github.com/mikejhill/codapact.git
cd codapact
uv sync --locked
uv run codapact generate -c examples/petstore/codapact.yaml
uv run --with . --with ./examples/petstore/generated/python petstore pets list --help

Quick mode, no project file:

uv run codapact generate --source openapi.yaml --target python --target python-cli \
  --package acme --program acme --out out/

Inspect any intermediate layer as JSON:

uv run codapact inspect model   -c examples/library/codapact.yaml
uv run codapact inspect surface -c examples/library/codapact.yaml
uv run codapact inspect commands -c examples/library/codapact.yaml

What you get

Output Contents
python Installable package: TypedDict types, a resource-per-namespace client, paging iterators, py.typed
python-cli argparse CLI calling the Python library: --help with examples, --version, describe (JSON catalog for agents), doctor, shell completion, --dry-run, JSON/JSONL/YAML/table output, JSON errors, documented exit codes; env + XDG settings
typescript Fetch-based client with bundled runtime; strict tsc clean
external plugin Any executable speaking the JSON plugin protocol

Generated code is a thin facade over codapact.runtime: retries, auth, validation, and pagination live in one tested place and improve without regenerating.

Documents

  • Architecture: layers, dependency rules, extension seams, and lessons taken from Smithy, Fern, Kiota, protoc, Stainless, Speakeasy, graphql-codegen, and restish.
  • Configuration: codapact.yaml, shaping transforms, target options, and generated CLI settings.
  • Publishing codas: naming (codapact-<api>) and repository layout for codas this project publishes.
  • Agent skills: create-coda-skill writes the thin skill that lets an agent use a coda's CLI. The repository is a plugin marketplace for Claude Code, GitHub Copilot, and Codex: <agent> plugin marketplace add mikejhill/codapact.
  • Discovery efficiency: how many tokens and calls an agent spends learning a generated CLI, compared with --help, MCP, OpenAPI, and llms.txt.
  • Contributing

Metadata

Release files for codapact 0.13.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for codapact 0.13.0
File Size Uploaded Provenance Actions
codapact-0.13.0.tar.gz 582.8 kB With provenance Details for codapact-0.13.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for codapact 0.13.0
File Interpreter ABI Platform Actions
codapact-0.13.0-py3-none-any.whl Python 3 none any Details for codapact-0.13.0-py3-none-any.whl

Total release size: 801.8 kB

Release files / codapact-0.13.0.tar.gz

Download URL codapact-0.13.0.tar.gz
Size 582.8 kB
Tags Source
SHA-256 checksum
How to use checksums
9c89b4081d5fe08ef064a3a8a3c08324374782bf9483cb2ab363c7032ff9dd57
BLAKE2b-256 checksum
How to use checksums
d317b4cfcb734a137e1377327d774f550c975143a71ddac6ae5e97ca0cbf197e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 21, 2026.

Transparency log

Release files / codapact-0.13.0-py3-none-any.whl

Download URL codapact-0.13.0-py3-none-any.whl
Size 218.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
c870feb20edb64ef172da6d2710b495fd9444ca957b906d62eee125a50c25097
BLAKE2b-256 checksum
How to use checksums
a8e3e4fdfcd93c599d59bc120ec21a55467e84390a33e5e422765a394ac1335b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 21, 2026.

Transparency log

Security for codapact 0.13.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for codapact-0.13.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 21, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page