Endpoint reference

All REST endpoints of API v1

Complete reference for every endpoint in the v1 API. Base URL: https://cbcthub.com/api/v1

GET/api/v1/me

Returns your account info (plan, storage, exam count). Useful to verify the key works.

json
{
  "user_id": "...",
  "email": "soporte@miclinica.com",
  "plan": "pro",
  "scopes": ["exams:read", "exams:write"],
  "storage": { "used_bytes": 41200000000, "limit_bytes": 375809638400, "used_percent": 11 },
  "exams": { "count": 110, "limit": 999999 }
}
POST/api/v1/exams

Creates an exam and returns presigned URLs for direct upload to R2.

FieldTypeRequiredNotes
namestringInternal exam name (max 200 chars).
exam_typestringcbct (default), radiografia, mesh, atm. Radiografia requires Pro.
patient_namestringPatient name. Shown in viewer.
patient_idstringSSN, ID number, medical record number.
birth_datestring ISOYYYY-MM-DD.
reasonstringReason / clinical findings requested.
expiration_daysnumberDays until expiry. null = never.
filesarray[{ name, size }]. Min 1, max 5000.
GET/api/v1/exams?limit=20&offset=0

List your account exams, paginated. Default limit=20, max 100.

GET/api/v1/exams/{id}

Single exam details. Includes share_url, viewer_url, share_password and public_page_pin.

POST/api/v1/exams/{id}/confirm

Marks exam as ready after files are uploaded. Idempotent.

DELETE/api/v1/exams/{id}

Deletes the exam. R2 files are cleaned up in background. Non-reversible.