{"action":"opened","number":16,"pull_request":{"url":"https://api.github.com/repos/lexich/redux-api/pulls/16","id":46511570,"html_url":"https://github.com/lexich/redux-api/pull/16","diff_url":"https://github.com/lexich/redux-api/pull/16.diff","patch_url":"https://github.com/lexich/redux-api/pull/16.patch","issue_url":"https://api.github.com/repos/lexich/redux-api/issues/16","number":16,"state":"open","locked":false,"title":"Add helpers option","user":{"login":"lexich","id":859946,"avatar_url":"https://avatars.githubusercontent.com/u/859946?v=3","gravatar_id":"","url":"https://api.github.com/users/lexich","html_url":"https://github.com/lexich","followers_url":"https://api.github.com/users/lexich/followers","following_url":"https://api.github.com/users/lexich/following{/other_user}","gists_url":"https://api.github.com/users/lexich/gists{/gist_id}","starred_url":"https://api.github.com/users/lexich/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lexich/subscriptions","organizations_url":"https://api.github.com/users/lexich/orgs","repos_url":"https://api.github.com/users/lexich/repos","events_url":"https://api.github.com/users/lexich/events{/privacy}","received_events_url":"https://api.github.com/users/lexich/received_events","type":"User","site_admin":false},"body":"Add: helpers options\r\n```js\r\n{\r\n  test: {\r\n    url: \"/api/test/:name/:id\",\r\n    helpers: {\r\n      get(id, name) {\r\n        return [{id, name}], {}]\r\n      },\r\n      post(id, name, data) {\r\n        const {uuid} = this.getState().test;\r\n        const urlparams = {id, name};\r\n        const params = {body: {uuid, data}};\r\n        return [urlparams, params];\r\n      }\r\n    }\r\n  }\r\n}\r\n// using helpers\r\nrest.actions.test.get(1, \"admin\");\r\n// with callback\r\nrest.actions.post(1, \"admin\", {msg: \"Hello\"}, (err)=> {\r\n// end of action\r\n});\r\n```","created_at":"2015-10-01T11:19:55Z","updated_at":"2015-10-01T11:19:55Z","closed_at":null,"merged_at":null,"merge_commit_sha":null,"assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/lexich/redux-api/pulls/16/commits","review_comments_url":"https://api.github.com/repos/lexich/redux-api/pulls/16/comments","review_comment_url":"https://api.github.com/repos/lexich/redux-api/pulls/comments{/number}","comments_url":"https://api.github.com/repos/lexich/redux-api/issues/16/comments","statuses_url":"https://api.github.com/repos/lexich/redux-api/statuses/8c8754ffe1afc90d75f422f9305b6fbf1a326223","head":{"label":"lexich:helpers","ref":"helpers","sha":"8c8754ffe1afc90d75f422f9305b6fbf1a326223","user":{"login":"lexich","id":859946,"avatar_url":"https://avatars.githubusercontent.com/u/859946?v=3","gravatar_id":"","url":"https://api.github.com/users/lexich","html_url":"https://github.com/lexich","followers_url":"https://api.github.com/users/lexich/followers","following_url":"https://api.github.com/users/lexich/following{/other_user}","gists_url":"https://api.github.com/users/lexich/gists{/gist_id}","starred_url":"https://api.github.com/users/lexich/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lexich/subscriptions","organizations_url":"https://api.github.com/users/lexich/orgs","repos_url":"https://api.github.com/users/lexich/repos","events_url":"https://api.github.com/users/lexich/events{/privacy}","received_events_url":"https://api.github.com/users/lexich/received_events","type":"User","site_admin":false},"repo":{"id":40594264,"name":"redux-api","full_name":"lexich/redux-api","owner":{"login":"lexich","id":859946,"avatar_url":"https://avatars.githubusercontent.com/u/859946?v=3","gravatar_id":"","url":"https://api.github.com/users/lexich","html_url":"https://github.com/lexich","followers_url":"https://api.github.com/users/lexich/followers","following_url":"https://api.github.com/users/lexich/following{/other_user}","gists_url":"https://api.github.com/users/lexich/gists{/gist_id}","starred_url":"https://api.github.com/users/lexich/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lexich/subscriptions","organizations_url":"https://api.github.com/users/lexich/orgs","repos_url":"https://api.github.com/users/lexich/repos","events_url":"https://api.github.com/users/lexich/events{/privacy}","received_events_url":"https://api.github.com/users/lexich/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/lexich/redux-api","description":"Flux REST API for redux infrastructure","fork":false,"url":"https://api.github.com/repos/lexich/redux-api","forks_url":"https://api.github.com/repos/lexich/redux-api/forks","keys_url":"https://api.github.com/repos/lexich/redux-api/keys{/key_id}","collaborators_url":"https://api.github.com/repos/lexich/redux-api/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/lexich/redux-api/teams","hooks_url":"https://api.github.com/repos/lexich/redux-api/hooks","issue_events_url":"https://api.github.com/repos/lexich/redux-api/issues/events{/number}","events_url":"https://api.github.com/repos/lexich/redux-api/events","assignees_url":"https://api.github.com/repos/lexich/redux-api/assignees{/user}","branches_url":"https://api.github.com/repos/lexich/redux-api/branches{/branch}","tags_url":"https://api.github.com/repos/lexich/redux-api/tags","blobs_url":"https://api.github.com/repos/lexich/redux-api/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/lexich/redux-api/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/lexich/redux-api/git/refs{/sha}","trees_url":"https://api.github.com/repos/lexich/redux-api/git/trees{/sha}","statuses_url":"https://api.github.com/repos/lexich/redux-api/statuses/{sha}","languages_url":"https://api.github.com/repos/lexich/redux-api/languages","stargazers_url":"https://api.github.com/repos/lexich/redux-api/stargazers","contributors_url":"https://api.github.com/repos/lexich/redux-api/contributors","subscribers_url":"https://api.github.com/repos/lexich/redux-api/subscribers","subscription_url":"https://api.github.com/repos/lexich/redux-api/subscription","commits_url":"https://api.github.com/repos/lexich/redux-api/commits{/sha}","git_commits_url":"https://api.github.com/repos/lexich/redux-api/git/commits{/sha}","comments_url":"https://api.github.com/repos/lexich/redux-api/comments{/number}","issue_comment_url":"https://api.github.com/repos/lexich/redux-api/issues/comments{/number}","contents_url":"https://api.github.com/repos/lexich/redux-api/contents/{+path}","compare_url":"https://api.github.com/repos/lexich/redux-api/compare/{base}...{head}","merges_url":"https://api.github.com/repos/lexich/redux-api/merges","archive_url":"https://api.github.com/repos/lexich/redux-api/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/lexich/redux-api/downloads","issues_url":"https://api.github.com/repos/lexich/redux-api/issues{/number}","pulls_url":"https://api.github.com/repos/lexich/redux-api/pulls{/number}","milestones_url":"https://api.github.com/repos/lexich/redux-api/milestones{/number}","notifications_url":"https://api.github.com/repos/lexich/redux-api/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/lexich/redux-api/labels{/name}","releases_url":"https://api.github.com/repos/lexich/redux-api/releases{/id}","created_at":"2015-08-12T10:11:44Z","updated_at":"2015-09-29T19:40:38Z","pushed_at":"2015-10-01T11:19:58Z","git_url":"git://github.com/lexich/redux-api.git","ssh_url":"git@github.com:lexich/redux-api.git","clone_url":"https://github.com/lexich/redux-api.git","svn_url":"https://github.com/lexich/redux-api","homepage":"","size":963,"stargazers_count":28,"watchers_count":28,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":1,"forks":2,"open_issues":1,"watchers":28,"default_branch":"master"}},"base":{"label":"lexich:master","ref":"master","sha":"4a2c9d2a7dc08e01a07ebb4ad7bdae9dea6c4509","user":{"login":"lexich","id":859946,"avatar_url":"https://avatars.githubusercontent.com/u/859946?v=3","gravatar_id":"","url":"https://api.github.com/users/lexich","html_url":"https://github.com/lexich","followers_url":"https://api.github.com/users/lexich/followers","following_url":"https://api.github.com/users/lexich/following{/other_user}","gists_url":"https://api.github.com/users/lexich/gists{/gist_id}","starred_url":"https://api.github.com/users/lexich/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lexich/subscriptions","organizations_url":"https://api.github.com/users/lexich/orgs","repos_url":"https://api.github.com/users/lexich/repos","events_url":"https://api.github.com/users/lexich/events{/privacy}","received_events_url":"https://api.github.com/users/lexich/received_events","type":"User","site_admin":false},"repo":{"id":40594264,"name":"redux-api","full_name":"lexich/redux-api","owner":{"login":"lexich","id":859946,"avatar_url":"https://avatars.githubusercontent.com/u/859946?v=3","gravatar_id":"","url":"https://api.github.com/users/lexich","html_url":"https://github.com/lexich","followers_url":"https://api.github.com/users/lexich/followers","following_url":"https://api.github.com/users/lexich/following{/other_user}","gists_url":"https://api.github.com/users/lexich/gists{/gist_id}","starred_url":"https://api.github.com/users/lexich/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lexich/subscriptions","organizations_url":"https://api.github.com/users/lexich/orgs","repos_url":"https://api.github.com/users/lexich/repos","events_url":"https://api.github.com/users/lexich/events{/privacy}","received_events_url":"https://api.github.com/users/lexich/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/lexich/redux-api","description":"Flux REST API for redux infrastructure","fork":false,"url":"https://api.github.com/repos/lexich/redux-api","forks_url":"https://api.github.com/repos/lexich/redux-api/forks","keys_url":"https://api.github.com/repos/lexich/redux-api/keys{/key_id}","collaborators_url":"https://api.github.com/repos/lexich/redux-api/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/lexich/redux-api/teams","hooks_url":"https://api.github.com/repos/lexich/redux-api/hooks","issue_events_url":"https://api.github.com/repos/lexich/redux-api/issues/events{/number}","events_url":"https://api.github.com/repos/lexich/redux-api/events","assignees_url":"https://api.github.com/repos/lexich/redux-api/assignees{/user}","branches_url":"https://api.github.com/repos/lexich/redux-api/branches{/branch}","tags_url":"https://api.github.com/repos/lexich/redux-api/tags","blobs_url":"https://api.github.com/repos/lexich/redux-api/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/lexich/redux-api/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/lexich/redux-api/git/refs{/sha}","trees_url":"https://api.github.com/repos/lexich/redux-api/git/trees{/sha}","statuses_url":"https://api.github.com/repos/lexich/redux-api/statuses/{sha}","languages_url":"https://api.github.com/repos/lexich/redux-api/languages","stargazers_url":"https://api.github.com/repos/lexich/redux-api/stargazers","contributors_url":"https://api.github.com/repos/lexich/redux-api/contributors","subscribers_url":"https://api.github.com/repos/lexich/redux-api/subscribers","subscription_url":"https://api.github.com/repos/lexich/redux-api/subscription","commits_url":"https://api.github.com/repos/lexich/redux-api/commits{/sha}","git_commits_url":"https://api.github.com/repos/lexich/redux-api/git/commits{/sha}","comments_url":"https://api.github.com/repos/lexich/redux-api/comments{/number}","issue_comment_url":"https://api.github.com/repos/lexich/redux-api/issues/comments{/number}","contents_url":"https://api.github.com/repos/lexich/redux-api/contents/{+path}","compare_url":"https://api.github.com/repos/lexich/redux-api/compare/{base}...{head}","merges_url":"https://api.github.com/repos/lexich/redux-api/merges","archive_url":"https://api.github.com/repos/lexich/redux-api/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/lexich/redux-api/downloads","issues_url":"https://api.github.com/repos/lexich/redux-api/issues{/number}","pulls_url":"https://api.github.com/repos/lexich/redux-api/pulls{/number}","milestones_url":"https://api.github.com/repos/lexich/redux-api/milestones{/number}","notifications_url":"https://api.github.com/repos/lexich/redux-api/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/lexich/redux-api/labels{/name}","releases_url":"https://api.github.com/repos/lexich/redux-api/releases{/id}","created_at":"2015-08-12T10:11:44Z","updated_at":"2015-09-29T19:40:38Z","pushed_at":"2015-10-01T11:19:58Z","git_url":"git://github.com/lexich/redux-api.git","ssh_url":"git@github.com:lexich/redux-api.git","clone_url":"https://github.com/lexich/redux-api.git","svn_url":"https://github.com/lexich/redux-api","homepage":"","size":963,"stargazers_count":28,"watchers_count":28,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":1,"forks":2,"open_issues":1,"watchers":28,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/lexich/redux-api/pulls/16"},"html":{"href":"https://github.com/lexich/redux-api/pull/16"},"issue":{"href":"https://api.github.com/repos/lexich/redux-api/issues/16"},"comments":{"href":"https://api.github.com/repos/lexich/redux-api/issues/16/comments"},"review_comments":{"href":"https://api.github.com/repos/lexich/redux-api/pulls/16/comments"},"review_comment":{"href":"https://api.github.com/repos/lexich/redux-api/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/lexich/redux-api/pulls/16/commits"},"statuses":{"href":"https://api.github.com/repos/lexich/redux-api/statuses/8c8754ffe1afc90d75f422f9305b6fbf1a326223"}},"merged":false,"mergeable":null,"mergeable_state":"unknown","merged_by":null,"comments":0,"review_comments":0,"commits":1,"additions":395,"deletions":233,"changed_files":10}}