Update Provider Schedule
Updates a shift and returns the updated record.
Endpoint
PATCH /v2/providers/{provider_id}/schedules/{schedule_id}
Path Parameters
| Parameter |
Type |
Required |
Description |
provider_id |
string |
Yes |
The treating provider. |
schedule_id |
string |
Yes |
|
Request Body
| Parameter |
Type |
Required |
Description |
clinic_id |
string |
No |
The clinic this record belongs to. |
start_date |
string (date) |
No |
YYYY-MM-DD. |
end_date |
string (date) |
No |
YYYY-MM-DD. |
start_time |
string |
No |
Clock time, 24-hour HH:MM. |
end_time |
string |
No |
Clock time, 24-hour HH:MM. |
recurrence |
object |
No |
Recurrence rule. null for a one-off. See Recurrence. |
Recurrence
| Parameter |
Type |
Required |
Description |
frequency |
string |
Yes |
How often the pattern repeats. One of DAILY, WEEKLY, MONTHLY. |
interval |
integer |
Yes |
Repeat every N periods of frequency. |
days_of_week |
array of string |
Yes |
Any of MONDAY, TUESDAY, WEDNESDAY, THURSDAY, FRIDAY, SATURDAY, SUNDAY. |
Request
curl --location '{base_url}/v2/providers/2094/schedules/schedule_id' \
--request PATCH \
--header 'Authorization: Bearer JWT_TOKEN' \
--header 'Content-Type: application/merge-patch+json' \
--data '{
"clinic_id": "5831",
"start_date": "2026-09-01",
"end_date": "2026-12-31",
"start_time": "08:00",
"end_time": "17:00",
"recurrence": {
"frequency": "WEEKLY",
"interval": 1,
"days_of_week": [
"MONDAY",
"TUESDAY"
]
}
}'
Response
Success Response
Code: 200 OK
{
"id": "6642",
"provider_id": "2094",
"clinic_id": "5831",
"start_date": "2026-09-01",
"end_date": "2026-12-31",
"start_time": "08:00",
"end_time": "17:00",
"recurrence": {
"frequency": "WEEKLY",
"interval": 1,
"days_of_week": [
"MONDAY",
"TUESDAY"
]
},
"created_at": "2026-08-27T14:30:00Z",
"updated_at": "2026-08-27T14:30:00Z"
}
Response Fields
| Field |
Type |
Description |
id |
string |
The schedule or block id. |
provider_id |
string |
The treating provider. |
clinic_id |
string |
The clinic this record belongs to. |
start_date |
string (date) or null |
YYYY-MM-DD. |
end_date |
string (date) or null |
YYYY-MM-DD. |
start_time |
string |
Clock time, 24-hour HH:MM. |
end_time |
string |
Clock time, 24-hour HH:MM. |
recurrence |
object or null |
Recurrence rule. null for a one-off. See Recurrence. |
created_at |
string (date-time) or null |
|
updated_at |
string (date-time) or null |
|
Recurrence
| Field |
Type |
Description |
frequency |
string |
How often the pattern repeats. One of DAILY, WEEKLY, MONTHLY. |
interval |
integer |
Repeat every N periods of frequency. |
days_of_week |
array of string |
Any of MONDAY, TUESDAY, WEDNESDAY, THURSDAY, FRIDAY, SATURDAY, SUNDAY. |
Error Response
Code: 400 Bad Request
{
"code": "bad_request",
"message": "Validation failed",
"errors": [
{
"field": "patient_id",
"message": "must be a string"
}
]
}
Every error has the same shape — a machine-readable code, a message, and an errors[] array that's empty when there's nothing field-specific to report. The HTTP status is authoritative.
| Status |
code |
Meaning |
400 Bad Request |
bad_request |
The request body or parameters failed validation. errors[] names the offending fields. |
401 Unauthorized |
unauthorized |
The access token is missing, malformed or expired. |
403 Forbidden |
forbidden |
The request references a resource outside the token's organisation or clinic scope. |
404 Not Found |
not_found |
No such resource, or it's outside your scope. |
429 Too Many Requests |
rate_limited |
Rate limit exceeded. Back off and retry. |
500 Internal Server Error |
internal_error |
Unexpected server error. |
502 Bad Gateway |
upstream_error |
Upstream service failed or timed out. |
Notes
PATCH is a JSON Merge Patch (RFC 7386): an omitted field is left alone, an explicit null clears it, and an array replaces the existing one wholesale.