Skip to main content

Error format

Every error shares one flat envelope:

{
"error": "validation_failed",
"message": "validation failed",
"fields": {
"slug": "slug is required",
"outputOptions.pdf.format": "format \"A9\" is not supported (allowed: A0, A1, …)"
}
}

fields is present only for field-level validation errors. Common codes:

HTTPerror codeWhen
400kind_mismatchEndpoint doesn't match the active template kind.
400invalid_jsonRequest body isn't valid JSON (or is empty when required).
400name_mismatchPUT template: filename in the body doesn't match the URL.
403csrf_blockedSec-Fetch-Site: cross-site on a mutating call.
404not_foundReport, template, or version doesn't exist.
409duplicate_slugA report with that slug already exists.
413upload_too_largeTemplate upload exceeds MAX_BINARY_UPLOAD_BYTES.
415unsupported_media_typeBody present with an unsupported Content-Type.
422validation_failedField validation failed (see fields).
422invalid_template_nameAsset name has illegal characters or hits a reserved name.
422invalid_templateUploaded content is invalid — bad UTF-8 HTML, or not a real .docx/.xlsx.
422template_missingRender/preview called with no active template selected.
422html_preview_unavailablepreview-html called on a non-HTML active template.
422empty_templateThe rendered output was empty.
422template_errorHandlebars failed to compile/execute (also covers JS helper errors).
422empty_commitA commit would record zero changed files.
500internal_errorUnexpected server error.
503*_renderer_unavailableThe PDF/DOCX/XLSX renderer isn't configured on the server.
503versions_unavailableCommit/history store not configured.