SautiDesk
SautiDesk API
Channels and templates

Set the web chat call button

PUT
/v1/desk/widget/voice

Sets the call button on the chat widget: whether it shows (enabled), the destination it rings, the queue_id and a short note shown beside it.

Requires: desk.admin scope, workspace owner or admin.

Authorization

bearerAuth
AuthorizationBearer <token>

A SautiDesk API key. An owner or admin makes it under Settings in SautiDesk for a named person and picks the scopes. The key is shown once. Send it as Authorization: Bearer <key>. It acts as that person and as nobody else.

In: header

Request Body

application/json

Response

OK

Example

{  "public_key": "example-value",  "enabled": false,  "allowed_origins": [    "https://example.com"  ],  "title": "Order 1182 has not arrived",  "greeting": "Thank you for calling. How can we help?",  "away_message": "We are away right now and will reply when we are back.",  "reply_time": "Usually within an hour",  "accent": "#1D4ED8",  "side": "example",  "theme": "light",  "identity_secret": "example-secret",  "identity_required": false,  "snippet": "Hi Amina, your order has shipped.",  "faces": [    "example"  ],  "names": [    "Amina Wanjiru"  ],  "lead": "example",  "voice": {    "enabled": false,    "queue_id": "c70c2d37-4d65-4ba4-9843-5e8aaf2dae40",    "queue_name": "Support",    "queue_ready": false,    "destination": "+254712345678",    "note": "Hi Amina, your order has shipped.",    "available": false,    "status": "open",    "message": "Hi Amina, your order has shipped.",    "needs_number": false  }}
FieldTypeDescription
public_keyrequiredstring
enabledrequiredbooleanTrue to switch it on, false to switch it off.
allowed_originsrequiredstring[]The websites allowed to show the chat widget, for example https://shop.example.co.ke. Leave empty to allow none.
titlerequiredstringA short title.
greetingrequiredstringThe words read to the caller or shown to the visitor first.
away_messagerequiredstringWhat the widget tells visitors when nobody is available.
reply_timerequiredstringWhat the widget tells visitors to expect, for example Usually within an hour.
accentrequiredstringThe colour of the chat button and header, as a hex code such as #4A44C6.
siderequiredstringWhich side of the page the chat button sits on: left or right.
themerequiredstringThe look of the widget: system, light or dark.
identity_secretrequiredstring
identity_requiredrequiredbooleanTrue to require visitors to prove who they are before chatting.
snippetrequiredstring
facesrequiredstring[]
namesrequiredstring[]
leadrequiredstring
voicerequiredobject
enabledrequiredbooleanTrue to switch it on, false to switch it off.
queue_idrequiredstring (uuid) | nullThe id of the queue that receives what arrives here.
queue_namerequiredstring
queue_readyrequiredboolean
destinationrequiredstringThe phone number the widget's call button rings.
noterequiredstringA note.
availablerequiredboolean
statusrequiredstringThe status to set.
messagestringA short note for the person receiving the ticket.
needs_numberrequiredboolean
curl -X PUT "https://api.sautidesk.com/v1/desk/widget/voice" \  -H "Content-Type: application/json" \  -d '{    "enabled": false,    "queue_id": "c70c2d37-4d65-4ba4-9843-5e8aaf2dae40",    "destination": "+254712345678",    "note": "Hi Amina, your order has shipped."  }'