{"action":"created","comment":{"url":"https://api.github.com/repos/guardian/path-manager/pulls/comments/27019428","id":27019428,"diff_hunk":"@@ -15,121 +15,180 @@ Operations\n \n The path manager exposes the following operations:\n \n-/registerNewPath\n-----------------\n+Register a new path\n+-------------------\n \n-Accepts a POST request with ```path``` and ```system``` parameters. This operation will create a new path entry for the path\n+To register a new path issue a POST request with ```path``` and ```system``` parameters. This operation will create a new path entry for the path\n requested iff the the path is not currently in use. An id is also generated for to identify the object that the path links to,\n this id should be stored in the calling system for future operations (this is stored as the pageId in R2 and composer,\n replacing the previous pageId sequence in oracle).\n \n-If successful this operation will return a JSON response with the paths registered, These are indexed by path type.\n+If successful this operation will return an argo JSON response with the paths registered, These are indexed by path type.\n \n example:\n \n ```\n-    curl --data \"path=foo/bar/baz&system=test\" https://pathmanager.local.dev-gutools.co.uk/registerNewPath\n+    curl --data \"path=foo/bar/baz&system=test\" https://pathmanager.local.dev-gutools.co.uk/paths\n ```\n \n returns\n \n ```\n-    {\n-    \"canonical\":\n-      {\n-      \"path\":\"foo/bar/baz\",\n-      \"identifier\":2000051,\n-      \"type\":\"canonical\",\n-      \"system\":\"test\"\n-      },\n-    \"short\":\n-      {\n-      \"path\":\"simulatedShort/foo/bar/baz\",\n-      \"identifier\":2000051,\n-      \"type\":\"short\",\n-      \"system\":\"test\"\n-      }\n+    {data: \n+        {\"canonical\":\n+            [{\n+            \"path\":\"foo/bar/baz\",\n+            \"identifier\":2000051,\n+            \"type\":\"canonical\",\n+            \"system\":\"test\"\n+            }],\n+        \"short\":\n+            [{\n+            \"path\":\"simulatedShort/foo/bar/baz\",\n+            \"identifier\":2000051,\n+            \"type\":\"short\",\n+            \"system\":\"test\"\n+            }]","path":"readme.md","position":57,"original_position":57,"commit_id":"d8e2ccbd167afa0d1b9307bd1f766b2dcfa675f4","original_commit_id":"518824f1a1d39a168f12a1735bc2670a1151e05a","user":{"login":"theefer","id":36964,"avatar_url":"https://avatars.githubusercontent.com/u/36964?v=3","gravatar_id":"","url":"https://api.github.com/users/theefer","html_url":"https://github.com/theefer","followers_url":"https://api.github.com/users/theefer/followers","following_url":"https://api.github.com/users/theefer/following{/other_user}","gists_url":"https://api.github.com/users/theefer/gists{/gist_id}","starred_url":"https://api.github.com/users/theefer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/theefer/subscriptions","organizations_url":"https://api.github.com/users/theefer/orgs","repos_url":"https://api.github.com/users/theefer/repos","events_url":"https://api.github.com/users/theefer/events{/privacy}","received_events_url":"https://api.github.com/users/theefer/received_events","type":"User","site_admin":false},"body":"ping?","created_at":"2015-03-24T11:31:07Z","updated_at":"2015-03-24T11:31:07Z","html_url":"https://github.com/guardian/path-manager/pull/3#discussion_r27019428","pull_request_url":"https://api.github.com/repos/guardian/path-manager/pulls/3","_links":{"self":{"href":"https://api.github.com/repos/guardian/path-manager/pulls/comments/27019428"},"html":{"href":"https://github.com/guardian/path-manager/pull/3#discussion_r27019428"},"pull_request":{"href":"https://api.github.com/repos/guardian/path-manager/pulls/3"}}},"pull_request":{"url":"https://api.github.com/repos/guardian/path-manager/pulls/3","id":31632821,"html_url":"https://github.com/guardian/path-manager/pull/3","diff_url":"https://github.com/guardian/path-manager/pull/3.diff","patch_url":"https://github.com/guardian/path-manager/pull/3.patch","issue_url":"https://api.github.com/repos/guardian/path-manager/issues/3","number":3,"state":"closed","locked":false,"title":"Restify","user":{"login":"steppenwells","id":145254,"avatar_url":"https://avatars.githubusercontent.com/u/145254?v=3","gravatar_id":"","url":"https://api.github.com/users/steppenwells","html_url":"https://github.com/steppenwells","followers_url":"https://api.github.com/users/steppenwells/followers","following_url":"https://api.github.com/users/steppenwells/following{/other_user}","gists_url":"https://api.github.com/users/steppenwells/gists{/gist_id}","starred_url":"https://api.github.com/users/steppenwells/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/steppenwells/subscriptions","organizations_url":"https://api.github.com/users/steppenwells/orgs","repos_url":"https://api.github.com/users/steppenwells/repos","events_url":"https://api.github.com/users/steppenwells/events{/privacy}","received_events_url":"https://api.github.com/users/steppenwells/received_events","type":"User","site_admin":false},"body":"The path management API is now much more RESTful.\r\n\r\nalso adds delete support.","created_at":"2015-03-20T17:09:09Z","updated_at":"2015-03-24T11:31:07Z","closed_at":"2015-03-24T10:53:18Z","merged_at":"2015-03-24T10:53:18Z","merge_commit_sha":"272c1896d3264a1b99e0b30a511ca86c1b71996a","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/guardian/path-manager/pulls/3/commits","review_comments_url":"https://api.github.com/repos/guardian/path-manager/pulls/3/comments","review_comment_url":"https://api.github.com/repos/guardian/path-manager/pulls/comments{/number}","comments_url":"https://api.github.com/repos/guardian/path-manager/issues/3/comments","statuses_url":"https://api.github.com/repos/guardian/path-manager/statuses/d8e2ccbd167afa0d1b9307bd1f766b2dcfa675f4","head":{"label":"guardian:restify","ref":"restify","sha":"d8e2ccbd167afa0d1b9307bd1f766b2dcfa675f4","user":{"login":"guardian","id":164318,"avatar_url":"https://avatars.githubusercontent.com/u/164318?v=3","gravatar_id":"","url":"https://api.github.com/users/guardian","html_url":"https://github.com/guardian","followers_url":"https://api.github.com/users/guardian/followers","following_url":"https://api.github.com/users/guardian/following{/other_user}","gists_url":"https://api.github.com/users/guardian/gists{/gist_id}","starred_url":"https://api.github.com/users/guardian/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/guardian/subscriptions","organizations_url":"https://api.github.com/users/guardian/orgs","repos_url":"https://api.github.com/users/guardian/repos","events_url":"https://api.github.com/users/guardian/events{/privacy}","received_events_url":"https://api.github.com/users/guardian/received_events","type":"Organization","site_admin":false},"repo":{"id":32155769,"name":"path-manager","full_name":"guardian/path-manager","owner":{"login":"guardian","id":164318,"avatar_url":"https://avatars.githubusercontent.com/u/164318?v=3","gravatar_id":"","url":"https://api.github.com/users/guardian","html_url":"https://github.com/guardian","followers_url":"https://api.github.com/users/guardian/followers","following_url":"https://api.github.com/users/guardian/following{/other_user}","gists_url":"https://api.github.com/users/guardian/gists{/gist_id}","starred_url":"https://api.github.com/users/guardian/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/guardian/subscriptions","organizations_url":"https://api.github.com/users/guardian/orgs","repos_url":"https://api.github.com/users/guardian/repos","events_url":"https://api.github.com/users/guardian/events{/privacy}","received_events_url":"https://api.github.com/users/guardian/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/guardian/path-manager","description":"Service that manages paths for a domain. Ensures they are unique etc.","fork":false,"url":"https://api.github.com/repos/guardian/path-manager","forks_url":"https://api.github.com/repos/guardian/path-manager/forks","keys_url":"https://api.github.com/repos/guardian/path-manager/keys{/key_id}","collaborators_url":"https://api.github.com/repos/guardian/path-manager/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/guardian/path-manager/teams","hooks_url":"https://api.github.com/repos/guardian/path-manager/hooks","issue_events_url":"https://api.github.com/repos/guardian/path-manager/issues/events{/number}","events_url":"https://api.github.com/repos/guardian/path-manager/events","assignees_url":"https://api.github.com/repos/guardian/path-manager/assignees{/user}","branches_url":"https://api.github.com/repos/guardian/path-manager/branches{/branch}","tags_url":"https://api.github.com/repos/guardian/path-manager/tags","blobs_url":"https://api.github.com/repos/guardian/path-manager/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/guardian/path-manager/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/guardian/path-manager/git/refs{/sha}","trees_url":"https://api.github.com/repos/guardian/path-manager/git/trees{/sha}","statuses_url":"https://api.github.com/repos/guardian/path-manager/statuses/{sha}","languages_url":"https://api.github.com/repos/guardian/path-manager/languages","stargazers_url":"https://api.github.com/repos/guardian/path-manager/stargazers","contributors_url":"https://api.github.com/repos/guardian/path-manager/contributors","subscribers_url":"https://api.github.com/repos/guardian/path-manager/subscribers","subscription_url":"https://api.github.com/repos/guardian/path-manager/subscription","commits_url":"https://api.github.com/repos/guardian/path-manager/commits{/sha}","git_commits_url":"https://api.github.com/repos/guardian/path-manager/git/commits{/sha}","comments_url":"https://api.github.com/repos/guardian/path-manager/comments{/number}","issue_comment_url":"https://api.github.com/repos/guardian/path-manager/issues/comments{/number}","contents_url":"https://api.github.com/repos/guardian/path-manager/contents/{+path}","compare_url":"https://api.github.com/repos/guardian/path-manager/compare/{base}...{head}","merges_url":"https://api.github.com/repos/guardian/path-manager/merges","archive_url":"https://api.github.com/repos/guardian/path-manager/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/guardian/path-manager/downloads","issues_url":"https://api.github.com/repos/guardian/path-manager/issues{/number}","pulls_url":"https://api.github.com/repos/guardian/path-manager/pulls{/number}","milestones_url":"https://api.github.com/repos/guardian/path-manager/milestones{/number}","notifications_url":"https://api.github.com/repos/guardian/path-manager/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/guardian/path-manager/labels{/name}","releases_url":"https://api.github.com/repos/guardian/path-manager/releases{/id}","created_at":"2015-03-13T12:55:24Z","updated_at":"2015-03-24T10:53:18Z","pushed_at":"2015-03-24T10:53:18Z","git_url":"git://github.com/guardian/path-manager.git","ssh_url":"git@github.com:guardian/path-manager.git","clone_url":"https://github.com/guardian/path-manager.git","svn_url":"https://github.com/guardian/path-manager","homepage":null,"size":200,"stargazers_count":0,"watchers_count":0,"language":"Scala","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":"guardian:master","ref":"master","sha":"fca13881606dc59dc49c8baaa175b9d817286af3","user":{"login":"guardian","id":164318,"avatar_url":"https://avatars.githubusercontent.com/u/164318?v=3","gravatar_id":"","url":"https://api.github.com/users/guardian","html_url":"https://github.com/guardian","followers_url":"https://api.github.com/users/guardian/followers","following_url":"https://api.github.com/users/guardian/following{/other_user}","gists_url":"https://api.github.com/users/guardian/gists{/gist_id}","starred_url":"https://api.github.com/users/guardian/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/guardian/subscriptions","organizations_url":"https://api.github.com/users/guardian/orgs","repos_url":"https://api.github.com/users/guardian/repos","events_url":"https://api.github.com/users/guardian/events{/privacy}","received_events_url":"https://api.github.com/users/guardian/received_events","type":"Organization","site_admin":false},"repo":{"id":32155769,"name":"path-manager","full_name":"guardian/path-manager","owner":{"login":"guardian","id":164318,"avatar_url":"https://avatars.githubusercontent.com/u/164318?v=3","gravatar_id":"","url":"https://api.github.com/users/guardian","html_url":"https://github.com/guardian","followers_url":"https://api.github.com/users/guardian/followers","following_url":"https://api.github.com/users/guardian/following{/other_user}","gists_url":"https://api.github.com/users/guardian/gists{/gist_id}","starred_url":"https://api.github.com/users/guardian/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/guardian/subscriptions","organizations_url":"https://api.github.com/users/guardian/orgs","repos_url":"https://api.github.com/users/guardian/repos","events_url":"https://api.github.com/users/guardian/events{/privacy}","received_events_url":"https://api.github.com/users/guardian/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/guardian/path-manager","description":"Service that manages paths for a domain. Ensures they are unique etc.","fork":false,"url":"https://api.github.com/repos/guardian/path-manager","forks_url":"https://api.github.com/repos/guardian/path-manager/forks","keys_url":"https://api.github.com/repos/guardian/path-manager/keys{/key_id}","collaborators_url":"https://api.github.com/repos/guardian/path-manager/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/guardian/path-manager/teams","hooks_url":"https://api.github.com/repos/guardian/path-manager/hooks","issue_events_url":"https://api.github.com/repos/guardian/path-manager/issues/events{/number}","events_url":"https://api.github.com/repos/guardian/path-manager/events","assignees_url":"https://api.github.com/repos/guardian/path-manager/assignees{/user}","branches_url":"https://api.github.com/repos/guardian/path-manager/branches{/branch}","tags_url":"https://api.github.com/repos/guardian/path-manager/tags","blobs_url":"https://api.github.com/repos/guardian/path-manager/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/guardian/path-manager/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/guardian/path-manager/git/refs{/sha}","trees_url":"https://api.github.com/repos/guardian/path-manager/git/trees{/sha}","statuses_url":"https://api.github.com/repos/guardian/path-manager/statuses/{sha}","languages_url":"https://api.github.com/repos/guardian/path-manager/languages","stargazers_url":"https://api.github.com/repos/guardian/path-manager/stargazers","contributors_url":"https://api.github.com/repos/guardian/path-manager/contributors","subscribers_url":"https://api.github.com/repos/guardian/path-manager/subscribers","subscription_url":"https://api.github.com/repos/guardian/path-manager/subscription","commits_url":"https://api.github.com/repos/guardian/path-manager/commits{/sha}","git_commits_url":"https://api.github.com/repos/guardian/path-manager/git/commits{/sha}","comments_url":"https://api.github.com/repos/guardian/path-manager/comments{/number}","issue_comment_url":"https://api.github.com/repos/guardian/path-manager/issues/comments{/number}","contents_url":"https://api.github.com/repos/guardian/path-manager/contents/{+path}","compare_url":"https://api.github.com/repos/guardian/path-manager/compare/{base}...{head}","merges_url":"https://api.github.com/repos/guardian/path-manager/merges","archive_url":"https://api.github.com/repos/guardian/path-manager/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/guardian/path-manager/downloads","issues_url":"https://api.github.com/repos/guardian/path-manager/issues{/number}","pulls_url":"https://api.github.com/repos/guardian/path-manager/pulls{/number}","milestones_url":"https://api.github.com/repos/guardian/path-manager/milestones{/number}","notifications_url":"https://api.github.com/repos/guardian/path-manager/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/guardian/path-manager/labels{/name}","releases_url":"https://api.github.com/repos/guardian/path-manager/releases{/id}","created_at":"2015-03-13T12:55:24Z","updated_at":"2015-03-24T10:53:18Z","pushed_at":"2015-03-24T10:53:18Z","git_url":"git://github.com/guardian/path-manager.git","ssh_url":"git@github.com:guardian/path-manager.git","clone_url":"https://github.com/guardian/path-manager.git","svn_url":"https://github.com/guardian/path-manager","homepage":null,"size":200,"stargazers_count":0,"watchers_count":0,"language":"Scala","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/guardian/path-manager/pulls/3"},"html":{"href":"https://github.com/guardian/path-manager/pull/3"},"issue":{"href":"https://api.github.com/repos/guardian/path-manager/issues/3"},"comments":{"href":"https://api.github.com/repos/guardian/path-manager/issues/3/comments"},"review_comments":{"href":"https://api.github.com/repos/guardian/path-manager/pulls/3/comments"},"review_comment":{"href":"https://api.github.com/repos/guardian/path-manager/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/guardian/path-manager/pulls/3/commits"},"statuses":{"href":"https://api.github.com/repos/guardian/path-manager/statuses/d8e2ccbd167afa0d1b9307bd1f766b2dcfa675f4"}}}}