Skip to content
vocapable.Docs

Set a teammate's default line, how they are rung, or their working hours

PUT
/v1/workspace/team/calling/{user_id}
curl --request PUT \
--url https://api.vocapable.com/v1/workspace/team/calling/example \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "expected_revision": 1, "default_line_id": "example", "ring_preference": "app_then_phone", "working_hours": { "timezone": "example", "days": { "additionalProperty": [ { "start": "example", "end": "example" } ] }, "time_off": [ { "start": "2026-04-15", "end": "2026-04-15", "label": "example" } ] } }'
user_id
required
User Id
string
Media typeapplication/json
WorkspaceTeammateCallingUpdate

An owner or manager sets one teammate’s default line (null clears it), how they are rung, or their working hours (null removes them). Fields left out are kept; at least one must be sent.

object
expected_revision
required
Expected Revision
integer
>= 1
default_line_id
Any of:
string
>= 1 characters <= 64 characters
ring_preference
Any of:
string
Allowed values: app_then_phone phone_only app_only
working_hours
Any of:
WorkspaceWorkingHours

The person’s own weekly hours. A day that is absent or empty is not worked. time_off lists date ranges off (at most 24, each at most a year); past ranges may stay and simply no longer match.

object
timezone
required
Timezone
string
>= 1 characters <= 64 characters
days
Days
object
key
additional properties
Array<object>
WorkspaceWorkingWindow

One span of a working day, local to the hours’ timezone. 24:00 ends at midnight; a shift across midnight is two windows.

object
start
required
Start
string
/^([01]\d|2[0-3]):[0-5]\d$/
end
required
End
string
/^(([01]\d|2[0-3]):[0-5]\d|24:00)$/
time_off
Time Off
Array<object>
<= 24 items
WorkspaceTimeOff

Whole days off - a holiday, leave (PRD E11-R2). Local dates in the hours’ timezone, both inclusive; on these days the person is never rung, whatever the weekly hours say.

object
start
required
Start
string format: date
end
required
End
string format: date
label
Any of:
string
>= 1 characters <= 80 characters

Successful Response

Media typeapplication/json
WorkspaceTeammateCalling
object
user
required
WorkspacePersonRef

A teammate named on a record: the id the server holds and the name to show.

object
user_id
required
User Id
string
name
required
Name
string
role
required
Role
string
Allowed values: owner manager rep
default_line_id
required
Any of:
string
permitted_line_ids
required
Permitted Line Ids
Array<string>
revision
required
Revision
integer
ring_preference
Ring Preference
string
default: app_then_phone
Allowed values: app_then_phone phone_only app_only
working_hours
Any of:
WorkspaceWorkingHours

The person’s own weekly hours. A day that is absent or empty is not worked. time_off lists date ranges off (at most 24, each at most a year); past ranges may stay and simply no longer match.

object
timezone
required
Timezone
string
>= 1 characters <= 64 characters
days
Days
object
key
additional properties
Array<object>
WorkspaceWorkingWindow

One span of a working day, local to the hours’ timezone. 24:00 ends at midnight; a shift across midnight is two windows.

object
start
required
Start
string
/^([01]\d|2[0-3]):[0-5]\d$/
end
required
End
string
/^(([01]\d|2[0-3]):[0-5]\d|24:00)$/
time_off
Time Off
Array<object>
<= 24 items
WorkspaceTimeOff

Whole days off - a holiday, leave (PRD E11-R2). Local dates in the hours’ timezone, both inclusive; on these days the person is never rung, whatever the weekly hours say.

object
start
required
Start
string format: date
end
required
End
string format: date
label
Any of:
string
>= 1 characters <= 80 characters
availability
Any of:
WorkspaceAvailability

What the dispatcher, the receptionist’s transfer and the team page all read.

object
state
required
State
string
Allowed values: available away offline do_not_disturb off_hours after_call_work
presence_state
required
Any of:
string
Allowed values: available away offline
presence_until
required
Any of:
string format: date-time
dnd_until
required
Any of:
string format: date-time
in_working_hours
required
Any of:
boolean
changes_at
required
Any of:
string format: date-time
time_off_until
Any of:
string format: date-time
ring_preference
required
Ring Preference
string
Allowed values: app_then_phone phone_only app_only
app_ready
required
App Ready
boolean
phone_ready
required
Phone Ready
boolean
rings_app
required
Rings App
boolean
rings_phone
required
Rings Phone
boolean
Example
{
"role": "owner",
"ring_preference": "app_then_phone",
"availability": {
"state": "available",
"presence_state": "available",
"ring_preference": "app_then_phone"
}
}

Validation Error

Media typeapplication/json
HTTPValidationError
object
detail
Detail
Array<object>
ValidationError
object
loc
required
Location
Array
msg
required
Message
string
type
required
Error Type
string
input
Input
ctx
Context
object
Examplegenerated
{
"detail": [
{
"loc": [
"example"
],
"msg": "example",
"type": "example",
"input": "example",
"ctx": {}
}
]
}