Introduction Every working day, solicitors spend hours extracting the same information from case documents: parties involved, key dates, disputed amounts, relevant precedents, procedural history.
A single case file might contain thirty pages of court filings, witness statements, and correspondence. A junior associate reads through everything, manually compiles an executive summary, checks costs against the brief, perhaps paraphrases sections into house style, then circulates it to the team. By the time the brief is ready, several billable hours have been spent on mechanical work that machines do faster and more consistently. The problem compounds in larger practices. A litigation team handling multiple concurrent cases generates dozens of these summaries monthly. Quality varies depending on who wrote it and how carefully they read. Some briefs miss crucial details; others contain unnecessary boilerplate. Senior partners review them anyway, wasting their time, or they don't and critical information gets lost. Meanwhile, your document management system sits there storing PDFs without any structured data extraction. This workflow automates the entire process. You upload a case file to your system. An orchestration layer immediately sends it to Chat With PDF for extraction, passes the extracted details through Okara AI for confidential analysis, optionally refines the language through QuillBot, and outputs a formatted brief ready for team review. No human touch required until someone actually reads the finished product.
The Automated Workflow You'll need an orchestration platform to coordinate these tools.
Zapier works well for simpler setups; n8n or Make offer better control and lower costs at scale. I'll show the n8n approach since it handles conditional logic and multi-step API calls cleanly.
The overall data flow 1.
A case file lands in a shared folder (Google Drive, OneDrive, or Dropbox).
-
n8n detects the new file and retrieves it.
-
The file is sent to Chat With PDF via their API.
-
Chat With PDF returns structured data: parties, dates, amounts, dispute type.
-
That data is sent to Okara AI in an encrypted request (for sensitive case information).
-
Okara AI produces a preliminary summary and cost analysis.
-
QuillBot polishes the language and ensures house style consistency.
-
The final brief is saved to a template document in your case management system and sent to relevant team members via email.
Setting up the n8n workflow You'll need API keys from Chat With PDF, Okara AI, and QuillBot.
Create them all before you start building. Start a new n8n workflow. Add a Trigger node set to monitor your file storage system. For this example, I'll use Google Drive:
Trigger: Google Drive - File Created (or Modified)
Watch for: Files in /Case Files folder
Trigger when: New file uploaded
File type: application/pdf
Your first action node retrieves the file content:
Node: Google Drive - Get File
Operation: Download file
File ID: from Trigger (dynamic)
Output: File binary data
Next, send this to Chat With PDF. You'll be making an HTTP POST request to their API endpoint:
POST https://api.chatwithpdf.copilot.us/v1/documents/upload
Headers: Authorization: Bearer YOUR_CHAT_WITH_PDF_API_KEY Content-Type: application/pdf
Body: file: [binary data from Google Drive node] document_name: {{$node["Google Drive"].data.name}}
In n8n, this looks like an HTTP Request node:
Node: HTTP Request - Chat With PDF Upload
Method: POST
URL: https://api.chatwithpdf.copilot.us/v1/documents/upload
Authentication: Header auth (Bearer token)
Body: raw JSON
{ "file": "{{$binary.data}}", "document_name": "{{$node['Google Drive'].json.name}}"
}
Chat With PDF will return a document ID. Store that for the next step. Now send a follow-up request to extract specific information:
POST https://api.chatwithpdf.copilot.us/v1/documents/{{documentId}}/query
Headers: Authorization: Bearer YOUR_CHAT_WITH_PDF_API_KEY Content-Type: application/json
Body:
{ "query": "Extract: 1) Claimant and defendant names, 2) Dispute type (contract/tort/other), 3) Claim amount, 4) Key dates (filing, hearing, decision), 5) Procedural history in bullet points. Format as JSON."
}
Chat With PDF will use Claude Sonnet 4.6 internally to process your document. The response will be structured JSON with extracted fields. Now route this to Okara AI for confidential analysis. Since you're dealing with sensitive case information, Okara AI's end-to-end encryption is valuable:
Node: HTTP Request - Okara AI Analysis
Method: POST
URL: https://api.okara.ai/v1/chat/encrypted
Authentication: API Key
Body:
{ "message": "Based on the following case information, draft a 200-word executive summary suitable for a client brief. Include: summary of dispute, likely costs and timeline, and three key risks. Case details: {{$node['Chat With PDF Query'].json.extraction}}", "models": ["claude-opus-4.6"], "encryption": true
}
Okara AI will encrypt your request and response in transit. Their platform supports multiple models; Claude Opus 4.6 is best for complex legal reasoning here. The response from Okara AI is your rough brief. Now polish it with QuillBot to ensure tone and style consistency:
Node: HTTP Request - QuillBot Paraphrase
Method: POST
URL: https://api.quillbot.com/v1/paraphrase
Authentication: API Key
Body:
{ "text": "{{$node['Okara AI'].json.response}}", "tone": "professional", "length": "maintain", "fluency": true
}
QuillBot returns a refined version. Combine this with the extracted structured data and format into your final brief template. Use a Google Docs or Word Online node to populate a template:
Node: Google Docs - Create Document
Template ID: {{yourTemplateDocId}}
Fields: {{claimant}}: {{$node['Chat With PDF'].json.claimant}} {{defendant}}: {{$node['Chat With PDF'].json.defendant}} {{summary}}: {{$node['QuillBot'].json.paraphrased_text}} {{amount}}: {{$node['Chat With PDF'].json.claim_amount}} {{timeline}}: {{$node['Chat With PDF'].json.key_dates}}
Finally, send an email notification to the case team:
Node: Email - Send
To: {{$node['Trigger'].json.shared_with_emails}}
Subject: Brief Ready: {{$node['Google Drive'].json.name}}
Body: Executive summary complete. Review at [link to document]
Set this entire workflow to run on file upload. n8n will monitor your folder continuously.
Cost management in the workflow Chat With PDF charges per document analysed, not per query.
One upload costs roughly the same whether you extract data once or five times, so batch your questions into a single thorough query. Okara AI's encrypted chat tier costs more than standard APIs but is worth it for sensitive material. If you're working with non-sensitive cases, switch to Claude Haiku 4.5 via Okara's standard tier to cut costs. For high volume, cache the extracted data. Store it in a local database (SQLite in n8n, or a spreadsheet) so you don't re-query the same document. Add a conditional check: if the file is already processed, skip to the QuillBot step.
The Manual Alternative If you prefer human oversight at each stage, run this as a semi-automated workflow instead.
Have n8n extract data and prepare summaries, then send them to a dedicated Slack channel where a solicitor reviews, approves, and adds case-specific commentary before the brief goes to the client. This takes longer but catches edge cases where AI misread a key detail or missed a procedural nuance. Alternatively, use Make (Integromat) for a visual, no-code approach. Make's interface is more approachable for non-technical users, though it's slower and more expensive than n8n for complex multi-step workflows.
Pro Tips Error handling: Chat With PDF sometimes struggles with scanned PDFs or unusual formatting.
Add a check in n8n: if the extraction returns fewer than three fields, route the document to a manual review queue instead of continuing. Use an IF node with the condition: $node['Chat With PDF'].json.fields_extracted > 3. Rate limiting: Okara AI and Chat With PDF both have rate limits on their standard plans. If you're processing more than ten documents daily, cache responses and implement a queue. n8n's built-in delay nodes prevent hitting the limit; add a 2-second pause between document uploads. Handling redacted documents: Some case files contain redacted sections (judges' notes, settlement negotiations marked confidential). Chat With PDF will see these as blank or placeholder text. Add a manual step in your workflow: flag documents where more than 20 per cent of content is blank, and assign them to a paralegal for review. Cost saving with Claude Haiku 4.5: If your summaries don't require extensive legal reasoning, Okara AI's Haiku tier costs 75 per cent less than Opus. Run a few test documents through both, compare quality, and decide if the saving justifies slightly less sophisticated analysis. Testing before full rollout: Start with five archived case files. Run the workflow, manually review the output for accuracy, and refine your Chat With PDF query before deploying to production. You might need to ask for specific detail extraction; generic queries produce less useful summaries.
Cost Breakdown
| Tool | Plan Needed | Monthly Cost | Notes |
|---|---|---|---|
| Chat With PDF | Pay-as-you-go | £0.50-2.00 per document | 20 documents = £10-40. Scale with volume. |
| Okara AI | Encrypted Chat (Claude Opus 4.6) | £150-300 (depending on usage tier) | Includes multiple API calls and encryption overhead. Non-sensitive cases can use standard tier at £50-100. |
| QuillBot | Premium API | £300 annually | Flat rate for API access. Free tier available but limited to 125 requests monthly. |
| n8n (self-hosted) | Free (cloud tier starts £25/month) | £0-25 | Self-hosting on your own server costs only platform maintenance time. Cloud tier suits small teams. |
| Google Drive/Docs API | Free (within Google Workspace) | Included | Already part of most firm subscriptions. No additional cost. |
| Email/notification system | Slack or Zapier | £0-50 | Most firms already use Slack. Zapier's free tier handles basic workflows; paid tiers add reliability. |
| Total (estimated, 20 documents/month) | Standard setup | £500-750/month | Scales down to £150-200/month for low volume or non-sensitive cases. |