Chirp API Reference

Browse Python API documentation by package.

Packages

_Internal

Internal utilities — not part of the public API.

Ai

Thin LLM streaming for chirp. Provider string in, typed async iterables out.

App

Chirp application facade.

Cache

Chirp caching framework. Three levels of caching: 1.

Cli

Chirp CLI — project scaffolding, dev server, and contract validation.

Contracts

Typed hypermedia contracts package.

Data

Typed async database access for chirp. SQL in, frozen dataclasses out.

Ext

Chirp extensions — optional integrations (chirp-ui, etc.).

Http

HTTP abstractions — Request, Response, Headers, QueryParams, FormData. This subpackage has zero internal dependencies.

I18N

Chirp internationalization (i18n).

Markdown

Markdown rendering for chirp via patitas.

Middleware

Middleware — Protocol-based, no inheritance required.

Pages

Filesystem-based routing with automatic layout nesting. Combines co-located routes and templates, automatic layout...

Realtime

Real-time — Server-Sent Events and EventStream.

Routing

Routing — compiled route table with O(path-depth) matching.

Security

Security utilities — route protection and password hashing.

Server

Server — ASGI handler and development server.

Templating

Kida template integration — not a dependency, a feature.

Testing

Test utilities for chirp applications. Provides a test client, fragment assertions, htmx header assertions, and SSE...

Tools

MCP tool support for chirp. Register functions as MCP tools alongside HTTP routes.

Validation

Form validation — composable rules, clean results.

Modules