For people unaware, Microsoft Lync is the new name for Microsoft Office Communications Server (OCS). In the past couple months I’ve been working with the Lync Client SDK to build client experiences on top of the recently released Lync Server RC and Lync Client SDK RC. I’m going to go through what is available to you in the Client SDK.
The Client SDK allows you to integrate client functionality like messaging, presence, voice, video and automation into your applications. It can be as simple as showing a users presence status in your application to being a full communicator-like experience that you can customize yourself.
I’m going to discuss the high level out-of-the-box functionality the SDK provides, the differences from the Communicator 2007 SDK as well as what UI Suppression mode is and what it means to you and how you decide to integrate with Lync Client (more on that later).
Office Communicator 2007
I won’t spend much time on Communicator 2007 but I wanted to mention it because the integration options in Lync Client that are available today are different than in Communicator 2007.
In Communicator 2007 you had the ability to integrate into the actual Communicator user interface and you could embed things like Silverlight to build rich experiences within Communicator. This was removed in Lync Client. You can no longer integrate within the user interface. Optionally the SDK gives a whole new twist to the problem of building communications driven applications based on Lync by exposing a collection of reusable WPF (Windows Presentation Foundation) and Silverlight controls.
Lync Client 2010
As mentioned in the Lync Client SDK we get an array of pre-canned controls for both WPF and Silverlight to use. These controls are very much identical to the Lync Client user interface. In a sense these are building blocks that allow you to add specific features into your already existing applications such as Presence, Messaging and Voice etc. If you wanted you could build a user interface using these controls that looked almost identical to the Lync Client themselves.
These controls like most WPF or Silverlight controls support templating so you can completely overhaul the visuals if you wish or you can keep the default Lync Client matching styles.
Here are some examples of the controls available to you (these are the WPF versions):
The great thing about these controls is you don’t have to do anything to get them to work. You drop them on your application and they will communicate with Lync Client behind the scenes and automatically display the data. You can use these to built a feature filled experience or you can drop something as simple as the PresenceIndicator if you want to display status of a user within your application. Alternatively you could just drop a call button if you want a user to have quick access to calling another user. There is lots of possible user experiences you can create from these.
These controls as I mentioned earlier are like any other WPF or Silverlight control. You can customize their appearance through Styling and Control Templates.
Using these controls has a caveat when we enable UI Suppression Mode. What is UI Suppression Mode? Let’s find out.
UI Suppression Mode
Some people will use the reusable controls to enable Presence, Messaging, Voice and other features in their applications but some of you may want to build a custom Lync Client user interface tailored to your needs. At first glance, UI Suppression looks like it is the last piece to your puzzle. UI Suppression Mode disables the Lync Client user interface. This means you can implement your own to replace Microsoft’s Lync Client while still leveraging the Lync Client functionality. Lync Client is still running, but the UI layer is not initialized. This sounds perfect right? Not exactly.
You enable UI Suppression on Lync Client via a registry key and when you do so, this disables all UI functionality, not just the visuals of the UI. This means all of the reusable controls above get disabled. They no longer just work as magically as they did before. I think Microsoft possibly misunderstood what people’s needs were when they wanted to hide Lync Client to implement their own user experience. They gave us a bunch of amazing controls we can reuse and style/template to our visual needs that just automatically hook up to the underlining Lync Client behind the scenes but at the time we want to hide Lync Client that all goes away. This includes the ConversationWindow as well. We have gone from having a cookie-cutter build your own Lync experience to losing all of that and only having the lower-level API’s to deal with.
With these lower-level API’s we can implement our own client but it has now become a much larger task. Things that were for free, are now very big implementations we must develop ourselves rather than customize:
- All the major controls like PresenceIndicator, Contact List, Contact Card etc.
- Options window. In Lync Client there is an options window to configure a bunch of options. We would love to just have a method to bring this on the screen. We don’t want to re-implement all of that.
This is an unfortunate situation here because all we wanted to do was swap the Microsoft Lync Client UI with our own and choose which reusable UI pieces we want. This gives us the option to use their excellent built-in control functionality or we can rewrite the world if we really wish to, but it doesn’t work that way right now. They make the call for us which is all or nothing. Hopefully this changes in the future.
Client & Automation API
The Client API and Automation API allows you to do some pretty powerful things which I will go into further detail in following blog posts. You can programmatically control things such as:
- Publishing Presence & Availability
- Publish Personal Note
- ConversationManager (start IM and audio conversations, respond to conversation invitations, etc)
- ContactsAndGroupsManager (search contacts, query presence, set privacy, etc)
- Subscribe to events
There is a pretty good complement of events you can listen to so that you can track state of contacts, conversations among other things in your application.
On top of all that, using the SDK is very simple and straight forward for the most part. The biggest caveat is UI Suppression Mode. If this doesn’t impact you then everything else is pretty straight forward.
I plan to blog more specific use cases with samples coming soon as well as some other surprises I have found along the way. I’m looking forward to blogging more about Lync Client development and some tricks I have discovered along the way.
If you have any feedback please leave a comment or hit me on Twitter: http://twitter.com/simongui
Trackback from your site.