views:

66

answers:

1

We have web service running for one of our projects. We want to be able to access this web service similar to how you'd access an API (such as Google Data, etc.) where you have client libraries in several languages: .NET, Java, Python, etc.

You'd be able to download these libraries (usually .DLL) from our project's website and then integrate these into your custom application.

The reason we want to have these client libraries is so that we can encrypt certain data transfers between the client and the web service and so that you wouldn't have to login a million times when you want to make a request (like you have to do when using raw SOAP requests).

So, my question is... What's the best way to do this? What would the client libraries contain, other than some encryption and a bunch of methods? What's the best way to create these libraries? Obviously some different platforms are needed to accomplish this (some flavor of Linux, maybe Mac OS), should virtual environments be used?

What are your thoughts? Thanks in advance for your help!

+1  A: 

You would first express an API via the web service. What you are then interested in doing is creating a client "wrapper" for your web service API. This is what the client would download and use in their application (similar to Facebook.NET). This would be an assembly project and house a bunch of classes and so on. These classes would maintain the state of the program utilizing the API and would take care of all the low level plumbing work interacting with the web services by exposing a verbose object model that is easy enough for the user of your wrapper to get around in.

You could do this for any language that could interact with your web services. Java, Python, etc. I suggest using WCF though as you can use TCP for the .NET library and standard web services for the other languages. This will help you to be more performance oriented where possible.

Andrew Siemer
So you suggest using WCF over WebServices in .NET? Aside from performance boosts, are there a lot of differences between WCF and WebServices? Is it hard to convert an existing WebService project to WCF?Thanks for your reply!
mbmccormick
The difference is performance boost, more granular control over security, support for multiple ways to access the method, etc. Converting is not difficult. WCF allows you to work with it easily and simply...but provides more complexity as you need to dig into it.
Andrew Siemer