title: "HttpMediaTypeNotAcceptableException: Could not find acceptable representation" error with type HTML
body: <p>I have a simple controller:</p>
  
  <pre><code>@RequestMapping(value = "/html", method = RequestMethod.GET, produces = MediaType.TEXT_HTML_VALUE)
  public ResponseEntity&lt;String&gt; calculateHTML(@RequestParam(required = false) final String key){
  String asd = "&lt;html&gt;&lt;head&gt;&lt;/head&gt;&lt;body&gt;Hello World!&lt;/body&gt;&lt;/html&gt;";
  HttpHeaders headers = new HttpHeaders();
      headers.setContentType(MediaType.TEXT_HTML);
      return new ResponseEntity&lt;String&gt;(asd, headers, HttpStatus.OK);
  </code></pre>
  
  <p>}</p>
  
  <p>However, I'm getting org.springframework.web.HttpMediaTypeNotAcceptableException: Could not find acceptable representation when i try to excecute the web service, since I'm learning with this simple example, i'm totally lost.</p>
  
  <p>When I remove the produces "produces = MediaType.TEXT_HTML_VALUE" it works, however the output seems to be a json</p>