Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

Chano

A Python framework for seamless serverless usage

Design

A serverless-first Python web framework. Its handler API follows the shape FastAPI made familiar (typed signatures, typed models, Depends, generated OpenAPI) but is built from the ground up around one-function-per-route deployments. Has native support for Vercel's Build Outputs API.

Usage

Routes live in an app/ directory, laid out like the Next.js App Router. Each route.py exports functions named after HTTP methods:

app/route.py                      ->  /
app/api/hello/route.py            ->  /api/hello
app/api/items/[item_id]/route.py  ->  /api/items/{item_id}
app/files/[...path]/route.py      ->  /files/{path:path}
app/(group)/about/route.py        ->  /about
public/                           ->  static files
# app/api/items/[item_id]/route.py
from typing import Annotated

from chano import Depends, HTTPBearer, HTTPException, raises
from msgspec import Meta, Struct


class Item(Struct):
    name: str
    price: Annotated[float, Meta(gt=0)]


bearer = HTTPBearer()


@raises(401, "Not authenticated")
def current_user(token: str = Depends(bearer)) -> str:
    if token != "secret":
        raise HTTPException(401, "Not authenticated")
    return "scott"


def GET(item_id: int, verbose: bool = False):
    return {"item_id": item_id, "verbose": verbose}


async def PUT(item_id: int, item: Item, user: str = Depends(current_user)) -> Item:
    return item

A handler's signature declares its inputs, which are validated with msgspec (invalid requests get a 422):

  • a parameter named after a [segment] comes from the path
  • a model (a msgspec Struct, dataclass or attrs class) comes from the JSON body, decoded and validated in a single pass
  • Depends(fn) is the result of calling fn, whose own signature is resolved the same way
  • a Request annotation receives the raw request
  • anything else is a query parameter; Query(), Header() and Body() override the default

Depends(HTTPBearer()) returns the token from Authorization: Bearer <token> (or responds 401) and documents an HTTP bearer security scheme in openapi.json. @raises(401, "Not authenticated") on a handler or dependency documents an error response for every operation using it.

Handlers can be sync or async, and return JSON-serializable data or a Response.

chano dev      # local server with reload
chano build    # writes .vercel/output (Build Output API v3)
vercel deploy --prebuilt

chano build deploys each route.py as its own function, so routes scale, cold-start and are configured independently. A route can set per-function options as module-level values, like Next.js route segment config:

max_duration = 30  # seconds
memory = 1024  # MB
regions = ["iad1"]

Framework features that assume one long-lived app are adapted to this model rather than run inside a function. The API docs are the first example: the OpenAPI schema and Swagger UI are rendered at build time and served as static files at /openapi.json and /docs, straight from the CDN.

Dependencies are resolved from the project's pyproject.toml with uv and vendored into every function; public/ is served as static files. Add chano[dev] to [dependency-groups].dev for chano dev so uvicorn is available locally without being vendored into built functions. See examples/hello.

Development

Tooling is uv, ruff and ty:

uv sync                 # install dependencies
uv run pytest           # tests
uv run ruff format .    # format
uv run ruff check .     # lint
uv run ty check         # type check

Metadata

Release files for chano 1.0.0a2

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

Source distribution (sdist)

Source distribution for chano 1.0.0a2
File Size Uploaded Provenance Actions
chano-1.0.0a2.tar.gz 223.2 kB With provenance Details for chano-1.0.0a2.tar.gz

Built distribution (wheel)

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

Total release size: 273.8 kB

Release files / chano-1.0.0a2.tar.gz

Download URL chano-1.0.0a2.tar.gz
Size 223.2 kB
Tags Source
SHA-256 checksum
How to use checksums
167898134657cc26553d103039fcccd9cfc0f511aeeb289b2220b725905aec5c
BLAKE2b-256 checksum
How to use checksums
1373ffbfd4c70dcf209eecd100c77ca3ee1bd5bacbb6b9d91f0751abc63657e0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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 22, 2026.

Transparency log

Release files / chano-1.0.0a2-py3-none-any.whl

Download URL chano-1.0.0a2-py3-none-any.whl
Size 50.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
c891194c1d5aade44d0640581ef2b987c70457ae7fbee5e549dc8202041c80c8
BLAKE2b-256 checksum
How to use checksums
82302e9bd1d2e627f5876eebb616a312a3807169b25f33f24ad6ea98cbe0a048
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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 22, 2026.

Transparency log

Security for chano 1.0.0a2

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 chano-1.0.0a2.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 22, 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