Endpoints
Classify a document
Upload a PDF and receive document classification, extracted metadata, and a partial /check request body when supported
POST
/check endpoint when the PDF is a supported federal filing. The API extracts page count, word count, structural metadata, and document type from the PDF automatically. You must add filing context fields (is_pro_se, pmc_completed, opposing_party_pro_se, filing_role) before sending to /check.
The response includes a supported boolean indicating whether the document is a classifiable federal court filing. Non-federal documents, blank templates, court rules or practices, and non-legal documents return supported: false with confidence: "low" and no check_request.
Uploaded PDFs are stored to improve quality.
The response can take 10 to 30 seconds. For fillable forms and some interactive PDFs, the font, margin and line spacing details can’t always be read in time. When that happens, the format checks are skipped and the response includes a warning.
Try it
A sample filing PDF is available in the console playground. Upload it to see classification, extracted metadata, and a ready-to-run/check request body.
Request
Base64-encoded PDF file, 10 MB or less before encoding. A larger request is refused with
413;
split a larger filing and classify the parts.Original filename of the PDF (e.g.
motion_for_summary_judgment.pdf). Recommended: always include
if available. Filenames like memo_in_support_sj.pdf provide a strong classification signal;
generic names like document.pdf are still accepted but add no value.Response fields
Extracted document metadata including page count, word count, and structural elements detected in
the PDF (caption, sections, format, privacy).
Present only when
supported is true. A partial request body for POST /api/v1/check. Includes judge_slug, district_id, document_scope,
motion_type (if detected), and the full document object. You must add is_pro_se,
pmc_completed, opposing_party_pro_se, and filing_role before sending.Conditions that may affect result quality. Present only when something noteworthy occurred during
analysis (e.g., format extraction failed, document was truncated).
Error responses
PDFs exported from a word processor are read directly from their text layer. Scanned pages (images of paper) go through text recognition, and only those pages do. When a scanned page cannot be read, the error body includes
scanned_pages, the 1-based page numbers that needed text recognition, so you can tell the user which pages to replace.
Usage pattern
The typical supported-document flow is classify, then check:check_request field contains everything the classifier can extract from the PDF. Before sending it to /check, add the filing context fields that only the filer knows: is_pro_se, pmc_completed, opposing_party_pro_se, and filing_role. When supported is false, show the classification reasoning to the user and do not call /check.