Skip to main content

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.

The problem: You have 5,000 documents from discovery. Finding the relevant ones takes weeks of manual review. The solution: Upload to a Vault. We OCR, chunk, and index everything. Search by meaning in seconds.

1. Create a vault

Vaults are secure containers for your users’ documents. Each vault gets automatic OCR, chunking, and vector indexing.
curl -X POST https://api.case.dev/vault \
  -H "Authorization: Bearer $CASEDEV_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Case Documents - User 12345",
    "description": "Discovery documents for case review"
  }'

2. Upload documents

Handle file uploads from your users and trigger automatic processing:
# 1. Get upload URL
UPLOAD=$(curl -s -X POST "https://api.case.dev/vault/$VAULT_ID/upload" \
  -H "Authorization: Bearer $CASEDEV_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"filename": "document.pdf", "contentType": "application/pdf"}')

UPLOAD_URL=$(echo $UPLOAD | jq -r '.uploadUrl')
OBJECT_ID=$(echo $UPLOAD | jq -r '.objectId')

# 2. Upload file
curl -X PUT "$UPLOAD_URL" \
  -H "Content-Type: application/pdf" \
  --data-binary "@document.pdf"

# 3. Trigger ingestion
curl -X POST "https://api.case.dev/vault/$VAULT_ID/ingest/$OBJECT_ID" \
  -H "Authorization: Bearer $CASEDEV_API_KEY"

3. Search by meaning

Enable your users to search by meaning, not just keywords:
curl -X POST "https://api.case.dev/vault/$VAULT_ID/search" \
  -H "Authorization: Bearer $CASEDEV_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "query": "communications about equipment failure",
    "method": "hybrid",
    "topK": 10
  }'

4. Summarize findings

Enhance results with AI-generated summaries for your users:
curl -X POST https://api.case.dev/llm/v1/chat/completions \
  -H "Authorization: Bearer $CASEDEV_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "anthropic/claude-sonnet-4.5",
    "messages": [
      {"role": "system", "content": "Summarize these search results concisely."},
      {"role": "user", "content": "User searched for: [QUERY]\n\nResults:\n\n[SEARCH RESULTS]"}
    ],
    "max_tokens": 500
  }'
Time saved: What used to take weeks of manual review now takes minutes. The AI finds relevant passages even when documents use different terminology.