#
Response Format & Error Codes
All LeapAI CXR API endpoints return responses in a consistent JSON structure.
#
Standard Response Format
Every API response follows this schema:
{
"Result": "Success | Warning | Failure",
"Data": <object | string | null>,
"Message": "Human-readable message"
}
#
HTTP Status Codes
#
Common Error Responses
#
Authentication Errors
#
Single Inference Errors
#
Bulk Inference Errors
#
Health Check
#
GET /ping
A simple health-check endpoint to verify the server is running.
{
"status": "ok"
}
The /ping endpoint does not require authentication and does not follow the standard response format.
#
Disease Findings Schema
Each entry in the findings array within the prediction JSON output follows this schema:
{
"name": "string",
"presence": true | false,
"confidence": 0.0 - 1.0
}
Confidence Threshold
A disease is marked as presence: true when its confidence score is ≥ 0.5.
#
Metadata Schema
{
"model_version": "v1.0.1",
"patient_id": "string",
"patient_name": "string",
"sop_instance_uid": "string",
"age": "string",
"sex": "string"
}