{"action":"closed","issue":{"url":"https://api.github.com/repos/silkapp/rest/issues/121","labels_url":"https://api.github.com/repos/silkapp/rest/issues/121/labels{/name}","comments_url":"https://api.github.com/repos/silkapp/rest/issues/121/comments","events_url":"https://api.github.com/repos/silkapp/rest/issues/121/events","html_url":"https://github.com/silkapp/rest/issues/121","id":83034206,"number":121,"title":"More flexible handling of Accept / content types","user":{"login":"fnoble","id":163239,"avatar_url":"https://avatars.githubusercontent.com/u/163239?v=3","gravatar_id":"","url":"https://api.github.com/users/fnoble","html_url":"https://github.com/fnoble","followers_url":"https://api.github.com/users/fnoble/followers","following_url":"https://api.github.com/users/fnoble/following{/other_user}","gists_url":"https://api.github.com/users/fnoble/gists{/gist_id}","starred_url":"https://api.github.com/users/fnoble/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fnoble/subscriptions","organizations_url":"https://api.github.com/users/fnoble/orgs","repos_url":"https://api.github.com/users/fnoble/repos","events_url":"https://api.github.com/users/fnoble/events{/privacy}","received_events_url":"https://api.github.com/users/fnoble/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-05-31T08:09:52Z","updated_at":"2015-06-16T13:26:10Z","closed_at":"2015-06-16T13:26:10Z","body":"I'm still trying to get my head around the `Handler` / `Dict` mechanics so forgive me if this is a silly question.\r\n\r\nI have a resource that has a representation either as JSON or as a legacy industry specific text based format. The legacy format is stored as a `ByteString` and is cached by the server. I want to be able to dispatch different responses with these two formats depending on what is in the `Accept` header. I'm running into a couple problems:\r\n\r\n1) I can write a handler for the legacy format that uses `fileO`. It works but it sets some headers inappropriately for this application. Same with `rawXmlO`. It doesn't seem like there is any way to have a custom content type?\r\n\r\n2) I'm having difficulty combining my `jsonO` and `fileO` handlers. I guess I just don't understand the `Dict` mechanism well enough to see if this is even possible. It seems like it only works for `(jsonO . xmlO)` because the same value can be serialized into either output? Is there any way to explicitly dispatch based on the `Accept` header? "}}