@microsoft/teams-js 2.1.1-beta.0 → 2.2.0-beta.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.
- package/dist/MicrosoftTeams.d.ts +219 -77
- package/dist/MicrosoftTeams.js +103 -25
- 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
@@ -645,6 +645,23 @@ export namespace files {
|
|
645
645
|
*/
|
646
646
|
extension: string;
|
647
647
|
}
|
648
|
+
/**
|
649
|
+
* Object used to represent a file
|
650
|
+
*/
|
651
|
+
export interface File extends Blob {
|
652
|
+
/**
|
653
|
+
* Last modified timestamp
|
654
|
+
*/
|
655
|
+
lastModified: Date;
|
656
|
+
/**
|
657
|
+
* Name of the file
|
658
|
+
*/
|
659
|
+
name: string;
|
660
|
+
/**
|
661
|
+
* The file path to uniquely identify it within the file hierarchy
|
662
|
+
*/
|
663
|
+
filePath: string;
|
664
|
+
}
|
648
665
|
/**
|
649
666
|
* @hidden
|
650
667
|
* Hide from docs
|
@@ -684,6 +701,7 @@ export namespace files {
|
|
684
701
|
export interface CloudStorageProviderNewFileContent extends CloudStorageProviderContent {
|
685
702
|
newFileName: string;
|
686
703
|
newFileExtension: string;
|
704
|
+
destinationFolder: CloudStorageFolderItem | ISharePointFile;
|
687
705
|
}
|
688
706
|
/**
|
689
707
|
* @hidden
|
@@ -699,12 +717,30 @@ export namespace files {
|
|
699
717
|
* @hidden
|
700
718
|
* Hide from docs
|
701
719
|
*
|
702
|
-
* Interface representing 3P cloud storage provider
|
720
|
+
* Interface representing 3P cloud storage provider delete existing file(s) action
|
703
721
|
*/
|
704
|
-
export interface
|
705
|
-
action: CloudStorageProviderFileAction;
|
722
|
+
export interface CloudStorageProviderDeleteFileContent extends CloudStorageProviderContent {
|
706
723
|
itemList: CloudStorageFolderItem[] | ISharePointFile[];
|
707
724
|
}
|
725
|
+
/**
|
726
|
+
* @hidden
|
727
|
+
* Hide from docs
|
728
|
+
*
|
729
|
+
* Interface representing 3P cloud storage provider download existing file(s) action
|
730
|
+
*/
|
731
|
+
export interface CloudStorageProviderDownloadFileContent extends CloudStorageProviderContent {
|
732
|
+
itemList: CloudStorageFolderItem[] | ISharePointFile[];
|
733
|
+
}
|
734
|
+
/**
|
735
|
+
* @hidden
|
736
|
+
* Hide from docs
|
737
|
+
*
|
738
|
+
* Interface representing 3P cloud storage provider upload existing file(s) action
|
739
|
+
*/
|
740
|
+
export interface CloudStorageProviderUploadFileContent extends CloudStorageProviderContent {
|
741
|
+
itemList: File[];
|
742
|
+
destinationFolder: CloudStorageFolderItem | ISharePointFile;
|
743
|
+
}
|
708
744
|
/**
|
709
745
|
* @hidden
|
710
746
|
* Hide from docs
|
@@ -824,7 +860,7 @@ export namespace files {
|
|
824
860
|
* @param addNewFileRequest 3P cloud storage provider add action request content
|
825
861
|
* @param callback Callback that will be triggered post adding a new file flow is finished
|
826
862
|
*/
|
827
|
-
export function addCloudStorageProviderFile(addNewFileRequest: CloudStorageProviderRequest<CloudStorageProviderNewFileContent>, callback: (error?: SdkError) => void): void;
|
863
|
+
export function addCloudStorageProviderFile(addNewFileRequest: CloudStorageProviderRequest<CloudStorageProviderNewFileContent>, callback: (error?: SdkError, actionStatus?: boolean) => void): void;
|
828
864
|
/**
|
829
865
|
* @hidden
|
830
866
|
* Hide from docs
|
@@ -834,21 +870,39 @@ export namespace files {
|
|
834
870
|
* @param renameFileRequest 3P cloud storage provider rename action request content
|
835
871
|
* @param callback Callback that will be triggered post renaming an existing file flow is finished
|
836
872
|
*/
|
837
|
-
export function renameCloudStorageProviderFile(renameFileRequest: CloudStorageProviderRequest<CloudStorageProviderRenameFileContent>, callback: (error?: SdkError) => void): void;
|
873
|
+
export function renameCloudStorageProviderFile(renameFileRequest: CloudStorageProviderRequest<CloudStorageProviderRenameFileContent>, callback: (error?: SdkError, actionStatus?: boolean) => void): void;
|
838
874
|
/**
|
839
875
|
* @hidden
|
840
876
|
* Hide from docs
|
841
877
|
*
|
842
|
-
* Initiates the 3P cloud storage
|
878
|
+
* Initiates the delete 3P cloud storage file(s) / folder (folder has to be empty) flow,
|
879
|
+
* which will delete existing file(s) / folder from the given 3P provider
|
843
880
|
*
|
844
|
-
*
|
845
|
-
*
|
846
|
-
|
881
|
+
* @param deleteFileRequest 3P cloud storage provider delete action request content
|
882
|
+
* @param callback Callback that will be triggered post deleting existing file(s) flow is finished
|
883
|
+
*/
|
884
|
+
export function deleteCloudStorageProviderFile(deleteFileRequest: CloudStorageProviderRequest<CloudStorageProviderDeleteFileContent>, callback: (error?: SdkError, actionStatus?: boolean) => void): void;
|
885
|
+
/**
|
886
|
+
* @hidden
|
887
|
+
* Hide from docs
|
888
|
+
*
|
889
|
+
* Initiates the download 3P cloud storage file(s) flow,
|
890
|
+
* which will download existing file(s) from the given 3P provider in the teams client side without sharing any file info in the callback
|
891
|
+
*
|
892
|
+
* @param downloadFileRequest 3P cloud storage provider download file(s) action request content
|
893
|
+
* @param callback Callback that will be triggered post downloading existing file(s) flow is finished
|
894
|
+
*/
|
895
|
+
export function downloadCloudStorageProviderFile(downloadFileRequest: CloudStorageProviderRequest<CloudStorageProviderDownloadFileContent>, callback: (error?: SdkError, actionStatus?: boolean) => void): void;
|
896
|
+
/**
|
897
|
+
* @hidden
|
898
|
+
* Hide from docs
|
899
|
+
*
|
900
|
+
* Initiates the upload 3P cloud storage file(s) flow, which will upload file(s) to the given 3P provider
|
847
901
|
*
|
848
|
-
* @param
|
849
|
-
* @param callback Callback that will be triggered post
|
902
|
+
* @param uploadFileRequest 3P cloud storage provider upload file(s) action request content
|
903
|
+
* @param callback Callback that will be triggered post uploading file(s) flow is finished
|
850
904
|
*/
|
851
|
-
export function
|
905
|
+
export function uploadCloudStorageProviderFile(uploadFileRequest: CloudStorageProviderRequest<CloudStorageProviderUploadFileContent>, callback: (error?: SdkError, actionStatus?: boolean) => void): void;
|
852
906
|
/**
|
853
907
|
* @hidden
|
854
908
|
* Hide from docs
|
@@ -1931,20 +1985,95 @@ export enum FileOpenPreference {
|
|
1931
1985
|
Desktop = "desktop",
|
1932
1986
|
Web = "web"
|
1933
1987
|
}
|
1988
|
+
/**
|
1989
|
+
* Possible Action Types
|
1990
|
+
*
|
1991
|
+
* @beta
|
1992
|
+
*/
|
1993
|
+
export enum ActionObjectType {
|
1994
|
+
M365Content = "m365content"
|
1995
|
+
}
|
1996
|
+
/**
|
1997
|
+
* Data pertaining to object(s) the action is being performed on
|
1998
|
+
*
|
1999
|
+
* @param T The type of action being implemented
|
2000
|
+
*
|
2001
|
+
* @beta
|
2002
|
+
*/
|
2003
|
+
export interface BaseActionObject<T extends ActionObjectType> {
|
2004
|
+
type: T;
|
2005
|
+
}
|
2006
|
+
/**
|
2007
|
+
* Stores information needed to represent M365 Content stored
|
2008
|
+
* in OneDrive or Sharepoint
|
2009
|
+
*
|
2010
|
+
* @beta
|
2011
|
+
*/
|
2012
|
+
export interface M365ContentAction extends BaseActionObject<ActionObjectType.M365Content> {
|
2013
|
+
/**
|
2014
|
+
* Only office content IDs are passed to the app. Apps should use these ids
|
2015
|
+
* to query the Microsoft graph for more details.
|
2016
|
+
*/
|
2017
|
+
itemId: string;
|
2018
|
+
secondaryId?: SecondaryId;
|
2019
|
+
}
|
2020
|
+
/**
|
2021
|
+
* Contains information on what Graph item is being queried
|
2022
|
+
*
|
2023
|
+
* @beta
|
2024
|
+
*/
|
2025
|
+
export interface SecondaryId {
|
2026
|
+
name: SecondaryM365ContentIdName;
|
2027
|
+
value: string;
|
2028
|
+
}
|
2029
|
+
/**
|
2030
|
+
* These correspond with field names in the MSGraph
|
2031
|
+
*
|
2032
|
+
* @beta
|
2033
|
+
*/
|
2034
|
+
export enum SecondaryM365ContentIdName {
|
2035
|
+
DriveId = "driveId",
|
2036
|
+
GroupId = "groupId",
|
2037
|
+
SiteId = "siteId",
|
2038
|
+
UserId = "userId"
|
2039
|
+
}
|
2040
|
+
/**
|
2041
|
+
* Information common to all actions
|
2042
|
+
*
|
2043
|
+
* @beta
|
2044
|
+
*/
|
2045
|
+
export interface ActionInfo {
|
2046
|
+
/**
|
2047
|
+
* Maps to the action id supplied inside the manifest
|
2048
|
+
*/
|
2049
|
+
actionId: string;
|
2050
|
+
/**
|
2051
|
+
* Array of corresponding action objects
|
2052
|
+
*/
|
2053
|
+
actionObjects: BaseActionObject<ActionObjectType>[];
|
2054
|
+
}
|
1934
2055
|
/**
|
1935
2056
|
* @deprecated
|
1936
|
-
* As of 2.0.0, please use {@link app.Context} instead.
|
2057
|
+
* As of 2.0.0, please use the {@link app.Context} interface and its updated properties instead.
|
1937
2058
|
*
|
1938
2059
|
* @remarks
|
1939
|
-
* For more details
|
1940
|
-
*
|
2060
|
+
* For more details about the updated {@link app.Context} interface, visit the
|
2061
|
+
* [Teams JavaScript client SDK](https://docs.microsoft.com/microsoftteams/platform/tabs/how-to/using-teams-client-sdk#updates-to-the-context-interface)
|
2062
|
+
* overview article.
|
1941
2063
|
*
|
1942
2064
|
* Represents the structure of the received context message.
|
1943
2065
|
*/
|
1944
2066
|
export interface Context {
|
1945
2067
|
/**
|
1946
2068
|
* @deprecated
|
1947
|
-
* As of 2.0.0, please use {@link app.Context.
|
2069
|
+
* As of 2.0.0, please use {@link ActionInfo | app.Context.actionInfo} instead
|
2070
|
+
*
|
2071
|
+
* Common information applicable to all content actions
|
2072
|
+
*/
|
2073
|
+
actionInfo?: ActionInfo;
|
2074
|
+
/**
|
2075
|
+
* @deprecated
|
2076
|
+
* As of 2.0.0, please use {@link app.TeamInfo.groupId | app.Context.team.groupId} instead
|
1948
2077
|
*
|
1949
2078
|
* The Office 365 group ID for the team with which the content is associated.
|
1950
2079
|
* This field is available only when the identity permission is requested in the manifest.
|
@@ -1952,49 +2081,49 @@ export interface Context {
|
|
1952
2081
|
groupId?: string;
|
1953
2082
|
/**
|
1954
2083
|
* @deprecated
|
1955
|
-
* As of 2.0.0, please use {@link app.Context.team.internalId} instead
|
2084
|
+
* As of 2.0.0, please use {@link app.TeamInfo.internalId | app.Context.team.internalId} instead
|
1956
2085
|
*
|
1957
2086
|
* The Microsoft Teams ID for the team with which the content is associated.
|
1958
2087
|
*/
|
1959
2088
|
teamId?: string;
|
1960
2089
|
/**
|
1961
2090
|
* @deprecated
|
1962
|
-
* As of 2.0.0, please use {@link app.Context.team.displayName} instead
|
2091
|
+
* As of 2.0.0, please use {@link app.TeamInfo.displayName | app.Context.team.displayName} instead
|
1963
2092
|
*
|
1964
2093
|
* The name for the team with which the content is associated.
|
1965
2094
|
*/
|
1966
2095
|
teamName?: string;
|
1967
2096
|
/**
|
1968
2097
|
* @deprecated
|
1969
|
-
* As of 2.0.0, please use {@link app.Context.channel.id} instead
|
2098
|
+
* As of 2.0.0, please use {@link app.ChannelInfo.id | app.Context.channel.id} instead
|
1970
2099
|
*
|
1971
2100
|
* The Microsoft Teams ID for the channel with which the content is associated.
|
1972
2101
|
*/
|
1973
2102
|
channelId?: string;
|
1974
2103
|
/**
|
1975
2104
|
* @deprecated
|
1976
|
-
* As of 2.0.0, please use {@link app.Context.channel.displayName} instead
|
2105
|
+
* As of 2.0.0, please use {@link app.ChannelInfo.displayName | app.Context.channel.displayName} instead
|
1977
2106
|
*
|
1978
2107
|
* The name for the channel with which the content is associated.
|
1979
2108
|
*/
|
1980
2109
|
channelName?: string;
|
1981
2110
|
/**
|
1982
2111
|
* @deprecated
|
1983
|
-
* As of 2.0.0, please use {@link app.Context.channel.membershipType} instead
|
2112
|
+
* As of 2.0.0, please use {@link app.ChannelInfo.membershipType | app.Context.channel.membershipType} instead
|
1984
2113
|
*
|
1985
2114
|
* The type of the channel with which the content is associated.
|
1986
2115
|
*/
|
1987
2116
|
channelType?: ChannelType;
|
1988
2117
|
/**
|
1989
2118
|
* @deprecated
|
1990
|
-
* As of 2.0.0, please use {@link app.Context.page.id} instead
|
2119
|
+
* As of 2.0.0, please use {@link app.PageInfo.id | app.Context.page.id} instead
|
1991
2120
|
*
|
1992
2121
|
* The developer-defined unique ID for the entity this content points to.
|
1993
2122
|
*/
|
1994
2123
|
entityId: string;
|
1995
2124
|
/**
|
1996
2125
|
* @deprecated
|
1997
|
-
* As of 2.0.0, please use {@link app.Context.page.subPageId} instead
|
2126
|
+
* As of 2.0.0, please use {@link app.PageInfo.subPageId | app.Context.page.subPageId} instead
|
1998
2127
|
*
|
1999
2128
|
* The developer-defined unique ID for the sub-entity this content points to.
|
2000
2129
|
* This field should be used to restore to a specific state within an entity,
|
@@ -2003,7 +2132,7 @@ export interface Context {
|
|
2003
2132
|
subEntityId?: string;
|
2004
2133
|
/**
|
2005
2134
|
* @deprecated
|
2006
|
-
* As of 2.0.0, please use {@link app.Context.app.locale} instead
|
2135
|
+
* As of 2.0.0, please use {@link app.AppInfo.locale | app.Context.app.locale} instead
|
2007
2136
|
*
|
2008
2137
|
* The current locale that the user has configured for the app formatted as
|
2009
2138
|
* languageId-countryId (for example, en-us).
|
@@ -2011,7 +2140,7 @@ export interface Context {
|
|
2011
2140
|
locale: string;
|
2012
2141
|
/**
|
2013
2142
|
* @deprecated
|
2014
|
-
* As of 2.0.0, please use {@link app.Context.app.osLocaleInfo} instead
|
2143
|
+
* As of 2.0.0, please use {@link app.AppInfo.osLocaleInfo | app.Context.app.osLocaleInfo} instead
|
2015
2144
|
*
|
2016
2145
|
* More detailed locale info from the user's OS if available. Can be used together with
|
2017
2146
|
* the @microsoft/globe NPM package to ensure your app respects the user's OS date and
|
@@ -2021,7 +2150,8 @@ export interface Context {
|
|
2021
2150
|
/**
|
2022
2151
|
* @deprecated
|
2023
2152
|
*
|
2024
|
-
* As of 2.0.0, please use {@link app.
|
2153
|
+
* As of 2.0.0, please use {@link app.UserInfo.loginHint | app.Context.user.loginHint} or
|
2154
|
+
* {@link app.UserInfo.userPrincipalName | app.Context.user.userPrincipalName} instead.
|
2025
2155
|
* The UPN of the current user.
|
2026
2156
|
* Because a malicious party can run your content in a browser, this value should
|
2027
2157
|
* be used only as a hint as to who the user is and never as proof of identity.
|
@@ -2030,7 +2160,7 @@ export interface Context {
|
|
2030
2160
|
upn?: string;
|
2031
2161
|
/**
|
2032
2162
|
* @deprecated
|
2033
|
-
* As of 2.0.0, please use {@link app.Context.user.tenant.id} instead
|
2163
|
+
* As of 2.0.0, please use {@link app.TenantInfo.id | app.Context.user.tenant.id} instead
|
2034
2164
|
*
|
2035
2165
|
* The Azure AD tenant ID of the current user.
|
2036
2166
|
* Because a malicious party can run your content in a browser, this value should
|
@@ -2040,77 +2170,77 @@ export interface Context {
|
|
2040
2170
|
tid?: string;
|
2041
2171
|
/**
|
2042
2172
|
* @deprecated
|
2043
|
-
* As of 2.0.0, please use {@link app.Context.app.theme} instead
|
2173
|
+
* As of 2.0.0, please use {@link app.AppInfo.theme | app.Context.app.theme} instead
|
2044
2174
|
*
|
2045
2175
|
* The current UI theme.
|
2046
2176
|
*/
|
2047
2177
|
theme?: string;
|
2048
2178
|
/**
|
2049
2179
|
* @deprecated
|
2050
|
-
* As of 2.0.0, please use {@link app.Context.page.isFullScreen} instead
|
2180
|
+
* As of 2.0.0, please use {@link app.PageInfo.isFullScreen | app.Context.page.isFullScreen} instead
|
2051
2181
|
*
|
2052
2182
|
* Indication whether the tab is in full-screen mode.
|
2053
2183
|
*/
|
2054
2184
|
isFullScreen?: boolean;
|
2055
2185
|
/**
|
2056
2186
|
* @deprecated
|
2057
|
-
* As of 2.0.0, please use {@link app.Context.team.type} instead
|
2187
|
+
* As of 2.0.0, please use {@link app.TeamInfo.type | app.Context.team.type} instead
|
2058
2188
|
*
|
2059
2189
|
* The type of the team.
|
2060
2190
|
*/
|
2061
2191
|
teamType?: TeamType;
|
2062
2192
|
/**
|
2063
2193
|
* @deprecated
|
2064
|
-
* As of 2.0.0, please use {@link app.Context.sharePointSite.teamSiteUrl} instead
|
2194
|
+
* As of 2.0.0, please use {@link app.SharePointSiteInfo.teamSiteUrl | app.Context.sharePointSite.teamSiteUrl} instead
|
2065
2195
|
*
|
2066
2196
|
* The root SharePoint site associated with the team.
|
2067
2197
|
*/
|
2068
2198
|
teamSiteUrl?: string;
|
2069
2199
|
/**
|
2070
2200
|
* @deprecated
|
2071
|
-
* As of 2.0.0, please use {@link app.Context.sharePointSite.teamSiteDomain} instead
|
2201
|
+
* As of 2.0.0, please use {@link app.SharePointSiteInfo.teamSiteDomain | app.Context.sharePointSite.teamSiteDomain} instead
|
2072
2202
|
*
|
2073
2203
|
* The domain of the root SharePoint site associated with the team.
|
2074
2204
|
*/
|
2075
2205
|
teamSiteDomain?: string;
|
2076
2206
|
/**
|
2077
2207
|
* @deprecated
|
2078
|
-
* As of 2.0.0, please use {@link app.Context.sharePointSite.teamSitePath} instead
|
2208
|
+
* As of 2.0.0, please use {@link app.SharePointSiteInfo.teamSitePath | app.Context.sharePointSite.teamSitePath} instead
|
2079
2209
|
*
|
2080
2210
|
* The relative path to the SharePoint site associated with the team.
|
2081
2211
|
*/
|
2082
2212
|
teamSitePath?: string;
|
2083
2213
|
/**
|
2084
2214
|
* @deprecated
|
2085
|
-
* As of 2.0.0, please use {@link app.Context.channel.
|
2215
|
+
* As of 2.0.0, please use {@link app.ChannelInfo.ownerTenantId | app.Context.channel.ownerTenantId} instead
|
2086
2216
|
*
|
2087
2217
|
* The tenant ID of the host team.
|
2088
2218
|
*/
|
2089
2219
|
hostTeamTenantId?: string;
|
2090
2220
|
/**
|
2091
2221
|
* @deprecated
|
2092
|
-
* As of 2.0.0, please use {@link app.Context.channel.ownerGroupId} instead
|
2222
|
+
* As of 2.0.0, please use {@link app.ChannelInfo.ownerGroupId | app.Context.channel.ownerGroupId} instead
|
2093
2223
|
*
|
2094
2224
|
* The AAD group ID of the host team.
|
2095
2225
|
*/
|
2096
2226
|
hostTeamGroupId?: string;
|
2097
2227
|
/**
|
2098
2228
|
* @deprecated
|
2099
|
-
* As of 2.0.0, please use {@link app.Context.channel.relativeUrl} instead
|
2229
|
+
* As of 2.0.0, please use {@link app.ChannelInfo.relativeUrl | app.Context.channel.relativeUrl} instead
|
2100
2230
|
*
|
2101
2231
|
* The relative path to the SharePoint folder associated with the channel.
|
2102
2232
|
*/
|
2103
2233
|
channelRelativeUrl?: string;
|
2104
2234
|
/**
|
2105
2235
|
* @deprecated
|
2106
|
-
* As of 2.0.0, please use {@link app.Context.app.host.sessionId} instead
|
2236
|
+
* As of 2.0.0, please use {@link app.AppHostInfo.sessionId | app.Context.app.host.sessionId} instead
|
2107
2237
|
*
|
2108
2238
|
* Unique ID for the current Teams session for use in correlating telemetry data.
|
2109
2239
|
*/
|
2110
2240
|
sessionId?: string;
|
2111
2241
|
/**
|
2112
2242
|
* @deprecated
|
2113
|
-
* As of 2.0.0, please use {@link app.Context.team.userRole} instead
|
2243
|
+
* As of 2.0.0, please use {@link app.TeamInfo.userRole | app.Context.team.userRole} instead
|
2114
2244
|
*
|
2115
2245
|
* The user's role in the team.
|
2116
2246
|
* Because a malicious party can run your content in a browser, this value should
|
@@ -2119,14 +2249,14 @@ export interface Context {
|
|
2119
2249
|
userTeamRole?: UserTeamRole;
|
2120
2250
|
/**
|
2121
2251
|
* @deprecated
|
2122
|
-
* As of 2.0.0, please use {@link app.Context.chat.id} instead
|
2252
|
+
* As of 2.0.0, please use {@link app.ChatInfo.id | app.Context.chat.id} instead
|
2123
2253
|
*
|
2124
2254
|
* The Microsoft Teams ID for the chat with which the content is associated.
|
2125
2255
|
*/
|
2126
2256
|
chatId?: string;
|
2127
2257
|
/**
|
2128
2258
|
* @deprecated
|
2129
|
-
* As of 2.0.0, please use {@link app.Context.user.loginHint} instead
|
2259
|
+
* As of 2.0.0, please use {@link app.UserInfo.loginHint | app.Context.user.loginHint} instead
|
2130
2260
|
*
|
2131
2261
|
* A value suitable for use as a login_hint when authenticating with Azure AD.
|
2132
2262
|
* Because a malicious party can run your content in a browser, this value should
|
@@ -2136,7 +2266,7 @@ export interface Context {
|
|
2136
2266
|
loginHint?: string;
|
2137
2267
|
/**
|
2138
2268
|
* @deprecated
|
2139
|
-
* As of 2.0.0, please use {@link app.Context.user.userPrincipalName} instead
|
2269
|
+
* As of 2.0.0, please use {@link app.UserInfo.userPrincipalName | app.Context.user.userPrincipalName} instead
|
2140
2270
|
*
|
2141
2271
|
* The UPN of the current user. This may be an externally-authenticated UPN (e.g., guest users).
|
2142
2272
|
* Because a malicious party run your content in a browser, this value should
|
@@ -2146,7 +2276,7 @@ export interface Context {
|
|
2146
2276
|
userPrincipalName?: string;
|
2147
2277
|
/**
|
2148
2278
|
* @deprecated
|
2149
|
-
* As of 2.0.0, please use {@link app.Context.user.id} instead
|
2279
|
+
* As of 2.0.0, please use {@link app.UserInfo.id | app.Context.user.id} instead
|
2150
2280
|
*
|
2151
2281
|
* The Azure AD object id of the current user.
|
2152
2282
|
* Because a malicious party run your content in a browser, this value should
|
@@ -2156,7 +2286,7 @@ export interface Context {
|
|
2156
2286
|
userObjectId?: string;
|
2157
2287
|
/**
|
2158
2288
|
* @deprecated
|
2159
|
-
* As of 2.0.0, please use {@link app.Context.team.isArchived} instead
|
2289
|
+
* As of 2.0.0, please use {@link app.TeamInfo.isArchived | app.Context.team.isArchived} instead
|
2160
2290
|
*
|
2161
2291
|
* Indicates whether team is archived.
|
2162
2292
|
* Apps should use this as a signal to prevent any changes to content associated with archived teams.
|
@@ -2164,14 +2294,14 @@ export interface Context {
|
|
2164
2294
|
isTeamArchived?: boolean;
|
2165
2295
|
/**
|
2166
2296
|
* @deprecated
|
2167
|
-
* As of 2.0.0, please use {@link app.Context.host.name} instead
|
2297
|
+
* As of 2.0.0, please use {@link app.AppHostInfo.name | app.Context.app.host.name} instead
|
2168
2298
|
*
|
2169
2299
|
* The name of the host client. Possible values are: Office, Orange, Outlook, Teams
|
2170
2300
|
*/
|
2171
2301
|
hostName?: HostName;
|
2172
2302
|
/**
|
2173
2303
|
* @deprecated
|
2174
|
-
* As of 2.0.0, please use {@link app.Context.host.clientType} instead
|
2304
|
+
* As of 2.0.0, please use {@link app.AppHostInfo.clientType | app.Context.app.host.clientType} instead
|
2175
2305
|
*
|
2176
2306
|
* The type of the host client. Possible values are : android, ios, web, desktop, rigel(deprecated, use teamsRoomsWindows instead),
|
2177
2307
|
* surfaceHub, teamsRoomsWindows, teamsRoomsAndroid, teamsPhones, teamsDisplays
|
@@ -2179,35 +2309,35 @@ export interface Context {
|
|
2179
2309
|
hostClientType?: HostClientType;
|
2180
2310
|
/**
|
2181
2311
|
* @deprecated
|
2182
|
-
* As of 2.0.0, please use {@link app.Context.page.frameContext} instead
|
2312
|
+
* As of 2.0.0, please use {@link app.PageInfo.frameContext | app.Context.page.frameContext} instead
|
2183
2313
|
*
|
2184
2314
|
* The context where tab url is loaded (content, task, setting, remove, sidePanel)
|
2185
2315
|
*/
|
2186
2316
|
frameContext?: FrameContexts;
|
2187
2317
|
/**
|
2188
2318
|
* @deprecated
|
2189
|
-
* As of 2.0.0, please use {@link app.Context.sharepoint} instead
|
2319
|
+
* As of 2.0.0, please use {@link app.Context | app.Context.sharepoint} instead
|
2190
2320
|
*
|
2191
2321
|
* SharePoint context. This is only available when hosted in SharePoint.
|
2192
2322
|
*/
|
2193
2323
|
sharepoint?: any;
|
2194
2324
|
/**
|
2195
2325
|
* @deprecated
|
2196
|
-
* As of 2.0.0, please use {@link app.Context.
|
2326
|
+
* As of 2.0.0, please use {@link app.TenantInfo.teamsSku | app.Context.tenant.teamsSku} instead
|
2197
2327
|
*
|
2198
2328
|
* The type of license for the current users tenant.
|
2199
2329
|
*/
|
2200
2330
|
tenantSKU?: string;
|
2201
2331
|
/**
|
2202
2332
|
* @deprecated
|
2203
|
-
* As of 2.0.0, please use {@link app.Context.user.licenseType} instead
|
2333
|
+
* As of 2.0.0, please use {@link app.UserInfo.licenseType | app.Context.user.licenseType} instead
|
2204
2334
|
*
|
2205
2335
|
* The license type for the current user.
|
2206
2336
|
*/
|
2207
2337
|
userLicenseType?: string;
|
2208
2338
|
/**
|
2209
2339
|
* @deprecated
|
2210
|
-
* As of 2.0.0, please use {@link app.Context.app.parentMessageId} instead
|
2340
|
+
* As of 2.0.0, please use {@link app.AppInfo.parentMessageId | app.Context.app.parentMessageId} instead
|
2211
2341
|
*
|
2212
2342
|
* The ID of the parent message from which this task module was launched.
|
2213
2343
|
* This is only available in task modules launched from bot cards.
|
@@ -2215,119 +2345,119 @@ export interface Context {
|
|
2215
2345
|
parentMessageId?: string;
|
2216
2346
|
/**
|
2217
2347
|
* @deprecated
|
2218
|
-
* As of 2.0.0, please use {@link app.Context.app.host.ringId} instead
|
2348
|
+
* As of 2.0.0, please use {@link app.AppHostInfo.ringId | app.Context.app.host.ringId} instead
|
2219
2349
|
*
|
2220
2350
|
* Current ring ID
|
2221
2351
|
*/
|
2222
2352
|
ringId?: string;
|
2223
2353
|
/**
|
2224
2354
|
* @deprecated
|
2225
|
-
* As of 2.0.0, please use {@link app.Context.app.sessionId} instead
|
2355
|
+
* As of 2.0.0, please use {@link app.AppInfo.sessionId | app.Context.app.sessionId} instead
|
2226
2356
|
*
|
2227
2357
|
* Unique ID for the current session for use in correlating telemetry data.
|
2228
2358
|
*/
|
2229
2359
|
appSessionId?: string;
|
2230
2360
|
/**
|
2231
2361
|
* @deprecated
|
2232
|
-
* As of 2.0.0, please use {@link app.Context.app.appLaunchId} instead
|
2362
|
+
* As of 2.0.0, please use {@link app.AppInfo.appLaunchId | app.Context.app.appLaunchId} instead
|
2233
2363
|
*
|
2234
2364
|
* ID for the current visible app which is different for across cached sessions. Used for correlating telemetry data``
|
2235
2365
|
*/
|
2236
2366
|
appLaunchId?: string;
|
2237
2367
|
/**
|
2238
2368
|
* @deprecated
|
2239
|
-
* As of 2.0.0, please use {@link app.Context.user.isCallingAllowed} instead
|
2369
|
+
* As of 2.0.0, please use {@link app.UserInfo.isCallingAllowed | app.Context.user.isCallingAllowed} instead
|
2240
2370
|
*
|
2241
2371
|
* Represents whether calling is allowed for the current logged in User
|
2242
2372
|
*/
|
2243
2373
|
isCallingAllowed?: boolean;
|
2244
2374
|
/**
|
2245
2375
|
* @deprecated
|
2246
|
-
* As of 2.0.0, please use {@link app.Context.user.isPSTNCallingAllowed} instead
|
2376
|
+
* As of 2.0.0, please use {@link app.UserInfo.isPSTNCallingAllowed | app.Context.user.isPSTNCallingAllowed} instead
|
2247
2377
|
*
|
2248
2378
|
* Represents whether PSTN calling is allowed for the current logged in User
|
2249
2379
|
*/
|
2250
2380
|
isPSTNCallingAllowed?: boolean;
|
2251
2381
|
/**
|
2252
2382
|
* @deprecated
|
2253
|
-
* As of 2.0.0, please use {@link app.Context.meeting.id} instead
|
2383
|
+
* As of 2.0.0, please use {@link app.MeetingInfo.id | app.Context.meeting.id} instead
|
2254
2384
|
*
|
2255
2385
|
* Meeting Id used by tab when running in meeting context
|
2256
2386
|
*/
|
2257
2387
|
meetingId?: string;
|
2258
2388
|
/**
|
2259
2389
|
* @deprecated
|
2260
|
-
* As of 2.0.0, please use {@link app.Context.channel.defaultOneNoteSectionId} instead
|
2390
|
+
* As of 2.0.0, please use {@link app.ChannelInfo.defaultOneNoteSectionId | app.Context.channel.defaultOneNoteSectionId} instead
|
2261
2391
|
*
|
2262
2392
|
* The OneNote section ID that is linked to the channel.
|
2263
2393
|
*/
|
2264
2394
|
defaultOneNoteSectionId?: string;
|
2265
2395
|
/**
|
2266
2396
|
* @deprecated
|
2267
|
-
* As of 2.0.0, please use {@link app.Context.page.isMultiWindow} instead
|
2397
|
+
* As of 2.0.0, please use {@link app.PageInfo.isMultiWindow | app.Context.page.isMultiWindow} instead
|
2268
2398
|
*
|
2269
2399
|
* Indication whether the tab is in a pop out window
|
2270
2400
|
*/
|
2271
2401
|
isMultiWindow?: boolean;
|
2272
2402
|
/**
|
2273
2403
|
* @deprecated
|
2274
|
-
* As of 2.0.0, please use {@link app.Context.app.iconPositionVertical} instead
|
2404
|
+
* As of 2.0.0, please use {@link app.AppInfo.iconPositionVertical | app.Context.app.iconPositionVertical} instead
|
2275
2405
|
*
|
2276
2406
|
* Personal app icon y coordinate position
|
2277
2407
|
*/
|
2278
2408
|
appIconPosition?: number;
|
2279
2409
|
/**
|
2280
2410
|
* @deprecated
|
2281
|
-
* As of 2.0.0, please use {@link app.Context.page.sourceOrigin} instead
|
2411
|
+
* As of 2.0.0, please use {@link app.PageInfo.sourceOrigin | app.Context.page.sourceOrigin} instead
|
2282
2412
|
*
|
2283
2413
|
* Source origin from where the tab is opened
|
2284
2414
|
*/
|
2285
2415
|
sourceOrigin?: string;
|
2286
2416
|
/**
|
2287
2417
|
* @deprecated
|
2288
|
-
* As of 2.0.0, please use {@link app.Context.app.userClickTime} instead
|
2418
|
+
* As of 2.0.0, please use {@link app.AppInfo.userClickTime | app.Context.app.userClickTime} instead
|
2289
2419
|
*
|
2290
2420
|
* Time when the user clicked on the tab
|
2291
2421
|
*/
|
2292
2422
|
userClickTime?: number;
|
2293
2423
|
/**
|
2294
2424
|
* @deprecated
|
2295
|
-
* As of 2.0.0, please use {@link app.Context.team.templateId} instead
|
2425
|
+
* As of 2.0.0, please use {@link app.TeamInfo.templateId | app.Context.team.templateId} instead
|
2296
2426
|
*
|
2297
2427
|
* Team Template ID if there was a Team Template associated with the creation of the team.
|
2298
2428
|
*/
|
2299
2429
|
teamTemplateId?: string;
|
2300
2430
|
/**
|
2301
2431
|
* @deprecated
|
2302
|
-
* As of 2.0.0, please use {@link app.Context.app.userFileOpenPreference} instead
|
2432
|
+
* As of 2.0.0, please use {@link app.AppInfo.userFileOpenPreference | app.Context.app.userFileOpenPreference} instead
|
2303
2433
|
*
|
2304
2434
|
* Where the user prefers the file to be opened from by default during file open
|
2305
2435
|
*/
|
2306
2436
|
userFileOpenPreference?: FileOpenPreference;
|
2307
2437
|
/**
|
2308
2438
|
* @deprecated
|
2309
|
-
* As of 2.0.0, please use {@link app.Context.user.displayName} instead
|
2439
|
+
* As of 2.0.0, please use {@link app.UserInfo.displayName | app.Context.user.displayName} instead
|
2310
2440
|
*
|
2311
2441
|
* The address book name of the current user.
|
2312
2442
|
*/
|
2313
2443
|
userDisplayName?: string;
|
2314
2444
|
/**
|
2315
2445
|
* @deprecated
|
2316
|
-
* As of 2.0.0, please use {@link app.Context.sharePointSite.teamSiteId} instead
|
2446
|
+
* As of 2.0.0, please use {@link app.SharePointSiteInfo.teamSiteId | app.Context.sharePointSite.teamSiteId} instead
|
2317
2447
|
*
|
2318
2448
|
* Teamsite ID, aka sharepoint site id.
|
2319
2449
|
*/
|
2320
2450
|
teamSiteId?: string;
|
2321
2451
|
/**
|
2322
2452
|
* @deprecated
|
2323
|
-
* As of 2.0.0, please use {@link app.Context.sharePointSite.mySiteDomain} instead
|
2453
|
+
* As of 2.0.0, please use {@link app.SharePointSiteInfo.mySiteDomain | app.Context.sharePointSite.mySiteDomain} instead
|
2324
2454
|
*
|
2325
2455
|
* The SharePoint my site domain associated with the user.
|
2326
2456
|
*/
|
2327
2457
|
mySiteDomain?: string;
|
2328
2458
|
/**
|
2329
2459
|
* @deprecated
|
2330
|
-
* As of 2.0.0, please use {@link app.Context.sharePointSite.mySitePath} instead
|
2460
|
+
* As of 2.0.0, please use {@link app.SharePointSiteInfo.mySitePath | app.Context.sharePointSite.mySitePath} instead
|
2331
2461
|
*
|
2332
2462
|
* The SharePoint relative path to the current users mysite
|
2333
2463
|
*/
|
@@ -2938,6 +3068,12 @@ export namespace app {
|
|
2938
3068
|
* Represents structure of the received context message.
|
2939
3069
|
*/
|
2940
3070
|
interface Context {
|
3071
|
+
/**
|
3072
|
+
* Content Action Info
|
3073
|
+
*
|
3074
|
+
* @beta
|
3075
|
+
*/
|
3076
|
+
actionInfo?: ActionInfo;
|
2941
3077
|
/**
|
2942
3078
|
* Info of the app
|
2943
3079
|
*/
|
@@ -3220,7 +3356,7 @@ export namespace dialog {
|
|
3220
3356
|
* Hide from docs because this function is only used during initialization
|
3221
3357
|
* ------------------
|
3222
3358
|
* Adds register handlers for messageForChild upon initialization and only in the tasks FrameContext. {@link FrameContexts.task}
|
3223
|
-
* Function is called during app
|
3359
|
+
* Function is called during app initialization
|
3224
3360
|
* @internal
|
3225
3361
|
*/
|
3226
3362
|
function initialize(): void;
|
@@ -3238,7 +3374,7 @@ export namespace dialog {
|
|
3238
3374
|
*/
|
3239
3375
|
function open(urlDialogInfo: UrlDialogInfo, submitHandler?: DialogSubmitHandler, messageFromChildHandler?: PostMessageChannel): void;
|
3240
3376
|
/**
|
3241
|
-
* Submit the dialog module
|
3377
|
+
* Submit the dialog module and close the dialog
|
3242
3378
|
*
|
3243
3379
|
* @param result - The result to be sent to the bot or the app. Typically a JSON object or a serialized version of it
|
3244
3380
|
* @param appIds - Helps to validate that the call originates from the same appId as the one that invoked the task module
|
@@ -4223,9 +4359,7 @@ export namespace media {
|
|
4223
4359
|
notifyEventToApp(mediaEvent: MediaControllerEvent): void;
|
4224
4360
|
}
|
4225
4361
|
/**
|
4226
|
-
* @
|
4227
|
-
* Hide from docs
|
4228
|
-
* --------
|
4362
|
+
* @beta
|
4229
4363
|
* Events which are used to communicate between the app and the host client during the media recording flow
|
4230
4364
|
*/
|
4231
4365
|
export enum MediaControllerEvent {
|
@@ -4562,12 +4696,20 @@ export namespace meeting {
|
|
4562
4696
|
*/
|
4563
4697
|
isAppSharing: boolean;
|
4564
4698
|
}
|
4699
|
+
/**
|
4700
|
+
* Property bag for the speakingState changed event
|
4701
|
+
*
|
4702
|
+
*/
|
4565
4703
|
interface ISpeakingState {
|
4566
4704
|
/**
|
4567
4705
|
* Indicates whether one or more participants in a meeting are speaking, or
|
4568
4706
|
* if no participants are speaking
|
4569
4707
|
*/
|
4570
4708
|
isSpeakingDetected: boolean;
|
4709
|
+
/**
|
4710
|
+
* error object in case there is a failure
|
4711
|
+
*/
|
4712
|
+
error?: SdkError;
|
4571
4713
|
}
|
4572
4714
|
/**
|
4573
4715
|
* Property bag for the meeting reaction received event
|
@@ -4750,9 +4892,9 @@ export namespace meeting {
|
|
4750
4892
|
*/
|
4751
4893
|
function getAppContentStageSharingState(callback: (error: SdkError | null, appContentStageSharingState: IAppContentStageSharingState | null) => void): void;
|
4752
4894
|
/**
|
4753
|
-
* Registers a handler for changes to paticipant speaking states.
|
4754
|
-
*
|
4755
|
-
* at a time. A subsequent registration replaces an existing registration.
|
4895
|
+
* Registers a handler for changes to paticipant speaking states. This API returns {@link ISpeakingState}, which will have isSpeakingDetected
|
4896
|
+
* and/or an error object. If any participant is speaking, isSpeakingDetected will be true. If no participants are speaking, isSpeakingDetected
|
4897
|
+
* will be false. Default value is false. Only one handler can be registered at a time. A subsequent registration replaces an existing registration.
|
4756
4898
|
*
|
4757
4899
|
* @param handler The handler to invoke when the speaking state of any participant changes (start/stop speaking).
|
4758
4900
|
*/
|
@@ -5622,7 +5764,7 @@ export function setFrameContext(frameContext: FrameContext): void;
|
|
5622
5764
|
* @deprecated
|
5623
5765
|
* As of 2.0.0, please use {@link pages.initializeWithFrameContext pages.initializeWithFrameContext(frameInfo: FrameInfo, callback?: () => void, validMessageOrigins?: string[],): void} instead.
|
5624
5766
|
*
|
5625
|
-
*
|
5767
|
+
* Initialize with FrameContext
|
5626
5768
|
*
|
5627
5769
|
* @param frameContext - FrameContext information to be set
|
5628
5770
|
* @param callback - The optional callback to be invoked be invoked after initilizing the frame context
|
@@ -5820,7 +5962,7 @@ export namespace tasks {
|
|
5820
5962
|
function getBotUrlDialogInfoFromTaskInfo(taskInfo: TaskInfo): BotUrlDialogInfo;
|
5821
5963
|
/**
|
5822
5964
|
* Sets the height and width of the {@link TaskInfo} object to the original height and width, if initially specified,
|
5823
|
-
* otherwise uses the height and width values corresponding to {@link TaskModuleDimension.Small}
|
5965
|
+
* otherwise uses the height and width values corresponding to {@link TaskModuleDimension | TaskModuleDimension.Small}
|
5824
5966
|
* @param taskInfo TaskInfo object from which to extract size info, if specified
|
5825
5967
|
* @returns TaskInfo with height and width specified
|
5826
5968
|
*/
|