Streaming Responses

Consume NDJSON file-processing streams.

NDJSON streaming

POST /process streams one extracted_page line per page in the source document, then a single redacted line containing the full redacted text, then a done sentinel.

This lets you render a progress UI on multi-page PDFs without buffering the whole document server-side.

curl https://api.savitar.dev/v1/process \
  -H "Authorization: Bearer $SAVITAR_API_KEY" \
  -F "file=@contract.pdf" \
  -F "operator=replace"