{"abstract":false,"baseDefinition":"http://hl7.org/fhir/StructureDefinition/Extension","contact":[{"telecom":[{"system":"url","value":"http://hl7.org/special/committees/fwg"}]}],"context":[{"expression":"Observation","type":"element"},{"expression":"DiagnosticReport","type":"element"},{"expression":"DocumentReference","type":"element"},{"expression":"NutritionOrder","type":"element"}],"date":"2017-12-06","derivation":"constraint","description":"Describes why the event occurred in coded or textual form.","differential":{"element":[{"comment":"For free text (uncoded data) use reasonCode.text.","definition":"Describes why the event occurred in coded or textual form.","id":"Extension","mapping":[{"identity":"workflow","map":"Event.reasonCode"},{"identity":"v2","map":"EVN.4 or by domain"},{"identity":"rim","map":".reasonCode"}],"max":"*","min":0,"path":"Extension","short":"Why was event performed?"},{"id":"Extension.extension","max":"0","path":"Extension.extension"},{"fixedUri":"http://hl7.org/fhir/StructureDefinition/workflow-reasonCode","id":"Extension.url","path":"Extension.url"},{"binding":{"extension":[{"url":"http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName","valueString":"EventReason"}],"strength":"example","valueSet":"http://hl7.org/fhir/ValueSet/condition-cause"},"id":"Extension.value[x]","min":1,"path":"Extension.value[x]","type":[{"code":"CodeableConcept"}]}]},"extension":[{"url":"http://hl7.org/fhir/StructureDefinition/structuredefinition-wg","valueCode":"fhir"},{"url":"http://hl7.org/fhir/StructureDefinition/structuredefinition-fmm","valueInteger":1}],"fhirVersion":"4.2.0","id":"workflow-reasonCode","kind":"complex-type","mapping":[{"identity":"workflow","name":"Workflow Pattern","uri":"http://hl7.org/fhir/workflow"},{"identity":"v2","name":"HL7 v2 Mapping","uri":"http://hl7.org/v2"},{"identity":"rim","name":"RIM Mapping","uri":"http://hl7.org/v3"}],"name":"reasonCode","publisher":"Health Level Seven, Inc. - FHIR WG","resourceType":"StructureDefinition","snapshot":{"element":[{"base":{"max":"*","min":0,"path":"Extension"},"comment":"For free text (uncoded data) use reasonCode.text.","constraint":[{"expression":"hasValue() or (children().count() > id.count())","human":"All FHIR elements must have a @value or children","key":"ele-1","severity":"error","source":"Element","xpath":"@value|f:*|h:div"},{"expression":"extension.exists() != value.exists()","human":"Must have either extensions or value[x], not both","key":"ext-1","severity":"error","source":"http://hl7.org/fhir/StructureDefinition/Extension","xpath":"exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])"}],"definition":"Describes why the event occurred in coded or textual form.","id":"Extension","isModifier":false,"mapping":[{"identity":"workflow","map":"Event.reasonCode"},{"identity":"v2","map":"EVN.4 or by domain"},{"identity":"rim","map":".reasonCode"}],"max":"*","min":0,"path":"Extension","short":"Why was event performed?"},{"base":{"max":"1","min":0,"path":"Element.id"},"definition":"Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.","id":"Extension.id","isModifier":false,"isSummary":false,"mapping":[{"identity":"rim","map":"n/a"}],"max":"1","min":0,"path":"Extension.id","representation":["xmlAttr"],"short":"Unique id for inter-element referencing","type":[{"code":"http://hl7.org/fhirpath/System.String","extension":[{"url":"http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type","valueUri":"string"}]}]},{"base":{"max":"*","min":0,"path":"Element.extension"},"constraint":[{"expression":"hasValue() or (children().count() > id.count())","human":"All FHIR elements must have a @value or children","key":"ele-1","severity":"error","source":"Element","xpath":"@value|f:*|h:div"},{"expression":"extension.exists() != value.exists()","human":"Must have either extensions or value[x], not both","key":"ext-1","severity":"error","source":"Extension","xpath":"exists(f:extension)!=exists(f:*[starts-with(local-name(.), \"value\")])"}],"definition":"An Extension","id":"Extension.extension","isModifier":false,"isSummary":false,"max":"0","min":0,"path":"Extension.extension","short":"Extension","slicing":{"description":"Extensions are always sliced by (at least) url","discriminator":[{"path":"url","type":"value"}],"rules":"open"},"type":[{"code":"Extension"}]},{"base":{"max":"1","min":1,"path":"Extension.url"},"comment":"The definition may point directly to a computable or human-readable definition of the extensibility codes, or it may be a logical URI as declared in some other specification. The definition SHALL be a URI for the Structure Definition defining the extension.","definition":"Source of the definition for the extension code - a logical name or a URL.","fixedUri":"http://hl7.org/fhir/StructureDefinition/workflow-reasonCode","id":"Extension.url","isModifier":false,"isSummary":false,"mapping":[{"identity":"rim","map":"N/A"}],"max":"1","min":1,"path":"Extension.url","representation":["xmlAttr"],"short":"identifies the meaning of the extension","type":[{"code":"http://hl7.org/fhirpath/System.String","extension":[{"url":"http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type","valueUri":"uri"}]}]},{"base":{"max":"1","min":0,"path":"Extension.value[x]"},"binding":{"extension":[{"url":"http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName","valueString":"EventReason"}],"strength":"example","valueSet":"http://hl7.org/fhir/ValueSet/condition-cause"},"constraint":[{"expression":"hasValue() or (children().count() > id.count())","human":"All FHIR elements must have a @value or children","key":"ele-1","severity":"error","source":"Element","xpath":"@value|f:*|h:div"}],"definition":"Value of extension - must be one of a constrained set of the data types (see [Extensibility](extensibility.html) for a list).","id":"Extension.value[x]","isModifier":false,"isSummary":false,"mapping":[{"identity":"rim","map":"N/A"}],"max":"1","min":1,"path":"Extension.value[x]","short":"Value of extension","type":[{"code":"CodeableConcept"}]}]},"status":"draft","title":"Reason Code","type":"Extension","url":"http://hl7.org/fhir/StructureDefinition/workflow-reasonCode","version":"4.2.0"}