{"action":"created","comment":{"url":"https://api.github.com/repos/fyler/fylerx/pulls/comments/57847322","id":57847322,"diff_hunk":"@@ -0,0 +1,22 @@\n+defmodule Fyler.Api.TasksController do\n+  use Fyler.Web, :controller\n+\n+  alias Fyler.Task\n+\n+  def show(conn, %{\"id\" => id}) do\n+    render conn, \"show.json\", data: Repo.get!(Task, id)\n+  end\n+\n+  def create(conn, %{\"task\" => params}) do\n+    changeset = Task.create_changeset(%Task{}, params)\n+    \n+    case Repo.insert(changeset) do\n+      {:ok, task} ->\n+        render conn, \"create.json\", data: task","path":"web/controllers/api/tasks_controller.ex","position":15,"original_position":15,"commit_id":"88d8c8cb1b1657852948c6a4cc166f51deffb267","original_commit_id":"88d8c8cb1b1657852948c6a4cc166f51deffb267","user":{"login":"palkan","id":1516722,"avatar_url":"https://avatars.githubusercontent.com/u/1516722?v=3","gravatar_id":"","url":"https://api.github.com/users/palkan","html_url":"https://github.com/palkan","followers_url":"https://api.github.com/users/palkan/followers","following_url":"https://api.github.com/users/palkan/following{/other_user}","gists_url":"https://api.github.com/users/palkan/gists{/gist_id}","starred_url":"https://api.github.com/users/palkan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/palkan/subscriptions","organizations_url":"https://api.github.com/users/palkan/orgs","repos_url":"https://api.github.com/users/palkan/repos","events_url":"https://api.github.com/users/palkan/events{/privacy}","received_events_url":"https://api.github.com/users/palkan/received_events","type":"User","site_admin":false},"body":"Здесь в ответе нужно передавать только id задачи ([доки](https://docs.google.com/document/d/1X9zRoYQEDkW1CTjcOJZJf4HtfJ38JAAdLM_k6gVez74/edit#heading=h.itznhcd6ijg6)).","created_at":"2016-03-30T07:37:22Z","updated_at":"2016-03-30T07:37:22Z","html_url":"https://github.com/fyler/fylerx/pull/4#discussion_r57847322","pull_request_url":"https://api.github.com/repos/fyler/fylerx/pulls/4","_links":{"self":{"href":"https://api.github.com/repos/fyler/fylerx/pulls/comments/57847322"},"html":{"href":"https://github.com/fyler/fylerx/pull/4#discussion_r57847322"},"pull_request":{"href":"https://api.github.com/repos/fyler/fylerx/pulls/4"}}},"pull_request":{"url":"https://api.github.com/repos/fyler/fylerx/pulls/4","id":64491674,"html_url":"https://github.com/fyler/fylerx/pull/4","diff_url":"https://github.com/fyler/fylerx/pull/4.diff","patch_url":"https://github.com/fyler/fylerx/pull/4.patch","issue_url":"https://api.github.com/repos/fyler/fylerx/issues/4","number":4,"state":"open","locked":false,"title":"Add Tasks controller and tests for Admin and Api scopes","user":{"login":"alekseenkoss77","id":2551688,"avatar_url":"https://avatars.githubusercontent.com/u/2551688?v=3","gravatar_id":"","url":"https://api.github.com/users/alekseenkoss77","html_url":"https://github.com/alekseenkoss77","followers_url":"https://api.github.com/users/alekseenkoss77/followers","following_url":"https://api.github.com/users/alekseenkoss77/following{/other_user}","gists_url":"https://api.github.com/users/alekseenkoss77/gists{/gist_id}","starred_url":"https://api.github.com/users/alekseenkoss77/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alekseenkoss77/subscriptions","organizations_url":"https://api.github.com/users/alekseenkoss77/orgs","repos_url":"https://api.github.com/users/alekseenkoss77/repos","events_url":"https://api.github.com/users/alekseenkoss77/events{/privacy}","received_events_url":"https://api.github.com/users/alekseenkoss77/received_events","type":"User","site_admin":false},"body":"","created_at":"2016-03-29T16:13:27Z","updated_at":"2016-03-30T07:37:22Z","closed_at":null,"merged_at":null,"merge_commit_sha":"fc0acb841236019020319060c3a70f243d5da4ba","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/fyler/fylerx/pulls/4/commits","review_comments_url":"https://api.github.com/repos/fyler/fylerx/pulls/4/comments","review_comment_url":"https://api.github.com/repos/fyler/fylerx/pulls/comments{/number}","comments_url":"https://api.github.com/repos/fyler/fylerx/issues/4/comments","statuses_url":"https://api.github.com/repos/fyler/fylerx/statuses/88d8c8cb1b1657852948c6a4cc166f51deffb267","head":{"label":"fyler:tasks-controller","ref":"tasks-controller","sha":"88d8c8cb1b1657852948c6a4cc166f51deffb267","user":{"login":"fyler","id":8720842,"avatar_url":"https://avatars.githubusercontent.com/u/8720842?v=3","gravatar_id":"","url":"https://api.github.com/users/fyler","html_url":"https://github.com/fyler","followers_url":"https://api.github.com/users/fyler/followers","following_url":"https://api.github.com/users/fyler/following{/other_user}","gists_url":"https://api.github.com/users/fyler/gists{/gist_id}","starred_url":"https://api.github.com/users/fyler/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fyler/subscriptions","organizations_url":"https://api.github.com/users/fyler/orgs","repos_url":"https://api.github.com/users/fyler/repos","events_url":"https://api.github.com/users/fyler/events{/privacy}","received_events_url":"https://api.github.com/users/fyler/received_events","type":"Organization","site_admin":false},"repo":{"id":51436279,"name":"fylerx","full_name":"fyler/fylerx","owner":{"login":"fyler","id":8720842,"avatar_url":"https://avatars.githubusercontent.com/u/8720842?v=3","gravatar_id":"","url":"https://api.github.com/users/fyler","html_url":"https://github.com/fyler","followers_url":"https://api.github.com/users/fyler/followers","following_url":"https://api.github.com/users/fyler/following{/other_user}","gists_url":"https://api.github.com/users/fyler/gists{/gist_id}","starred_url":"https://api.github.com/users/fyler/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fyler/subscriptions","organizations_url":"https://api.github.com/users/fyler/orgs","repos_url":"https://api.github.com/users/fyler/repos","events_url":"https://api.github.com/users/fyler/events{/privacy}","received_events_url":"https://api.github.com/users/fyler/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/fyler/fylerx","description":"Fyler 2.0 API server","fork":false,"url":"https://api.github.com/repos/fyler/fylerx","forks_url":"https://api.github.com/repos/fyler/fylerx/forks","keys_url":"https://api.github.com/repos/fyler/fylerx/keys{/key_id}","collaborators_url":"https://api.github.com/repos/fyler/fylerx/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/fyler/fylerx/teams","hooks_url":"https://api.github.com/repos/fyler/fylerx/hooks","issue_events_url":"https://api.github.com/repos/fyler/fylerx/issues/events{/number}","events_url":"https://api.github.com/repos/fyler/fylerx/events","assignees_url":"https://api.github.com/repos/fyler/fylerx/assignees{/user}","branches_url":"https://api.github.com/repos/fyler/fylerx/branches{/branch}","tags_url":"https://api.github.com/repos/fyler/fylerx/tags","blobs_url":"https://api.github.com/repos/fyler/fylerx/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/fyler/fylerx/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/fyler/fylerx/git/refs{/sha}","trees_url":"https://api.github.com/repos/fyler/fylerx/git/trees{/sha}","statuses_url":"https://api.github.com/repos/fyler/fylerx/statuses/{sha}","languages_url":"https://api.github.com/repos/fyler/fylerx/languages","stargazers_url":"https://api.github.com/repos/fyler/fylerx/stargazers","contributors_url":"https://api.github.com/repos/fyler/fylerx/contributors","subscribers_url":"https://api.github.com/repos/fyler/fylerx/subscribers","subscription_url":"https://api.github.com/repos/fyler/fylerx/subscription","commits_url":"https://api.github.com/repos/fyler/fylerx/commits{/sha}","git_commits_url":"https://api.github.com/repos/fyler/fylerx/git/commits{/sha}","comments_url":"https://api.github.com/repos/fyler/fylerx/comments{/number}","issue_comment_url":"https://api.github.com/repos/fyler/fylerx/issues/comments{/number}","contents_url":"https://api.github.com/repos/fyler/fylerx/contents/{+path}","compare_url":"https://api.github.com/repos/fyler/fylerx/compare/{base}...{head}","merges_url":"https://api.github.com/repos/fyler/fylerx/merges","archive_url":"https://api.github.com/repos/fyler/fylerx/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/fyler/fylerx/downloads","issues_url":"https://api.github.com/repos/fyler/fylerx/issues{/number}","pulls_url":"https://api.github.com/repos/fyler/fylerx/pulls{/number}","milestones_url":"https://api.github.com/repos/fyler/fylerx/milestones{/number}","notifications_url":"https://api.github.com/repos/fyler/fylerx/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/fyler/fylerx/labels{/name}","releases_url":"https://api.github.com/repos/fyler/fylerx/releases{/id}","deployments_url":"https://api.github.com/repos/fyler/fylerx/deployments","created_at":"2016-02-10T11:08:19Z","updated_at":"2016-02-10T11:10:30Z","pushed_at":"2016-03-29T16:13:27Z","git_url":"git://github.com/fyler/fylerx.git","ssh_url":"git@github.com:fyler/fylerx.git","clone_url":"https://github.com/fyler/fylerx.git","svn_url":"https://github.com/fyler/fylerx","homepage":"","size":37,"stargazers_count":0,"watchers_count":0,"language":"Elixir","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"fyler:master","ref":"master","sha":"bec3a58e4c56234d21fde3a20d689e9feca1b5cf","user":{"login":"fyler","id":8720842,"avatar_url":"https://avatars.githubusercontent.com/u/8720842?v=3","gravatar_id":"","url":"https://api.github.com/users/fyler","html_url":"https://github.com/fyler","followers_url":"https://api.github.com/users/fyler/followers","following_url":"https://api.github.com/users/fyler/following{/other_user}","gists_url":"https://api.github.com/users/fyler/gists{/gist_id}","starred_url":"https://api.github.com/users/fyler/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fyler/subscriptions","organizations_url":"https://api.github.com/users/fyler/orgs","repos_url":"https://api.github.com/users/fyler/repos","events_url":"https://api.github.com/users/fyler/events{/privacy}","received_events_url":"https://api.github.com/users/fyler/received_events","type":"Organization","site_admin":false},"repo":{"id":51436279,"name":"fylerx","full_name":"fyler/fylerx","owner":{"login":"fyler","id":8720842,"avatar_url":"https://avatars.githubusercontent.com/u/8720842?v=3","gravatar_id":"","url":"https://api.github.com/users/fyler","html_url":"https://github.com/fyler","followers_url":"https://api.github.com/users/fyler/followers","following_url":"https://api.github.com/users/fyler/following{/other_user}","gists_url":"https://api.github.com/users/fyler/gists{/gist_id}","starred_url":"https://api.github.com/users/fyler/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fyler/subscriptions","organizations_url":"https://api.github.com/users/fyler/orgs","repos_url":"https://api.github.com/users/fyler/repos","events_url":"https://api.github.com/users/fyler/events{/privacy}","received_events_url":"https://api.github.com/users/fyler/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/fyler/fylerx","description":"Fyler 2.0 API server","fork":false,"url":"https://api.github.com/repos/fyler/fylerx","forks_url":"https://api.github.com/repos/fyler/fylerx/forks","keys_url":"https://api.github.com/repos/fyler/fylerx/keys{/key_id}","collaborators_url":"https://api.github.com/repos/fyler/fylerx/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/fyler/fylerx/teams","hooks_url":"https://api.github.com/repos/fyler/fylerx/hooks","issue_events_url":"https://api.github.com/repos/fyler/fylerx/issues/events{/number}","events_url":"https://api.github.com/repos/fyler/fylerx/events","assignees_url":"https://api.github.com/repos/fyler/fylerx/assignees{/user}","branches_url":"https://api.github.com/repos/fyler/fylerx/branches{/branch}","tags_url":"https://api.github.com/repos/fyler/fylerx/tags","blobs_url":"https://api.github.com/repos/fyler/fylerx/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/fyler/fylerx/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/fyler/fylerx/git/refs{/sha}","trees_url":"https://api.github.com/repos/fyler/fylerx/git/trees{/sha}","statuses_url":"https://api.github.com/repos/fyler/fylerx/statuses/{sha}","languages_url":"https://api.github.com/repos/fyler/fylerx/languages","stargazers_url":"https://api.github.com/repos/fyler/fylerx/stargazers","contributors_url":"https://api.github.com/repos/fyler/fylerx/contributors","subscribers_url":"https://api.github.com/repos/fyler/fylerx/subscribers","subscription_url":"https://api.github.com/repos/fyler/fylerx/subscription","commits_url":"https://api.github.com/repos/fyler/fylerx/commits{/sha}","git_commits_url":"https://api.github.com/repos/fyler/fylerx/git/commits{/sha}","comments_url":"https://api.github.com/repos/fyler/fylerx/comments{/number}","issue_comment_url":"https://api.github.com/repos/fyler/fylerx/issues/comments{/number}","contents_url":"https://api.github.com/repos/fyler/fylerx/contents/{+path}","compare_url":"https://api.github.com/repos/fyler/fylerx/compare/{base}...{head}","merges_url":"https://api.github.com/repos/fyler/fylerx/merges","archive_url":"https://api.github.com/repos/fyler/fylerx/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/fyler/fylerx/downloads","issues_url":"https://api.github.com/repos/fyler/fylerx/issues{/number}","pulls_url":"https://api.github.com/repos/fyler/fylerx/pulls{/number}","milestones_url":"https://api.github.com/repos/fyler/fylerx/milestones{/number}","notifications_url":"https://api.github.com/repos/fyler/fylerx/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/fyler/fylerx/labels{/name}","releases_url":"https://api.github.com/repos/fyler/fylerx/releases{/id}","deployments_url":"https://api.github.com/repos/fyler/fylerx/deployments","created_at":"2016-02-10T11:08:19Z","updated_at":"2016-02-10T11:10:30Z","pushed_at":"2016-03-29T16:13:27Z","git_url":"git://github.com/fyler/fylerx.git","ssh_url":"git@github.com:fyler/fylerx.git","clone_url":"https://github.com/fyler/fylerx.git","svn_url":"https://github.com/fyler/fylerx","homepage":"","size":37,"stargazers_count":0,"watchers_count":0,"language":"Elixir","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/fyler/fylerx/pulls/4"},"html":{"href":"https://github.com/fyler/fylerx/pull/4"},"issue":{"href":"https://api.github.com/repos/fyler/fylerx/issues/4"},"comments":{"href":"https://api.github.com/repos/fyler/fylerx/issues/4/comments"},"review_comments":{"href":"https://api.github.com/repos/fyler/fylerx/pulls/4/comments"},"review_comment":{"href":"https://api.github.com/repos/fyler/fylerx/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/fyler/fylerx/pulls/4/commits"},"statuses":{"href":"https://api.github.com/repos/fyler/fylerx/statuses/88d8c8cb1b1657852948c6a4cc166f51deffb267"}}}}