Skip to main content
POST
/
format
/
v1
/
document
cURL
curl -X POST "https://api.case.dev/format/v1/document" \
  -H "Authorization: Bearer $CASEDEV_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "content": "<string>",
  "output_format": "pdf"
}'
"<string>"

Documentation Index

Fetch the complete documentation index at: https://docs.case.dev/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

API key starting with sk_case_

Body

application/json
content
string
required

The source content to format

output_format
enum<string>
required

Desired output format

Available options:
pdf,
docx,
html_preview
input_format
enum<string>
default:md

Format of the input content

Available options:
md,
json,
text
options
object

Optional template composition and styling settings used during document generation

Response

Formatted document (binary for PDF/DOCX, HTML for preview)

The response is of type file.