Request structure
Endpoint
Required headers
Optional headers
Request body structure
Themedical_note field is required. You can optionally include a pdf_file for additional context:
Required: Text Input
Optional: PDF Input (for additional context)
Required fields
medical_note (string, REQUIRED)
Clinical narrative text to process for ICD-10 coding. This field is always required.
Examples:
- “Patient admitted with acute myocardial infarction”
- “Type 2 Diabetes Mellitus, controlled with oral medications”
- “Diabetic patient with poor glycemic control, HbA1c 9.2%”
- Maximum size: 50 KB (~25,000 words)
- UTF-8 encoding
- Always required
pdf_file (object, optional)
Optional PDF file object for providing additional context or supporting documents.
Structure:
type: Must be"file"(validated)source_type: Must be"base64"(validated)data: Base64 encoded PDF content (max 5MB decoded)mime_type: Must be"application/pdf"(validated)filename: String (required)- Optional - can be provided alongside
medical_notefor additional context
Optional fields
model (string, optional)
AI model quality level selection for processing.
Available options:
"fast"- Fastest processing with good accuracy (recommended for high-volume)"balanced"- Balance between speed and accuracy (default)"high-quality"- Highest accuracy with slower processing (recommended for complex cases)
"balanced" if not specified
Example:
Response structure
Success response (HTTP 200)
Error response (HTTP 4xx/5xx)
Response fields explained
final_code_assessments (array)
Array of approved ICD-10 code assessments selected by the AI.
Each assessment contains:
code(string): ICD-10 medical code (e.g., “E11.9”)description(string): Medical description of the codejustification(string): AI reasoning for code selectionconfidence_percent(number): Confidence score (0-100)
discarded_code_assessments (array)
Array of considered but rejected code assessments. Shows the AI’s decision-making process and codes that were evaluated but not included.
Same structure as final_code_assessments
run_id (string)
Unique identifier (UUID) for this codification run.
Uses:
- Tracking and auditing
- Debugging issues
- Correlating with backend logs
- Support requests
Special cases
Very long input
If your clinical text exceeds 50KB or PDF exceeds 5MB: Option 1: Split into multiple calls- For text: Remove unnecessary whitespace and formatting
- For PDFs: Compress PDF before encoding, remove non-essential pages
PDF file encoding
To encode a PDF file for the API:Text preprocessing
Optional but recommended:Request optimization
Batch processing
For processing multiple notes, send parallel requests:Handling confidence scores
Filter results based on confidence thresholds:Limits and restrictions
See Complete limits and quotas for detailed information. Main limits:- Maximum
medical_notesize: 50 KB (~25,000 words) - Maximum
pdf_filesize: 5 MB (decoded) - Processing timeout: 10 minutes (600 seconds)
- Rate limit: Varies by customer plan
Next steps
View examples
Real requests and responses
Error handling
Error responses and how to handle them
Authentication
API authentication and headers
OpenAPI Reference
Complete API specification