-s-create-episode-of-care
type: OperationDefinition
node role: treeRoot
resource.id:
  value: -s-create-episode-of-care
domain resource.text:
  narrative.status:
    value: generated
  narrative.div: Generated Narrative: OperationDefinition -s-create-episode-of-care URL: [base]/$create-episode-of-care Parameters Use Name Scope Cardinality Type Binding Documentation IN episodeOfCareAndProvenances 1..1 Bundle The input is a Bundle which must contain exactly one EpisodeOfCare, conditions referenced in diagnosis list and at least one Provenance resource. All Provenances in the input must have the EpisodeOfCare as target. At least one Provenance must be interpreted into a 'Privacy-provenance' OUT return 0..1 Bundle
operation definition.url:
  value: http://ehealth.sundhed.dk/fhir/OperationDefinition/-s-create-episode-of-care
operation definition.version:
  value: 10.0.0
operation definition.name:
  value: create-episode-of-care
operation definition.title:
  value: Create an EpisodeOfCare
operation definition.status:
  value: active
operation definition.kind:
  value: operation
operation definition.date:
  value: 2026-08-06T13:17:54+00:00
operation definition.publisher:
  value: Den telemedicinske infrastruktur (eHealth Infrastructure)
operation definition.contact:
  index: 0
  contact detail.name:
    value: Den telemedicinske infrastruktur (eHealth Infrastructure)
  contact detail.telecom:
    index: 0
    contact point.system:
      value: url
    contact point.value:
      value: http://ehealth.sundhed.dk
operation definition.description:
  value: This operation persists an EpisodeOfCare based on the transient value of an EpisodeOfCare provided in the input. ## Input The input is a Bundle which must contain exactly one EpisodeOfCare, conditions referenced in diagnosis list and at least one Provenance resource. All Provenances in the input must have the EpisodeOfCare as target. At least one Provenance must be interpreted into a 'Privacy-provenance' (see below). ### The EpisodeOfCare resource The EpisodeOfCare has to have `PLANNED` status The 'id' property of the EpisodeOfCare will be reassigned by the server, but can be referenced by other resources in the same bundle. The GDPR Data Controller (Danish: 'Dataansvarlig') of the EpisodeOfCare is provided through the 'ehealth-managing-organization' extension (managingOrganizations), where each entry holds the responsible organisation and the period during which it held that responsibility. The standard 'managingOrganization' property is no longer used (cardinality 0..0). ### The privacy-Provenance resource A privacy-Provenance is a Provenance resource characterized by having at least one entry in Provenance.policy which data are transported, stored, or processed in the system. Possible values are: - 'http://ehealth.sundhed.dk/policy/dk/sundhedsloven' - 'http://ehealth.sundhed.dk/policy/dk/serviceloven' - 'http://ehealth.sundhed.dk/policy/dk/aeldreloven' ### Diagnosis referenced Condition resource For any diagnosis listed, the referenced Condition must be concerning the same Patient as the EpisodeOfCare. ### Treatment area validation When creating an EpisodeOfCare, the infrastructure validates that all diagnoses (referenced Condition.code) are within the treatment area of the telemedicine solution tied to the EpisodeOfCare.The telemedicine solution is determined by inspecting the incoming security token of the practitioner creating the EpisodeOfCare (coexistence-tag in scope claim).The treatment areas are defined by each telemedicine solution having a ValueSet dete…
operation definition.jurisdiction:
  index: 0
  codeable concept.coding:
    index: 0
    coding.system:
      value: urn:iso:std:iso:3166
    coding.code:
      value: DK
    coding.display:
      value: Denmark
operation definition.affects state:
  value: true
operation definition.code:
  value: create-episode-of-care
operation definition.system:
  value: true
operation definition.type:
  value: false
operation definition.instance:
  value: false
operation definition.parameter:
  index: 0
  operation definition.parameter.name:
    value: episodeOfCareAndProvenances
  operation definition.parameter.use:
    value: in
  operation definition.parameter.min:
    value: 1
  operation definition.parameter.max:
    value: 1
  operation definition.parameter.documentation:
    value: The input is a Bundle which must contain exactly one EpisodeOfCare, conditions referenced in diagnosis list and at least one Provenance resource. All Provenances in the input must have the EpisodeOfCare as target. At least one Provenance must be interpreted into a 'Privacy-provenance'
  operation definition.parameter.type:
    value: Bundle
operation definition.parameter:
  index: 1
  operation definition.parameter.name:
    value: return
  operation definition.parameter.use:
    value: out
  operation definition.parameter.min:
    value: 0
  operation definition.parameter.max:
    value: 1
  operation definition.parameter.type:
    value: Bundle