This an oldie, but a goodie. Not many people use this tool, much less know about it or where it exists.
By default when you install VS2008 (I’m not sure if its part of 2005 or not) you have a tool at your disposal in the Visual Studio install path:
My Path: c:\Program Files\Microsoft Visual Studio 9.0\Common7\ide\
In this path, you’ll find a tool called “WcfTestClient.exe”
It is located here: c:\Program Files\Microsoft Visual Studio 9.0\Common7\ide\WcfTestClient.exe
Fire this bad boy up and here’s the screen you get:
You can add a service endpoint by right clicking on “My Service Projects” and clicking Add Service
Then paste in your service location (I’m using an open one I found on xmethods.net that generates prime numbers):
Click Ok, and the service contract, config, etc will be generated for you and you’ll have something that looks like this:
Double click on “GetPrimeNumbers” and you’ll see the following:
Open the body of the request (as it looks like this service uses message contracts) and where it says “(null)” select “GetPrimeNumbersRequestBody”
Then expand the body and the request what is the highest number the service should search for prime numbers (in english – give me all the prime numbers up to 50):
Click “Invoke”, wait a few seconds and your response will come back.
All Done!
You have now tested a WCF Service without creating an application, generating a proxy, running the app, etc. Super easy!
Other Uses
You could use this to test your own in house services or even to debug a service running on your machine during development (if you wanted to test full end to end). Simply paste in the address of your local service (http://localhost:someport/myservice.svc) and then start testing. This is a HUGE time saver to see if your service works or not. Otherwise you’d have to generate a client, perform a service reference or generate a service proxy, etc.
Dev says
I dont have it, where can I download it?
Coach Outlet Online says
http://www.mycoachoutletstoreonline.com
Coach Factory Outlet says
http://buycoachfactoryoutletsz.com
Cheap ray bans says
The oakley oil rig, radar, oakley goggles of cheap oakleys are hot sale online, and the more and more new product of fake oakleys are waitting for your choice, If you want to experience the new product brings the protection and the pleasant sensation, fake oakley sunglasses can let you spend less money and experience more different style, No matter you are men and women, you will get your favorite style on the outlet cheap oakley sunglasses
namigop says
Have you tried WCFStorm? It’s pretty neat and the free version still has more features than WCFTestClient
http://www.wcfstorm.com