LTCOperationOutcomeFeeAudit
type: StructureDefinition
node role: treeRoot
resource.id:
  value: LTCOperationOutcomeFeeAudit
domain resource.text:
  narrative.status:
    value: extensions
  narrative.div: Generated Narrative: StructureDefinition LTCOperationOutcomeFeeAudit Name Flags Card. Type Description & Constraints<img src="[binary]" alt="doco" style="background-color: inherit"/> OperationOutcome 0..* OperationOutcome 支付審核系統之申報檢核結果；API 交易層級之回覆結果代碼（rtncode）由 VS_TW_LTC_FeeAuditRtnCode（vs-tw-ltc-feeaudit-rtncode）表達，例：0 成功回傳、1 Request 輸入參數錯誤、40 查無資料、90 發生無法預期錯誤；本 Profile 之 issue 則表達個別服務紀錄之檢核錯誤（err_code／err_message） #xD; Slices for extension 0..* Extension Extension Slice: Unordered, Open by value:url #xD; extension:caseNo S 0..1 string 核銷案號（case_no，最長 30 碼）；OperationOutcome 無 identifier 元素，故沿用既有 Extension ExtTWLTCExportCaseNo（Ext-TW-LTC-Export-CaseNo）承載案件編號，該 Extension 之 ^context 已涵蓋 OperationOutcome，於本 Profile 中其語意為支付審核系統之核銷案號 URL: http://ltc-ig.fhir.tw/StructureDefinition/Ext-TW-LTC-Export-CaseNo #xD; issue S 1..* BackboneElement 檢核錯誤項目；每一筆錯誤訊息（err_info／exception_records／delete_exception_records）對應一個 issue，同一筆服務紀錄有多筆錯誤時以多個 issue 表達 #xD; severity S 1..1 code 錯誤嚴重程度；因檢核未通過而導致該筆服務紀錄申報、分案或刪除失敗者，使用 error #xD; code S 1..1 code FHIR 問題類型代碼；欄位必填或長度／格式檢核（E1xxx、E2xxx）建議使用 required 或 value，資料查詢與寫入異常（E4xxx）建議使用 not-found 或 processing，審核規則與支付碼專屬檢核（E5xxx、EBA／EBC／ECB／EGA／EOT／ESC 系列）建議使用 business-rule #xD; details S 1..1 CodeableConcept 錯誤內容，承載回覆明細之錯誤碼（err_code，最長 5 碼）與錯誤原因（err_message，最長 200 字） #xD; coding S 1..1 Coding 錯誤碼（err_code），綁定支付審查錯誤代碼值集 VS_TW_LTC_FeeAuditErrorCode，例：E1001（服務紀錄識別碼不可空白）、E4015（單位已執行申報確認通知，不在受理新的服務紀錄申報）、E4032（此筆服務紀錄不存在） Binding: 支付審查－錯誤代碼 (extensible) #xD; text S 0..1 string 錯誤原因（err_message）之顯示文字 #xD; diagnostics S 0..1 string 錯誤原因原文或補充說明，可放回覆明細之 err_message 全文，或 API 層級之回覆訊息（errmsg）、批次處理結果（batch_proc_result）等敘述文字 #xD; expression S 0..* string 指向出錯的服務紀錄識別碼（objid），即 err_record.objid、exception_records.objid 或 delete_exception_records.objid。表述時須將實際的 objid 值寫入條件，方能唯一指出是哪一筆服務紀錄，例：Claim.identifier.where(system='http://ltc-ig.fhir.tw/identifier/feeaudit/objid' and value='882601914')；僅寫出路徑而未帶入 objid 值者無法定位錯誤來源 #xD; <img src="[binary]" alt="doco" style="background-…
structure definition.url:
  value: http://ltc-ig.fhir.tw/StructureDefinition/LTCOperationOutcomeFeeAudit
structure definition.version:
  value: 1.0.0
structure definition.name:
  value: LTCOperationOutcomeFeeAudit
structure definition.title:
  value: 長照支付審查－申報檢核結果
structure definition.status:
  value: draft
structure definition.date:
  value: 2026-07-29T07:47:19+00:00
structure definition.publisher:
  value: 經濟部產業發展署
structure definition.contact:
  index: 0
  contact detail.name:
    value: 經濟部產業發展署
  contact detail.telecom:
    index: 0
    contact point.system:
      value: url
    contact point.value:
      value: https://www.ida.gov.tw/
structure definition.description:
  value: 此 Profile 說明本 IG 如何進一步定義 FHIR 的 OperationOutcome Resource，以呈現衛生福利部支付審核系統（照管平台）回覆的服務紀錄檢核錯誤與 API 回覆結果代碼。適用情境包含：（1）「服務記錄申報」（FeeApply）之回覆明細中的錯誤服務記錄（err_record），每筆含識別碼（objid）與多筆錯誤訊息（err_info：err_code 錯誤碼、err_message 錯誤原因）；（2）「(查詢A) 申報結果查詢」回覆之分案異常資料（exception_records）與服務紀錄刪除失敗資料（delete_exception_records），其結構同為 objid、err_code、err_message；（3）API 交易層級之回覆結果代碼（rtncode）與回覆訊息（errmsg）。每一筆錯誤訊息（err_info）對應一個 OperationOutcome.issue。
structure definition.fhir version:
  value: 4.0.1
structure definition.mapping:
  index: 0
  structure definition.mapping.identity:
    value: rim
  structure definition.mapping.uri:
    value: http://hl7.org/v3
  structure definition.mapping.name:
    value: RIM Mapping
structure definition.mapping:
  index: 1
  structure definition.mapping.identity:
    value: v2
  structure definition.mapping.uri:
    value: http://hl7.org/v2
  structure definition.mapping.name:
    value: HL7 v2 Mapping
structure definition.kind:
  value: resource
structure definition.abstract:
  value: false
structure definition.type:
  value: OperationOutcome
structure definition.base definition:
  value: http://hl7.org/fhir/StructureDefinition/OperationOutcome
  link: http://hl7.org/fhir/StructureDefinition/OperationOutcome
structure definition.derivation:
  value: constraint
structure definition.snapshot:
  element.extension:
    index: 0
    extension.url:
      value: http://hl7.org/fhir/tools/StructureDefinition/snapshot-base-version
    extension.value string:
      value: 4.0.1
  structure definition.snapshot.element:
    index: 0
    element.id:
      value: OperationOutcome
    element definition.path:
      value: OperationOutcome
    element definition.short:
      value: 支付審核系統之申報檢核結果；API 交易層級之回覆結果代碼（rtncode）由 VS_TW_LTC_FeeAuditRtnCode（vs-tw-ltc-feeaudit-rtncode）表達，例：0 成功回傳、1 Request 輸入參數錯誤、40 查無資料、90 發生無法預期錯誤；本 Profile 之 issue 則表達個別服務紀錄之檢核錯誤（err_code／err_message）
    element definition.definition:
      value: A collection of error, warning, or information messages that result from a system action.
    element definition.comment:
      value: Can result from the failure of a REST call or be part of the response message returned from a request message.
    element definition.min:
      value: 0
    element definition.max:
      value: *
    element definition.base:
      element definition.base.path:
        value: OperationOutcome
      element definition.base.min:
        value: 0
      element definition.base.max:
        value: *
    element definition.constraint:
      index: 0
      element definition.constraint.key:
        value: dom-2
      element definition.constraint.severity:
        value: error
      element definition.constraint.human:
        value: If the resource is contained in another resource, it SHALL NOT contain nested Resources
      element definition.constraint.expression:
        value: contained.contained.empty()
      element definition.constraint.xpath:
        value: not(parent::f:contained and f:contained)
      element definition.constraint.source:
        value: http://hl7.org/fhir/StructureDefinition/DomainResource
        link: http://hl7.org/fhir/StructureDefinition/DomainResource
    element definition.constraint:
      index: 1
      element definition.constraint.key:
        value: dom-3
      element definition.constraint.severity:
        value: error
      element definition.constraint.human:
        value: If the resource is contained in another resource, it SHALL be referred to from elsewhere in the resource or SHALL refer to the containing resource
      element definition.constraint.expression:
        value: contained.where((('#'+id in (%resource.descendants().reference | %resource.descendants().as(canonical) | %resource.descendants().as(uri) | %resource.descendants().as(url))) or descendants().where(reference = '#').exists() or descendants().where(as(canonical) = '#').exists() or descendants().where(as(canonical) = '#').exists()).not()).trace('unmatched', id).empty()
      element definition.constraint.xpath:
        value: not(exists(for $id in f:contained/*/f:id/@value return $contained[not(parent::*/descendant::f:reference/@value=concat('#', $contained/*/id/@value) or descendant::f:reference[@value='#'])]))
      element definition.constraint.source:
        value: http://hl7.org/fhir/StructureDefinition/DomainResource
        link: http://hl7.org/fhir/StructureDefinition/DomainResource
    element definition.constraint:
      index: 2
      element definition.constraint.key:
        value: dom-4
      element definition.constraint.severity:
        value: error
      element definition.constraint.human:
        value: If a resource is contained in another resource, it SHALL NOT have a meta.versionId or a meta.lastUpdated
      element definition.constraint.expression:
        value: contained.meta.versionId.empty() and contained.meta.lastUpdated.empty()
      element definition.constraint.xpath:
        value: not(exists(f:contained/*/f:meta/f:versionId)) and not(exists(f:contained/*/f:meta/f:lastUpdated))
      element definition.constraint.source:
        value: http://hl7.org/fhir/StructureDefinition/DomainResource
        link: http://hl7.org/fhir/StructureDefinition/DomainResource
    element definition.constraint:
      index: 3
      element definition.constraint.key:
        value: dom-5
      element definition.constraint.severity:
        value: error
      element definition.constraint.human:
        value: If a resource is contained in another resource, it SHALL NOT have a security label
      element definition.constraint.expression:
        value: contained.meta.security.empty()
      element definition.constraint.xpath:
        value: not(exists(f:contained/*/f:meta/f:security))
      element definition.constraint.source:
        value: http://hl7.org/fhir/StructureDefinition/DomainResource
        link: http://hl7.org/fhir/StructureDefinition/DomainResource
    element definition.constraint:
      index: 4
      element.extension:
        index: 0
      element.extension:
        index: 1
      element definition.constraint.key:
        value: dom-6
      element definition.constraint.severity:
        value: warning
      element definition.constraint.human:
        value: A resource should have narrative for robust management
      element definition.constraint.expression:
        value: text.`div`.exists()
      element definition.constraint.xpath:
        value: exists(f:text/h:div)
      element definition.constraint.source:
        value: http://hl7.org/fhir/StructureDefinition/DomainResource
        link: http://hl7.org/fhir/StructureDefinition/DomainResource
    element definition.is modifier:
      value: false
    element definition.is summary:
      value: false
    element definition.mapping:
      index: 0
      element definition.mapping.identity:
        value: rim
      element definition.mapping.map:
        value: Entity. Role, or Act
    element definition.mapping:
      index: 1
      element definition.mapping.identity:
        value: rim
      element definition.mapping.map:
        value: Grouping is handled through multiple repetitions from whatever context references the outcomes (no specific grouper required)
  structure definition.snapshot.element:
    index: 1
    element.id:
      value: OperationOutcome.id
    element definition.path:
      value: OperationOutcome.id
    element definition.short:
      value: Logical id of this artifact
    element definition.definition:
      value: The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes.
    element definition.comment:
      value: The only time that a resource does not have an id is when it is being submitted to the server using a create operation.
    element definition.min:
      value: 0

value: true

value: When a resource has no narrative, only systems that fully understand the data can display the resource to a human safely. Including a human readable representation in the resource makes for a much more robust eco-system and cheaper handling of resources by intermediary systems. Some ecosystems restrict distribution of resources to only those systems that do fully understand the resources, and as a consequence implementers may believe that the narrative is superfluous. However experience shows that such eco-systems often open up to new participants over time.

value: 1

element definition.base.path:
  value: Resource.id
element definition.base.min:
  value: 0
element definition.base.max:
  value: 1

index: 0
element.extension:
  index: 0
  extension.url:
    value: http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type
  extension.value url:
    value: id
element definition.type.code:
  value: http://hl7.org/fhirpath/System.String

value: false

value: true

index: 2
element.id:
  value: OperationOutcome.meta
element definition.path:
  value: OperationOutcome.meta
element definition.short:
  value: Metadata about the resource
element definition.definition:
  value: The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.
element definition.min:
  value: 0
element definition.max:
  value: 1
element definition.base:
  element definition.base.path:
    value: Resource.meta
  element definition.base.min:
    value: 0
  element definition.base.max:
    value: 1
element definition.type:
  index: 0
  element definition.type.code:
    value: Meta
element definition.constraint:
  index: 0
  element definition.constraint.key:
    value: ele-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: All FHIR elements must have a @value or children
  element definition.constraint.expression:
    value: hasValue() or (children().count() > id.count())
  element definition.constraint.xpath:
    value: @value|f:*|h:div
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
element definition.is modifier:
  value: false
element definition.is summary:
  value: true

index: 3
element.id:
  value: OperationOutcome.implicitRules
element definition.path:
  value: OperationOutcome.implicitRules
element definition.short:
  value: A set of rules under which this content was created
element definition.definition:
  value: A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc.
element definition.comment:
  value: Asserting this rule set restricts the content to be only understood by a limited set of trading partners. This inherently limits the usefulness of the data in the long term. However, the existing health eco-system is highly fractured, and not yet ready to define, collect, and exchange data in a generally computable sense. Wherever possible, implementers and/or specification writers should avoid using this element. Often, when used, the URL is a reference to an implementation guide that defines these special rules as part of it's narrative along with other profiles, value sets, etc.
element definition.min:
  value: 0
element definition.max:
  value: 1
element definition.base:
  element definition.base.path:
    value: Resource.implicitRules
  element definition.base.min:
    value: 0
  element definition.base.max:
    value: 1
element definition.type:
  index: 0
  element definition.type.code:
    value: uri
element definition.constraint:
  index: 0
  element definition.constraint.key:
    value: ele-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: All FHIR elements must have a @value or children
  element definition.constraint.expression:
    value: hasValue() or (children().count() > id.count())
  element definition.constraint.xpath:
    value: @value|f:*|h:div
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
element definition.is modifier:
  value: true
element definition.is modifier reason:
  value: This element is labeled as a modifier because the implicit rules may provide additional knowledge about the resource that modifies it's meaning or interpretation
element definition.is summary:
  value: true

index: 4
element.id:
  value: OperationOutcome.language
element definition.path:
  value: OperationOutcome.language
element definition.short:
  value: Language of the resource content
element definition.definition:
  value: The base language in which the resource is written.
element definition.comment:
  value: Language is provided to support indexing and accessibility (typically, services such as text to speech use the language tag). The html language tag in the narrative applies to the narrative. The language tag on the resource may be used to specify the language of other presentations generated from the data in the resource. Not all the content has to be in the base language. The Resource.language should not be assumed to apply to the narrative automatically. If a language is specified, it should it also be specified on the div element in the html (see rules in HTML5 for information about the relationship between xml:lang and the html lang attribute).
element definition.min:
  value: 0
element definition.max:
  value: 1
element definition.base:
  element definition.base.path:
    value: Resource.language
  element definition.base.min:
    value: 0
  element definition.base.max:
    value: 1
element definition.type:
  index: 0
  element definition.type.code:
    value: code
element definition.constraint:
  index: 0
  element definition.constraint.key:
    value: ele-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: All FHIR elements must have a @value or children
  element definition.constraint.expression:
    value: hasValue() or (children().count() > id.count())
  element definition.constraint.xpath:
    value: @value|f:*|h:div
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
element definition.is modifier:
  value: false
element definition.is summary:
  value: false
element definition.binding:
  element.extension:
    index: 0
    extension.url:
      value: http://hl7.org/fhir/StructureDefinition/elementdefinition-maxValueSet
    extension.value canonical:
      value: http://hl7.org/fhir/ValueSet/all-languages
      link: http://hl7.org/fhir/ValueSet/all-languages
  element.extension:
    index: 1
    extension.url:
      value: http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName
    extension.value string:
      value: Language
  element definition.binding.strength:
    value: preferred
  element definition.binding.description:
    value: A human language.
  element definition.binding.value set:
    value: http://hl7.org/fhir/ValueSet/languages|4.0.1
    link: 4.0
    link: .1

index: 5
element.id:
  value: OperationOutcome.text
element definition.path:
  value: OperationOutcome.text
element definition.short:
  value: Text summary of the resource, for human interpretation
element definition.definition:
  value: A human-readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it "clinically safe" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.
element definition.comment:
  value: Contained resources do not have narrative. Resources that are not contained SHOULD have a narrative. In some cases, a resource may only have text with little or no additional discrete data (as long as all minOccurs=1 elements are satisfied). This may be necessary for data from legacy systems where information is captured as a "text blob" or where text is additionally entered raw or narrated and encoded information is added later.
element definition.alias:
  value: narrative
  index: 0
element definition.alias:
  value: html
  index: 1
element definition.alias:
  value: xhtml
  index: 2
element definition.alias:
  value: display
  index: 3
element definition.min:
  value: 0
element definition.max:
  value: 1
element definition.base:
  element definition.base.path:
    value: DomainResource.text
  element definition.base.min:
    value: 0
  element definition.base.max:
    value: 1
element definition.type:
  index: 0
  element definition.type.code:
    value: Narrative
element definition.constraint:
  index: 0
  element definition.constraint.key:
    value: ele-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: All FHIR elements must have a @value or children
  element definition.constraint.expression:
    value: hasValue() or (children().count() > id.count())
  element definition.constraint.xpath:
    value: @value|f:*|h:div
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
element definition.is modifier:
  value: false
element definition.is summary:
  value: false
element definition.mapping:
  index: 0
  element definition.mapping.identity:
    value: rim
  element definition.mapping.map:
    value: Act.text?

index: 6
element.id:
  value: OperationOutcome.contained
element definition.path:
  value: OperationOutcome.contained
element definition.short:
  value: Contained, inline Resources
element definition.definition:
  value: These resources do not have an independent existence apart from the resource that contains them - they cannot be identified independently, and nor can they have their own independent transaction scope.
element definition.comment:
  value: This should never be done when the content can be identified properly, as once identification is lost, it is extremely difficult (and context dependent) to restore it again. Contained resources may have profiles and tags In their meta elements, but SHALL NOT have security labels.
element definition.alias:
  value: inline resources
  index: 0
element definition.alias:
  value: anonymous resources
  index: 1
element definition.alias:
  value: contained resources
  index: 2
element definition.min:
  value: 0
element definition.max:
  value: *
element definition.base:
  element definition.base.path:
    value: DomainResource.contained
  element definition.base.min:
    value: 0
  element definition.base.max:
    value: *
element definition.type:
  index: 0
  element definition.type.code:
    value: Resource
element definition.is modifier:
  value: false
element definition.is summary:
  value: false
element definition.mapping:
  index: 0
  element definition.mapping.identity:
    value: rim
  element definition.mapping.map:
    value: N/A

index: 7
element.id:
  value: OperationOutcome.extension
element definition.path:
  value: OperationOutcome.extension
element definition.slicing:
  element definition.slicing.discriminator:
    index: 0
    element definition.slicing.discriminator.type:
      value: value
    element definition.slicing.discriminator.path:
      value: url
  element definition.slicing.ordered:
    value: false
  element definition.slicing.rules:
    value: open
element definition.short:
  value: Extension
element definition.definition:
  value: An Extension
element definition.min:
  value: 0
element definition.max:
  value: *
element definition.base:
  element definition.base.path:
    value: DomainResource.extension
  element definition.base.min:
    value: 0
  element definition.base.max:
    value: *
element definition.type:
  index: 0
  element definition.type.code:
    value: Extension
element definition.constraint:
  index: 0
  element definition.constraint.key:
    value: ele-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: All FHIR elements must have a @value or children
  element definition.constraint.expression:
    value: hasValue() or (children().count() > id.count())
  element definition.constraint.xpath:
    value: @value|f:*|h:div
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
element definition.constraint:
  index: 1
  element definition.constraint.key:
    value: ext-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: Must have either extensions or value[x], not both
  element definition.constraint.expression:
    value: extension.exists() != value.exists()
  element definition.constraint.xpath:
    value: exists(f:extension)!=exists(f:*[starts-with(local-name(.), "value")])
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Extension
    link: http://hl7.org/fhir/StructureDefinition/Extension
element definition.is modifier:
  value: false
element definition.is summary:
  value: false

index: 8
element.id:
  value: OperationOutcome.extension:caseNo
element definition.path:
  value: OperationOutcome.extension
element definition.slice name:
  value: caseNo
element definition.short:
  value: 核銷案號（case_no，最長 30 碼）；OperationOutcome 無 identifier 元素，故沿用既有 Extension ExtTWLTCExportCaseNo（Ext-TW-LTC-Export-CaseNo）承載案件編號，該 Extension 之 ^context 已涵蓋 OperationOutcome，於本 Profile 中其語意為支付審核系統之核銷案號
element definition.definition:
  value: 此 Extension 用於表示長照 SDK 的案件編號（CASENO），適用於 Claim、CarePlan、Communication 或 OperationOutcome 資源。
element definition.min:
  value: 0
element definition.max:
  value: 1
element definition.base:
  element definition.base.path:
    value: DomainResource.extension
  element definition.base.min:
    value: 0
  element definition.base.max:
    value: *
element definition.type:
  index: 0
  element definition.type.code:
    value: Extension
  element definition.type.profile:
    value: http://ltc-ig.fhir.tw/StructureDefinition/Ext-TW-LTC-Export-CaseNo
    index: 0
    link: http://ltc-ig.fhir.tw/StructureDefinition/Ext-TW-LTC-Export-CaseNo
element definition.condition:
  value: ele-1
  index: 0
element definition.constraint:
  index: 0
  element definition.constraint.key:
    value: ele-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: All FHIR elements must have a @value or children
  element definition.constraint.expression:
    value: hasValue() or (children().count() > id.count())
  element definition.constraint.xpath:
    value: @value|f:*|h:div
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
element definition.constraint:
  index: 1
  element definition.constraint.key:
    value: ext-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: Must have either extensions or value[x], not both
  element definition.constraint.expression:
    value: extension.exists() != value.exists()
  element definition.constraint.xpath:
    value: exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Extension
    link: http://hl7.org/fhir/StructureDefinition/Extension
element definition.must support:
  value: true
element definition.is modifier:
  value: false
element definition.is summary:
  value: false

index: 9
element.id:
  value: OperationOutcome.modifierExtension
element definition.path:
  value: OperationOutcome.modifierExtension
element definition.short:
  value: Extensions that cannot be ignored
element definition.definition:
  value: May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions. Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).
element definition.comment:
  value: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
element definition.requirements:
  value: Modifier extensions allow for extensions that *cannot* be safely ignored to be clearly distinguished from the vast majority of extensions which can be safely ignored. This promotes interoperability by eliminating the need for implementers to prohibit the presence of extensions. For further information, see the [definition of modifier extensions](http://hl7.org/fhir/R4/extensibility.html#modifierExtension).
element definition.alias:
  value: extensions
  index: 0
element definition.alias:
  value: user content
  index: 1
element definition.min:
  value: 0
element definition.max:
  value: *
element definition.base:
  element definition.base.path:
    value: DomainResource.modifierExtension
  element definition.base.min:
    value: 0
  element definition.base.max:
    value: *
element definition.type:
  index: 0
  element definition.type.code:
    value: Extension
element definition.constraint:
  index: 0
  element definition.constraint.key:
    value: ele-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: All FHIR elements must have a @value or children
  element definition.constraint.expression:
    value: hasValue() or (children().count() > id.count())
  element definition.constraint.xpath:
    value: @value|f:*|h:div
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
element definition.constraint:
  index: 1
  element definition.constraint.key:
    value: ext-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: Must have either extensions or value[x], not both
  element definition.constraint.expression:
    value: extension.exists() != value.exists()
  element definition.constraint.xpath:
    value: exists(f:extension)!=exists(f:*[starts-with(local-name(.), "value")])
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Extension
    link: http://hl7.org/fhir/StructureDefinition/Extension
element definition.is modifier:
  value: true
element definition.is modifier reason:
  value: Modifier extensions are expected to modify the meaning or interpretation of the resource that contains them
element definition.is summary:
  value: false
element definition.mapping:
  index: 0
  element definition.mapping.identity:
    value: rim
  element definition.mapping.map:
    value: N/A

index: 10
element.id:
  value: OperationOutcome.issue
element definition.path:
  value: OperationOutcome.issue
element definition.short:
  value: 檢核錯誤項目；每一筆錯誤訊息（err_info／exception_records／delete_exception_records）對應一個 issue，同一筆服務紀錄有多筆錯誤時以多個 issue 表達
element definition.definition:
  value: An error, warning, or information message that results from a system action.
element definition.min:
  value: 1
element definition.max:
  value: *
element definition.base:
  element definition.base.path:
    value: OperationOutcome.issue
  element definition.base.min:
    value: 1
  element definition.base.max:
    value: *
element definition.type:
  index: 0
  element definition.type.code:
    value: BackboneElement
element definition.constraint:
  index: 0
  element definition.constraint.key:
    value: ele-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: All FHIR elements must have a @value or children
  element definition.constraint.expression:
    value: hasValue() or (children().count() > id.count())
  element definition.constraint.xpath:
    value: @value|f:*|h:div
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
element definition.must support:
  value: true
element definition.is modifier:
  value: false
element definition.is summary:
  value: true
element definition.mapping:
  index: 0
  element definition.mapping.identity:
    value: v2
  element definition.mapping.map:
    value: ERR
element definition.mapping:
  index: 1
  element definition.mapping.identity:
    value: rim
  element definition.mapping.map:
    value: AcknowledgementDetail or Observation[classCode="ALRT" and moodCode="EVN"]

index: 11
element.id:
  value: OperationOutcome.issue.id
element definition.path:
  value: OperationOutcome.issue.id
element definition.representation:
  value: xmlAttr
  index: 0
element definition.short:
  value: Unique id for inter-element referencing
element definition.definition:
  value: Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.
element definition.min:
  value: 0
element definition.max:
  value: 1
element definition.base:
  element definition.base.path:
    value: Element.id
  element definition.base.min:
    value: 0
  element definition.base.max:
    value: 1
element definition.type:
  index: 0
  element.extension:
    index: 0
    extension.url:
      value: http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type
    extension.value url:
      value: string
  element definition.type.code:
    value: http://hl7.org/fhirpath/System.String
element definition.is modifier:
  value: false
element definition.is summary:
  value: false
element definition.mapping:
  index: 0
  element definition.mapping.identity:
    value: rim
  element definition.mapping.map:
    value: n/a

index: 12
element.id:
  value: OperationOutcome.issue.extension
element definition.path:
  value: OperationOutcome.issue.extension
element definition.short:
  value: Additional content defined by implementations
element definition.definition:
  value: May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.
element definition.comment:
  value: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
element definition.alias:
  value: extensions
  index: 0
element definition.alias:
  value: user content
  index: 1
element definition.min:
  value: 0
element definition.max:
  value: *
element definition.base:
  element definition.base.path:
    value: Element.extension
  element definition.base.min:
    value: 0
  element definition.base.max:
    value: *
element definition.type:
  index: 0
  element definition.type.code:
    value: Extension
element definition.constraint:
  index: 0
  element definition.constraint.key:
    value: ele-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: All FHIR elements must have a @value or children
  element definition.constraint.expression:
    value: hasValue() or (children().count() > id.count())
  element definition.constraint.xpath:
    value: @value|f:*|h:div
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
element definition.constraint:
  index: 1
  element definition.constraint.key:
    value: ext-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: Must have either extensions or value[x], not both
  element definition.constraint.expression:
    value: extension.exists() != value.exists()
  element definition.constraint.xpath:
    value: exists(f:extension)!=exists(f:*[starts-with(local-name(.), "value")])
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Extension
    link: http://hl7.org/fhir/StructureDefinition/Extension
element definition.is modifier:
  value: false
element definition.is summary:
  value: false
element definition.mapping:
  index: 0
  element definition.mapping.identity:
    value: rim
  element definition.mapping.map:
    value: n/a

index: 13
element.id:
  value: OperationOutcome.issue.modifierExtension
element definition.path:
  value: OperationOutcome.issue.modifierExtension
element definition.short:
  value: Extensions that cannot be ignored even if unrecognized
element definition.definition:
  value: May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions. Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).
element definition.comment:
  value: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
element definition.requirements:
  value: Modifier extensions allow for extensions that *cannot* be safely ignored to be clearly distinguished from the vast majority of extensions which can be safely ignored. This promotes interoperability by eliminating the need for implementers to prohibit the presence of extensions. For further information, see the [definition of modifier extensions](http://hl7.org/fhir/R4/extensibility.html#modifierExtension).
element definition.alias:
  value: extensions
  index: 0
element definition.alias:
  value: user content
  index: 1
element definition.alias:
  value: modifiers
  index: 2
element definition.min:
  value: 0
element definition.max:
  value: *
element definition.base:
  element definition.base.path:
    value: BackboneElement.modifierExtension
  element definition.base.min:
    value: 0
  element definition.base.max:
    value: *
element definition.type:
  index: 0
  element definition.type.code:
    value: Extension
element definition.constraint:
  index: 0
  element definition.constraint.key:
    value: ele-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: All FHIR elements must have a @value or children
  element definition.constraint.expression:
    value: hasValue() or (children().count() > id.count())
  element definition.constraint.xpath:
    value: @value|f:*|h:div
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
element definition.constraint:
  index: 1
  element definition.constraint.key:
    value: ext-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: Must have either extensions or value[x], not both
  element definition.constraint.expression:
    value: extension.exists() != value.exists()
  element definition.constraint.xpath:
    value: exists(f:extension)!=exists(f:*[starts-with(local-name(.), "value")])
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Extension
    link: http://hl7.org/fhir/StructureDefinition/Extension
element definition.is modifier:
  value: true
element definition.is modifier reason:
  value: Modifier extensions are expected to modify the meaning or interpretation of the element that contains them
element definition.is summary:
  value: true
element definition.mapping:
  index: 0
  element definition.mapping.identity:
    value: rim
  element definition.mapping.map:
    value: N/A

index: 14
element.id:
  value: OperationOutcome.issue.severity
element definition.path:
  value: OperationOutcome.issue.severity
element definition.short:
  value: 錯誤嚴重程度；因檢核未通過而導致該筆服務紀錄申報、分案或刪除失敗者，使用 error
element definition.definition:
  value: Indicates whether the issue indicates a variation from successful processing.
element definition.comment:
  value: This is labeled as "Is Modifier" because applications should not confuse hints and warnings with errors.
element definition.requirements:
  value: Indicates how relevant the issue is to the overall success of the action.
element definition.min:
  value: 1
element definition.max:
  value: 1
element definition.base:
  element definition.base.path:
    value: OperationOutcome.issue.severity
  element definition.base.min:
    value: 1
  element definition.base.max:
    value: 1
element definition.type:
  index: 0
  element definition.type.code:
    value: code
element definition.constraint:
  index: 0
  element definition.constraint.key:
    value: ele-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: All FHIR elements must have a @value or children
  element definition.constraint.expression:
    value: hasValue() or (children().count() > id.count())
  element definition.constraint.xpath:
    value: @value|f:*|h:div
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
element definition.must support:
  value: true
element definition.is modifier:
  value: false
element definition.is summary:
  value: true
element definition.binding:
  element.extension:
    index: 0
    extension.url:
      value: http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName
    extension.value string:
      value: IssueSeverity
  element definition.binding.strength:
    value: required
  element definition.binding.description:
    value: How the issue affects the success of the action.
  element definition.binding.value set:
    value: http://hl7.org/fhir/ValueSet/issue-severity|4.0.1
    link: 4.0
    link: .1
element definition.mapping:
  index: 0
  element definition.mapping.identity:
    value: v2
  element definition.mapping.map:
    value: ERR-4
element definition.mapping:
  index: 1
  element definition.mapping.identity:
    value: rim
  element definition.mapping.map:
    value: ./typeCode[parent::AcknowledgmentDetail] or unique(./inboundRelationship[parent::Observation and typeCode='SUBJ' and isNormalActRelationship()]/source[classCode="OBS" and moodCode="EVN" and implies(code, ActCode#SEV and isNormalAct())/value[xsi:type="CD"]

index: 15
element.id:
  value: OperationOutcome.issue.code
element definition.path:
  value: OperationOutcome.issue.code
element definition.short:
  value: FHIR 問題類型代碼；欄位必填或長度／格式檢核（E1xxx、E2xxx）建議使用 required 或 value，資料查詢與寫入異常（E4xxx）建議使用 not-found 或 processing，審核規則與支付碼專屬檢核（E5xxx、EBA／EBC／ECB／EGA／EOT／ESC 系列）建議使用 business-rule
element definition.definition:
  value: Describes the type of the issue. The system that creates an OperationOutcome SHALL choose the most applicable code from the IssueType value set, and may additional provide its own code for the error in the details element.
element definition.requirements:
  value: Expresses the issue in a human and computer-friendly way, allowing the requesting system to behave differently based on the type of issue. The required element provides a base level of computable interoperability across all systems for processing an outcome, allowing systems to respond appropriately regardless of the internal system error codes returned.
element definition.min:
  value: 1
element definition.max:
  value: 1
element definition.base:
  element definition.base.path:
    value: OperationOutcome.issue.code
  element definition.base.min:
    value: 1
  element definition.base.max:
    value: 1
element definition.type:
  index: 0
  element definition.type.code:
    value: code
element definition.constraint:
  index: 0
  element definition.constraint.key:
    value: ele-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: All FHIR elements must have a @value or children
  element definition.constraint.expression:
    value: hasValue() or (children().count() > id.count())
  element definition.constraint.xpath:
    value: @value|f:*|h:div
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
element definition.must support:
  value: true
element definition.is modifier:
  value: false
element definition.is summary:
  value: true
element definition.binding:
  element.extension:
    index: 0
    extension.url:
      value: http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName
    extension.value string:
      value: IssueType
  element definition.binding.strength:
    value: required
  element definition.binding.description:
    value: A code that describes the type of issue.
  element definition.binding.value set:
    value: http://hl7.org/fhir/ValueSet/issue-type|4.0.1
    link: 4.0
    link: .1
element definition.mapping:
  index: 0
  element definition.mapping.identity:
    value: v2
  element definition.mapping.map:
    value: ERR-3
element definition.mapping:
  index: 1
  element definition.mapping.identity:
    value: rim
  element definition.mapping.map:
    value: ./code

index: 16
element.id:
  value: OperationOutcome.issue.details
element definition.path:
  value: OperationOutcome.issue.details
element definition.short:
  value: 錯誤內容，承載回覆明細之錯誤碼（err_code，最長 5 碼）與錯誤原因（err_message，最長 200 字）
element definition.definition:
  value: Additional details about the error. This may be a text description of the error or a system code that identifies the error.
element definition.comment:
  value: A human readable description of the error issue SHOULD be placed in details.text.
element definition.min:
  value: 1
element definition.max:
  value: 1
element definition.base:
  element definition.base.path:
    value: OperationOutcome.issue.details
  element definition.base.min:
    value: 0
  element definition.base.max:
    value: 1
element definition.type:
  index: 0
  element definition.type.code:
    value: CodeableConcept
element definition.constraint:
  index: 0
  element definition.constraint.key:
    value: ele-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: All FHIR elements must have a @value or children
  element definition.constraint.expression:
    value: hasValue() or (children().count() > id.count())
  element definition.constraint.xpath:
    value: @value|f:*|h:div
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
element definition.must support:
  value: true
element definition.is modifier:
  value: false
element definition.is summary:
  value: true
element definition.binding:
  element.extension:
    index: 0
    extension.url:
      value: http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName
    extension.value string:
      value: IssueDetails
  element definition.binding.strength:
    value: example
  element definition.binding.description:
    value: A code that provides details as the exact issue.
  element definition.binding.value set:
    value: http://hl7.org/fhir/ValueSet/operation-outcome|4.0.1
    link: 4.0
    link: .1
element definition.mapping:
  index: 0
  element definition.mapping.identity:
    value: v2
  element definition.mapping.map:
    value: ERR-5
element definition.mapping:
  index: 1
  element definition.mapping.identity:
    value: rim
  element definition.mapping.map:
    value: ./code

index: 17
element.id:
  value: OperationOutcome.issue.details.id
element definition.path:
  value: OperationOutcome.issue.details.id
element definition.representation:
  value: xmlAttr
  index: 0
element definition.short:
  value: Unique id for inter-element referencing
element definition.definition:
  value: Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.
element definition.min:
  value: 0
element definition.max:
  value: 1
element definition.base:
  element definition.base.path:
    value: Element.id
  element definition.base.min:
    value: 0
  element definition.base.max:
    value: 1
element definition.type:
  index: 0
  element.extension:
    index: 0
    extension.url:
      value: http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type
    extension.value url:
      value: string
  element definition.type.code:
    value: http://hl7.org/fhirpath/System.String
element definition.is modifier:
  value: false
element definition.is summary:
  value: false
element definition.mapping:
  index: 0
  element definition.mapping.identity:
    value: rim
  element definition.mapping.map:
    value: n/a

index: 18
element.id:
  value: OperationOutcome.issue.details.extension
element definition.path:
  value: OperationOutcome.issue.details.extension
element definition.slicing:
  element definition.slicing.discriminator:
    index: 0
    element definition.slicing.discriminator.type:
      value: value
    element definition.slicing.discriminator.path:
      value: url
  element definition.slicing.description:
    value: Extensions are always sliced by (at least) url
  element definition.slicing.rules:
    value: open
element definition.short:
  value: Additional content defined by implementations
element definition.definition:
  value: May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.
element definition.comment:
  value: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
element definition.alias:
  value: extensions
  index: 0
element definition.alias:
  value: user content
  index: 1
element definition.min:
  value: 0
element definition.max:
  value: *
element definition.base:
  element definition.base.path:
    value: Element.extension
  element definition.base.min:
    value: 0
  element definition.base.max:
    value: *
element definition.type:
  index: 0
  element definition.type.code:
    value: Extension
element definition.constraint:
  index: 0
  element definition.constraint.key:
    value: ele-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: All FHIR elements must have a @value or children
  element definition.constraint.expression:
    value: hasValue() or (children().count() > id.count())
  element definition.constraint.xpath:
    value: @value|f:*|h:div
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
element definition.constraint:
  index: 1
  element definition.constraint.key:
    value: ext-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: Must have either extensions or value[x], not both
  element definition.constraint.expression:
    value: extension.exists() != value.exists()
  element definition.constraint.xpath:
    value: exists(f:extension)!=exists(f:*[starts-with(local-name(.), "value")])
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Extension
    link: http://hl7.org/fhir/StructureDefinition/Extension
element definition.is modifier:
  value: false
element definition.is summary:
  value: false
element definition.mapping:
  index: 0
  element definition.mapping.identity:
    value: rim
  element definition.mapping.map:
    value: n/a

index: 19
element.id:
  value: OperationOutcome.issue.details.coding
element definition.path:
  value: OperationOutcome.issue.details.coding
element definition.short:
  value: 錯誤碼（err_code），綁定支付審查錯誤代碼值集 VS_TW_LTC_FeeAuditErrorCode，例：E1001（服務紀錄識別碼不可空白）、E4015（單位已執行申報確認通知，不在受理新的服務紀錄申報）、E4032（此筆服務紀錄不存在）
element definition.definition:
  value: A reference to a code defined by a terminology system.
element definition.comment:
  value: Codes may be defined very casually in enumerations, or code lists, up to very formal definitions such as SNOMED CT - see the HL7 v3 Core Principles for more information. Ordering of codings is undefined and SHALL NOT be used to infer meaning. Generally, at most only one of the coding values will be labeled as UserSelected = true.
element definition.requirements:
  value: Allows for alternative encodings within a code system, and translations to other code systems.
element definition.min:
  value: 1
element definition.max:
  value: 1
element definition.base:
  element definition.base.path:
    value: CodeableConcept.coding
  element definition.base.min:
    value: 0
  element definition.base.max:
    value: *
element definition.type:
  index: 0
  element definition.type.code:
    value: Coding
element definition.constraint:
  index: 0
  element definition.constraint.key:
    value: ele-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: All FHIR elements must have a @value or children
  element definition.constraint.expression:
    value: hasValue() or (children().count() > id.count())
  element definition.constraint.xpath:
    value: @value|f:*|h:div
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
element definition.must support:
  value: true
element definition.is modifier:
  value: false
element definition.is summary:
  value: true
element definition.binding:
  element definition.binding.strength:
    value: extensible
  element definition.binding.value set:
    value: http://ltc-ig.fhir.tw/ValueSet/vs-tw-ltc-feeaudit-error-code
    link: http://ltc-ig.fhir.tw/ValueSet/vs-tw-ltc-feeaudit-error-code
element definition.mapping:
  index: 0
  element definition.mapping.identity:
    value: v2
  element definition.mapping.map:
    value: C*E.1-8, C*E.10-22
element definition.mapping:
  index: 1
  element definition.mapping.identity:
    value: rim
  element definition.mapping.map:
    value: union(., ./translation)
element definition.mapping:
  index: 2
  element definition.mapping.identity:
    value: orim
  element definition.mapping.map:
    value: fhir:CodeableConcept.coding rdfs:subPropertyOf dt:CD.coding

index: 20
element.id:
  value: OperationOutcome.issue.details.text
element.extension:
  index: 0
  extension.url:
    value: http://hl7.org/fhir/StructureDefinition/elementdefinition-translatable
  extension.value boolean:
    value: true
element definition.path:
  value: OperationOutcome.issue.details.text
element definition.short:
  value: 錯誤原因（err_message）之顯示文字
element definition.definition:
  value: A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user.
element definition.comment:
  value: Very often the text is the same as a displayName of one of the codings.
element definition.requirements:
  value: The codes from the terminologies do not always capture the correct meaning with all the nuances of the human using them, or sometimes there is no appropriate code at all. In these cases, the text is used to capture the full meaning of the source.
element definition.min:
  value: 0
element definition.max:
  value: 1
element definition.base:
  element definition.base.path:
    value: CodeableConcept.text
  element definition.base.min:
    value: 0
  element definition.base.max:
    value: 1
element definition.type:
  index: 0
  element definition.type.code:
    value: string
element definition.constraint:
  index: 0
  element definition.constraint.key:
    value: ele-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: All FHIR elements must have a @value or children
  element definition.constraint.expression:
    value: hasValue() or (children().count() > id.count())
  element definition.constraint.xpath:
    value: @value|f:*|h:div
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
element definition.must support:
  value: true
element definition.is modifier:
  value: false
element definition.is summary:
  value: true
element definition.mapping:
  index: 0
  element definition.mapping.identity:
    value: v2
  element definition.mapping.map:
    value: C*E.9. But note many systems use C*E.2 for this
element definition.mapping:
  index: 1
  element definition.mapping.identity:
    value: rim
  element definition.mapping.map:
    value: ./originalText[mediaType/code="text/plain"]/data
element definition.mapping:
  index: 2
  element definition.mapping.identity:
    value: orim
  element definition.mapping.map:
    value: fhir:CodeableConcept.text rdfs:subPropertyOf dt:CD.originalText

index: 21
element.id:
  value: OperationOutcome.issue.diagnostics
element definition.path:
  value: OperationOutcome.issue.diagnostics
element definition.short:
  value: 錯誤原因原文或補充說明，可放回覆明細之 err_message 全文，或 API 層級之回覆訊息（errmsg）、批次處理結果（batch_proc_result）等敘述文字
element definition.definition:
  value: Additional diagnostic information about the issue.
element definition.comment:
  value: This may be a description of how a value is erroneous, a stack dump to help trace the issue or other troubleshooting information.
element definition.min:
  value: 0
element definition.max:
  value: 1
element definition.base:
  element definition.base.path:
    value: OperationOutcome.issue.diagnostics
  element definition.base.min:
    value: 0
  element definition.base.max:
    value: 1
element definition.type:
  index: 0
  element definition.type.code:
    value: string
element definition.constraint:
  index: 0
  element definition.constraint.key:
    value: ele-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: All FHIR elements must have a @value or children
  element definition.constraint.expression:
    value: hasValue() or (children().count() > id.count())
  element definition.constraint.xpath:
    value: @value|f:*|h:div
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
element definition.must support:
  value: true
element definition.is modifier:
  value: false
element definition.is summary:
  value: true
element definition.mapping:
  index: 0
  element definition.mapping.identity:
    value: v2
  element definition.mapping.map:
    value: ERR-8
element definition.mapping:
  index: 1
  element definition.mapping.identity:
    value: rim
  element definition.mapping.map:
    value: ./text[parent::AcknowledgmentDetail]

index: 22
element.id:
  value: OperationOutcome.issue.location
element definition.path:
  value: OperationOutcome.issue.location
element definition.short:
  value: Deprecated: Path of element(s) related to issue
element definition.definition:
  value: This element is deprecated because it is XML specific. It is replaced by issue.expression, which is format independent, and simpler to parse. For resource issues, this will be a simple XPath limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised. For HTTP errors, will be "http." + the parameter name.
element definition.comment:
  value: The root of the XPath is the resource or bundle that generated OperationOutcome. Each XPath SHALL resolve to a single node. This element is deprecated, and is being replaced by expression.
element definition.requirements:
  value: Allows systems to highlight or otherwise guide users to elements implicated in issues to allow them to be fixed more easily.
element definition.min:
  value: 0
element definition.max:
  value: *
element definition.base:
  element definition.base.path:
    value: OperationOutcome.issue.location
  element definition.base.min:
    value: 0
  element definition.base.max:
    value: *
element definition.type:
  index: 0
  element definition.type.code:
    value: string
element definition.constraint:
  index: 0
  element definition.constraint.key:
    value: ele-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: All FHIR elements must have a @value or children
  element definition.constraint.expression:
    value: hasValue() or (children().count() > id.count())
  element definition.constraint.xpath:
    value: @value|f:*|h:div
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
element definition.is modifier:
  value: false
element definition.is summary:
  value: true
element definition.mapping:
  index: 0
  element definition.mapping.identity:
    value: v2
  element definition.mapping.map:
    value: ERR-2
element definition.mapping:
  index: 1
  element definition.mapping.identity:
    value: rim
  element definition.mapping.map:
    value: ./location[parent::AcknowledgmentDetail]

index: 23
element.id:
  value: OperationOutcome.issue.expression
element definition.path:
  value: OperationOutcome.issue.expression
element definition.short:
  value: 指向出錯的服務紀錄識別碼（objid），即 err_record.objid、exception_records.objid 或 delete_exception_records.objid。表述時須將實際的 objid 值寫入條件，方能唯一指出是哪一筆服務紀錄，例：Claim.identifier.where(system='http://ltc-ig.fhir.tw/identifier/feeaudit/objid' and value='882601914')；僅寫出路徑而未帶入 objid 值者無法定位錯誤來源
element definition.definition:
  value: A [simple subset of FHIRPath](http://hl7.org/fhir/R4/fhirpath.html#simple) limited to element names, repetition indicators and the default child accessor that identifies one of the elements in the resource that caused this issue to be raised.
element definition.comment:
  value: The root of the FHIRPath is the resource or bundle that generated OperationOutcome. Each FHIRPath SHALL resolve to a single node.
element definition.requirements:
  value: Allows systems to highlight or otherwise guide users to elements implicated in issues to allow them to be fixed more easily.
element definition.min:
  value: 0
element definition.max:
  value: *
element definition.base:
  element definition.base.path:
    value: OperationOutcome.issue.expression
  element definition.base.min:
    value: 0
  element definition.base.max:
    value: *
element definition.type:
  index: 0
  element definition.type.code:
    value: string
element definition.constraint:
  index: 0
  element definition.constraint.key:
    value: ele-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: All FHIR elements must have a @value or children
  element definition.constraint.expression:
    value: hasValue() or (children().count() > id.count())
  element definition.constraint.xpath:
    value: @value|f:*|h:div
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
element definition.must support:
  value: true
element definition.is modifier:
  value: false
element definition.is summary:
  value: true
element definition.mapping:
  index: 0
  element definition.mapping.identity:
    value: v2
  element definition.mapping.map:
    value: ERR-2
element definition.mapping:
  index: 1
  element definition.mapping.identity:
    value: rim
  element definition.mapping.map:
    value: ./location[parent::AcknowledgmentDetail]

structure definition.differential.element:
  index: 0
  element.id:
    value: OperationOutcome
  element definition.path:
    value: OperationOutcome
  element definition.short:
    value: 支付審核系統之申報檢核結果；API 交易層級之回覆結果代碼（rtncode）由 VS_TW_LTC_FeeAuditRtnCode（vs-tw-ltc-feeaudit-rtncode）表達，例：0 成功回傳、1 Request 輸入參數錯誤、40 查無資料、90 發生無法預期錯誤；本 Profile 之 issue 則表達個別服務紀錄之檢核錯誤（err_code／err_message）
structure definition.differential.element:
  index: 1
  element.id:
    value: OperationOutcome.extension
  element definition.path:
    value: OperationOutcome.extension
  element definition.slicing:
    element definition.slicing.discriminator:
      index: 0
      element definition.slicing.discriminator.type:
        value: value
      element definition.slicing.discriminator.path:
        value: url
    element definition.slicing.ordered:
      value: false
    element definition.slicing.rules:
      value: open
structure definition.differential.element:
  index: 2
  element.id:
    value: OperationOutcome.extension:caseNo
  element definition.path:
    value: OperationOutcome.extension
  element definition.slice name:
    value: caseNo
  element definition.short:
    value: 核銷案號（case_no，最長 30 碼）；OperationOutcome 無 identifier 元素，故沿用既有 Extension ExtTWLTCExportCaseNo（Ext-TW-LTC-Export-CaseNo）承載案件編號，該 Extension 之 ^context 已涵蓋 OperationOutcome，於本 Profile 中其語意為支付審核系統之核銷案號
  element definition.min:
    value: 0
  element definition.max:
    value: 1
  element definition.type:
    index: 0
    element definition.type.code:
      value: Extension
    element definition.type.profile:
      value: http://ltc-ig.fhir.tw/StructureDefinition/Ext-TW-LTC-Export-CaseNo
      index: 0
      link: http://ltc-ig.fhir.tw/StructureDefinition/Ext-TW-LTC-Export-CaseNo
  element definition.must support:
    value: true
structure definition.differential.element:
  index: 3
  element.id:
    value: OperationOutcome.issue
  element definition.path:
    value: OperationOutcome.issue
  element definition.short:
    value: 檢核錯誤項目；每一筆錯誤訊息（err_info／exception_records／delete_exception_records）對應一個 issue，同一筆服務紀錄有多筆錯誤時以多個 issue 表達
  element definition.must support:
    value: true
structure definition.differential.element:
  index: 4
  element.id:
    value: OperationOutcome.issue.severity
  element definition.path:
    value: OperationOutcome.issue.severity
  element definition.short:
    value: 錯誤嚴重程度；因檢核未通過而導致該筆服務紀錄申報、分案或刪除失敗者，使用 error
  element definition.must support:
    value: true
structure definition.differential.element:
  index: 5
  element.id:
    value: OperationOutcome.issue.code
  element definition.path:
    value: OperationOutcome.issue.code
  element definition.short:
    value: FHIR 問題類型代碼；欄位必填或長度／格式檢核（E1xxx、E2xxx）建議使用 required 或 value，資料查詢與寫入異常（E4xxx）建議使用 not-found 或 processing，審核規則與支付碼專屬檢核（E5xxx、EBA／EBC／ECB／EGA／EOT／ESC 系列）建議使用 business-rule
  element definition.must support:
    value: true
structure definition.differential.element:
  index: 6
  element.id:
    value: OperationOutcome.issue.details
  element definition.path:
    value: OperationOutcome.issue.details
  element definition.short:
    value: 錯誤內容，承載回覆明細之錯誤碼（err_code，最長 5 碼）與錯誤原因（err_message，最長 200 字）
  element definition.min:
    value: 1
  element definition.must support:
    value: true
structure definition.differential.element:
  index: 7
  element.id:
    value: OperationOutcome.issue.details.coding
  element definition.path:
    value: OperationOutcome.issue.details.coding
  element definition.short:
    value: 錯誤碼（err_code），綁定支付審查錯誤代碼值集 VS_TW_LTC_FeeAuditErrorCode，例：E1001（服務紀錄識別碼不可空白）、E4015（單位已執行申報確認通知，不在受理新的服務紀錄申報）、E4032（此筆服務紀錄不存在）
  element definition.min:
    value: 1
  element definition.max:
    value: 1
  element definition.must support:
    value: true
  element definition.binding:
    element definition.binding.strength:
      value: extensible
    element definition.binding.value set:
      value: http://ltc-ig.fhir.tw/ValueSet/vs-tw-ltc-feeaudit-error-code
      link: http://ltc-ig.fhir.tw/ValueSet/vs-tw-ltc-feeaudit-error-code
structure definition.differential.element:
  index: 8
  element.id:
    value: OperationOutcome.issue.details.text
  element definition.path:
    value: OperationOutcome.issue.details.text
  element definition.short:
    value: 錯誤原因（err_message）之顯示文字
  element definition.must support:
    value: true
structure definition.differential.element:
  index: 9
  element.id:
    value: OperationOutcome.issue.diagnostics
  element definition.path:
    value: OperationOutcome.issue.diagnostics
  element definition.short:
    value: 錯誤原因原文或補充說明，可放回覆明細之 err_message 全文，或 API 層級之回覆訊息（errmsg）、批次處理結果（batch_proc_result）等敘述文字
  element definition.must support:
    value: true
structure definition.differential.element:
  index: 10
  element.id:
    value: OperationOutcome.issue.expression
  element definition.path:
    value: OperationOutcome.issue.expression
  element definition.short:
    value: 指向出錯的服務紀錄識別碼（objid），即 err_record.objid、exception_records.objid 或 delete_exception_records.objid。表述時須將實際的 objid 值寫入條件，方能唯一指出是哪一筆服務紀錄，例：Claim.identifier.where(system='http://ltc-ig.fhir.tw/identifier/feeaudit/objid' and value='882601914')；僅寫出路徑而未帶入 objid 值者無法定位錯誤來源
  element definition.must support:
    value: true