Lab Endpoints
Lab Network exposes FHIR R4 endpoints for laboratory ordering, status tracking, result retrieval, and event notifications.
Endpoints map to FHIR resources and stages in the order-to-result workflow. Use the Order API to understand resource structure and field-level details.
Overview
Lab Network uses standard FHIR R4 resources to represent laboratory workflows, such as:
- Submit orders
- Retrieve orders and track status
- Retrieve results
- Access documents
- Receive event-driven notifications
All endpoints require OAuth 2.0 authentication and use application/fhir+json unless otherwise specified.
Core Resources
The following FHIR resources are used across Lab Network workflows.
| Resource | Purpose |
|---|---|
RequestGroup | Represents the complete laboratory order |
ServiceRequest | Represents individual tests within an order |
Specimen | Describes collected sample details |
DiagnosticReport | Represents the overall lab report |
Observation | Contains discrete result values |
DocumentReference | References document-based results |
Binary | Provides access to downloadable report files |
Subscription | Enables event-driven notifications |
OperationOutcome | Represents validation and processing errors |
Order Endpoints
POST /fhir/R4/RequestGroup
GET /fhir/R4/RequestGroup/{id}
GET /fhir/R4/RequestGroup?patient={patient-id}Use these endpoints to submit, retrieve, and search laboratory orders.
Example Request
POST /fhir/R4/RequestGroup
Content-Type: application/fhir+json
Authorization: Bearer {access_token}{
"resourceType": "RequestGroup",
"status": "active",
"intent": "order",
"subject": {
"reference": "Patient/12345"
},
"author": {
"reference": "Practitioner/67890"
}
}Result Endpoints
GET /fhir/R4/DiagnosticReport?based-on=RequestGroup/{order-id}
GET /fhir/R4/Observation?based-on=RequestGroup/{order-id}Use these endpoints to retrieve structured results associated with an order.
Example Response
{
"resourceType": "DiagnosticReport",
"status": "final",
"subject": {
"reference": "Patient/12345"
}
}Document Endpoints
GET /fhir/R4/DocumentReference?subject=Patient/{patient-id}&category=laboratory
GET /fhir/R4/Binary/{id}Use these endpoints to retrieve document-based results and file content.
Subscription Endpoint
POST /fhir/R4/SubscriptionUse this endpoint to register for event-driven notifications.
Subscriptions support:
- Order status updates
- Result availability
Example Payload
{
"resourceType": "Subscription",
"status": "active",
"criteria": "DiagnosticReport?status=final",
"channel": {
"type": "rest-hook",
"endpoint": "https://client.example.com/webhook",
"payload": "application/fhir+json"
}
}Workflow Mapping
Follow this sequence to implement a typical workflow:
- Submit an order using
RequestGroup - Retrieve or monitor order status
- Retrieve
DiagnosticReportwhen results are available - Retrieve associated
Observationresources - Retrieve document-based results using
DocumentReferenceandBinary - Optionally use
Subscriptionfor event-driven updates
Resources are linked through FHIR relationships to maintain traceability across each step.
Error Responses
Endpoints return OperationOutcome resources when validation or processing fails.
Your system must parse and handle OperationOutcome responses as part of normal API usage.
Example Error Response
{
"resourceType": "OperationOutcome",
"issue": [
{
"severity": "error",
"code": "invalid",
"diagnostics": "Invalid or missing required field"
}
]
}
Summary
Lab Network endpoints provide access to laboratory ordering and result retrieval using FHIR R4.
Use these endpoints with the Order API and API Implementation guides to build end-to-end laboratory workflows.
Updated about 17 hours ago
