curl --request POST \
--url https://api.example.com/v1/patients/match-suggestion \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"external_id": {
"type_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"value": "<string>"
},
"first_name": "<string>",
"last_name": "<string>",
"date_of_birth": "<string>",
"phone_number": "<string>",
"email": "<string>"
}
'import requests
url = "https://api.example.com/v1/patients/match-suggestion"
payload = {
"external_id": {
"type_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"value": "<string>"
},
"first_name": "<string>",
"last_name": "<string>",
"date_of_birth": "<string>",
"phone_number": "<string>",
"email": "<string>"
}
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
external_id: {type_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a', value: '<string>'},
first_name: '<string>',
last_name: '<string>',
date_of_birth: '<string>',
phone_number: '<string>',
email: '<string>'
})
};
fetch('https://api.example.com/v1/patients/match-suggestion', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.example.com/v1/patients/match-suggestion",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'external_id' => [
'type_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'value' => '<string>'
],
'first_name' => '<string>',
'last_name' => '<string>',
'date_of_birth' => '<string>',
'phone_number' => '<string>',
'email' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-API-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/v1/patients/match-suggestion"
payload := strings.NewReader("{\n \"external_id\": {\n \"type_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"value\": \"<string>\"\n },\n \"first_name\": \"<string>\",\n \"last_name\": \"<string>\",\n \"date_of_birth\": \"<string>\",\n \"phone_number\": \"<string>\",\n \"email\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-API-Key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.example.com/v1/patients/match-suggestion")
.header("X-API-Key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"external_id\": {\n \"type_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"value\": \"<string>\"\n },\n \"first_name\": \"<string>\",\n \"last_name\": \"<string>\",\n \"date_of_birth\": \"<string>\",\n \"phone_number\": \"<string>\",\n \"email\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/v1/patients/match-suggestion")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-API-Key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"external_id\": {\n \"type_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"value\": \"<string>\"\n },\n \"first_name\": \"<string>\",\n \"last_name\": \"<string>\",\n \"date_of_birth\": \"<string>\",\n \"phone_number\": \"<string>\",\n \"email\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"kind": "hard",
"reason": "external_id",
"patient": {
"id": "<string>",
"first_name": "<string>",
"last_name": "<string>",
"phone_number": "<string>",
"email": "<string>",
"day_of_birth": "2023-12-25",
"workflow_stage": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"title": "<string>",
"order": 123,
"description": "<string>"
},
"active": true
}
}{
"type": "validation_error",
"code": "invalid_parameter",
"message": "Field validation failed",
"param": "phone_number"
}Match Suggestion (no-write)
Run the patient matcher against caller-supplied identifiers and return the verdict. Never persists. The verdict’s kind tells the caller how to render its picker: hard (lock — external-id / name+DOB uniqueness), medium (pre-fill with override — phone/email + name heuristic), soft (pre-fill, confirm — a single same-name patient with no date of birth to confirm), or none. Used by the file detail page to lock or pre-fill its patient picker, and by future eligibility / prior-auth extraction surfaces. Identifiers are normalized with the same forgiving parsers the upsert endpoint uses, so callers can pass raw values from extracted document data.
curl --request POST \
--url https://api.example.com/v1/patients/match-suggestion \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"external_id": {
"type_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"value": "<string>"
},
"first_name": "<string>",
"last_name": "<string>",
"date_of_birth": "<string>",
"phone_number": "<string>",
"email": "<string>"
}
'import requests
url = "https://api.example.com/v1/patients/match-suggestion"
payload = {
"external_id": {
"type_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"value": "<string>"
},
"first_name": "<string>",
"last_name": "<string>",
"date_of_birth": "<string>",
"phone_number": "<string>",
"email": "<string>"
}
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
external_id: {type_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a', value: '<string>'},
first_name: '<string>',
last_name: '<string>',
date_of_birth: '<string>',
phone_number: '<string>',
email: '<string>'
})
};
fetch('https://api.example.com/v1/patients/match-suggestion', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.example.com/v1/patients/match-suggestion",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'external_id' => [
'type_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'value' => '<string>'
],
'first_name' => '<string>',
'last_name' => '<string>',
'date_of_birth' => '<string>',
'phone_number' => '<string>',
'email' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-API-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/v1/patients/match-suggestion"
payload := strings.NewReader("{\n \"external_id\": {\n \"type_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"value\": \"<string>\"\n },\n \"first_name\": \"<string>\",\n \"last_name\": \"<string>\",\n \"date_of_birth\": \"<string>\",\n \"phone_number\": \"<string>\",\n \"email\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-API-Key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.example.com/v1/patients/match-suggestion")
.header("X-API-Key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"external_id\": {\n \"type_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"value\": \"<string>\"\n },\n \"first_name\": \"<string>\",\n \"last_name\": \"<string>\",\n \"date_of_birth\": \"<string>\",\n \"phone_number\": \"<string>\",\n \"email\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/v1/patients/match-suggestion")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-API-Key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"external_id\": {\n \"type_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"value\": \"<string>\"\n },\n \"first_name\": \"<string>\",\n \"last_name\": \"<string>\",\n \"date_of_birth\": \"<string>\",\n \"phone_number\": \"<string>\",\n \"email\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"kind": "hard",
"reason": "external_id",
"patient": {
"id": "<string>",
"first_name": "<string>",
"last_name": "<string>",
"phone_number": "<string>",
"email": "<string>",
"day_of_birth": "2023-12-25",
"workflow_stage": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"title": "<string>",
"order": 123,
"description": "<string>"
},
"active": true
}
}{
"type": "validation_error",
"code": "invalid_parameter",
"message": "Field validation failed",
"param": "phone_number"
}Authorizations
Body
Identifiers the matcher will resolve to a patient.
Forgiving on the wire — same parse_*_safe normalizers the upsert
endpoint runs, so a partly-formatted phone or a free-text DOB still
matches. Pass raw values from extracted document data, form fields,
or eligibility payloads — the service normalizes before calling the
matcher. Empty/missing fields are skipped (matcher tiers gate on
presence, so unsupplied identifiers just narrow the tier set).
External-id pair. Tier 1 of the matcher when supplied.
Show child attributes
Show child attributes
DOB in any of: YYYY-MM-DD, YYYYMMDD, MM/DD/YYYY, MMDDYYYY, MM-DD-YYYY, MM/DD/YY. Unparseable values are ignored.
Response
Successful Response
Matcher verdict + optional slim patient. Never includes side-effect data.
How the caller should render the picker: hard = lock to the matched patient (DB-enforced uniqueness leaves exactly one valid choice); medium = pre-fill with override (contact-channel heuristic); soft = pre-fill with override (name-only suggestion, confirm before use); none = free.
hard, medium, soft, none Which matcher tier resolved the patient (external_id, demographics, phone_fuzzy_name, email_fuzzy_name, name_only). Null when kind is none.
external_id, demographics, phone_fuzzy_name, email_fuzzy_name The matched patient when kind is hard, medium, or soft; null otherwise.
Show child attributes
Show child attributes

