I would explore using ASP.NET MVC for your web service. You can provide parameters via the standard form parameters and return the result as JSON.
[HttpPost]
public ActionResult MyPostAction( string foo, string bar )
{
...
return Json( new { Value = "baz" } );
}
In your client, use the HttpWebRequest
var request = WebRequest.Create( "/controller/mypostaction" );
request.Method = "POST";
var data = string.Format( "foo={0}&bar={1}", foo, bar );
using (var writer = new StreamWriter( request.GetRequestStream() ))
{
writer.WriteLine( data );
}
var response = request.GetResponse();
var serializer = new DataContractJsonSerializer(typeof(PostActionResult));
var result = serializer.ReadObject( response.GetResponseStream() )
as PostActionResult;
where you have
public class PostActionResult
{
public string Value { get; set; }
}