{"action":"created","comment":{"url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/pulls/comments/96698669","pull_request_review_id":17286303,"id":96698669,"diff_hunk":"@@ -53,37 +82,52 @@ right_code: |\n   ~~~ php\n   <?php\n \n-  $client = new http\\Client;\n-  $request = new http\\Client\\Request;\n-\n-  $request->setRequestUrl('https://api.membergetmember.co/sales/callback');\n-  $request->setRequestMethod('POST');\n-  $request->setQuery(new http\\QueryString(array(\n-    'source' => 'backend_php',\n-    'voucher' => 'VOUCHER',\n-    'name' => 'NAME',\n-    'email' => 'EMAIL',\n-    'api_key' => 'API_KEY'\n-  )));\n-\n-  $client->enqueue($request)->send();\n-  $response = $client->getResponse();\n-\n-  echo $response->getBody();\n+  $request = new HttpRequest();\n+  $request->setUrl('https://api.membergetmember.co/sales/status');\n+  $request->setMethod(HTTP_METH_POST);\n+\n+  $request->setHeaders(array(\n+    'content-type' => 'application/json'\n+  ));\n+\n+  $request->setBody('{\n+    \"source\": \"curl\",\n+    \"api_key\": \"API_KEY\",\n+    \"voucher\": \"VOUCHER_CODE\",\n+    \"name\": \"BUYER_NAME\",\n+    \"email\": \"BUYER_EMAIL\",\n+    \"state\": \"completed\"\n+  }');\n+\n+  try {\n+    $response = $request->send();\n+\n+    echo $response->getBody();\n+  } catch (HttpException $ex) {\n+    echo $ex;\n+  }\n   ~~~\n   {: title=\"PHP\"}\n   ~~~csharp\n-  var client = new RestClient(\"https://api.membergetmember.co/sales/status?source=backend_csharp&voucher=VOUCHER&name=NAME&email=EMAIL&api_key=API_KEY\");\n+  var client = new RestClient(\"https://api.membergetmember.co/sales/status\");\n   var request = new RestRequest(Method.POST);\n+  request.AddHeader(\"content-type\", \"application/json\");\n+  request.AddParameter(\"application/json\", \"{\\n\\t\\\"source\\\": \\\"curl\\\",\\n\\t\\\"api_key\\\": \\\"API_KEY\\\",\\n\\t\\\"voucher\\\": \\\"VOUCHER\\\",\\n\\t\\\"name\\\": \\\"BUYER_NAME\\\",\\n\\t\\\"email\\\": \\\"BUYER_EMAIL\\\",\\n\\t\\\"state\\\": \\\"completed\\\"\\n}\", ParameterType.RequestBody);","path":"_sales_tracking/vouchers.md","position":131,"original_position":131,"commit_id":"296e114a75c423ccf29d1ad5d2a70b6fe2a604c9","original_commit_id":"296e114a75c423ccf29d1ad5d2a70b6fe2a604c9","user":{"login":"harianus","id":1079135,"avatar_url":"https://avatars.githubusercontent.com/u/1079135?v=3","gravatar_id":"","url":"https://api.github.com/users/harianus","html_url":"https://github.com/harianus","followers_url":"https://api.github.com/users/harianus/followers","following_url":"https://api.github.com/users/harianus/following{/other_user}","gists_url":"https://api.github.com/users/harianus/gists{/gist_id}","starred_url":"https://api.github.com/users/harianus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/harianus/subscriptions","organizations_url":"https://api.github.com/users/harianus/orgs","repos_url":"https://api.github.com/users/harianus/repos","events_url":"https://api.github.com/users/harianus/events{/privacy}","received_events_url":"https://api.github.com/users/harianus/received_events","type":"User","site_admin":false},"body":"Source should be `backend_csharp`","created_at":"2017-01-18T18:13:57Z","updated_at":"2017-01-18T18:14:40Z","html_url":"https://github.com/mgmco/clients.membergetmember.co/pull/9#discussion_r96698669","pull_request_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/pulls/9","_links":{"self":{"href":"https://api.github.com/repos/mgmco/clients.membergetmember.co/pulls/comments/96698669"},"html":{"href":"https://github.com/mgmco/clients.membergetmember.co/pull/9#discussion_r96698669"},"pull_request":{"href":"https://api.github.com/repos/mgmco/clients.membergetmember.co/pulls/9"}}},"pull_request":{"url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/pulls/9","id":102080911,"html_url":"https://github.com/mgmco/clients.membergetmember.co/pull/9","diff_url":"https://github.com/mgmco/clients.membergetmember.co/pull/9.diff","patch_url":"https://github.com/mgmco/clients.membergetmember.co/pull/9.patch","issue_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/issues/9","number":9,"state":"open","locked":false,"title":"Update code snippets","user":{"login":"chrissvo","id":2834982,"avatar_url":"https://avatars.githubusercontent.com/u/2834982?v=3","gravatar_id":"","url":"https://api.github.com/users/chrissvo","html_url":"https://github.com/chrissvo","followers_url":"https://api.github.com/users/chrissvo/followers","following_url":"https://api.github.com/users/chrissvo/following{/other_user}","gists_url":"https://api.github.com/users/chrissvo/gists{/gist_id}","starred_url":"https://api.github.com/users/chrissvo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chrissvo/subscriptions","organizations_url":"https://api.github.com/users/chrissvo/orgs","repos_url":"https://api.github.com/users/chrissvo/repos","events_url":"https://api.github.com/users/chrissvo/events{/privacy}","received_events_url":"https://api.github.com/users/chrissvo/received_events","type":"User","site_admin":false},"body":"Fixes: https://github.com/mgmco/bugs/issues/2338\r\n\r\nChanges proposed in this pull request:\r\n * TSIA\r\n\r\ncc @mgmco/developers\r\n","created_at":"2017-01-18T14:55:47Z","updated_at":"2017-01-18T18:14:40Z","closed_at":null,"merged_at":null,"merge_commit_sha":"be1d93995dbf769589983e8e2d27d36319089c66","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/pulls/9/commits","review_comments_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/pulls/9/comments","review_comment_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/pulls/comments{/number}","comments_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/issues/9/comments","statuses_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/statuses/296e114a75c423ccf29d1ad5d2a70b6fe2a604c9","head":{"label":"mgmco:update-snippets","ref":"update-snippets","sha":"296e114a75c423ccf29d1ad5d2a70b6fe2a604c9","user":{"login":"mgmco","id":1814640,"avatar_url":"https://avatars.githubusercontent.com/u/1814640?v=3","gravatar_id":"","url":"https://api.github.com/users/mgmco","html_url":"https://github.com/mgmco","followers_url":"https://api.github.com/users/mgmco/followers","following_url":"https://api.github.com/users/mgmco/following{/other_user}","gists_url":"https://api.github.com/users/mgmco/gists{/gist_id}","starred_url":"https://api.github.com/users/mgmco/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mgmco/subscriptions","organizations_url":"https://api.github.com/users/mgmco/orgs","repos_url":"https://api.github.com/users/mgmco/repos","events_url":"https://api.github.com/users/mgmco/events{/privacy}","received_events_url":"https://api.github.com/users/mgmco/received_events","type":"Organization","site_admin":false},"repo":{"id":41682373,"name":"clients.membergetmember.co","full_name":"mgmco/clients.membergetmember.co","owner":{"login":"mgmco","id":1814640,"avatar_url":"https://avatars.githubusercontent.com/u/1814640?v=3","gravatar_id":"","url":"https://api.github.com/users/mgmco","html_url":"https://github.com/mgmco","followers_url":"https://api.github.com/users/mgmco/followers","following_url":"https://api.github.com/users/mgmco/following{/other_user}","gists_url":"https://api.github.com/users/mgmco/gists{/gist_id}","starred_url":"https://api.github.com/users/mgmco/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mgmco/subscriptions","organizations_url":"https://api.github.com/users/mgmco/orgs","repos_url":"https://api.github.com/users/mgmco/repos","events_url":"https://api.github.com/users/mgmco/events{/privacy}","received_events_url":"https://api.github.com/users/mgmco/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/mgmco/clients.membergetmember.co","description":"Documentation for our clients","fork":false,"url":"https://api.github.com/repos/mgmco/clients.membergetmember.co","forks_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/forks","keys_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/teams","hooks_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/hooks","issue_events_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/issues/events{/number}","events_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/events","assignees_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/assignees{/user}","branches_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/branches{/branch}","tags_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/tags","blobs_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/git/refs{/sha}","trees_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/statuses/{sha}","languages_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/languages","stargazers_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/stargazers","contributors_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/contributors","subscribers_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/subscribers","subscription_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/subscription","commits_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/commits{/sha}","git_commits_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/git/commits{/sha}","comments_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/comments{/number}","issue_comment_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/issues/comments{/number}","contents_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/contents/{+path}","compare_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/merges","archive_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/downloads","issues_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/issues{/number}","pulls_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/pulls{/number}","milestones_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/milestones{/number}","notifications_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/labels{/name}","releases_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/releases{/id}","deployments_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/deployments","created_at":"2015-08-31T15:08:01Z","updated_at":"2016-10-24T08:22:54Z","pushed_at":"2017-01-18T15:06:07Z","git_url":"git://github.com/mgmco/clients.membergetmember.co.git","ssh_url":"git@github.com:mgmco/clients.membergetmember.co.git","clone_url":"https://github.com/mgmco/clients.membergetmember.co.git","svn_url":"https://github.com/mgmco/clients.membergetmember.co","homepage":"https://clients.membergetmember.co","size":1414,"stargazers_count":0,"watchers_count":0,"language":"CSS","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":true,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"gh-pages"}},"base":{"label":"mgmco:gh-pages","ref":"gh-pages","sha":"e95aa688140360ee06c7c8034c6dabb8dc81fcbb","user":{"login":"mgmco","id":1814640,"avatar_url":"https://avatars.githubusercontent.com/u/1814640?v=3","gravatar_id":"","url":"https://api.github.com/users/mgmco","html_url":"https://github.com/mgmco","followers_url":"https://api.github.com/users/mgmco/followers","following_url":"https://api.github.com/users/mgmco/following{/other_user}","gists_url":"https://api.github.com/users/mgmco/gists{/gist_id}","starred_url":"https://api.github.com/users/mgmco/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mgmco/subscriptions","organizations_url":"https://api.github.com/users/mgmco/orgs","repos_url":"https://api.github.com/users/mgmco/repos","events_url":"https://api.github.com/users/mgmco/events{/privacy}","received_events_url":"https://api.github.com/users/mgmco/received_events","type":"Organization","site_admin":false},"repo":{"id":41682373,"name":"clients.membergetmember.co","full_name":"mgmco/clients.membergetmember.co","owner":{"login":"mgmco","id":1814640,"avatar_url":"https://avatars.githubusercontent.com/u/1814640?v=3","gravatar_id":"","url":"https://api.github.com/users/mgmco","html_url":"https://github.com/mgmco","followers_url":"https://api.github.com/users/mgmco/followers","following_url":"https://api.github.com/users/mgmco/following{/other_user}","gists_url":"https://api.github.com/users/mgmco/gists{/gist_id}","starred_url":"https://api.github.com/users/mgmco/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mgmco/subscriptions","organizations_url":"https://api.github.com/users/mgmco/orgs","repos_url":"https://api.github.com/users/mgmco/repos","events_url":"https://api.github.com/users/mgmco/events{/privacy}","received_events_url":"https://api.github.com/users/mgmco/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/mgmco/clients.membergetmember.co","description":"Documentation for our clients","fork":false,"url":"https://api.github.com/repos/mgmco/clients.membergetmember.co","forks_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/forks","keys_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/teams","hooks_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/hooks","issue_events_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/issues/events{/number}","events_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/events","assignees_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/assignees{/user}","branches_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/branches{/branch}","tags_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/tags","blobs_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/git/refs{/sha}","trees_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/statuses/{sha}","languages_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/languages","stargazers_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/stargazers","contributors_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/contributors","subscribers_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/subscribers","subscription_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/subscription","commits_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/commits{/sha}","git_commits_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/git/commits{/sha}","comments_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/comments{/number}","issue_comment_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/issues/comments{/number}","contents_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/contents/{+path}","compare_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/merges","archive_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/downloads","issues_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/issues{/number}","pulls_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/pulls{/number}","milestones_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/milestones{/number}","notifications_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/labels{/name}","releases_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/releases{/id}","deployments_url":"https://api.github.com/repos/mgmco/clients.membergetmember.co/deployments","created_at":"2015-08-31T15:08:01Z","updated_at":"2016-10-24T08:22:54Z","pushed_at":"2017-01-18T15:06:07Z","git_url":"git://github.com/mgmco/clients.membergetmember.co.git","ssh_url":"git@github.com:mgmco/clients.membergetmember.co.git","clone_url":"https://github.com/mgmco/clients.membergetmember.co.git","svn_url":"https://github.com/mgmco/clients.membergetmember.co","homepage":"https://clients.membergetmember.co","size":1414,"stargazers_count":0,"watchers_count":0,"language":"CSS","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":true,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"gh-pages"}},"_links":{"self":{"href":"https://api.github.com/repos/mgmco/clients.membergetmember.co/pulls/9"},"html":{"href":"https://github.com/mgmco/clients.membergetmember.co/pull/9"},"issue":{"href":"https://api.github.com/repos/mgmco/clients.membergetmember.co/issues/9"},"comments":{"href":"https://api.github.com/repos/mgmco/clients.membergetmember.co/issues/9/comments"},"review_comments":{"href":"https://api.github.com/repos/mgmco/clients.membergetmember.co/pulls/9/comments"},"review_comment":{"href":"https://api.github.com/repos/mgmco/clients.membergetmember.co/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/mgmco/clients.membergetmember.co/pulls/9/commits"},"statuses":{"href":"https://api.github.com/repos/mgmco/clients.membergetmember.co/statuses/296e114a75c423ccf29d1ad5d2a70b6fe2a604c9"}}}}
{"actor":{"display_login":"harianus"}}