From f1c9663c7f63e5a9c98783d8f90b81814b5c93cf Mon Sep 17 00:00:00 2001 From: Adrian Solis Date: Tue, 29 May 2018 09:55:42 -0700 Subject: [PATCH] Update version to 0.2.0 - Update package.json - Remove deprecated methods --- Node/package.json | 2 +- Node/src/TeamsChatConnector.ts | 25 ------------------------- Node/src/botbuilder-teams.d.ts | 10 ---------- 3 files changed, 1 insertion(+), 36 deletions(-) diff --git a/Node/package.json b/Node/package.json index cd7915eb..850914d1 100644 --- a/Node/package.json +++ b/Node/package.json @@ -1,6 +1,6 @@ { "name": "botbuilder-teams", - "version": "0.1.6", + "version": "0.2.0", "description": "Microsoft Teams Bot Builder extension SDK", "scripts": { "prepublish": "cd src && tsc && copy botbuilder-teams.d.ts ..\\lib", diff --git a/Node/src/TeamsChatConnector.ts b/Node/src/TeamsChatConnector.ts index a432df76..77785c31 100644 --- a/Node/src/TeamsChatConnector.ts +++ b/Node/src/TeamsChatConnector.ts @@ -124,31 +124,6 @@ export class TeamsChatConnector extends builder.ChatConnector { }); } - /** - * @deprecated Since version 0.1.2 Will be deleted in version 0.1.5. Use fetchMembers(serverUrl, conversationId, callback). - * Return a list of members in a conversation or channel - * @param {string} serverUrl - Server url is composed of baseUrl and cloud name, remember to find your correct cloud name in session or the function will not find the team. - * @param {string} conversationId - The conversation id or channel id, you can look it up in session object. - * @param {string} tenantId - The tenantId, you can look it up in session object. - * @param {function} callback - This callback returns err or result. - */ - public fetchMemberList(serverUrl: string, conversationId: string, tenantId: string, callback: (err: Error, result: ChannelAccount[]) => void) : void { - var options: msRest.RequestOptions = {customHeaders: {}, jar: false}; - var restClient = new RestClient(serverUrl, null); - var remoteQuery = new RemoteQuery(restClient); - this.getAccessToken((err, token) => { - if (!err && token) { - options.customHeaders = { - 'Authorization': 'Bearer ' + token, - 'X-MsTeamsTenantId' : tenantId - }; - remoteQuery.fetchMemberList(conversationId, options, callback); - } else { - return callback(new Error('Failed to authorize request'), null); - } - }); - } - /** * Return a list of members in a team or channel * @param {string} serverUrl - Server url is composed of baseUrl and cloud name, remember to find your correct cloud name in session or the function will not find the team. diff --git a/Node/src/botbuilder-teams.d.ts b/Node/src/botbuilder-teams.d.ts index c2d4cf36..57bdc2d8 100644 --- a/Node/src/botbuilder-teams.d.ts +++ b/Node/src/botbuilder-teams.d.ts @@ -906,16 +906,6 @@ export class TeamsChatConnector extends builder.ChatConnector { */ public fetchTeamInfo(serviceUrl: string, teamId: string, callback: (err: Error, result: TeamInfo) => void) : void; - /** - * @deprecated Since version 0.1.2 Will be deleted in version 0.1.5. Use fetchMembers(serviceUrl, conversationId, callback). - * Return a list of members in a conversation or channel. - * @param {string} serviceUrl - The team's service url, which should be taken from a previous message received from that team. If the wrong service url is used, the team will not be found and the method wil fail. - * @param {string} conversationId - The conversation id or channel id, you can look it up in session object. - * @param {string} tenantId - The tenantId, you can look it up in session object. - * @param {function} callback - This callback returns err or result. - */ - public fetchMemberList(serviceUrl: string, conversationId: string, tenantId: string, callback: (err: Error, result: ChannelAccount[]) => void) : void; - /** * Return a list of members in team or chat. * @param {string} serviceUrl - The service url for the team or chat, which should be taken from a previous message received from that team or chat. If the wrong service url is used, the method wil fail.