pptx.dev API Documentation
Generate .pptx files from OpenPresentation JSON, validate OPF documents, parse existing decks, and run best-effort PPTX-to-OPF conversion. Authenticated /v1 endpoints use Bearer token authentication.
Authentication
Authenticated API endpoints require a Clerk API key sent as a Bearer token. Local Author and Inspector editing, preview, and PowerPoint export need no account or API key. Get your API key from the API Keys page in your account settings.
Authorization: Bearer ak_your_clerk_api_key
Both user-level and organization-level Clerk API keys are supported. Signed-in browser sessions are used for account pages and optional hosted operations such as Decoder conversion and saved Author threads.
Base URL
https://api.pptx.devEndpoints
/v1/validateliveValidate OPF
Validate an OPF JSON document or an external OPF registry URL. Returns errors and warnings without generating any files.
/v1/previewlivePreview OPF (anonymous)
Validate OPF (max 256 KB) for Inspector. No API key; 30 req/min and 500/hour per IP. Query ?format=web|svg|png (default svg) and ?slides=1,3 for subsets.
/v1/parseliveParse PPTX
Upload a .pptx file and extract structured data: slides, text, metadata, speaker notes.
/v1/convertlivePPTX to OPF
Convert an existing .pptx file into a best-effort OPF JSON document for Decoder, inspection, editing, and regeneration. This is the canonical OPF-out API; there is no separate /v1/decode alias.
/v1/generateliveGenerate PPTX
Turn a valid OPF JSON document into a production .pptx file. Only format=pptx is implemented. format=pdf|png|svg are reserved values and return 501 not_implemented.
/v1/authorbetaAuthor OPF draft
Create or refine a beta OPF draft from prompts, uploads, raw text, or OPF source. Author is the developer workbench/API layer, distinct from DeckChat's chat-first business surface.
/v1/author/threadsbetaCreate Author thread
Create a persistent Author conversation with OPF versions, run history, tool-call traces, and reviewable ghost edits.
/v1/renderbetaRender slides
Convert a .pptx file to web-viewable slide data. Only format=web is implemented. format=svg|png return 501 not_implemented.
/v1/parse/[parseId]/metadataliveGet metadata
Retrieve metadata (title, creator, dates, custom properties) from a previously parsed PPTX.
/v1/parse/[parseId]/slides/[index]liveGet slide
Retrieve a single slide's text runs, dimensions, and speaker notes by index.
/v1/parse/[parseId]/textliveGet all text
Retrieve all text content from all slides of a parsed PPTX.
/v1/data/importbetaData to table or chart
Turn CSV, TSV, JSON or .xlsx data into OPF table or chart content with the same rules as opf ingest. Returns a one-slide OPF document, or adds a slide (or a table/chart at a JSON Pointer path) to a document you send, with a validation report. Up to 5 MiB of text or a 10 MiB workbook, 5,000 rows and 100 columns; .xlsx reads one sheet, uses the values Excel saved for formulas, and turns date-formatted cells into ISO dates.
/v1/diffbetaDiff two decks
Structural diff of two OPF decks (inline, or stored decks by id): slides and blocks match by id, then identical content, then similarity. Returns categorized changes, a slide summary, a text report and an RFC 6902 patch from a to b.
/v1/patchbetaApply a patch
Apply RFC 6902 operations to an OPF deck atomically, with the inverse patch for undo. The result is validated by default (422 when invalid); with a stored deck, save: true stores it as a new version.
/v1/lintbetaLint and audit
Format and reference checks (schema checks and catalog reference checks against the records the deck embeds and the default catalog pptx.dev registers, with suggestions), design and accessibility audit (contrast, overflow, type size, alt text, reading order, charts and more) and a font report, as findings in core's Finding format. Send source (JSON text) to get line and column for each finding.
/v1/fonts/checkbetaCheck fonts
Every family an OPF deck, a .pptx or a list names, with OPF's font policy: license class, where viewers get the font, the open replacement previews draw with, and viewer diagnostics.
/v1/decksbetaStore a deck
Store a .pptx file or an OPF JSON file as a new deck owned by your user or organization. Files up to 50 MiB; 1 GiB and 1,000 decks per owner. OPF files are stored even when they do not validate, and the response reports the validation result. Supports Idempotency-Key.
/v1/decksbetaList decks
Your stored decks, most recently updated first, with storage usage and limits. Page with ?limit= and ?cursor=.
/v1/decks/[deckId]betaGet a deck
A stored deck's metadata and its versions, newest first. DELETE on the same path deletes the deck, every version and every share link.
/v1/decks/[deckId]/versionsbetaStore a new version
Add a version in the deck's format (up to 100 per deck). GET on the same path lists the versions.
/v1/decks/[deckId]/contentbetaDownload a deck
Download the latest version, or ?version=N, as an attachment. The ETag is the file's SHA-256.
/v1/decks/[deckId]/sharesbetaCreate a share link
Create an expiring link (1 minute to 30 days, default 7 days) that downloads the deck without an account, pinned to a version or following the latest. The URL is shown once. GET lists links; DELETE /v1/decks/[deckId]/shares/[shareId] revokes one.
/v1/shares/[token]betaDownload a shared deck
Public download through a share link; no API key. Unknown, expired and revoked links return 404.
Quick Start
Create a minimal OPF document and validate it:
curl -X POST https://api.pptx.dev/v1/validate \
-H "Authorization: Bearer ak_your_clerk_api_key" \
-H "Content-Type: application/json" \
-d '{
"$schema": "https://openpresentation.org/schema/opf/v1",
"name": "My Presentation",
"slides": [{ "title": "Hello, World" }]
}'Conversion Pipeline
The full input/output matrix supported by the API:
| From | To | Endpoint | Status |
|---|---|---|---|
| Natural language | OPF JSON | /author + /v1/author/* | Beta |
| .pptx file | OPF JSON | /v1/convert | Live |
| OPF JSON | .pptx file | /v1/generate | Live |
| OPF JSON | /v1/generate?format=pdf | Not available (501) | |
| .pptx file | Web slides | /v1/render?format=web | Beta |
| .pptx file | SVG / PNG | /v1/render?format=svg | Not available (501) |
Error Codes
| Code | Meaning |
|---|---|
| 400 | Bad request — invalid input, missing fields, or wrong content type |
| 401 | Unauthorized — missing or invalid API key |
| 403 | Forbidden — API key lacks required scopes, or a storage quota would be exceeded (quota_exceeded) |
| 422 | Unprocessable — OPF document failed schema validation |
| 413 | Payload too large — the upload is over the size limit |
| 429 | Rate limited — too many requests for the current key or IP |
| 500 | Internal error — please report if persistent |
| 501 | Not implemented — the requested format (PDF, PNG or SVG output) is not available yet. The body is { error: { code: "not_implemented", message, details } }; nothing is processed or billed. |
| 503 | Service unavailable — a backing service such as deck storage is not configured on this host (service_unavailable) |