How to retrieve JSON via ASP.Net context.Request

  1. get the request body from HttpContext.Current.Request.InputStream.
  2. read the input stream and convert to string
  3. use javascriptserializer to deserialize the json object to a strongly type object (ensure the json properties share the same name as the strongly type counter part)

Leave a Comment