Complete Extraction Workflow
Understanding the full extraction lifecycle helps you build robust automation pipelines. Here’s how documents flow through the system:Phase 1: Document Upload
1
Upload Files
Submit documents via Credit Impact: No credits charged for upload
Storage: No public retention SLA is exposed by the backend
POST /upload. You may send multiple files form fields in one request.2
Receive Document IDs
Store the returned UUIDs for extraction requests.
Phase 2: Schema Definition
Choose one of three approaches:- Predefined Schema (UI Only)
- Custom Schema
- Generated Schema
Use the Documind UI to access built-in templates for common document types like invoices, receipts, forms, etc.Navigate to: Dashboard → Schemas → Templates
Phase 3: Data Extraction
Configure extraction mode based on requirements:Mode Selection Decision Tree
Basic Extraction Example
Advanced Extraction Example
Phase 4: Review Workflow
Copypoll_for_review from Polling for Reviews into a local review_polling.py module in your integration. Copy the imports and function definition only; keep the module-level usage demonstration in your caller. This is customer code, not an installed SDK. Synchronous extraction responses do not include technical status; the helper reads stored state.
Phase 5: Data Processing
Process the final data in your automation:Complete Example
Complete upload, schema definition, and extraction as shown above. Then use the tested helper in Phase 4. Keep cancellation, legacy policy, and timeout separate from successful data processing. For batch and concurrent work, see Automation Pipeline.Troubleshooting
Upload Fails
Upload Fails
Problem:
500 Internal Server Error on uploadSolutions:- Verify file is not corrupted
- Retry with a smaller request if infrastructure rejects the upload size
- Ensure file format is supported
- Retry with exponential backoff
Extraction Timeout
Extraction Timeout
Problem: Extraction takes too long or times outSolutions:
- Switch to Basic mode for faster processing
- Reduce document page count
- Simplify schema (fewer fields)
- Contact support if issue persists
All Extractions Need Review
All Extractions Need Review
Problem: Review threshold too strictSolutions:
- Lower
review_thresholdfrom 85 to 75 - Mark fewer fields as
required - Improve schema descriptions
- Use Basic mode if reviews aren’t needed
Reviews Never Complete
Reviews Never Complete
Problem: Polling times out waiting for reviewSolutions:
- Increase timeout to match your review SLA
- Implement email notifications to reviewers
- Check review queue isn’t backlogged
- Consider async processing instead of blocking
Next Steps
Upload Documents
Detailed upload endpoint documentation
Extract Data
Complete extraction API reference
Polling Pattern
Robust polling implementation guide
Automation Patterns
Production-ready automation examples