# Create a patient

Canonical page: https://docs.ovok.com/signals/tutorial/create-patient

<Effort complexity={1} clients="Any HTTP client" time="5 minutes" />

Signals judges readings per patient, so create one before you post a reading. You do it with the **Manager** app from [Get started](/signals/standalone/get-started).

```bash title=".env"
OVOK_MANAGER_ID=…
OVOK_MANAGER_SECRET=…
```

## Set a band and turn on episodes [Terminal] [#set-a-band-and-turn-on-episodes-terminal]

A new tenant has no heart-rate band, so nothing alerts yet. Set one for every patient, and turn on episodes so related breaches are grouped into one event.

```bash
curl --request PATCH 'https://api.sandbox.ovok.com/v1/signals/api/tenant' \
  --user "${OVOK_MANAGER_ID}:${OVOK_MANAGER_SECRET}" \
  --header 'Content-Type: application/json' \
  --data '{"orgSettings":{"bands":{"8867-4":{"low":40,"high":110}}},"settings":{"episodicAlerts":true}}'
```

- `orgSettings.bands` keys a band by LOINC code; `8867-4` is heart rate. See [Update tenant settings](/api/signals-api---tenants/update-tenant-settings).

## Create the patient [Terminal] [#create-the-patient-terminal]

Name the patient with your own id, `refId`. Creating the same `refId` again updates it.

```bash
curl --request POST 'https://api.sandbox.ovok.com/v1/signals/api/patient' \
  --user "${OVOK_MANAGER_ID}:${OVOK_MANAGER_SECRET}" \
  --header 'Content-Type: application/json' \
  --data '{"patients":[{"refId":"resident-001","name":"Resident 001"}]}'
```

The answer lists the patients as stored. The full contract is [Create patients](/api/signals-api---patients/create-patients).

## Try it here [Client-side] [#try-it-here-client-side]

Pick the sandbox server, choose **Basic** authentication, and enter your Manager id and secret. Send the request to create `resident-001`.

<ApiOperation url="/api/signals-api---patients/create-patients" />

## Verify your integration [#verify-your-integration]

The answer is `200` and holds `resident-001`. If it isn't:

1. `401`: the id or secret is wrong, or is not a Manager app.
2. `403`: the app lacks `signals_patients:update`. See [app types](/signals/standalone#app-types).

## Next [#next]

[Send a reading](/signals/tutorial/send-observation) posts a heart rate above the band.
