1.0.0 - release

CambioOpenServicesIG - Local Development build (v1.0.0) built by the FHIR (HL7® FHIR® Standard) Build Tools. See the Directory of published versions

Resource Profile: ProvenanceStatusSe

Official URL: https://fhir.cambio.se/StructureDefinition/ProvenanceStatusSe/v1 Version: 1.0.0
Active as of 2025-10-27 Computable Name: ProvenanceStatusSe

Introduction

The ProvenanceStatusSe profile is used to manipulate the status of other resources. This means that ProvenanceStatusSe does not represent an individual resource in the system.

Intended Use

If the external system is considered the master system of the information, ProvenanceStatusSe can be used to nullify (invalidate) the data in COSMIC if it is nullified (invalidated) in the master system. Intended user of the API is a healthcare professional with a specified HSA ID. The healthcare professional should have their assignment (medarbetaruppdrag) and be connected to the specified unit. The specified unit should also be identified with HSA ID.

Specific Rules and Limitations

Type Description
Rule The API should not be used by patients who wishes to nullify (invalidate) a QuestionnaireResponse or Observation. This needs to be handled with business routines outside the API communication.
Rule The API should not be used to transfer data between caregivers.
Rule The API for nullifying (invalidating) should be implemented for real-time use by external system due to the patient risk with having wrong information in COSMIC.
Limitation The only supported target is QuestionnaireResponse or Observation.
Limitation The only supported activity code is NULLIFY.
Limitation Reason.coding is not applicable for QuestionnaireResponse, only reason.text.
Limitation The only supported reason.coding for Observation is EIE.

Versions

COS version Profile version Required COSMIC version Date Description
4.1.0 1.0.0 R8.3.05 July 2021 Initial version, support for POST

APIs & Supported Operations

HTTP Method Description
POST Support to POST Provenance with target QuestionnaireResponse or Observation

Supported Queries

  1. POST [baseURL]/Provenance

Error Codes

In the table below, a few error messages specific for Provenance are listed.

Code Description Comment
400 Not supported target Occurs when provenance.target is something else than QuestionnaireResponse or Observation
400 Not supported activity Occurs when provenance.activity is something else than NULLIFY

Usages:

You can also check for usages in the FHIR IG Statistics

Formal Views of Profile Content

Description of Profiles, Differentials, Snapshots and how the different presentations work.

NameFlagsCard.TypeDescription & Constraints    Filter: Filtersdoco
.. Provenance 0..* Provenance Who, What, When for a set of resources
... implicitRules ?!Σ 0..1 uri A set of rules under which this content was created
... modifierExtension ?! 0..* Extension Extensions that cannot be ignored
... target Σ 1..* Reference(QuestionnaireResponse | Observation) Target Reference(s), only a QuestionnaireResponse or an Observation can be referred
... reason 1..1 CodeableConcept Reason the activity is occurring
Binding: PurposeOfUse (extensible): The reason the activity took place.
.... coding Σ 0..1 Coding Only one coding is allowed for the reason
.... text Σ 1..1 string Plain text representation of the concept
... activity 1..1 CodeableConcept Activity that occurred. The profile only supports nullify for now
Binding: ProvenanceActivityType (extensible): The activity that took place.
.... coding Σ 1..1 Coding Code defined by a terminology system
... agent 1..* BackboneElement Actor involved
.... modifierExtension ?!Σ 0..* Extension Extensions that cannot be ignored even if unrecognized
.... who Σ 1..1 Reference(Practitioner | PractitionerRole | Organization) Who participated

doco Documentation for this format

Terminology Bindings

PathConformanceValueSetURI
Provenance.reasonextensiblePurposeOfUse
http://terminology.hl7.org/ValueSet/v3-PurposeOfUse
Provenance.activityextensibleProvenanceActivityType
http://hl7.org/fhir/ValueSet/provenance-activity-type
From the FHIR Standard
Provenance.entity.rolerequiredProvenanceEntityRole
http://hl7.org/fhir/ValueSet/provenance-entity-role|4.0.1
From the FHIR Standard

Constraints

IdGradePath(s)DetailsRequirements
dom-2errorProvenanceIf the resource is contained in another resource, it SHALL NOT contain nested Resources
: contained.contained.empty()
dom-3errorProvenanceIf the resource is contained in another resource, it SHALL be referred to from elsewhere in the resource or SHALL refer to the containing resource
: 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()
dom-4errorProvenanceIf a resource is contained in another resource, it SHALL NOT have a meta.versionId or a meta.lastUpdated
: contained.meta.versionId.empty() and contained.meta.lastUpdated.empty()
dom-5errorProvenanceIf a resource is contained in another resource, it SHALL NOT have a security label
: contained.meta.security.empty()
dom-6best practiceProvenanceA resource should have narrative for robust management
: text.`div`.exists()
ele-1error**ALL** elementsAll FHIR elements must have a @value or children
: hasValue() or (children().count() > id.count())
ext-1error**ALL** extensionsMust have either extensions or value[x], not both
: extension.exists() != value.exists()

This structure is derived from Provenance

NameFlagsCard.TypeDescription & Constraints    Filter: Filtersdoco
.. Provenance 0..* Provenance Who, What, When for a set of resources
... meta
.... profile 1..1 canonical(StructureDefinition) Profiles this resource claims to conform to
... target 1..* Reference(QuestionnaireResponse | Observation) Target Reference(s), only a QuestionnaireResponse or an Observation can be referred
... occurred[x] 0..0
... location 0..0
... reason 1..1 CodeableConcept Reason the activity is occurring
.... coding 0..1 Coding Only one coding is allowed for the reason
.... text 1..1 string Plain text representation of the concept
... activity 1..1 CodeableConcept Activity that occurred. The profile only supports nullify for now
.... coding 1..1 Coding Code defined by a terminology system
... agent 1..* BackboneElement Actor involved
.... who 1..1 Reference(Practitioner | PractitionerRole | Organization) Who participated
.... onBehalfOf 0..0
... entity 0..0

doco Documentation for this format
NameFlagsCard.TypeDescription & Constraints    Filter: Filtersdoco
.. Provenance 0..* Provenance Who, What, When for a set of resources
... id Σ 0..1 id Logical id of this artifact
... meta Σ 0..1 Meta Metadata about the resource
.... id 0..1 string Unique id for inter-element referencing
.... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
.... versionId Σ 0..1 id Version specific identifier
.... lastUpdated Σ 0..1 instant When the resource version last changed
.... source Σ 0..1 uri Identifies where the resource comes from
.... profile Σ 1..1 canonical(StructureDefinition) Profiles this resource claims to conform to
.... security Σ 0..* Coding Security Labels applied to this resource
Binding: All Security Labels (extensible): Security Labels from the Healthcare Privacy and Security Classification System.
.... tag Σ 0..* Coding Tags applied to this resource
Binding: CommonTags (example): Codes that represent various types of tags, commonly workflow-related; e.g. "Needs review by Dr. Jones".
... implicitRules ?!Σ 0..1 uri A set of rules under which this content was created
... text 0..1 Narrative Text summary of the resource, for human interpretation
This profile does not constrain the narrative in regard to content, language, or traceability to data elements
... contained 0..* Resource Contained, inline Resources
... extension 0..* Extension Additional content defined by implementations
... modifierExtension ?! 0..* Extension Extensions that cannot be ignored
... target Σ 1..* Reference(QuestionnaireResponse | Observation) Target Reference(s), only a QuestionnaireResponse or an Observation can be referred
... recorded Σ 1..1 instant When the activity was recorded / updated
... reason 1..1 CodeableConcept Reason the activity is occurring
Binding: PurposeOfUse (extensible): The reason the activity took place.
.... id 0..1 string Unique id for inter-element referencing
.... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
.... coding Σ 0..1 Coding Only one coding is allowed for the reason
.... text Σ 1..1 string Plain text representation of the concept
... activity 1..1 CodeableConcept Activity that occurred. The profile only supports nullify for now
Binding: ProvenanceActivityType (extensible): The activity that took place.
.... id 0..1 string Unique id for inter-element referencing
.... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
.... coding Σ 1..1 Coding Code defined by a terminology system
.... text Σ 0..1 string Plain text representation of the concept
... agent 1..* BackboneElement Actor involved
.... id 0..1 string Unique id for inter-element referencing
.... extension 0..* Extension Additional content defined by implementations
.... modifierExtension ?!Σ 0..* Extension Extensions that cannot be ignored even if unrecognized
.... type Σ 0..1 CodeableConcept How the agent participated
Binding: ProvenanceParticipantType (extensible): The type of participation that a provenance agent played with respect to the activity.
.... role 0..* CodeableConcept What the agents role was
Binding: SecurityRoleType (example): The role that a provenance agent played with respect to the activity.
.... who Σ 1..1 Reference(Practitioner | PractitionerRole | Organization) Who participated
... signature 0..* Signature Signature on target

doco Documentation for this format

Terminology Bindings

PathConformanceValueSetURI
Provenance.meta.securityextensibleAll Security Labels
http://hl7.org/fhir/ValueSet/security-labels
From the FHIR Standard
Provenance.meta.tagexampleCommonTags
http://hl7.org/fhir/ValueSet/common-tags
From the FHIR Standard
Provenance.languagepreferredCommonLanguages
http://hl7.org/fhir/ValueSet/languages
From the FHIR Standard
Additional Bindings Purpose
AllLanguages Max Binding
Provenance.reasonextensiblePurposeOfUse
http://terminology.hl7.org/ValueSet/v3-PurposeOfUse
Provenance.activityextensibleProvenanceActivityType
http://hl7.org/fhir/ValueSet/provenance-activity-type
From the FHIR Standard
Provenance.agent.typeextensibleProvenanceParticipantType
http://hl7.org/fhir/ValueSet/provenance-agent-type
From the FHIR Standard
Provenance.agent.roleexampleSecurityRoleType
http://hl7.org/fhir/ValueSet/security-role-type
From the FHIR Standard
Provenance.entity.rolerequiredProvenanceEntityRole
http://hl7.org/fhir/ValueSet/provenance-entity-role|4.0.1
From the FHIR Standard

Constraints

IdGradePath(s)DetailsRequirements
dom-2errorProvenanceIf the resource is contained in another resource, it SHALL NOT contain nested Resources
: contained.contained.empty()
dom-3errorProvenanceIf the resource is contained in another resource, it SHALL be referred to from elsewhere in the resource or SHALL refer to the containing resource
: 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()
dom-4errorProvenanceIf a resource is contained in another resource, it SHALL NOT have a meta.versionId or a meta.lastUpdated
: contained.meta.versionId.empty() and contained.meta.lastUpdated.empty()
dom-5errorProvenanceIf a resource is contained in another resource, it SHALL NOT have a security label
: contained.meta.security.empty()
dom-6best practiceProvenanceA resource should have narrative for robust management
: text.`div`.exists()
ele-1error**ALL** elementsAll FHIR elements must have a @value or children
: hasValue() or (children().count() > id.count())
ext-1error**ALL** extensionsMust have either extensions or value[x], not both
: extension.exists() != value.exists()

This structure is derived from Provenance

Summary

Mandatory: 4 elements(1 nested mandatory element)
Prohibited: 5 elements

Key Elements View

NameFlagsCard.TypeDescription & Constraints    Filter: Filtersdoco
.. Provenance 0..* Provenance Who, What, When for a set of resources
... implicitRules ?!Σ 0..1 uri A set of rules under which this content was created
... modifierExtension ?! 0..* Extension Extensions that cannot be ignored
... target Σ 1..* Reference(QuestionnaireResponse | Observation) Target Reference(s), only a QuestionnaireResponse or an Observation can be referred
... reason 1..1 CodeableConcept Reason the activity is occurring
Binding: PurposeOfUse (extensible): The reason the activity took place.
.... coding Σ 0..1 Coding Only one coding is allowed for the reason
.... text Σ 1..1 string Plain text representation of the concept
... activity 1..1 CodeableConcept Activity that occurred. The profile only supports nullify for now
Binding: ProvenanceActivityType (extensible): The activity that took place.
.... coding Σ 1..1 Coding Code defined by a terminology system
... agent 1..* BackboneElement Actor involved
.... modifierExtension ?!Σ 0..* Extension Extensions that cannot be ignored even if unrecognized
.... who Σ 1..1 Reference(Practitioner | PractitionerRole | Organization) Who participated

doco Documentation for this format

Terminology Bindings

PathConformanceValueSetURI
Provenance.reasonextensiblePurposeOfUse
http://terminology.hl7.org/ValueSet/v3-PurposeOfUse
Provenance.activityextensibleProvenanceActivityType
http://hl7.org/fhir/ValueSet/provenance-activity-type
From the FHIR Standard
Provenance.entity.rolerequiredProvenanceEntityRole
http://hl7.org/fhir/ValueSet/provenance-entity-role|4.0.1
From the FHIR Standard

Constraints

IdGradePath(s)DetailsRequirements
dom-2errorProvenanceIf the resource is contained in another resource, it SHALL NOT contain nested Resources
: contained.contained.empty()
dom-3errorProvenanceIf the resource is contained in another resource, it SHALL be referred to from elsewhere in the resource or SHALL refer to the containing resource
: 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()
dom-4errorProvenanceIf a resource is contained in another resource, it SHALL NOT have a meta.versionId or a meta.lastUpdated
: contained.meta.versionId.empty() and contained.meta.lastUpdated.empty()
dom-5errorProvenanceIf a resource is contained in another resource, it SHALL NOT have a security label
: contained.meta.security.empty()
dom-6best practiceProvenanceA resource should have narrative for robust management
: text.`div`.exists()
ele-1error**ALL** elementsAll FHIR elements must have a @value or children
: hasValue() or (children().count() > id.count())
ext-1error**ALL** extensionsMust have either extensions or value[x], not both
: extension.exists() != value.exists()

Differential View

This structure is derived from Provenance

NameFlagsCard.TypeDescription & Constraints    Filter: Filtersdoco
.. Provenance 0..* Provenance Who, What, When for a set of resources
... meta
.... profile 1..1 canonical(StructureDefinition) Profiles this resource claims to conform to
... target 1..* Reference(QuestionnaireResponse | Observation) Target Reference(s), only a QuestionnaireResponse or an Observation can be referred
... occurred[x] 0..0
... location 0..0
... reason 1..1 CodeableConcept Reason the activity is occurring
.... coding 0..1 Coding Only one coding is allowed for the reason
.... text 1..1 string Plain text representation of the concept
... activity 1..1 CodeableConcept Activity that occurred. The profile only supports nullify for now
.... coding 1..1 Coding Code defined by a terminology system
... agent 1..* BackboneElement Actor involved
.... who 1..1 Reference(Practitioner | PractitionerRole | Organization) Who participated
.... onBehalfOf 0..0
... entity 0..0

doco Documentation for this format

Snapshot View

NameFlagsCard.TypeDescription & Constraints    Filter: Filtersdoco
.. Provenance 0..* Provenance Who, What, When for a set of resources
... id Σ 0..1 id Logical id of this artifact
... meta Σ 0..1 Meta Metadata about the resource
.... id 0..1 string Unique id for inter-element referencing
.... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
.... versionId Σ 0..1 id Version specific identifier
.... lastUpdated Σ 0..1 instant When the resource version last changed
.... source Σ 0..1 uri Identifies where the resource comes from
.... profile Σ 1..1 canonical(StructureDefinition) Profiles this resource claims to conform to
.... security Σ 0..* Coding Security Labels applied to this resource
Binding: All Security Labels (extensible): Security Labels from the Healthcare Privacy and Security Classification System.
.... tag Σ 0..* Coding Tags applied to this resource
Binding: CommonTags (example): Codes that represent various types of tags, commonly workflow-related; e.g. "Needs review by Dr. Jones".
... implicitRules ?!Σ 0..1 uri A set of rules under which this content was created
... text 0..1 Narrative Text summary of the resource, for human interpretation
This profile does not constrain the narrative in regard to content, language, or traceability to data elements
... contained 0..* Resource Contained, inline Resources
... extension 0..* Extension Additional content defined by implementations
... modifierExtension ?! 0..* Extension Extensions that cannot be ignored
... target Σ 1..* Reference(QuestionnaireResponse | Observation) Target Reference(s), only a QuestionnaireResponse or an Observation can be referred
... recorded Σ 1..1 instant When the activity was recorded / updated
... reason 1..1 CodeableConcept Reason the activity is occurring
Binding: PurposeOfUse (extensible): The reason the activity took place.
.... id 0..1 string Unique id for inter-element referencing
.... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
.... coding Σ 0..1 Coding Only one coding is allowed for the reason
.... text Σ 1..1 string Plain text representation of the concept
... activity 1..1 CodeableConcept Activity that occurred. The profile only supports nullify for now
Binding: ProvenanceActivityType (extensible): The activity that took place.
.... id 0..1 string Unique id for inter-element referencing
.... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
.... coding Σ 1..1 Coding Code defined by a terminology system
.... text Σ 0..1 string Plain text representation of the concept
... agent 1..* BackboneElement Actor involved
.... id 0..1 string Unique id for inter-element referencing
.... extension 0..* Extension Additional content defined by implementations
.... modifierExtension ?!Σ 0..* Extension Extensions that cannot be ignored even if unrecognized
.... type Σ 0..1 CodeableConcept How the agent participated
Binding: ProvenanceParticipantType (extensible): The type of participation that a provenance agent played with respect to the activity.
.... role 0..* CodeableConcept What the agents role was
Binding: SecurityRoleType (example): The role that a provenance agent played with respect to the activity.
.... who Σ 1..1 Reference(Practitioner | PractitionerRole | Organization) Who participated
... signature 0..* Signature Signature on target

doco Documentation for this format

Terminology Bindings

PathConformanceValueSetURI
Provenance.meta.securityextensibleAll Security Labels
http://hl7.org/fhir/ValueSet/security-labels
From the FHIR Standard
Provenance.meta.tagexampleCommonTags
http://hl7.org/fhir/ValueSet/common-tags
From the FHIR Standard
Provenance.languagepreferredCommonLanguages
http://hl7.org/fhir/ValueSet/languages
From the FHIR Standard
Additional Bindings Purpose
AllLanguages Max Binding
Provenance.reasonextensiblePurposeOfUse
http://terminology.hl7.org/ValueSet/v3-PurposeOfUse
Provenance.activityextensibleProvenanceActivityType
http://hl7.org/fhir/ValueSet/provenance-activity-type
From the FHIR Standard
Provenance.agent.typeextensibleProvenanceParticipantType
http://hl7.org/fhir/ValueSet/provenance-agent-type
From the FHIR Standard
Provenance.agent.roleexampleSecurityRoleType
http://hl7.org/fhir/ValueSet/security-role-type
From the FHIR Standard
Provenance.entity.rolerequiredProvenanceEntityRole
http://hl7.org/fhir/ValueSet/provenance-entity-role|4.0.1
From the FHIR Standard

Constraints

IdGradePath(s)DetailsRequirements
dom-2errorProvenanceIf the resource is contained in another resource, it SHALL NOT contain nested Resources
: contained.contained.empty()
dom-3errorProvenanceIf the resource is contained in another resource, it SHALL be referred to from elsewhere in the resource or SHALL refer to the containing resource
: 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()
dom-4errorProvenanceIf a resource is contained in another resource, it SHALL NOT have a meta.versionId or a meta.lastUpdated
: contained.meta.versionId.empty() and contained.meta.lastUpdated.empty()
dom-5errorProvenanceIf a resource is contained in another resource, it SHALL NOT have a security label
: contained.meta.security.empty()
dom-6best practiceProvenanceA resource should have narrative for robust management
: text.`div`.exists()
ele-1error**ALL** elementsAll FHIR elements must have a @value or children
: hasValue() or (children().count() > id.count())
ext-1error**ALL** extensionsMust have either extensions or value[x], not both
: extension.exists() != value.exists()

This structure is derived from Provenance

Summary

Mandatory: 4 elements(1 nested mandatory element)
Prohibited: 5 elements

 

Other representations of profile: CSV, Excel, Schematron