Search code examples
skype-for-businessskypedeveloper

Skype for Business Web SDK - rejoining a conversation is not working


The problem scenario is as follows:

  1. We create a Skype conversation via the SDK and add 3 or 4 participants, so that it becomes a Skype meeting with a conversation URI
  2. We save the conversation URI in our database so that we can rejoin if we disconnect
  3. The next day, when we try to reconnect to that conversation URI, we get an error:

    Error: The person or meeting doesn't exist. at Error (native) at String.Exception (https://latest-swx.cdn.skype.com/jLync/master_0.4.212/sdk.js:3801:31) at Object.EInvitationFailed (https://latest-swx.cdn.skype.com/jLync/master_0.4.212/sdk.js:17564:38) at https://latest-swx.cdn.skype.com/jLync/master_0.4.212/sdk.js:33747:56 at Task.exec2 (https://latest-swx.cdn.skype.com/jLync/master_0.4.212/sdk.js:4509:63) at Task.exec (https://latest-swx.cdn.skype.com/jLync/master_0.4.212/sdk.js:4489:26) at Task._complete (https://latest-swx.cdn.skype.com/jLync/master_0.4.212/sdk.js:4471:30) at Task.resolve (https://latest-swx.cdn.skype.com/jLync/master_0.4.212/sdk.js:4433:33) at handler (https://latest-swx.cdn.skype.com/jLync/master_0.4.212/sdk.js:15297:34) at Event._invoke (https://latest-swx.cdn.skype.com/jLync/master_0.4.212/sdk.js:5133:32)

We are following the online documentation and using the provided code example here: https://msdn.microsoft.com/EN-US/library/office/dn962176(v=office.16).aspx

It is this line which is throwing the error:

conversation.chatService.start().then(function() {…});

It's worth noting that this behaviour contradicts what is written in the documentation found here: https://msdn.microsoft.com/en-us/library/office/dn962151(v=office.16).aspx

Specifically the part that says it will create a new conversation if it cannot find the existing one:

getConversationByUri Finds an existing multi-party conversation model or creates a new one.

Any help would be greatly appreciated!


Solution

  • The getConversationByUri tries to find an existing conversation model, if it cannot find one then it creates a new model. It does not create a new meeting. When you start chat service it tries to join that meeting. What is happening in your case is that you are escalating a p2p to an adhoc conference whose expiry is around 1 day (will confirm the expiry time shortly). After that uri has expired you cannot reuse it to join the conference. You will need to create a new meeting (either by using the schedule meeting api https://msdn.microsoft.com/en-us/skype/websdk/schedulemeeting) or simply create a new conversation and add the same participants to it.