I’ve been doing a lot of research into how you can extend OCS using the SDKs that MS makes available. Before I launch into my take on it, I have a couple points about the SDKs
- There are lots of SDKs
- The SDKs are very, very good – they are the building blocks that OCS itself was written with
- I am shocked at what you can do with the SDKs
If you want details on all the different SDKs and what they do, visit Joe Calev’s blog
What I wanted to do in this post is to give you an idea of what kinds of things you can do with the SDKs and the quickest way to do it.
What you can do
I wanted to be able to get an IM sent to me everytime a record in a back-end database gets created or updated. For example, if someone submits an expense report and needs my approval. The OCS SDKs make this task possible.
You can write an app (in C#) based on some sample code that monitors a database, then uses the communicator libraries to send out an IM to the right manager when an expense report is submitted to the database. The IM can say something like "Hello Matt, an expense report for BillyBob has been submitted and awaits your approval". In this case, the app requires some intelligence to know that I am BillyBob’s manager.
But wouldn’t it be cool if the IM also sent out a second message that contained a link: "Click here to view the expense report"? Or if the IM just contained all the expenses and you approved it via IM? All totally doable. Better yet, use the application to detect my presence: if I am available, send me the IM, if I am busy, send me an e-mail, if I am out-of-office, send the message to a different manager.
The more interesting scenario might be having your application watch certain key metrics, like say if the Dow Jones Industrial Average drops below a certain level, immediately notify the relevant parties. Or if a flight is going to arrive late or at a different gate, send out a notice to the gate agents, family members of passengers, whomever. Or heck, even use OCS to send out an automated phone call made by Speech Server / OCS to multiple people, depending on who shows "available" presence.
The point is that you can really weave OCS into the fabric of your business in many different ways.
How best to do it
I’ve discovered that the easiest way to get started with OCS SDKs and building your own apps with them is to use the AJAX SDK. This is the most user-friendly SDK out there. You get a sample OCS client app (it’s what the OCS web communicator app is based on) that you can fiddle with in either C# or JavaScript. I am a bad programmer and was able to muck around enough to do some cool stuff with it. I asked one of our developers to lend a hand to write an app with the SDK that would do a lot of the database / business logic stuff that I mentioned above. He had it done in a day or so. It was mighty impressive.
Now, if you are interested in building a scalable, enterprise-class app, the AJAX SDK is not for you. The real deal is using the UCMA SDK. It contains all the building blocks that were used to write many of the OCS servers themselves: Mediation, Exchange UM among others. This SDK lets you write your own scalable server application to integrate OCS into almost any back-end application or business process you have.
Demo
I’ve put together a demo of how an app like this works and will be posting it to our site as a "podcast". Once it’s posted, I’ll link to it here.
Conclusion
For now, if you have any development skillz at all, I recommend taking a look at the OCS AJAX SDK and tweaking the sample code. You’ll need a copy of Visual Studio to do the tweaking. And this SDK runs against the CWA server, so you’ll need that role in place. The important thing is to start playing with the SDKs and understanding how powerful a platform OCS is. You can start to see how it can transform the way people do business.