NZ Shared Digital Health Record API
1.1.6 - release

NZ Shared Digital Health Record API, published by Health New Zealand. This guide is not an authorized publication; it is the continuous build for version 1.1.6 built by the FHIR (HL7® FHIR® Standard) CI Build. This version is based on the current content of https://github.com/tewhatuora/fhir-sdhr/ and changes regularly. See the Directory of published versions

: SDHRVerificationSamplesOperation - XML Representation

Draft as of 2026-10-20

Raw xml | Download


<OperationDefinition xmlns="http://hl7.org/fhir">
  <id value="SDHRVerificationSamplesOperation"/>
  <text>
    <status value="generated"/>
    <div xmlns="http://www.w3.org/1999/xhtml"><p class="res-header-id"><b>Generated Narrative: OperationDefinition SDHRVerificationSamplesOperation</b></p><a name="SDHRVerificationSamplesOperation"> </a><a name="hcSDHRVerificationSamplesOperation"> </a><p>URL: [base]/AuditEvent/$verification-samples</p><h3>Parameters</h3><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>_count</td><td/><td>0..1</td><td><a href="http://hl7.org/fhir/R4/datatypes.html#integer">integer</a></td><td/><td><div><p>Optional page size. Limits the maximum number of sampled AuditEvent resources returned in the Bundle.</p>
</div></td></tr><tr><td>IN</td><td>_getpagesoffset</td><td/><td>0..1</td><td><a href="http://hl7.org/fhir/R4/datatypes.html#integer">integer</a></td><td/><td><div><p>Optional zero-based starting offset. Skips the specified number of matching sampled AuditEvent resources before returning results.</p>
</div></td></tr><tr><td>OUT</td><td>return</td><td/><td>1..1</td><td><a href="http://hl7.org/fhir/R4/bundle.html">Bundle</a></td><td/><td><div><p>A searchset Bundle of slim AuditEvent resources conforming to SDHRAuditEvent for the authenticated client, including an empty Bundle when no samples are pending. Bundle paging links return to this operation.</p>
</div></td></tr></table></div>
  </text>
  <url
       value="https://fhir-ig.digital.health.nz/sdhr/OperationDefinition/SDHRVerificationSamplesOperation"/>
  <version value="1.1.6"/>
  <name value="VerificationSamples"/>
  <status value="draft"/>
  <kind value="operation"/>
  <date value="2026-10-20T03:14:47+00:00"/>
  <publisher value="Health New Zealand"/>
  <contact>
    <name value="Health New Zealand"/>
    <telecom>
      <system value="url"/>
      <value value="https://github.com/tewhatuora"/>
    </telecom>
  </contact>
  <contact>
    <name value="HNZ Integration Team"/>
    <telecom>
      <system value="email"/>
      <value value="integration@tewhatuora.govt.nz"/>
      <use value="work"/>
    </telecom>
  </contact>
  <description
               value="DRAFT OPERATION: This operation returns `AuditEvent` resources that have been sampled for verification and are still outstanding for the data viewer application.

The operation is invoked on the `AuditEvent` type using `GET /AuditEvent/$verification-samples`.

Sampling runs independently of this retrieval operation.

A successful response is always a searchset `Bundle` containing slim `SDHRAuditEvent` samples. In each sample, the application agent has the `dataprocessor` role and identifies the Keycloak client UUID in `who.identifier`. The separate healthworker agent carries the clinician’s HPI person identifier; an organisation agent may also be present. Use the clinician identity, patient NHI and recorded time to assess whether the clinician had a valid reason to access that patient. NHI and correlation ID are returned as string-valued `entity.detail` entries with types `nhi` and `correlationId`.

Samples:
- are pending verification
- belong to the authenticated `client_id`
- have not already been marked as verified by the data viewer application

The operation supports optional paging parameters:
- `_count` to limit the maximum number of samples returned in a single response
- `_getpagesoffset` to skip a number of matching samples before returning results

Only these paging parameters are forwarded to the sample search. The server fixes the client and pending-verification filters. Follow the returned paging links, which point back to this operation; links may be relative in the development environment. An empty searchset Bundle means no pending samples are currently available.

The required operation scope is `https://fhir-ig.digital.health.nz/sdhr/OperationDefinition/SDHRVerificationSamplesOperation`. Generic AuditEvent read, search and write routes are unavailable."/>
  <affectsState value="false"/>
  <code value="verification-samples"/>
  <resource value="AuditEvent"/>
  <system value="false"/>
  <type value="true"/>
  <instance value="false"/>
  <parameter>
    <name value="_count"/>
    <use value="in"/>
    <min value="0"/>
    <max value="1"/>
    <documentation
                   value="Optional page size. Limits the maximum number of sampled AuditEvent resources returned in the Bundle."/>
    <type value="integer"/>
  </parameter>
  <parameter>
    <name value="_getpagesoffset"/>
    <use value="in"/>
    <min value="0"/>
    <max value="1"/>
    <documentation
                   value="Optional zero-based starting offset. Skips the specified number of matching sampled AuditEvent resources before returning results."/>
    <type value="integer"/>
  </parameter>
  <parameter>
    <name value="return"/>
    <use value="out"/>
    <min value="1"/>
    <max value="1"/>
    <documentation
                   value="A searchset Bundle of slim AuditEvent resources conforming to SDHRAuditEvent for the authenticated client, including an empty Bundle when no samples are pending. Bundle paging links return to this operation."/>
    <type value="Bundle"/>
  </parameter>
</OperationDefinition>