Skip to main content
Beyond JSONL and CSV, KiwiFS can render markdown into deliverable formats using Pandoc, Marp, MkDocs, and Typst tooling (bundled in the Docker image). The web UI also supports in-browser PDF export via Typst without server-side dependencies.

Endpoint

POST /api/kiwi/export/document
Content-Type: application/json

Request body

format
string
required
Output format: pdf, html, slides, site, or mkdocs.
path
string
required
File or directory under the knowledge root to render.
theme
string
Theme name for HTML/PDF output.
self_contained
boolean
default:"false"
Produce a single-file HTML with embedded assets.
bibliography
string
BibTeX path for citations.
csl_style
string
Citation style preset: apa, ieee, chicago, vancouver, or harvard.
pdf_engine
string
PDF engine: typst or xelatex (default: auto-detect).
slide_format
string
Slide format (Marp).
site_name
string
Static site title (for site format).
site_url
string
Canonical site URL.
repo_url
string
Edit-on-GitHub style link for the generated site.

Examples

kiwifs export --format pdf --path docs/report.md --output report.pdf --theme paper
kiwifs export --format html --path concepts/ --self-contained --output site.html
kiwifs export --format slides --path talks/intro.md --output slides.html
kiwifs export --format site --path docs/ --site-name "My Wiki" --output docs-site.zip
kiwifs export --format mkdocs --path docs/ --site-name "My Wiki" --output docs-project/
The response streams the rendered artifact with an appropriate Content-Type. Large exports may take up to five minutes server-side.

MCP

kiwi_export_document accepts the same options for agent-driven publishing workflows.

Format details

Uses Typst by default for fast compilation. Falls back to XeLaTeX via Pandoc when Typst is unavailable. The web UI also provides in-browser PDF export via a bundled Typst WASM compiler — no server-side tools required.
The mkdocs format generates a complete MkDocs project directory with mkdocs.yml, navigation, and theme configuration. Build the static site with mkdocs build or preview with mkdocs serve.
Renders Marp-formatted markdown into HTML, PDF, or PPTX slides. Use slide_format to control the output type.
The site format produces a ready-to-deploy static site as a ZIP archive, with navigation generated from the directory structure.

Docker requirement

Server-side PDF (via Pandoc/Typst CLI) and site generation depend on external tools bundled in the official Docker image. Bare-metal installs may need Pandoc and related dependencies installed separately. In-browser PDF export via the web UI works without these dependencies.

Export overview

JSONL, CSV, and Parquet export.

Import/export API

REST reference.
Last modified on June 25, 2026