title: Set input type of a rest web service to Json
body: <p>I'm having a rest web service and i'm executing it through Rest Client in FF. Till now it was used as a post method now i've to change it's input type to JSON i.e now i'm sending json input to that ws but on rest client i'm getting</p>
  
  <pre><code>Status Code: 415 Unsupported Media Type
  Connection: Keep-Alive
  Content-Length: 0
  Content-Type: text/plain
  Date: Wed, 28 Aug 2013 07:52:50 GMT
  Keep-Alive: timeout=5, max=99
  Server: Apache/2.2.19 (Win32) mod_jk/1.2.30 PHP/5.3.6
  </code></pre>
  
  <p>Below is the ws new signature (I've added the Consume and Produce Line)</p>
  
  <pre><code>@Override
      @POST
      @Path("/addHouseHoldAccounts")
      @Consumes(MediaType.APPLICATION_JSON)
      @Produces(MediaType.APPLICATION_JSON)
      public Response addHouseHoldAccounts(JSONObject jsonObject) {
  ....
  ....
  }
  </code></pre>
  
  <p>on rest client i've set header <code>Content-Type application/json</code></p>
  
  <p>and below is the JSON input i'm trying to send</p>
  
  <pre><code>{
     "jsonObject":{
         "JsonId":"17fb00b6-dfa3-4cc6-b7ba-c54ecd429350",
     "JsonTypeOf":"JSonTest",
     "JsonType":"",
     "JsonTypetName":"JsonImplemented"
     }
  }
  </code></pre>
  
  <p>can anyone point out my mistake or suggest me a solution for achieving this.</p>