{"action":"created","comment":{"url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/pulls/comments/49865086","id":49865086,"diff_hunk":"@@ -0,0 +1,46 @@\n+'use strict';\n+\n+var njwt = require('njwt');\n+var uuid = require('node-uuid');\n+\n+function SamlIdpUrlBuilder(application) {\n+  this.application = application;\n+  this.secret = application.dataStore.requestExecutor.options.client.apiKey.secret;\n+}\n+\n+SamlIdpUrlBuilder.prototype._getServiceProvider = function _getServiceProvider(callback) {\n+  this.application.getSamlPolicy(function (err, samlPolicy) {\n+    if (err) {\n+      return callback(err);\n+    }\n+\n+    samlPolicy.getServiceProvider(callback);\n+  });\n+};\n+\n+SamlIdpUrlBuilder.prototype._buildInitializationUrl = function _buildInitializationUrl(initEndpointUrl, accessToken) {\n+  return initEndpointUrl + '?accessToken=' + encodeURIComponent(accessToken);","path":"lib/saml/SamlIdpUrlBuilder.js","position":22,"original_position":22,"commit_id":"bf379c508ea6e4b8d2fed8c91aee38afccc0c457","original_commit_id":"c78778793c4f313896183ddfa86bcf6b931989d8","user":{"login":"typerandom","id":1331778,"avatar_url":"https://avatars.githubusercontent.com/u/1331778?v=3","gravatar_id":"","url":"https://api.github.com/users/typerandom","html_url":"https://github.com/typerandom","followers_url":"https://api.github.com/users/typerandom/followers","following_url":"https://api.github.com/users/typerandom/following{/other_user}","gists_url":"https://api.github.com/users/typerandom/gists{/gist_id}","starred_url":"https://api.github.com/users/typerandom/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/typerandom/subscriptions","organizations_url":"https://api.github.com/users/typerandom/orgs","repos_url":"https://api.github.com/users/typerandom/repos","events_url":"https://api.github.com/users/typerandom/events{/privacy}","received_events_url":"https://api.github.com/users/typerandom/received_events","type":"User","site_admin":false},"body":"Do you want to post the URL that you generated?","created_at":"2016-01-15T15:27:25Z","updated_at":"2016-01-15T15:27:25Z","html_url":"https://github.com/stormpath/stormpath-sdk-node/pull/345#discussion_r49865086","pull_request_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/pulls/345","_links":{"self":{"href":"https://api.github.com/repos/stormpath/stormpath-sdk-node/pulls/comments/49865086"},"html":{"href":"https://github.com/stormpath/stormpath-sdk-node/pull/345#discussion_r49865086"},"pull_request":{"href":"https://api.github.com/repos/stormpath/stormpath-sdk-node/pulls/345"}}},"pull_request":{"url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/pulls/345","id":55751008,"html_url":"https://github.com/stormpath/stormpath-sdk-node/pull/345","diff_url":"https://github.com/stormpath/stormpath-sdk-node/pull/345.diff","patch_url":"https://github.com/stormpath/stormpath-sdk-node/pull/345.patch","issue_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/issues/345","number":345,"state":"open","locked":false,"title":"Feature: SAML Support","user":{"login":"typerandom","id":1331778,"avatar_url":"https://avatars.githubusercontent.com/u/1331778?v=3","gravatar_id":"","url":"https://api.github.com/users/typerandom","html_url":"https://github.com/typerandom","followers_url":"https://api.github.com/users/typerandom/followers","following_url":"https://api.github.com/users/typerandom/following{/other_user}","gists_url":"https://api.github.com/users/typerandom/gists{/gist_id}","starred_url":"https://api.github.com/users/typerandom/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/typerandom/subscriptions","organizations_url":"https://api.github.com/users/typerandom/orgs","repos_url":"https://api.github.com/users/typerandom/repos","events_url":"https://api.github.com/users/typerandom/events{/privacy}","received_events_url":"https://api.github.com/users/typerandom/received_events","type":"User","site_admin":false},"body":"Adds the ability to authenticate SAML requests.\r\n\r\nFixes #332.","created_at":"2016-01-12T12:25:55Z","updated_at":"2016-01-15T15:27:25Z","closed_at":null,"merged_at":null,"merge_commit_sha":"7782e566577a56ea6161dabdbd3746dd4b862cac","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/pulls/345/commits","review_comments_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/pulls/345/comments","review_comment_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/pulls/comments{/number}","comments_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/issues/345/comments","statuses_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/statuses/bf379c508ea6e4b8d2fed8c91aee38afccc0c457","head":{"label":"stormpath:feature-saml-support","ref":"feature-saml-support","sha":"bf379c508ea6e4b8d2fed8c91aee38afccc0c457","user":{"login":"stormpath","id":1377453,"avatar_url":"https://avatars.githubusercontent.com/u/1377453?v=3","gravatar_id":"","url":"https://api.github.com/users/stormpath","html_url":"https://github.com/stormpath","followers_url":"https://api.github.com/users/stormpath/followers","following_url":"https://api.github.com/users/stormpath/following{/other_user}","gists_url":"https://api.github.com/users/stormpath/gists{/gist_id}","starred_url":"https://api.github.com/users/stormpath/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stormpath/subscriptions","organizations_url":"https://api.github.com/users/stormpath/orgs","repos_url":"https://api.github.com/users/stormpath/repos","events_url":"https://api.github.com/users/stormpath/events{/privacy}","received_events_url":"https://api.github.com/users/stormpath/received_events","type":"Organization","site_admin":false},"repo":{"id":16016386,"name":"stormpath-sdk-node","full_name":"stormpath/stormpath-sdk-node","owner":{"login":"stormpath","id":1377453,"avatar_url":"https://avatars.githubusercontent.com/u/1377453?v=3","gravatar_id":"","url":"https://api.github.com/users/stormpath","html_url":"https://github.com/stormpath","followers_url":"https://api.github.com/users/stormpath/followers","following_url":"https://api.github.com/users/stormpath/following{/other_user}","gists_url":"https://api.github.com/users/stormpath/gists{/gist_id}","starred_url":"https://api.github.com/users/stormpath/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stormpath/subscriptions","organizations_url":"https://api.github.com/users/stormpath/orgs","repos_url":"https://api.github.com/users/stormpath/repos","events_url":"https://api.github.com/users/stormpath/events{/privacy}","received_events_url":"https://api.github.com/users/stormpath/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/stormpath/stormpath-sdk-node","description":"Official Node.js SDK for the Stormpath User Management REST API","fork":false,"url":"https://api.github.com/repos/stormpath/stormpath-sdk-node","forks_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/forks","keys_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/keys{/key_id}","collaborators_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/teams","hooks_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/hooks","issue_events_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/issues/events{/number}","events_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/events","assignees_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/assignees{/user}","branches_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/branches{/branch}","tags_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/tags","blobs_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/git/refs{/sha}","trees_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/git/trees{/sha}","statuses_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/statuses/{sha}","languages_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/languages","stargazers_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/stargazers","contributors_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/contributors","subscribers_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/subscribers","subscription_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/subscription","commits_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/commits{/sha}","git_commits_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/git/commits{/sha}","comments_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/comments{/number}","issue_comment_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/issues/comments{/number}","contents_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/contents/{+path}","compare_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/compare/{base}...{head}","merges_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/merges","archive_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/downloads","issues_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/issues{/number}","pulls_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/pulls{/number}","milestones_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/milestones{/number}","notifications_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/labels{/name}","releases_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/releases{/id}","created_at":"2014-01-18T01:03:26Z","updated_at":"2016-01-14T04:18:06Z","pushed_at":"2016-01-14T16:44:36Z","git_url":"git://github.com/stormpath/stormpath-sdk-node.git","ssh_url":"git@github.com:stormpath/stormpath-sdk-node.git","clone_url":"https://github.com/stormpath/stormpath-sdk-node.git","svn_url":"https://github.com/stormpath/stormpath-sdk-node","homepage":null,"size":1364,"stargazers_count":72,"watchers_count":72,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":25,"mirror_url":null,"open_issues_count":38,"forks":25,"open_issues":38,"watchers":72,"default_branch":"master"}},"base":{"label":"stormpath:master","ref":"master","sha":"a41df782a7df0a1dcf6e57a25777243bda0b3a93","user":{"login":"stormpath","id":1377453,"avatar_url":"https://avatars.githubusercontent.com/u/1377453?v=3","gravatar_id":"","url":"https://api.github.com/users/stormpath","html_url":"https://github.com/stormpath","followers_url":"https://api.github.com/users/stormpath/followers","following_url":"https://api.github.com/users/stormpath/following{/other_user}","gists_url":"https://api.github.com/users/stormpath/gists{/gist_id}","starred_url":"https://api.github.com/users/stormpath/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stormpath/subscriptions","organizations_url":"https://api.github.com/users/stormpath/orgs","repos_url":"https://api.github.com/users/stormpath/repos","events_url":"https://api.github.com/users/stormpath/events{/privacy}","received_events_url":"https://api.github.com/users/stormpath/received_events","type":"Organization","site_admin":false},"repo":{"id":16016386,"name":"stormpath-sdk-node","full_name":"stormpath/stormpath-sdk-node","owner":{"login":"stormpath","id":1377453,"avatar_url":"https://avatars.githubusercontent.com/u/1377453?v=3","gravatar_id":"","url":"https://api.github.com/users/stormpath","html_url":"https://github.com/stormpath","followers_url":"https://api.github.com/users/stormpath/followers","following_url":"https://api.github.com/users/stormpath/following{/other_user}","gists_url":"https://api.github.com/users/stormpath/gists{/gist_id}","starred_url":"https://api.github.com/users/stormpath/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stormpath/subscriptions","organizations_url":"https://api.github.com/users/stormpath/orgs","repos_url":"https://api.github.com/users/stormpath/repos","events_url":"https://api.github.com/users/stormpath/events{/privacy}","received_events_url":"https://api.github.com/users/stormpath/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/stormpath/stormpath-sdk-node","description":"Official Node.js SDK for the Stormpath User Management REST API","fork":false,"url":"https://api.github.com/repos/stormpath/stormpath-sdk-node","forks_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/forks","keys_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/keys{/key_id}","collaborators_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/teams","hooks_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/hooks","issue_events_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/issues/events{/number}","events_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/events","assignees_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/assignees{/user}","branches_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/branches{/branch}","tags_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/tags","blobs_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/git/refs{/sha}","trees_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/git/trees{/sha}","statuses_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/statuses/{sha}","languages_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/languages","stargazers_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/stargazers","contributors_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/contributors","subscribers_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/subscribers","subscription_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/subscription","commits_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/commits{/sha}","git_commits_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/git/commits{/sha}","comments_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/comments{/number}","issue_comment_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/issues/comments{/number}","contents_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/contents/{+path}","compare_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/compare/{base}...{head}","merges_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/merges","archive_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/downloads","issues_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/issues{/number}","pulls_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/pulls{/number}","milestones_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/milestones{/number}","notifications_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/labels{/name}","releases_url":"https://api.github.com/repos/stormpath/stormpath-sdk-node/releases{/id}","created_at":"2014-01-18T01:03:26Z","updated_at":"2016-01-14T04:18:06Z","pushed_at":"2016-01-14T16:44:36Z","git_url":"git://github.com/stormpath/stormpath-sdk-node.git","ssh_url":"git@github.com:stormpath/stormpath-sdk-node.git","clone_url":"https://github.com/stormpath/stormpath-sdk-node.git","svn_url":"https://github.com/stormpath/stormpath-sdk-node","homepage":null,"size":1364,"stargazers_count":72,"watchers_count":72,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":25,"mirror_url":null,"open_issues_count":38,"forks":25,"open_issues":38,"watchers":72,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/stormpath/stormpath-sdk-node/pulls/345"},"html":{"href":"https://github.com/stormpath/stormpath-sdk-node/pull/345"},"issue":{"href":"https://api.github.com/repos/stormpath/stormpath-sdk-node/issues/345"},"comments":{"href":"https://api.github.com/repos/stormpath/stormpath-sdk-node/issues/345/comments"},"review_comments":{"href":"https://api.github.com/repos/stormpath/stormpath-sdk-node/pulls/345/comments"},"review_comment":{"href":"https://api.github.com/repos/stormpath/stormpath-sdk-node/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/stormpath/stormpath-sdk-node/pulls/345/commits"},"statuses":{"href":"https://api.github.com/repos/stormpath/stormpath-sdk-node/statuses/bf379c508ea6e4b8d2fed8c91aee38afccc0c457"}}}}