{"action":"created","issue":{"url":"https://api.github.com/repos/mulesoft-labs/osprey-mock-service/issues/3","labels_url":"https://api.github.com/repos/mulesoft-labs/osprey-mock-service/issues/3/labels{/name}","comments_url":"https://api.github.com/repos/mulesoft-labs/osprey-mock-service/issues/3/comments","events_url":"https://api.github.com/repos/mulesoft-labs/osprey-mock-service/issues/3/events","html_url":"https://github.com/mulesoft-labs/osprey-mock-service/issues/3","id":63458594,"number":3,"title":"'application/json' type body example content never gets written to the response","user":{"login":"jewelsjacobs","id":3187525,"avatar_url":"https://avatars.githubusercontent.com/u/3187525?v=3","gravatar_id":"","url":"https://api.github.com/users/jewelsjacobs","html_url":"https://github.com/jewelsjacobs","followers_url":"https://api.github.com/users/jewelsjacobs/followers","following_url":"https://api.github.com/users/jewelsjacobs/following{/other_user}","gists_url":"https://api.github.com/users/jewelsjacobs/gists{/gist_id}","starred_url":"https://api.github.com/users/jewelsjacobs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jewelsjacobs/subscriptions","organizations_url":"https://api.github.com/users/jewelsjacobs/orgs","repos_url":"https://api.github.com/users/jewelsjacobs/repos","events_url":"https://api.github.com/users/jewelsjacobs/events{/privacy}","received_events_url":"https://api.github.com/users/jewelsjacobs/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":7,"created_at":"2015-03-21T21:56:32Z","updated_at":"2015-03-23T20:18:41Z","closed_at":null,"body":"I can't figure out where these `req.headers.accept` are coming from in\r\n```javaScript\r\nvar type = getType(req.headers.accept, types)\r\n```\r\nhttps://github.com/mulesoft-labs/osprey-mock-service/blob/master/osprey-mock-service.js#L89\r\n\r\nbut they always seem to be returning\r\n `'text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8'`\r\neven if I add `Accept` headers in the RAML.\r\n\r\nThis ensures the `'application/json'` type response body will never make it past the condition in the `getType` function resulting in the body example content never getting written to the response despite the HTTP 200 status code.\r\n\r\nI also tried messing with the files from https://github.com/raml-org/raml-tutorial-200 and the `'binary/octet-stream'` type in https://github.com/raml-org/raml-tutorial-200/blob/master/jukebox-api.raml#L129 totally hosed this as well.\r\n\r\nIn general if you want to put the osprey stuff to the test, those files are pretty good because they are kind of nightmarish. :scream:"},"comment":{"url":"https://api.github.com/repos/mulesoft-labs/osprey-mock-service/issues/comments/85175775","html_url":"https://github.com/mulesoft-labs/osprey-mock-service/issues/3#issuecomment-85175775","issue_url":"https://api.github.com/repos/mulesoft-labs/osprey-mock-service/issues/3","id":85175775,"user":{"login":"blakeembrey","id":1088987,"avatar_url":"https://avatars.githubusercontent.com/u/1088987?v=3","gravatar_id":"","url":"https://api.github.com/users/blakeembrey","html_url":"https://github.com/blakeembrey","followers_url":"https://api.github.com/users/blakeembrey/followers","following_url":"https://api.github.com/users/blakeembrey/following{/other_user}","gists_url":"https://api.github.com/users/blakeembrey/gists{/gist_id}","starred_url":"https://api.github.com/users/blakeembrey/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/blakeembrey/subscriptions","organizations_url":"https://api.github.com/users/blakeembrey/orgs","repos_url":"https://api.github.com/users/blakeembrey/repos","events_url":"https://api.github.com/users/blakeembrey/events{/privacy}","received_events_url":"https://api.github.com/users/blakeembrey/received_events","type":"User","site_admin":false},"created_at":"2015-03-23T20:18:41Z","updated_at":"2015-03-23T20:18:41Z","body":"@jewelsjacobs Right now you can make API requests with `Accept: application/json`, but I'm working on fixing this to parse the media type from the browser correctly."}}