Skip to content

API

These pages are generated from the source with mkdocstrings.

Stability

The public stability boundaries are:

Module Status
caxton Recommended short facade. Start here.
caxton.api The extended generative API and the render/write/validate operations.
caxton.core.models Immutable semantic nodes.
caxton.core.types Semantic value types.
caxton.core.formatting Backend-neutral presentation vocabulary.
caxton.core.protocols Contracts for data sources, sinks and renderers.
caxton.core.accessors Built-in exact mapping and attribute row accessors.
caxton.core.rendering Renderer descriptors, requirements, contexts and results.
caxton.core.values The backend-neutral cell-value type.
caxton.core.ir Versioned read-only IR used by custom renderers.
caxton.core.errors The public exception and warning hierarchy.
caxton.testing Stable inspection and comparison surface.

Not public API

The underscore-prefixed implementation packages — including bundled renderer implementations, mutable IR builders, parsers, planners and package post-processors — are implementation detail. It may change in any release without notice.

Choosing an import

from caxton import spreadsheet, table, text, write  # everyday work
from caxton.api import xlsx  # XLSX escape hatches
from caxton.core.models import SpreadsheetDocument  # type annotations
from caxton.core.protocols import DataSource, Renderer  # custom integrations
from caxton.testing import inspect_artifact, inspect_spec  # tests