{"action":"created","comment":{"url":"https://api.github.com/repos/edx/cs_comments_service/pulls/comments/35238764","id":35238764,"diff_hunk":"@@ -34,6 +35,10 @@\n   if params[\"group_id\"]\n     thread.group_id = params[\"group_id\"]\n   end\n+\n+  if params[\"context\"]","path":"api/commentables.rb","position":15,"original_position":15,"commit_id":"1085c48a7a773577a71275a18ae0ccaf8568b131","original_commit_id":"1085c48a7a773577a71275a18ae0ccaf8568b131","user":{"login":"benmcmorran","id":6981284,"avatar_url":"https://avatars.githubusercontent.com/u/6981284?v=3","gravatar_id":"","url":"https://api.github.com/users/benmcmorran","html_url":"https://github.com/benmcmorran","followers_url":"https://api.github.com/users/benmcmorran/followers","following_url":"https://api.github.com/users/benmcmorran/following{/other_user}","gists_url":"https://api.github.com/users/benmcmorran/gists{/gist_id}","starred_url":"https://api.github.com/users/benmcmorran/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/benmcmorran/subscriptions","organizations_url":"https://api.github.com/users/benmcmorran/orgs","repos_url":"https://api.github.com/users/benmcmorran/repos","events_url":"https://api.github.com/users/benmcmorran/events{/privacy}","received_events_url":"https://api.github.com/users/benmcmorran/received_events","type":"User","site_admin":false},"body":"Yes, https://github.com/edx/cs_comments_service/blob/benmcmorran/team-discussions/models/comment_thread.rb#L14","created_at":"2015-07-22T17:21:37Z","updated_at":"2015-07-22T17:21:37Z","html_url":"https://github.com/edx/cs_comments_service/pull/131#discussion_r35238764","pull_request_url":"https://api.github.com/repos/edx/cs_comments_service/pulls/131","_links":{"self":{"href":"https://api.github.com/repos/edx/cs_comments_service/pulls/comments/35238764"},"html":{"href":"https://github.com/edx/cs_comments_service/pull/131#discussion_r35238764"},"pull_request":{"href":"https://api.github.com/repos/edx/cs_comments_service/pulls/131"}}},"pull_request":{"url":"https://api.github.com/repos/edx/cs_comments_service/pulls/131","id":40378685,"html_url":"https://github.com/edx/cs_comments_service/pull/131","diff_url":"https://github.com/edx/cs_comments_service/pull/131.diff","patch_url":"https://github.com/edx/cs_comments_service/pull/131.patch","issue_url":"https://api.github.com/repos/edx/cs_comments_service/issues/131","number":131,"state":"open","locked":false,"title":"TNL-1943 Add context field to CommentThread","user":{"login":"benmcmorran","id":6981284,"avatar_url":"https://avatars.githubusercontent.com/u/6981284?v=3","gravatar_id":"","url":"https://api.github.com/users/benmcmorran","html_url":"https://github.com/benmcmorran","followers_url":"https://api.github.com/users/benmcmorran/followers","following_url":"https://api.github.com/users/benmcmorran/following{/other_user}","gists_url":"https://api.github.com/users/benmcmorran/gists{/gist_id}","starred_url":"https://api.github.com/users/benmcmorran/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/benmcmorran/subscriptions","organizations_url":"https://api.github.com/users/benmcmorran/orgs","repos_url":"https://api.github.com/users/benmcmorran/repos","events_url":"https://api.github.com/users/benmcmorran/events{/privacy}","received_events_url":"https://api.github.com/users/benmcmorran/received_events","type":"User","site_admin":false},"body":"This PR introduces a `context` field on the `CommentThread` model. Currently, context can be `course` or `standalone`. `course` is the normal value, and indicates that the thread is part of general course discussions. `standalone` indicates that the thread is separate from general course discussion and should only be returned if explicitly requested. Context can be specified when creating threads associated with commentables by passing an extra parameter. Context can also be specified when retrieving threads associated with a commentable by passing a parameter. https://github.com/edx/edx-platform/pull/8982 uses this field.\r\n\r\n@cahrens @dan-f please review.","created_at":"2015-07-20T17:52:57Z","updated_at":"2015-07-22T17:21:37Z","closed_at":null,"merged_at":null,"merge_commit_sha":"7aff512fb3a5b4e668ad3dcccc0b79660d1bb706","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/edx/cs_comments_service/pulls/131/commits","review_comments_url":"https://api.github.com/repos/edx/cs_comments_service/pulls/131/comments","review_comment_url":"https://api.github.com/repos/edx/cs_comments_service/pulls/comments{/number}","comments_url":"https://api.github.com/repos/edx/cs_comments_service/issues/131/comments","statuses_url":"https://api.github.com/repos/edx/cs_comments_service/statuses/1085c48a7a773577a71275a18ae0ccaf8568b131","head":{"label":"edx:benmcmorran/team-discussions","ref":"benmcmorran/team-discussions","sha":"1085c48a7a773577a71275a18ae0ccaf8568b131","user":{"login":"edx","id":3179841,"avatar_url":"https://avatars.githubusercontent.com/u/3179841?v=3","gravatar_id":"","url":"https://api.github.com/users/edx","html_url":"https://github.com/edx","followers_url":"https://api.github.com/users/edx/followers","following_url":"https://api.github.com/users/edx/following{/other_user}","gists_url":"https://api.github.com/users/edx/gists{/gist_id}","starred_url":"https://api.github.com/users/edx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/edx/subscriptions","organizations_url":"https://api.github.com/users/edx/orgs","repos_url":"https://api.github.com/users/edx/repos","events_url":"https://api.github.com/users/edx/events{/privacy}","received_events_url":"https://api.github.com/users/edx/received_events","type":"Organization","site_admin":false},"repo":{"id":4732120,"name":"cs_comments_service","full_name":"edx/cs_comments_service","owner":{"login":"edx","id":3179841,"avatar_url":"https://avatars.githubusercontent.com/u/3179841?v=3","gravatar_id":"","url":"https://api.github.com/users/edx","html_url":"https://github.com/edx","followers_url":"https://api.github.com/users/edx/followers","following_url":"https://api.github.com/users/edx/following{/other_user}","gists_url":"https://api.github.com/users/edx/gists{/gist_id}","starred_url":"https://api.github.com/users/edx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/edx/subscriptions","organizations_url":"https://api.github.com/users/edx/orgs","repos_url":"https://api.github.com/users/edx/repos","events_url":"https://api.github.com/users/edx/events{/privacy}","received_events_url":"https://api.github.com/users/edx/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/edx/cs_comments_service","description":"server side of the comment service","fork":false,"url":"https://api.github.com/repos/edx/cs_comments_service","forks_url":"https://api.github.com/repos/edx/cs_comments_service/forks","keys_url":"https://api.github.com/repos/edx/cs_comments_service/keys{/key_id}","collaborators_url":"https://api.github.com/repos/edx/cs_comments_service/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/edx/cs_comments_service/teams","hooks_url":"https://api.github.com/repos/edx/cs_comments_service/hooks","issue_events_url":"https://api.github.com/repos/edx/cs_comments_service/issues/events{/number}","events_url":"https://api.github.com/repos/edx/cs_comments_service/events","assignees_url":"https://api.github.com/repos/edx/cs_comments_service/assignees{/user}","branches_url":"https://api.github.com/repos/edx/cs_comments_service/branches{/branch}","tags_url":"https://api.github.com/repos/edx/cs_comments_service/tags","blobs_url":"https://api.github.com/repos/edx/cs_comments_service/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/edx/cs_comments_service/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/edx/cs_comments_service/git/refs{/sha}","trees_url":"https://api.github.com/repos/edx/cs_comments_service/git/trees{/sha}","statuses_url":"https://api.github.com/repos/edx/cs_comments_service/statuses/{sha}","languages_url":"https://api.github.com/repos/edx/cs_comments_service/languages","stargazers_url":"https://api.github.com/repos/edx/cs_comments_service/stargazers","contributors_url":"https://api.github.com/repos/edx/cs_comments_service/contributors","subscribers_url":"https://api.github.com/repos/edx/cs_comments_service/subscribers","subscription_url":"https://api.github.com/repos/edx/cs_comments_service/subscription","commits_url":"https://api.github.com/repos/edx/cs_comments_service/commits{/sha}","git_commits_url":"https://api.github.com/repos/edx/cs_comments_service/git/commits{/sha}","comments_url":"https://api.github.com/repos/edx/cs_comments_service/comments{/number}","issue_comment_url":"https://api.github.com/repos/edx/cs_comments_service/issues/comments{/number}","contents_url":"https://api.github.com/repos/edx/cs_comments_service/contents/{+path}","compare_url":"https://api.github.com/repos/edx/cs_comments_service/compare/{base}...{head}","merges_url":"https://api.github.com/repos/edx/cs_comments_service/merges","archive_url":"https://api.github.com/repos/edx/cs_comments_service/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/edx/cs_comments_service/downloads","issues_url":"https://api.github.com/repos/edx/cs_comments_service/issues{/number}","pulls_url":"https://api.github.com/repos/edx/cs_comments_service/pulls{/number}","milestones_url":"https://api.github.com/repos/edx/cs_comments_service/milestones{/number}","notifications_url":"https://api.github.com/repos/edx/cs_comments_service/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/edx/cs_comments_service/labels{/name}","releases_url":"https://api.github.com/repos/edx/cs_comments_service/releases{/id}","created_at":"2012-06-20T22:12:04Z","updated_at":"2015-05-09T08:33:12Z","pushed_at":"2015-07-21T15:01:51Z","git_url":"git://github.com/edx/cs_comments_service.git","ssh_url":"git@github.com:edx/cs_comments_service.git","clone_url":"https://github.com/edx/cs_comments_service.git","svn_url":"https://github.com/edx/cs_comments_service","homepage":null,"size":3243,"stargazers_count":22,"watchers_count":22,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":59,"mirror_url":null,"open_issues_count":5,"forks":59,"open_issues":5,"watchers":22,"default_branch":"master"}},"base":{"label":"edx:master","ref":"master","sha":"8d83377b7d93b69eebe2baebad57e9119f45f141","user":{"login":"edx","id":3179841,"avatar_url":"https://avatars.githubusercontent.com/u/3179841?v=3","gravatar_id":"","url":"https://api.github.com/users/edx","html_url":"https://github.com/edx","followers_url":"https://api.github.com/users/edx/followers","following_url":"https://api.github.com/users/edx/following{/other_user}","gists_url":"https://api.github.com/users/edx/gists{/gist_id}","starred_url":"https://api.github.com/users/edx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/edx/subscriptions","organizations_url":"https://api.github.com/users/edx/orgs","repos_url":"https://api.github.com/users/edx/repos","events_url":"https://api.github.com/users/edx/events{/privacy}","received_events_url":"https://api.github.com/users/edx/received_events","type":"Organization","site_admin":false},"repo":{"id":4732120,"name":"cs_comments_service","full_name":"edx/cs_comments_service","owner":{"login":"edx","id":3179841,"avatar_url":"https://avatars.githubusercontent.com/u/3179841?v=3","gravatar_id":"","url":"https://api.github.com/users/edx","html_url":"https://github.com/edx","followers_url":"https://api.github.com/users/edx/followers","following_url":"https://api.github.com/users/edx/following{/other_user}","gists_url":"https://api.github.com/users/edx/gists{/gist_id}","starred_url":"https://api.github.com/users/edx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/edx/subscriptions","organizations_url":"https://api.github.com/users/edx/orgs","repos_url":"https://api.github.com/users/edx/repos","events_url":"https://api.github.com/users/edx/events{/privacy}","received_events_url":"https://api.github.com/users/edx/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/edx/cs_comments_service","description":"server side of the comment service","fork":false,"url":"https://api.github.com/repos/edx/cs_comments_service","forks_url":"https://api.github.com/repos/edx/cs_comments_service/forks","keys_url":"https://api.github.com/repos/edx/cs_comments_service/keys{/key_id}","collaborators_url":"https://api.github.com/repos/edx/cs_comments_service/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/edx/cs_comments_service/teams","hooks_url":"https://api.github.com/repos/edx/cs_comments_service/hooks","issue_events_url":"https://api.github.com/repos/edx/cs_comments_service/issues/events{/number}","events_url":"https://api.github.com/repos/edx/cs_comments_service/events","assignees_url":"https://api.github.com/repos/edx/cs_comments_service/assignees{/user}","branches_url":"https://api.github.com/repos/edx/cs_comments_service/branches{/branch}","tags_url":"https://api.github.com/repos/edx/cs_comments_service/tags","blobs_url":"https://api.github.com/repos/edx/cs_comments_service/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/edx/cs_comments_service/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/edx/cs_comments_service/git/refs{/sha}","trees_url":"https://api.github.com/repos/edx/cs_comments_service/git/trees{/sha}","statuses_url":"https://api.github.com/repos/edx/cs_comments_service/statuses/{sha}","languages_url":"https://api.github.com/repos/edx/cs_comments_service/languages","stargazers_url":"https://api.github.com/repos/edx/cs_comments_service/stargazers","contributors_url":"https://api.github.com/repos/edx/cs_comments_service/contributors","subscribers_url":"https://api.github.com/repos/edx/cs_comments_service/subscribers","subscription_url":"https://api.github.com/repos/edx/cs_comments_service/subscription","commits_url":"https://api.github.com/repos/edx/cs_comments_service/commits{/sha}","git_commits_url":"https://api.github.com/repos/edx/cs_comments_service/git/commits{/sha}","comments_url":"https://api.github.com/repos/edx/cs_comments_service/comments{/number}","issue_comment_url":"https://api.github.com/repos/edx/cs_comments_service/issues/comments{/number}","contents_url":"https://api.github.com/repos/edx/cs_comments_service/contents/{+path}","compare_url":"https://api.github.com/repos/edx/cs_comments_service/compare/{base}...{head}","merges_url":"https://api.github.com/repos/edx/cs_comments_service/merges","archive_url":"https://api.github.com/repos/edx/cs_comments_service/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/edx/cs_comments_service/downloads","issues_url":"https://api.github.com/repos/edx/cs_comments_service/issues{/number}","pulls_url":"https://api.github.com/repos/edx/cs_comments_service/pulls{/number}","milestones_url":"https://api.github.com/repos/edx/cs_comments_service/milestones{/number}","notifications_url":"https://api.github.com/repos/edx/cs_comments_service/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/edx/cs_comments_service/labels{/name}","releases_url":"https://api.github.com/repos/edx/cs_comments_service/releases{/id}","created_at":"2012-06-20T22:12:04Z","updated_at":"2015-05-09T08:33:12Z","pushed_at":"2015-07-21T15:01:51Z","git_url":"git://github.com/edx/cs_comments_service.git","ssh_url":"git@github.com:edx/cs_comments_service.git","clone_url":"https://github.com/edx/cs_comments_service.git","svn_url":"https://github.com/edx/cs_comments_service","homepage":null,"size":3243,"stargazers_count":22,"watchers_count":22,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":59,"mirror_url":null,"open_issues_count":5,"forks":59,"open_issues":5,"watchers":22,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/edx/cs_comments_service/pulls/131"},"html":{"href":"https://github.com/edx/cs_comments_service/pull/131"},"issue":{"href":"https://api.github.com/repos/edx/cs_comments_service/issues/131"},"comments":{"href":"https://api.github.com/repos/edx/cs_comments_service/issues/131/comments"},"review_comments":{"href":"https://api.github.com/repos/edx/cs_comments_service/pulls/131/comments"},"review_comment":{"href":"https://api.github.com/repos/edx/cs_comments_service/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/edx/cs_comments_service/pulls/131/commits"},"statuses":{"href":"https://api.github.com/repos/edx/cs_comments_service/statuses/1085c48a7a773577a71275a18ae0ccaf8568b131"}}}}