Re: WebSockets: determine the active device when using hotdesking
Hello Richard,
the Hotdesking functionality from the point of view of an IP-phone is just a switch, that enables a VoIP registration on this device with a username + password (usually it is a MAC address of the device + TLS certificate). You can press the hotdesking button and type in userna and password to login. Press the hotdesking button to log out.
The hotdesking configuration from the PBX point of view is just a setting, that enables a VoIP registration/login using username/password combination (usually this is not enabled, so login via MAC is only possible). The only configuration change is a new entry in the Devices list of the User Object, where the "Hardware Id" matches the "Name" of the User Object.
What the customer asks you is not really a hotdesking feature, but just switching between active devices in the myApps client. This is the variant b) in your question number 3.
The switching between phone devices is in fact selecting default app for the telephony in the myApps client. This functionality is based on a client API between myApps cleint and the PBX.
The myApps client gets a message from the PBX with a list of APIs. The API "com.innovaphone.phone" is provided by registered phones. Here is an example, with one phone registered by MAC and one registered by hotdesking (johndoe):
{
"mt": "ApiUpdate",
"defaultApiProviders": {
"com.innovaphone.chat": "chat",
"com.innovaphone.phone": "dev:johndoe"
},
"apis": {
"com.innovaphone.phone": {
"dev:0090334f21c1": {
"info": {
"type": "phone"
},
"model": {},
"title": "sifi IP Phone IP111",
"url": "http://localhost:10008/appproxy/ext/sifi.innovaphone.com/PBX0/APPS/phone/phone.htm"
},
"dev:johndoe": {
"info": {
"type": "phone"
},
"model": {},
"title": "hotdesking",
"url": "http://localhost:10008/appproxy/ext/sifi.innovaphone.com/PBX0/APPS/phone/phone.htm"
}
}
}
}
This way you can detect the active device - it is the default API provider for the "com.innovaphone.phon" API.
Regarding questions about your system - it seems to be, multiple settings for Devices and Profile App are not set correctly. Usually if you use the installer wizard to setup the PBX, all required settings are set automatically. If you have the possibility to run the install again and configure your PBX from scratch, this would be a fastest solution.
Best Regards
Andreas Fink