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

<OperationDefinition xmlns="http://hl7.org/fhir">
  <id value="-s-fetch-ssl-orders"/>
  <text>
    <status value="extensions"/><div xmlns="http://www.w3.org/1999/xhtml"><p>URL: [base]/$fetch-ssl-orders</p><p>Parameters</p><table class="grid"><tr><td><b>Use</b></td><td><b>Name</b></td><td><b>Scope</b></td><td><b>Cardinality</b></td><td><b>Type</b></td><td><b>Binding</b></td><td><b>Documentation</b></td></tr><tr><td>IN</td><td>anonymization</td><td/><td>1..1</td><td><a href="http://hl7.org/fhir/R4/datatypes.html#string">string</a></td><td/><td/></tr><tr><td>IN</td><td>organization</td><td/><td>0..1</td><td><a href="http://hl7.org/fhir/R4/references.html#Reference">Reference</a></td><td/><td/></tr><tr><td>IN</td><td>seller</td><td/><td>0..1</td><td><a href="http://hl7.org/fhir/R4/references.html#Reference">Reference</a></td><td/><td/></tr><tr><td>IN</td><td>period</td><td/><td>0..1</td><td><a href="http://hl7.org/fhir/R4/datatypes.html#Period">Period</a></td><td/><td/></tr><tr><td>OUT</td><td>return</td><td/><td>0..1</td><td><a href="http://hl7.org/fhir/R4/binary.html">Binary</a></td><td/><td/></tr></table></div>
  </text>
  <url value="https://reporting.devtest.systematic-ehealth.com/fhir/OperationDefinition/-s-fetch-ssl-orders"/>
  <version value="2.9.0"/>
  <name value="fetch-ssl-orders"/>
  <title value="Fetch ssl orders"/>
  <status value="active"/>
  <kind value="operation"/>
  <date value="2023-08-23T12:57:57+00:00"/>
  <publisher value="Systematic | Trifork"/>
  <contact>
    <name value="Systematic | Trifork"/>
    <telecom>
      <system value="url"/>
      <value value="http://ehealth.sundhed.dk"/>
    </telecom>
  </contact>
  <description value="### Report Contents&#xA;This report contains SSL Orders&#xA;- OrderDetails&#xA;- OrderLines&#xA;- TraceLines&#xA;### Grouping &#xA;Order. Each Order is returned in a single JSon file.&#xA;### Parameters&#xA;- organization: Filter on Order.buyer&#xA;- period: Filter on TraceLine.timestamp&#xA;- seller: Filter on Order.seller&#xA;### Output&#xA;Output can be found in Binary.content. This is a Base64 encoded .zip file containing JSon files corresponding to the report groups.&#xA;### Example output&#xA;All returned objects are SSL resources. See the SSL API description for details&#xA;&#xA;    {&#xA;        'OrderDetails': {&#xA;            'order': {&#xA;                'id': 'https://ssl-order.local.ehealth.sundhed.dk/v1/order/ORDER',&#xA;                'threadId': null,&#xA;                'identifiers': null,&#xA;                'status': null,&#xA;                'priority': null,&#xA;                'notes': null,&#xA;                'buyer': 'https://ssl-order.local.ehealth.sundhed.dk/v1/party/BUYER',&#xA;                'seller': 'https://ssl-order.local.ehealth.sundhed.dk/v1/party/SELLER',&#xA;                'sellerDeliveryContactEmail': null,&#xA;                'carePlanRef': null,&#xA;                'carePlanTitle': null,&#xA;                'earliestDeliveryDate': null,&#xA;                'latestDeliveryDate': null,&#xA;                'receiver': null&#xA;            },&#xA;            'orderLines': [{&#xA;                    'id': 'https://ssl-order.local.ehealth.sundhed.dk/v1/order-line/ORDERLINE',&#xA;                    'order': 'https://ssl-order.local.ehealth.sundhed.dk/v1/order/ORDER',&#xA;                    'status': null,&#xA;                    'item': null,&#xA;                    'agreedDate': null,&#xA;                    'device': null&#xA;                }&#xA;            ],&#xA;            'traceLines': [{&#xA;                    'id': 'https://ssl-order.local.ehealth.sundhed.dk/v1/order/ORDER/1',&#xA;                    'timestamp': '2019-12-24T18:00:00Z',&#xA;                    'createdByOrganization': null,&#xA;                    'createdByUser': null,&#xA;                    'text': null,&#xA;                    'supplementaryText': null,&#xA;                    'order': 'https://ssl-order.local.ehealth.sundhed.dk/v1/order/ORDER',&#xA;                    'orderLine': null,&#xA;                    'statusChange': null&#xA;                }&#xA;            ]&#xA;        }&#xA;    }&#xA;"/>
  <affectsState value="true"/>
  <code value="fetch-ssl-orders"/>
  <system value="true"/>
  <type value="false"/>
  <instance value="false"/>
  <parameter>
    <name value="anonymization"/>
    <use value="in"/>
    <min value="1"/>
    <max value="1"/>
    <type value="string"/>
  </parameter>
  <parameter>
    <name value="organization"/>
    <use value="in"/>
    <min value="0"/>
    <max value="1"/>
    <type value="Reference"/>
  </parameter>
  <parameter>
    <name value="seller"/>
    <use value="in"/>
    <min value="0"/>
    <max value="1"/>
    <type value="Reference"/>
  </parameter>
  <parameter>
    <name value="period"/>
    <use value="in"/>
    <min value="0"/>
    <max value="1"/>
    <type value="Period"/>
  </parameter>
  <parameter>
    <name value="return"/>
    <use value="out"/>
    <min value="0"/>
    <max value="1"/>
    <type value="Binary"/>
  </parameter>
</OperationDefinition>