{"action":"created","comment":{"url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/pulls/comments/200514636","pull_request_review_id":134847632,"id":200514636,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIwMDUxNDYzNg==","diff_hunk":"@@ -6,49 +6,49 @@ import { Strings } from \"../../../locale/locale\";\n let config = require(\"config\");\n \n export class UpdateCardMsgDialog extends TriggerActionDialog {\n-\n+    // update the card, if user has already setup the card message from below dialog file using update button click\n+    // microsoft-teams-sample-complete-node\\src\\dialogs\\examples\\teams\\UpdateCardMsgSetupDialog.ts\n     private static async updateCardMessage(session: builder.Session, args?: any | builder.IDialogResult<any>, next?: (args?: builder.IDialogResult<any>) => void): Promise<void> {\n-        if (session.conversationData.updateCardCounter !== null) {\n-            session.conversationData.updateCardCounter = session.conversationData.updateCardCounter + 1;\n-        }\n-\n-        if (args.address) {\n+        if (session.message.replyToId)\n+        {\n             let buttons = new Array<builder.CardAction>();\n+            let updateCardCounter = session.message.value.updateCounterKey;\n+            let messageBackButtonValue = JSON.stringify({ updateCounterKey: ++updateCardCounter });\n \n-            buttons.push(new builder.CardAction(session)\n-                .type(\"invoke\")\n-                .title(Strings.update_card_button, session.conversationData.updateCardCounter)\n-                .value(\"{\" +\n-                    \"\\\"dialog\\\": \\\"\" + DialogIds.UpdateCardMsgDialogId + \"\\\", \" +\n-                    \"\\\"address\\\": \" + JSON.stringify(args.address) + \"\" +\n-                \"}\"),\n-            );\n+            let messageBackButton = builder.CardAction.messageBack(session, messageBackButtonValue)\n+                .displayText(Strings.messageBack_button_display_text)\n+                .title(Strings.update_card_button, updateCardCounter)\n+                .text(\"update card message\");\n+            buttons.push(messageBackButton);\n \n             let newCard = new builder.HeroCard(session)\n-                .title(Strings.default_title)\n-                .subtitle(Strings.default_subtitle)\n+                .title(Strings.updated_card_title)\n+                .subtitle(Strings.updated_card_subtitle)\n                 .text(Strings.default_text)\n                 .images([\n                     new builder.CardImage(session)\n                         .url(config.get(\"app.baseUri\") + \"/assets/computer_person.jpg\")\n                         .alt(session.gettext(Strings.img_default)),\n-                ])\n+                    ])\n                 .buttons(buttons);\n \n+            let newAddress = { ...session.message.address, id: session.message.replyToId };","path":"src/dialogs/examples/teams/UpdateCardMsgDialog.ts","position":47,"original_position":47,"commit_id":"a9a34d0f5994819af245d470b406b4cf38598dc2","original_commit_id":"a9a34d0f5994819af245d470b406b4cf38598dc2","user":{"login":"vamagra","id":26070837,"node_id":"MDQ6VXNlcjI2MDcwODM3","avatar_url":"https://avatars0.githubusercontent.com/u/26070837?v=4","gravatar_id":"","url":"https://api.github.com/users/vamagra","html_url":"https://github.com/vamagra","followers_url":"https://api.github.com/users/vamagra/followers","following_url":"https://api.github.com/users/vamagra/following{/other_user}","gists_url":"https://api.github.com/users/vamagra/gists{/gist_id}","starred_url":"https://api.github.com/users/vamagra/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vamagra/subscriptions","organizations_url":"https://api.github.com/users/vamagra/orgs","repos_url":"https://api.github.com/users/vamagra/repos","events_url":"https://api.github.com/users/vamagra/events{/privacy}","received_events_url":"https://api.github.com/users/vamagra/received_events","type":"User","site_admin":false},"body":"Done.","created_at":"2018-07-05T23:22:01Z","updated_at":"2018-07-05T23:22:02Z","html_url":"https://github.com/OfficeDev/microsoft-teams-sample-complete-node/pull/51#discussion_r200514636","pull_request_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/pulls/51","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/pulls/comments/200514636"},"html":{"href":"https://github.com/OfficeDev/microsoft-teams-sample-complete-node/pull/51#discussion_r200514636"},"pull_request":{"href":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/pulls/51"}},"in_reply_to_id":200495592},"pull_request":{"url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/pulls/51","id":199574487,"node_id":"MDExOlB1bGxSZXF1ZXN0MTk5NTc0NDg3","html_url":"https://github.com/OfficeDev/microsoft-teams-sample-complete-node/pull/51","diff_url":"https://github.com/OfficeDev/microsoft-teams-sample-complete-node/pull/51.diff","patch_url":"https://github.com/OfficeDev/microsoft-teams-sample-complete-node/pull/51.patch","issue_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/issues/51","number":51,"state":"open","locked":false,"title":"Update card message using ReplyToid","user":{"login":"vamagra","id":26070837,"node_id":"MDQ6VXNlcjI2MDcwODM3","avatar_url":"https://avatars0.githubusercontent.com/u/26070837?v=4","gravatar_id":"","url":"https://api.github.com/users/vamagra","html_url":"https://github.com/vamagra","followers_url":"https://api.github.com/users/vamagra/followers","following_url":"https://api.github.com/users/vamagra/following{/other_user}","gists_url":"https://api.github.com/users/vamagra/gists{/gist_id}","starred_url":"https://api.github.com/users/vamagra/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vamagra/subscriptions","organizations_url":"https://api.github.com/users/vamagra/orgs","repos_url":"https://api.github.com/users/vamagra/repos","events_url":"https://api.github.com/users/vamagra/events{/privacy}","received_events_url":"https://api.github.com/users/vamagra/received_events","type":"User","site_admin":false},"body":"@msftdherron @jotrick @MattSFT @aosolis @goelashish7 @jialic @robin-liao ","created_at":"2018-07-05T20:08:46Z","updated_at":"2018-07-05T23:22:02Z","closed_at":null,"merged_at":null,"merge_commit_sha":"4c1a64ac2cccd46eeb29ae8dbdf83da1da35983b","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/pulls/51/commits","review_comments_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/pulls/51/comments","review_comment_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/pulls/comments{/number}","comments_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/issues/51/comments","statuses_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/statuses/a9a34d0f5994819af245d470b406b4cf38598dc2","head":{"label":"OfficeDev:UpdateCardReplyToId","ref":"UpdateCardReplyToId","sha":"a9a34d0f5994819af245d470b406b4cf38598dc2","user":{"login":"OfficeDev","id":6789362,"node_id":"MDEyOk9yZ2FuaXphdGlvbjY3ODkzNjI=","avatar_url":"https://avatars2.githubusercontent.com/u/6789362?v=4","gravatar_id":"","url":"https://api.github.com/users/OfficeDev","html_url":"https://github.com/OfficeDev","followers_url":"https://api.github.com/users/OfficeDev/followers","following_url":"https://api.github.com/users/OfficeDev/following{/other_user}","gists_url":"https://api.github.com/users/OfficeDev/gists{/gist_id}","starred_url":"https://api.github.com/users/OfficeDev/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/OfficeDev/subscriptions","organizations_url":"https://api.github.com/users/OfficeDev/orgs","repos_url":"https://api.github.com/users/OfficeDev/repos","events_url":"https://api.github.com/users/OfficeDev/events{/privacy}","received_events_url":"https://api.github.com/users/OfficeDev/received_events","type":"Organization","site_admin":false},"repo":{"id":90650728,"node_id":"MDEwOlJlcG9zaXRvcnk5MDY1MDcyOA==","name":"microsoft-teams-sample-complete-node","full_name":"OfficeDev/microsoft-teams-sample-complete-node","owner":{"login":"OfficeDev","id":6789362,"node_id":"MDEyOk9yZ2FuaXphdGlvbjY3ODkzNjI=","avatar_url":"https://avatars2.githubusercontent.com/u/6789362?v=4","gravatar_id":"","url":"https://api.github.com/users/OfficeDev","html_url":"https://github.com/OfficeDev","followers_url":"https://api.github.com/users/OfficeDev/followers","following_url":"https://api.github.com/users/OfficeDev/following{/other_user}","gists_url":"https://api.github.com/users/OfficeDev/gists{/gist_id}","starred_url":"https://api.github.com/users/OfficeDev/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/OfficeDev/subscriptions","organizations_url":"https://api.github.com/users/OfficeDev/orgs","repos_url":"https://api.github.com/users/OfficeDev/repos","events_url":"https://api.github.com/users/OfficeDev/events{/privacy}","received_events_url":"https://api.github.com/users/OfficeDev/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/OfficeDev/microsoft-teams-sample-complete-node","description":"A template for building complex bots for Microsoft Teams - Node.JS version","fork":false,"url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node","forks_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/forks","keys_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/keys{/key_id}","collaborators_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/teams","hooks_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/hooks","issue_events_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/issues/events{/number}","events_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/events","assignees_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/assignees{/user}","branches_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/branches{/branch}","tags_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/tags","blobs_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/git/refs{/sha}","trees_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/git/trees{/sha}","statuses_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/statuses/{sha}","languages_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/languages","stargazers_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/stargazers","contributors_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/contributors","subscribers_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/subscribers","subscription_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/subscription","commits_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/commits{/sha}","git_commits_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/git/commits{/sha}","comments_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/comments{/number}","issue_comment_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/issues/comments{/number}","contents_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/contents/{+path}","compare_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/compare/{base}...{head}","merges_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/merges","archive_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/downloads","issues_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/issues{/number}","pulls_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/pulls{/number}","milestones_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/milestones{/number}","notifications_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/labels{/name}","releases_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/releases{/id}","deployments_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/deployments","created_at":"2017-05-08T16:41:53Z","updated_at":"2018-07-05T17:33:54Z","pushed_at":"2018-07-05T20:08:47Z","git_url":"git://github.com/OfficeDev/microsoft-teams-sample-complete-node.git","ssh_url":"git@github.com:OfficeDev/microsoft-teams-sample-complete-node.git","clone_url":"https://github.com/OfficeDev/microsoft-teams-sample-complete-node.git","svn_url":"https://github.com/OfficeDev/microsoft-teams-sample-complete-node","homepage":"","size":9495,"stargazers_count":39,"watchers_count":39,"language":"TypeScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":22,"mirror_url":null,"archived":false,"open_issues_count":5,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":22,"open_issues":5,"watchers":39,"default_branch":"master"}},"base":{"label":"OfficeDev:master","ref":"master","sha":"4764d862e147e742041396d8e7afa78034cd1cbb","user":{"login":"OfficeDev","id":6789362,"node_id":"MDEyOk9yZ2FuaXphdGlvbjY3ODkzNjI=","avatar_url":"https://avatars2.githubusercontent.com/u/6789362?v=4","gravatar_id":"","url":"https://api.github.com/users/OfficeDev","html_url":"https://github.com/OfficeDev","followers_url":"https://api.github.com/users/OfficeDev/followers","following_url":"https://api.github.com/users/OfficeDev/following{/other_user}","gists_url":"https://api.github.com/users/OfficeDev/gists{/gist_id}","starred_url":"https://api.github.com/users/OfficeDev/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/OfficeDev/subscriptions","organizations_url":"https://api.github.com/users/OfficeDev/orgs","repos_url":"https://api.github.com/users/OfficeDev/repos","events_url":"https://api.github.com/users/OfficeDev/events{/privacy}","received_events_url":"https://api.github.com/users/OfficeDev/received_events","type":"Organization","site_admin":false},"repo":{"id":90650728,"node_id":"MDEwOlJlcG9zaXRvcnk5MDY1MDcyOA==","name":"microsoft-teams-sample-complete-node","full_name":"OfficeDev/microsoft-teams-sample-complete-node","owner":{"login":"OfficeDev","id":6789362,"node_id":"MDEyOk9yZ2FuaXphdGlvbjY3ODkzNjI=","avatar_url":"https://avatars2.githubusercontent.com/u/6789362?v=4","gravatar_id":"","url":"https://api.github.com/users/OfficeDev","html_url":"https://github.com/OfficeDev","followers_url":"https://api.github.com/users/OfficeDev/followers","following_url":"https://api.github.com/users/OfficeDev/following{/other_user}","gists_url":"https://api.github.com/users/OfficeDev/gists{/gist_id}","starred_url":"https://api.github.com/users/OfficeDev/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/OfficeDev/subscriptions","organizations_url":"https://api.github.com/users/OfficeDev/orgs","repos_url":"https://api.github.com/users/OfficeDev/repos","events_url":"https://api.github.com/users/OfficeDev/events{/privacy}","received_events_url":"https://api.github.com/users/OfficeDev/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/OfficeDev/microsoft-teams-sample-complete-node","description":"A template for building complex bots for Microsoft Teams - Node.JS version","fork":false,"url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node","forks_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/forks","keys_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/keys{/key_id}","collaborators_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/teams","hooks_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/hooks","issue_events_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/issues/events{/number}","events_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/events","assignees_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/assignees{/user}","branches_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/branches{/branch}","tags_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/tags","blobs_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/git/refs{/sha}","trees_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/git/trees{/sha}","statuses_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/statuses/{sha}","languages_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/languages","stargazers_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/stargazers","contributors_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/contributors","subscribers_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/subscribers","subscription_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/subscription","commits_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/commits{/sha}","git_commits_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/git/commits{/sha}","comments_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/comments{/number}","issue_comment_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/issues/comments{/number}","contents_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/contents/{+path}","compare_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/compare/{base}...{head}","merges_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/merges","archive_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/downloads","issues_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/issues{/number}","pulls_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/pulls{/number}","milestones_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/milestones{/number}","notifications_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/labels{/name}","releases_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/releases{/id}","deployments_url":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/deployments","created_at":"2017-05-08T16:41:53Z","updated_at":"2018-07-05T17:33:54Z","pushed_at":"2018-07-05T20:08:47Z","git_url":"git://github.com/OfficeDev/microsoft-teams-sample-complete-node.git","ssh_url":"git@github.com:OfficeDev/microsoft-teams-sample-complete-node.git","clone_url":"https://github.com/OfficeDev/microsoft-teams-sample-complete-node.git","svn_url":"https://github.com/OfficeDev/microsoft-teams-sample-complete-node","homepage":"","size":9495,"stargazers_count":39,"watchers_count":39,"language":"TypeScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":22,"mirror_url":null,"archived":false,"open_issues_count":5,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":22,"open_issues":5,"watchers":39,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/pulls/51"},"html":{"href":"https://github.com/OfficeDev/microsoft-teams-sample-complete-node/pull/51"},"issue":{"href":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/issues/51"},"comments":{"href":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/issues/51/comments"},"review_comments":{"href":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/pulls/51/comments"},"review_comment":{"href":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/pulls/51/commits"},"statuses":{"href":"https://api.github.com/repos/OfficeDev/microsoft-teams-sample-complete-node/statuses/a9a34d0f5994819af245d470b406b4cf38598dc2"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"vamagra"}}