<?xml version="1.0" encoding="UTF-8"?>

<Parameters xmlns="http://hl7.org/fhir">
  <id value="EraAppointmentProvenance-parameter-example"/>
  <parameter>
    <name value="Provenance"/>
    <resource>
      <Provenance>
        <meta>
          <profile value="https://eradocumentation.atostek.com/StructureDefinition/EraAppointmentProvenance"/>
        </meta>
        <language value="fi"/>
        <extension url="https://gen.kanta.fi/fhir/StructureDefinition/extension/serviceEvent">
          <valueIdentifier>
            <system value="urn:ietf:rfc:3986"/>
            <value value="urn:oid:1.2.246.10.99999773.14.2024.123"/>
          </valueIdentifier>
        </extension>
        <extension url="https://gen.kanta.fi/fhir/StructureDefinition/extension/Status">
          <valueCoding>
            <system value="urn:oid:1.2.246.537.5.40154.2008"/>
            <code value="3"/>
            <display value="Arkistointivalmis"/>
          </valueCoding>
        </extension>
        <extension url="https://gen.kanta.fi/fhir/StructureDefinition/extension/RegisterType">
          <valueCoding>
            <system value="urn:oid:1.2.246.537.5.40150.2009"/>
            <code value="2"/>
            <display value="Julkinen terveydenhuolto"/>
          </valueCoding>
        </extension>
        <extension url="https://gen.kanta.fi/fhir/StructureDefinition/extension/ReleaseDateForPatientViewing">
          <valueDate value="2026-05-10"/>
        </extension>
        <target>
          <reference value="Appointment/id"/>
          <display value="Ajanvaraus"/>
        </target>
        <recorded value="2023-05-10T09:02:00+00:00"/>
        <agent>
          <role>
            <coding>
              <system value="http://gen.kanta.fi/figen-cs-provenancerolecategory"/>
              <code value="2"/>
              <display value="Resurssin tallentanut ammattihenkilö"/>
            </coding>
          </role>
          <who>
            <reference value="Practitioner/id"/>
          </who>
        </agent>
        <agent>
          <role>
            <coding>
              <system value="http://gen.kanta.fi/figen-cs-provenancerolecategory"/>
              <code value="7"/>
              <display value="Resurssin tallentaneen ammattihenkilön palveluyksikkö"/>
            </coding>
          </role>
          <who>
            <identifier>
              <system value="urn:ietf:rfc:3986"/>
              <value value="urn:oid:1.2.246.10.99999773.10.20.1014"/>
            </identifier>
            <display value="Asiakaspalvelu, Kirkonkylän sosiaali- ja terveystoimi"/>
          </who>
        </agent>
        <agent>
          <role>
            <coding>
              <system value="http://gen.kanta.fi/figen-cs-provenancerolecategory"/>
              <code value="1"/>
              <display value="Resurssin rekisterinpitäjä"/>
            </coding>
          </role>
          <who>
            <identifier>
              <system value="urn:ietf:rfc:3986"/>
              <value value="urn:oid:1.2.246.10.99999773.19.0"/>
            </identifier>
            <display value="Hämeen hyvinvointialueen rekisterinpitäjä"/>
          </who>
        </agent>
        <agent>
          <role>
            <coding>
              <system value="http://gen.kanta.fi/figen-cs-provenancerolecategory"/>
              <code value="13"/>
              <display value="Resurssin tuottanut palveluntuottaja"/>
            </coding>
          </role>
          <who>
            <identifier>
              <system value="urn:ietf:rfc:3986"/>
              <value value="urn:oid:1.2.246.10.99999773.10.0"/>
            </identifier>
            <display value="Hämeen hyvinvointialue"/>
          </who>
        </agent>
        <agent>
          <role>
            <coding>
              <system value="http://gen.kanta.fi/figen-cs-provenancerolecategory"/>
              <code value="10"/>
              <display value="Palvelunjärjestäjä"/>
            </coding>
          </role>
          <who>
            <identifier>
              <system value="urn:ietf:rfc:3986"/>
              <value value="urn:oid:1.2.246.10.99999773.10.0"/>
            </identifier>
            <display value="Hämeen hyvinvointialue"/>
          </who>
        </agent>
        <agent>
          <role>
            <coding>
              <system value="http://gen.kanta.fi/figen-cs-provenancerolecategory"/>
              <code value="8"/>
              <display value="Isäntäorganisaatio"/>
            </coding>
          </role>
          <who>
            <identifier>
              <system value="urn:ietf:rfc:3986"/>
              <value value="urn:oid:1.2.246.10.99999773.10.0"/>
            </identifier>
          </who>
        </agent>
        <agent>
          <role>
            <coding>
              <system value="http://gen.kanta.fi/figen-cs-provenancerolecategory"/>
              <code value="11"/>
              <display value="Aktiivi rekisterinpitäjä"/>
            </coding>
          </role>
          <who>
            <identifier>
              <system value="urn:ietf:rfc:3986"/>
              <value value="urn:oid:1.2.246.10.99999773.10.0"/>
            </identifier>
            <display value="Hämeen hyvinvointialue"/>
          </who>
        </agent>
        <agent>
          <role>
            <coding>
              <system value="http://gen.kanta.fi/figen-cs-provenancerolecategory"/>
              <code value="3"/>
              <display value="Asiakas tai potilas, jota resurssi koskee"/>
            </coding>
          </role>
          <who>
            <reference value="Patient/id"/>
          </who>
        </agent>
        <agent>
          <role>
            <coding>
              <system value="http://gen.kanta.fi/figen-cs-provenancerolecategory"/>
              <code value="4"/>
              <display value="Resurssin tuottanut tietojärjestelmä"/>
            </coding>
          </role>
          <who>
            <reference value="Device/id"/>
          </who>
        </agent>
      </Provenance>
    </resource>
  </parameter>
</Parameters>