Client events
client.activity
Change AFK (away from keyboard) status
afk
- Is away from keyboard
{
"confirm_id": "75a406625c58",
"event": "client.activity",
"params": {
"afk": "BOOL"
}
}
client.call.buzzcancel
Call buzzing cancelled
jid
- Chat or contact id
{
"confirm_id": "8c52201ff7ed",
"event": "client.call.buzzcancel",
"params": {
"jid": "JID"
}
}
client.call.leave
Leave call
jid
- Chat or contact idreason
- Reason, if any
{
"confirm_id": "f5b6d29013c3",
"event": "client.call.leave",
"params": {
"jid": "JID",
"reason": "STRING"
}
}
client.call.muteall
Mute all other call participants
jid
- Chat or contact id
MISSING EXAMPLE
client.call.offer
Start a call
jid
- Chat or contact idmuted
- Mute statesdp
- SDP (session description protocol) datatrickle
- Is trickle mode enabled
{
"confirm_id": "b45fdc034116",
"event": "client.call.offer",
"params": {
"jid": "JID",
"muted": "BOOL",
"sdp": "STRING",
"trickle": "BOOL"
}
}
client.call.reject
Reject the call
jid
- Chat or contact idreason
- Reason, if any
{
"confirm_id": "55e8cc25d534",
"event": "client.call.reject",
"params": {
"jid": "JID"
}
}
client.call.sdp
For exchange Session Description with server when client’s Local Session Description is changed
jid
- Chat or contact idjsep
- SDP datauid
- Call id
MISSING EXAMPLE
client.call.sound
Change mute state in call
jid
- Chat or contact idmuted
- Mute state
{
"confirm_id": "4a24b770a659",
"event": "client.call.sound",
"params": {
"jid": "JID",
"muted": "BOOL"
}
}
client.call.trickle
Send trickle candidate for webrtc connection
candidate
- Trickle candidatejid
- Chat or contact idsdp_mid
- SDP midsdp_mline_index
- SDP index
{
"confirm_id": "5bde78b37316",
"event": "client.call.trickle",
"params": {
"candidate": "STRING",
"jid": "JID",
"sdp_mid": "STRING",
"sdp_mline_index": "INT"
}
}
client.chat.composing
Typing or recording audiomessage
composing
- true = start typing / audio recording, false = stopdraft
- Message draft datais_audio
- true = audiomessage, false = text typingjid
- Chat or contact id
{
"confirm_id": "2bd5afaf39af",
"event": "client.chat.composing",
"params": {
"jid": "JID"
}
}
client.chat.lastread
Last read message in chat changed
jid
- Chat or contact idlast_read_message_id
- Last read message id. Omitted = last message in chat
{
"confirm_id": "8561d892f3d8",
"event": "client.chat.lastread",
"params": {
"jid": "JID",
"last_read_message_id": "STRING"
}
}
client.confirm
Client confirmed server message
confirm_id
- Unique identifier generated by client
{
"event": "client.confirm",
"params": {
"confirm_id": "str"
}
}
client.message.deleted
Message deleted
message_id
- Message id
{
"confirm_id": "cd778785149a",
"event": "client.message.deleted",
"params": {
"message_id": "STRING"
}
}
client.message.updated
Message created or changed
comment
- Deprecatedcontent
- Message content. Requiredimportant
- Important flag. Not required. Default: falselinked_messages
- Forwarded messages (previously was for reply too). Not requiredmessage_id
- Uid created by client. Recommendednopreview
- Disable links preview generation. Not required. Default: falseold_style_attachment
- Backward compatibility modereply_to
- Replied to message id. Not requiredto
- Chat, task or contact jid. Requireduploads
- Message attachments
{
"confirm_id": "2694a2864526",
"event": "client.message.updated",
"params": {
"comment": "STRING",
"content": {
"text": "...",
"type": "plain"
},
"important": "BOOL",
"linked_messages": [
"STRING"
],
"message_id": "STRING",
"nopreview": "BOOL",
"to": "JID"
}
}
client.ping
Empty message for checking server connection
{
"confirm_id": "8aad294579b8",
"event": "client.ping"
}
Server events
server.call.answer
Call parameters (deprecated: use ServerCallSdp)
candidates
- List of ICE candidates (when trickle = false)jid
- Chat or contact idjsep
- SDP dataonliners
- Current call participantsuid
- Call id
{
"event": "server.call.answer",
"params": {
"candidates": [
{
"candidate": "candidate:2 1 tcp 1019216383 95.213.181.86 0 typ host tcptype active",
"sdpMLineIndex": 0
}
],
"jid": "g-3f7e2a85-49f5-4586-8229-d9c52813dcb2",
"jsep": {
"sdp": ".....SDP....",
"type": "answer"
},
"onliners": [
{
"devices": [
{
"browser": null,
"muted": true
},
{
"browser": null,
"muted": true
}
],
"jid": "d-ef53637c-f44c-4f49-9ffb-05436eb995ce",
"muted": true
}
]
}
}
server.call.buzz
Call buzzing
actor
- Short call creator informationbuzz_timeout
- Number of seconds for stop buzzingchat
- Short chat informationdisplay_name
- Chat titleicons
- Chat iconsjid
- Chat or contact idteam
- Deprecatedteaminfo
- Short team informationuid
- Call id
{
"event": "server.call.buzz",
"params": {
"display_name": "имя фамилия",
"icons": {
"lg": {
"height": 512,
"url": "http://127.0.0.1:8000/static/tada-bots/systembot512.png",
"width": 512
},
"sm": {
"height": 256,
"url": "http://127.0.0.1:8000/static/tada-bots/systembot256.png",
"width": 256
}
},
"jid": "g-3f7e2a85-49f5-4586-8229-d9c52813dcb2",
"team": "6aefcf3b-e61c-4f35-8b5b-9d762a6a6cf9"
}
}
server.call.buzzcancel
Call cancelled on buzzing
jid
- Chat or contact idteam
- Team iduid
- Call id
{
"event": "server.call.buzzcancel",
"params": {
"jid": "d-0bdfbbf5-abfa-4ed2-9f98-991d5bb80127",
"team": "848cc926-3048-44b3-a9ba-3195a394351d"
}
}
server.call.checkfingerprint
Experimental function
fingerprint
- DOCUMENTATION MISSING
MISSING EXAMPLE
server.call.leave
Participant leave a call
jid
- Chat or contact iduid
- Call uid
MISSING EXAMPLE
server.call.muteall
All participants in call muted
jid
- Chat or contact idmuted
- Mute state
MISSING EXAMPLE
server.call.reject
Call rejected
jid
- Chat or contact idreason
- Reason, if anyuid
- Call id
MISSING EXAMPLE
server.call.restart
Call restarted
jid
- Chat or contact idteam
- Team iduid
- Call id
MISSING EXAMPLE
server.call.sdp
For exchange Session Description with client when server’s Local Session Description is changed
jid
- Chat or contact idjsep
- SDP datauid
- Call id
MISSING EXAMPLE
server.call.sound
Mute/unmute call participant
jid
- Chat or contact idmuted
- Mute state
MISSING EXAMPLE
server.call.state
Call information
audiorecord
- Call record enabledbuzz
- Call buzzingcreated
- Creation date, iso datetimefinish
- Call finishgentime
- Versionjid
- Chat or contact idonliners
- Call participantsstart
- Call start. For direct calls can be empty when buzzingtimestamp
- Deprecated: use gentime or createduid
- Call id
{
"event": "server.call.state",
"params": {
"audiorecord": true,
"buzz": false,
"finish": null,
"jid": "g-3f7e2a85-49f5-4586-8229-d9c52813dcb2",
"onliners": [
{
"devices": [
{
"muted": false,
"useragent": "Chrome"
}
],
"jid": "d-d6de9748-0bcd-4145-b1ce-3d7f41c1c26f",
"muted": false
}
],
"start": "2019-09-27T01:01:35.264095Z"
}
}
server.call.talking
Someone talks in call
actor
- Actor idjid
- Chat or contact idtalking
- Is talking
{
"event": "server.call.talking",
"params": {
"_level": null,
"actor": "d-bd500a50-3a38-44d1-a43c-fb1a48e1a79e",
"jid": "d-bd500a50-3a38-44d1-a43c-fb1a48e1a79e",
"talking": true
}
}
server.chat.composing
Someone typing or recording audiomessage in chat
actor
- Actor idcomposing
- true = start typing / audio recording, false = stopis_audio
- true = audiomessage, false = text typingjid
- Chat or contact idvalid_until
- Composing event max lifetime
{
"event": "server.chat.composing",
"params": {
"actor": "d-bd500a50-3a38-44d1-a43c-fb1a48e1a79e",
"composing": true,
"is_audio": false,
"jid": "d-bd500a50-3a38-44d1-a43c-fb1a48e1a79e"
}
}
server.chat.deleted
Chat deleted
badge
- Total number of unreadschats
- List of deleted chatsteam_unread
- Current team counters
{
"event": "server.chat.deleted",
"params": {
"badge": 449,
"chats": [
{
"chat_type": "group",
"gentime": 1569546094920474368,
"is_archive": true,
"jid": "g-3f7e2a85-49f5-4586-8229-d9c52813dcb2"
}
],
"team_unread": {
"direct": {
"chats": 1,
"messages": 31
},
"group": {
"chats": 0,
"messages": 0
},
"task": {
"chats": 1,
"messages": 1
}
}
}
}
server.chat.draft
Changed draft message in chat
draft
- Draft textdraft_gentime
- Draft versiondraft_num
- Deprecatedjid
- Chat or contact id
MISSING EXAMPLE
server.chat.lastread
Changed last read message in chat
badge
- Total number of unreadschats
- Chat countersteam_unread
- Current team counters
{
"event": "server.chat.lastread",
"params": {
"badge": 0,
"chats": [
{
"chat_type": "direct",
"gentime": 1569546084300075149,
"jid": "d-2a9d8c43-41d1-479c-9c8c-f029f799a724",
"last_read_message_id": "f4f1f09c-f978-4b54-a321-b4c82604010d",
"num_unread": 0,
"num_unread_notices": 0
}
],
"team_unread": {
"direct": {
"chats": 0,
"messages": 0
},
"group": {
"chats": 0,
"messages": 0
},
"task": {
"chats": 0,
"messages": 0
}
}
}
}
server.chat.updated
Chat created or updated
badge
- Total number of unreadschats
- Chat countersteam_unread
- Current team counters
{
"event": "server.chat.updated",
"params": {
"badge": 449,
"chats": [
{
"can_call": true,
"can_send_message": true,
"chat_type": "group",
"counters_enabled": true,
"created": "2019-09-18T00:00:06.105362Z",
"default_for_all": true,
"description": "Сюда автоматически попадают все участники команды",
"display_name": "Общий чат",
"gentime": 1568764808134709248,
"icons": {
"stub": "http://127.0.0.1:8000/u/f0769a/%D0%9E%D1%87/256.png"
},
"jid": "g-82d6c0d4-8921-4519-abb3-02f17373112f",
"notifications_enabled": true,
"num_members": 32,
"public": true,
"status": "member"
}
],
"team_unread": {
"direct": {
"chats": 1,
"messages": 31
},
"group": {
"chats": 0,
"messages": 0
},
"task": {
"chats": 1,
"messages": 1
}
}
}
}
server.confirm
Server confirmed client message
confirm_id
- Unique id generated by server
{
"event": "server.confirm",
"params": {
"confirm_id": "b8b2ccd6-35a6-408f-a591-c696a9f9e73e"
}
}
server.contact.updated
Contact created or updated
contacts
- Contact info
{
"event": "server.contact.updated",
"params": {
"contacts": [
{
"can_add_to_group": true,
"can_call": true,
"can_create_task": true,
"can_send_message": true,
"changeable_fields": [],
"contact_email": "",
"contact_phone": "+75550000031",
"display_name": "Контакт №32",
"icons": {
"stub": "http://127.0.0.1:8000/u/8e88eb/32/256.png"
},
"jid": "d-a792832a-d9f6-4bbc-b545-f2800e329c8c",
"last_activity": null,
"role": "",
"sections": [],
"status": "member"
}
]
}
}
server.debug
Debug message
text
- Debug message
MISSING EXAMPLE
server.login
Login from other device
device_name
- Device name
{
"event": "server.login",
"params": {
"device_name": "(unknown device)"
}
}
server.message.push
Push replacement for desktop application
chat
- Chat idclick_action
- Url opened on clickcreated
- Message creation iso datetimeicon_url
- Absolute url to push iconmessage
- Push bodymessage_id
- Message idsender
- Sender contact idsubtitle
- Push subtitletag
- Push tag (for join pushes)team
- Team uidtitle
- Push title
MISSING EXAMPLE
server.message.received
Message received by someone in chat
messages
- received message data
{
"event": "server.message.received",
"params": {
"messages": [
{
"chat": "t-be962c01-14ae-4c59-aeb0-f0ff5cffab74",
"message_id": "e0fca4c2-0d17-4317-96cd-703c2ca781e4",
"num_received": 0,
"received": false
}
]
}
}
server.message.updated
Chat message created, updated or deleted
badge
- Total number of unreads, if changedchat_counters
- Chat countersdelayed
- true = silently message update, false = new messagemessages
- Messages datateam_unread
- Current team counters
{
"event": "server.message.updated",
"params": {
"badge": 51,
"chat_counters": [
{
"chat_type": "task",
"gentime": 1569546093662061959,
"jid": "t-be962c01-14ae-4c59-aeb0-f0ff5cffab74",
"last_read_message_id": null,
"num_unread": 0,
"num_unread_notices": 0
}
],
"delayed": false,
"messages": [
{
"chat": "t-be962c01-14ae-4c59-aeb0-f0ff5cffab74",
"chat_type": "task",
"content": {
"actor": "d-0b1b2362-fb69-4dd6-8bfb-90c89517168d",
"text": "Создана задача для @Контакт_№394: Тест",
"title": "Создана задача для @Контакт_№394: Тест",
"type": "change"
},
"created": "2019-09-27T01:01:33.661466Z",
"editable_until": "2019-09-28T01:01:33.661466Z",
"from": "d-a2d94e8e-74aa-4b0b-b55d-0b4fc1ce07f4",
"gentime": 1569546093662061959,
"is_first": true,
"is_last": true,
"message_id": "e0fca4c2-0d17-4317-96cd-703c2ca781e4",
"to": "t-be962c01-14ae-4c59-aeb0-f0ff5cffab74"
}
],
"team_unread": {
"direct": {
"chats": 1,
"messages": 51
},
"group": {
"chats": 0,
"messages": 0
},
"task": {
"chats": 0,
"messages": 0
}
}
}
}
server.online
Online team members and current active calls
calls
- Active callscontacts
- Online team members
{
"event": "server.online",
"params": {
"calls": [
{
"jid": "g-3f7e2a85-49f5-4586-8229-d9c52813dcb2"
}
],
"contacts": [
{
"afk": false,
"jid": "d-bd500a50-3a38-44d1-a43c-fb1a48e1a79e",
"mobile": false
}
]
}
}
server.processing
Status of background operation
action
- Action namehas_error
- Has errormessage
- Messagenum
- Current processing itemtotal
- Total processing items
MISSING EXAMPLE
server.remind.deleted
Task or group remind deleted
reminds
- Remind information
{
"event": "server.remind.deleted",
"params": {
"reminds": [
{
"uid": "22018199-c3ae-4a9c-829e-985e975eb62a"
}
]
}
}
server.remind.fired
Task or group remind fired
reminds
- Remind information
{
"event": "server.remind.fired",
"params": {
"reminds": [
{
"chat": "t-2c527748-2e00-440e-a625-58121d42fdad",
"fire_at": "2019-09-27T11:01:03.428564Z",
"uid": "22018199-c3ae-4a9c-829e-985e975eb62a"
}
]
}
}
server.remind.updated
Task/group remind created or changed
reminds
- Remind information
{
"event": "server.remind.updated",
"params": {
"reminds": [
{
"chat": "t-2c527748-2e00-440e-a625-58121d42fdad",
"fire_at": "2019-09-27T11:01:03.428564Z",
"uid": "22018199-c3ae-4a9c-829e-985e975eb62a"
}
]
}
}
server.section.deleted
Contact section or task project deleted
chat_type
- Chat typegentime
- Deprecatedsections
- Section/project info
{
"event": "server.section.deleted",
"params": {
"chat_type": "direct",
"gentime": 1568786364815431424,
"sections": [
{
"uid": "8daeb4a2-4863-4953-bcf1-c58b84dc5272"
}
]
}
}
server.section.updated
Contact section or task project created or changed
chat_type
- Chat typegentime
- deprecatedsections
- Section/project info
{
"event": "server.section.updated",
"params": {
"chat_type": "group",
"gentime": 1569546093241191168,
"sections": []
}
}
server.tag.deleted
Tag deleted
tags
- Tags info
MISSING EXAMPLE
server.tag.updated
Tag created or changed
tags
- Tags info
MISSING EXAMPLE
server.team.counters
Counters form other teams
badge
- Total number of unreadsteams
- Counters
{
"event": "server.team.counters",
"params": {
"teams": [
{
"uid": "b3e92407-41d0-456a-9b1d-3d6b79bfa7d3",
"unread": {
"direct": {
"chats": 1,
"messages": 161
},
"group": {
"chats": 0,
"messages": 0
},
"task": {
"chats": 1,
"messages": 1
}
}
},
{
"uid": "8b05a648-d43a-4d17-9a0e-c2a119453494",
"unread": {
"direct": {
"chats": 0,
"messages": 0
},
"group": {
"chats": 0,
"messages": 0
},
"task": {
"chats": 1,
"messages": 1
}
}
},
{
"uid": "6aefcf3b-e61c-4f35-8b5b-9d762a6a6cf9",
"unread": {
"direct": {
"chats": 1,
"messages": 3
},
"group": {
"chats": 0,
"messages": 0
},
"task": {
"chats": 0,
"messages": 0
}
}
},
{
"uid": "5e854825-d1ac-4b28-a389-f0e8cc3bd675",
"unread": {
"direct": {
"chats": 1,
"messages": 1
},
"group": {
"chats": 0,
"messages": 0
},
"task": {
"chats": 0,
"messages": 0
}
}
},
{
"uid": "180b9b6d-ecb0-47aa-8712-33dbd9b4a642",
"unread": {
"direct": {
"chats": 0,
"messages": 0
},
"group": {
"chats": 1,
"messages": 58
},
"task": {
"chats": 0,
"messages": 0
}
}
},
{
"uid": "99cabb3b-d4fd-464d-b33d-144b67e3c1df",
"unread": {
"direct": {
"chats": 1,
"messages": 127
},
"group": {
"chats": 0,
"messages": 0
},
"task": {
"chats": 1,
"messages": 1
}
}
},
{
"uid": "523e7bdc-e73f-4150-b6b9-656d6178ba51",
"unread": {
"direct": {
"chats": 1,
"messages": 63
},
"group": {
"chats": 0,
"messages": 0
},
"task": {
"chats": 1,
"messages": 1
}
}
},
{
"uid": "c9d8a896-a2b6-40a1-869e-2ecc0ef2436b",
"unread": {
"direct": {
"chats": 1,
"messages": 31
},
"group": {
"chats": 0,
"messages": 0
},
"task": {
"chats": 1,
"messages": 1
}
}
}
]
}
}
server.team.deleted
Team archived
teams
- Teams info
{
"event": "server.team.deleted",
"params": {
"teams": [
{
"is_archive": true,
"uid": "c9d8a896-a2b6-40a1-869e-2ecc0ef2436b"
}
]
}
}
server.team.updated
Team created or changed
teams
- DOCUMENTATION MISSING
{
"event": "server.team.updated",
"params": {
"teams": [
{
"can_manage_sections": true,
"default_task_deadline": "18:00:00",
"icons": {
"stub": "http://127.0.0.1:8000/u/f0769a/00/256.png"
},
"last_active": false,
"max_message_update_age": 86400,
"me": {
"alt_send": false,
"can_add_to_group": true,
"can_create_task": true,
"can_delete": true,
"changeable_fields": [
"alt_send",
"contact_email",
"contact_mshort_view",
"contact_phone",
"contact_short_view",
"contact_show_archived",
"debug_show_activity",
"default_lang",
"family_name",
"given_name",
"group_mshort_view",
"group_notifications_enabled",
"group_short_view",
"icons",
"phone",
"role",
"task_mshort_view",
"task_notifications_enabled",
"task_short_view",
"unread_first"
],
"contact_email": "",
"contact_mshort_view": false,
"contact_phone": "+75550000001",
"contact_short_view": false,
"contact_show_archived": false,
"debug_show_activity": false,
"default_lang": null,
"display_name": "Контакт №2",
"family_name": "№2",
"given_name": "Контакт",
"group_mshort_view": false,
"group_notifications_enabled": true,
"group_short_view": false,
"icons": {
"stub": "http://127.0.0.1:8000/u/63bed3/%D0%9A%E2%84%96/256.png"
},
"jid": "d-bd500a50-3a38-44d1-a43c-fb1a48e1a79e",
"last_activity": null,
"role": "",
"sections": [],
"status": "member",
"task_mshort_view": false,
"task_notifications_enabled": true,
"task_short_view": false,
"unread_first": false
},
"name": "T-32 2019-09-18 00:00:05.603182+00:00",
"need_confirmation": true,
"uid": "c9d8a896-a2b6-40a1-869e-2ecc0ef2436b",
"unread": {
"direct": {
"chats": 1,
"messages": 31
},
"group": {
"chats": 0,
"messages": 0
},
"task": {
"chats": 1,
"messages": 1
}
}
}
]
}
}
server.time
Current server time
time
- Current time
{
"event": "server.time",
"params": {
"time": "2019-09-27T01:01:33.216665Z"
}
}
server.uisettings
Part of UI settings changed
data
- UiSettingsDatanamespace
- Namespace. For example: web, app
{
"last-tab": 91238475
}
server.upload.updated
Upload object created or changed
uploads
- Uploads data
MISSING EXAMPLE
server.warning
Something went wrong with client message
message
- Messageorig
- Debug information
{
"event": "server.warning",
"params": {
"message": "unknown event: client.deeeeeaddddbeeeeeef",
"orig": {
"confirm_id": "c6280a82ed1c",
"event": "client.deeeeeaddddbeeeeeef"
}
}
}