---
title: "Update a patient"
method: PATCH
path: "/workspaces/{workspaceId}/patients/{patientId}"
tags: ["patients"]
---

# Update a patient

`PATCH /workspaces/{workspaceId}/patients/{patientId}`

## Request

- Base URL: `https://vetnio.com/api/v2`
- URL: `https://vetnio.com/api/v2/workspaces/{workspaceId}/patients/{patientId}`
- Auth: HTTP bearer

Updates the fields present in the body and leaves omitted fields unchanged. Fields cannot be set to `null`; send an empty string to blank a text field (not `dateOfBirth`, where an empty or invalid value fails with `500`). The owner cannot be changed here. Repeating the same request leaves the same data, but `updatedAt` is refreshed on every call. Returns `404` when the patient does not exist in the workspace. Patients synced from a practice-management system can be overwritten by the next sync.

## Path parameters

- `workspaceId` string, required: Identifier of the workspace (clinic) that owns the patients and clients. The caller must be a member of it; patients and clients are shared by all members of the workspace.
- `patientId` string, required: Patient id (UUID) in this workspace. Unknown ids and ids from other workspaces return `404`.

## Request body

- object
  - `name` string: New value for the name. The animal's name. Free text; Vetnio does not enforce uniqueness.
  - `species` string: New value for the species. Species, free text. The Vetnio web app stores the English species name, followed by ` - <breed>` when a breed is chosen (for example `Dog` or `Dog - Labrador Retriever`); patients synced from a practice-management system may use that system's values.
  - `breed` string: New value for the breed. Breed, free text.
  - `dateOfBirth` string: New date of birth. Date of birth as an ISO-8601 calendar date (`YYYY-MM-DD`). Stored as a date, so other formats are rejected by the database.
  - `gender` string: New value for sex and neuter status. Sex and neuter status, free text. The Vetnio web app uses `Male`, `Female`, `Male Neutered` and `Female Neutered`; use the same values so the patient list's gender filter and the UI stay consistent.
  - `weight` string: New weight. Body weight as free text including the unit, as the web app writes it (for example `24.5 kg`). Not parsed or converted.
  - `identifier` string: New identifier. The animal's identifier, typically a microchip (transponder) number, but it can be a tattoo, registration number or practice-management-system id. Free text, not unique; matched by the patient list search.
  - `insurance` string: New insurance company. Name of the animal's insurance company, free text.

## Response `200`

Confirmation that the patient was updated.

- PatientSuccess: Acknowledgement returned by patient and client mutations that have no resource body.
  - `success` boolean, required: Always `true`; failures are returned as errors.

## Other responses

- `400`: Invalid input data
- `401`: Authorization not provided
- `403`: Insufficient access
- `404`: Not found
- `500`: Internal server error

---

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