{"action":"created","comment":{"url":"https://api.github.com/repos/haskell-servant/servant/pulls/comments/218006241","pull_request_review_id":155847591,"id":218006241,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIxODAwNjI0MQ==","diff_hunk":"@@ -130,13 +130,14 @@ data Req f = Req\n   , _reqBody       :: Maybe f\n   , _reqReturnType :: Maybe f\n   , _reqFuncName   :: FunctionName\n+  , _reqBodyIsJSON :: Bool","path":"servant-foreign/src/Servant/Foreign/Internal.hs","position":4,"original_position":4,"commit_id":"62def38a9beec8c0d952660274d65808c2a65a8e","original_commit_id":"62def38a9beec8c0d952660274d65808c2a65a8e","user":{"login":"phadej","id":51087,"node_id":"MDQ6VXNlcjUxMDg3","avatar_url":"https://avatars2.githubusercontent.com/u/51087?v=4","gravatar_id":"","url":"https://api.github.com/users/phadej","html_url":"https://github.com/phadej","followers_url":"https://api.github.com/users/phadej/followers","following_url":"https://api.github.com/users/phadej/following{/other_user}","gists_url":"https://api.github.com/users/phadej/gists{/gist_id}","starred_url":"https://api.github.com/users/phadej/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/phadej/subscriptions","organizations_url":"https://api.github.com/users/phadej/orgs","repos_url":"https://api.github.com/users/phadej/repos","events_url":"https://api.github.com/users/phadej/events{/privacy}","received_events_url":"https://api.github.com/users/phadej/received_events","type":"User","site_admin":false},"body":"I'd rather have\r\n\r\n```haskell\r\nreqBodyContentType :: ReqBodyContentType\r\n\r\ndata ReqBodyContentType = RBCTJSON | RBCTRaw\r\n```\r\n\r\n(better names are welcome). I'd like `servant-foreign` to support other \"envelope\" formats (cbor, edn, ... - those aren't easy to use from JavaScript, but there are other client languages!)","created_at":"2018-09-17T09:45:57Z","updated_at":"2018-09-17T09:46:02Z","html_url":"https://github.com/haskell-servant/servant/pull/1035#discussion_r218006241","pull_request_url":"https://api.github.com/repos/haskell-servant/servant/pulls/1035","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/haskell-servant/servant/pulls/comments/218006241"},"html":{"href":"https://github.com/haskell-servant/servant/pull/1035#discussion_r218006241"},"pull_request":{"href":"https://api.github.com/repos/haskell-servant/servant/pulls/1035"}}},"pull_request":{"url":"https://api.github.com/repos/haskell-servant/servant/pulls/1035","id":215857815,"node_id":"MDExOlB1bGxSZXF1ZXN0MjE1ODU3ODE1","html_url":"https://github.com/haskell-servant/servant/pull/1035","diff_url":"https://github.com/haskell-servant/servant/pull/1035.diff","patch_url":"https://github.com/haskell-servant/servant/pull/1035.patch","issue_url":"https://api.github.com/repos/haskell-servant/servant/issues/1035","number":1035,"state":"open","locked":false,"title":"Implement HasForeign instance","user":{"login":"afcady","id":8866102,"node_id":"MDQ6VXNlcjg4NjYxMDI=","avatar_url":"https://avatars3.githubusercontent.com/u/8866102?v=4","gravatar_id":"","url":"https://api.github.com/users/afcady","html_url":"https://github.com/afcady","followers_url":"https://api.github.com/users/afcady/followers","following_url":"https://api.github.com/users/afcady/following{/other_user}","gists_url":"https://api.github.com/users/afcady/gists{/gist_id}","starred_url":"https://api.github.com/users/afcady/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/afcady/subscriptions","organizations_url":"https://api.github.com/users/afcady/orgs","repos_url":"https://api.github.com/users/afcady/repos","events_url":"https://api.github.com/users/afcady/events{/privacy}","received_events_url":"https://api.github.com/users/afcady/received_events","type":"User","site_admin":false},"body":"This is three patches, to `servant-foreign`, `servant-multipart`, and `servant-js`.\r\n\r\nhttps://github.com/haskell-servant/servant-multipart/compare/master...afcady:multipart-foreign?expand=1\r\n\r\nhttps://github.com/haskell-servant/servant/compare/master...afcady:multipart-foreign?expand=1\r\n\r\nhttps://github.com/haskell-servant/servant-js/compare/master...afcady:multipart-foreign?expand=1\r\n\r\nThe patch to `servant-foreign` adds a Boolean field to the `Req` type specifying whether the request body is JSON (as is currently assumed).  The patch to `servant-multipart` implements a HasForeign instance that sets this field to `False`.  The patch to `servant-js` changes the output of `vanillaJS` when the flag is false, so that `JSON.stringify()` does not get called on the body and the content-type is not set to JSON.\r\n\r\nThis address https://github.com/haskell-servant/servant-multipart/issues/5","created_at":"2018-09-17T01:25:07Z","updated_at":"2018-09-17T09:46:01Z","closed_at":null,"merged_at":null,"merge_commit_sha":"293f221389230a557c497e794c09bdac33d8d431","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/haskell-servant/servant/pulls/1035/commits","review_comments_url":"https://api.github.com/repos/haskell-servant/servant/pulls/1035/comments","review_comment_url":"https://api.github.com/repos/haskell-servant/servant/pulls/comments{/number}","comments_url":"https://api.github.com/repos/haskell-servant/servant/issues/1035/comments","statuses_url":"https://api.github.com/repos/haskell-servant/servant/statuses/62def38a9beec8c0d952660274d65808c2a65a8e","head":{"label":"afcady:multipart-foreign","ref":"multipart-foreign","sha":"62def38a9beec8c0d952660274d65808c2a65a8e","user":{"login":"afcady","id":8866102,"node_id":"MDQ6VXNlcjg4NjYxMDI=","avatar_url":"https://avatars3.githubusercontent.com/u/8866102?v=4","gravatar_id":"","url":"https://api.github.com/users/afcady","html_url":"https://github.com/afcady","followers_url":"https://api.github.com/users/afcady/followers","following_url":"https://api.github.com/users/afcady/following{/other_user}","gists_url":"https://api.github.com/users/afcady/gists{/gist_id}","starred_url":"https://api.github.com/users/afcady/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/afcady/subscriptions","organizations_url":"https://api.github.com/users/afcady/orgs","repos_url":"https://api.github.com/users/afcady/repos","events_url":"https://api.github.com/users/afcady/events{/privacy}","received_events_url":"https://api.github.com/users/afcady/received_events","type":"User","site_admin":false},"repo":{"id":149014948,"node_id":"MDEwOlJlcG9zaXRvcnkxNDkwMTQ5NDg=","name":"servant","full_name":"afcady/servant","private":false,"owner":{"login":"afcady","id":8866102,"node_id":"MDQ6VXNlcjg4NjYxMDI=","avatar_url":"https://avatars3.githubusercontent.com/u/8866102?v=4","gravatar_id":"","url":"https://api.github.com/users/afcady","html_url":"https://github.com/afcady","followers_url":"https://api.github.com/users/afcady/followers","following_url":"https://api.github.com/users/afcady/following{/other_user}","gists_url":"https://api.github.com/users/afcady/gists{/gist_id}","starred_url":"https://api.github.com/users/afcady/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/afcady/subscriptions","organizations_url":"https://api.github.com/users/afcady/orgs","repos_url":"https://api.github.com/users/afcady/repos","events_url":"https://api.github.com/users/afcady/events{/privacy}","received_events_url":"https://api.github.com/users/afcady/received_events","type":"User","site_admin":false},"html_url":"https://github.com/afcady/servant","description":"Main repository for the servant libraries -- DSL for describing, serving, querying, mocking, documenting web applications and more!","fork":true,"url":"https://api.github.com/repos/afcady/servant","forks_url":"https://api.github.com/repos/afcady/servant/forks","keys_url":"https://api.github.com/repos/afcady/servant/keys{/key_id}","collaborators_url":"https://api.github.com/repos/afcady/servant/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/afcady/servant/teams","hooks_url":"https://api.github.com/repos/afcady/servant/hooks","issue_events_url":"https://api.github.com/repos/afcady/servant/issues/events{/number}","events_url":"https://api.github.com/repos/afcady/servant/events","assignees_url":"https://api.github.com/repos/afcady/servant/assignees{/user}","branches_url":"https://api.github.com/repos/afcady/servant/branches{/branch}","tags_url":"https://api.github.com/repos/afcady/servant/tags","blobs_url":"https://api.github.com/repos/afcady/servant/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/afcady/servant/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/afcady/servant/git/refs{/sha}","trees_url":"https://api.github.com/repos/afcady/servant/git/trees{/sha}","statuses_url":"https://api.github.com/repos/afcady/servant/statuses/{sha}","languages_url":"https://api.github.com/repos/afcady/servant/languages","stargazers_url":"https://api.github.com/repos/afcady/servant/stargazers","contributors_url":"https://api.github.com/repos/afcady/servant/contributors","subscribers_url":"https://api.github.com/repos/afcady/servant/subscribers","subscription_url":"https://api.github.com/repos/afcady/servant/subscription","commits_url":"https://api.github.com/repos/afcady/servant/commits{/sha}","git_commits_url":"https://api.github.com/repos/afcady/servant/git/commits{/sha}","comments_url":"https://api.github.com/repos/afcady/servant/comments{/number}","issue_comment_url":"https://api.github.com/repos/afcady/servant/issues/comments{/number}","contents_url":"https://api.github.com/repos/afcady/servant/contents/{+path}","compare_url":"https://api.github.com/repos/afcady/servant/compare/{base}...{head}","merges_url":"https://api.github.com/repos/afcady/servant/merges","archive_url":"https://api.github.com/repos/afcady/servant/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/afcady/servant/downloads","issues_url":"https://api.github.com/repos/afcady/servant/issues{/number}","pulls_url":"https://api.github.com/repos/afcady/servant/pulls{/number}","milestones_url":"https://api.github.com/repos/afcady/servant/milestones{/number}","notifications_url":"https://api.github.com/repos/afcady/servant/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/afcady/servant/labels{/name}","releases_url":"https://api.github.com/repos/afcady/servant/releases{/id}","deployments_url":"https://api.github.com/repos/afcady/servant/deployments","created_at":"2018-09-16T16:39:50Z","updated_at":"2018-09-16T16:39:52Z","pushed_at":"2018-09-17T01:08:38Z","git_url":"git://github.com/afcady/servant.git","ssh_url":"git@github.com:afcady/servant.git","clone_url":"https://github.com/afcady/servant.git","svn_url":"https://github.com/afcady/servant","homepage":"http://haskell-servant.readthedocs.org/","size":5270,"stargazers_count":0,"watchers_count":0,"language":"Haskell","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":null,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"haskell-servant:master","ref":"master","sha":"af7ba3d6b82e67e032a03992649cdbaa7ca51517","user":{"login":"haskell-servant","id":10049283,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEwMDQ5Mjgz","avatar_url":"https://avatars0.githubusercontent.com/u/10049283?v=4","gravatar_id":"","url":"https://api.github.com/users/haskell-servant","html_url":"https://github.com/haskell-servant","followers_url":"https://api.github.com/users/haskell-servant/followers","following_url":"https://api.github.com/users/haskell-servant/following{/other_user}","gists_url":"https://api.github.com/users/haskell-servant/gists{/gist_id}","starred_url":"https://api.github.com/users/haskell-servant/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/haskell-servant/subscriptions","organizations_url":"https://api.github.com/users/haskell-servant/orgs","repos_url":"https://api.github.com/users/haskell-servant/repos","events_url":"https://api.github.com/users/haskell-servant/events{/privacy}","received_events_url":"https://api.github.com/users/haskell-servant/received_events","type":"Organization","site_admin":false},"repo":{"id":27440142,"node_id":"MDEwOlJlcG9zaXRvcnkyNzQ0MDE0Mg==","name":"servant","full_name":"haskell-servant/servant","private":false,"owner":{"login":"haskell-servant","id":10049283,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEwMDQ5Mjgz","avatar_url":"https://avatars0.githubusercontent.com/u/10049283?v=4","gravatar_id":"","url":"https://api.github.com/users/haskell-servant","html_url":"https://github.com/haskell-servant","followers_url":"https://api.github.com/users/haskell-servant/followers","following_url":"https://api.github.com/users/haskell-servant/following{/other_user}","gists_url":"https://api.github.com/users/haskell-servant/gists{/gist_id}","starred_url":"https://api.github.com/users/haskell-servant/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/haskell-servant/subscriptions","organizations_url":"https://api.github.com/users/haskell-servant/orgs","repos_url":"https://api.github.com/users/haskell-servant/repos","events_url":"https://api.github.com/users/haskell-servant/events{/privacy}","received_events_url":"https://api.github.com/users/haskell-servant/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/haskell-servant/servant","description":"Main repository for the servant libraries -- DSL for describing, serving, querying, mocking, documenting web applications and more!","fork":false,"url":"https://api.github.com/repos/haskell-servant/servant","forks_url":"https://api.github.com/repos/haskell-servant/servant/forks","keys_url":"https://api.github.com/repos/haskell-servant/servant/keys{/key_id}","collaborators_url":"https://api.github.com/repos/haskell-servant/servant/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/haskell-servant/servant/teams","hooks_url":"https://api.github.com/repos/haskell-servant/servant/hooks","issue_events_url":"https://api.github.com/repos/haskell-servant/servant/issues/events{/number}","events_url":"https://api.github.com/repos/haskell-servant/servant/events","assignees_url":"https://api.github.com/repos/haskell-servant/servant/assignees{/user}","branches_url":"https://api.github.com/repos/haskell-servant/servant/branches{/branch}","tags_url":"https://api.github.com/repos/haskell-servant/servant/tags","blobs_url":"https://api.github.com/repos/haskell-servant/servant/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/haskell-servant/servant/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/haskell-servant/servant/git/refs{/sha}","trees_url":"https://api.github.com/repos/haskell-servant/servant/git/trees{/sha}","statuses_url":"https://api.github.com/repos/haskell-servant/servant/statuses/{sha}","languages_url":"https://api.github.com/repos/haskell-servant/servant/languages","stargazers_url":"https://api.github.com/repos/haskell-servant/servant/stargazers","contributors_url":"https://api.github.com/repos/haskell-servant/servant/contributors","subscribers_url":"https://api.github.com/repos/haskell-servant/servant/subscribers","subscription_url":"https://api.github.com/repos/haskell-servant/servant/subscription","commits_url":"https://api.github.com/repos/haskell-servant/servant/commits{/sha}","git_commits_url":"https://api.github.com/repos/haskell-servant/servant/git/commits{/sha}","comments_url":"https://api.github.com/repos/haskell-servant/servant/comments{/number}","issue_comment_url":"https://api.github.com/repos/haskell-servant/servant/issues/comments{/number}","contents_url":"https://api.github.com/repos/haskell-servant/servant/contents/{+path}","compare_url":"https://api.github.com/repos/haskell-servant/servant/compare/{base}...{head}","merges_url":"https://api.github.com/repos/haskell-servant/servant/merges","archive_url":"https://api.github.com/repos/haskell-servant/servant/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/haskell-servant/servant/downloads","issues_url":"https://api.github.com/repos/haskell-servant/servant/issues{/number}","pulls_url":"https://api.github.com/repos/haskell-servant/servant/pulls{/number}","milestones_url":"https://api.github.com/repos/haskell-servant/servant/milestones{/number}","notifications_url":"https://api.github.com/repos/haskell-servant/servant/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/haskell-servant/servant/labels{/name}","releases_url":"https://api.github.com/repos/haskell-servant/servant/releases{/id}","deployments_url":"https://api.github.com/repos/haskell-servant/servant/deployments","created_at":"2014-12-02T15:58:17Z","updated_at":"2018-09-15T11:03:27Z","pushed_at":"2018-09-17T01:25:08Z","git_url":"git://github.com/haskell-servant/servant.git","ssh_url":"git@github.com:haskell-servant/servant.git","clone_url":"https://github.com/haskell-servant/servant.git","svn_url":"https://github.com/haskell-servant/servant","homepage":"http://haskell-servant.readthedocs.org/","size":5274,"stargazers_count":1030,"watchers_count":1030,"language":"Haskell","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":231,"mirror_url":null,"archived":false,"open_issues_count":150,"license":null,"forks":231,"open_issues":150,"watchers":1030,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/haskell-servant/servant/pulls/1035"},"html":{"href":"https://github.com/haskell-servant/servant/pull/1035"},"issue":{"href":"https://api.github.com/repos/haskell-servant/servant/issues/1035"},"comments":{"href":"https://api.github.com/repos/haskell-servant/servant/issues/1035/comments"},"review_comments":{"href":"https://api.github.com/repos/haskell-servant/servant/pulls/1035/comments"},"review_comment":{"href":"https://api.github.com/repos/haskell-servant/servant/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/haskell-servant/servant/pulls/1035/commits"},"statuses":{"href":"https://api.github.com/repos/haskell-servant/servant/statuses/62def38a9beec8c0d952660274d65808c2a65a8e"}},"author_association":"NONE"}}
{"actor":{"display_login":"phadej"}}