Generated Narrative: CapabilityStatement MyFHIRServerCapabilityStatement My FHIR Server Capability Statement Implementation Guide Version: 0.1.0 FHIR Version: 4.0.1 Supported Formats: xml, json Supported Patch Formats: application/json-patch+json Published on: 2025-10-24 Published by: Kimsber Note to Implementers: FHIR Capabilities Any FHIR capability may be 'allowed' by the system unless explicitly marked as 'SHALL NOT'. A few items are marked as MAY in the Implementation Guide to highlight their potential relevance to the use case. FHIR RESTful Capabilities Mode: server Capabilities by Resource/Profile Summary The summary table lists the resources that are part of this configuration, and for each resource it lists: The relevant profiles (if any) The interactions supported by each resource (Read, Search, Update, and Create, are always shown, while VRead, Patch, Delete, History on Instance, or History on Type are only present if at least one of the resources has support for them. The required, recommended, and some optional search parameters (if any). The linked resources enabled for _include The other resources enabled for _revinclude The operations on the resource (if any) Resource Type Profile R S U C Searches _include _revinclude Operations Patient http://hl7.org/fhir/StructureDefinition/Patient Y Y _id, birthdate, gender, identifier, name $everything Bundle http://hl7.org/fhir/StructureDefinition/Bundle Y Y _id, identifier CarePlan http://hl7.org/fhir/StructureDefinition/CarePlan Y Y patient, category, date, status Condition http://hl7.org/fhir/StructureDefinition/Condition Y Y _id, clinical-status, code, subject, onset-date, abatement-date, severity Encounter http://hl7.org/fhir/StructureDefinition/Encounter Y Y _id, class, date, identifier, location, subject, status Goal http://hl7.org/fhir/StructureDefinition/Goal Y Y patient, lifecycle-status, target-date, description MedicationAdministration http://hl7.org/fhir/StructureDefinition/MedicationAdministration Y Y code, identifier, medication, patient, status, context, device, effective-time, performer, reason-given, reason-not-given, request, subject Observation http://hl7.org/fhir/StructureDefinition/Observation Y Y _id, category, code, date, performer, status, subject, patient, _lastUpdated Organization http://hl7.org/fhir/StructureDefinition/Organization Y Y _id, identifier, name, type Practitioner http://hl7.org/fhir/StructureDefinition/Practitioner Y Y _id, identifier, name PractitionerRole http://hl7.org/fhir/StructureDefinition/PractitionerRole Y Y _id, identifier, specialty Procedure http://hl7.org/fhir/StructureDefinition/Procedure Y Y _id, code, status, subject, date QuestionnaireResponse http://hl7.org/fhir/StructureDefinition/QuestionnaireResponse Y Y Y Y _id, patient, status, authored, questionnaire, subject $extract Questionnaire http://hl7.org/fhir/StructureDefinition/Questionnaire Y Y Y Y identifier, title $populate, $render Resource Conformance: unspecified Patient Base System Profile Patient Profile Conformance SHOULD Reference Policy Interaction summary SHALL support read, search-type. Search Parameters Conformance Parameter Type Documentation SHOULD _id token SHOULD birthdate date SHOULD gender token SHOULD identifier token SHOULD name string Extended Operations Conformance Operation Documentation SHOULD $everything Resource Conformance: unspecified Bundle Base System Profile Bundle Profile Conformance SHOULD Reference Policy Interaction summary SHALL support read, search-type. Search Parameters Conformance Parameter Type Documentation SHOULD _id token SHOULD identifier token Resource Conformance: unspecified CarePlan Base System Profile CarePlan Profile Conformance SHOULD Reference Policy Interaction summary SHALL support read, search-type. Search Parameters Conformance Parameter Type Documentation SHOULD patient reference SHOULD category token SHOULD date date SHOULD status token Resource Conformance: unspecified Condition Base System Profile Condition Profile Conformance SHOULD Reference Policy Interaction summary SHALL support read, search-type. Search Parameters Conformance Parameter Type Documentation SHOULD _id token SHOULD clinical-status token SHOULD code token SHOULD subject reference SHOULD onset-date date SHOULD abatement-date date SHOULD severity token Resource Conformance: unspecified Encounter Base System Profile Encounter Profile Conformance SHOULD Reference Policy Interaction summary SHALL support read, search-type. Search Parameters Conformance Parameter Type Documentation SHOULD _id token SHOULD class token SHOULD date date SHOULD identifier token SHOULD location reference SHOULD subject reference SHOULD status token Resource Conformance: unspecified Goal Base System Profile Goal Profile Conformance SHOULD Reference Policy Interaction summary SHALL support read, search-type. Search Parameters Conformance Parameter Type Documentation SHOULD patient reference SHOULD lifecycle-status token SHOULD target-date date SHOULD description token Resource Conformance: unspecified MedicationAdministration Base System Profile MedicationAdministration Profile Conformance SHOULD Reference Policy Interaction summary SHALL support read, search-type. Search Parameters Conformance Parameter Type Documentation SHOULD code token SHOULD identifier token SHOULD medication reference SHOULD patient reference SHOULD status token SHOULD context reference SHOULD device reference SHOULD effective-time date SHOULD performer reference SHOULD reason-given token SHOULD reason-not-given token SHOULD request reference SHOULD subject reference Resource Conformance: unspecified Observation Base System Profile Observation Profile Conformance SHOULD Reference Policy Interaction summary SHALL support read, search-type. Search Parameters Conformance Parameter Type Documentation SHOULD _id token SHOULD category token SHOULD code token SHOULD date date SHOULD performer reference SHOULD status token SHOULD subject reference SHOULD patient reference SHOULD _lastUpdated date Resource Conformance: unspecified Organization Base System Profile Organization Profile Conformance SHOULD Reference Policy Interaction summary SHALL support read, search-type. Search Parameters Conformance Parameter Type Documentation SHOULD _id token SHOULD identifier token SHOULD name string SHOULD type token Resource Conformance: unspecified Practitioner Base System Profile Practitioner Profile Conformance SHOULD Reference Policy Interaction summary SHALL support read, search-type. Search Parameters Conformance Parameter Type Documentation SHOULD _id token SHOULD identifier token SHOULD name string Resource Conformance: unspecified PractitionerRole Base System Profile PractitionerRole Profile Conformance SHOULD Reference Policy Interaction summary SHALL support read, search-type. Search Parameters Conformance Parameter Type Documentation SHOULD _id token SHOULD identifier token SHOULD specialty token Resource Conformance: unspecified Procedure Base System Profile Procedure Profile Conformance SHOULD Reference Policy Interaction summary SHALL support read, search-type. Search Parameters Conformance Parameter Type Documentation SHOULD _id token SHOULD code token SHOULD status token SHOULD subject reference SHOULD date date Resource Conformance: unspecified QuestionnaireResponse Base System Profile QuestionnaireResponse Profile Conformance SHOULD Reference Policy Interaction summary SHALL support read, search-type, create. SHOULD support update. Search Parameters Conformance Parameter Type Documentation SHOULD _id token SHOULD patient reference SHOULD status token SHOULD authored date SHOULD questionnaire reference SHOULD subject reference Extended Operations Conformance Operation Documentation SHALL $extract 伺服器必須實現 $extract 操作以： 接收已填寫的 QuestionnaireResponse 解析 Questionnaire 中的 extraction extension 根據提取定義轉換為結構化 FHIR 資源 返回 Bundle 或單一資源 技術要求： • 支援 ObservationExtract（最常見） • 支援 DefinitionExtract（複雜資源） • 支援 TemplateExtract（預設樣板） • StructureMapExtract（高級轉換） 提取優先級： 簡單 Observation 提取（計分、測量） 複雜資源提取（診斷/藥物） 自動計算欄位（如 BMI） 交易 Bundle 生成 回傳格式： { "resourceType": "Bundle", "type": "transaction", "entry": [ { "resource": { "resourceType": "Observation", "code": { "coding": [{ "code": "PHQ9", "system": "http://loinc.org" }] }, "value": { "integer": 12 }, "derivedFrom": [{ "reference": "QuestionnaireResponse/qr123" }] } } ] } 這是 SDC 工作流的最終步驟，用於自動導入結構化資料 Resource Conformance: unspecified Questionnaire Base System Profile Questionnaire Profile Conformance SHOULD Reference Policy Interaction summary SHALL support read, search-type. SHOULD support create, update. Search Parameters Conformance Parameter Type Documentation SHOULD identifier token SHOULD title string Extended Operations Conformance Operation Documentation SHALL $populate 伺服器必須實現 $populate 操作以： 接收 Client 的預填請求 根據 questionnaire.item.definition 查詢患者資料 根據 FHIRPath expression 預填答案 返回已預填的 QuestionnaireResponse 技術要求： • FHIRPath 引擎支援 • 資料查詢引擎（能查詢 Patient/Observation 等資源） • Extension 解析（processingPriority/itemWeight/calculatedExpression） 實現優先級： 基本預填（根據 definition 字段） FHIRPath 評估 answerExpression 支援 複雜表達式與條件 回傳格式： { "resourceType": "QuestionnaireResponse", "questionnaire": "Questionnaire/q1", "status": "in-progress", "item": [ { "linkId": "patient-name", "answer": [{ "valueString": "[自動填入的病人名稱]" }] } ] } MAY $render 伺服器可選支援 $render 操作以： • 將 Questionnaire 轉換為可用格式（HTML/PDF/JSON） • 應用主題樣式和客製化呈現 • 支援多語言 大多數 Client 會自行實現渲染，此操作非必要
此 CapabilityStatement 定義了伺服端必須支援的 FHIR RESTful API 功能
伺服器必須實現 $extract 操作以： 1. 接收已填寫的 QuestionnaireResponse 2. 解析 Questionnaire 中的 extraction extension 3. 根據提取定義轉換為結構化 FHIR 資源 4. 返回 Bundle 或單一資源 技術要求： • 支援 ObservationExtract（最常見） • 支援 DefinitionExtract（複雜資源） • 支援 TemplateExtract（預設樣板） • StructureMapExtract（高級轉換） 提取優先級： 1. 簡單 Observation 提取（計分、測量） 2. 複雜資源提取（診斷/藥物） 3. 自動計算欄位（如 BMI） 4. 交易 Bundle 生成 回傳格式： { "resourceType": "Bundle", "type": "transaction", "entry": [ { "resource": { "resourceType": "Observation", "code": { "coding": [{ "code": "PHQ9", "system": "http://loinc.org" }] }, "value": { "integer": 12 }, "derivedFrom": [{ "reference": "QuestionnaireResponse/qr123" }] } } ] } 這是 SDC 工作流的最終步驟，用於自動導入結構化資料
伺服器必須實現 $populate 操作以： 1. 接收 Client 的預填請求 2. 根據 questionnaire.item.definition 查詢患者資料 3. 根據 FHIRPath expression 預填答案 4. 返回已預填的 QuestionnaireResponse 技術要求： • FHIRPath 引擎支援 • 資料查詢引擎（能查詢 Patient/Observation 等資源） • Extension 解析（processingPriority/itemWeight/calculatedExpression） 實現優先級： 1. 基本預填（根據 definition 字段） 2. FHIRPath 評估 3. answerExpression 支援 4. 複雜表達式與條件 回傳格式： { "resourceType": "QuestionnaireResponse", "questionnaire": "Questionnaire/q1", "status": "in-progress", "item": [ { "linkId": "patient-name", "answer": [{ "valueString": "[自動填入的病人名稱]" }] } ] }
伺服器可選支援 $render 操作以： • 將 Questionnaire 轉換為可用格式（HTML/PDF/JSON） • 應用主題樣式和客製化呈現 • 支援多語言 大多數 Client 會自行實現渲染，此操作非必要