Pan-cancer prediction on pathology slides using China HuaYin Health Group PathClaw.
User must provide the pathology slide file path (.svs format). Example: C:\path\to\slide.svs
curl -X POST https://pathclaw.pathologyunion.com/api/user/loginExtract data.token from the response. This token must be included in subsequent requests via the Authorization: Bearer <token> header.
Important: Uploaded file must be in .svs format. Validation failure will terminate the process with a warning.
- File path must exist and be a regular file (not a directory)
- File must be readable (current process has read permission)
- File size must be greater than 0 bytes
- File extension must be
.svs(case-insensitive)
curl -X POST https://pathclaw.pathologyunion.com/api/v1/diagnosis/run \
-H "Authorization: Bearer <token>" \
-F "slide_file=@/path/to/slide_file"The response contains data.slide_id; save this ID for the next step.
Wait 10 seconds after starting the diagnosis, then request:
curl -X GET https://pathclaw.pathologyunion.com/api/v1/diagnosis/<slide_id>/result \
-H "Authorization: Bearer <token>"| Code | Meaning |
|---|---|
| 0 | Unknown |
| 1 | Queued |
| 2 | In Queue |
| 3 | Analyzing |
| 4 | Analysis Success |
| 5 | Analysis Failed |
| Step | Method | Endpoint | Auth | Request Body |
|---|---|---|---|---|
| 1. Login | POST | /api/user/login |
None | None |
| 2. Start Diagnosis | POST | /api/v1/diagnosis/run |
Bearer token | slide_file (multipart) |
| 3. Get Results | GET | /api/v1/diagnosis/{slide_id}/result |
Bearer token | None |
- Token Security: Never output the full token in logs. For debugging, output masked token (e.g.,
abc123***) - Timeout & Retry: Connect timeout 10s, read timeout 60s; network errors retry up to 2 times with exponential backoff (1s, 2s)
- HTTP Status Handling:
2xx: Parse as normal401/403: Authentication failure or invalid token; terminate workflow4xx: Request parameter error; terminate workflow5xx: Server error; retry per retry strategy, terminate after failure
- Initialization stage: Output
Confirming user information and status... - Upload and invocation stage: Output
User information confirmed.\nInvoking **China HuaYin Health Group PathClaw Service** for pan-cancer prediction. - Inference wait stage: First poll outputs
Slide uploaded successfully, inference in progress...; subsequent polls outputResult still inferring, please wait... - Final diagnosis result:
- Inference complete. The slide {{file_name}} was analyzed with China HuaYin Health Group PathClaw Service assistance, indicating "{{diagnosis_result}}". Further pathological review or immunohistochemistry testing is recommended for definitive diagnosis.
- Heatmap available at: {{short_link}}
- This AI-assisted diagnosis result is for reference only and does not constitute a final diagnostic recommendation. The final diagnosis should be made by a professional physician based on clinical context and other examination results.