@kodelyth/msteams 2026.5.39 → 2026.5.42

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (208) hide show
  1. package/api.ts +3 -0
  2. package/channel-config-api.ts +1 -0
  3. package/channel-plugin-api.ts +2 -0
  4. package/config-api.ts +4 -0
  5. package/contract-api.ts +4 -0
  6. package/dist/api.js +3 -0
  7. package/dist/channel-BvTXHuGs.js +1161 -0
  8. package/dist/channel-config-api.js +2 -0
  9. package/dist/channel-plugin-api.js +2 -0
  10. package/dist/channel.runtime-NssGKZm5.js +650 -0
  11. package/dist/config-schema-Btk-XCOd.js +43 -0
  12. package/dist/contract-api.js +2 -0
  13. package/dist/graph-users-D-gKCguI.js +1411 -0
  14. package/dist/index.js +22 -0
  15. package/dist/oauth-BUxlphX3.js +114 -0
  16. package/dist/oauth.token-ebId9946.js +116 -0
  17. package/dist/probe-Cj2KsAGF.js +2190 -0
  18. package/dist/runtime-api-BL4DOWXD.js +28 -0
  19. package/dist/runtime-api.js +2 -0
  20. package/dist/secret-contract-Bo7kdUrT.js +35 -0
  21. package/dist/secret-contract-api.js +2 -0
  22. package/dist/setup-entry.js +15 -0
  23. package/dist/setup-plugin-api.js +64 -0
  24. package/dist/setup-surface-COTQDcTQ.js +531 -0
  25. package/dist/src-tvpsGYPV.js +4226 -0
  26. package/dist/test-api.js +2 -0
  27. package/index.ts +20 -0
  28. package/klaw.plugin.json +2 -726
  29. package/package.json +4 -4
  30. package/runtime-api.ts +66 -0
  31. package/secret-contract-api.ts +5 -0
  32. package/setup-entry.ts +13 -0
  33. package/setup-plugin-api.ts +3 -0
  34. package/src/ai-entity.ts +7 -0
  35. package/src/approval-auth.ts +44 -0
  36. package/src/attachments/bot-framework.test.ts +506 -0
  37. package/src/attachments/bot-framework.ts +348 -0
  38. package/src/attachments/download.ts +328 -0
  39. package/src/attachments/graph.test.ts +441 -0
  40. package/src/attachments/graph.ts +489 -0
  41. package/src/attachments/html.ts +122 -0
  42. package/src/attachments/payload.ts +14 -0
  43. package/src/attachments/remote-media.test.ts +187 -0
  44. package/src/attachments/remote-media.ts +86 -0
  45. package/src/attachments/shared.test.ts +547 -0
  46. package/src/attachments/shared.ts +655 -0
  47. package/src/attachments/types.ts +47 -0
  48. package/src/attachments.graph.test.ts +414 -0
  49. package/src/attachments.helpers.test.ts +245 -0
  50. package/src/attachments.test-helpers.ts +17 -0
  51. package/src/attachments.test.ts +754 -0
  52. package/src/attachments.ts +18 -0
  53. package/src/block-streaming-config.test.ts +61 -0
  54. package/src/channel-api.ts +1 -0
  55. package/src/channel.actions.test.ts +797 -0
  56. package/src/channel.directory.test.ts +176 -0
  57. package/src/channel.message-adapter.test.ts +227 -0
  58. package/src/channel.runtime.ts +56 -0
  59. package/src/channel.setup.ts +77 -0
  60. package/src/channel.test.ts +136 -0
  61. package/src/channel.ts +1176 -0
  62. package/src/config-schema.ts +6 -0
  63. package/src/config-ui-hints.ts +40 -0
  64. package/src/conversation-store-fs.test.ts +81 -0
  65. package/src/conversation-store-fs.ts +149 -0
  66. package/src/conversation-store-helpers.test.ts +202 -0
  67. package/src/conversation-store-helpers.ts +105 -0
  68. package/src/conversation-store-memory.ts +51 -0
  69. package/src/conversation-store.shared.test.ts +260 -0
  70. package/src/conversation-store.ts +71 -0
  71. package/src/directory-live.test.ts +156 -0
  72. package/src/directory-live.ts +111 -0
  73. package/src/doctor.ts +27 -0
  74. package/src/errors.test.ts +154 -0
  75. package/src/errors.ts +270 -0
  76. package/src/feedback-reflection-prompt.ts +117 -0
  77. package/src/feedback-reflection-store.ts +113 -0
  78. package/src/feedback-reflection.test.ts +237 -0
  79. package/src/feedback-reflection.ts +268 -0
  80. package/src/file-consent-helpers.test.ts +328 -0
  81. package/src/file-consent-helpers.ts +115 -0
  82. package/src/file-consent-invoke.ts +150 -0
  83. package/src/file-consent.test.ts +378 -0
  84. package/src/file-consent.ts +223 -0
  85. package/src/graph-chat.ts +36 -0
  86. package/src/graph-group-management.test.ts +332 -0
  87. package/src/graph-group-management.ts +168 -0
  88. package/src/graph-members.test.ts +89 -0
  89. package/src/graph-members.ts +48 -0
  90. package/src/graph-messages.actions.test.ts +253 -0
  91. package/src/graph-messages.read.test.ts +391 -0
  92. package/src/graph-messages.search.test.ts +227 -0
  93. package/src/graph-messages.test-helpers.ts +50 -0
  94. package/src/graph-messages.ts +534 -0
  95. package/src/graph-teams.test.ts +222 -0
  96. package/src/graph-teams.ts +114 -0
  97. package/src/graph-thread.test.ts +252 -0
  98. package/src/graph-thread.ts +146 -0
  99. package/src/graph-upload.test.ts +253 -0
  100. package/src/graph-upload.ts +531 -0
  101. package/src/graph-users.ts +29 -0
  102. package/src/graph.test.ts +540 -0
  103. package/src/graph.ts +308 -0
  104. package/src/inbound.test.ts +221 -0
  105. package/src/inbound.ts +148 -0
  106. package/src/index.ts +4 -0
  107. package/src/media-helpers.test.ts +220 -0
  108. package/src/media-helpers.ts +105 -0
  109. package/src/mentions.test.ts +254 -0
  110. package/src/mentions.ts +114 -0
  111. package/src/messenger.test.ts +961 -0
  112. package/src/messenger.ts +608 -0
  113. package/src/monitor-handler/access.ts +136 -0
  114. package/src/monitor-handler/inbound-media.test.ts +314 -0
  115. package/src/monitor-handler/inbound-media.ts +180 -0
  116. package/src/monitor-handler/message-handler-mock-support.test-support.ts +28 -0
  117. package/src/monitor-handler/message-handler.authz.test.ts +739 -0
  118. package/src/monitor-handler/message-handler.dm-media.test.ts +54 -0
  119. package/src/monitor-handler/message-handler.test-support.ts +99 -0
  120. package/src/monitor-handler/message-handler.thread-parent.test.ts +225 -0
  121. package/src/monitor-handler/message-handler.thread-session.test.ts +132 -0
  122. package/src/monitor-handler/message-handler.ts +1003 -0
  123. package/src/monitor-handler/reaction-handler.test.ts +325 -0
  124. package/src/monitor-handler/reaction-handler.ts +122 -0
  125. package/src/monitor-handler/thread-session.ts +30 -0
  126. package/src/monitor-handler.adaptive-card.test.ts +158 -0
  127. package/src/monitor-handler.feedback-authz.test.ts +357 -0
  128. package/src/monitor-handler.file-consent.test.ts +443 -0
  129. package/src/monitor-handler.sso.test.ts +576 -0
  130. package/src/monitor-handler.test-helpers.ts +181 -0
  131. package/src/monitor-handler.ts +538 -0
  132. package/src/monitor-handler.types.ts +27 -0
  133. package/src/monitor-types.ts +6 -0
  134. package/src/monitor.lifecycle.test.ts +457 -0
  135. package/src/monitor.test.ts +119 -0
  136. package/src/monitor.ts +476 -0
  137. package/src/oauth.flow.ts +77 -0
  138. package/src/oauth.shared.ts +37 -0
  139. package/src/oauth.test.ts +350 -0
  140. package/src/oauth.token.ts +162 -0
  141. package/src/oauth.ts +130 -0
  142. package/src/outbound.test.ts +400 -0
  143. package/src/outbound.ts +198 -0
  144. package/src/pending-uploads-fs.test.ts +261 -0
  145. package/src/pending-uploads-fs.ts +235 -0
  146. package/src/pending-uploads.test.ts +186 -0
  147. package/src/pending-uploads.ts +121 -0
  148. package/src/policy.test.ts +156 -0
  149. package/src/policy.ts +245 -0
  150. package/src/polls-store-memory.ts +32 -0
  151. package/src/polls.test.ts +169 -0
  152. package/src/polls.ts +312 -0
  153. package/src/presentation.ts +93 -0
  154. package/src/probe.test.ts +79 -0
  155. package/src/probe.ts +132 -0
  156. package/src/reply-dispatcher.test.ts +543 -0
  157. package/src/reply-dispatcher.ts +523 -0
  158. package/src/reply-stream-controller.test.ts +424 -0
  159. package/src/reply-stream-controller.ts +334 -0
  160. package/src/resolve-allowlist.test.ts +253 -0
  161. package/src/resolve-allowlist.ts +309 -0
  162. package/src/revoked-context.ts +17 -0
  163. package/src/runtime.ts +12 -0
  164. package/src/sdk-types.ts +59 -0
  165. package/src/sdk.test.ts +727 -0
  166. package/src/sdk.ts +916 -0
  167. package/src/secret-contract.ts +49 -0
  168. package/src/secret-input.ts +7 -0
  169. package/src/send-context.test.ts +93 -0
  170. package/src/send-context.ts +269 -0
  171. package/src/send.test.ts +588 -0
  172. package/src/send.ts +697 -0
  173. package/src/sent-message-cache.test.ts +106 -0
  174. package/src/sent-message-cache.ts +174 -0
  175. package/src/session-route.ts +40 -0
  176. package/src/setup-core.ts +162 -0
  177. package/src/setup-surface.test.ts +175 -0
  178. package/src/setup-surface.ts +319 -0
  179. package/src/sso-token-store.test.ts +74 -0
  180. package/src/sso-token-store.ts +166 -0
  181. package/src/sso.ts +300 -0
  182. package/src/storage.ts +25 -0
  183. package/src/store-fs.ts +42 -0
  184. package/src/streaming-message.test.ts +323 -0
  185. package/src/streaming-message.ts +327 -0
  186. package/src/test-runtime.ts +16 -0
  187. package/src/thread-parent-context.test.ts +224 -0
  188. package/src/thread-parent-context.ts +159 -0
  189. package/src/token-response.ts +11 -0
  190. package/src/token.test.ts +268 -0
  191. package/src/token.ts +194 -0
  192. package/src/user-agent.test.ts +121 -0
  193. package/src/user-agent.ts +53 -0
  194. package/src/webhook-timeouts.ts +27 -0
  195. package/src/welcome-card.test.ts +104 -0
  196. package/src/welcome-card.ts +57 -0
  197. package/test-api.ts +1 -0
  198. package/tsconfig.json +16 -0
  199. package/api.js +0 -7
  200. package/channel-config-api.js +0 -7
  201. package/channel-plugin-api.js +0 -7
  202. package/contract-api.js +0 -7
  203. package/index.js +0 -7
  204. package/runtime-api.js +0 -7
  205. package/secret-contract-api.js +0 -7
  206. package/setup-entry.js +0 -7
  207. package/setup-plugin-api.js +0 -7
  208. package/test-api.js +0 -7
package/dist/index.js ADDED
@@ -0,0 +1,22 @@
1
+ import { defineBundledChannelEntry } from "klaw/plugin-sdk/channel-entry-contract";
2
+ //#region extensions/msteams/index.ts
3
+ var msteams_default = defineBundledChannelEntry({
4
+ id: "msteams",
5
+ name: "Microsoft Teams",
6
+ description: "Microsoft Teams channel plugin (Bot Framework)",
7
+ importMetaUrl: import.meta.url,
8
+ plugin: {
9
+ specifier: "./channel-plugin-api.js",
10
+ exportName: "msteamsPlugin"
11
+ },
12
+ secrets: {
13
+ specifier: "./secret-contract-api.js",
14
+ exportName: "channelSecrets"
15
+ },
16
+ runtime: {
17
+ specifier: "./runtime-api.js",
18
+ exportName: "setMSTeamsRuntime"
19
+ }
20
+ });
21
+ //#endregion
22
+ export { msteams_default as default };
@@ -0,0 +1,114 @@
1
+ import { a as MSTEAMS_OAUTH_CALLBACK_PORT, i as MSTEAMS_OAUTH_CALLBACK_PATH, o as MSTEAMS_OAUTH_REDIRECT_URI, r as MSTEAMS_DEFAULT_DELEGATED_SCOPES, s as buildMSTeamsAuthEndpoint, t as exchangeMSTeamsCodeForTokens } from "./oauth.token-ebId9946.js";
2
+ import { generateHexPkceVerifierChallenge } from "klaw/plugin-sdk/provider-auth";
3
+ import { generateOAuthState, parseOAuthCallbackInput, waitForLocalOAuthCallback } from "klaw/plugin-sdk/provider-auth-runtime";
4
+ import { isWSL2Sync } from "klaw/plugin-sdk/runtime-env";
5
+ //#region extensions/msteams/src/oauth.flow.ts
6
+ function shouldUseManualOAuthFlow(isRemote) {
7
+ return isRemote || isWSL2Sync();
8
+ }
9
+ function generatePkce() {
10
+ return generateHexPkceVerifierChallenge();
11
+ }
12
+ function buildMSTeamsAuthUrl(params) {
13
+ const scopes = params.scopes ?? MSTEAMS_DEFAULT_DELEGATED_SCOPES;
14
+ return `${buildMSTeamsAuthEndpoint(params.tenantId)}?${new URLSearchParams({
15
+ client_id: params.clientId,
16
+ response_type: "code",
17
+ redirect_uri: MSTEAMS_OAUTH_REDIRECT_URI,
18
+ scope: scopes.join(" "),
19
+ code_challenge: params.challenge,
20
+ code_challenge_method: "S256",
21
+ state: params.state,
22
+ prompt: "consent"
23
+ }).toString()}`;
24
+ }
25
+ function parseCallbackInput(input, _expectedState) {
26
+ return parseOAuthCallbackInput(input, {
27
+ missingState: "Missing 'state' parameter in URL. Paste the full redirect URL.",
28
+ invalidInput: "Paste the full redirect URL (including code and state parameters), not just the authorization code."
29
+ });
30
+ }
31
+ async function waitForLocalCallback(params) {
32
+ return await waitForLocalOAuthCallback({
33
+ expectedState: params.expectedState,
34
+ timeoutMs: params.timeoutMs,
35
+ port: MSTEAMS_OAUTH_CALLBACK_PORT,
36
+ callbackPath: MSTEAMS_OAUTH_CALLBACK_PATH,
37
+ redirectUri: MSTEAMS_OAUTH_REDIRECT_URI,
38
+ successTitle: "MSTeams Delegated OAuth complete",
39
+ progressMessage: `Waiting for OAuth callback on ${MSTEAMS_OAUTH_REDIRECT_URI}...`,
40
+ onProgress: params.onProgress
41
+ });
42
+ }
43
+ //#endregion
44
+ //#region extensions/msteams/src/oauth.ts
45
+ async function loginMSTeamsDelegated(ctx, params) {
46
+ const scopes = params.scopes ?? MSTEAMS_DEFAULT_DELEGATED_SCOPES;
47
+ const needsManual = shouldUseManualOAuthFlow(ctx.isRemote);
48
+ await ctx.note(needsManual ? [
49
+ "You are running in a remote/VPS environment.",
50
+ "A URL will be shown for you to open in your LOCAL browser.",
51
+ "After signing in, copy the redirect URL and paste it back here."
52
+ ].join("\n") : [
53
+ "Browser will open for Microsoft authentication.",
54
+ `Sign in to grant delegated permissions for MSTeams.`,
55
+ `The callback will be captured automatically on localhost:${MSTEAMS_OAUTH_CALLBACK_PORT}.`
56
+ ].join("\n"), "MSTeams Delegated OAuth");
57
+ const { verifier, challenge } = generatePkce();
58
+ const state = generateOAuthState();
59
+ const authUrl = buildMSTeamsAuthUrl({
60
+ tenantId: params.tenantId,
61
+ clientId: params.clientId,
62
+ challenge,
63
+ state,
64
+ scopes
65
+ });
66
+ if (needsManual) return manualFlow(ctx, authUrl, state, verifier, params);
67
+ ctx.progress.update("Complete sign-in in browser...");
68
+ try {
69
+ await ctx.openUrl(authUrl);
70
+ } catch {
71
+ ctx.log(`\nOpen this URL in your browser:\n\n${authUrl}\n`);
72
+ }
73
+ try {
74
+ const { code } = await waitForLocalCallback({
75
+ expectedState: state,
76
+ timeoutMs: 300 * 1e3,
77
+ onProgress: (msg) => ctx.progress.update(msg)
78
+ });
79
+ ctx.progress.update("Exchanging authorization code for tokens...");
80
+ return await exchangeMSTeamsCodeForTokens({
81
+ tenantId: params.tenantId,
82
+ clientId: params.clientId,
83
+ clientSecret: params.clientSecret,
84
+ code,
85
+ verifier,
86
+ scopes
87
+ });
88
+ } catch (err) {
89
+ if (err instanceof Error && (err.message.includes("EADDRINUSE") || err.message.includes("port") || err.message.includes("listen"))) {
90
+ ctx.progress.update("Local callback server failed. Switching to manual mode...");
91
+ return manualFlow(ctx, authUrl, state, verifier, params, err);
92
+ }
93
+ throw err;
94
+ }
95
+ }
96
+ async function manualFlow(ctx, authUrl, state, verifier, params, cause) {
97
+ ctx.progress.update("OAuth URL ready");
98
+ ctx.log(`\nOpen this URL in your LOCAL browser:\n\n${authUrl}\n`);
99
+ ctx.progress.update("Waiting for you to paste the callback URL...");
100
+ const parsed = parseCallbackInput(await ctx.prompt("Paste the redirect URL here: "), state);
101
+ if ("error" in parsed) throw new Error(parsed.error, cause ? { cause } : void 0);
102
+ if (parsed.state !== state) throw new Error("OAuth state mismatch - please try again", cause ? { cause } : void 0);
103
+ ctx.progress.update("Exchanging authorization code for tokens...");
104
+ return exchangeMSTeamsCodeForTokens({
105
+ tenantId: params.tenantId,
106
+ clientId: params.clientId,
107
+ clientSecret: params.clientSecret,
108
+ code: parsed.code,
109
+ verifier,
110
+ scopes: params.scopes
111
+ });
112
+ }
113
+ //#endregion
114
+ export { loginMSTeamsDelegated };
@@ -0,0 +1,116 @@
1
+ import { fetchWithSsrFGuard } from "klaw/plugin-sdk/ssrf-runtime";
2
+ import { readProviderJsonResponse } from "klaw/plugin-sdk/provider-http";
3
+ //#region extensions/msteams/src/oauth.shared.ts
4
+ const MSTEAMS_OAUTH_REDIRECT_URI = "http://localhost:8086/oauth2callback";
5
+ const MSTEAMS_OAUTH_CALLBACK_PORT = 8086;
6
+ const MSTEAMS_OAUTH_CALLBACK_PATH = "/oauth2callback";
7
+ const MSTEAMS_DEFAULT_TOKEN_FETCH_TIMEOUT_MS = 1e4;
8
+ const MSTEAMS_DEFAULT_DELEGATED_SCOPES = [
9
+ "ChatMessage.Send",
10
+ "ChannelMessage.Send",
11
+ "Chat.ReadWrite",
12
+ "offline_access"
13
+ ];
14
+ function buildMSTeamsAuthEndpoint(tenantId) {
15
+ return `https://login.microsoftonline.com/${encodeURIComponent(tenantId)}/oauth2/v2.0/authorize`;
16
+ }
17
+ function buildMSTeamsTokenEndpoint(tenantId) {
18
+ return `https://login.microsoftonline.com/${encodeURIComponent(tenantId)}/oauth2/v2.0/token`;
19
+ }
20
+ //#endregion
21
+ //#region extensions/msteams/src/oauth.token.ts
22
+ /** Five-minute buffer subtracted from token expiry to avoid edge-case clock drift. */
23
+ const EXPIRY_BUFFER_MS = 300 * 1e3;
24
+ function createMSTeamsTokenBody(params) {
25
+ const body = new URLSearchParams({
26
+ client_id: params.clientId,
27
+ client_secret: params.clientSecret,
28
+ grant_type: params.grantType,
29
+ scope: [...params.scopes].join(" ")
30
+ });
31
+ for (const [key, value] of Object.entries(params.values ?? {})) body.set(key, value);
32
+ return body;
33
+ }
34
+ async function fetchMSTeamsTokens(params) {
35
+ const currentFetch = globalThis.fetch;
36
+ const { response, release } = await fetchWithSsrFGuard({
37
+ url: params.tokenUrl,
38
+ fetchImpl: async (input, guardedInit) => await currentFetch(input, guardedInit),
39
+ init: {
40
+ method: "POST",
41
+ headers: {
42
+ "Content-Type": "application/x-www-form-urlencoded;charset=UTF-8",
43
+ Accept: "application/json"
44
+ },
45
+ body: params.body,
46
+ signal: AbortSignal.timeout(MSTEAMS_DEFAULT_TOKEN_FETCH_TIMEOUT_MS)
47
+ },
48
+ auditContext: params.auditContext
49
+ });
50
+ try {
51
+ if (!response.ok) {
52
+ const errorText = await response.text();
53
+ throw new Error(`MSTeams ${params.failureLabel} failed (${response.status}): ${errorText}`);
54
+ }
55
+ return await readProviderJsonResponse(response, `MSTeams ${params.failureLabel} failed`);
56
+ } finally {
57
+ await release();
58
+ }
59
+ }
60
+ async function requestMSTeamsDelegatedTokens(params) {
61
+ const scopes = params.scopes ?? MSTEAMS_DEFAULT_DELEGATED_SCOPES;
62
+ const body = createMSTeamsTokenBody({
63
+ clientId: params.clientId,
64
+ clientSecret: params.clientSecret,
65
+ grantType: params.grantType,
66
+ scopes,
67
+ values: params.values
68
+ });
69
+ const data = await fetchMSTeamsTokens({
70
+ tokenUrl: buildMSTeamsTokenEndpoint(params.tenantId),
71
+ body,
72
+ auditContext: params.auditContext,
73
+ failureLabel: params.failureLabel
74
+ });
75
+ return {
76
+ accessToken: data.access_token,
77
+ refreshToken: params.resolveRefreshToken(data),
78
+ expiresAt: Date.now() + data.expires_in * 1e3 - EXPIRY_BUFFER_MS,
79
+ scopes: data.scope ? data.scope.split(" ") : [...scopes]
80
+ };
81
+ }
82
+ async function exchangeMSTeamsCodeForTokens(params) {
83
+ return await requestMSTeamsDelegatedTokens({
84
+ tenantId: params.tenantId,
85
+ clientId: params.clientId,
86
+ clientSecret: params.clientSecret,
87
+ grantType: "authorization_code",
88
+ scopes: params.scopes,
89
+ values: {
90
+ code: params.code,
91
+ redirect_uri: MSTEAMS_OAUTH_REDIRECT_URI,
92
+ code_verifier: params.verifier
93
+ },
94
+ auditContext: "msteams-oauth-token-exchange",
95
+ failureLabel: "token exchange",
96
+ resolveRefreshToken: (data) => {
97
+ if (!data.refresh_token) throw new Error("No refresh token received from Azure AD. Please try again.");
98
+ return data.refresh_token;
99
+ }
100
+ });
101
+ }
102
+ async function refreshMSTeamsDelegatedTokens(params) {
103
+ return await requestMSTeamsDelegatedTokens({
104
+ tenantId: params.tenantId,
105
+ clientId: params.clientId,
106
+ clientSecret: params.clientSecret,
107
+ grantType: "refresh_token",
108
+ scopes: params.scopes,
109
+ values: { refresh_token: params.refreshToken },
110
+ auditContext: "msteams-oauth-token-refresh",
111
+ failureLabel: "token refresh",
112
+ resolveRefreshToken: (data) => data.refresh_token ?? params.refreshToken
113
+ });
114
+ }
115
+ //#endregion
116
+ export { MSTEAMS_OAUTH_CALLBACK_PORT as a, MSTEAMS_OAUTH_CALLBACK_PATH as i, refreshMSTeamsDelegatedTokens as n, MSTEAMS_OAUTH_REDIRECT_URI as o, MSTEAMS_DEFAULT_DELEGATED_SCOPES as r, buildMSTeamsAuthEndpoint as s, exchangeMSTeamsCodeForTokens as t };