Skip to content
vocapable.Docs

Narrow your company's calling window (owner only)

PUT
/v1/mobile/workspace/calling-policy
curl --request PUT \
--url https://api.vocapable.com/v1/mobile/workspace/calling-policy \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "window_start_local": "example", "window_end_local": "example", "expected_revision": 1 }'
Media typeapplication/json
WorkspaceCallingPolicyUpdate

A narrower window. Anything outside the product default is refused, not clamped.

object
window_start_local
required
Window Start Local
string format: time
window_end_local
required
Window End Local
string format: time
expected_revision
required
Expected Revision
integer
Examplegenerated
{
"window_start_local": "example",
"window_end_local": "example",
"expected_revision": 1
}

Successful Response

Media typeapplication/json
WorkspaceCallingPolicy

The company’s calling window and the rules layered on it.

window_*_local is what binds before any state rule: the owner’s window when one is set (owner_set), else the product default. revision is 0 until the owner saves one; send it back as expected_revision.

object
window_start_local
required
Window Start Local
string format: time
window_end_local
required
Window End Local
string format: time
default_window_start_local
required
Default Window Start Local
string format: time
default_window_end_local
required
Default Window End Local
string format: time
owner_set
required
Owner Set
boolean
revision
required
Revision
integer
updated_at
required
Any of:
string format: date-time
updated_by
required
Any of:
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
can_edit
required
Can Edit
boolean
rules_version
required
Rules Version
string
default_citation
required
Default Citation
string
state_rules
required
State Rules
Array<object>
WorkspaceStateCallingRule

One state’s encoded rule, with the primary source it came from.

object
jurisdiction
required
Jurisdiction
string
channels
required
Channels
Array<string>
Allowed values: voice sms
window_start_local
required
Window Start Local
string format: time
window_end_local
required
Window End Local
string format: time
sunday_window_start_local
required
Any of:
string format: time
sunday_window_end_local
required
Any of:
string format: time
frequency_cap
required
Any of:
integer
frequency_cap_period_hours
required
Any of:
integer
citation
required
Citation
string
effective_from
required
Effective From
string format: date
notes
required
Notes
string
Example
{
"state_rules": [
{
"channels": [
"voice"
]
}
]
}

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": {}
}
]
}