Course info
Jul 23, 2015
1h 20m

The Skype Web SDK is a complete JavaScript library for Skype that enables developers to embed Skype and Lync functionality into web sites and applications without the need for complex infrastructure. This course shows developers how to get started with the SDK by introducing tasks such as retrieving contacts, presence, and sending and receiving instant messages.

About the author
About the author

Matthew is a telecommunications industry executive and software developer, but his real passion is building tools to enable people to communicate simply and effectively. He writes software for Microsoft Skype for Business (formerly Lync) as well as Big Data tools for the telecommunications industry.

More from the author
Skype Web SDK: Audio, Video, and Conferencing
1h 15m
Dec 23, 2015
Section Introduction Transcripts
Section Introduction Transcripts

Managing Your Details
Welcome back. We'll learn how the Skype Web SDK exposes your Lync or Skype for Business account details. Including your contact information and how this can be updated in real time. This information can be displayed and managed within conversations and conferences and how it can be used to help people find you in directories and contact you. Firstly we'll look at the mePerson object, which is a collection of the properties and methods containing your account information. We'll look at how to retrieve this collection. We'll look at how to update this collection. We'll look at an example of how this works and we'll be shown a quick demonstration followed by a brief summary.

Receiving an Instant Message
Previously, we looked at the steps required to create a new conversation and add participants in order to send instant messages. In this module we'll be exploring how to receive instant messages back from one or more participants. This module is made up of five sections. A summary of how messages are received. A review of the chatService and how we use it. The historyService and how in particular it relates to incoming messages. A demonstration showing how to handle multiple incoming messages from different conversational participants. And of course the summary. The chatService we used when sending an instant message earlier in this course already sets up most of the mechanisms needed to receive an instant message. So how does the SDK actually receive an instant message? Firstly, the participant sends the instant message, which arrives at the actual Lync or Skype for Business server. The SDK is connected to the server and collects the message, adding it to the historyService, which we'll see shortly. The server then notifies the sending participant that the message has been received, assuming that it has been presented to the recipient. In this case the currently signed-in user. At this point the application is responsible for collecting the message using the SDK and presenting it to the user or processing it accordingly.

Stopping a Conversation and Signing Out
In our final module, we'll be taking a look at stopping conversations and Skype Web SDK best practices. We'll take a quick look at how to stop a conversation and why you should really do this. We'll review best practices when using the SDK. We'll summarize what we've learned in this course. And finally, I'll provide a list of where you can go to learn more about the Skype Web SDK. Firstly, why would we need to stop a conversation? Sure, participants can close their conversation windows and the conversation, in reality, is over. But the SDK will keep connections on the server open, which is inefficient and wasteful of resources. And will result in errors in the longer term, especially if your server has lots of connections running. As with any client-server application, it is always best practice to close off the connection once it's no longer needed. The final step in any conversation is to stop the conversation. And this is really as simple as invoking the chatService. stop method. I'm sure you could have guessed that. One thing to remember though, when the chatService. stop method is invoked, all history in the messages collection is disposed of. So you should write these to the code database if you wish to keep a copy for audit or logging purposes, before you invoke the stop method.