Views: 5655
Last Modified: 23.11.2017
Within IFRAME applications, you can use methods to open user dialogues or to manage window sizes. The following functions are provided to work with web-messenger:
Open messenger window
JavaScript method:
BX24.im.openMessenger
Method call:
<script>>
BX24.im.openMessenger('dialogId');
</script>
Parameters:
dialogId - Dialogue ID:
userId
or chatXXX
- chat, where XXX - chat ID, it can be just a digit.
sgXXX
- chat of group, where XXX – number of social media group (chat should be permitted in this group).
imol|XXXX
- open channel, where XXX – code, returned via REST method imopenlines.network.join.
If nothing is sent, chat interface will open with the last opened dialogue.
Open history window
JavaScript method:
BX24.im.openHistory
Method call:
<script>>
BX24.im.openHistory('dialogId');
</script>
Parameters:
dialogId - Dialogue ID:
userId
or chatXXX
- chat, where XXX - chat ID, it can be just a digit.
imol|XXXX
- open channel, wher XXX – number of open channel session.
Call to internal number
JavaScript method:
BX24.im.callTo
Method call:
<script>>
BX24.im.callTo('userId[, video=true]');
</script>
Parameters:
dialogId - Account user ID.
video - true
- video call, false
- audio call. Optional parameter.
Call to telephone number
JavaScript method:
BX24.im.phoneTo
Method call:
<script>>
BX24.im.phoneTo('number');
</script>
Parameters:
number - Telephone number (string). Telephone number can have format: 6418736493
or (641) 873-6493
.