Implementation Guide
23.1.0 - R4 APIs

Publish Box goes here

Resource Profile: AthenaProvenance - Mappings

Active as of 2022-03-01

Mappings for the athena-provenance-profile resource profile.

Mappings for athenaFlow (http://unknown.org/athenaFlow)

AthenaProvenance
Provenance
   idMakeIdWithPrefix(%RESOURCEID%,%RESOURCETYPE%)
   meta
      lastUpdated%WHENUPDATED%
   targetMakeReference("Target",%RESOURCEID%,%RESOURCETYPE%)
   recordedMapProvenanceTimestamp(%CHANGE%,%INACTIVE%,%SIGNED%,%FILEDINERROR%,%WHENCREATED%,%WHENUPDATED%,%WHENSIGNED%)
   activityMapCode(%RESOURCEID%,%VERSIONID%,%CHANGE%,"PROVENANCEACTIVITYTYPE") OR MapCode(%STATUS%,"PROVENANCEACTIVITYTYPE")
   agent
   agent (ProvenanceAuthor)
      typeMakeCoding("author", "http://terminology.hl7.org/CodeSystem/provenance-participant-type", "Author")
      whoMapProvenanceWho(%CHANGE%,%INACTIVE%,%SIGNED%,%FILEDINERROR%,%CREATOR%,%WHOUPDATED%,%SIGNER%)
      onBehalfOfMakeReference("LOCREG",%ORGANIZATIONID%,"Organization")
   agent (ProvenanceTransmitter)
      typeIfEqual(%MIMETYPE%,"text/xml").Then(MakeCoding("transmitter", "http://hl7.org/fhir/us/core/CodeSystem/us-core-provenance-participant-type", "Transmitter"))
      whoIfEqual(%MIMETYPE%,"text/xml").Then(Context::MakeTextReference,%SOURCENAME%)
      onBehalfOfIfEqual(%MIMETYPE%,"text/xml").Then(Context::MakeTextReference,%SOURCEORG%)
   entity
      whatMakeReference("DOCUMENT",%SDID%,"Encounter")

Mappings for athenaPractice (http://unknown.org/athenaPractice)

AthenaProvenance
Provenance
   idMakeIdWithPrefix(%RESOURCEID%,%RESOURCETYPE%)
   meta
      lastUpdated%WHENUPDATED%
   targetMakeReference("Target",%RESOURCEID%,%RESOURCETYPE%)
   recordedMapProvenanceTimestamp(%CHANGE%,%INACTIVE%,%SIGNED%,%FILEDINERROR%,%WHENCREATED%,%WHENUPDATED%,%WHENSIGNED%)
   activityMapCode(%RESOURCEID%,%VERSIONID%,%CHANGE%,"PROVENANCEACTIVITYTYPE") OR MapCode(%STATUS%,"PROVENANCEACTIVITYTYPE")
   agent
   agent (ProvenanceAuthor)
      typeMakeCoding("author", "http://terminology.hl7.org/CodeSystem/provenance-participant-type", "Author")
      whoMapProvenanceWho(%CHANGE%,%INACTIVE%,%SIGNED%,%FILEDINERROR%,%CREATOR%,%WHOUPDATED%,%SIGNER%)
      onBehalfOfMakeReference("LOCREG",%ORGANIZATIONID%,"Organization")
   agent (ProvenanceTransmitter)
      typeIfEqual(%MIMETYPE%,"text/xml").Then(MakeCoding("transmitter", "http://hl7.org/fhir/us/core/CodeSystem/us-core-provenance-participant-type", "Transmitter"))
      whoIfEqual(%MIMETYPE%,"text/xml").Then(Context::MakeTextReference,%SOURCENAME%)
      onBehalfOfIfEqual(%MIMETYPE%,"text/xml").Then(Context::MakeTextReference,%SOURCEORG%)
   entity
      whatMakeReference("DOCUMENT",%SDID%,"Encounter")

Mappings for Workflow Pattern (http://hl7.org/fhir/workflow)

AthenaProvenance
ProvenanceEvent
   occurred[x]Event.occurred[x]
   locationEvent.location
   reasonEvent.reasonCode
   activityEvent.code
   agentEvent.performer
      typeEvent.performer.function
      whoEvent.performer.actor
   agent (ProvenanceAuthor)Event.performer
      typeEvent.performer.function
      whoEvent.performer.actor
   agent (ProvenanceTransmitter)Event.performer
      typeEvent.performer.function
      whoEvent.performer.actor

Mappings for RIM Mapping (http://hl7.org/v3)

AthenaProvenance
ProvenanceEntity. Role, or Act, ControlAct[isNormalAct() and subsumes(CACT, classCode) and moodCode=EVN]
   meta
      idn/a
      extensionn/a
   textAct.text?
   containedN/A
   extensionN/A
   modifierExtensionN/A
   target./outboundRelationship[isNormalActRelationship() and typeCode=SUBJ]/target OR ./participation[isNormalParticipation() and typeCode=SBJ]/role OR ./participation[isNormalParticipation() and typeCode=SBJ]/role[isNormalRole()]/player
   occurred[x]./effectiveTime[type=IVL_TS]
   recordedunique(./participation[isNormalParticipation() and typeCode=AUT]/time[type=TS])
   policy./inboundRelationship[isNormalActRelationship() and typeCode="SUBJ"]/source[isNormalAct and subsumes(POLICY, classCode) and moodCode=EVN]/text[typeCode='ED'/tel
   locationunique(./participation[isNormalParticipation() and typeCode=LOC]/role[isNormalRole() and subsumes(SDLOC, classCode)]/player[isNormalEntity and classCode="LOC" and determinerCode="INST"]
   reasonunique(./reasonCode)
   activityAct.code
   agent./participation[isNormalParticipation()] OR ./outboundRelationship[isNormalActRelationship() and typeCode='DRIV']
      idn/a
      extensionn/a
      modifierExtensionN/A
      type.role
      role.typecode
      who.id
      onBehalfOfPerson, Practitioner, Organization, Device :* .role [classCode = RoleClassMutualRelationship; role.code and * .scopes[Role](classCode=IDENT) and *.plays [Role.Code]
   agent (ProvenanceAuthor)./participation[isNormalParticipation()] OR ./outboundRelationship[isNormalActRelationship() and typeCode='DRIV']
      idn/a
      extensionn/a
      modifierExtensionN/A
      type.role
         idn/a
         extensionn/a
         codingunion(., ./translation)
            idn/a
            extensionn/a
            system./codeSystem
            version./codeSystemVersion
            code./code
            displayCV.displayName
            userSelectedCD.codingRationale
         text./originalText[mediaType/code="text/plain"]/data
      role.typecode
      who.id
      onBehalfOfPerson, Practitioner, Organization, Device :* .role [classCode = RoleClassMutualRelationship; role.code and * .scopes[Role](classCode=IDENT) and *.plays [Role.Code]
   agent (ProvenanceTransmitter)./participation[isNormalParticipation()] OR ./outboundRelationship[isNormalActRelationship() and typeCode='DRIV']
      idn/a
      extensionn/a
      modifierExtensionN/A
      type.role
         idn/a
         extensionn/a
         codingunion(., ./translation)
            idn/a
            extensionn/a
            system./codeSystem
            version./codeSystemVersion
            code./code
            displayCV.displayName
            userSelectedCD.codingRationale
         text./originalText[mediaType/code="text/plain"]/data
      role.typecode
      who.id
      onBehalfOfPerson, Practitioner, Organization, Device :* .role [classCode = RoleClassMutualRelationship; role.code and * .scopes[Role](classCode=IDENT) and *.plays [Role.Code]
   entity./subjectOf
      idn/a
      extensionn/a
      modifierExtensionN/A
      role./typeCode
      what./text/reference
      agent./author/role
   signature./signatureText

Mappings for W3C PROV (http://www.w3.org/ns/prov)

AthenaProvenance
ProvenanceActivity
   targetEntity Created/Updated
   occurred[x]Activity.startTime & Activity.endTime
   recordedActivity.when
   locationActivity.location
   reasonActivity.Activity
   activityActivity.Activity
   agentAgent
      typeAgent.Attribution
   agent (ProvenanceAuthor)Agent
      typeAgent.Attribution
   agent (ProvenanceTransmitter)Agent
      typeAgent.Attribution
   entityEntity
      roleEntity.role
      whatEntity.Identity

Mappings for FiveWs Pattern Mapping (http://hl7.org/fhir/fivews)

AthenaProvenance
Provenance
   targetFiveWs.what[x]
   occurred[x]FiveWs.done[x]
   recordedFiveWs.recorded
   locationFiveWs.where[x]
   reasonFiveWs.why[x]
   activityFiveWs.why[x]
   agentFiveWs.who
      whoFiveWs.actor
   agent (ProvenanceAuthor)FiveWs.who
      whoFiveWs.actor
   agent (ProvenanceTransmitter)FiveWs.who
      whoFiveWs.actor

Mappings for FHIR AuditEvent Mapping (http://hl7.org/fhir/auditevent)

AthenaProvenance
Provenance
   targetAuditEvent.entity.reference
   recordedAuditEvent.recorded
   policyAuditEvent.agent.policy
   locationAuditEvent.agent.location
   reasonAuditEvent.purposeOfEvent
   agentAuditEvent.agent
      typeAuditEvent.agent.type
      roleAuditEvent.agent.role
   agent (ProvenanceAuthor)AuditEvent.agent
      typeAuditEvent.agent.type
      roleAuditEvent.agent.role
   agent (ProvenanceTransmitter)AuditEvent.agent
      typeAuditEvent.agent.type
      roleAuditEvent.agent.role
   entityAuditEvent.entity
      roleAuditEvent.entity.lifecycle
      whatAuditEvent.entity.reference