---
title: "Scan"
method: GET
path: "/patient-merge/v1/updates/scan"
tags: ["v1"]
---

# Scan

`GET /patient-merge/v1/updates/scan`

## Request

- Base URL: `https://pre-api.joincandidhealth.com`
- URL: `https://pre-api.joincandidhealth.com/patient-merge/v1/updates/scan`
- Auth: HTTP bearer

Scans up to 1000 patient merge updates. The since query parameter is inclusive, and the result list is ordered by updatedAt ascending.

**Polling Pattern:**
To continuously poll for updates without gaps:
1. Make your initial request with a `since` timestamp (e.g., `since=2020-01-01T13:00:00.000Z`)
2. The API returns 100 by default and up to 1000 patient merge records, sorted by `updated_at` ascending
3. Find the `updated_at` value from the last record in the response
4. Use that `updated_at` value as the `since` parameter in your next request
5. Repeat steps 2-4 to ingest updates until you receive an empty list

**Important Notes:**
- The `since` parameter is inclusive, so you may receive the last record from the previous batch again (you can deduplicate by ID and version)
- All patient merge records include `updated_at`, `id`, `version`, `deactivated`, and `updating_user` fields for tracking changes
- Timestamps have millisecond resolution for precise ordering

## Query parameters

- `since` string, date-time, required
- `maxResults` integer

## Response `200`

Response with status 200

- PreEncounterPatientMergesV1PatientMerge[]
  - `organization_id` string, required: The unique identifier for an Organization in the database
  - `deactivated` boolean, required: True if the object is deactivated. Deactivated objects are not returned in search results but are returned in all other endpoints including scan.
  - `version` integer, required: The version of the object. Any update to any property of an object object will create a new version.
  - `updated_at` string, date-time, required
  - `updating_user_id` string, required: The unique identifier for a User in the database
  - `alternative_patient_mrn` string, required: The MRN of the patient that was merged.
  - `primary_patient_mrn` string, required: The MRN of the patient that is getting a patient merged into them.
  - `id` string, required: The unique identifier for a PatientMerge record.

## Changes

- **2026-09-17** `24b2d80d577a`: 1 breaking, 1 warning, 9 info
  - the `items/` response's property type changed from no type to `object` for status `200`
  - deleted the `header` request parameter `Authorization`
  - the endpoint scheme security `OAuthScheme` was added to the API
  - added the required property `items/alternative_patient_mrn` to the response with the `200` status
  - …7 more
- **2026-09-12** `3a81ee81d4ed`: 1 info
  - api operation id `scan` removed and replaced with `v1_scan_4`

[Operation history](https://skmtc.dev/joincandidhealth/apis/api-reference/changes/patient-merge/v1/updates/scan/get.md)

---

[API](https://skmtc.dev/joincandidhealth/apis/api-reference.md) - [All operations](https://skmtc.dev/joincandidhealth/apis/api-reference/llms.txt) - [OpenAPI document](https://skmtc.dev/joincandidhealth/apis/api-reference/revisions/d8b0a61873e2?raw)
