{"action":"closed","number":14,"pull_request":{"url":"https://api.github.com/repos/vigetlabs/gangway/pulls/14","id":38001391,"html_url":"https://github.com/vigetlabs/gangway/pull/14","diff_url":"https://github.com/vigetlabs/gangway/pull/14.diff","patch_url":"https://github.com/vigetlabs/gangway/pull/14.patch","issue_url":"https://api.github.com/repos/vigetlabs/gangway/issues/14","number":14,"state":"closed","locked":false,"title":"Mocks can be functions","user":{"login":"nhunzaker","id":590904,"avatar_url":"https://avatars.githubusercontent.com/u/590904?v=3","gravatar_id":"","url":"https://api.github.com/users/nhunzaker","html_url":"https://github.com/nhunzaker","followers_url":"https://api.github.com/users/nhunzaker/followers","following_url":"https://api.github.com/users/nhunzaker/following{/other_user}","gists_url":"https://api.github.com/users/nhunzaker/gists{/gist_id}","starred_url":"https://api.github.com/users/nhunzaker/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nhunzaker/subscriptions","organizations_url":"https://api.github.com/users/nhunzaker/orgs","repos_url":"https://api.github.com/users/nhunzaker/repos","events_url":"https://api.github.com/users/nhunzaker/events{/privacy}","received_events_url":"https://api.github.com/users/nhunzaker/received_events","type":"User","site_admin":false},"body":"```javascript\r\napi.route({\r\n  users: {\r\n    update: {\r\n      path: '/users/{id*}',\r\n      mock: options => options.body\r\n    }\r\n  }\r\n})\r\n\r\nlet user = { id: 10, name: 'Greypants' }\r\n\r\napi.users.update({ body: user }).done(function(body) {\r\n  console.log(body) //=> { id: 10, name: 'Greypants' }\r\n})","created_at":"2015-06-18T12:34:17Z","updated_at":"2015-06-24T14:51:45Z","closed_at":"2015-06-24T14:51:45Z","merged_at":"2015-06-24T14:51:45Z","merge_commit_sha":"a390e78bd0c47df12404acfa97ec56e15e488e04","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/vigetlabs/gangway/pulls/14/commits","review_comments_url":"https://api.github.com/repos/vigetlabs/gangway/pulls/14/comments","review_comment_url":"https://api.github.com/repos/vigetlabs/gangway/pulls/comments{/number}","comments_url":"https://api.github.com/repos/vigetlabs/gangway/issues/14/comments","statuses_url":"https://api.github.com/repos/vigetlabs/gangway/statuses/2d652a992ccee6b99f7dde4ae852d0d9c0adfc91","head":{"label":"vigetlabs:functional-mocks","ref":"functional-mocks","sha":"2d652a992ccee6b99f7dde4ae852d0d9c0adfc91","user":{"login":"vigetlabs","id":4845,"avatar_url":"https://avatars.githubusercontent.com/u/4845?v=3","gravatar_id":"","url":"https://api.github.com/users/vigetlabs","html_url":"https://github.com/vigetlabs","followers_url":"https://api.github.com/users/vigetlabs/followers","following_url":"https://api.github.com/users/vigetlabs/following{/other_user}","gists_url":"https://api.github.com/users/vigetlabs/gists{/gist_id}","starred_url":"https://api.github.com/users/vigetlabs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vigetlabs/subscriptions","organizations_url":"https://api.github.com/users/vigetlabs/orgs","repos_url":"https://api.github.com/users/vigetlabs/repos","events_url":"https://api.github.com/users/vigetlabs/events{/privacy}","received_events_url":"https://api.github.com/users/vigetlabs/received_events","type":"Organization","site_admin":false},"repo":{"id":37326036,"name":"gangway","full_name":"vigetlabs/gangway","owner":{"login":"vigetlabs","id":4845,"avatar_url":"https://avatars.githubusercontent.com/u/4845?v=3","gravatar_id":"","url":"https://api.github.com/users/vigetlabs","html_url":"https://github.com/vigetlabs","followers_url":"https://api.github.com/users/vigetlabs/followers","following_url":"https://api.github.com/users/vigetlabs/following{/other_user}","gists_url":"https://api.github.com/users/vigetlabs/gists{/gist_id}","starred_url":"https://api.github.com/users/vigetlabs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vigetlabs/subscriptions","organizations_url":"https://api.github.com/users/vigetlabs/orgs","repos_url":"https://api.github.com/users/vigetlabs/repos","events_url":"https://api.github.com/users/vigetlabs/events{/privacy}","received_events_url":"https://api.github.com/users/vigetlabs/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/vigetlabs/gangway","description":"A client-side API abstraction layer","fork":false,"url":"https://api.github.com/repos/vigetlabs/gangway","forks_url":"https://api.github.com/repos/vigetlabs/gangway/forks","keys_url":"https://api.github.com/repos/vigetlabs/gangway/keys{/key_id}","collaborators_url":"https://api.github.com/repos/vigetlabs/gangway/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/vigetlabs/gangway/teams","hooks_url":"https://api.github.com/repos/vigetlabs/gangway/hooks","issue_events_url":"https://api.github.com/repos/vigetlabs/gangway/issues/events{/number}","events_url":"https://api.github.com/repos/vigetlabs/gangway/events","assignees_url":"https://api.github.com/repos/vigetlabs/gangway/assignees{/user}","branches_url":"https://api.github.com/repos/vigetlabs/gangway/branches{/branch}","tags_url":"https://api.github.com/repos/vigetlabs/gangway/tags","blobs_url":"https://api.github.com/repos/vigetlabs/gangway/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/vigetlabs/gangway/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/vigetlabs/gangway/git/refs{/sha}","trees_url":"https://api.github.com/repos/vigetlabs/gangway/git/trees{/sha}","statuses_url":"https://api.github.com/repos/vigetlabs/gangway/statuses/{sha}","languages_url":"https://api.github.com/repos/vigetlabs/gangway/languages","stargazers_url":"https://api.github.com/repos/vigetlabs/gangway/stargazers","contributors_url":"https://api.github.com/repos/vigetlabs/gangway/contributors","subscribers_url":"https://api.github.com/repos/vigetlabs/gangway/subscribers","subscription_url":"https://api.github.com/repos/vigetlabs/gangway/subscription","commits_url":"https://api.github.com/repos/vigetlabs/gangway/commits{/sha}","git_commits_url":"https://api.github.com/repos/vigetlabs/gangway/git/commits{/sha}","comments_url":"https://api.github.com/repos/vigetlabs/gangway/comments{/number}","issue_comment_url":"https://api.github.com/repos/vigetlabs/gangway/issues/comments{/number}","contents_url":"https://api.github.com/repos/vigetlabs/gangway/contents/{+path}","compare_url":"https://api.github.com/repos/vigetlabs/gangway/compare/{base}...{head}","merges_url":"https://api.github.com/repos/vigetlabs/gangway/merges","archive_url":"https://api.github.com/repos/vigetlabs/gangway/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/vigetlabs/gangway/downloads","issues_url":"https://api.github.com/repos/vigetlabs/gangway/issues{/number}","pulls_url":"https://api.github.com/repos/vigetlabs/gangway/pulls{/number}","milestones_url":"https://api.github.com/repos/vigetlabs/gangway/milestones{/number}","notifications_url":"https://api.github.com/repos/vigetlabs/gangway/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/vigetlabs/gangway/labels{/name}","releases_url":"https://api.github.com/repos/vigetlabs/gangway/releases{/id}","created_at":"2015-06-12T14:18:29Z","updated_at":"2015-06-16T19:28:09Z","pushed_at":"2015-06-24T14:51:44Z","git_url":"git://github.com/vigetlabs/gangway.git","ssh_url":"git@github.com:vigetlabs/gangway.git","clone_url":"https://github.com/vigetlabs/gangway.git","svn_url":"https://github.com/vigetlabs/gangway","homepage":"","size":278,"stargazers_count":2,"watchers_count":2,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":2,"forks":0,"open_issues":2,"watchers":2,"default_branch":"master"}},"base":{"label":"vigetlabs:master","ref":"master","sha":"d7a950f49dc1f764e1417d5b6c511036d461fb62","user":{"login":"vigetlabs","id":4845,"avatar_url":"https://avatars.githubusercontent.com/u/4845?v=3","gravatar_id":"","url":"https://api.github.com/users/vigetlabs","html_url":"https://github.com/vigetlabs","followers_url":"https://api.github.com/users/vigetlabs/followers","following_url":"https://api.github.com/users/vigetlabs/following{/other_user}","gists_url":"https://api.github.com/users/vigetlabs/gists{/gist_id}","starred_url":"https://api.github.com/users/vigetlabs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vigetlabs/subscriptions","organizations_url":"https://api.github.com/users/vigetlabs/orgs","repos_url":"https://api.github.com/users/vigetlabs/repos","events_url":"https://api.github.com/users/vigetlabs/events{/privacy}","received_events_url":"https://api.github.com/users/vigetlabs/received_events","type":"Organization","site_admin":false},"repo":{"id":37326036,"name":"gangway","full_name":"vigetlabs/gangway","owner":{"login":"vigetlabs","id":4845,"avatar_url":"https://avatars.githubusercontent.com/u/4845?v=3","gravatar_id":"","url":"https://api.github.com/users/vigetlabs","html_url":"https://github.com/vigetlabs","followers_url":"https://api.github.com/users/vigetlabs/followers","following_url":"https://api.github.com/users/vigetlabs/following{/other_user}","gists_url":"https://api.github.com/users/vigetlabs/gists{/gist_id}","starred_url":"https://api.github.com/users/vigetlabs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vigetlabs/subscriptions","organizations_url":"https://api.github.com/users/vigetlabs/orgs","repos_url":"https://api.github.com/users/vigetlabs/repos","events_url":"https://api.github.com/users/vigetlabs/events{/privacy}","received_events_url":"https://api.github.com/users/vigetlabs/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/vigetlabs/gangway","description":"A client-side API abstraction layer","fork":false,"url":"https://api.github.com/repos/vigetlabs/gangway","forks_url":"https://api.github.com/repos/vigetlabs/gangway/forks","keys_url":"https://api.github.com/repos/vigetlabs/gangway/keys{/key_id}","collaborators_url":"https://api.github.com/repos/vigetlabs/gangway/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/vigetlabs/gangway/teams","hooks_url":"https://api.github.com/repos/vigetlabs/gangway/hooks","issue_events_url":"https://api.github.com/repos/vigetlabs/gangway/issues/events{/number}","events_url":"https://api.github.com/repos/vigetlabs/gangway/events","assignees_url":"https://api.github.com/repos/vigetlabs/gangway/assignees{/user}","branches_url":"https://api.github.com/repos/vigetlabs/gangway/branches{/branch}","tags_url":"https://api.github.com/repos/vigetlabs/gangway/tags","blobs_url":"https://api.github.com/repos/vigetlabs/gangway/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/vigetlabs/gangway/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/vigetlabs/gangway/git/refs{/sha}","trees_url":"https://api.github.com/repos/vigetlabs/gangway/git/trees{/sha}","statuses_url":"https://api.github.com/repos/vigetlabs/gangway/statuses/{sha}","languages_url":"https://api.github.com/repos/vigetlabs/gangway/languages","stargazers_url":"https://api.github.com/repos/vigetlabs/gangway/stargazers","contributors_url":"https://api.github.com/repos/vigetlabs/gangway/contributors","subscribers_url":"https://api.github.com/repos/vigetlabs/gangway/subscribers","subscription_url":"https://api.github.com/repos/vigetlabs/gangway/subscription","commits_url":"https://api.github.com/repos/vigetlabs/gangway/commits{/sha}","git_commits_url":"https://api.github.com/repos/vigetlabs/gangway/git/commits{/sha}","comments_url":"https://api.github.com/repos/vigetlabs/gangway/comments{/number}","issue_comment_url":"https://api.github.com/repos/vigetlabs/gangway/issues/comments{/number}","contents_url":"https://api.github.com/repos/vigetlabs/gangway/contents/{+path}","compare_url":"https://api.github.com/repos/vigetlabs/gangway/compare/{base}...{head}","merges_url":"https://api.github.com/repos/vigetlabs/gangway/merges","archive_url":"https://api.github.com/repos/vigetlabs/gangway/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/vigetlabs/gangway/downloads","issues_url":"https://api.github.com/repos/vigetlabs/gangway/issues{/number}","pulls_url":"https://api.github.com/repos/vigetlabs/gangway/pulls{/number}","milestones_url":"https://api.github.com/repos/vigetlabs/gangway/milestones{/number}","notifications_url":"https://api.github.com/repos/vigetlabs/gangway/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/vigetlabs/gangway/labels{/name}","releases_url":"https://api.github.com/repos/vigetlabs/gangway/releases{/id}","created_at":"2015-06-12T14:18:29Z","updated_at":"2015-06-16T19:28:09Z","pushed_at":"2015-06-24T14:51:44Z","git_url":"git://github.com/vigetlabs/gangway.git","ssh_url":"git@github.com:vigetlabs/gangway.git","clone_url":"https://github.com/vigetlabs/gangway.git","svn_url":"https://github.com/vigetlabs/gangway","homepage":"","size":278,"stargazers_count":2,"watchers_count":2,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":2,"forks":0,"open_issues":2,"watchers":2,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/vigetlabs/gangway/pulls/14"},"html":{"href":"https://github.com/vigetlabs/gangway/pull/14"},"issue":{"href":"https://api.github.com/repos/vigetlabs/gangway/issues/14"},"comments":{"href":"https://api.github.com/repos/vigetlabs/gangway/issues/14/comments"},"review_comments":{"href":"https://api.github.com/repos/vigetlabs/gangway/pulls/14/comments"},"review_comment":{"href":"https://api.github.com/repos/vigetlabs/gangway/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/vigetlabs/gangway/pulls/14/commits"},"statuses":{"href":"https://api.github.com/repos/vigetlabs/gangway/statuses/2d652a992ccee6b99f7dde4ae852d0d9c0adfc91"}},"merged":true,"mergeable":null,"mergeable_state":"unknown","merged_by":{"login":"nhunzaker","id":590904,"avatar_url":"https://avatars.githubusercontent.com/u/590904?v=3","gravatar_id":"","url":"https://api.github.com/users/nhunzaker","html_url":"https://github.com/nhunzaker","followers_url":"https://api.github.com/users/nhunzaker/followers","following_url":"https://api.github.com/users/nhunzaker/following{/other_user}","gists_url":"https://api.github.com/users/nhunzaker/gists{/gist_id}","starred_url":"https://api.github.com/users/nhunzaker/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nhunzaker/subscriptions","organizations_url":"https://api.github.com/users/nhunzaker/orgs","repos_url":"https://api.github.com/users/nhunzaker/repos","events_url":"https://api.github.com/users/nhunzaker/events{/privacy}","received_events_url":"https://api.github.com/users/nhunzaker/received_events","type":"User","site_admin":false},"comments":1,"review_comments":0,"commits":1,"additions":20,"deletions":1,"changed_files":3}}