← All contracts
OHN-11 Diagnostics Results Exchange
- Version
- 1.0.0
- OpenAPI
- 3.1.0
- Source in the repository
modules/OHN-11/api/openapi.json- Servers
https://opeshealthnetwork.com/api/ohn/v1/diagnostics
- Authentication
bearer: http bearer
Download the contract (JSON)
Contracts are written in English.
Server paths are under /api/ohn/v1/diagnostics. Default deny: role AND purpose must match. Inventory paths OHN-11-API-001..003 are mapped to this disjoint prefix (see ADR-0001). Reconciled with the observed behaviour of backend/modules/ohn-11 (docs/program/java/ohn-11-contract-changes.md).
Operations
OHN-11
GET/patients/{id}/observationsPublished observation lines for one patient by code (system|code), every version flagged is_current, with source report provenance
Operation ID: listPatientObservations
Authentication: bearer
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | yes | |
code | query | array of string | no | system|code, repeatable or comma separated (1-20) |
include_superseded | query | boolean | no | |
Responses
| Code | Description | Media type |
|---|
200 | Success | application/json: object
|
400 | Malformed request or missing Idempotency-Key | — |
401 | Unauthenticated | — |
403 | Denied by policy, separation of duties or role not permitted for the step | — |
404 | Not found / not disclosed | — |
409 | version_conflict, invalid_transition, not_overdue, max_escalation_reached, report_not_ready, duplicate_source_report, duplicate_amendment, idempotency_key_reused or request_in_progress | — |
422 | domain_validation_failed (details per field), code_list_not_configured, policy_not_configured, amendment_mismatch, different_patients, report_not_publishable, safety_block | — |
429 | Rate limited | — |
503 | Dependency unavailable (fail closed): dependency_unavailable with details.dependency | — |
GET/patients/{id}/patient-viewOwn published results of the patient for the OHN-31 patient chart (role patient under purpose patient_access; own record only, otherwise 404; OHN-16 decision; every read audited)
Operation ID: patientResultView
Authentication: bearer
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | yes | |
Responses
| Code | Description | Media type |
|---|
200 | Success | application/json: object
|
400 | Malformed request or missing Idempotency-Key | — |
401 | Unauthenticated | — |
403 | Denied by policy, separation of duties or role not permitted for the step | — |
404 | Not found / not disclosed | — |
409 | version_conflict, invalid_transition, not_overdue, max_escalation_reached, report_not_ready, duplicate_source_report, duplicate_amendment, idempotency_key_reused or request_in_progress | — |
422 | domain_validation_failed (details per field), code_list_not_configured, policy_not_configured, amendment_mismatch, different_patients, report_not_publishable, safety_block | — |
429 | Rate limited | — |
503 | Dependency unavailable (fail closed): dependency_unavailable with details.dependency | — |
GET/patients/{id}/resultsResults for one patient (current versions; clinicians see published only)
Operation ID: listPatientResults
Authentication: bearer
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | yes | |
include_superseded | query | boolean | no | |
report_type | query | string | no | |
cursor | query | string | no | |
Responses
| Code | Description | Media type |
|---|
200 | Success | application/json: object
|
400 | Malformed request or missing Idempotency-Key | — |
401 | Unauthenticated | — |
403 | Denied by policy, separation of duties or role not permitted for the step | — |
404 | Not found / not disclosed | — |
409 | version_conflict, invalid_transition, not_overdue, max_escalation_reached, report_not_ready, duplicate_source_report, duplicate_amendment, idempotency_key_reused or request_in_progress | — |
422 | domain_validation_failed (details per field), code_list_not_configured, policy_not_configured, amendment_mismatch, different_patients, report_not_publishable, safety_block | — |
429 | Rate limited | — |
503 | Dependency unavailable (fail closed): dependency_unavailable with details.dependency | — |
POST/results/ingestImport a diagnostic report as received
Operation ID: ingestResult
Authentication: bearer
Parameters
| Name | In | Type | Required | Description |
|---|
Idempotency-Key | header | string | yes | |
Request body (required)
Responses
| Code | Description | Media type |
|---|
201 | Created | application/json: object
|
400 | Malformed request or missing Idempotency-Key | — |
401 | Unauthenticated | — |
403 | Denied by policy, separation of duties or role not permitted for the step | — |
404 | Not found / not disclosed | — |
409 | version_conflict, invalid_transition, not_overdue, max_escalation_reached, report_not_ready, duplicate_source_report, duplicate_amendment, idempotency_key_reused or request_in_progress | — |
422 | domain_validation_failed (details per field), code_list_not_configured, policy_not_configured, amendment_mismatch, different_patients, report_not_publishable, safety_block | — |
429 | Rate limited | — |
503 | Dependency unavailable (fail closed): dependency_unavailable with details.dependency | — |
GET/resultsResults inbox
Operation ID: listResults
Authentication: bearer
Parameters
| Name | In | Type | Required | Description |
|---|
state | query | string | no | |
report_type | query | string | no | |
critical | query | boolean | no | |
patient_ref | query | string (uuid) | no | |
source_facility | query | string (uuid) | no | |
current_only | query | boolean | no | |
cursor | query | string | no | |
Responses
| Code | Description | Media type |
|---|
200 | Success | application/json: object
|
400 | Malformed request or missing Idempotency-Key | — |
401 | Unauthenticated | — |
403 | Denied by policy, separation of duties or role not permitted for the step | — |
404 | Not found / not disclosed | — |
409 | version_conflict, invalid_transition, not_overdue, max_escalation_reached, report_not_ready, duplicate_source_report, duplicate_amendment, idempotency_key_reused or request_in_progress | — |
422 | domain_validation_failed (details per field), code_list_not_configured, policy_not_configured, amendment_mismatch, different_patients, report_not_publishable, safety_block | — |
429 | Rate limited | — |
503 | Dependency unavailable (fail closed): dependency_unavailable with details.dependency | — |
GET/results/compareCompare two reports of one patient
Operation ID: compareResults
Authentication: bearer
Parameters
| Name | In | Type | Required | Description |
|---|
left | query | string (uuid) | yes | |
right | query | string (uuid) | yes | |
Responses
| Code | Description | Media type |
|---|
200 | Success | application/json: object
|
400 | Malformed request or missing Idempotency-Key | — |
401 | Unauthenticated | — |
403 | Denied by policy, separation of duties or role not permitted for the step | — |
404 | Not found / not disclosed | — |
409 | version_conflict, invalid_transition, not_overdue, max_escalation_reached, report_not_ready, duplicate_source_report, duplicate_amendment, idempotency_key_reused or request_in_progress | — |
422 | domain_validation_failed (details per field), code_list_not_configured, policy_not_configured, amendment_mismatch, different_patients, report_not_publishable, safety_block | — |
429 | Rate limited | — |
503 | Dependency unavailable (fail closed): dependency_unavailable with details.dependency | — |
GET/results/{id}Report with observations, imaging references and critical case
Operation ID: getResult
Authentication: bearer
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | yes | |
Responses
| Code | Description | Media type |
|---|
200 | Success | application/json: object
|
400 | Malformed request or missing Idempotency-Key | — |
401 | Unauthenticated | — |
403 | Denied by policy, separation of duties or role not permitted for the step | — |
404 | Not found / not disclosed | — |
409 | version_conflict, invalid_transition, not_overdue, max_escalation_reached, report_not_ready, duplicate_source_report, duplicate_amendment, idempotency_key_reused or request_in_progress | — |
422 | domain_validation_failed (details per field), code_list_not_configured, policy_not_configured, amendment_mismatch, different_patients, report_not_publishable, safety_block | — |
429 | Rate limited | — |
503 | Dependency unavailable (fail closed): dependency_unavailable with details.dependency | — |
GET/results/{id}/provenanceSource, custody, history and audit of a report
Operation ID: getProvenance
Authentication: bearer
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | yes | |
Responses
| Code | Description | Media type |
|---|
200 | Success | application/json: object
|
400 | Malformed request or missing Idempotency-Key | — |
401 | Unauthenticated | — |
403 | Denied by policy, separation of duties or role not permitted for the step | — |
404 | Not found / not disclosed | — |
409 | version_conflict, invalid_transition, not_overdue, max_escalation_reached, report_not_ready, duplicate_source_report, duplicate_amendment, idempotency_key_reused or request_in_progress | — |
422 | domain_validation_failed (details per field), code_list_not_configured, policy_not_configured, amendment_mismatch, different_patients, report_not_publishable, safety_block | — |
429 | Rate limited | — |
503 | Dependency unavailable (fail closed): dependency_unavailable with details.dependency | — |
GET/results/{id}/versionsAll versions of a report
Operation ID: getVersions
Authentication: bearer
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | yes | |
Responses
| Code | Description | Media type |
|---|
200 | Success | application/json: object
|
400 | Malformed request or missing Idempotency-Key | — |
401 | Unauthenticated | — |
403 | Denied by policy, separation of duties or role not permitted for the step | — |
404 | Not found / not disclosed | — |
409 | version_conflict, invalid_transition, not_overdue, max_escalation_reached, report_not_ready, duplicate_source_report, duplicate_amendment, idempotency_key_reused or request_in_progress | — |
422 | domain_validation_failed (details per field), code_list_not_configured, policy_not_configured, amendment_mismatch, different_patients, report_not_publishable, safety_block | — |
429 | Rate limited | — |
503 | Dependency unavailable (fail closed): dependency_unavailable with details.dependency | — |
POST/results/{id}/transitionsAdvance the publication workflow (W001)
Operation ID: transitionResult
Authentication: bearer
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | yes | |
Idempotency-Key | header | string | yes | |
Request body (required)
Responses
| Code | Description | Media type |
|---|
200 | Success | application/json: object
|
400 | Malformed request or missing Idempotency-Key | — |
401 | Unauthenticated | — |
403 | Denied by policy, separation of duties or role not permitted for the step | — |
404 | Not found / not disclosed | — |
409 | version_conflict, invalid_transition, not_overdue, max_escalation_reached, report_not_ready, duplicate_source_report, duplicate_amendment, idempotency_key_reused or request_in_progress | — |
422 | domain_validation_failed (details per field), code_list_not_configured, policy_not_configured, amendment_mismatch, different_patients, report_not_publishable, safety_block | — |
429 | Rate limited | — |
503 | Dependency unavailable (fail closed): dependency_unavailable with details.dependency | — |
GET/critical-resultsEscalation board
Operation ID: listCriticalResults
Authentication: bearer
Parameters
| Name | In | Type | Required | Description |
|---|
state | query | string | no | |
overdue | query | boolean | no | |
facility | query | string (uuid) | no | |
cursor | query | string | no | |
Responses
| Code | Description | Media type |
|---|
200 | Success | application/json: object
|
400 | Malformed request or missing Idempotency-Key | — |
401 | Unauthenticated | — |
403 | Denied by policy, separation of duties or role not permitted for the step | — |
404 | Not found / not disclosed | — |
409 | version_conflict, invalid_transition, not_overdue, max_escalation_reached, report_not_ready, duplicate_source_report, duplicate_amendment, idempotency_key_reused or request_in_progress | — |
422 | domain_validation_failed (details per field), code_list_not_configured, policy_not_configured, amendment_mismatch, different_patients, report_not_publishable, safety_block | — |
429 | Rate limited | — |
503 | Dependency unavailable (fail closed): dependency_unavailable with details.dependency | — |
GET/critical-results/{id}Critical result with receipts
Operation ID: getCriticalResult
Authentication: bearer
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | yes | |
Responses
| Code | Description | Media type |
|---|
200 | Success | application/json: object
|
400 | Malformed request or missing Idempotency-Key | — |
401 | Unauthenticated | — |
403 | Denied by policy, separation of duties or role not permitted for the step | — |
404 | Not found / not disclosed | — |
409 | version_conflict, invalid_transition, not_overdue, max_escalation_reached, report_not_ready, duplicate_source_report, duplicate_amendment, idempotency_key_reused or request_in_progress | — |
422 | domain_validation_failed (details per field), code_list_not_configured, policy_not_configured, amendment_mismatch, different_patients, report_not_publishable, safety_block | — |
429 | Rate limited | — |
503 | Dependency unavailable (fail closed): dependency_unavailable with details.dependency | — |
POST/critical-results/{id}/notifyNotify the responsible clinician
Operation ID: notifyCriticalResult
Authentication: bearer
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | yes | |
Idempotency-Key | header | string | yes | |
Request body (required)
Responses
| Code | Description | Media type |
|---|
200 | Success | application/json: object
|
400 | Malformed request or missing Idempotency-Key | — |
401 | Unauthenticated | — |
403 | Denied by policy, separation of duties or role not permitted for the step | — |
404 | Not found / not disclosed | — |
409 | version_conflict, invalid_transition, not_overdue, max_escalation_reached, report_not_ready, duplicate_source_report, duplicate_amendment, idempotency_key_reused or request_in_progress | — |
422 | domain_validation_failed (details per field), code_list_not_configured, policy_not_configured, amendment_mismatch, different_patients, report_not_publishable, safety_block | — |
429 | Rate limited | — |
503 | Dependency unavailable (fail closed): dependency_unavailable with details.dependency | — |
POST/critical-results/{id}/ackAcknowledge with read-back
Operation ID: acknowledgeCriticalResult
Authentication: bearer
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | yes | |
Idempotency-Key | header | string | yes | |
Request body (required)
Responses
| Code | Description | Media type |
|---|
200 | Success | application/json: object
|
400 | Malformed request or missing Idempotency-Key | — |
401 | Unauthenticated | — |
403 | Denied by policy, separation of duties or role not permitted for the step | — |
404 | Not found / not disclosed | — |
409 | version_conflict, invalid_transition, not_overdue, max_escalation_reached, report_not_ready, duplicate_source_report, duplicate_amendment, idempotency_key_reused or request_in_progress | — |
422 | domain_validation_failed (details per field), code_list_not_configured, policy_not_configured, amendment_mismatch, different_patients, report_not_publishable, safety_block | — |
429 | Rate limited | — |
503 | Dependency unavailable (fail closed): dependency_unavailable with details.dependency | — |
POST/critical-results/{id}/escalateEscalate an overdue critical result
Operation ID: escalateCriticalResult
Authentication: bearer
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | yes | |
Idempotency-Key | header | string | yes | |
Request body (required)
Responses
| Code | Description | Media type |
|---|
200 | Success | application/json: object
|
400 | Malformed request or missing Idempotency-Key | — |
401 | Unauthenticated | — |
403 | Denied by policy, separation of duties or role not permitted for the step | — |
404 | Not found / not disclosed | — |
409 | version_conflict, invalid_transition, not_overdue, max_escalation_reached, report_not_ready, duplicate_source_report, duplicate_amendment, idempotency_key_reused or request_in_progress | — |
422 | domain_validation_failed (details per field), code_list_not_configured, policy_not_configured, amendment_mismatch, different_patients, report_not_publishable, safety_block | — |
429 | Rate limited | — |
503 | Dependency unavailable (fail closed): dependency_unavailable with details.dependency | — |
POST/critical-results/{id}/closeClose an acknowledged critical result
Operation ID: closeCriticalResult
Authentication: bearer
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | yes | |
Idempotency-Key | header | string | yes | |
Request body (required)
Responses
| Code | Description | Media type |
|---|
200 | Success | application/json: object
|
400 | Malformed request or missing Idempotency-Key | — |
401 | Unauthenticated | — |
403 | Denied by policy, separation of duties or role not permitted for the step | — |
404 | Not found / not disclosed | — |
409 | version_conflict, invalid_transition, not_overdue, max_escalation_reached, report_not_ready, duplicate_source_report, duplicate_amendment, idempotency_key_reused or request_in_progress | — |
422 | domain_validation_failed (details per field), code_list_not_configured, policy_not_configured, amendment_mismatch, different_patients, report_not_publishable, safety_block | — |
429 | Rate limited | — |
503 | Dependency unavailable (fail closed): dependency_unavailable with details.dependency | — |
GET/amendmentsAmendments
Operation ID: listAmendments
Authentication: bearer
Parameters
| Name | In | Type | Required | Description |
|---|
state | query | string | no | |
report_id | query | string (uuid) | no | |
cursor | query | string | no | |
Responses
| Code | Description | Media type |
|---|
200 | Success | application/json: object
|
400 | Malformed request or missing Idempotency-Key | — |
401 | Unauthenticated | — |
403 | Denied by policy, separation of duties or role not permitted for the step | — |
404 | Not found / not disclosed | — |
409 | version_conflict, invalid_transition, not_overdue, max_escalation_reached, report_not_ready, duplicate_source_report, duplicate_amendment, idempotency_key_reused or request_in_progress | — |
422 | domain_validation_failed (details per field), code_list_not_configured, policy_not_configured, amendment_mismatch, different_patients, report_not_publishable, safety_block | — |
429 | Rate limited | — |
503 | Dependency unavailable (fail closed): dependency_unavailable with details.dependency | — |
POST/amendmentsSubmit a report amendment for review (F003)
Operation ID: submitAmendment
Authentication: bearer
Parameters
| Name | In | Type | Required | Description |
|---|
Idempotency-Key | header | string | yes | |
Request body (required)
Responses
| Code | Description | Media type |
|---|
201 | Created | application/json: object
|
400 | Malformed request or missing Idempotency-Key | — |
401 | Unauthenticated | — |
403 | Denied by policy, separation of duties or role not permitted for the step | — |
404 | Not found / not disclosed | — |
409 | version_conflict, invalid_transition, not_overdue, max_escalation_reached, report_not_ready, duplicate_source_report, duplicate_amendment, idempotency_key_reused or request_in_progress | — |
422 | domain_validation_failed (details per field), code_list_not_configured, policy_not_configured, amendment_mismatch, different_patients, report_not_publishable, safety_block | — |
429 | Rate limited | — |
503 | Dependency unavailable (fail closed): dependency_unavailable with details.dependency | — |
POST/amendments/{id}/transitionsAdvance an amendment (W003)
Operation ID: transitionAmendment
Authentication: bearer
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | yes | |
Idempotency-Key | header | string | yes | |
Request body (required)
Responses
| Code | Description | Media type |
|---|
200 | Success | application/json: object
|
400 | Malformed request or missing Idempotency-Key | — |
401 | Unauthenticated | — |
403 | Denied by policy, separation of duties or role not permitted for the step | — |
404 | Not found / not disclosed | — |
409 | version_conflict, invalid_transition, not_overdue, max_escalation_reached, report_not_ready, duplicate_source_report, duplicate_amendment, idempotency_key_reused or request_in_progress | — |
422 | domain_validation_failed (details per field), code_list_not_configured, policy_not_configured, amendment_mismatch, different_patients, report_not_publishable, safety_block | — |
429 | Rate limited | — |
503 | Dependency unavailable (fail closed): dependency_unavailable with details.dependency | — |
GET/code-lists/{list}Controlled code list
Operation ID: getCodeList
Authentication: bearer
Parameters
| Name | In | Type | Required | Description |
|---|
list | path | "report_type" | "clinical_responsibility" | "imaging_modality" | yes | |
Responses
| Code | Description | Media type |
|---|
200 | Success | application/json: object
|
400 | Malformed request or missing Idempotency-Key | — |
401 | Unauthenticated | — |
403 | Denied by policy, separation of duties or role not permitted for the step | — |
404 | Not found / not disclosed | — |
409 | version_conflict, invalid_transition, not_overdue, max_escalation_reached, report_not_ready, duplicate_source_report, duplicate_amendment, idempotency_key_reused or request_in_progress | — |
422 | domain_validation_failed (details per field), code_list_not_configured, policy_not_configured, amendment_mismatch, different_patients, report_not_publishable, safety_block | — |
429 | Rate limited | — |
503 | Dependency unavailable (fail closed): dependency_unavailable with details.dependency | — |
POST/code-lists/{list}Upsert code list entries
Operation ID: upsertCodeList
Authentication: bearer
Parameters
| Name | In | Type | Required | Description |
|---|
list | path | "report_type" | "clinical_responsibility" | "imaging_modality" | yes | |
Idempotency-Key | header | string | yes | |
Request body (required)
Responses
| Code | Description | Media type |
|---|
200 | Success | application/json: object
|
400 | Malformed request or missing Idempotency-Key | — |
401 | Unauthenticated | — |
403 | Denied by policy, separation of duties or role not permitted for the step | — |
404 | Not found / not disclosed | — |
409 | version_conflict, invalid_transition, not_overdue, max_escalation_reached, report_not_ready, duplicate_source_report, duplicate_amendment, idempotency_key_reused or request_in_progress | — |
422 | domain_validation_failed (details per field), code_list_not_configured, policy_not_configured, amendment_mismatch, different_patients, report_not_publishable, safety_block | — |
429 | Rate limited | — |
503 | Dependency unavailable (fail closed): dependency_unavailable with details.dependency | — |
GET/policyJurisdiction critical-result policy
Operation ID: getPolicy
Authentication: bearer
Responses
| Code | Description | Media type |
|---|
200 | Success | application/json: object
|
400 | Malformed request or missing Idempotency-Key | — |
401 | Unauthenticated | — |
403 | Denied by policy, separation of duties or role not permitted for the step | — |
404 | Not found / not disclosed | — |
409 | version_conflict, invalid_transition, not_overdue, max_escalation_reached, report_not_ready, duplicate_source_report, duplicate_amendment, idempotency_key_reused or request_in_progress | — |
422 | domain_validation_failed (details per field), code_list_not_configured, policy_not_configured, amendment_mismatch, different_patients, report_not_publishable, safety_block | — |
429 | Rate limited | — |
503 | Dependency unavailable (fail closed): dependency_unavailable with details.dependency | — |
POST/policySet the jurisdiction critical-result policy
Operation ID: setPolicy
Authentication: bearer
Parameters
| Name | In | Type | Required | Description |
|---|
Idempotency-Key | header | string | yes | |
Request body (required)
Responses
| Code | Description | Media type |
|---|
200 | Success | application/json: object
|
400 | Malformed request or missing Idempotency-Key | — |
401 | Unauthenticated | — |
403 | Denied by policy, separation of duties or role not permitted for the step | — |
404 | Not found / not disclosed | — |
409 | version_conflict, invalid_transition, not_overdue, max_escalation_reached, report_not_ready, duplicate_source_report, duplicate_amendment, idempotency_key_reused or request_in_progress | — |
422 | domain_validation_failed (details per field), code_list_not_configured, policy_not_configured, amendment_mismatch, different_patients, report_not_publishable, safety_block | — |
429 | Rate limited | — |
503 | Dependency unavailable (fail closed): dependency_unavailable with details.dependency | — |
POST/maintenance/drain-outboxReport pending outbox events (no sink configured: nothing is claimed delivered)
Operation ID: drainOutbox
Authentication: bearer
Parameters
| Name | In | Type | Required | Description |
|---|
Idempotency-Key | header | string | yes | |
Responses
| Code | Description | Media type |
|---|
200 | Success | application/json: object
|
400 | Malformed request or missing Idempotency-Key | — |
401 | Unauthenticated | — |
403 | Denied by policy, separation of duties or role not permitted for the step | — |
404 | Not found / not disclosed | — |
409 | version_conflict, invalid_transition, not_overdue, max_escalation_reached, report_not_ready, duplicate_source_report, duplicate_amendment, idempotency_key_reused or request_in_progress | — |
422 | domain_validation_failed (details per field), code_list_not_configured, policy_not_configured, amendment_mismatch, different_patients, report_not_publishable, safety_block | — |
429 | Rate limited | — |
503 | Dependency unavailable (fail closed): dependency_unavailable with details.dependency | — |
GET/report-catalogAvailable reports
Operation ID: reportCatalog
Authentication: bearer
Responses
| Code | Description | Media type |
|---|
200 | Success | application/json: object
|
400 | Malformed request or missing Idempotency-Key | — |
401 | Unauthenticated | — |
403 | Denied by policy, separation of duties or role not permitted for the step | — |
404 | Not found / not disclosed | — |
409 | version_conflict, invalid_transition, not_overdue, max_escalation_reached, report_not_ready, duplicate_source_report, duplicate_amendment, idempotency_key_reused or request_in_progress | — |
422 | domain_validation_failed (details per field), code_list_not_configured, policy_not_configured, amendment_mismatch, different_patients, report_not_publishable, safety_block | — |
429 | Rate limited | — |
503 | Dependency unavailable (fail closed): dependency_unavailable with details.dependency | — |
GET/reports/{reportId}Run report R001..R003
Operation ID: runReport
Authentication: bearer
Parameters
| Name | In | Type | Required | Description |
|---|
reportId | path | "OHN-11-R001" | "OHN-11-R002" | "OHN-11-R003" | yes | |
facility | query | string (uuid) | no | |
severity | query | "critical" | no | |
result_type | query | string | no | |
patient_scope | query | string (uuid) | no | |
jurisdiction | query | string (uuid) | no | |
period_from | query | string | no | |
period_to | query | string | no | |
cursor | query | string | no | |
Responses
| Code | Description | Media type |
|---|
200 | Success | application/json: object
|
400 | Malformed request or missing Idempotency-Key | — |
401 | Unauthenticated | — |
403 | Denied by policy, separation of duties or role not permitted for the step | — |
404 | Not found / not disclosed | — |
409 | version_conflict, invalid_transition, not_overdue, max_escalation_reached, report_not_ready, duplicate_source_report, duplicate_amendment, idempotency_key_reused or request_in_progress | — |
422 | domain_validation_failed (details per field), code_list_not_configured, policy_not_configured, amendment_mismatch, different_patients, report_not_publishable, safety_block | — |
429 | Rate limited | — |
503 | Dependency unavailable (fail closed): dependency_unavailable with details.dependency | — |
POST/reports/{reportId}/exportCreate a signed single-use export
Operation ID: exportReport
Authentication: bearer
Parameters
| Name | In | Type | Required | Description |
|---|
reportId | path | "OHN-11-R001" | "OHN-11-R002" | "OHN-11-R003" | yes | |
Idempotency-Key | header | string | yes | |
Request body (required)
Responses
| Code | Description | Media type |
|---|
201 | Created | application/json: object
|
400 | Malformed request or missing Idempotency-Key | — |
401 | Unauthenticated | — |
403 | Denied by policy, separation of duties or role not permitted for the step | — |
404 | Not found / not disclosed | — |
409 | version_conflict, invalid_transition, not_overdue, max_escalation_reached, report_not_ready, duplicate_source_report, duplicate_amendment, idempotency_key_reused or request_in_progress | — |
422 | domain_validation_failed (details per field), code_list_not_configured, policy_not_configured, amendment_mismatch, different_patients, report_not_publishable, safety_block | — |
429 | Rate limited | — |
503 | Dependency unavailable (fail closed): dependency_unavailable with details.dependency | — |
GET/exports/{token}Download an export once
Operation ID: downloadExport
Authentication: bearer
Parameters
| Name | In | Type | Required | Description |
|---|
token | path | string | yes | |
Responses
| Code | Description | Media type |
|---|
200 | The export file (single use, five minutes) | text/csv: string (binary)
application/pdf: string (binary)
|
400 | Malformed request or missing Idempotency-Key | — |
401 | Unauthenticated | — |
403 | Denied by policy, separation of duties or role not permitted for the step | — |
404 | Not found / not disclosed | — |
409 | version_conflict, invalid_transition, not_overdue, max_escalation_reached, report_not_ready, duplicate_source_report, duplicate_amendment, idempotency_key_reused or request_in_progress | — |
410 | Export expired or already downloaded | — |
422 | domain_validation_failed (details per field), code_list_not_configured, policy_not_configured, amendment_mismatch, different_patients, report_not_publishable, safety_block | — |
429 | Rate limited | — |
503 | Dependency unavailable (fail closed): dependency_unavailable with details.dependency | — |
Schemas
IngestCommand
| Name | Type | Required | Description |
|---|
patient_ref | string (uuid) | yes | |
source_facility | string (uuid) | yes | |
specimen_ref | string (uuid) | no | |
report_type | string | yes | |
report_status | "registered" | "partial" | "preliminary" | "final" | "amended" | "corrected" | "appended" | "cancelled" | "entered_in_error" | yes | |
issued_at | string (date-time) | yes | |
file_or_payload | string (uuid) | yes | |
payload_sha256 | string | no | |
source_report_id | string | yes | |
ordering_org | string (uuid) | no | |
replaces_report_id | string (uuid) | no | |
source_interpretation | string | no | |
critical_declared | boolean | no | |
observations | array of IngestCommand.observations.item | no | |
imaging_studies | array of IngestCommand.imaging_studies.item | no | |
TransitionCommand
| Name | Type | Required | Description |
|---|
to_state | "validated" | "patient_matched" | "released" | "available" | "rejected" | yes | |
expected_version | integer | yes | |
reason | string | yes | |
NotifyCommand
| Name | Type | Required | Description |
|---|
responsible_clinician | string (uuid) | yes | |
expected_version | integer | yes | |
reason | string | yes | |
AckCommand
| Name | Type | Required | Description |
|---|
result_ref | string (uuid) | no | |
acknowledged_by | string (uuid) | no | |
acknowledged_at | string (date-time) | no | |
readback_notes | string | yes | |
clinical_responsibility | string | yes | |
expected_version | integer | yes | |
EscalateCommand
| Name | Type | Required | Description |
|---|
escalate_to | string (uuid) | yes | |
expected_version | integer | yes | |
reason | string | yes | |
CloseCommand
| Name | Type | Required | Description |
|---|
expected_version | integer | yes | |
reason | string | yes | |
AmendmentCommand
| Name | Type | Required | Description |
|---|
original_report_id | string (uuid) | yes | |
replacement_report_id | string (uuid) | yes | |
amendment_reason | string | yes | |
reviewer | string (uuid) | yes | |
AmendmentTransitionCommand
| Name | Type | Required | Description |
|---|
to_state | "version_linked" | "prior_version_marked" | "notified" | yes | |
expected_version | integer | yes | |
reason | string | yes | |
PolicyCommand
| Name | Type | Required | Description |
|---|
critical_ack_window_minutes | integer | yes | |
max_escalation_level | integer | yes | |
approval_reference | string | yes | |
expected_version | integer | no | |
IngestCommand.observations.item defined inline
| Name | Type | Required | Description |
|---|
code_system | "loinc" | "snomed_ct" | "local" | yes | |
code | string | yes | |
code_display | string | no | |
value_number | number | no | |
value_text | string | no | |
unit | string | no | |
ref_low | number | no | |
ref_high | number | no | |
source_flag | "normal" | "abnormal" | "critical_low" | "critical_high" | "critical" | "unknown" | no | |
IngestCommand.imaging_studies.item defined inline
| Name | Type | Required | Description |
|---|
study_instance_uid | string | yes | |
accession_number | string | no | |
modality | string | yes | |
locator_ref | string (uuid) | yes | |
series_count | integer | no | |
ExportCommand.filters defined inline
| Name | Type | Required | Description |
|---|
facility | string (uuid) | no | |
severity | "critical" | no | |
result_type | string | no | |
patient_scope | string (uuid) | no | |
jurisdiction | string (uuid) | no | |
period_from | string | no | |
period_to | string | no | |
CodeListCommand.entries.item defined inline
| Name | Type | Required | Description |
|---|
code | string | yes | |
label | string | yes | |
active | boolean | no | |