PackagesCanonicalsLogsProblems
    Packages
    ca.on.consent.r4@0.9.0
    http://ehealthontario.ca/fhir/StructureDefinition/ca-on-consent-pcoi-profile-Consent
{
  "description": null,
  "_filename": "StructDef-Consent.json",
  "package_name": "ca.on.consent.r4",
  "date": "2019-11-01T20:23:48.7383422+00:00",
  "derivation": "constraint",
  "meta": {
    "lastUpdated": "2019-11-01T20:23:48.234+00:00"
  },
  "publisher": null,
  "fhirVersion": "4.0.0",
  "name": "Consent",
  "mapping": [ {
    "uri": "http://hl7.org/fhir/workflow",
    "name": "Workflow Pattern",
    "identity": "workflow"
  }, {
    "uri": "http://hl7.org/v2",
    "name": "HL7 v2 Mapping",
    "identity": "v2"
  }, {
    "uri": "http://hl7.org/v3",
    "name": "RIM Mapping",
    "identity": "rim"
  }, {
    "uri": "http://hl7.org/fhir/fivews",
    "name": "FiveWs Pattern Mapping",
    "identity": "w5"
  } ],
  "abstract": false,
  "type": "Consent",
  "experimental": null,
  "resourceType": "StructureDefinition",
  "title": null,
  "package_version": "0.9.0",
  "snapshot": {
    "element": [ {
      "constraint": [ {
        "key": "dom-2",
        "human": "If the resource is contained in another resource, it SHALL NOT contain nested Resources",
        "xpath": "not(parent::f:contained and f:contained)",
        "source": "DomainResource",
        "severity": "error",
        "expression": "contained.contained.empty()"
      }, {
        "key": "dom-4",
        "human": "If a resource is contained in another resource, it SHALL NOT have a meta.versionId or a meta.lastUpdated",
        "xpath": "not(exists(f:contained/*/f:meta/f:versionId)) and not(exists(f:contained/*/f:meta/f:lastUpdated))",
        "source": "DomainResource",
        "severity": "error",
        "expression": "contained.meta.versionId.empty() and contained.meta.lastUpdated.empty()"
      }, {
        "key": "dom-3",
        "human": "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",
        "xpath": "not(exists(for $contained in f:contained return $contained[not(parent::*/descendant::f:reference/@value=concat('#', $contained/*/id/@value) or descendant::f:reference[@value='#'])]))",
        "source": "DomainResource",
        "severity": "error",
        "expression": "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()"
      }, {
        "key": "dom-6",
        "human": "A resource should have narrative for robust management",
        "xpath": "exists(f:text/h:div)",
        "source": "DomainResource",
        "severity": "warning",
        "extension": [ {
          "url": "http://hl7.org/fhir/StructureDefinition/elementdefinition-bestpractice",
          "valueBoolean": true
        }, {
          "url": "http://hl7.org/fhir/StructureDefinition/elementdefinition-bestpractice-explanation",
          "valueMarkdown": "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."
        } ],
        "expression": "text.div.exists()"
      }, {
        "key": "dom-5",
        "human": "If a resource is contained in another resource, it SHALL NOT have a security label",
        "xpath": "not(exists(f:contained/*/f:meta/f:security))",
        "source": "DomainResource",
        "severity": "error",
        "expression": "contained.meta.security.empty()"
      }, {
        "key": "ppc-4",
        "human": "IF Scope=adr, there must be a patient",
        "xpath": "exists(f:patient) or not(exists(f:scope/f:coding[f:system/@value='something' and f:code/@value='adr'])))",
        "source": "Consent",
        "severity": "error",
        "expression": "patient.exists() or scope.coding.where(system='something' and code='adr').exists().not()"
      }, {
        "key": "ppc-5",
        "human": "IF Scope=treatment, there must be a patient",
        "xpath": "exists(f:patient) or not(exists(f:scope/f:coding[f:system/@value='something' and f:code/@value='treatment'])))",
        "source": "Consent",
        "severity": "error",
        "expression": "patient.exists() or scope.coding.where(system='something' and code='treatment').exists().not()"
      }, {
        "key": "ppc-2",
        "human": "IF Scope=privacy, there must be a patient",
        "xpath": "exists(f:patient) or not(exists(f:scope/f:coding[f:system/@value='something' and f:code/@value='patient-privacy'])))",
        "source": "Consent",
        "severity": "error",
        "expression": "patient.exists() or scope.coding.where(system='something' and code='patient-privacy').exists().not()"
      }, {
        "key": "ppc-3",
        "human": "IF Scope=research, there must be a patient",
        "xpath": "exists(f:patient) or not(exists(f:scope/f:coding[f:system/@value='something' and f:code/@value='research'])))",
        "source": "Consent",
        "severity": "error",
        "expression": "patient.exists() or scope.coding.where(system='something' and code='research').exists().not()"
      }, {
        "key": "ppc-1",
        "human": "Either a Policy or PolicyRule",
        "xpath": "exists(f:policy) or exists(f:policyRule)",
        "source": "Consent",
        "severity": "error",
        "expression": "policy.exists() or policyRule.exists()"
      } ],
      "path": "Consent",
      "min": 0,
      "definition": "A record of a healthcare consumer’s  choices, which permits or denies identified recipient(s) or recipient role(s) to perform one or more actions within a given policy context, for specific purposes and periods of time.",
      "short": "A healthcare consumer's  choices to permit or deny recipients or roles to perform actions for specific purposes and periods of time",
      "mapping": [ {
        "map": "Entity. Role, or Act",
        "identity": "rim"
      }, {
        "map": "Event",
        "identity": "workflow"
      }, {
        "map": "CON",
        "identity": "v2"
      }, {
        "map": "FinancialConsent",
        "identity": "rim"
      } ],
      "max": "*",
      "id": "Consent",
      "comment": "Broadly, there are 3 key areas of consent for patients: Consent around sharing information (aka Privacy Consent Directive - Authorization to Collect, Use, or Disclose information), consent for specific treatment, or kinds of treatment, and general advance care directives.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Consent"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.id",
      "min": 0,
      "definition": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes.",
      "short": "Logical id of this artifact",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "id"
      } ],
      "max": "1",
      "id": "Consent.id",
      "condition": [ "ele-1" ],
      "comment": "The only time that a resource does not have an id is when it is being submitted to the server using a create operation.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Resource.id"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.meta",
      "min": 1,
      "definition": "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.",
      "short": "Metadata about the resource",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "Meta"
      } ],
      "mustSupport": true,
      "max": "1",
      "id": "Consent.meta",
      "condition": [ "ele-1" ],
      "base": {
        "max": "1",
        "min": 0,
        "path": "Resource.meta"
      },
      "isSummary": true
    }, {
      "path": "Consent.meta.id",
      "min": 0,
      "definition": "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.",
      "short": "Unique id for inter-element referencing",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "_code": {
          "extension": [ {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-json-type",
            "valueString": "string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-xml-type",
            "valueString": "xsd:string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-rdf-type",
            "valueString": "xsd:string"
          } ]
        }
      } ],
      "representation": [ "xmlAttr" ],
      "max": "1",
      "id": "Consent.meta.id",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Element.id"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "Extension",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Consent.meta.extension",
      "min": 0,
      "definition": "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.",
      "short": "Additional content defined by implementations",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "slicing": {
        "rules": "open",
        "description": "Extensions are always sliced by (at least) url",
        "discriminator": [ {
          "path": "url",
          "type": "value"
        } ]
      },
      "type": [ {
        "code": "Extension"
      } ],
      "alias": [ "extensions", "user content" ],
      "max": "*",
      "id": "Consent.meta.extension",
      "condition": [ "ele-1" ],
      "comment": "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.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Element.extension"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.meta.versionId",
      "min": 0,
      "definition": "The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted.",
      "short": "Version specific identifier",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "id"
      } ],
      "max": "1",
      "id": "Consent.meta.versionId",
      "condition": [ "ele-1" ],
      "comment": "The server assigns this value, and ignores what the client specifies, except in the case that the server is imposing version integrity on updates/deletes.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Meta.versionId"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.meta.lastUpdated",
      "min": 0,
      "definition": "When the resource last changed - e.g. when the version changed.",
      "short": "When the resource version last changed",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "instant"
      } ],
      "max": "1",
      "id": "Consent.meta.lastUpdated",
      "condition": [ "ele-1" ],
      "comment": "This value is always populated except when the resource is first being created. The server / resource manager sets this value; what a client provides is irrelevant. This is equivalent to the HTTP Last-Modified and SHOULD have the same value on a [read](http.html#read) interaction.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Meta.lastUpdated"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.meta.source",
      "min": 0,
      "definition": "A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc.",
      "short": "Identifies where the resource comes from",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "uri"
      } ],
      "max": "1",
      "id": "Consent.meta.source",
      "condition": [ "ele-1" ],
      "comment": "In the provenance resource, this corresponds to Provenance.entity.what[x]. The exact use of the source (and the implied Provenance.entity.role) is left to implementer discretion. Only one nominated source is allowed; for additional provenance details, a full Provenance resource should be used. \n\nThis element can be used to indicate where the current master source of a resource that has a canonical URL if the resource is no longer hosted at the canonical URL.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Meta.source"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.meta.profile",
      "min": 1,
      "definition": "A list of profiles (references to [StructureDefinition](structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](structuredefinition-definitions.html#StructureDefinition.url).",
      "short": "Profiles this resource claims to conform to",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "canonical",
        "targetProfile": [ "http://hl7.org/fhir/StructureDefinition/StructureDefinition" ]
      } ],
      "mustSupport": true,
      "max": "*",
      "id": "Consent.meta.profile",
      "condition": [ "ele-1" ],
      "comment": "#### **_` FOR PCOI USAGE: The meta.profile = http://ehealthontario.ca/fhir/StructureDefinition/ca-on-consent-pcoi-profile-Consent|1.0.0 `_** \r\n\r\nIt is up to the server and/or other infrastructure of policy to determine whether/how these claims are verified and/or updated over time.  The list of profile URLs is a set.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Meta.profile"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.meta.security",
      "min": 0,
      "definition": "Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.",
      "short": "Security Labels applied to this resource",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "CE/CNE/CWE subset one of the sets of component 1-3 or 4-6",
        "identity": "v2"
      }, {
        "map": "CV",
        "identity": "rim"
      }, {
        "map": "fhir:Coding rdfs:subClassOf dt:CDCoding",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "Coding"
      } ],
      "binding": {
        "strength": "extensible",
        "valueSet": "http://hl7.org/fhir/ValueSet/security-labels",
        "description": "Security Labels from the Healthcare Privacy and Security Classification System."
      },
      "max": "*",
      "id": "Consent.meta.security",
      "condition": [ "ele-1" ],
      "comment": "The security labels can be updated without changing the stated version of the resource. The list of security labels is a set. Uniqueness is based the system/code, and version and display are ignored.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Meta.security"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.meta.tag",
      "min": 0,
      "definition": "Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.",
      "short": "Tags applied to this resource",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "CE/CNE/CWE subset one of the sets of component 1-3 or 4-6",
        "identity": "v2"
      }, {
        "map": "CV",
        "identity": "rim"
      }, {
        "map": "fhir:Coding rdfs:subClassOf dt:CDCoding",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "Coding"
      } ],
      "binding": {
        "strength": "example",
        "valueSet": "http://hl7.org/fhir/ValueSet/common-tags",
        "description": "Codes that represent various types of tags, commonly workflow-related; e.g. \"Needs review by Dr. Jones\"."
      },
      "max": "*",
      "id": "Consent.meta.tag",
      "condition": [ "ele-1" ],
      "comment": "The tags can be updated without changing the stated version of the resource. The list of tags is a set. Uniqueness is based the system/code, and version and display are ignored.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Meta.tag"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.implicitRules",
      "min": 0,
      "definition": "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.",
      "isModifier": true,
      "short": "A set of rules under which this content was created",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "uri"
      } ],
      "max": "1",
      "id": "Consent.implicitRules",
      "condition": [ "ele-1" ],
      "comment": "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.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Resource.implicitRules"
      },
      "isModifierReason": "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",
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.language",
      "min": 0,
      "definition": "The base language in which the resource is written.",
      "short": "Language of the resource content",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "code"
      } ],
      "binding": {
        "strength": "preferred",
        "valueSet": "http://hl7.org/fhir/ValueSet/languages",
        "description": "A human language."
      },
      "max": "1",
      "id": "Consent.language",
      "condition": [ "ele-1" ],
      "comment": "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).",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Resource.language"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.text",
      "min": 0,
      "definition": "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.",
      "short": "Text summary of the resource, for human interpretation",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      }, {
        "map": "Act.text?",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "Narrative"
      } ],
      "alias": [ "narrative", "html", "xhtml", "display" ],
      "max": "1",
      "id": "Consent.text",
      "condition": [ "ele-1" ],
      "comment": "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.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "DomainResource.text"
      }
    }, {
      "path": "Consent.contained",
      "min": 0,
      "definition": "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.",
      "short": "Contained, inline Resources",
      "mapping": [ {
        "map": "Entity. Role, or Act",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "Resource"
      } ],
      "alias": [ "inline resources", "anonymous resources", "contained resources" ],
      "max": "*",
      "id": "Consent.contained",
      "comment": "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.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "DomainResource.contained"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "Extension",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Consent.extension",
      "min": 0,
      "definition": "May be used to represent additional information that is not part of the basic definition of the resource. 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.",
      "short": "Additional content defined by implementations",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "slicing": {
        "rules": "open",
        "description": "Extensions are always sliced by (at least) url",
        "discriminator": [ {
          "path": "url",
          "type": "value"
        } ]
      },
      "type": [ {
        "code": "Extension"
      } ],
      "alias": [ "extensions", "user content" ],
      "max": "*",
      "id": "Consent.extension",
      "condition": [ "ele-1" ],
      "comment": "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.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "DomainResource.extension"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "Extension",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Consent.modifierExtension",
      "requirements": "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](extensibility.html#modifierExtension).",
      "min": 0,
      "definition": "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.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
      "isModifier": true,
      "short": "Extensions that cannot be ignored",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "slicing": {
        "rules": "open",
        "description": "Extensions are always sliced by (at least) url",
        "discriminator": [ {
          "path": "url",
          "type": "value"
        } ]
      },
      "type": [ {
        "code": "Extension"
      } ],
      "alias": [ "extensions", "user content" ],
      "max": "*",
      "id": "Consent.modifierExtension",
      "condition": [ "ele-1" ],
      "comment": "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.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "DomainResource.modifierExtension"
      },
      "isModifierReason": "Modifier extensions are expected to modify the meaning or interpretation of the resource that contains them"
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.identifier",
      "min": 0,
      "definition": "Unique identifier for this copy of the Consent Statement.\r\neHealth Ontario and Implementers will work together to define the value passed in this field, if any.",
      "short": "Identifier for this record (external references)",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "CX / EI (occasionally, more often EI maps to a resource id or a URL)",
        "identity": "v2"
      }, {
        "map": "II - The Identifier class is a little looser than the v3 type II because it allows URIs as well as registered OIDs or GUIDs.  Also maps to Role[classCode=IDENT]",
        "identity": "rim"
      }, {
        "map": "Identifier",
        "identity": "servd"
      }, {
        "map": "Event.identifier",
        "identity": "workflow"
      }, {
        "map": "FiveWs.identifier",
        "identity": "w5"
      }, {
        "map": ".id",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "Identifier"
      } ],
      "mustSupport": false,
      "max": "*",
      "id": "Consent.identifier",
      "condition": [ "ele-1" ],
      "comment": "This identifier identifies this copy of the consent. Where this identifier is also used elsewhere as the identifier for a consent record (e.g. a CDA consent document) then the consent details are expected to be the same.\r\nTBD if an identifier is necessary; this field can be used to store an identifier from the submitting system for reconciliation. DICS requires a msid from the Message Header (this value can come from the client, or could be HIAL/Gateway-assigned). CDR uses msgid from the SOAP Header  from the SOAP request msg. CMTA or the gateway would need to turn/store this ID for future retrieval/reference.",
      "example": [ {
        "label": "General",
        "valueIdentifier": {
          "value": "Local eCMS identifier",
          "system": "urn:ietf:rfc:3986"
        }
      } ],
      "base": {
        "max": "*",
        "min": 0,
        "path": "Consent.identifier"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.status",
      "fixedCode": "active",
      "requirements": "The Consent Directive that is pointed to might be in various lifecycle states, e.g., a revoked Consent Directive.",
      "min": 1,
      "definition": "Indicates the current state of this consent.\r\nFor consent overrides, this value will be fixed to \"active\".",
      "isModifier": true,
      "short": "draft | proposed | active | rejected | inactive | entered-in-error",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "Event.status",
        "identity": "workflow"
      }, {
        "map": "FiveWs.status",
        "identity": "w5"
      }, {
        "map": "HL7 Table 0498 - Consent Status",
        "identity": "v2"
      }, {
        "map": ".statusCode",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "code"
      } ],
      "mustSupport": true,
      "binding": {
        "strength": "required",
        "valueSet": "http://hl7.org/fhir/ValueSet/consent-state-codes|4.0.0",
        "description": "Indicates the state of the consent."
      },
      "max": "1",
      "id": "Consent.status",
      "condition": [ "ele-1" ],
      "comment": "This element is labeled as a modifier because the status contains the codes rejected and entered-in-error that mark the Consent as not currently valid.",
      "base": {
        "max": "1",
        "min": 1,
        "path": "Consent.status"
      },
      "isModifierReason": "This element is labelled as a modifier because it is a status element that contains status entered-in-error which means that the resource should not be treated as valid",
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.scope",
      "min": 1,
      "definition": "A selector of the type of consent being presented: ADR, Privacy, Treatment, Research.  This list is now extensible.",
      "isModifier": true,
      "short": "Which of the four areas this resource covers (extensible)",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "CE/CNE/CWE",
        "identity": "v2"
      }, {
        "map": "CD",
        "identity": "rim"
      }, {
        "map": "fhir:CodeableConcept rdfs:subClassOf dt:CD",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "CodeableConcept"
      } ],
      "mustSupport": true,
      "binding": {
        "strength": "extensible",
        "valueSet": "http://hl7.org/fhir/ValueSet/consent-scope",
        "description": "The four anticipated uses for the Consent Resource."
      },
      "max": "1",
      "id": "Consent.scope",
      "condition": [ "ele-1" ],
      "comment": "Not all terminology uses fit this general pattern. In some cases, models should not use CodeableConcept and use Coding directly and provide their own structure for managing text, codings, translations and the relationship between elements and pre- and post-coordination.",
      "base": {
        "max": "1",
        "min": 1,
        "path": "Consent.scope"
      },
      "isModifierReason": "Allows changes to codes based on scope selection",
      "isSummary": true
    }, {
      "path": "Consent.scope.id",
      "min": 0,
      "definition": "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.",
      "short": "Unique id for inter-element referencing",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "_code": {
          "extension": [ {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-json-type",
            "valueString": "string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-xml-type",
            "valueString": "xsd:string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-rdf-type",
            "valueString": "xsd:string"
          } ]
        }
      } ],
      "representation": [ "xmlAttr" ],
      "max": "1",
      "id": "Consent.scope.id",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Element.id"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "Extension",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Consent.scope.extension",
      "min": 0,
      "definition": "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.",
      "short": "Additional content defined by implementations",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "slicing": {
        "rules": "open",
        "description": "Extensions are always sliced by (at least) url",
        "discriminator": [ {
          "path": "url",
          "type": "value"
        } ]
      },
      "type": [ {
        "code": "Extension"
      } ],
      "alias": [ "extensions", "user content" ],
      "max": "*",
      "id": "Consent.scope.extension",
      "condition": [ "ele-1" ],
      "comment": "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.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Element.extension"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.scope.coding",
      "requirements": "Allows for alternative encodings within a code system, and translations to other code systems.",
      "min": 1,
      "definition": "A reference to a code defined by a terminology system.",
      "short": "Code defined by a terminology system",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "CE/CNE/CWE subset one of the sets of component 1-3 or 4-6",
        "identity": "v2"
      }, {
        "map": "CV",
        "identity": "rim"
      }, {
        "map": "fhir:Coding rdfs:subClassOf dt:CDCoding",
        "identity": "orim"
      }, {
        "map": "C*E.1-8, C*E.10-22",
        "identity": "v2"
      }, {
        "map": "union(., ./translation)",
        "identity": "rim"
      }, {
        "map": "fhir:CodeableConcept.coding rdfs:subPropertyOf dt:CD.coding",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "Coding"
      } ],
      "mustSupport": true,
      "max": "1",
      "id": "Consent.scope.coding",
      "condition": [ "ele-1" ],
      "comment": "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.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "CodeableConcept.coding"
      },
      "isSummary": true
    }, {
      "path": "Consent.scope.coding.id",
      "min": 0,
      "definition": "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.",
      "short": "Unique id for inter-element referencing",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "_code": {
          "extension": [ {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-json-type",
            "valueString": "string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-xml-type",
            "valueString": "xsd:string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-rdf-type",
            "valueString": "xsd:string"
          } ]
        }
      } ],
      "representation": [ "xmlAttr" ],
      "max": "1",
      "id": "Consent.scope.coding.id",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Element.id"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "Extension",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Consent.scope.coding.extension",
      "min": 0,
      "definition": "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.",
      "short": "Additional content defined by implementations",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "slicing": {
        "rules": "open",
        "description": "Extensions are always sliced by (at least) url",
        "discriminator": [ {
          "path": "url",
          "type": "value"
        } ]
      },
      "type": [ {
        "code": "Extension"
      } ],
      "alias": [ "extensions", "user content" ],
      "max": "*",
      "id": "Consent.scope.coding.extension",
      "condition": [ "ele-1" ],
      "comment": "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.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Element.extension"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.scope.coding.system",
      "requirements": "Need to be unambiguous about the source of the definition of the symbol.",
      "min": 1,
      "definition": "The identification of the code system that defines the meaning of the symbol in the code.",
      "short": "Identity of the terminology system",
      "fixedUri": "http://terminology.hl7.org/CodeSystem/consentscope",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.3",
        "identity": "v2"
      }, {
        "map": "./codeSystem",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.system rdfs:subPropertyOf dt:CDCoding.codeSystem",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "uri"
      } ],
      "mustSupport": true,
      "max": "1",
      "id": "Consent.scope.coding.system",
      "condition": [ "ele-1" ],
      "comment": "The URI may be an OID (urn:oid:...) or a UUID (urn:uuid:...).  OIDs and UUIDs SHALL be references to the HL7 OID registry. Otherwise, the URI should come from HL7's list of FHIR defined special URIs or it should reference to some definition that establishes the system clearly and unambiguously.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.system"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.scope.coding.version",
      "min": 0,
      "definition": "The version of the code system which was used when choosing this code. Note that a well-maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged.",
      "short": "Version of the system - if relevant",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.7",
        "identity": "v2"
      }, {
        "map": "./codeSystemVersion",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.version rdfs:subPropertyOf dt:CDCoding.codeSystemVersion",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "string"
      } ],
      "max": "1",
      "id": "Consent.scope.coding.version",
      "condition": [ "ele-1" ],
      "comment": "Where the terminology does not clearly define what string should be used to identify code system versions, the recommendation is to use the date (expressed in FHIR date format) on which that version was officially published as the version date.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.version"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.scope.coding.code",
      "fixedCode": "patient-privacy",
      "requirements": "Need to refer to a particular code in the system.",
      "min": 1,
      "definition": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post-coordination).",
      "short": "Symbol in syntax defined by the system",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.1",
        "identity": "v2"
      }, {
        "map": "./code",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.code rdfs:subPropertyOf dt:CDCoding.code",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "code"
      } ],
      "mustSupport": true,
      "max": "1",
      "id": "Consent.scope.coding.code",
      "condition": [ "ele-1" ],
      "comment": "Note that FHIR strings SHALL NOT exceed 1MB in size",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.code"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.scope.coding.display",
      "requirements": "Need to be able to carry a human-readable meaning of the code for readers that do not know  the system.",
      "min": 1,
      "definition": "A representation of the meaning of the code in the system, following the rules of the system.",
      "short": "Representation defined by the system",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.2 - but note this is not well followed",
        "identity": "v2"
      }, {
        "map": "CV.displayName",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.display rdfs:subPropertyOf dt:CDCoding.displayName",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "string"
      } ],
      "mustSupport": true,
      "max": "1",
      "fixedString": "Privacy Consent",
      "id": "Consent.scope.coding.display",
      "condition": [ "ele-1" ],
      "comment": "Note that FHIR strings SHALL NOT exceed 1MB in size",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.display"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.scope.coding.userSelected",
      "requirements": "This has been identified as a clinical safety criterium - that this exact system/code pair was chosen explicitly, rather than inferred by the system based on some rules or language processing.",
      "min": 0,
      "definition": "Indicates that this coding was chosen by a user directly - e.g. off a pick list of available items (codes or displays).",
      "short": "If this coding was chosen directly by the user",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "Sometimes implied by being first",
        "identity": "v2"
      }, {
        "map": "CD.codingRationale",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.userSelected fhir:mapsTo dt:CDCoding.codingRationale. fhir:Coding.userSelected fhir:hasMap fhir:Coding.userSelected.map. fhir:Coding.userSelected.map a fhir:Map;   fhir:target dt:CDCoding.codingRationale. fhir:Coding.userSelected\\#true a [     fhir:source \"true\";     fhir:target dt:CDCoding.codingRationale\\#O   ]",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "boolean"
      } ],
      "max": "1",
      "id": "Consent.scope.coding.userSelected",
      "condition": [ "ele-1" ],
      "comment": "Amongst a set of alternatives, a directly chosen code is the most appropriate starting point for new translations. There is some ambiguity about what exactly 'directly chosen' implies, and trading partner agreement may be needed to clarify the use of this element and its consequences more completely.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.userSelected"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.scope.text",
      "requirements": "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.",
      "min": 0,
      "definition": "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.",
      "short": "Plain text representation of the concept",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.9. But note many systems use C*E.2 for this",
        "identity": "v2"
      }, {
        "map": "./originalText[mediaType/code=\"text/plain\"]/data",
        "identity": "rim"
      }, {
        "map": "fhir:CodeableConcept.text rdfs:subPropertyOf dt:CD.originalText",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "string"
      } ],
      "max": "1",
      "id": "Consent.scope.text",
      "condition": [ "ele-1" ],
      "comment": "Very often the text is the same as a displayName of one of the codings.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "CodeableConcept.text"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.category",
      "min": 1,
      "definition": "A classification of the type of consents found in the statement. This element supports indexing and retrieval of consent statements.",
      "short": "Classification of the consent statement - for indexing/retrieval",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "CE/CNE/CWE",
        "identity": "v2"
      }, {
        "map": "CD",
        "identity": "rim"
      }, {
        "map": "fhir:CodeableConcept rdfs:subClassOf dt:CD",
        "identity": "orim"
      }, {
        "map": "Event.code",
        "identity": "workflow"
      }, {
        "map": "FiveWs.class",
        "identity": "w5"
      }, {
        "map": "HL7 Table 0497 - Consent Type",
        "identity": "v2"
      }, {
        "map": "CNTRCT",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "CodeableConcept"
      } ],
      "mustSupport": true,
      "binding": {
        "strength": "extensible",
        "valueSet": "http://hl7.org/fhir/ValueSet/consent-category",
        "description": "A classification of the type of consents found in a consent statement."
      },
      "max": "1",
      "id": "Consent.category",
      "condition": [ "ele-1" ],
      "comment": "Not all terminology uses fit this general pattern. In some cases, models should not use CodeableConcept and use Coding directly and provide their own structure for managing text, codings, translations and the relationship between elements and pre- and post-coordination.",
      "base": {
        "max": "*",
        "min": 1,
        "path": "Consent.category"
      },
      "isSummary": true
    }, {
      "path": "Consent.category.id",
      "min": 0,
      "definition": "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.",
      "short": "Unique id for inter-element referencing",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "_code": {
          "extension": [ {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-json-type",
            "valueString": "string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-xml-type",
            "valueString": "xsd:string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-rdf-type",
            "valueString": "xsd:string"
          } ]
        }
      } ],
      "representation": [ "xmlAttr" ],
      "max": "1",
      "id": "Consent.category.id",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Element.id"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "Extension",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Consent.category.extension",
      "min": 0,
      "definition": "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.",
      "short": "Additional content defined by implementations",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "slicing": {
        "rules": "open",
        "description": "Extensions are always sliced by (at least) url",
        "discriminator": [ {
          "path": "url",
          "type": "value"
        } ]
      },
      "type": [ {
        "code": "Extension"
      } ],
      "alias": [ "extensions", "user content" ],
      "max": "*",
      "id": "Consent.category.extension",
      "condition": [ "ele-1" ],
      "comment": "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.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Element.extension"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.category.coding",
      "requirements": "Allows for alternative encodings within a code system, and translations to other code systems.",
      "min": 1,
      "definition": "A reference to a code defined by a terminology system.",
      "short": "Code defined by a terminology system",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "CE/CNE/CWE subset one of the sets of component 1-3 or 4-6",
        "identity": "v2"
      }, {
        "map": "CV",
        "identity": "rim"
      }, {
        "map": "fhir:Coding rdfs:subClassOf dt:CDCoding",
        "identity": "orim"
      }, {
        "map": "C*E.1-8, C*E.10-22",
        "identity": "v2"
      }, {
        "map": "union(., ./translation)",
        "identity": "rim"
      }, {
        "map": "fhir:CodeableConcept.coding rdfs:subPropertyOf dt:CD.coding",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "Coding"
      } ],
      "mustSupport": true,
      "max": "1",
      "id": "Consent.category.coding",
      "condition": [ "ele-1" ],
      "comment": "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.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "CodeableConcept.coding"
      },
      "isSummary": true
    }, {
      "path": "Consent.category.coding.id",
      "min": 0,
      "definition": "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.",
      "short": "Unique id for inter-element referencing",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "_code": {
          "extension": [ {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-json-type",
            "valueString": "string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-xml-type",
            "valueString": "xsd:string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-rdf-type",
            "valueString": "xsd:string"
          } ]
        }
      } ],
      "representation": [ "xmlAttr" ],
      "max": "1",
      "id": "Consent.category.coding.id",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Element.id"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "Extension",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Consent.category.coding.extension",
      "min": 0,
      "definition": "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.",
      "short": "Additional content defined by implementations",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "slicing": {
        "rules": "open",
        "description": "Extensions are always sliced by (at least) url",
        "discriminator": [ {
          "path": "url",
          "type": "value"
        } ]
      },
      "type": [ {
        "code": "Extension"
      } ],
      "alias": [ "extensions", "user content" ],
      "max": "*",
      "id": "Consent.category.coding.extension",
      "condition": [ "ele-1" ],
      "comment": "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.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Element.extension"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.category.coding.system",
      "requirements": "Need to be unambiguous about the source of the definition of the symbol.",
      "min": 1,
      "definition": "The identification of the code system that defines the meaning of the symbol in the code.",
      "short": "Identity of the terminology system",
      "fixedUri": "http://terminology.hl7.org/CodeSystem/v3-ActCode",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.3",
        "identity": "v2"
      }, {
        "map": "./codeSystem",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.system rdfs:subPropertyOf dt:CDCoding.codeSystem",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "uri"
      } ],
      "mustSupport": true,
      "max": "1",
      "id": "Consent.category.coding.system",
      "condition": [ "ele-1" ],
      "comment": "The URI may be an OID (urn:oid:...) or a UUID (urn:uuid:...).  OIDs and UUIDs SHALL be references to the HL7 OID registry. Otherwise, the URI should come from HL7's list of FHIR defined special URIs or it should reference to some definition that establishes the system clearly and unambiguously.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.system"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.category.coding.version",
      "min": 0,
      "definition": "The version of the code system which was used when choosing this code. Note that a well-maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged.",
      "short": "Version of the system - if relevant",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.7",
        "identity": "v2"
      }, {
        "map": "./codeSystemVersion",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.version rdfs:subPropertyOf dt:CDCoding.codeSystemVersion",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "string"
      } ],
      "max": "1",
      "id": "Consent.category.coding.version",
      "condition": [ "ele-1" ],
      "comment": "Where the terminology does not clearly define what string should be used to identify code system versions, the recommendation is to use the date (expressed in FHIR date format) on which that version was officially published as the version date.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.version"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.category.coding.code",
      "fixedCode": "INFA",
      "requirements": "Need to refer to a particular code in the system.",
      "min": 1,
      "definition": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post-coordination).",
      "short": "Symbol in syntax defined by the system",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.1",
        "identity": "v2"
      }, {
        "map": "./code",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.code rdfs:subPropertyOf dt:CDCoding.code",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "code"
      } ],
      "mustSupport": true,
      "max": "1",
      "id": "Consent.category.coding.code",
      "condition": [ "ele-1" ],
      "comment": "Note that FHIR strings SHALL NOT exceed 1MB in size",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.code"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.category.coding.display",
      "requirements": "Need to be able to carry a human-readable meaning of the code for readers that do not know  the system.",
      "min": 1,
      "definition": "A representation of the meaning of the code in the system, following the rules of the system.",
      "short": "Representation defined by the system",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.2 - but note this is not well followed",
        "identity": "v2"
      }, {
        "map": "CV.displayName",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.display rdfs:subPropertyOf dt:CDCoding.displayName",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "string"
      } ],
      "mustSupport": true,
      "max": "1",
      "fixedString": "information access",
      "id": "Consent.category.coding.display",
      "condition": [ "ele-1" ],
      "comment": "Note that FHIR strings SHALL NOT exceed 1MB in size",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.display"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.category.coding.userSelected",
      "requirements": "This has been identified as a clinical safety criterium - that this exact system/code pair was chosen explicitly, rather than inferred by the system based on some rules or language processing.",
      "min": 0,
      "definition": "Indicates that this coding was chosen by a user directly - e.g. off a pick list of available items (codes or displays).",
      "short": "If this coding was chosen directly by the user",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "Sometimes implied by being first",
        "identity": "v2"
      }, {
        "map": "CD.codingRationale",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.userSelected fhir:mapsTo dt:CDCoding.codingRationale. fhir:Coding.userSelected fhir:hasMap fhir:Coding.userSelected.map. fhir:Coding.userSelected.map a fhir:Map;   fhir:target dt:CDCoding.codingRationale. fhir:Coding.userSelected\\#true a [     fhir:source \"true\";     fhir:target dt:CDCoding.codingRationale\\#O   ]",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "boolean"
      } ],
      "max": "1",
      "id": "Consent.category.coding.userSelected",
      "condition": [ "ele-1" ],
      "comment": "Amongst a set of alternatives, a directly chosen code is the most appropriate starting point for new translations. There is some ambiguity about what exactly 'directly chosen' implies, and trading partner agreement may be needed to clarify the use of this element and its consequences more completely.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.userSelected"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.category.text",
      "requirements": "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.",
      "min": 0,
      "definition": "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.",
      "short": "Plain text representation of the concept",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.9. But note many systems use C*E.2 for this",
        "identity": "v2"
      }, {
        "map": "./originalText[mediaType/code=\"text/plain\"]/data",
        "identity": "rim"
      }, {
        "map": "fhir:CodeableConcept.text rdfs:subPropertyOf dt:CD.originalText",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "string"
      } ],
      "max": "1",
      "id": "Consent.category.text",
      "condition": [ "ele-1" ],
      "comment": "Very often the text is the same as a displayName of one of the codings.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "CodeableConcept.text"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ref-1",
        "human": "SHALL have a contained resource if a local reference is provided",
        "xpath": "not(starts-with(f:reference/@value, '#')) or exists(ancestor::*[self::f:entry or self::f:parameter]/f:resource/f:*/f:contained/f:*[f:id/@value=substring-after(current()/f:reference/@value, '#')]|/*/f:contained/f:*[f:id/@value=substring-after(current()/f:reference/@value, '#')])",
        "source": "Reference",
        "severity": "error",
        "expression": "reference.startsWith('#').not() or (reference.substring(1).trace('url') in %resource.contained.id.trace('ids'))"
      } ],
      "path": "Consent.patient",
      "min": 1,
      "definition": "The patient/healthcare consumer to whom this consent applies.",
      "short": "Who the consent applies to",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "The target of a resource reference is a RIM entry point (Act, Role, or Entity)",
        "identity": "rim"
      }, {
        "map": "Event.subject",
        "identity": "workflow"
      }, {
        "map": "FiveWs.subject[x]",
        "identity": "w5"
      }, {
        "map": "Role",
        "identity": "rim"
      }, {
        "map": "FiveWs.subject",
        "identity": "w5"
      } ],
      "type": [ {
        "code": "Reference",
        "targetProfile": [ "http://ehealthontario.ca/fhir/StructureDefinition/ca-on-consent-pcoi-profile-Patient" ]
      } ],
      "mustSupport": true,
      "max": "1",
      "id": "Consent.patient",
      "condition": [ "ele-1" ],
      "comment": "Commonly, the patient the consent pertains to is the author, but for young and old people, it may be some other person.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Consent.patient"
      },
      "isSummary": true
    }, {
      "path": "Consent.patient.id",
      "min": 0,
      "definition": "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.",
      "short": "Unique id for inter-element referencing",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "_code": {
          "extension": [ {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-json-type",
            "valueString": "string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-xml-type",
            "valueString": "xsd:string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-rdf-type",
            "valueString": "xsd:string"
          } ]
        }
      } ],
      "representation": [ "xmlAttr" ],
      "max": "1",
      "id": "Consent.patient.id",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Element.id"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "Extension",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Consent.patient.extension",
      "min": 0,
      "definition": "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.",
      "short": "Additional content defined by implementations",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "slicing": {
        "rules": "open",
        "description": "Extensions are always sliced by (at least) url",
        "discriminator": [ {
          "path": "url",
          "type": "value"
        } ]
      },
      "type": [ {
        "code": "Extension"
      } ],
      "alias": [ "extensions", "user content" ],
      "max": "*",
      "id": "Consent.patient.extension",
      "condition": [ "ele-1" ],
      "comment": "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.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Element.extension"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.patient.reference",
      "min": 1,
      "definition": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources.",
      "short": "Literal reference, Relative, internal or absolute URL",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "string"
      } ],
      "mustSupport": true,
      "max": "1",
      "id": "Consent.patient.reference",
      "condition": [ "ele-1", "ref-1" ],
      "comment": "Using absolute URLs provides a stable scalable approach suitable for a cloud/web context, while using relative/logical references provides a flexible approach suitable for use when trading across closed eco-system boundaries.   Absolute URLs do not need to point to a FHIR RESTful server, though this is the preferred approach. If the URL conforms to the structure \"/[type]/[id]\" then it should be assumed that the reference is to a FHIR RESTful server.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Reference.reference"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.patient.type",
      "min": 0,
      "definition": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources).",
      "short": "Type the reference refers to (e.g. \"Patient\")",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "uri"
      } ],
      "binding": {
        "strength": "extensible",
        "valueSet": "http://hl7.org/fhir/ValueSet/resource-types",
        "description": "Aa resource (or, for logical models, the URI of the logical model)."
      },
      "max": "1",
      "id": "Consent.patient.type",
      "condition": [ "ele-1" ],
      "comment": "This element is used to indicate the type of  the target of the reference. This may be used which ever of the other elements are populated (or not). In some cases, the type of the target may be determined by inspection of the reference (e.g. a RESTful URL) or by resolving the target of the reference; if both the type and a reference is provided, the reference SHALL resolve to a resource of the same type as that specified.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Reference.type"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.patient.identifier",
      "min": 0,
      "definition": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference.",
      "short": "Logical reference, when literal reference is not known",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "CX / EI (occasionally, more often EI maps to a resource id or a URL)",
        "identity": "v2"
      }, {
        "map": "II - The Identifier class is a little looser than the v3 type II because it allows URIs as well as registered OIDs or GUIDs.  Also maps to Role[classCode=IDENT]",
        "identity": "rim"
      }, {
        "map": "Identifier",
        "identity": "servd"
      }, {
        "map": ".identifier",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "Identifier"
      } ],
      "max": "1",
      "id": "Consent.patient.identifier",
      "condition": [ "ele-1" ],
      "comment": "When an identifier is provided in place of a reference, any system processing the reference will only be able to resolve the identifier to a reference if it understands the business context in which the identifier is used. Sometimes this is global (e.g. a national identifier) but often it is not. For this reason, none of the useful mechanisms described for working with references (e.g. chaining, includes) are possible, nor should servers be expected to be able resolve the reference. Servers may accept an identifier based reference untouched, resolve it, and/or reject it - see CapabilityStatement.rest.resource.referencePolicy. \n\nWhen both an identifier and a literal reference are provided, the literal reference is preferred. Applications processing the resource are allowed - but not required - to check that the identifier matches the literal reference\n\nApplications converting a logical reference to a literal reference may choose to leave the logical reference present, or remove it.\n\nReference is intended to point to a structure that can potentially be expressed as a FHIR resource, though there is no need for it to exist as an actual FHIR resource instance - except in as much as an application wishes to actual find the target of the reference. The content referred to be the identifier must meet the logical constraints implied by any limitations on what resource types are permitted for the reference.  For example, it would not be legitimate to send the identifier for a drug prescription if the type were Reference(Observation|DiagnosticReport).  One of the use-cases for Reference.identifier is the situation where no FHIR representation exists (where the type is Reference (Any).",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Reference.identifier"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.patient.display",
      "min": 0,
      "definition": "Plain text narrative that identifies the resource in addition to the resource reference.",
      "short": "Text alternative for the resource",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "string"
      } ],
      "max": "1",
      "id": "Consent.patient.display",
      "condition": [ "ele-1" ],
      "comment": "This is generally not the same as the Resource.text of the referenced resource.  The purpose is to identify what's being referenced, not to fully describe it.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Reference.display"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.dateTime",
      "min": 0,
      "definition": "When this  Consent was issued / created / indexed.",
      "short": "When this Consent was created or indexed",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "Event.occurrence[x]",
        "identity": "workflow"
      }, {
        "map": "FiveWs.recorded",
        "identity": "w5"
      }, {
        "map": "Field 13/ Consent Decision Date",
        "identity": "v2"
      }, {
        "map": "FinancialConsent effectiveTime",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "dateTime"
      } ],
      "max": "1",
      "id": "Consent.dateTime",
      "condition": [ "ele-1" ],
      "comment": "This is not the time of the original consent, but the time that this statement was made or derived.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Consent.dateTime"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ref-1",
        "human": "SHALL have a contained resource if a local reference is provided",
        "xpath": "not(starts-with(f:reference/@value, '#')) or exists(ancestor::*[self::f:entry or self::f:parameter]/f:resource/f:*/f:contained/f:*[f:id/@value=substring-after(current()/f:reference/@value, '#')]|/*/f:contained/f:*[f:id/@value=substring-after(current()/f:reference/@value, '#')])",
        "source": "Reference",
        "severity": "error",
        "expression": "reference.startsWith('#').not() or (reference.substring(1).trace('url') in %resource.contained.id.trace('ids'))"
      } ],
      "path": "Consent.performer",
      "min": 1,
      "definition": "Either the Grantor, which is the entity responsible for granting the rights listed in a Consent Directive or the Grantee, which is the entity responsible for complying with the Consent Directive, including any obligations or limitations on authorizations and enforcement of prohibitions.\r\nOnly Patient and RelatedPerson are in the scope of the current release. Practitioner-initiated Consent Override",
      "short": "Who is agreeing to the policy and rules",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "The target of a resource reference is a RIM entry point (Act, Role, or Entity)",
        "identity": "rim"
      }, {
        "map": "Event.performer",
        "identity": "workflow"
      }, {
        "map": "FiveWs.actor",
        "identity": "w5"
      }, {
        "map": "Field 24/ ConsenterID",
        "identity": "v2"
      } ],
      "type": [ {
        "code": "Reference",
        "targetProfile": [ "http://ehealthontario.ca/fhir/StructureDefinition/ca-on-consent-pcoi-profile-Patient", "http://ehealthontario.ca/fhir/StructureDefinition/ca-on-consent-pcoi-profile-RelatedPerson", "http://ehealthontario.ca/fhir/StructureDefinition/ca-on-consent-pcoi-profile-Practitioner", "http://ehealthontario.ca/fhir/StructureDefinition/ca-on-consent-pcoi-profile-Organization" ]
      } ],
      "mustSupport": true,
      "alias": [ "consentor" ],
      "max": "1",
      "id": "Consent.performer",
      "condition": [ "ele-1" ],
      "comment": "Commonly, the patient the consent pertains to is the consentor, but particularly for young and old people, it may be some other person - e.g. a legal guardian.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Consent.performer"
      },
      "isSummary": true
    }, {
      "path": "Consent.performer.id",
      "min": 0,
      "definition": "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.",
      "short": "Unique id for inter-element referencing",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "_code": {
          "extension": [ {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-json-type",
            "valueString": "string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-xml-type",
            "valueString": "xsd:string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-rdf-type",
            "valueString": "xsd:string"
          } ]
        }
      } ],
      "representation": [ "xmlAttr" ],
      "max": "1",
      "id": "Consent.performer.id",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Element.id"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "Extension",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Consent.performer.extension",
      "min": 0,
      "definition": "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.",
      "short": "Additional content defined by implementations",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "slicing": {
        "rules": "open",
        "description": "Extensions are always sliced by (at least) url",
        "discriminator": [ {
          "path": "url",
          "type": "value"
        } ]
      },
      "type": [ {
        "code": "Extension"
      } ],
      "alias": [ "extensions", "user content" ],
      "max": "*",
      "id": "Consent.performer.extension",
      "condition": [ "ele-1" ],
      "comment": "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.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Element.extension"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.performer.reference",
      "min": 1,
      "definition": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources.",
      "short": "Literal reference, Relative, internal or absolute URL",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "string"
      } ],
      "mustSupport": true,
      "max": "1",
      "id": "Consent.performer.reference",
      "condition": [ "ele-1", "ref-1" ],
      "comment": "Using absolute URLs provides a stable scalable approach suitable for a cloud/web context, while using relative/logical references provides a flexible approach suitable for use when trading across closed eco-system boundaries.   Absolute URLs do not need to point to a FHIR RESTful server, though this is the preferred approach. If the URL conforms to the structure \"/[type]/[id]\" then it should be assumed that the reference is to a FHIR RESTful server.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Reference.reference"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.performer.type",
      "min": 0,
      "definition": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources).",
      "short": "Type the reference refers to (e.g. \"Patient\")",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "uri"
      } ],
      "binding": {
        "strength": "extensible",
        "valueSet": "http://hl7.org/fhir/ValueSet/resource-types",
        "description": "Aa resource (or, for logical models, the URI of the logical model)."
      },
      "max": "1",
      "id": "Consent.performer.type",
      "condition": [ "ele-1" ],
      "comment": "This element is used to indicate the type of  the target of the reference. This may be used which ever of the other elements are populated (or not). In some cases, the type of the target may be determined by inspection of the reference (e.g. a RESTful URL) or by resolving the target of the reference; if both the type and a reference is provided, the reference SHALL resolve to a resource of the same type as that specified.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Reference.type"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.performer.identifier",
      "min": 0,
      "definition": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference.",
      "short": "Logical reference, when literal reference is not known",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "CX / EI (occasionally, more often EI maps to a resource id or a URL)",
        "identity": "v2"
      }, {
        "map": "II - The Identifier class is a little looser than the v3 type II because it allows URIs as well as registered OIDs or GUIDs.  Also maps to Role[classCode=IDENT]",
        "identity": "rim"
      }, {
        "map": "Identifier",
        "identity": "servd"
      }, {
        "map": ".identifier",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "Identifier"
      } ],
      "max": "1",
      "id": "Consent.performer.identifier",
      "condition": [ "ele-1" ],
      "comment": "When an identifier is provided in place of a reference, any system processing the reference will only be able to resolve the identifier to a reference if it understands the business context in which the identifier is used. Sometimes this is global (e.g. a national identifier) but often it is not. For this reason, none of the useful mechanisms described for working with references (e.g. chaining, includes) are possible, nor should servers be expected to be able resolve the reference. Servers may accept an identifier based reference untouched, resolve it, and/or reject it - see CapabilityStatement.rest.resource.referencePolicy. \n\nWhen both an identifier and a literal reference are provided, the literal reference is preferred. Applications processing the resource are allowed - but not required - to check that the identifier matches the literal reference\n\nApplications converting a logical reference to a literal reference may choose to leave the logical reference present, or remove it.\n\nReference is intended to point to a structure that can potentially be expressed as a FHIR resource, though there is no need for it to exist as an actual FHIR resource instance - except in as much as an application wishes to actual find the target of the reference. The content referred to be the identifier must meet the logical constraints implied by any limitations on what resource types are permitted for the reference.  For example, it would not be legitimate to send the identifier for a drug prescription if the type were Reference(Observation|DiagnosticReport).  One of the use-cases for Reference.identifier is the situation where no FHIR representation exists (where the type is Reference (Any).",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Reference.identifier"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.performer.display",
      "min": 0,
      "definition": "Plain text narrative that identifies the resource in addition to the resource reference.",
      "short": "Text alternative for the resource",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "string"
      } ],
      "max": "1",
      "id": "Consent.performer.display",
      "condition": [ "ele-1" ],
      "comment": "This is generally not the same as the Resource.text of the referenced resource.  The purpose is to identify what's being referenced, not to fully describe it.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Reference.display"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ref-1",
        "human": "SHALL have a contained resource if a local reference is provided",
        "xpath": "not(starts-with(f:reference/@value, '#')) or exists(ancestor::*[self::f:entry or self::f:parameter]/f:resource/f:*/f:contained/f:*[f:id/@value=substring-after(current()/f:reference/@value, '#')]|/*/f:contained/f:*[f:id/@value=substring-after(current()/f:reference/@value, '#')])",
        "source": "Reference",
        "severity": "error",
        "expression": "reference.startsWith('#').not() or (reference.substring(1).trace('url') in %resource.contained.id.trace('ids'))"
      } ],
      "path": "Consent.organization",
      "min": 1,
      "definition": "The organization that manages the consent, and the framework within which it is executed.\r\nFor PCOI, this captures the facility name and identifier of the \"Under Authority Of\" organization.",
      "short": "Custodian of the consent",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "The target of a resource reference is a RIM entry point (Act, Role, or Entity)",
        "identity": "rim"
      }, {
        "map": "Event.performer",
        "identity": "workflow"
      }, {
        "map": "FiveWs.witness",
        "identity": "w5"
      } ],
      "type": [ {
        "code": "Reference",
        "targetProfile": [ "http://ehealthontario.ca/fhir/StructureDefinition/ca-on-consent-pcoi-profile-Organization" ]
      } ],
      "mustSupport": true,
      "alias": [ "custodian" ],
      "max": "1",
      "id": "Consent.organization",
      "condition": [ "ele-1" ],
      "comment": "References SHALL be a reference to an actual FHIR resource, and SHALL be resolveable (allowing for access control, temporary unavailability, etc.). Resolution can be either by retrieval from the URL, or, where applicable by resource type, by treating an absolute reference as a canonical URL and looking it up in a local registry/repository.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Consent.organization"
      },
      "isSummary": true
    }, {
      "path": "Consent.organization.id",
      "min": 0,
      "definition": "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.",
      "short": "Unique id for inter-element referencing",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "_code": {
          "extension": [ {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-json-type",
            "valueString": "string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-xml-type",
            "valueString": "xsd:string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-rdf-type",
            "valueString": "xsd:string"
          } ]
        }
      } ],
      "representation": [ "xmlAttr" ],
      "max": "1",
      "id": "Consent.organization.id",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Element.id"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "Extension",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Consent.organization.extension",
      "min": 0,
      "definition": "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.",
      "short": "Additional content defined by implementations",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "slicing": {
        "rules": "open",
        "description": "Extensions are always sliced by (at least) url",
        "discriminator": [ {
          "path": "url",
          "type": "value"
        } ]
      },
      "type": [ {
        "code": "Extension"
      } ],
      "alias": [ "extensions", "user content" ],
      "max": "*",
      "id": "Consent.organization.extension",
      "condition": [ "ele-1" ],
      "comment": "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.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Element.extension"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.organization.reference",
      "min": 1,
      "definition": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources.",
      "short": "Literal reference, Relative, internal or absolute URL",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "string"
      } ],
      "mustSupport": true,
      "max": "1",
      "id": "Consent.organization.reference",
      "condition": [ "ele-1", "ref-1" ],
      "comment": "Using absolute URLs provides a stable scalable approach suitable for a cloud/web context, while using relative/logical references provides a flexible approach suitable for use when trading across closed eco-system boundaries.   Absolute URLs do not need to point to a FHIR RESTful server, though this is the preferred approach. If the URL conforms to the structure \"/[type]/[id]\" then it should be assumed that the reference is to a FHIR RESTful server.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Reference.reference"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.organization.type",
      "min": 0,
      "definition": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources).",
      "short": "Type the reference refers to (e.g. \"Patient\")",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "uri"
      } ],
      "binding": {
        "strength": "extensible",
        "valueSet": "http://hl7.org/fhir/ValueSet/resource-types",
        "description": "Aa resource (or, for logical models, the URI of the logical model)."
      },
      "max": "1",
      "id": "Consent.organization.type",
      "condition": [ "ele-1" ],
      "comment": "This element is used to indicate the type of  the target of the reference. This may be used which ever of the other elements are populated (or not). In some cases, the type of the target may be determined by inspection of the reference (e.g. a RESTful URL) or by resolving the target of the reference; if both the type and a reference is provided, the reference SHALL resolve to a resource of the same type as that specified.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Reference.type"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.organization.identifier",
      "min": 0,
      "definition": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference.",
      "short": "Logical reference, when literal reference is not known",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "CX / EI (occasionally, more often EI maps to a resource id or a URL)",
        "identity": "v2"
      }, {
        "map": "II - The Identifier class is a little looser than the v3 type II because it allows URIs as well as registered OIDs or GUIDs.  Also maps to Role[classCode=IDENT]",
        "identity": "rim"
      }, {
        "map": "Identifier",
        "identity": "servd"
      }, {
        "map": ".identifier",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "Identifier"
      } ],
      "max": "1",
      "id": "Consent.organization.identifier",
      "condition": [ "ele-1" ],
      "comment": "When an identifier is provided in place of a reference, any system processing the reference will only be able to resolve the identifier to a reference if it understands the business context in which the identifier is used. Sometimes this is global (e.g. a national identifier) but often it is not. For this reason, none of the useful mechanisms described for working with references (e.g. chaining, includes) are possible, nor should servers be expected to be able resolve the reference. Servers may accept an identifier based reference untouched, resolve it, and/or reject it - see CapabilityStatement.rest.resource.referencePolicy. \n\nWhen both an identifier and a literal reference are provided, the literal reference is preferred. Applications processing the resource are allowed - but not required - to check that the identifier matches the literal reference\n\nApplications converting a logical reference to a literal reference may choose to leave the logical reference present, or remove it.\n\nReference is intended to point to a structure that can potentially be expressed as a FHIR resource, though there is no need for it to exist as an actual FHIR resource instance - except in as much as an application wishes to actual find the target of the reference. The content referred to be the identifier must meet the logical constraints implied by any limitations on what resource types are permitted for the reference.  For example, it would not be legitimate to send the identifier for a drug prescription if the type were Reference(Observation|DiagnosticReport).  One of the use-cases for Reference.identifier is the situation where no FHIR representation exists (where the type is Reference (Any).",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Reference.identifier"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.organization.display",
      "min": 0,
      "definition": "Plain text narrative that identifies the resource in addition to the resource reference.",
      "short": "Text alternative for the resource",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "string"
      } ],
      "max": "1",
      "id": "Consent.organization.display",
      "condition": [ "ele-1" ],
      "comment": "This is generally not the same as the Resource.text of the referenced resource.  The purpose is to identify what's being referenced, not to fully describe it.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Reference.display"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "att-1",
        "human": "If the Attachment has data, it SHALL have a contentType",
        "xpath": "not(exists(f:data)) or exists(f:contentType)",
        "source": "Attachment",
        "severity": "error",
        "expression": "data.empty() or contentType.exists()"
      } ],
      "path": "Consent.source[x]",
      "min": 0,
      "definition": "The source on which this consent statement is based. The source might be a scanned original paper form, or a reference to a consent that links back to such a source, a reference to a document repository (e.g. XDS) that stores the original consent document.",
      "short": "Source from which this consent is taken",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "ED/RP",
        "identity": "v2"
      }, {
        "map": "ED",
        "identity": "rim"
      }, {
        "map": "Field 19 Informational Material Supplied Indicator",
        "identity": "v2"
      } ],
      "type": [ {
        "code": "Attachment"
      }, {
        "code": "Reference",
        "targetProfile": [ "http://hl7.org/fhir/StructureDefinition/Consent", "http://hl7.org/fhir/StructureDefinition/DocumentReference", "http://hl7.org/fhir/StructureDefinition/Contract", "http://hl7.org/fhir/StructureDefinition/QuestionnaireResponse" ]
      } ],
      "max": "1",
      "id": "Consent.source[x]",
      "condition": [ "ele-1" ],
      "comment": "The source can be contained inline (Attachment), referenced directly (Consent), referenced in a consent repository (DocumentReference), or simply by an identifier (Identifier), e.g. a CDA document id.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Consent.source[x]"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.policy",
      "min": 1,
      "definition": "The references to the policies that are included in this consent scope. Policies may be organizational, but are often defined jurisdictionally, or in law.",
      "short": "Policies covered by this consent",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "BackboneElement"
      } ],
      "mustSupport": true,
      "max": "1",
      "id": "Consent.policy",
      "condition": [ "ele-1" ],
      "base": {
        "max": "*",
        "min": 0,
        "path": "Consent.policy"
      }
    }, {
      "path": "Consent.policy.id",
      "min": 0,
      "definition": "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.",
      "short": "Unique id for inter-element referencing",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "_code": {
          "extension": [ {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-json-type",
            "valueString": "string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-xml-type",
            "valueString": "xsd:string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-rdf-type",
            "valueString": "xsd:string"
          } ]
        }
      } ],
      "representation": [ "xmlAttr" ],
      "max": "1",
      "id": "Consent.policy.id",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Element.id"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "Extension",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Consent.policy.extension",
      "min": 0,
      "definition": "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.",
      "short": "Additional content defined by implementations",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "slicing": {
        "rules": "open",
        "description": "Extensions are always sliced by (at least) url",
        "discriminator": [ {
          "path": "url",
          "type": "value"
        } ]
      },
      "type": [ {
        "code": "Extension"
      } ],
      "alias": [ "extensions", "user content" ],
      "max": "*",
      "id": "Consent.policy.extension",
      "condition": [ "ele-1" ],
      "comment": "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.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Element.extension"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "Extension",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Consent.policy.modifierExtension",
      "requirements": "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](extensibility.html#modifierExtension).",
      "min": 0,
      "definition": "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.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
      "isModifier": true,
      "short": "Extensions that cannot be ignored even if unrecognized",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "Extension"
      } ],
      "alias": [ "extensions", "user content", "modifiers" ],
      "max": "*",
      "id": "Consent.policy.modifierExtension",
      "condition": [ "ele-1" ],
      "comment": "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.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "BackboneElement.modifierExtension"
      },
      "isModifierReason": "Modifier extensions are expected to modify the meaning or interpretation of the element that contains them",
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.policy.authority",
      "min": 1,
      "definition": "Entity or Organization having regulatory jurisdiction or accountability for  enforcing policies pertaining to Consent Directives.",
      "short": "Enforcement source for policy",
      "fixedUri": "http://www.ontario.ca",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "uri"
      } ],
      "mustSupport": true,
      "max": "1",
      "id": "Consent.policy.authority",
      "condition": [ "ele-1", "ppc-1" ],
      "comment": "see http://en.wikipedia.org/wiki/Uniform_resource_identifier",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Consent.policy.authority"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.policy.uri",
      "min": 0,
      "definition": "The references to the policies that are included in this consent scope. Policies may be organizational, but are often defined jurisdictionally, or in law.",
      "short": "Specific policy covered by this consent",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "uri"
      } ],
      "max": "1",
      "id": "Consent.policy.uri",
      "condition": [ "ele-1", "ppc-1" ],
      "comment": "This element is for discoverability / documentation and does not modify or qualify the policy rules.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Consent.policy.uri"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.policyRule",
      "requirements": "Might be a unique identifier of a policy set in XACML, or other rules engine.",
      "min": 0,
      "definition": "A reference to the specific base computable regulation or policy.",
      "short": "Regulation that this consents to",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "CE/CNE/CWE",
        "identity": "v2"
      }, {
        "map": "CD",
        "identity": "rim"
      }, {
        "map": "fhir:CodeableConcept rdfs:subClassOf dt:CD",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "CodeableConcept"
      } ],
      "binding": {
        "strength": "extensible",
        "valueSet": "http://hl7.org/fhir/ValueSet/consent-policy",
        "description": "Regulatory policy examples."
      },
      "max": "1",
      "id": "Consent.policyRule",
      "condition": [ "ele-1", "ppc-1" ],
      "comment": "If the policyRule is absent, computable consent would need to be constructed from the elements of the Consent resource.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Consent.policyRule"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.verification",
      "min": 0,
      "definition": "Whether a treatment instruction (e.g. artificial respiration yes or no) was verified with the patient, his/her family or another authorized person.",
      "short": "Consent Verified by patient or family",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "BackboneElement"
      } ],
      "max": "*",
      "id": "Consent.verification",
      "condition": [ "ele-1" ],
      "base": {
        "max": "*",
        "min": 0,
        "path": "Consent.verification"
      },
      "isSummary": true
    }, {
      "path": "Consent.verification.id",
      "min": 0,
      "definition": "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.",
      "short": "Unique id for inter-element referencing",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "_code": {
          "extension": [ {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-json-type",
            "valueString": "string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-xml-type",
            "valueString": "xsd:string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-rdf-type",
            "valueString": "xsd:string"
          } ]
        }
      } ],
      "representation": [ "xmlAttr" ],
      "max": "1",
      "id": "Consent.verification.id",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Element.id"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "Extension",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Consent.verification.extension",
      "min": 0,
      "definition": "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.",
      "short": "Additional content defined by implementations",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "slicing": {
        "rules": "open",
        "description": "Extensions are always sliced by (at least) url",
        "discriminator": [ {
          "path": "url",
          "type": "value"
        } ]
      },
      "type": [ {
        "code": "Extension"
      } ],
      "alias": [ "extensions", "user content" ],
      "max": "*",
      "id": "Consent.verification.extension",
      "condition": [ "ele-1" ],
      "comment": "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.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Element.extension"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "Extension",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Consent.verification.modifierExtension",
      "requirements": "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](extensibility.html#modifierExtension).",
      "min": 0,
      "definition": "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.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
      "isModifier": true,
      "short": "Extensions that cannot be ignored even if unrecognized",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "Extension"
      } ],
      "alias": [ "extensions", "user content", "modifiers" ],
      "max": "*",
      "id": "Consent.verification.modifierExtension",
      "condition": [ "ele-1" ],
      "comment": "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.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "BackboneElement.modifierExtension"
      },
      "isModifierReason": "Modifier extensions are expected to modify the meaning or interpretation of the element that contains them",
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.verification.verified",
      "min": 1,
      "definition": "Has the instruction been verified.",
      "short": "Has been verified",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "boolean"
      } ],
      "max": "1",
      "id": "Consent.verification.verified",
      "condition": [ "ele-1" ],
      "base": {
        "max": "1",
        "min": 1,
        "path": "Consent.verification.verified"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ref-1",
        "human": "SHALL have a contained resource if a local reference is provided",
        "xpath": "not(starts-with(f:reference/@value, '#')) or exists(ancestor::*[self::f:entry or self::f:parameter]/f:resource/f:*/f:contained/f:*[f:id/@value=substring-after(current()/f:reference/@value, '#')]|/*/f:contained/f:*[f:id/@value=substring-after(current()/f:reference/@value, '#')])",
        "source": "Reference",
        "severity": "error",
        "expression": "reference.startsWith('#').not() or (reference.substring(1).trace('url') in %resource.contained.id.trace('ids'))"
      } ],
      "path": "Consent.verification.verifiedWith",
      "min": 0,
      "definition": "Who verified the instruction (Patient, Relative or other Authorized Person).",
      "short": "Person who verified",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "The target of a resource reference is a RIM entry point (Act, Role, or Entity)",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "Reference",
        "targetProfile": [ "http://hl7.org/fhir/StructureDefinition/Patient", "http://hl7.org/fhir/StructureDefinition/RelatedPerson" ]
      } ],
      "max": "1",
      "id": "Consent.verification.verifiedWith",
      "condition": [ "ele-1" ],
      "comment": "References SHALL be a reference to an actual FHIR resource, and SHALL be resolveable (allowing for access control, temporary unavailability, etc.). Resolution can be either by retrieval from the URL, or, where applicable by resource type, by treating an absolute reference as a canonical URL and looking it up in a local registry/repository.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Consent.verification.verifiedWith"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.verification.verificationDate",
      "min": 0,
      "definition": "Date verification was collected.",
      "short": "When consent verified",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "dateTime"
      } ],
      "max": "1",
      "id": "Consent.verification.verificationDate",
      "condition": [ "ele-1" ],
      "base": {
        "max": "1",
        "min": 0,
        "path": "Consent.verification.verificationDate"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision",
      "min": 1,
      "definition": "An exception to the base policy of this consent. An exception can be an addition or removal of access permissions.",
      "short": "Constraints to the base Consent.policyRule",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "BackboneElement"
      } ],
      "mustSupport": true,
      "max": "1",
      "id": "Consent.provision",
      "condition": [ "ele-1" ],
      "base": {
        "max": "1",
        "min": 0,
        "path": "Consent.provision"
      },
      "isSummary": true
    }, {
      "path": "Consent.provision.id",
      "min": 0,
      "definition": "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.",
      "short": "Unique id for inter-element referencing",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "_code": {
          "extension": [ {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-json-type",
            "valueString": "string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-xml-type",
            "valueString": "xsd:string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-rdf-type",
            "valueString": "xsd:string"
          } ]
        }
      } ],
      "representation": [ "xmlAttr" ],
      "max": "1",
      "id": "Consent.provision.id",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Element.id"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "Extension",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Consent.provision.extension",
      "min": 0,
      "definition": "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.",
      "short": "Additional content defined by implementations",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "slicing": {
        "rules": "open",
        "description": "Extensions are always sliced by (at least) url",
        "discriminator": [ {
          "path": "url",
          "type": "value"
        } ]
      },
      "type": [ {
        "code": "Extension"
      } ],
      "alias": [ "extensions", "user content" ],
      "max": "*",
      "id": "Consent.provision.extension",
      "condition": [ "ele-1" ],
      "comment": "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.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Element.extension"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "Extension",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Consent.provision.modifierExtension",
      "requirements": "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](extensibility.html#modifierExtension).",
      "min": 0,
      "definition": "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.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
      "isModifier": true,
      "short": "Extensions that cannot be ignored even if unrecognized",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "Extension"
      } ],
      "alias": [ "extensions", "user content", "modifiers" ],
      "max": "*",
      "id": "Consent.provision.modifierExtension",
      "condition": [ "ele-1" ],
      "comment": "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.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "BackboneElement.modifierExtension"
      },
      "isModifierReason": "Modifier extensions are expected to modify the meaning or interpretation of the element that contains them",
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision.type",
      "fixedCode": "permit",
      "min": 1,
      "definition": "Action  to take - permit or deny - when the rule conditions are met.  Not permitted in root rule, required in all nested rules.",
      "short": "deny | permit",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "code"
      } ],
      "mustSupport": true,
      "binding": {
        "strength": "required",
        "valueSet": "http://hl7.org/fhir/ValueSet/consent-provision-type|4.0.0",
        "description": "How a rule statement is applied, such as adding additional consent or removing consent."
      },
      "max": "1",
      "id": "Consent.provision.type",
      "condition": [ "ele-1" ],
      "comment": "Note that FHIR strings SHALL NOT exceed 1MB in size",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Consent.provision.type"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "per-1",
        "human": "If present, start SHALL have a lower value than end",
        "xpath": "not(exists(f:start/@value)) or not(exists(f:end/@value)) or (xs:dateTime(f:start/@value) <= xs:dateTime(f:end/@value))",
        "source": "Period",
        "severity": "error",
        "expression": "start.hasValue().not() or end.hasValue().not() or (start <= end)"
      } ],
      "path": "Consent.provision.period",
      "min": 0,
      "definition": "The timeframe in this rule is valid.\r\n\r\nThis field is optional and will be ignored for processing in the current PCOI implementation. The consent override duration will be processed based on the time of receipt of the FHIR Consent resource, and not based on the payload's Consent.dateTime value (to prevent unintended behaviour based on incorrect payload dateTime).",
      "short": "Timeframe for this rule",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "DR",
        "identity": "v2"
      }, {
        "map": "IVL[lowClosed=\"true\" and highClosed=\"true\"] or URG[lowClosed=\"true\" and highClosed=\"true\"]",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "Period"
      } ],
      "max": "1",
      "id": "Consent.provision.period",
      "condition": [ "ele-1" ],
      "comment": "A Period specifies a range of time; the context of use will specify whether the entire range applies (e.g. \"the patient was an inpatient of the hospital for this time range\") or one value from the range applies (e.g. \"give to the patient between these two times\").\n\nPeriod is not used for a duration (a measure of elapsed time). See [Duration](datatypes.html#Duration).",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Consent.provision.period"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision.actor",
      "min": 1,
      "definition": "Who or what is controlled by this rule. Use group to identify a set of actors by some property they share (e.g. 'admitting officers').",
      "short": "Who|what controlled by this rule (or group, by role)",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "BackboneElement"
      } ],
      "mustSupport": true,
      "meaningWhenMissing": "There is no specific actor associated with the exception",
      "max": "1",
      "id": "Consent.provision.actor",
      "condition": [ "ele-1" ],
      "base": {
        "max": "*",
        "min": 0,
        "path": "Consent.provision.actor"
      }
    }, {
      "path": "Consent.provision.actor.id",
      "min": 0,
      "definition": "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.",
      "short": "Unique id for inter-element referencing",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "_code": {
          "extension": [ {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-json-type",
            "valueString": "string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-xml-type",
            "valueString": "xsd:string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-rdf-type",
            "valueString": "xsd:string"
          } ]
        }
      } ],
      "representation": [ "xmlAttr" ],
      "max": "1",
      "id": "Consent.provision.actor.id",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Element.id"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "Extension",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Consent.provision.actor.extension",
      "min": 0,
      "definition": "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.",
      "short": "Additional content defined by implementations",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "slicing": {
        "rules": "open",
        "description": "Extensions are always sliced by (at least) url",
        "discriminator": [ {
          "path": "url",
          "type": "value"
        } ]
      },
      "type": [ {
        "code": "Extension"
      } ],
      "alias": [ "extensions", "user content" ],
      "max": "*",
      "id": "Consent.provision.actor.extension",
      "condition": [ "ele-1" ],
      "comment": "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.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Element.extension"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "Extension",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Consent.provision.actor.modifierExtension",
      "requirements": "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](extensibility.html#modifierExtension).",
      "min": 0,
      "definition": "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.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
      "isModifier": true,
      "short": "Extensions that cannot be ignored even if unrecognized",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "Extension"
      } ],
      "alias": [ "extensions", "user content", "modifiers" ],
      "max": "*",
      "id": "Consent.provision.actor.modifierExtension",
      "condition": [ "ele-1" ],
      "comment": "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.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "BackboneElement.modifierExtension"
      },
      "isModifierReason": "Modifier extensions are expected to modify the meaning or interpretation of the element that contains them",
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision.actor.role",
      "min": 1,
      "definition": "How the individual is involved in the resources content that is described in the exception.",
      "short": "How the actor is involved",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "CE/CNE/CWE",
        "identity": "v2"
      }, {
        "map": "CD",
        "identity": "rim"
      }, {
        "map": "fhir:CodeableConcept rdfs:subClassOf dt:CD",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "CodeableConcept"
      } ],
      "mustSupport": true,
      "binding": {
        "strength": "extensible",
        "valueSet": "http://hl7.org/fhir/ValueSet/security-role-type",
        "description": "How an actor is involved in the consent considerations."
      },
      "max": "1",
      "id": "Consent.provision.actor.role",
      "condition": [ "ele-1" ],
      "comment": "Not all terminology uses fit this general pattern. In some cases, models should not use CodeableConcept and use Coding directly and provide their own structure for managing text, codings, translations and the relationship between elements and pre- and post-coordination.",
      "base": {
        "max": "1",
        "min": 1,
        "path": "Consent.provision.actor.role"
      }
    }, {
      "path": "Consent.provision.actor.role.id",
      "min": 0,
      "definition": "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.",
      "short": "Unique id for inter-element referencing",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "_code": {
          "extension": [ {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-json-type",
            "valueString": "string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-xml-type",
            "valueString": "xsd:string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-rdf-type",
            "valueString": "xsd:string"
          } ]
        }
      } ],
      "representation": [ "xmlAttr" ],
      "max": "1",
      "id": "Consent.provision.actor.role.id",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Element.id"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "Extension",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Consent.provision.actor.role.extension",
      "min": 0,
      "definition": "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.",
      "short": "Additional content defined by implementations",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "slicing": {
        "rules": "open",
        "description": "Extensions are always sliced by (at least) url",
        "discriminator": [ {
          "path": "url",
          "type": "value"
        } ]
      },
      "type": [ {
        "code": "Extension"
      } ],
      "alias": [ "extensions", "user content" ],
      "max": "*",
      "id": "Consent.provision.actor.role.extension",
      "condition": [ "ele-1" ],
      "comment": "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.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Element.extension"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision.actor.role.coding",
      "requirements": "Allows for alternative encodings within a code system, and translations to other code systems.",
      "min": 1,
      "definition": "A reference to a code defined by a terminology system.",
      "short": "Code defined by a terminology system",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "CE/CNE/CWE subset one of the sets of component 1-3 or 4-6",
        "identity": "v2"
      }, {
        "map": "CV",
        "identity": "rim"
      }, {
        "map": "fhir:Coding rdfs:subClassOf dt:CDCoding",
        "identity": "orim"
      }, {
        "map": "C*E.1-8, C*E.10-22",
        "identity": "v2"
      }, {
        "map": "union(., ./translation)",
        "identity": "rim"
      }, {
        "map": "fhir:CodeableConcept.coding rdfs:subPropertyOf dt:CD.coding",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "Coding"
      } ],
      "mustSupport": true,
      "max": "1",
      "id": "Consent.provision.actor.role.coding",
      "condition": [ "ele-1" ],
      "comment": "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.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "CodeableConcept.coding"
      },
      "isSummary": true
    }, {
      "path": "Consent.provision.actor.role.coding.id",
      "min": 0,
      "definition": "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.",
      "short": "Unique id for inter-element referencing",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "_code": {
          "extension": [ {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-json-type",
            "valueString": "string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-xml-type",
            "valueString": "xsd:string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-rdf-type",
            "valueString": "xsd:string"
          } ]
        }
      } ],
      "representation": [ "xmlAttr" ],
      "max": "1",
      "id": "Consent.provision.actor.role.coding.id",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Element.id"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "Extension",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Consent.provision.actor.role.coding.extension",
      "min": 0,
      "definition": "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.",
      "short": "Additional content defined by implementations",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "slicing": {
        "rules": "open",
        "description": "Extensions are always sliced by (at least) url",
        "discriminator": [ {
          "path": "url",
          "type": "value"
        } ]
      },
      "type": [ {
        "code": "Extension"
      } ],
      "alias": [ "extensions", "user content" ],
      "max": "*",
      "id": "Consent.provision.actor.role.coding.extension",
      "condition": [ "ele-1" ],
      "comment": "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.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Element.extension"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision.actor.role.coding.system",
      "requirements": "Need to be unambiguous about the source of the definition of the symbol.",
      "min": 1,
      "definition": "The identification of the code system that defines the meaning of the symbol in the code.",
      "short": "Identity of the terminology system",
      "fixedUri": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.3",
        "identity": "v2"
      }, {
        "map": "./codeSystem",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.system rdfs:subPropertyOf dt:CDCoding.codeSystem",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "uri"
      } ],
      "mustSupport": true,
      "max": "1",
      "id": "Consent.provision.actor.role.coding.system",
      "condition": [ "ele-1" ],
      "comment": "The URI may be an OID (urn:oid:...) or a UUID (urn:uuid:...).  OIDs and UUIDs SHALL be references to the HL7 OID registry. Otherwise, the URI should come from HL7's list of FHIR defined special URIs or it should reference to some definition that establishes the system clearly and unambiguously.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.system"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision.actor.role.coding.version",
      "min": 0,
      "definition": "The version of the code system which was used when choosing this code. Note that a well-maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged.",
      "short": "Version of the system - if relevant",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.7",
        "identity": "v2"
      }, {
        "map": "./codeSystemVersion",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.version rdfs:subPropertyOf dt:CDCoding.codeSystemVersion",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "string"
      } ],
      "max": "1",
      "id": "Consent.provision.actor.role.coding.version",
      "condition": [ "ele-1" ],
      "comment": "Where the terminology does not clearly define what string should be used to identify code system versions, the recommendation is to use the date (expressed in FHIR date format) on which that version was officially published as the version date.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.version"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision.actor.role.coding.code",
      "fixedCode": "IRCP",
      "requirements": "Need to refer to a particular code in the system.",
      "min": 1,
      "definition": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post-coordination).",
      "short": "Symbol in syntax defined by the system",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.1",
        "identity": "v2"
      }, {
        "map": "./code",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.code rdfs:subPropertyOf dt:CDCoding.code",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "code"
      } ],
      "mustSupport": true,
      "max": "1",
      "id": "Consent.provision.actor.role.coding.code",
      "condition": [ "ele-1" ],
      "comment": "Note that FHIR strings SHALL NOT exceed 1MB in size",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.code"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision.actor.role.coding.display",
      "requirements": "Need to be able to carry a human-readable meaning of the code for readers that do not know  the system.",
      "min": 1,
      "definition": "A representation of the meaning of the code in the system, following the rules of the system.",
      "short": "Representation defined by the system",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.2 - but note this is not well followed",
        "identity": "v2"
      }, {
        "map": "CV.displayName",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.display rdfs:subPropertyOf dt:CDCoding.displayName",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "string"
      } ],
      "mustSupport": true,
      "max": "1",
      "fixedString": "information recipient",
      "id": "Consent.provision.actor.role.coding.display",
      "condition": [ "ele-1" ],
      "comment": "Note that FHIR strings SHALL NOT exceed 1MB in size",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.display"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision.actor.role.coding.userSelected",
      "requirements": "This has been identified as a clinical safety criterium - that this exact system/code pair was chosen explicitly, rather than inferred by the system based on some rules or language processing.",
      "min": 0,
      "definition": "Indicates that this coding was chosen by a user directly - e.g. off a pick list of available items (codes or displays).",
      "short": "If this coding was chosen directly by the user",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "Sometimes implied by being first",
        "identity": "v2"
      }, {
        "map": "CD.codingRationale",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.userSelected fhir:mapsTo dt:CDCoding.codingRationale. fhir:Coding.userSelected fhir:hasMap fhir:Coding.userSelected.map. fhir:Coding.userSelected.map a fhir:Map;   fhir:target dt:CDCoding.codingRationale. fhir:Coding.userSelected\\#true a [     fhir:source \"true\";     fhir:target dt:CDCoding.codingRationale\\#O   ]",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "boolean"
      } ],
      "max": "1",
      "id": "Consent.provision.actor.role.coding.userSelected",
      "condition": [ "ele-1" ],
      "comment": "Amongst a set of alternatives, a directly chosen code is the most appropriate starting point for new translations. There is some ambiguity about what exactly 'directly chosen' implies, and trading partner agreement may be needed to clarify the use of this element and its consequences more completely.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.userSelected"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision.actor.role.text",
      "requirements": "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.",
      "min": 0,
      "definition": "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.",
      "short": "Plain text representation of the concept",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.9. But note many systems use C*E.2 for this",
        "identity": "v2"
      }, {
        "map": "./originalText[mediaType/code=\"text/plain\"]/data",
        "identity": "rim"
      }, {
        "map": "fhir:CodeableConcept.text rdfs:subPropertyOf dt:CD.originalText",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "string"
      } ],
      "max": "1",
      "id": "Consent.provision.actor.role.text",
      "condition": [ "ele-1" ],
      "comment": "Very often the text is the same as a displayName of one of the codings.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "CodeableConcept.text"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ref-1",
        "human": "SHALL have a contained resource if a local reference is provided",
        "xpath": "not(starts-with(f:reference/@value, '#')) or exists(ancestor::*[self::f:entry or self::f:parameter]/f:resource/f:*/f:contained/f:*[f:id/@value=substring-after(current()/f:reference/@value, '#')]|/*/f:contained/f:*[f:id/@value=substring-after(current()/f:reference/@value, '#')])",
        "source": "Reference",
        "severity": "error",
        "expression": "reference.startsWith('#').not() or (reference.substring(1).trace('url') in %resource.contained.id.trace('ids'))"
      } ],
      "path": "Consent.provision.actor.reference",
      "min": 1,
      "definition": "The resource that identifies the actor. To identify actors by type, use group to identify a set of actors by some property they share (e.g. 'admitting officers').",
      "short": "Resource for the actor (or group, by role)",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "The target of a resource reference is a RIM entry point (Act, Role, or Entity)",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "Reference",
        "targetProfile": [ "http://ehealthontario.ca/fhir/StructureDefinition/ca-on-consent-pcoi-profile-Practitioner" ]
      } ],
      "mustSupport": true,
      "max": "1",
      "id": "Consent.provision.actor.reference",
      "condition": [ "ele-1" ],
      "comment": "References SHALL be a reference to an actual FHIR resource, and SHALL be resolveable (allowing for access control, temporary unavailability, etc.). Resolution can be either by retrieval from the URL, or, where applicable by resource type, by treating an absolute reference as a canonical URL and looking it up in a local registry/repository.",
      "base": {
        "max": "1",
        "min": 1,
        "path": "Consent.provision.actor.reference"
      }
    }, {
      "path": "Consent.provision.actor.reference.id",
      "min": 0,
      "definition": "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.",
      "short": "Unique id for inter-element referencing",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "_code": {
          "extension": [ {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-json-type",
            "valueString": "string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-xml-type",
            "valueString": "xsd:string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-rdf-type",
            "valueString": "xsd:string"
          } ]
        }
      } ],
      "representation": [ "xmlAttr" ],
      "max": "1",
      "id": "Consent.provision.actor.reference.id",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Element.id"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "Extension",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Consent.provision.actor.reference.extension",
      "min": 0,
      "definition": "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.",
      "short": "Additional content defined by implementations",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "slicing": {
        "rules": "open",
        "description": "Extensions are always sliced by (at least) url",
        "discriminator": [ {
          "path": "url",
          "type": "value"
        } ]
      },
      "type": [ {
        "code": "Extension"
      } ],
      "alias": [ "extensions", "user content" ],
      "max": "*",
      "id": "Consent.provision.actor.reference.extension",
      "condition": [ "ele-1" ],
      "comment": "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.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Element.extension"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision.actor.reference.reference",
      "min": 1,
      "definition": "A reference to a location at which the other resource is found. The reference may be a relative reference, in which case it is relative to the service base URL, or an absolute URL that resolves to the location where the resource is found. The reference may be version specific or not. If the reference is not to a FHIR RESTful server, then it should be assumed to be version specific. Internal fragment references (start with '#') refer to contained resources.",
      "short": "Literal reference, Relative, internal or absolute URL",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "string"
      } ],
      "mustSupport": true,
      "max": "1",
      "id": "Consent.provision.actor.reference.reference",
      "condition": [ "ele-1", "ref-1" ],
      "comment": "Using absolute URLs provides a stable scalable approach suitable for a cloud/web context, while using relative/logical references provides a flexible approach suitable for use when trading across closed eco-system boundaries.   Absolute URLs do not need to point to a FHIR RESTful server, though this is the preferred approach. If the URL conforms to the structure \"/[type]/[id]\" then it should be assumed that the reference is to a FHIR RESTful server.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Reference.reference"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision.actor.reference.type",
      "min": 0,
      "definition": "The expected type of the target of the reference. If both Reference.type and Reference.reference are populated and Reference.reference is a FHIR URL, both SHALL be consistent.\n\nThe type is the Canonical URL of Resource Definition that is the type this reference refers to. References are URLs that are relative to http://hl7.org/fhir/StructureDefinition/ e.g. \"Patient\" is a reference to http://hl7.org/fhir/StructureDefinition/Patient. Absolute URLs are only allowed for logical models (and can only be used in references in logical models, not resources).",
      "short": "Type the reference refers to (e.g. \"Patient\")",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "uri"
      } ],
      "binding": {
        "strength": "extensible",
        "valueSet": "http://hl7.org/fhir/ValueSet/resource-types",
        "description": "Aa resource (or, for logical models, the URI of the logical model)."
      },
      "max": "1",
      "id": "Consent.provision.actor.reference.type",
      "condition": [ "ele-1" ],
      "comment": "This element is used to indicate the type of  the target of the reference. This may be used which ever of the other elements are populated (or not). In some cases, the type of the target may be determined by inspection of the reference (e.g. a RESTful URL) or by resolving the target of the reference; if both the type and a reference is provided, the reference SHALL resolve to a resource of the same type as that specified.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Reference.type"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision.actor.reference.identifier",
      "min": 0,
      "definition": "An identifier for the target resource. This is used when there is no way to reference the other resource directly, either because the entity it represents is not available through a FHIR server, or because there is no way for the author of the resource to convert a known identifier to an actual location. There is no requirement that a Reference.identifier point to something that is actually exposed as a FHIR instance, but it SHALL point to a business concept that would be expected to be exposed as a FHIR instance, and that instance would need to be of a FHIR resource type allowed by the reference.",
      "short": "Logical reference, when literal reference is not known",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "CX / EI (occasionally, more often EI maps to a resource id or a URL)",
        "identity": "v2"
      }, {
        "map": "II - The Identifier class is a little looser than the v3 type II because it allows URIs as well as registered OIDs or GUIDs.  Also maps to Role[classCode=IDENT]",
        "identity": "rim"
      }, {
        "map": "Identifier",
        "identity": "servd"
      }, {
        "map": ".identifier",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "Identifier"
      } ],
      "max": "1",
      "id": "Consent.provision.actor.reference.identifier",
      "condition": [ "ele-1" ],
      "comment": "When an identifier is provided in place of a reference, any system processing the reference will only be able to resolve the identifier to a reference if it understands the business context in which the identifier is used. Sometimes this is global (e.g. a national identifier) but often it is not. For this reason, none of the useful mechanisms described for working with references (e.g. chaining, includes) are possible, nor should servers be expected to be able resolve the reference. Servers may accept an identifier based reference untouched, resolve it, and/or reject it - see CapabilityStatement.rest.resource.referencePolicy. \n\nWhen both an identifier and a literal reference are provided, the literal reference is preferred. Applications processing the resource are allowed - but not required - to check that the identifier matches the literal reference\n\nApplications converting a logical reference to a literal reference may choose to leave the logical reference present, or remove it.\n\nReference is intended to point to a structure that can potentially be expressed as a FHIR resource, though there is no need for it to exist as an actual FHIR resource instance - except in as much as an application wishes to actual find the target of the reference. The content referred to be the identifier must meet the logical constraints implied by any limitations on what resource types are permitted for the reference.  For example, it would not be legitimate to send the identifier for a drug prescription if the type were Reference(Observation|DiagnosticReport).  One of the use-cases for Reference.identifier is the situation where no FHIR representation exists (where the type is Reference (Any).",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Reference.identifier"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision.actor.reference.display",
      "min": 0,
      "definition": "Plain text narrative that identifies the resource in addition to the resource reference.",
      "short": "Text alternative for the resource",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "string"
      } ],
      "max": "1",
      "id": "Consent.provision.actor.reference.display",
      "condition": [ "ele-1" ],
      "comment": "This is generally not the same as the Resource.text of the referenced resource.  The purpose is to identify what's being referenced, not to fully describe it.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Reference.display"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision.action",
      "min": 0,
      "definition": "Actions controlled by this Rule.\r\n\r\nWhile this element may be used by some underlying lines of business (e.g. DHDR), the PCOI currently is not using this optional element. If sent, this element will not be processed by the PCOI.\r\n\r\nSee comments.",
      "short": "Actions controlled by this rule",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "CE/CNE/CWE",
        "identity": "v2"
      }, {
        "map": "CD",
        "identity": "rim"
      }, {
        "map": "fhir:CodeableConcept rdfs:subClassOf dt:CD",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "CodeableConcept"
      } ],
      "meaningWhenMissing": "all actions",
      "binding": {
        "strength": "example",
        "valueSet": "http://hl7.org/fhir/ValueSet/consent-action",
        "description": "Detailed codes for the consent action."
      },
      "max": "*",
      "id": "Consent.provision.action",
      "condition": [ "ele-1" ],
      "comment": "Note that this is the direct action (not the grounds for the action covered in the purpose element). At present, the only action in the understood and tested scope of this resource is 'read'.\r\n\r\nAs of FHIR R4, HL7 notes that \"At present, the only action in the understood and tested scope of this resource is 'read'\". (yet \"read\" is not one of the sample Consent Action Codes).\r\n\r\nThis element may be populated with the value \"use\", to align with the example binding and with the current DHDR implementation, but may require additional discussion. Note that DHDR V1 and V2 used value \"access\", while DHDR V3 used \"use\".",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Consent.provision.action"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision.securityLabel",
      "min": 0,
      "definition": "A security label, comprised of 0..* security label fields (Privacy tags), which define which resources are controlled by this exception.",
      "short": "Security Labels that define affected resources",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "CE/CNE/CWE subset one of the sets of component 1-3 or 4-6",
        "identity": "v2"
      }, {
        "map": "CV",
        "identity": "rim"
      }, {
        "map": "fhir:Coding rdfs:subClassOf dt:CDCoding",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "Coding"
      } ],
      "binding": {
        "strength": "extensible",
        "valueSet": "http://hl7.org/fhir/ValueSet/security-labels",
        "description": "Security Labels from the Healthcare Privacy and Security Classification System."
      },
      "max": "*",
      "id": "Consent.provision.securityLabel",
      "condition": [ "ele-1" ],
      "comment": "If the consent specifies a security label of \"R\" then it applies to all resources that are labeled \"R\" or lower. E.g. for Confidentiality, it's a high water mark. For other kinds of security labels, subsumption logic applies. When the purpose of use tag is on the data, access request purpose of use shall not conflict.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Consent.provision.securityLabel"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision.purpose",
      "min": 1,
      "definition": "The context of the activities a user is taking - why the user is accessing the data - that are controlled by this rule.\r\nThis element captures the \"reason for override\". Ontario legislation currently allows for:\r\n* Express Patient Consent [PATRQT]\r\n* Risk to Safety of Patient [OVRER]\r\n* Risk to Safety of Third Parites [OVRTPS]\r\nNot all systems will allow all three reasons for override, however. Please see additional documentation for details.",
      "short": "Context of activities covered by this rule",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "CE/CNE/CWE subset one of the sets of component 1-3 or 4-6",
        "identity": "v2"
      }, {
        "map": "CV",
        "identity": "rim"
      }, {
        "map": "fhir:Coding rdfs:subClassOf dt:CDCoding",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "Coding"
      } ],
      "mustSupport": true,
      "binding": {
        "strength": "required",
        "valueSet": "http://ehealthontario.ca/fhir/ValueSet/consent-pcoi-override-reason",
        "description": "What purposes of use are controlled by this exception. If more than one label is specified, operations must have all the specified labels."
      },
      "max": "1",
      "id": "Consent.provision.purpose",
      "condition": [ "ele-1" ],
      "comment": "When the purpose of use tag is on the data, access request purpose of use shall not conflict.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Consent.provision.purpose"
      },
      "isSummary": true
    }, {
      "path": "Consent.provision.purpose.id",
      "min": 0,
      "definition": "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.",
      "short": "Unique id for inter-element referencing",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "_code": {
          "extension": [ {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-json-type",
            "valueString": "string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-xml-type",
            "valueString": "xsd:string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-rdf-type",
            "valueString": "xsd:string"
          } ]
        }
      } ],
      "representation": [ "xmlAttr" ],
      "max": "1",
      "id": "Consent.provision.purpose.id",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Element.id"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "Extension",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Consent.provision.purpose.extension",
      "min": 0,
      "definition": "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.",
      "short": "Additional content defined by implementations",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "slicing": {
        "rules": "open",
        "description": "Extensions are always sliced by (at least) url",
        "discriminator": [ {
          "path": "url",
          "type": "value"
        } ]
      },
      "type": [ {
        "code": "Extension"
      } ],
      "alias": [ "extensions", "user content" ],
      "max": "*",
      "id": "Consent.provision.purpose.extension",
      "condition": [ "ele-1" ],
      "comment": "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.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Element.extension"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision.purpose.system",
      "requirements": "Need to be unambiguous about the source of the definition of the symbol.",
      "min": 1,
      "definition": "The identification of the code system that defines the meaning of the symbol in the code.",
      "short": "Identity of the terminology system",
      "fixedUri": "http://terminology.hl7.org/CodeSystem/v3-ActReason",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.3",
        "identity": "v2"
      }, {
        "map": "./codeSystem",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.system rdfs:subPropertyOf dt:CDCoding.codeSystem",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "uri"
      } ],
      "mustSupport": true,
      "max": "1",
      "id": "Consent.provision.purpose.system",
      "condition": [ "ele-1" ],
      "comment": "The URI may be an OID (urn:oid:...) or a UUID (urn:uuid:...).  OIDs and UUIDs SHALL be references to the HL7 OID registry. Otherwise, the URI should come from HL7's list of FHIR defined special URIs or it should reference to some definition that establishes the system clearly and unambiguously.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.system"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision.purpose.version",
      "min": 0,
      "definition": "The version of the code system which was used when choosing this code. Note that a well-maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged.",
      "short": "Version of the system - if relevant",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.7",
        "identity": "v2"
      }, {
        "map": "./codeSystemVersion",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.version rdfs:subPropertyOf dt:CDCoding.codeSystemVersion",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "string"
      } ],
      "max": "1",
      "id": "Consent.provision.purpose.version",
      "condition": [ "ele-1" ],
      "comment": "Where the terminology does not clearly define what string should be used to identify code system versions, the recommendation is to use the date (expressed in FHIR date format) on which that version was officially published as the version date.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.version"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision.purpose.code",
      "requirements": "Need to refer to a particular code in the system.",
      "min": 1,
      "definition": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post-coordination).",
      "short": "Symbol in syntax defined by the system",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.1",
        "identity": "v2"
      }, {
        "map": "./code",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.code rdfs:subPropertyOf dt:CDCoding.code",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "code"
      } ],
      "mustSupport": true,
      "max": "1",
      "id": "Consent.provision.purpose.code",
      "condition": [ "ele-1" ],
      "comment": "Note that FHIR strings SHALL NOT exceed 1MB in size",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.code"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision.purpose.display",
      "requirements": "Need to be able to carry a human-readable meaning of the code for readers that do not know  the system.",
      "min": 1,
      "definition": "A representation of the meaning of the code in the system, following the rules of the system.",
      "short": "Representation defined by the system",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.2 - but note this is not well followed",
        "identity": "v2"
      }, {
        "map": "CV.displayName",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.display rdfs:subPropertyOf dt:CDCoding.displayName",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "string"
      } ],
      "mustSupport": true,
      "max": "1",
      "id": "Consent.provision.purpose.display",
      "condition": [ "ele-1" ],
      "comment": "Note that FHIR strings SHALL NOT exceed 1MB in size",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.display"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision.purpose.userSelected",
      "requirements": "This has been identified as a clinical safety criterium - that this exact system/code pair was chosen explicitly, rather than inferred by the system based on some rules or language processing.",
      "min": 0,
      "definition": "Indicates that this coding was chosen by a user directly - e.g. off a pick list of available items (codes or displays).",
      "short": "If this coding was chosen directly by the user",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "Sometimes implied by being first",
        "identity": "v2"
      }, {
        "map": "CD.codingRationale",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.userSelected fhir:mapsTo dt:CDCoding.codingRationale. fhir:Coding.userSelected fhir:hasMap fhir:Coding.userSelected.map. fhir:Coding.userSelected.map a fhir:Map;   fhir:target dt:CDCoding.codingRationale. fhir:Coding.userSelected\\#true a [     fhir:source \"true\";     fhir:target dt:CDCoding.codingRationale\\#O   ]",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "boolean"
      } ],
      "max": "1",
      "id": "Consent.provision.purpose.userSelected",
      "condition": [ "ele-1" ],
      "comment": "Amongst a set of alternatives, a directly chosen code is the most appropriate starting point for new translations. There is some ambiguity about what exactly 'directly chosen' implies, and trading partner agreement may be needed to clarify the use of this element and its consequences more completely.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.userSelected"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision.class",
      "min": 1,
      "definition": "The class of information covered by this rule. The type can be a FHIR resource type, a profile on a type, or a CDA document, or some other type that indicates what sort of information the consent relates to.\r\nThe classes identified will indicate the Ontario EHR repository for which the Consent Override is being requested. As additional Ontario EHR respositories are onboarded to the Provincial Consent Override Interface service, the bound ValueSet will be updated to include those repositories.",
      "short": "e.g. Resource Type, Profile, CDA, etc.",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "CE/CNE/CWE subset one of the sets of component 1-3 or 4-6",
        "identity": "v2"
      }, {
        "map": "CV",
        "identity": "rim"
      }, {
        "map": "fhir:Coding rdfs:subClassOf dt:CDCoding",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "Coding"
      } ],
      "mustSupport": true,
      "binding": {
        "strength": "extensible",
        "valueSet": "http://hl7.org/fhir/ValueSet/consent-content-class",
        "description": "The class (type) of information a consent rule covers."
      },
      "max": "*",
      "id": "Consent.provision.class",
      "condition": [ "ele-1" ],
      "comment": "Multiple types are or'ed together. The intention of the contentType element is that the codes refer to profiles or document types defined in a standard or an implementation guide somewhere.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Consent.provision.class"
      },
      "isSummary": true
    }, {
      "path": "Consent.provision.class.id",
      "min": 0,
      "definition": "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.",
      "short": "Unique id for inter-element referencing",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "_code": {
          "extension": [ {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-json-type",
            "valueString": "string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-xml-type",
            "valueString": "xsd:string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-rdf-type",
            "valueString": "xsd:string"
          } ]
        }
      } ],
      "representation": [ "xmlAttr" ],
      "max": "1",
      "id": "Consent.provision.class.id",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Element.id"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "Extension",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Consent.provision.class.extension",
      "min": 0,
      "definition": "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.",
      "short": "Additional content defined by implementations",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "slicing": {
        "rules": "open",
        "description": "Extensions are always sliced by (at least) url",
        "discriminator": [ {
          "path": "url",
          "type": "value"
        } ]
      },
      "type": [ {
        "code": "Extension"
      } ],
      "alias": [ "extensions", "user content" ],
      "max": "*",
      "id": "Consent.provision.class.extension",
      "condition": [ "ele-1" ],
      "comment": "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.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Element.extension"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision.class.system",
      "requirements": "Need to be unambiguous about the source of the definition of the symbol.",
      "min": 1,
      "definition": "The identification of the code system that defines the meaning of the symbol in the code.",
      "short": "Identity of the terminology system",
      "fixedUri": "urn:ietf:rfc:3986",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.3",
        "identity": "v2"
      }, {
        "map": "./codeSystem",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.system rdfs:subPropertyOf dt:CDCoding.codeSystem",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "uri"
      } ],
      "mustSupport": true,
      "max": "1",
      "id": "Consent.provision.class.system",
      "condition": [ "ele-1" ],
      "comment": "The URI may be an OID (urn:oid:...) or a UUID (urn:uuid:...).  OIDs and UUIDs SHALL be references to the HL7 OID registry. Otherwise, the URI should come from HL7's list of FHIR defined special URIs or it should reference to some definition that establishes the system clearly and unambiguously.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.system"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision.class.version",
      "min": 0,
      "definition": "The version of the code system which was used when choosing this code. Note that a well-maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged.",
      "short": "Version of the system - if relevant",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.7",
        "identity": "v2"
      }, {
        "map": "./codeSystemVersion",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.version rdfs:subPropertyOf dt:CDCoding.codeSystemVersion",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "string"
      } ],
      "max": "1",
      "id": "Consent.provision.class.version",
      "condition": [ "ele-1" ],
      "comment": "Where the terminology does not clearly define what string should be used to identify code system versions, the recommendation is to use the date (expressed in FHIR date format) on which that version was officially published as the version date.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.version"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision.class.code",
      "requirements": "Need to refer to a particular code in the system.",
      "min": 1,
      "definition": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post-coordination).\r\nThis will contain the gateway URI identifying the provincial EHR assets as a target for the consent override request",
      "short": "Symbol in syntax defined by the system",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.1",
        "identity": "v2"
      }, {
        "map": "./code",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.code rdfs:subPropertyOf dt:CDCoding.code",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "code"
      } ],
      "mustSupport": true,
      "max": "1",
      "id": "Consent.provision.class.code",
      "condition": [ "ele-1" ],
      "comment": "Note that FHIR strings SHALL NOT exceed 1MB in size",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.code"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision.class.display",
      "requirements": "Need to be able to carry a human-readable meaning of the code for readers that do not know  the system.",
      "min": 1,
      "definition": "A representation of the meaning of the code in the system, following the rules of the system.",
      "short": "Representation defined by the system",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.2 - but note this is not well followed",
        "identity": "v2"
      }, {
        "map": "CV.displayName",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.display rdfs:subPropertyOf dt:CDCoding.displayName",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "string"
      } ],
      "mustSupport": true,
      "max": "1",
      "id": "Consent.provision.class.display",
      "condition": [ "ele-1" ],
      "comment": "Note that FHIR strings SHALL NOT exceed 1MB in size",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.display"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision.class.userSelected",
      "requirements": "This has been identified as a clinical safety criterium - that this exact system/code pair was chosen explicitly, rather than inferred by the system based on some rules or language processing.",
      "min": 0,
      "definition": "Indicates that this coding was chosen by a user directly - e.g. off a pick list of available items (codes or displays).",
      "short": "If this coding was chosen directly by the user",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "Sometimes implied by being first",
        "identity": "v2"
      }, {
        "map": "CD.codingRationale",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.userSelected fhir:mapsTo dt:CDCoding.codingRationale. fhir:Coding.userSelected fhir:hasMap fhir:Coding.userSelected.map. fhir:Coding.userSelected.map a fhir:Map;   fhir:target dt:CDCoding.codingRationale. fhir:Coding.userSelected\\#true a [     fhir:source \"true\";     fhir:target dt:CDCoding.codingRationale\\#O   ]",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "boolean"
      } ],
      "max": "1",
      "id": "Consent.provision.class.userSelected",
      "condition": [ "ele-1" ],
      "comment": "Amongst a set of alternatives, a directly chosen code is the most appropriate starting point for new translations. There is some ambiguity about what exactly 'directly chosen' implies, and trading partner agreement may be needed to clarify the use of this element and its consequences more completely.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.userSelected"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision.code",
      "min": 0,
      "definition": "If this code is found in an instance, then the rule applies.",
      "short": "e.g. LOINC or SNOMED CT code, etc. in the content",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "CE/CNE/CWE",
        "identity": "v2"
      }, {
        "map": "CD",
        "identity": "rim"
      }, {
        "map": "fhir:CodeableConcept rdfs:subClassOf dt:CD",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "CodeableConcept"
      } ],
      "binding": {
        "strength": "example",
        "valueSet": "http://hl7.org/fhir/ValueSet/consent-content-code",
        "description": "If this code is found in an instance, then the exception applies."
      },
      "max": "*",
      "id": "Consent.provision.code",
      "condition": [ "ele-1" ],
      "comment": "Typical use of this is a Document code with class = CDA.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Consent.provision.code"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "per-1",
        "human": "If present, start SHALL have a lower value than end",
        "xpath": "not(exists(f:start/@value)) or not(exists(f:end/@value)) or (xs:dateTime(f:start/@value) <= xs:dateTime(f:end/@value))",
        "source": "Period",
        "severity": "error",
        "expression": "start.hasValue().not() or end.hasValue().not() or (start <= end)"
      } ],
      "path": "Consent.provision.dataPeriod",
      "min": 0,
      "definition": "Clinical or Operational Relevant period of time that bounds the data controlled by this rule.",
      "short": "Timeframe for data controlled by this rule",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "DR",
        "identity": "v2"
      }, {
        "map": "IVL[lowClosed=\"true\" and highClosed=\"true\"] or URG[lowClosed=\"true\" and highClosed=\"true\"]",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "Period"
      } ],
      "max": "1",
      "id": "Consent.provision.dataPeriod",
      "condition": [ "ele-1" ],
      "comment": "This has a different sense to the Consent.period - that is when the consent agreement holds. This is the time period of the data that is controlled by the agreement.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Consent.provision.dataPeriod"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision.data",
      "min": 0,
      "definition": "The resources controlled by this rule if specific resources are referenced.",
      "short": "Data controlled by this rule",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "Role",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "BackboneElement"
      } ],
      "meaningWhenMissing": "all data",
      "max": "*",
      "id": "Consent.provision.data",
      "condition": [ "ele-1" ],
      "base": {
        "max": "*",
        "min": 0,
        "path": "Consent.provision.data"
      },
      "isSummary": true
    }, {
      "path": "Consent.provision.data.id",
      "min": 0,
      "definition": "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.",
      "short": "Unique id for inter-element referencing",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "_code": {
          "extension": [ {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-json-type",
            "valueString": "string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-xml-type",
            "valueString": "xsd:string"
          }, {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-rdf-type",
            "valueString": "xsd:string"
          } ]
        }
      } ],
      "representation": [ "xmlAttr" ],
      "max": "1",
      "id": "Consent.provision.data.id",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Element.id"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "Extension",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Consent.provision.data.extension",
      "min": 0,
      "definition": "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.",
      "short": "Additional content defined by implementations",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "slicing": {
        "rules": "open",
        "description": "Extensions are always sliced by (at least) url",
        "discriminator": [ {
          "path": "url",
          "type": "value"
        } ]
      },
      "type": [ {
        "code": "Extension"
      } ],
      "alias": [ "extensions", "user content" ],
      "max": "*",
      "id": "Consent.provision.data.extension",
      "condition": [ "ele-1" ],
      "comment": "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.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Element.extension"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "Extension",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Consent.provision.data.modifierExtension",
      "requirements": "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](extensibility.html#modifierExtension).",
      "min": 0,
      "definition": "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.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).",
      "isModifier": true,
      "short": "Extensions that cannot be ignored even if unrecognized",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "Extension"
      } ],
      "alias": [ "extensions", "user content", "modifiers" ],
      "max": "*",
      "id": "Consent.provision.data.modifierExtension",
      "condition": [ "ele-1" ],
      "comment": "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.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "BackboneElement.modifierExtension"
      },
      "isModifierReason": "Modifier extensions are expected to modify the meaning or interpretation of the element that contains them",
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Consent.provision.data.meaning",
      "min": 1,
      "definition": "How the resource reference is interpreted when testing consent restrictions.",
      "short": "instance | related | dependents | authoredby",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "code"
      } ],
      "binding": {
        "strength": "required",
        "valueSet": "http://hl7.org/fhir/ValueSet/consent-data-meaning|4.0.0",
        "description": "How a resource reference is interpreted when testing consent restrictions."
      },
      "max": "1",
      "id": "Consent.provision.data.meaning",
      "condition": [ "ele-1" ],
      "comment": "Note that FHIR strings SHALL NOT exceed 1MB in size",
      "base": {
        "max": "1",
        "min": 1,
        "path": "Consent.provision.data.meaning"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ref-1",
        "human": "SHALL have a contained resource if a local reference is provided",
        "xpath": "not(starts-with(f:reference/@value, '#')) or exists(ancestor::*[self::f:entry or self::f:parameter]/f:resource/f:*/f:contained/f:*[f:id/@value=substring-after(current()/f:reference/@value, '#')]|/*/f:contained/f:*[f:id/@value=substring-after(current()/f:reference/@value, '#')])",
        "source": "Reference",
        "severity": "error",
        "expression": "reference.startsWith('#').not() or (reference.substring(1).trace('url') in %resource.contained.id.trace('ids'))"
      } ],
      "path": "Consent.provision.data.reference",
      "min": 1,
      "definition": "A reference to a specific resource that defines which resources are covered by this consent.",
      "short": "The actual data reference",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "The target of a resource reference is a RIM entry point (Act, Role, or Entity)",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "Reference",
        "targetProfile": [ "http://hl7.org/fhir/StructureDefinition/Resource" ]
      } ],
      "max": "1",
      "id": "Consent.provision.data.reference",
      "condition": [ "ele-1" ],
      "comment": "References SHALL be a reference to an actual FHIR resource, and SHALL be resolveable (allowing for access control, temporary unavailability, etc.). Resolution can be either by retrieval from the URL, or, where applicable by resource type, by treating an absolute reference as a canonical URL and looking it up in a local registry/repository.",
      "base": {
        "max": "1",
        "min": 1,
        "path": "Consent.provision.data.reference"
      },
      "isSummary": true
    }, {
      "id": "Consent.provision.provision",
      "max": "*",
      "min": 0,
      "base": {
        "max": "*",
        "min": 0,
        "path": "Consent.provision.provision"
      },
      "path": "Consent.provision.provision",
      "short": "Nested Exception Rules",
      "definition": "Rules which provide exceptions to the base rule or subrules.",
      "contentReference": "#Consent.provision"
    } ]
  },
  "status": "draft",
  "id": "88e40112-baca-4cba-870c-3866552b000d",
  "kind": "resource",
  "url": "http://ehealthontario.ca/fhir/StructureDefinition/ca-on-consent-pcoi-profile-Consent",
  "version": null,
  "differential": {
    "element": [ {
      "id": "Consent.meta",
      "min": 1,
      "path": "Consent.meta",
      "mustSupport": true
    }, {
      "id": "Consent.meta.profile",
      "min": 1,
      "path": "Consent.meta.profile",
      "comment": "#### **_` FOR PCOI USAGE: The meta.profile = http://ehealthontario.ca/fhir/StructureDefinition/ca-on-consent-pcoi-profile-Consent|1.0.0 `_** \r\n\r\nIt is up to the server and/or other infrastructure of policy to determine whether/how these claims are verified and/or updated over time.  The list of profile URLs is a set.",
      "mustSupport": true
    }, {
      "id": "Consent.identifier",
      "path": "Consent.identifier",
      "comment": "This identifier identifies this copy of the consent. Where this identifier is also used elsewhere as the identifier for a consent record (e.g. a CDA consent document) then the consent details are expected to be the same.\r\nTBD if an identifier is necessary; this field can be used to store an identifier from the submitting system for reconciliation. DICS requires a msid from the Message Header (this value can come from the client, or could be HIAL/Gateway-assigned). CDR uses msgid from the SOAP Header  from the SOAP request msg. CMTA or the gateway would need to turn/store this ID for future retrieval/reference.",
      "definition": "Unique identifier for this copy of the Consent Statement.\r\neHealth Ontario and Implementers will work together to define the value passed in this field, if any.",
      "mustSupport": false
    }, {
      "id": "Consent.status",
      "path": "Consent.status",
      "fixedCode": "active",
      "definition": "Indicates the current state of this consent.\r\nFor consent overrides, this value will be fixed to \"active\".",
      "mustSupport": true
    }, {
      "id": "Consent.scope",
      "path": "Consent.scope",
      "mustSupport": true
    }, {
      "id": "Consent.scope.coding",
      "max": "1",
      "min": 1,
      "path": "Consent.scope.coding",
      "mustSupport": true
    }, {
      "id": "Consent.scope.coding.system",
      "min": 1,
      "path": "Consent.scope.coding.system",
      "fixedUri": "http://terminology.hl7.org/CodeSystem/consentscope",
      "mustSupport": true
    }, {
      "id": "Consent.scope.coding.code",
      "min": 1,
      "path": "Consent.scope.coding.code",
      "fixedCode": "patient-privacy",
      "mustSupport": true
    }, {
      "id": "Consent.scope.coding.display",
      "min": 1,
      "path": "Consent.scope.coding.display",
      "fixedString": "Privacy Consent",
      "mustSupport": true
    }, {
      "id": "Consent.category",
      "max": "1",
      "path": "Consent.category",
      "mustSupport": true
    }, {
      "id": "Consent.category.coding",
      "max": "1",
      "min": 1,
      "path": "Consent.category.coding",
      "mustSupport": true
    }, {
      "id": "Consent.category.coding.system",
      "min": 1,
      "path": "Consent.category.coding.system",
      "fixedUri": "http://terminology.hl7.org/CodeSystem/v3-ActCode",
      "mustSupport": true
    }, {
      "id": "Consent.category.coding.code",
      "min": 1,
      "path": "Consent.category.coding.code",
      "fixedCode": "INFA",
      "mustSupport": true
    }, {
      "id": "Consent.category.coding.display",
      "min": 1,
      "path": "Consent.category.coding.display",
      "fixedString": "information access",
      "mustSupport": true
    }, {
      "id": "Consent.patient",
      "min": 1,
      "path": "Consent.patient",
      "type": [ {
        "code": "Reference",
        "targetProfile": [ "http://ehealthontario.ca/fhir/StructureDefinition/ca-on-consent-pcoi-profile-Patient" ]
      } ],
      "mustSupport": true
    }, {
      "id": "Consent.patient.reference",
      "min": 1,
      "path": "Consent.patient.reference",
      "mustSupport": true
    }, {
      "id": "Consent.performer",
      "max": "1",
      "min": 1,
      "path": "Consent.performer",
      "type": [ {
        "code": "Reference",
        "targetProfile": [ "http://ehealthontario.ca/fhir/StructureDefinition/ca-on-consent-pcoi-profile-Patient", "http://ehealthontario.ca/fhir/StructureDefinition/ca-on-consent-pcoi-profile-RelatedPerson", "http://ehealthontario.ca/fhir/StructureDefinition/ca-on-consent-pcoi-profile-Practitioner", "http://ehealthontario.ca/fhir/StructureDefinition/ca-on-consent-pcoi-profile-Organization" ]
      } ],
      "definition": "Either the Grantor, which is the entity responsible for granting the rights listed in a Consent Directive or the Grantee, which is the entity responsible for complying with the Consent Directive, including any obligations or limitations on authorizations and enforcement of prohibitions.\r\nOnly Patient and RelatedPerson are in the scope of the current release. Practitioner-initiated Consent Override",
      "mustSupport": true
    }, {
      "id": "Consent.performer.reference",
      "min": 1,
      "path": "Consent.performer.reference",
      "mustSupport": true
    }, {
      "id": "Consent.organization",
      "max": "1",
      "min": 1,
      "path": "Consent.organization",
      "type": [ {
        "code": "Reference",
        "targetProfile": [ "http://ehealthontario.ca/fhir/StructureDefinition/ca-on-consent-pcoi-profile-Organization" ]
      } ],
      "definition": "The organization that manages the consent, and the framework within which it is executed.\r\nFor PCOI, this captures the facility name and identifier of the \"Under Authority Of\" organization.",
      "mustSupport": true
    }, {
      "id": "Consent.organization.reference",
      "min": 1,
      "path": "Consent.organization.reference",
      "mustSupport": true
    }, {
      "id": "Consent.policy",
      "max": "1",
      "min": 1,
      "path": "Consent.policy",
      "mustSupport": true
    }, {
      "id": "Consent.policy.authority",
      "min": 1,
      "path": "Consent.policy.authority",
      "fixedUri": "http://www.ontario.ca",
      "mustSupport": true
    }, {
      "id": "Consent.provision",
      "min": 1,
      "path": "Consent.provision",
      "mustSupport": true
    }, {
      "id": "Consent.provision.type",
      "min": 1,
      "path": "Consent.provision.type",
      "fixedCode": "permit",
      "mustSupport": true
    }, {
      "id": "Consent.provision.period",
      "path": "Consent.provision.period",
      "definition": "The timeframe in this rule is valid.\r\n\r\nThis field is optional and will be ignored for processing in the current PCOI implementation. The consent override duration will be processed based on the time of receipt of the FHIR Consent resource, and not based on the payload's Consent.dateTime value (to prevent unintended behaviour based on incorrect payload dateTime)."
    }, {
      "id": "Consent.provision.actor",
      "max": "1",
      "min": 1,
      "path": "Consent.provision.actor",
      "mustSupport": true
    }, {
      "id": "Consent.provision.actor.role",
      "path": "Consent.provision.actor.role",
      "mustSupport": true
    }, {
      "id": "Consent.provision.actor.role.coding",
      "max": "1",
      "min": 1,
      "path": "Consent.provision.actor.role.coding",
      "mustSupport": true
    }, {
      "id": "Consent.provision.actor.role.coding.system",
      "min": 1,
      "path": "Consent.provision.actor.role.coding.system",
      "fixedUri": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
      "mustSupport": true
    }, {
      "id": "Consent.provision.actor.role.coding.code",
      "min": 1,
      "path": "Consent.provision.actor.role.coding.code",
      "fixedCode": "IRCP",
      "mustSupport": true
    }, {
      "id": "Consent.provision.actor.role.coding.display",
      "min": 1,
      "path": "Consent.provision.actor.role.coding.display",
      "fixedString": "information recipient",
      "mustSupport": true
    }, {
      "id": "Consent.provision.actor.reference",
      "path": "Consent.provision.actor.reference",
      "type": [ {
        "code": "Reference",
        "targetProfile": [ "http://ehealthontario.ca/fhir/StructureDefinition/ca-on-consent-pcoi-profile-Practitioner" ]
      } ],
      "mustSupport": true
    }, {
      "id": "Consent.provision.actor.reference.reference",
      "min": 1,
      "path": "Consent.provision.actor.reference.reference",
      "mustSupport": true
    }, {
      "id": "Consent.provision.action",
      "path": "Consent.provision.action",
      "comment": "Note that this is the direct action (not the grounds for the action covered in the purpose element). At present, the only action in the understood and tested scope of this resource is 'read'.\r\n\r\nAs of FHIR R4, HL7 notes that \"At present, the only action in the understood and tested scope of this resource is 'read'\". (yet \"read\" is not one of the sample Consent Action Codes).\r\n\r\nThis element may be populated with the value \"use\", to align with the example binding and with the current DHDR implementation, but may require additional discussion. Note that DHDR V1 and V2 used value \"access\", while DHDR V3 used \"use\".",
      "definition": "Actions controlled by this Rule.\r\n\r\nWhile this element may be used by some underlying lines of business (e.g. DHDR), the PCOI currently is not using this optional element. If sent, this element will not be processed by the PCOI.\r\n\r\nSee comments."
    }, {
      "id": "Consent.provision.purpose",
      "max": "1",
      "min": 1,
      "path": "Consent.provision.purpose",
      "binding": {
        "strength": "required",
        "valueSet": "http://ehealthontario.ca/fhir/ValueSet/consent-pcoi-override-reason"
      },
      "definition": "The context of the activities a user is taking - why the user is accessing the data - that are controlled by this rule.\r\nThis element captures the \"reason for override\". Ontario legislation currently allows for:\r\n* Express Patient Consent [PATRQT]\r\n* Risk to Safety of Patient [OVRER]\r\n* Risk to Safety of Third Parites [OVRTPS]\r\nNot all systems will allow all three reasons for override, however. Please see additional documentation for details.",
      "mustSupport": true
    }, {
      "id": "Consent.provision.purpose.system",
      "min": 1,
      "path": "Consent.provision.purpose.system",
      "fixedUri": "http://terminology.hl7.org/CodeSystem/v3-ActReason",
      "mustSupport": true
    }, {
      "id": "Consent.provision.purpose.code",
      "min": 1,
      "path": "Consent.provision.purpose.code",
      "mustSupport": true
    }, {
      "id": "Consent.provision.purpose.display",
      "min": 1,
      "path": "Consent.provision.purpose.display",
      "mustSupport": true
    }, {
      "id": "Consent.provision.class",
      "min": 1,
      "path": "Consent.provision.class",
      "definition": "The class of information covered by this rule. The type can be a FHIR resource type, a profile on a type, or a CDA document, or some other type that indicates what sort of information the consent relates to.\r\nThe classes identified will indicate the Ontario EHR repository for which the Consent Override is being requested. As additional Ontario EHR respositories are onboarded to the Provincial Consent Override Interface service, the bound ValueSet will be updated to include those repositories.",
      "mustSupport": true
    }, {
      "id": "Consent.provision.class.system",
      "min": 1,
      "path": "Consent.provision.class.system",
      "fixedUri": "urn:ietf:rfc:3986",
      "mustSupport": true
    }, {
      "id": "Consent.provision.class.code",
      "min": 1,
      "path": "Consent.provision.class.code",
      "definition": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post-coordination).\r\nThis will contain the gateway URI identifying the provincial EHR assets as a target for the consent override request",
      "mustSupport": true
    }, {
      "id": "Consent.provision.class.display",
      "min": 1,
      "path": "Consent.provision.class.display",
      "mustSupport": true
    } ]
  },
  "baseDefinition": "http://hl7.org/fhir/StructureDefinition/Consent"
}