Template Profile¶
| Canonical | ../StructureDefinition/nexus-template-list |
|---|---|
| Status | draft · 1.26.0 |
| Base | List (constraint) |
| Source | FSH · JSON |
A reusable template: a List that names and identifies the template, carrying the resources it
produces as prototypes inside a contained transaction Bundle.
Examples
Specialist Referral Letter
A one-entry template -- a List whose single contained prototype is the Composition a specialist referral letter will become. The prototype carries no subject because a template is about no patient; its date, author and title are the template's OWN, and are overwritten when a letter is made from it. The merge tokens in the section narrative are rendered by the letter composer, not by FHIR
List/nexus-template-letter-example — claims conformance to Template Profile
{
"resourceType": "List",
"id": "nexus-template-letter-example",
"meta": {
"profile": [
"../StructureDefinition/nexus-template-list"
]
},
"text": {
"status": "generated",
"div": "<div xmlns="http://www.w3.org/1999/xhtml"><p>Specialist Referral Letter template. Its prototypes ride in a contained transaction Bundle: one entry, the Composition a referral letter will become, with the POST that instantiating performs. The List names and identifies the template; its subject is a PLACEHOLDER carrying a population expression, because a template is about nobody until it is used.</p></div>"
},
"contained": [
{
"resourceType": "Bundle",
"id": "bundle",
"type": "transaction",
"entry": [
{
"fullUrl": "urn:uuid:3d41b6c7-0000-4000-8000-000000000001",
"resource": {
"resourceType": "Composition",
"text": {
"status": "generated",
"div": "<div xmlns="http://www.w3.org/1999/xhtml"><p>Prototype of a specialist referral letter.</p></div>"
},
"status": "preliminary",
"type": {
"coding": [
{
"system": "http://loinc.org",
"code": "51852-2",
"display": "Letter"
}
]
},
"date": "2026-08-18T09:00:00Z",
"author": [
{
"display": "Cedarbrook Family Health"
}
],
"title": "Specialist Referral Letter",
"section": [
{
"text": {
"status": "additional",
"div": "<div xmlns="http://www.w3.org/1999/xhtml"><p>{{clinic.name}}</p><p>{{clinic.address}}</p><p>{{global.todaysDate}}</p><p>Dear Colleague,</p><p>I would be grateful for your assessment of {{patient.fullName}} (DOB {{patient.dob}}, {{patient.healthNumber}}).</p><p>Reason for referral:</p><p>Sincerely,</p><p>{{provider.fullName}}{{provider.credentials}}</p></div>"
}
}
]
},
"request": {
"method": "POST",
"url": "Composition"
}
}
]
}
],
"identifier": [
{
"system": "../NamingSystem/nexus-template",
"value": "specialist-referral-letter"
}
],
"status": "current",
"mode": "working",
"subject": {
"extension": [
{
"url": "http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaire-templateExtractValue",
"valueString": "%patient.reference"
}
],
"display": "Filled in when the template is used"
},
"title": "Specialist Referral Letter",
"date": "2026-08-18T09:00:00Z",
"entry": [
{
"item": {
"reference": "#bundle",
"display": "Prototype Bundle: the letter this template produces"
}
}
]
}