@microsoft/teams-js 2.21.1-beta.0 → 2.22.0-beta.0
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/MicrosoftTeams.d.ts +379 -54
- package/dist/MicrosoftTeams.js +725 -1424
- package/dist/MicrosoftTeams.js.map +1 -1
- package/dist/MicrosoftTeams.min.js +1 -1
- package/dist/MicrosoftTeams.min.js.map +1 -1
- package/package.json +1 -1
package/dist/MicrosoftTeams.d.ts
CHANGED
@@ -61,7 +61,7 @@ export interface ThreadMember {
|
|
61
61
|
* @internal
|
62
62
|
* Limited to Microsoft-internal use
|
63
63
|
*/
|
64
|
-
export enum NotificationTypes {
|
64
|
+
export const enum NotificationTypes {
|
65
65
|
fileDownloadStart = "fileDownloadStart",
|
66
66
|
fileDownloadComplete = "fileDownloadComplete"
|
67
67
|
}
|
@@ -81,7 +81,7 @@ export interface ShowNotificationParameters {
|
|
81
81
|
* @internal
|
82
82
|
* Limited to Microsoft-internal use
|
83
83
|
*/
|
84
|
-
export enum ViewerActionTypes {
|
84
|
+
export const enum ViewerActionTypes {
|
85
85
|
view = "view",
|
86
86
|
edit = "edit",
|
87
87
|
editNew = "editNew"
|
@@ -91,7 +91,7 @@ export enum ViewerActionTypes {
|
|
91
91
|
*
|
92
92
|
* User setting changes that can be subscribed to
|
93
93
|
*/
|
94
|
-
export enum UserSettingTypes {
|
94
|
+
export const enum UserSettingTypes {
|
95
95
|
/**
|
96
96
|
* @hidden
|
97
97
|
* Use this key to subscribe to changes in user's file open preference
|
@@ -502,6 +502,31 @@ export namespace externalAppAuthentication {
|
|
502
502
|
* Limited to Microsoft-internal use
|
503
503
|
*/
|
504
504
|
type IOriginalRequestInfo = IQueryMessageExtensionRequest | IActionExecuteInvokeRequest;
|
505
|
+
/**
|
506
|
+
* @hidden
|
507
|
+
* Parameters OauthWindow
|
508
|
+
* @internal
|
509
|
+
* Limited to Microsoft-internal use
|
510
|
+
*/
|
511
|
+
type OauthWindowProperties = {
|
512
|
+
/**
|
513
|
+
* The preferred width for the pop-up. This value can be ignored if outside the acceptable bounds.
|
514
|
+
*/
|
515
|
+
width?: number;
|
516
|
+
/**
|
517
|
+
* The preferred height for the pop-up. This value can be ignored if outside the acceptable bounds.
|
518
|
+
*/
|
519
|
+
height?: number;
|
520
|
+
/**
|
521
|
+
* Some identity providers restrict their authentication pages from being displayed in embedded browsers (e.g., a web view inside of a native application)
|
522
|
+
* If the identity provider you are using prevents embedded browser usage, this flag should be set to `true` to enable the authentication page
|
523
|
+
* to be opened in an external browser. If this flag is `false`, the page will be opened directly within the current hosting application.
|
524
|
+
*
|
525
|
+
* This flag is ignored when the host for the application is a web app (as opposed to a native application) as the behavior is unnecessary in a web-only
|
526
|
+
* environment without an embedded browser.
|
527
|
+
*/
|
528
|
+
isExternal?: boolean;
|
529
|
+
};
|
505
530
|
/**
|
506
531
|
* @hidden
|
507
532
|
* Parameters for the authentication pop-up. This interface is used exclusively with the externalAppAuthentication APIs
|
@@ -585,7 +610,7 @@ export namespace externalAppAuthentication {
|
|
585
610
|
* @internal
|
586
611
|
* Limited to Microsoft-internal use
|
587
612
|
*/
|
588
|
-
enum OriginalRequestType {
|
613
|
+
const enum OriginalRequestType {
|
589
614
|
ActionExecuteInvokeRequest = "ActionExecuteInvokeRequest",
|
590
615
|
QueryMessageExtensionRequest = "QueryMessageExtensionRequest"
|
591
616
|
}
|
@@ -602,7 +627,7 @@ export namespace externalAppAuthentication {
|
|
602
627
|
* @internal
|
603
628
|
* Limited to Microsoft-internal use
|
604
629
|
*/
|
605
|
-
enum InvokeResponseType {
|
630
|
+
const enum InvokeResponseType {
|
606
631
|
ActionExecuteInvokeResponse = "ActionExecuteInvokeResponse",
|
607
632
|
QueryMessageExtensionResponse = "QueryMessageExtensionResponse"
|
608
633
|
}
|
@@ -708,7 +733,7 @@ export namespace externalAppAuthentication {
|
|
708
733
|
* @internal
|
709
734
|
* Limited to Microsoft-internal use
|
710
735
|
*/
|
711
|
-
enum InvokeErrorCode {
|
736
|
+
const enum InvokeErrorCode {
|
712
737
|
INTERNAL_ERROR = "INTERNAL_ERROR"
|
713
738
|
}
|
714
739
|
/**
|
@@ -746,6 +771,18 @@ export namespace externalAppAuthentication {
|
|
746
771
|
* @returns A promise that resolves to the IInvokeResponse from the application backend and rejects with InvokeError if the host encounters an error while authenticating or resending the request
|
747
772
|
*/
|
748
773
|
function authenticateWithSSOAndResendRequest(appId: string, authTokenRequest: AuthTokenRequestParameters, originalRequestInfo: IOriginalRequestInfo): Promise<IInvokeResponse>;
|
774
|
+
/**
|
775
|
+
* @beta
|
776
|
+
* @hidden
|
777
|
+
* Signals to the host to perform Oauth2 authentication for the application specified by the title ID
|
778
|
+
* @internal
|
779
|
+
* Limited to Microsoft-internal use
|
780
|
+
* @param titleId ID of the acquisition
|
781
|
+
* @param oauthConfigId lookup ID in token store
|
782
|
+
* @param oauthWindowParameters parameters for the signIn window
|
783
|
+
* @returns A promise that resolves when authentication succeeds and rejects with InvokeError on failure
|
784
|
+
*/
|
785
|
+
function authenticateWithOauth2(titleId: string, oauthConfigId: string, oauthWindowParameters: OauthWindowProperties): Promise<void>;
|
749
786
|
/**
|
750
787
|
* @hidden
|
751
788
|
* Checks if the externalAppAuthentication capability is supported by the host
|
@@ -772,7 +809,7 @@ export namespace externalAppCardActions {
|
|
772
809
|
* @internal
|
773
810
|
* Limited to Microsoft-internal use
|
774
811
|
*/
|
775
|
-
enum ActionOpenUrlType {
|
812
|
+
const enum ActionOpenUrlType {
|
776
813
|
DeepLinkDialog = "DeepLinkDialog",
|
777
814
|
DeepLinkOther = "DeepLinkOther",
|
778
815
|
DeepLinkStageView = "DeepLinkStageView",
|
@@ -795,7 +832,7 @@ export namespace externalAppCardActions {
|
|
795
832
|
* @internal
|
796
833
|
* Limited to Microsoft-internal use
|
797
834
|
*/
|
798
|
-
enum ActionOpenUrlErrorCode {
|
835
|
+
const enum ActionOpenUrlErrorCode {
|
799
836
|
INTERNAL_ERROR = "INTERNAL_ERROR",
|
800
837
|
INVALID_LINK = "INVALID_LINK",
|
801
838
|
NOT_SUPPORTED = "NOT_SUPPORTED"
|
@@ -819,18 +856,9 @@ export namespace externalAppCardActions {
|
|
819
856
|
* Limited to Microsoft-internal use
|
820
857
|
*/
|
821
858
|
interface ActionSubmitError {
|
822
|
-
errorCode:
|
859
|
+
errorCode: ExternalAppErrorCode;
|
823
860
|
message?: string;
|
824
861
|
}
|
825
|
-
/**
|
826
|
-
* @hidden
|
827
|
-
* Error codes that can be thrown from IExternalAppCardActionService.handleActionSubmit
|
828
|
-
* @internal
|
829
|
-
* Limited to Microsoft-internal use
|
830
|
-
*/
|
831
|
-
enum ActionSubmitErrorCode {
|
832
|
-
INTERNAL_ERROR = "INTERNAL_ERROR"
|
833
|
-
}
|
834
862
|
/**
|
835
863
|
* @beta
|
836
864
|
* @hidden
|
@@ -846,14 +874,19 @@ export namespace externalAppCardActions {
|
|
846
874
|
/**
|
847
875
|
* @beta
|
848
876
|
* @hidden
|
849
|
-
* Delegates an Adaptive Card Action.OpenUrl request to the host for the application with the provided app ID
|
877
|
+
* Delegates an Adaptive Card Action.OpenUrl request to the host for the application with the provided app ID.
|
878
|
+
* If `fromElement` is not provided, the information from the manifest is used to determine whether the URL can
|
879
|
+
* be processed by the host. Deep link URLs for plugins are not supported and will result in an error.
|
850
880
|
* @internal
|
851
881
|
* Limited to Microsoft-internal use
|
852
882
|
* @param appId ID of the application the request is intended for. This must be a UUID
|
853
883
|
* @param url The URL to open
|
884
|
+
* @param fromElement The element on behalf of which the M365 app is making the request.
|
854
885
|
* @returns Promise that resolves to ActionOpenUrlType indicating the type of URL that was opened on success and rejects with ActionOpenUrlError if the request fails
|
855
886
|
*/
|
856
|
-
function processActionOpenUrl(appId: string, url: URL
|
887
|
+
function processActionOpenUrl(appId: string, url: URL, fromElement?: {
|
888
|
+
name: 'composeExtensions' | 'plugins';
|
889
|
+
}): Promise<ActionOpenUrlType>;
|
857
890
|
/**
|
858
891
|
* @hidden
|
859
892
|
* Checks if the externalAppCardActions capability is supported by the host
|
@@ -867,6 +900,128 @@ export namespace externalAppCardActions {
|
|
867
900
|
function isSupported(): boolean;
|
868
901
|
}
|
869
902
|
|
903
|
+
/**
|
904
|
+
* @hidden
|
905
|
+
* Namespace to delegate the ActionCommand to the host
|
906
|
+
* @internal
|
907
|
+
* Limited to Microsoft-internal use
|
908
|
+
*
|
909
|
+
* @beta
|
910
|
+
*/
|
911
|
+
export namespace externalAppCommands {
|
912
|
+
/**
|
913
|
+
* @hidden
|
914
|
+
* The payload of IActionCommandResponse
|
915
|
+
*
|
916
|
+
* @internal
|
917
|
+
* Limited to Microsoft-internal use
|
918
|
+
*
|
919
|
+
* @beta
|
920
|
+
*/
|
921
|
+
type IActionCommandResponse = ITextActionCommandResponse | ICardActionCommandResponse;
|
922
|
+
/**
|
923
|
+
* @hidden
|
924
|
+
* The payload of IBaseActionCommandResponse
|
925
|
+
*
|
926
|
+
* @internal
|
927
|
+
* Limited to Microsoft-internal use
|
928
|
+
*
|
929
|
+
* @beta
|
930
|
+
*/
|
931
|
+
interface IBaseActionCommandResponse {
|
932
|
+
taskModuleClosedReason: TaskModuleClosedReason;
|
933
|
+
}
|
934
|
+
/**
|
935
|
+
* @hidden
|
936
|
+
* The text result type
|
937
|
+
*
|
938
|
+
* @internal
|
939
|
+
* Limited to Microsoft-internal use
|
940
|
+
*
|
941
|
+
* @beta
|
942
|
+
*/
|
943
|
+
interface ITextActionCommandResponse extends IBaseActionCommandResponse {
|
944
|
+
resultType: 'text';
|
945
|
+
text: string | undefined;
|
946
|
+
}
|
947
|
+
/**
|
948
|
+
* @hidden
|
949
|
+
* The card result type
|
950
|
+
*
|
951
|
+
* @internal
|
952
|
+
* Limited to Microsoft-internal use
|
953
|
+
*
|
954
|
+
* @beta
|
955
|
+
*/
|
956
|
+
interface ICardActionCommandResponse extends IBaseActionCommandResponse {
|
957
|
+
resultType: 'card';
|
958
|
+
attachmentLayout: externalAppAuthentication.AttachmentLayout;
|
959
|
+
attachments: externalAppAuthentication.QueryMessageExtensionAttachment[];
|
960
|
+
}
|
961
|
+
/**
|
962
|
+
* @hidden
|
963
|
+
* The result type for the ActionCommandResultType
|
964
|
+
*
|
965
|
+
* @internal
|
966
|
+
* Limited to Microsoft-internal use
|
967
|
+
*
|
968
|
+
* @beta
|
969
|
+
*/
|
970
|
+
type ActionCommandResultType = 'card' | 'text';
|
971
|
+
/**
|
972
|
+
* @hidden
|
973
|
+
* The reason for the TaskModuleClosedReason
|
974
|
+
*
|
975
|
+
* @internal
|
976
|
+
* Limited to Microsoft-internal use
|
977
|
+
*
|
978
|
+
* @beta
|
979
|
+
*/
|
980
|
+
type TaskModuleClosedReason = 'Done' | 'CancelledByUser';
|
981
|
+
/**
|
982
|
+
*
|
983
|
+
* @hidden
|
984
|
+
* Error that can be thrown from IExternalAppCommandsService.processActionCommand
|
985
|
+
*
|
986
|
+
* @internal
|
987
|
+
* Limited to Microsoft-internal use
|
988
|
+
*
|
989
|
+
* @beta
|
990
|
+
*/
|
991
|
+
interface ActionCommandError {
|
992
|
+
errorCode: ExternalAppErrorCode;
|
993
|
+
message?: string;
|
994
|
+
}
|
995
|
+
/**
|
996
|
+
* @internal
|
997
|
+
* Limited to Microsoft-internal use
|
998
|
+
* @hidden
|
999
|
+
* This API delegates an ActionCommand request to the host for the application with the provided following parameters:
|
1000
|
+
*
|
1001
|
+
* @param appId ID of the application the request is intended for. This must be a UUID
|
1002
|
+
* @param commandId extensibilityProvider use this ID to look up the command declared by ActionME
|
1003
|
+
* @param extractedParameters are the key-value pairs that the dialog will be prepopulated with
|
1004
|
+
*
|
1005
|
+
* @returns Promise that resolves with the {@link IActionCommandResponse} when the request is completed and rejects with {@link ActionCommandError} if the request fails
|
1006
|
+
*
|
1007
|
+
* @beta
|
1008
|
+
*/
|
1009
|
+
function processActionCommand(appId: string, commandId: string, extractedParameters: Record<string, string>): Promise<IActionCommandResponse>;
|
1010
|
+
/**
|
1011
|
+
* @hidden
|
1012
|
+
* Checks if the externalAppCommands capability is supported by the host
|
1013
|
+
* @returns boolean to represent whether externalAppCommands capability is supported
|
1014
|
+
*
|
1015
|
+
* @throws Error if {@linkcode app.initialize} has not successfully completed
|
1016
|
+
*
|
1017
|
+
* @internal
|
1018
|
+
* Limited to Microsoft-internal use
|
1019
|
+
*
|
1020
|
+
* @beta
|
1021
|
+
*/
|
1022
|
+
function isSupported(): boolean;
|
1023
|
+
}
|
1024
|
+
|
870
1025
|
export namespace files {
|
871
1026
|
/**
|
872
1027
|
* @hidden
|
@@ -876,7 +1031,7 @@ export namespace files {
|
|
876
1031
|
* @internal
|
877
1032
|
* Limited to Microsoft-internal use
|
878
1033
|
*/
|
879
|
-
export enum CloudStorageProvider {
|
1034
|
+
export const enum CloudStorageProvider {
|
880
1035
|
Dropbox = "DROPBOX",
|
881
1036
|
Box = "BOX",
|
882
1037
|
Sharefile = "SHAREFILE",
|
@@ -913,7 +1068,7 @@ export namespace files {
|
|
913
1068
|
* @internal
|
914
1069
|
* Limited to Microsoft-internal use
|
915
1070
|
*/
|
916
|
-
export enum CloudStorageProviderType {
|
1071
|
+
export const enum CloudStorageProviderType {
|
917
1072
|
Sharepoint = 0,
|
918
1073
|
WopiIntegration = 1,
|
919
1074
|
Google = 2,
|
@@ -1131,7 +1286,7 @@ export namespace files {
|
|
1131
1286
|
* @internal
|
1132
1287
|
* Limited to Microsoft-internal use
|
1133
1288
|
*/
|
1134
|
-
export enum SpecialDocumentLibraryType {
|
1289
|
+
export const enum SpecialDocumentLibraryType {
|
1135
1290
|
ClassMaterials = "classMaterials"
|
1136
1291
|
}
|
1137
1292
|
/**
|
@@ -1142,7 +1297,7 @@ export namespace files {
|
|
1142
1297
|
* @internal
|
1143
1298
|
* Limited to Microsoft-internal use
|
1144
1299
|
*/
|
1145
|
-
export enum DocumentLibraryAccessType {
|
1300
|
+
export const enum DocumentLibraryAccessType {
|
1146
1301
|
Readonly = "readonly"
|
1147
1302
|
}
|
1148
1303
|
/**
|
@@ -1184,7 +1339,7 @@ export namespace files {
|
|
1184
1339
|
* @internal
|
1185
1340
|
* Limited to Microsoft-internal use
|
1186
1341
|
*/
|
1187
|
-
export enum FileDownloadStatus {
|
1342
|
+
export const enum FileDownloadStatus {
|
1188
1343
|
Downloaded = "Downloaded",
|
1189
1344
|
Downloading = "Downloading",
|
1190
1345
|
Failed = "Failed"
|
@@ -1286,7 +1441,7 @@ export namespace files {
|
|
1286
1441
|
* @internal
|
1287
1442
|
* Limited to Microsoft-internal use
|
1288
1443
|
*/
|
1289
|
-
export enum CloudStorageProviderFileAction {
|
1444
|
+
export const enum CloudStorageProviderFileAction {
|
1290
1445
|
Download = "DOWNLOAD",
|
1291
1446
|
Upload = "UPLOAD",
|
1292
1447
|
Delete = "DELETE"
|
@@ -1906,6 +2061,88 @@ export namespace notifications {
|
|
1906
2061
|
function isSupported(): boolean;
|
1907
2062
|
}
|
1908
2063
|
|
2064
|
+
/**
|
2065
|
+
* @hidden
|
2066
|
+
* @internal
|
2067
|
+
* @beta
|
2068
|
+
* Limited to Microsoft-internal use
|
2069
|
+
*
|
2070
|
+
* This capability contains the APIs for handling events that happen to other applications on the host
|
2071
|
+
* *while* the developer's application is running. For example, if the developer wants to be notified
|
2072
|
+
* when another application has been installed.
|
2073
|
+
*/
|
2074
|
+
export namespace otherAppStateChange {
|
2075
|
+
/**
|
2076
|
+
* @hidden
|
2077
|
+
* @beta
|
2078
|
+
* @internal
|
2079
|
+
* Limited to Microsoft-internal use
|
2080
|
+
*
|
2081
|
+
* Represent an event that has happened with other number of applications installed on this host.
|
2082
|
+
* (e.g. a new app has been installed)
|
2083
|
+
*/
|
2084
|
+
interface OtherAppStateChangeEvent {
|
2085
|
+
/** An array of app ids that this event applies to */
|
2086
|
+
appIds: string[];
|
2087
|
+
}
|
2088
|
+
/**
|
2089
|
+
* @hidden
|
2090
|
+
* @beta
|
2091
|
+
* @internal
|
2092
|
+
* Limited to Microsoft-internal use
|
2093
|
+
*
|
2094
|
+
* A function handler that will be called whenever an event happens with some number of applications installed on this host.
|
2095
|
+
*/
|
2096
|
+
type OtherAppStateChangeEventHandler = (event: OtherAppStateChangeEvent) => void;
|
2097
|
+
/**
|
2098
|
+
* @hidden
|
2099
|
+
* @beta
|
2100
|
+
* @internal
|
2101
|
+
* Limited to Microsoft-internal use
|
2102
|
+
*
|
2103
|
+
* This function allows an app to register a handler that will receive whenever other applications are installed
|
2104
|
+
* on the host while the developer's application is running.
|
2105
|
+
*
|
2106
|
+
* @param appInstallHandler - This handler will be called whenever apps are installed on the host.
|
2107
|
+
*
|
2108
|
+
* @throws Error if {@link app.initialize} has not successfully completed, if the platform
|
2109
|
+
* does not support the otherAppStateChange capability, or if a valid handler is not passed to the function.
|
2110
|
+
*
|
2111
|
+
* @example
|
2112
|
+
* ``` ts
|
2113
|
+
* if (otherAppStateChange.isSupported()) {
|
2114
|
+
* otherAppStateChange.registerAppInstallationHandler((event: otherAppStateChange.OtherAppStateChangeEvent) => {
|
2115
|
+
* // code to handle the event goes here
|
2116
|
+
* });
|
2117
|
+
* }
|
2118
|
+
* ```
|
2119
|
+
*/
|
2120
|
+
function registerAppInstallationHandler(appInstallHandler: OtherAppStateChangeEventHandler): void;
|
2121
|
+
/**
|
2122
|
+
* @hidden
|
2123
|
+
* @beta
|
2124
|
+
* @internal
|
2125
|
+
* Limited to Microsoft-internal use
|
2126
|
+
*
|
2127
|
+
* This function can be called so that the handler passed to {@link registerAppInstallationHandler}
|
2128
|
+
* will no longer receive app installation events. If this is called before registering a handler
|
2129
|
+
* it will have no effect.
|
2130
|
+
*
|
2131
|
+
* @throws Error if {@link app.initialize} has not successfully completed or if the platform
|
2132
|
+
* does not support the otherAppStateChange capability.
|
2133
|
+
*/
|
2134
|
+
function unregisterAppInstallationHandler(): void;
|
2135
|
+
/**
|
2136
|
+
* Checks if the otherAppStateChange capability is supported by the host
|
2137
|
+
* @returns boolean to represent whether the otherAppStateChange capability is supported
|
2138
|
+
*
|
2139
|
+
* @throws Error if {@link app.initialize} has not successfully completed
|
2140
|
+
*
|
2141
|
+
* @beta
|
2142
|
+
*/
|
2143
|
+
function isSupported(): boolean;
|
2144
|
+
}
|
2145
|
+
|
1909
2146
|
export namespace remoteCamera {
|
1910
2147
|
/**
|
1911
2148
|
* @hidden
|
@@ -2043,7 +2280,7 @@ export namespace remoteCamera {
|
|
2043
2280
|
* @internal
|
2044
2281
|
* Limited to Microsoft-internal use
|
2045
2282
|
*/
|
2046
|
-
enum ErrorReason {
|
2283
|
+
const enum ErrorReason {
|
2047
2284
|
CommandResetError = 0,
|
2048
2285
|
CommandZoomInError = 1,
|
2049
2286
|
CommandZoomOutError = 2,
|
@@ -2085,7 +2322,7 @@ export namespace remoteCamera {
|
|
2085
2322
|
* @internal
|
2086
2323
|
* Limited to Microsoft-internal use
|
2087
2324
|
*/
|
2088
|
-
enum SessionTerminatedReason {
|
2325
|
+
const enum SessionTerminatedReason {
|
2089
2326
|
None = 0,
|
2090
2327
|
ControlDenied = 1,
|
2091
2328
|
ControlNoResponse = 2,
|
@@ -2294,7 +2531,7 @@ export namespace appEntity {
|
|
2294
2531
|
}
|
2295
2532
|
|
2296
2533
|
export namespace teams {
|
2297
|
-
enum ChannelType {
|
2534
|
+
const enum ChannelType {
|
2298
2535
|
Regular = 0,
|
2299
2536
|
Private = 1,
|
2300
2537
|
Shared = 2
|
@@ -2418,7 +2655,7 @@ export namespace videoEffectsEx {
|
|
2418
2655
|
* @internal
|
2419
2656
|
* Limited to Microsoft-internal use
|
2420
2657
|
*/
|
2421
|
-
enum ErrorLevel {
|
2658
|
+
const enum ErrorLevel {
|
2422
2659
|
Fatal = "fatal",
|
2423
2660
|
Warn = "warn"
|
2424
2661
|
}
|
@@ -3003,7 +3240,7 @@ export namespace authentication {
|
|
3003
3240
|
* @internal
|
3004
3241
|
* Limited to Microsoft-internal use
|
3005
3242
|
*/
|
3006
|
-
enum DataResidency {
|
3243
|
+
const enum DataResidency {
|
3007
3244
|
/**
|
3008
3245
|
* Public
|
3009
3246
|
*/
|
@@ -3069,7 +3306,7 @@ export enum HostClientType {
|
|
3069
3306
|
teamsDisplays = "teamsDisplays"
|
3070
3307
|
}
|
3071
3308
|
/** HostName indicates the possible hosts for your application. */
|
3072
|
-
export enum HostName {
|
3309
|
+
export const enum HostName {
|
3073
3310
|
/**
|
3074
3311
|
* Office.com and Office Windows App
|
3075
3312
|
*/
|
@@ -3161,7 +3398,7 @@ export enum UserTeamRole {
|
|
3161
3398
|
/**
|
3162
3399
|
* Dialog module dimension enum
|
3163
3400
|
*/
|
3164
|
-
export enum DialogDimension {
|
3401
|
+
export const enum DialogDimension {
|
3165
3402
|
/** Represents a large-sized dialog box, which is typically used for displaying large amounts of content or complex workflows that require more space. */
|
3166
3403
|
Large = "large",
|
3167
3404
|
/** Represents a medium-sized dialog box, which is typically used for displaying moderate amounts of content or workflows that require less space. */
|
@@ -3177,7 +3414,7 @@ export import TaskModuleDimension = DialogDimension;
|
|
3177
3414
|
/**
|
3178
3415
|
* The type of the channel with which the content is associated.
|
3179
3416
|
*/
|
3180
|
-
export enum ChannelType {
|
3417
|
+
export const enum ChannelType {
|
3181
3418
|
/** The default channel type. Type of channel is used for general collaboration and communication within a team. */
|
3182
3419
|
Regular = "Regular",
|
3183
3420
|
/** Type of channel is used for sensitive or confidential communication within a team and is only accessible to members of the channel. */
|
@@ -3373,7 +3610,7 @@ export interface LocaleInfo {
|
|
3373
3610
|
/**
|
3374
3611
|
* Allowed user file open preferences
|
3375
3612
|
*/
|
3376
|
-
export enum FileOpenPreference {
|
3613
|
+
export const enum FileOpenPreference {
|
3377
3614
|
/** Indicates that the user should be prompted to open the file in inline. */
|
3378
3615
|
Inline = "inline",
|
3379
3616
|
/** Indicates that the user should be prompted to open the file in the native desktop application associated with the file type. */
|
@@ -3386,7 +3623,7 @@ export enum FileOpenPreference {
|
|
3386
3623
|
*
|
3387
3624
|
* @beta
|
3388
3625
|
*/
|
3389
|
-
export enum ActionObjectType {
|
3626
|
+
export const enum ActionObjectType {
|
3390
3627
|
/** Represents content within a Microsoft 365 application. */
|
3391
3628
|
M365Content = "m365content"
|
3392
3629
|
}
|
@@ -3432,7 +3669,7 @@ export interface SecondaryId {
|
|
3432
3669
|
* See [commonly accessed resources](https://learn.microsoft.com/graph/api/resources/onedrive?view=graph-rest-1.0#commonly-accessed-resources).
|
3433
3670
|
* @beta
|
3434
3671
|
*/
|
3435
|
-
export enum SecondaryM365ContentIdName {
|
3672
|
+
export const enum SecondaryM365ContentIdName {
|
3436
3673
|
/** OneDrive ID */
|
3437
3674
|
DriveId = "driveId",
|
3438
3675
|
/** Teams Group ID */
|
@@ -3867,6 +4104,15 @@ export interface Context {
|
|
3867
4104
|
* The SharePoint relative path to the current users mysite
|
3868
4105
|
*/
|
3869
4106
|
mySitePath?: string;
|
4107
|
+
/**
|
4108
|
+
* @deprecated
|
4109
|
+
* As of 2.0.0, please use {@link app.Context.dialogParameters} instead
|
4110
|
+
*
|
4111
|
+
* When `processActionCommand` activates a dialog, this dialog should automatically fill in some fields with information. This information comes from M365 and is given to `processActionCommand` as `extractedParameters`.
|
4112
|
+
* App developers need to use these `extractedParameters` in their dialog.
|
4113
|
+
* They help pre-fill the dialog with necessary information (`dialogParameters`) along with other details.
|
4114
|
+
*/
|
4115
|
+
dialogParameters?: Record<string, string>;
|
3870
4116
|
}
|
3871
4117
|
/** Represents the parameters used to share a deep link. */
|
3872
4118
|
export interface ShareDeepLinkParameters {
|
@@ -4137,7 +4383,7 @@ export enum ErrorCode {
|
|
4137
4383
|
SIZE_EXCEEDED = 10000
|
4138
4384
|
}
|
4139
4385
|
/** @hidden */
|
4140
|
-
export enum DevicePermission {
|
4386
|
+
export const enum DevicePermission {
|
4141
4387
|
GeoLocation = "geolocation",
|
4142
4388
|
Media = "media"
|
4143
4389
|
}
|
@@ -4609,6 +4855,13 @@ export namespace app {
|
|
4609
4855
|
* Will be `undefined` when not running in Teams.
|
4610
4856
|
*/
|
4611
4857
|
team?: TeamInfo;
|
4858
|
+
/**
|
4859
|
+
* When `processActionCommand` activates a dialog, this dialog should automatically fill in some fields with information. This information comes from M365 and is given to `processActionCommand` as `extractedParameters`.
|
4860
|
+
* App developers need to use these `extractedParameters` in their dialog.
|
4861
|
+
* They help pre-fill the dialog with necessary information (`dialogParameters`) along with other details.
|
4862
|
+
* If there's no key/value pairs passed, the object will be empty in the case
|
4863
|
+
*/
|
4864
|
+
dialogParameters: Record<string, string>;
|
4612
4865
|
}
|
4613
4866
|
/**
|
4614
4867
|
* This function is passed to registerOnThemeHandler. It is called every time the user changes their theme.
|
@@ -5204,6 +5457,22 @@ export namespace dialog {
|
|
5204
5457
|
}
|
5205
5458
|
}
|
5206
5459
|
|
5460
|
+
/**
|
5461
|
+
* @beta
|
5462
|
+
* Nested app auth capabilities
|
5463
|
+
*/
|
5464
|
+
export namespace nestedAppAuth {
|
5465
|
+
/**
|
5466
|
+
* Checks if MSAL-NAA channel recommended by the host
|
5467
|
+
* @returns true if host is recommending NAA channel and false otherwise
|
5468
|
+
*
|
5469
|
+
* @throws Error if {@linkcode app.initialize} has not successfully completed
|
5470
|
+
*
|
5471
|
+
* @beta
|
5472
|
+
*/
|
5473
|
+
function isNAAChannelRecommended(): boolean;
|
5474
|
+
}
|
5475
|
+
|
5207
5476
|
/**
|
5208
5477
|
* Namespace to interact with the geoLocation module-specific part of the SDK. This is the newer version of location module.
|
5209
5478
|
*
|
@@ -5981,7 +6250,7 @@ export namespace menus {
|
|
5981
6250
|
* @hidden
|
5982
6251
|
* Represents information about type of list to display in Navigation Bar Menu.
|
5983
6252
|
*/
|
5984
|
-
enum MenuListType {
|
6253
|
+
const enum MenuListType {
|
5985
6254
|
dropDown = "dropDown",
|
5986
6255
|
popOver = "popOver"
|
5987
6256
|
}
|
@@ -6077,7 +6346,7 @@ export namespace media {
|
|
6077
6346
|
/**
|
6078
6347
|
* Enum for file formats supported
|
6079
6348
|
*/
|
6080
|
-
export enum FileFormat {
|
6349
|
+
export const enum FileFormat {
|
6081
6350
|
/** Base64 encoding */
|
6082
6351
|
Base64 = "base64",
|
6083
6352
|
/** File id */
|
@@ -6947,7 +7216,7 @@ export namespace meeting {
|
|
6947
7216
|
*
|
6948
7217
|
* @beta
|
6949
7218
|
*/
|
6950
|
-
enum MeetingReactionType {
|
7219
|
+
const enum MeetingReactionType {
|
6951
7220
|
like = "like",
|
6952
7221
|
heart = "heart",
|
6953
7222
|
laugh = "laugh",
|
@@ -6963,7 +7232,7 @@ export namespace meeting {
|
|
6963
7232
|
* @remarks
|
6964
7233
|
* Teams has several types of meetings to account for different user scenarios and requirements.
|
6965
7234
|
*/
|
6966
|
-
enum MeetingType {
|
7235
|
+
const enum MeetingType {
|
6967
7236
|
/**
|
6968
7237
|
* Used when the meeting type is not known.
|
6969
7238
|
*
|
@@ -7017,7 +7286,7 @@ export namespace meeting {
|
|
7017
7286
|
* @hidden
|
7018
7287
|
* Hide from docs.
|
7019
7288
|
*/
|
7020
|
-
enum CallType {
|
7289
|
+
const enum CallType {
|
7021
7290
|
/**
|
7022
7291
|
* Represents a call between two people.
|
7023
7292
|
*
|
@@ -7037,7 +7306,7 @@ export namespace meeting {
|
|
7037
7306
|
/**
|
7038
7307
|
* Represents the protocol option for sharing app content to the meeting stage.
|
7039
7308
|
*/
|
7040
|
-
enum SharingProtocol {
|
7309
|
+
const enum SharingProtocol {
|
7041
7310
|
/**
|
7042
7311
|
* The default protocol for sharing app content to stage. To learn more, visit https://aka.ms/teamsjs/shareAppContentToStage
|
7043
7312
|
*/
|
@@ -7302,7 +7571,7 @@ export namespace meeting {
|
|
7302
7571
|
source?: EventActionSource;
|
7303
7572
|
}
|
7304
7573
|
/** The source of the join button click. */
|
7305
|
-
enum EventActionSource {
|
7574
|
+
const enum EventActionSource {
|
7306
7575
|
/**
|
7307
7576
|
* Source is calendar grid context menu.
|
7308
7577
|
*/
|
@@ -7946,7 +8215,7 @@ export namespace videoEffects {
|
|
7946
8215
|
* Video frame format enum, currently only support NV12
|
7947
8216
|
* @beta
|
7948
8217
|
*/
|
7949
|
-
enum VideoFrameFormat {
|
8218
|
+
const enum VideoFrameFormat {
|
7950
8219
|
/** Video format used for encoding and decoding YUV color data in video streaming and storage applications. */
|
7951
8220
|
NV12 = "NV12"
|
7952
8221
|
}
|
@@ -7964,7 +8233,7 @@ export namespace videoEffects {
|
|
7964
8233
|
* Video effect change type enum
|
7965
8234
|
* @beta
|
7966
8235
|
*/
|
7967
|
-
enum EffectChangeType {
|
8236
|
+
const enum EffectChangeType {
|
7968
8237
|
/**
|
7969
8238
|
* Current video effect changed
|
7970
8239
|
*/
|
@@ -8278,6 +8547,54 @@ export namespace sharing {
|
|
8278
8547
|
* @throws Error if {@linkcode app.initialize} has not successfully completed
|
8279
8548
|
*/
|
8280
8549
|
export function isSupported(): boolean;
|
8550
|
+
/**
|
8551
|
+
* Namespace to get the list of content shared in a Teams meeting
|
8552
|
+
*
|
8553
|
+
* @beta
|
8554
|
+
*/
|
8555
|
+
export namespace history {
|
8556
|
+
/**
|
8557
|
+
* Represents the data returned when calling {@link sharing.history.getContent}
|
8558
|
+
*
|
8559
|
+
* @beta
|
8560
|
+
*/
|
8561
|
+
interface IContentResponse {
|
8562
|
+
/** Id of the app where the content was shared from */
|
8563
|
+
appId: string;
|
8564
|
+
/** Title of the shared content */
|
8565
|
+
title: string;
|
8566
|
+
/** Reference of the shared content */
|
8567
|
+
contentReference: string;
|
8568
|
+
/** Id of the thread where the content was shared. This is a UUID */
|
8569
|
+
threadId: string;
|
8570
|
+
/** Id of the user who shared the content. This is a UUID */
|
8571
|
+
author: string;
|
8572
|
+
/** Type of the shared content.
|
8573
|
+
* For sharing to Teams stage scenarios, this value would be `ShareToStage`
|
8574
|
+
* Other `contentType` values will be added and documented here over time
|
8575
|
+
*/
|
8576
|
+
contentType: string;
|
8577
|
+
}
|
8578
|
+
/**
|
8579
|
+
* Get the list of content shared in a Teams meeting
|
8580
|
+
*
|
8581
|
+
* @throws Error if call capability is not supported
|
8582
|
+
* @throws Error if returned content details are invalid
|
8583
|
+
* @returns Promise that will resolve with the {@link IContentResponse} objects array
|
8584
|
+
*
|
8585
|
+
* @beta
|
8586
|
+
*/
|
8587
|
+
function getContent(): Promise<IContentResponse[]>;
|
8588
|
+
/**
|
8589
|
+
* Checks if sharing.history capability is supported by the host
|
8590
|
+
* @returns boolean to represent whether the sharing.history capability is supported
|
8591
|
+
*
|
8592
|
+
* @throws Error if {@linkcode app.initialize} has not successfully completed
|
8593
|
+
*
|
8594
|
+
* @beta
|
8595
|
+
*/
|
8596
|
+
function isSupported(): boolean;
|
8597
|
+
}
|
8281
8598
|
export {};
|
8282
8599
|
}
|
8283
8600
|
|
@@ -8325,7 +8642,7 @@ export namespace stageView {
|
|
8325
8642
|
/**
|
8326
8643
|
* The open mode for stage content.
|
8327
8644
|
*/
|
8328
|
-
enum StageViewOpenMode {
|
8645
|
+
const enum StageViewOpenMode {
|
8329
8646
|
/**
|
8330
8647
|
* Open the content in a modal.
|
8331
8648
|
*/
|
@@ -8340,8 +8657,6 @@ export namespace stageView {
|
|
8340
8657
|
popoutWithChat = "popoutWithChat"
|
8341
8658
|
}
|
8342
8659
|
/**
|
8343
|
-
* @hidden
|
8344
|
-
* Feature is under development
|
8345
8660
|
*
|
8346
8661
|
* Opens a stage view to display a Teams application
|
8347
8662
|
* @beta
|
@@ -8589,7 +8904,7 @@ export namespace webStorage {
|
|
8589
8904
|
*/
|
8590
8905
|
export namespace call {
|
8591
8906
|
/** Modalities that can be associated with a call. */
|
8592
|
-
enum CallModalities {
|
8907
|
+
const enum CallModalities {
|
8593
8908
|
/** Indicates that the modality is unknown or undefined. */
|
8594
8909
|
Unknown = "unknown",
|
8595
8910
|
/** Indicates that the call includes audio. */
|
@@ -9243,7 +9558,7 @@ export namespace liveShare {
|
|
9243
9558
|
* Used in Live Share for its role verification feature.
|
9244
9559
|
* For more information, visit https://learn.microsoft.com/microsoftteams/platform/apps-in-teams-meetings/teams-live-share-capabilities?tabs=javascript#role-verification-for-live-data-structures
|
9245
9560
|
*/
|
9246
|
-
enum UserMeetingRole {
|
9561
|
+
const enum UserMeetingRole {
|
9247
9562
|
/**
|
9248
9563
|
* Guest role.
|
9249
9564
|
*/
|
@@ -9266,7 +9581,7 @@ export namespace liveShare {
|
|
9266
9581
|
* State of the current Live Share session's Fluid container.
|
9267
9582
|
* This is used internally by the `LiveShareClient` when joining a Live Share session.
|
9268
9583
|
*/
|
9269
|
-
enum ContainerState {
|
9584
|
+
const enum ContainerState {
|
9270
9585
|
/**
|
9271
9586
|
* The call to `LiveShareHost.setContainerId()` successfully created the container mapping
|
9272
9587
|
* for the current Live Share session.
|
@@ -9620,7 +9935,7 @@ export namespace marketplace {
|
|
9620
9935
|
* Represents the persona creating the cart.
|
9621
9936
|
* @beta
|
9622
9937
|
*/
|
9623
|
-
export enum Intent {
|
9938
|
+
export const enum Intent {
|
9624
9939
|
/**
|
9625
9940
|
* @hidden
|
9626
9941
|
* The cart is created by admin of an organization in Teams Admin Center.
|
@@ -9774,6 +10089,16 @@ export namespace marketplace {
|
|
9774
10089
|
export {};
|
9775
10090
|
}
|
9776
10091
|
|
10092
|
+
/**
|
10093
|
+
* @hidden
|
10094
|
+
* Error codes that can be thrown from externalAppCommands and externalAppCardCommands Action Submit specifically
|
10095
|
+
* @internal
|
10096
|
+
* Limited to Microsoft-internal use
|
10097
|
+
*/
|
10098
|
+
export const enum ExternalAppErrorCode {
|
10099
|
+
INTERNAL_ERROR = "INTERNAL_ERROR"
|
10100
|
+
}
|
10101
|
+
|
9777
10102
|
/**
|
9778
10103
|
* @hidden
|
9779
10104
|
* Create a MediaStreamTrack from the media stream with the given streamId and processed by videoFrameHandler.
|