Back to Tools
submit_document
2,500+ credits
Uploads a document for legal review and analysis. Documents must be associated with an active matter. Supported formats include PDF, DOCX, and TXT. Pricing is based on document size: base fee of 2,500 credits plus 100 credits per page, up to 10,000 credits maximum.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| session_token | string | Required | The session token from start_session |
| filename | string | Required | Original filename with extension |
| content_base64 | string | Required | Base64-encoded document content |
| matter_id | string | Optional | Matter ID to associate the document with |
| document_type | string | Optional | Type of document (contract, agreement, policy, other) |
| notes | string | Optional | Additional notes or instructions for reviewers |
Returns
| Name | Type | Description |
|---|---|---|
| document_id | string | Unique document identifier |
| status | string | Document status (processing, ready) |
| page_count | number | Number of pages detected |
| credits_charged | number | Credits deducted |
Example
typescript
import { readFileSync } from 'fs'; const content = readFileSync('./contract.pdf');const base64 = content.toString('base64'); const doc = await mcp.callTool("submit_document", { session_token: "sess_xyz789...", filename: "contract.pdf", content_base64: base64, matter_id: "mat_abc123...", document_type: "contract", notes: "Please focus on liability and indemnification clauses"}); console.log(doc.document_id); // "doc_ghi789..."console.log(doc.credits_charged); // 3500 (base + 10 pages)Notes
- Base fee: 2,500 credits
- Per page: 100 credits
- Maximum: 10,000 credits
- Supported formats: PDF, DOCX, TXT
- Maximum file size: 10MB