Skip to main content
PATCH
Update session by id

Update Session

Partially update a single session (appointment) by its public id, scoped to the organization that owns the API key. All referenced entities (staff, client, clinician, location, provider location, non-billable code, service lines) must belong to that organization.

Headers

Merge-then-validate

A PATCH is a partial update. Every field you send is overlaid on the stored session, and the resulting merged state is validated with the exact same rules as create. A PATCH can therefore never leave a session in a shape that create would reject.
  • Omit a field to leave it unchanged.
  • Send null for a nullable reference (clientId, clinicianId, providerLocationId, nonBillableCodeId) to clear it.
  • services replaces the current service. Send null to make the session non-billable — you must then also provide nonBillableCodeId.
Because the merged state is validated as a whole, the billable/non-billable rules still apply after the merge:
  • Billable (merged state has services): clientId and clinicianId must be present, and it is mutually exclusive with nonBillableCodeId.
  • Non-billable (merged state has nonBillableCodeId): mutually exclusive with services; supervision requires clinicianId, while a standard (non-supervision) non-billable session must not have a clinicianId.
  • Telehealth: allowed only on billable sessions and requires providerLocationId.

Frozen sessions

A session that already has recorded clinical work cannot be edited (nor deleted), mirroring the calendar. Any of the following freezes the session and makes a PATCH return 400:
  • a non-archived encounter,
  • a non-archived note (activity),
  • a completed cancellation.
Cancellations still mid-workflow (pending, searching, etc.) do not freeze the session.

Time fields

To change the time, send date, startTime, endTime and timezone together. Sending only some of them is rejected with 400 (To change the time, provide date, startTime, endTime and timezone together.). When all four are provided, they are combined into UTC instants:
  • dateYYYY-MM-DD, a real calendar date.
  • startTime / endTimeHH:mm or HH:mm:ss. endTime must be after startTime, and the total duration must not exceed 8 hours.
  • timezone — IANA zone (for example America/New_York).

Session status

status changes the scheduling status of the session.
  • Allowed values: CONFIRMED, UNCONFIRMED, DECLINED, PATIENT_NO_SHOW, REQUESTED_TO_CANCEL.
  • Omit status to leave the stored value unchanged, so a patch of unrelated fields never re-confirms a session that was declined or marked a no-show. Unlike create, there is no default on update.
  • Values are matched exactly (uppercase). Any other value returns a 400.
  • The response includes the session’s current status after the update.

Success Response (200)

Returns the updated session in the same discriminated shape as create and get — billable sessions expose isBillable: true, isTelehealth, clinicianId, providerLocationId and services; non-billable sessions expose isBillable: false and nonBillableCode instead.

Error Responses

400 - Bad Request

Returned when the session is frozen (it has a non-archived encounter, a non-archived note, or a completed cancellation), when the merged state violates a validation rule (billable/non-billable requirements, telehealth without a provider location, endTime not after startTime, total duration over 8 hours compared at second precision, an invalid calendar date, place of service not allowed by a service line, a technicianId whose role cannot deliver a session, a clientId that is not a patient, a clinicianId that is not a clinical role, or a technician on a non-technician service line), or when a referenced entity does not exist in the organization. Business-rule rejections — a frozen session, or a merged state that violates a billable/non-billable, telehealth, time, place-of-service, staff-role or referenced-entity rule — are returned as a plain error (no validation list):
Malformed field input caught before the business rules (bad enum, empty string, invalid date pattern, a partial time change, a non-nullable field sent as null) is returned as a validation list instead (each path is an array of segments):

401 - Unauthorized

403 - Forbidden

404 - Not Found

Examples

Reschedule a session (cURL)

Convert a billable session to non-billable (cURL)

JavaScript Example

Authorizations

Authorization
string
header
required

API key authentication. Include your API key in the Authorization header as 'Bearer '

Path Parameters

sessionId
string
required

Session public identifier

Minimum string length: 1

Body

application/json

Partial update for a single session. Any subset of fields may be sent; each is overlaid on the stored session and the MERGED final state is validated with the exact same rules as create, so a PATCH can never leave a session in a shape create would reject. Nullable reference fields (clientId, clinicianId, providerLocationId, nonBillableCodeId) accept null to clear the reference; omit a field to leave it unchanged. Time changes require date, startTime, endTime and timezone together.

technicianId
string

Public id of the staff member delivering the session. Must be a staff role (TECHNICIAN, CLINICIAN, CLINICAL_ADMIN or CLINICAL_SUPERADMIN). A TECHNICIAN can only be assigned to technician-only service lines.

Minimum string length: 1
Example:

"usr_tech123"

clientId
string | null

Public id of the client. Must reference a patient. Send null to clear. Required on the merged state when the session is billable.

Minimum string length: 1
Example:

"usr_client789"

clinicianId
string | null

Public id of the clinician. Must reference a clinician or clinical admin. Send null to clear. Required on the merged state for billable sessions and for non-billable supervision sessions.

Minimum string length: 1
Example:

"usr_clin456"

date
string

Calendar date (YYYY-MM-DD). Must be a real calendar date. Provide together with startTime, endTime and timezone to change the time.

Pattern: ^\d{4}-\d{2}-\d{2}$
Example:

"2026-01-05"

startTime
string

Wall-clock start time (HH:mm or HH:mm:ss). Only applied when date, startTime, endTime and timezone are all sent together.

Pattern: ^([01]\d|2[0-3]):[0-5]\d(:[0-5]\d)?$
Example:

"09:00"

endTime
string

Wall-clock end time (HH:mm or HH:mm:ss). Must be after startTime, and the total duration must not exceed 8 hours.

Pattern: ^([01]\d|2[0-3]):[0-5]\d(:[0-5]\d)?$
Example:

"10:00"

timezone
string

IANA timezone used to interpret date/startTime/endTime.

Minimum string length: 1
Example:

"America/New_York"

locationId
string

Public id of the session location.

Minimum string length: 1
Example:

"loc_1a2b3c"

providerLocationId
string | null

Public id of the location the provider delivers from. Send null to clear. Required on the merged state when isTelehealth is true.

Minimum string length: 1
Example:

"loc_9x8y7z"

services
string | null

Public id of the billable service line. Replaces the current service. Send null to clear it (making the merged session non-billable, which then requires nonBillableCodeId); omit to leave it unchanged.

Minimum string length: 1
Example:

"svc_1a2b3c"

nonBillableCodeId
string | null

Public id of the non-billable code. Send null to clear. Mutually exclusive with a billable (services) merged state.

Minimum string length: 1
Example:

"nbc_1a2b3c"

placeOfService
enum<string>

CMS place-of-service classification for the session

Available options:
TELEHEALTH_PROVIDED_ELSEWHERE,
TELEHEALTH_PROVIDED_IN_PATIENT_HOME,
OFFICE,
HOME,
SCHOOL,
OTHER,
TEMPORARY_LODGING,
PLACE_OF_EMPLOYMENT,
COMMUNITY_MENTAL_HEALTH_CENTER
isTelehealth
boolean

Whether the session is delivered via telehealth. Only allowed on billable sessions and requires providerLocationId on the merged state.

isSupervision
boolean

Whether the session is a supervision session. For non-billable supervision, clinicianId is required on the merged state.

isClientPresent
boolean

Whether the client is present for the session.

title
string

Custom title. When provided, replaces the stored title.

Minimum string length: 1
status
enum<string>

New scheduling status for the session. Omit to leave the stored status unchanged, so a patch of unrelated fields never re-confirms a session that was declined or marked a no-show. Matched exactly (uppercase); any other value returns a 400.

Available options:
CONFIRMED,
UNCONFIRMED,
DECLINED,
PATIENT_NO_SHOW,
REQUESTED_TO_CANCEL

Response

Session updated

A scheduled session (appointment). The shape depends on isBillable: billable sessions expose isTelehealth, clinicianId and services; non-billable sessions expose nonBillableCode instead.

publicId
string
required
Example:

"apt_1a2b3c4d5e"

title
string
required
Example:

"John Doe — Adaptive behavior treatment"

status
enum<string>
required

Scheduling status of the session. Matched exactly (uppercase); any other value returns a 400.

Available options:
CONFIRMED,
UNCONFIRMED,
DECLINED,
PATIENT_NO_SHOW,
REQUESTED_TO_CANCEL
startTime
string<date-time>
required

Session start instant in UTC (ISO-8601).

Example:

"2026-01-05T14:00:00.000Z"

endTime
string<date-time>
required

Session end instant in UTC (ISO-8601).

Example:

"2026-01-05T15:00:00.000Z"

isSupervision
boolean
required
Example:

false

isClientPresent
boolean
required
Example:

true

placeOfService
enum<string>
required

CMS place-of-service classification for the session

Available options:
TELEHEALTH_PROVIDED_ELSEWHERE,
TELEHEALTH_PROVIDED_IN_PATIENT_HOME,
OFFICE,
HOME,
SCHOOL,
OTHER,
TEMPORARY_LODGING,
PLACE_OF_EMPLOYMENT,
COMMUNITY_MENTAL_HEALTH_CENTER
locationId
string
required

Public id of the session location.

Example:

"loc_1a2b3c"

technicianId
string | null
required

Public id of the assigned technician, if any.

Example:

"usr_tech123"

clientId
string | null
required

Public id of the client, if any.

Example:

"usr_client789"

isBillable
enum<boolean>
required

Always true for billable sessions.

Available options:
true
isTelehealth
boolean
required
Example:

false

clinicianId
string | null
required

Public id of the assigned clinician, if any.

Example:

"usr_clin456"

providerLocationId
string | null
required

Public id of the provider location the care was delivered from, if any.

Example:

"loc_9f8e7d"

services
string
required

Public id of the billable service line rendered. A session bills exactly one service line.

Example:

"svc_1a2b3c"