Api referenceApiOperationsSlimThresholdSlim/Threshold/Patient
Update patient threshold
- Sandbox: available
- Staging: available
- Production: unknown
PUT
Saves one resident's own thresholds.
Deprecated. Use
PUT /v2/slim/threshold/patient/{patientId}. This v1 route stays available, unchanged, until every client has moved.
Auth: Bearer token. The caller must be a practitioner, an admin, a super admin, or hold the "System Owner" access policy. The access policy must grant Goal:update (an admin or super admin who holds no access policy skips this check).
Scope: The resident must be in the caller's project (from the token) or one of its sub-projects.
Behaviour
- Each metric's
modedecides what is stored:patient: yourabsolute/relativelimits.organization: the home's limits. Sendingenabled: falsefor a metric the home has enabled switches it topatientmode, disabled.
patient-autois no longer accepted: a body that uses it is refused with 422.patientIdin the body is required but ignored; the path decides the resident.averageandaverageRangeare set by the server; values you send are ignored.- Enabling a relative heart-rate or respiratory-rate band for a resident with no baseline average answers 424, because the band would have nothing to be relative to.
- Every limit is evaluated by Signals, so every save writes the resident's settings to Signals before it answers, all or nothing: Signals holds the saved limits once it answers, or it answers 502 with
saved: falseand nothing is changed (a 500 says putting the previous limits back failed too). Send the save again. - Change-history entries are written for each changed metric.
- The response is the saved threshold.
Example
curl -X PUT 'https://api.sandbox.ovok.com/v1/slim/threshold/patient/c3499c27-2973-0a7f-807e-fb8676a92dcb' \ -H 'Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpYXQiOjE3NjcyNjg4MDAsImV4cCI6MTc2NzI3MjQwMH0.Ql3B_ztDvctlyZ2z0vp4sl3ExXRQGkzmxdmTAqxNzZk' \ -H 'Content-Type: application/json' \ -d '{ "patientId": "c3499c27-2973-0a7f-807e-fb8676a92dcb", "status": "active", "settings": { "heartRate": { "mode": "patient", "enabled": true, "absolute": { "enabled": true, "min": 45, "max": 110 } } } }'bearerheader
AuthorizationBearer <JWT>patientId*stringapplication/json- body
id?stringpatientId*stringprojectId?stringstatus*stringValue in
"active""revoked"date?stringFormat
date-timesettings*Patient threshold updated successfully.
application/json- response
id?stringpatientId*stringprojectId?stringstatus*stringValue in
"active""revoked"date?stringFormat
date-timeperiod?settings*curl -X PUT 'https://api.sandbox.ovok.com/v1/slim/threshold/patient/string' \ -H 'Content-Type: application/json' \ -d '{ "patientId": "string", "status": "active", "settings": {}}'Example Response
{ "id": "string", "patientId": "string", "projectId": "string", "status": "active", "date": "2019-08-24T14:15:22Z", "period": { "start": "2019-08-24T14:15:22Z", "end": "2019-08-24T14:15:22Z" }, "settings": { "heartRate": { "period": { "start": "19:00:00", "end": "09:00:00" }, "average": 0, "averageRange": { "min": 0, "max": 0 }, "mode": "organization", "enabled": true, "absolute": { "enabled": true, "min": 0, "max": 1000 } }, "meanHeartRate": { "period": { "start": "19:00:00", "end": "09:00:00" }, "average": 0, "averageRange": { "min": 0, "max": 0 }, "mode": "organization", "enabled": true, "relative": { "enabled": true, "min": 0, "max": 1000 } }, "respiratoryRate": { "period": { "start": "19:00:00", "end": "09:00:00" }, "average": 0, "averageRange": { "min": 0, "max": 0 }, "mode": "organization", "enabled": true, "absolute": { "enabled": true, "min": 0, "max": 1000 } }, "meanRespiratoryRate": { "period": { "start": "19:00:00", "end": "09:00:00" }, "average": 0, "averageRange": { "min": 0, "max": 0 }, "mode": "organization", "enabled": true, "relative": { "enabled": true, "min": 0, "max": 1000 } }, "durationOfOutOfBed": { "period": { "start": "19:00:00", "end": "09:00:00" }, "average": 0, "averageRange": { "min": 0, "max": 0 }, "mode": "organization", "enabled": true, "absolute": { "enabled": true, "max": 1000000 }, "relative": { "enabled": true, "max": 100 } }, "sleepDuration": { "period": { "start": "19:00:00", "end": "09:00:00" }, "average": 0, "averageRange": { "min": 0, "max": 0 }, "mode": "organization", "enabled": true, "absolute": { "enabled": true, "min": 0, "max": 1000 } }, "numberOfTimesGettingOutOfBed": { "period": { "start": "19:00:00", "end": "09:00:00" }, "average": 0, "averageRange": { "min": 0, "max": 0 }, "mode": "organization", "enabled": true, "absolute": { "enabled": true, "max": 1000 } }, "oxygenSaturation": { "period": { "start": "19:00:00", "end": "09:00:00" }, "average": 0, "averageRange": { "min": 0, "max": 0 }, "mode": "organization", "enabled": true, "absolute": { "enabled": true, "min": 0, "max": 0 } }, "pulseRate": { "period": { "start": "19:00:00", "end": "09:00:00" }, "average": 0, "averageRange": { "min": 0, "max": 0 }, "mode": "organization", "enabled": true, "absolute": { "enabled": true, "min": 0, "max": 0 } }, "perfusionIndex": { "period": { "start": "19:00:00", "end": "09:00:00" }, "average": 0, "averageRange": { "min": 0, "max": 0 }, "mode": "organization", "enabled": true, "absolute": { "enabled": true, "min": 0, "max": 0 } }, "bodyTemperature": { "period": { "start": "19:00:00", "end": "09:00:00" }, "average": 0, "averageRange": { "min": 0, "max": 0 }, "mode": "organization", "enabled": true, "absolute": { "enabled": true, "min": 0, "max": 0 } } }}