@microsoft/teamsfx 2.2.3-alpha.dea6b9e8a.0 → 2.2.3-alpha.ebba7eb40.0

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.
@@ -773,8 +773,10 @@ class TeamsUserCredential {
773
773
 
774
774
  // Copyright (c) Microsoft Corporation.
775
775
  const defaultScope = "https://graph.microsoft.com/.default";
776
+ // eslint-disable-next-line no-secrets/no-secrets
776
777
  /**
777
778
  * Microsoft Graph auth provider for Teams Framework
779
+ * @deprecated Use `TokenCredentialAuthenticationProvider` from `@microsoft/microsoft-graph-client/authProviders/azureTokenCredentials` instead.
778
780
  */
779
781
  class MsGraphAuthProvider {
780
782
  constructor(credentialOrTeamsFx, scopes) {
@@ -831,6 +833,14 @@ class MsGraphAuthProvider {
831
833
  // Copyright (c) Microsoft Corporation.
832
834
  /**
833
835
  * Get Microsoft graph client.
836
+ * @deprecated Use `TokenCredentialAuthenticationProvider` and `Client.initWithMiddleware` instead.
837
+ * ```typescript
838
+ * const authProvider = new TokenCredentialAuthenticationProvider(credential, { scopes: scope });
839
+ * const graph = Client.initWithMiddleware({
840
+ * authProvider: authProvider,
841
+ * });
842
+ * ```
843
+ *
834
844
  * @example
835
845
  * Get Microsoft graph client by TokenCredential
836
846
  * ```typescript
@@ -888,6 +898,14 @@ function createMicrosoftGraphClient(teamsfx, scopes) {
888
898
  // eslint-disable-next-line no-secrets/no-secrets
889
899
  /**
890
900
  * Get Microsoft graph client.
901
+ * @deprecated Use `TokenCredentialAuthenticationProvider` and `Client.initWithMiddleware` instead.
902
+ * ```typescript
903
+ * const authProvider = new TokenCredentialAuthenticationProvider(credential, { scopes: scope });
904
+ * const graph = Client.initWithMiddleware({
905
+ * authProvider: authProvider,
906
+ * });
907
+ * ```
908
+ *
891
909
  * @example
892
910
  * Get Microsoft graph client by TokenCredential
893
911
  * ```typescript
@@ -1787,6 +1805,8 @@ const ReservedKey = new Set([
1787
1805
  ]);
1788
1806
  /**
1789
1807
  * A class providing credential and configuration.
1808
+ * @deprecated Please use {@link TeamsUserCredential}
1809
+ * in browser environment and {@link OnBehalfOfUserCredential} or {@link AppCredential} in NodeJS.
1790
1810
  */
1791
1811
  class TeamsFx {
1792
1812
  /**
@@ -3608,8 +3628,7 @@ class DefaultBotSsoExecutionActivityHandler extends botbuilder.TeamsActivityHand
3608
3628
  timeout: (_h = (_g = ssoConfig.dialog) === null || _g === void 0 ? void 0 : _g.ssoPromptConfig) === null || _h === void 0 ? void 0 : _h.timeout,
3609
3629
  endOnInvalidMessage: (_k = (_j = ssoConfig.dialog) === null || _j === void 0 ? void 0 : _j.ssoPromptConfig) === null || _k === void 0 ? void 0 : _k.endOnInvalidMessage,
3610
3630
  };
3611
- const teamsfx = new TeamsFx(exports.IdentityType.User, Object.assign({}, customConfig));
3612
- this.ssoExecutionDialog = new BotSsoExecutionDialog(dedupStorage, settings, teamsfx);
3631
+ this.ssoExecutionDialog = new BotSsoExecutionDialog(dedupStorage, settings, customConfig, customConfig.initiateLoginEndpoint);
3613
3632
  this.conversationState = conversationState;
3614
3633
  this.dialogState = conversationState.createProperty("DialogState");
3615
3634
  this.userState = userState;
@@ -4064,6 +4083,7 @@ function executionWithTokenAndConfig(context, authConfig, initiateLoginEndpoint,
4064
4083
  }
4065
4084
  /**
4066
4085
  * execution in message extension with SSO token.
4086
+ * @deprecated Use {@link executionWithTokenAndConfig} instead.
4067
4087
  *
4068
4088
  * @param {TurnContext} context - The context object for the current turn.
4069
4089
  * @param {AuthenticationConfiguration} config - User custom the message extension authentication configuration.
@@ -4114,7 +4134,7 @@ function executionWithToken(context, config, scopes, logic) {
4114
4134
  // eslint-disable-next-line no-secrets/no-secrets
4115
4135
  /**
4116
4136
  * Users execute query in message extension with SSO or access token.
4117
- *
4137
+ * @deprecated Use {@link handleMessageExtensionQueryWithSSO} instead.
4118
4138
  *
4119
4139
  * @param {TurnContext} context - The context object for the current turn.
4120
4140
  * @param {AuthenticationConfiguration} config - User custom the message extension authentication configuration.