@types/office-js-preview 1.0.520 → 1.0.522

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.
@@ -8,7 +8,7 @@ This package contains type definitions for office-js-preview (https://github.com
8
8
  Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/office-js-preview.
9
9
 
10
10
  ### Additional Details
11
- * Last updated: Mon, 07 Oct 2024 22:07:58 GMT
11
+ * Last updated: Thu, 17 Oct 2024 17:36:59 GMT
12
12
  * Dependencies: none
13
13
 
14
14
  # Credits
@@ -10090,6 +10090,12 @@ declare namespace Office {
10090
10090
  * [Api set: Mailbox 1.3]
10091
10091
  *
10092
10092
  * **{@link https://learn.microsoft.com/office/dev/add-ins/outlook/outlook-add-ins-overview#extension-points | Applicable Outlook mode}**: Compose or Read
10093
+ *
10094
+ * **Important**: The Outlook REST v2.0 and beta endpoints are now deprecated. However, privately released and AppSource-hosted add-ins are able to use the REST service
10095
+ * until extended support ends for Outlook 2019 on October 14, 2025. Traffic from these add-ins is automatically identified for exemption. This exemption also
10096
+ * applies to new add-ins developed after March 31, 2024. Although add-ins are able to use the REST service until 2025, we highly encourage you to migrate your
10097
+ * add-ins to use {@link https://learn.microsoft.com/outlook/rest#outlook-rest-api-via-microsoft-graph | Microsoft Graph}. For guidance, see
10098
+ * {@link https://learn.microsoft.com/outlook/rest/compare-graph | Compare Microsoft Graph and Outlook REST API endpoints}.
10093
10099
  */
10094
10100
  enum RestVersion {
10095
10101
  /**
@@ -10938,14 +10944,11 @@ declare namespace Office {
10938
10944
  */
10939
10945
  getInitializationContextAsync(callback: (asyncResult: Office.AsyncResult<string>) => void): void;
10940
10946
  /**
10941
- * Asynchronously gets the ID of a saved item.
10947
+ * Asynchronously gets the {@link https://learn.microsoft.com/exchange/client-developer/exchange-web-services/ews-identifiers-in-exchange | Exchange Web Services (EWS) item identifier}
10948
+ * of a saved item.
10942
10949
  *
10943
10950
  * When invoked, this method returns the item ID via the callback function.
10944
10951
  *
10945
- * **Note**: If your add-in calls `getItemIdAsync` on an item in compose mode (e.g., to get an `itemId` to use with EWS or the REST API),
10946
- * be aware that when Outlook is in cached mode, it may take some time before the item is synced to the server.
10947
- * Until the item is synced, the `itemId` is not recognized and using it returns an error.
10948
- *
10949
10952
  * @remarks
10950
10953
  * [Api set: Mailbox 1.8]
10951
10954
  *
@@ -10953,6 +10956,15 @@ declare namespace Office {
10953
10956
  *
10954
10957
  * **{@link https://learn.microsoft.com/office/dev/add-ins/outlook/outlook-add-ins-overview#extension-points | Applicable Outlook mode}**: Appointment Organizer
10955
10958
  *
10959
+ * **Important**:
10960
+ *
10961
+ * - The item ID returned isn't identical to the Outlook Entry ID or the ID used by the Outlook REST API.
10962
+ * Before making REST API calls using this value, it should be converted using `Office.context.mailbox.convertToRestId`.
10963
+ *
10964
+ * - If your add-in calls `getItemIdAsync` (for example, to get an item ID to use with EWS or the REST API),
10965
+ * be aware that when Outlook is in cached mode, it may take some time before the item is synced to the server.
10966
+ * Until the item is synced, the item ID isn't recognized and using it returns an error.
10967
+ *
10956
10968
  * **Errors**:
10957
10969
  *
10958
10970
  * - `ItemNotSaved`: The ID can't be retrieved until the item is saved.
@@ -10960,18 +10972,15 @@ declare namespace Office {
10960
10972
  * @param options - An object literal that contains one or more of the following properties:-
10961
10973
  * `asyncContext`: Developers can provide any object they wish to access in the callback function.
10962
10974
  * @param callback - When the method completes, the function passed in the `callback` parameter is called with a single parameter
10963
- * of type `Office.AsyncResult`.
10975
+ * of type `Office.AsyncResult`. The EWS item ID of the item is returned in the `asyncResult.value` property.
10964
10976
  */
10965
10977
  getItemIdAsync(options: Office.AsyncContextOptions, callback: (asyncResult: Office.AsyncResult<string>) => void): void;
10966
10978
  /**
10967
- * Asynchronously gets the ID of a saved item.
10979
+ * Asynchronously gets the {@link https://learn.microsoft.com/exchange/client-developer/exchange-web-services/ews-identifiers-in-exchange | Exchange Web Services (EWS) item identifier}
10980
+ * of a saved item.
10968
10981
  *
10969
10982
  * When invoked, this method returns the item ID via the callback function.
10970
10983
  *
10971
- * **Note**: If your add-in calls `getItemIdAsync` on an item in compose mode (e.g., to get an `itemId` to use with EWS or the REST API),
10972
- * be aware that when Outlook is in cached mode, it may take some time before the item is synced to the server.
10973
- * Until the item is synced, the `itemId` is not recognized and using it returns an error.
10974
- *
10975
10984
  * @remarks
10976
10985
  * [Api set: Mailbox 1.8]
10977
10986
  *
@@ -10979,12 +10988,21 @@ declare namespace Office {
10979
10988
  *
10980
10989
  * **{@link https://learn.microsoft.com/office/dev/add-ins/outlook/outlook-add-ins-overview#extension-points | Applicable Outlook mode}**: Appointment Organizer
10981
10990
  *
10991
+ * **Important**:
10992
+ *
10993
+ * - The item ID returned isn't identical to the Outlook Entry ID or the ID used by the Outlook REST API.
10994
+ * Before making REST API calls using this value, it should be converted using `Office.context.mailbox.convertToRestId`.
10995
+ *
10996
+ * - If your add-in calls `getItemIdAsync` (for example, to get an item ID to use with EWS or the REST API),
10997
+ * be aware that when Outlook is in cached mode, it may take some time before the item is synced to the server.
10998
+ * Until the item is synced, the item ID isn't recognized and using it returns an error.
10999
+ *
10982
11000
  * **Errors**:
10983
11001
  *
10984
11002
  * - `ItemNotSaved`: The ID can't be retrieved until the item is saved.
10985
11003
  *
10986
11004
  * @param callback - When the method completes, the function passed in the `callback` parameter is called with a single parameter
10987
- * of type `Office.AsyncResult`.
11005
+ * of type `Office.AsyncResult`. The EWS item ID of the item is returned in the `asyncResult.value` property.
10988
11006
  */
10989
11007
  getItemIdAsync(callback: (asyncResult: Office.AsyncResult<string>) => void): void;
10990
11008
  /**
@@ -11271,7 +11289,12 @@ declare namespace Office {
11271
11289
  * - When working with HTML-formatted content, it's important to note that the Outlook client may modify the content. This means that
11272
11290
  * subsequent calls to methods like `Body.getAsync`, `Body.setAsync`, and even `saveAsync` may not result in the same content.
11273
11291
  *
11274
- * - If your add-in calls `saveAsync` on an item in compose mode in order to get an item ID to use with EWS or the REST API, be aware that
11292
+ * - The identifier returned is the same as the
11293
+ * {@link https://learn.microsoft.com/exchange/client-developer/exchange-web-services/ews-identifiers-in-exchange | Exchange Web Services (EWS) item identifier}.
11294
+ * The item ID returned isn't identical to the Outlook Entry ID or the ID used by the Outlook REST API.
11295
+ * Before making REST API calls using this value, it should be converted using `Office.context.mailbox.convertToRestId`.
11296
+ *
11297
+ * - If your add-in calls `saveAsync` to get an item ID to use with EWS or the REST API, be aware that
11275
11298
  * when Outlook is in cached mode, it may take some time before the item is actually synced to the server.
11276
11299
  * Until the item is synced, using the item ID will return an error.
11277
11300
  *
@@ -11286,7 +11309,7 @@ declare namespace Office {
11286
11309
  * @param options - An object literal that contains one or more of the following properties:-
11287
11310
  * `asyncContext`: Developers can provide any object they wish to access in the callback function.
11288
11311
  * @param callback - When the method completes, the function passed in the `callback` parameter is called with a single parameter, `asyncResult`,
11289
- * which is an `Office.AsyncResult` object. The appointment ID is returned in the `asyncResult.value` property.
11312
+ * which is an `Office.AsyncResult` object. The EWS appointment ID is returned in the `asyncResult.value` property.
11290
11313
  */
11291
11314
  saveAsync(options: Office.AsyncContextOptions, callback: (asyncResult: Office.AsyncResult<string>) => void): void;
11292
11315
  /**
@@ -11311,7 +11334,12 @@ declare namespace Office {
11311
11334
  * - When working with HTML-formatted content, it's important to note that the Outlook client may modify the content. This means that
11312
11335
  * subsequent calls to methods like `Body.getAsync`, `Body.setAsync`, and even `saveAsync` may not result in the same content.
11313
11336
  *
11314
- * - If your add-in calls `saveAsync` on an item in compose mode in order to get an item ID to use with EWS or the REST API, be aware that
11337
+ * - The identifier returned is the same as the
11338
+ * {@link https://learn.microsoft.com/exchange/client-developer/exchange-web-services/ews-identifiers-in-exchange | Exchange Web Services (EWS) item identifier}.
11339
+ * The item ID returned isn't identical to the Outlook Entry ID or the ID used by the Outlook REST API.
11340
+ * Before making REST API calls using this value, it should be converted using `Office.context.mailbox.convertToRestId`.
11341
+ *
11342
+ * - If your add-in calls `saveAsync` to get an item ID to use with EWS or the REST API, be aware that
11315
11343
  * when Outlook is in cached mode, it may take some time before the item is actually synced to the server.
11316
11344
  * Until the item is synced, using the item ID will return an error.
11317
11345
  *
@@ -11324,7 +11352,7 @@ declare namespace Office {
11324
11352
  * - `InvalidAttachmentId`: The attachment identifier does not exist.
11325
11353
  *
11326
11354
  * @param callback - When the method completes, the function passed in the `callback` parameter is called with a single parameter, `asyncResult`,
11327
- * which is an `Office.AsyncResult` object. The appointment ID is returned in the `asyncResult.value` property.
11355
+ * which is an `Office.AsyncResult` object. The EWS appointment ID is returned in the `asyncResult.value` property.
11328
11356
  */
11329
11357
  saveAsync(callback: (asyncResult: Office.AsyncResult<string>) => void): void;
11330
11358
  /**
@@ -11690,24 +11718,23 @@ declare namespace Office {
11690
11718
  */
11691
11719
  itemClass: string;
11692
11720
  /**
11693
- * Gets the {@link https://learn.microsoft.com/exchange/client-developer/exchange-web-services/ews-identifiers-in-exchange | Exchange Web Services item identifier}
11694
- * for the current item.
11695
- *
11696
- * The `itemId` property is not available in compose mode.
11697
- * If an item identifier is required, the `saveAsync` method can be used to save the item to the store, which will return the item identifier
11698
- * in the `asyncResult.value` parameter in the callback function.
11699
- *
11700
- * **Note**: The identifier returned by the `itemId` property is the same as the
11701
- * {@link https://learn.microsoft.com/exchange/client-developer/exchange-web-services/ews-identifiers-in-exchange | Exchange Web Services item identifier}.
11702
- * The `itemId` property is not identical to the Outlook Entry ID or the ID used by the Outlook REST API.
11703
- * Before making REST API calls using this value, it should be converted using `Office.context.mailbox.convertToRestId`.
11704
- * For more details, see {@link https://learn.microsoft.com/office/dev/add-ins/outlook/use-rest-api#get-the-item-id | Use the Outlook REST APIs from an Outlook add-in}.
11721
+ * Gets the {@link https://learn.microsoft.com/exchange/client-developer/exchange-web-services/ews-identifiers-in-exchange | Exchange Web Services (EWS) item identifier}
11722
+ * of the current item.
11705
11723
  *
11706
11724
  * @remarks
11707
11725
  *
11708
11726
  * **{@link https://learn.microsoft.com/office/dev/add-ins/outlook/understanding-outlook-add-in-permissions | Minimum permission level}**: **read item**
11709
11727
  *
11710
11728
  * **{@link https://learn.microsoft.com/office/dev/add-ins/outlook/outlook-add-ins-overview#extension-points | Applicable Outlook mode}**: Appointment Attendee
11729
+ *
11730
+ * **Important**:
11731
+ *
11732
+ * - The `itemId` property isn't available in compose mode.
11733
+ * If an item identifier is required, the `Office.context.mailbox.item.saveAsync` method can be used to save the item to the store, which will return the item identifier
11734
+ * in the `asyncResult.value` parameter in the callback function. If the item is already saved, you can call the `Office.context.mailbox.item.getItemIdAsync` method instead.
11735
+ *
11736
+ * - The item ID returned isn't identical to the Outlook Entry ID or the ID used by the Outlook REST API.
11737
+ * Before making REST API calls using this value, it should be converted using `Office.context.mailbox.convertToRestId`.
11711
11738
  */
11712
11739
  itemId: string;
11713
11740
  /**
@@ -15080,15 +15107,6 @@ declare namespace Office {
15080
15107
  /**
15081
15108
  * Gets the URL of the REST endpoint for this email account.
15082
15109
  *
15083
- * Your app must have the **read item** permission specified in its manifest to call the `restUrl` member in read mode.
15084
- *
15085
- * In compose mode you must call the `saveAsync` method before you can use the `restUrl` member.
15086
- * Your app must have **read/write item** permissions to call the `saveAsync` method.
15087
- *
15088
- * However, in delegate or shared scenarios, you should instead use the `targetRestUrl` property of the
15089
- * {@link Office.SharedProperties | SharedProperties} object (introduced in requirement set 1.8). For more information,
15090
- * see the {@link https://learn.microsoft.com/office/dev/add-ins/outlook/delegate-access | shared folders and shared mailbox} article.
15091
- *
15092
15110
  * @remarks
15093
15111
  * [Api set: Mailbox 1.5]
15094
15112
  *
@@ -15096,7 +15114,21 @@ declare namespace Office {
15096
15114
  *
15097
15115
  * **{@link https://learn.microsoft.com/office/dev/add-ins/outlook/outlook-add-ins-overview#extension-points | Applicable Outlook mode}**: Compose or Read
15098
15116
  *
15099
- * The `restUrl` value can be used to make {@link https://learn.microsoft.com/outlook/rest/ | REST API} calls to the user's mailbox.
15117
+ * **Important**:
15118
+ *
15119
+ * - The Outlook REST v2.0 and beta endpoints are now deprecated. However, privately released and AppSource-hosted add-ins are able to use the REST service
15120
+ * until extended support ends for Outlook 2019 on October 14, 2025. Traffic from these add-ins is automatically identified for exemption. This exemption also
15121
+ * applies to new add-ins developed after March 31, 2024. Although add-ins are able to use the REST service until 2025, we highly encourage you to migrate your
15122
+ * add-ins to use {@link https://learn.microsoft.com/outlook/rest#outlook-rest-api-via-microsoft-graph | Microsoft Graph}. For guidance, see
15123
+ * {@link https://learn.microsoft.com/outlook/rest/compare-graph | Compare Microsoft Graph and Outlook REST API endpoints}.
15124
+ *
15125
+ * - Your add-in must have the **read item** permission specified in its manifest to call the `restUrl` member in read mode.
15126
+ *
15127
+ * - In compose mode you must call the `saveAsync` method before you can use the `restUrl` member.
15128
+ * Your add-in must have **read/write item** permissions to call the `saveAsync` method.
15129
+ * However, in delegate or shared scenarios, you should instead use the `targetRestUrl` property of the
15130
+ * {@link Office.SharedProperties | SharedProperties} object (introduced in requirement set 1.8). For more information,
15131
+ * see the {@link https://learn.microsoft.com/office/dev/add-ins/outlook/delegate-access | shared folders and shared mailbox} article.
15100
15132
  */
15101
15133
  restUrl: string;
15102
15134
  /**
@@ -15159,10 +15191,17 @@ declare namespace Office {
15159
15191
  *
15160
15192
  * **Important**:
15161
15193
  *
15194
+ * - In October 2024, legacy Exchange {@link https://learn.microsoft.com/office/dev/add-ins/outlook/authentication#exchange-user-identity-token | user identity} and
15195
+ * {@link https://learn.microsoft.com/office/dev/add-ins/outlook/authentication#callback-tokens | callback} tokens will be turned off by default for all Exchange Online tenants.
15196
+ * This is part of {@link https://blogs.microsoft.com/on-the-issues/2023/11/02/secure-future-initiative-sfi-cybersecurity-cyberattacks/ | Microsoft's Secure Future Initiative},
15197
+ * which gives organizations the tools needed to respond to the current threat landscape. Exchange user identity tokens will still work for Exchange on-premises.
15198
+ * Nested app authentication is the recommended approach for tokens going forward. For more information, see our {@link https://aka.ms/NAApreviewblog | blog post} and
15199
+ * {@link https://learn.microsoft.com/office/dev/add-ins/outlook/faq-nested-app-auth-outlook-legacy-tokens | FAQ page}.
15200
+ *
15162
15201
  * - This method isn't supported in Outlook on Android or on iOS. For more information on supported APIs in Outlook mobile, see
15163
15202
  * {@link https://learn.microsoft.com/office/dev/add-ins/outlook/outlook-mobile-apis | Outlook JavaScript APIs supported in Outlook on mobile devices}.
15164
15203
  *
15165
- * - Item IDs retrieved via a REST API (such as the Outlook Mail API or the Microsoft Graph) use a different format than the format used by EWS.
15204
+ * - Item IDs retrieved via a REST API (such as {@link https://graph.microsoft.io/ | Microsoft Graph}) use a different format than the format used by EWS.
15166
15205
  * The `convertToEwsId` method converts a REST-formatted ID into the proper format for EWS.
15167
15206
  *
15168
15207
  * @param id - The ID to be converted into EWS format. This string can be an item ID formatted for the Outlook REST APIs or a conversation ID retrieved from
@@ -15206,10 +15245,8 @@ declare namespace Office {
15206
15245
  * - This method isn't supported in Outlook on Android or on iOS. For more information on supported APIs in Outlook mobile, see
15207
15246
  * {@link https://learn.microsoft.com/office/dev/add-ins/outlook/outlook-mobile-apis | Outlook JavaScript APIs supported in Outlook on mobile devices}.
15208
15247
  *
15209
- * - Item IDs retrieved via Exchange Web Services (EWS) or via the `itemId` property use a different format than the format used by REST APIs (such as the
15210
- * {@link https://learn.microsoft.com/previous-versions/office/office-365-api/api/version-2.0/mail-rest-operations | Outlook Mail API}
15211
- * or the {@link https://graph.microsoft.io/ | Microsoft Graph}).
15212
- * The `convertToRestId` method converts an EWS-formatted ID into the proper format for REST.
15248
+ * - Item IDs retrieved via Exchange Web Services (EWS) or via the `itemId` property use a different format than the format used by REST APIs (such as
15249
+ * {@link https://graph.microsoft.io/ | Microsoft Graph}). The `convertToRestId` method converts an EWS-formatted ID into the proper format for REST.
15213
15250
  *
15214
15251
  * @param id - The ID to be converted into REST format. This string can be an item ID formatted for EWS that's usually retrieved from
15215
15252
  * `Office.context.mailbox.item.itemId`, a conversation ID retrieved from `Office.context.mailbox.item.conversationId`, or a
@@ -15678,6 +15715,12 @@ declare namespace Office {
15678
15715
  * Nested app authentication is the recommended approach for tokens going forward. For more information, see our {@link https://aka.ms/NAApreviewblog | blog post} and
15679
15716
  * {@link https://learn.microsoft.com/office/dev/add-ins/outlook/faq-nested-app-auth-outlook-legacy-tokens | FAQ page}.
15680
15717
  *
15718
+ * - The Outlook REST v2.0 and beta endpoints are now deprecated. However, privately released and AppSource-hosted add-ins are able to use the REST service
15719
+ * until extended support ends for Outlook 2019 on October 14, 2025. Traffic from these add-ins is automatically identified for exemption. This exemption also
15720
+ * applies to new add-ins developed after March 31, 2024. Although add-ins are able to use the REST service until 2025, we highly encourage you to migrate your
15721
+ * add-ins to use {@link https://learn.microsoft.com/outlook/rest#outlook-rest-api-via-microsoft-graph | Microsoft Graph}. For guidance, see
15722
+ * {@link https://learn.microsoft.com/outlook/rest/compare-graph | Compare Microsoft Graph and Outlook REST API endpoints}.
15723
+ *
15681
15724
  * - This method isn't supported if you load an add-in in an Outlook.com or Gmail mailbox.
15682
15725
  *
15683
15726
  * - This method is only supported in read mode in Outlook on Android and on iOS. For more information on supported APIs in Outlook mobile, see
@@ -17249,14 +17292,11 @@ declare namespace Office {
17249
17292
  */
17250
17293
  getItemClassAsync(callback: (asyncResult: Office.AsyncResult<string>) => void): void;
17251
17294
  /**
17252
- * Asynchronously gets the ID of a saved item.
17295
+ * Asynchronously gets the {@link https://learn.microsoft.com/exchange/client-developer/exchange-web-services/ews-identifiers-in-exchange | Exchange Web Services (EWS) item identifier}
17296
+ * of a saved item.
17253
17297
  *
17254
17298
  * When invoked, this method returns the item ID via the callback function.
17255
17299
  *
17256
- * **Note**: If your add-in calls `getItemIdAsync` on an item in compose mode (e.g., to get an `itemId` to use with EWS or the REST API),
17257
- * be aware that when Outlook is in cached mode, it may take some time before the item is synced to the server.
17258
- * Until the item is synced, the `itemId` is not recognized and using it returns an error.
17259
- *
17260
17300
  * @remarks
17261
17301
  * [Api set: Mailbox 1.8]
17262
17302
  *
@@ -17264,6 +17304,15 @@ declare namespace Office {
17264
17304
  *
17265
17305
  * **{@link https://learn.microsoft.com/office/dev/add-ins/outlook/outlook-add-ins-overview#extension-points | Applicable Outlook mode}**: Message Compose
17266
17306
  *
17307
+ * **Important**:
17308
+ *
17309
+ * - The item ID returned isn't identical to the Outlook Entry ID or the ID used by the Outlook REST API.
17310
+ * Before making REST API calls using this value, it should be converted using `Office.context.mailbox.convertToRestId`.
17311
+ *
17312
+ * - If your add-in calls `getItemIdAsync` (for example, to get an item ID to use with EWS or the REST API),
17313
+ * be aware that when Outlook is in cached mode, it may take some time before the item is synced to the server.
17314
+ * Until the item is synced, the item ID isn't recognized and using it returns an error.
17315
+ *
17267
17316
  * **Errors**:
17268
17317
  *
17269
17318
  * - `ItemNotSaved`: The ID can't be retrieved until the item is saved.
@@ -17271,18 +17320,15 @@ declare namespace Office {
17271
17320
  * @param options - An object literal that contains one or more of the following properties:-
17272
17321
  * `asyncContext`: Developers can provide any object they wish to access in the callback function.
17273
17322
  * @param callback - When the method completes, the function passed in the `callback` parameter is called with a single parameter
17274
- * of type `Office.AsyncResult`.
17323
+ * of type `Office.AsyncResult`. The EWS item ID of the item is returned in the `asyncResult.value` property.
17275
17324
  */
17276
17325
  getItemIdAsync(options: Office.AsyncContextOptions, callback: (asyncResult: Office.AsyncResult<string>) => void): void;
17277
17326
  /**
17278
- * Asynchronously gets the ID of a saved item.
17327
+ * Asynchronously gets the {@link https://learn.microsoft.com/exchange/client-developer/exchange-web-services/ews-identifiers-in-exchange | Exchange Web Services (EWS) item identifier}
17328
+ * of a saved item.
17279
17329
  *
17280
17330
  * When invoked, this method returns the item ID via the callback function.
17281
17331
  *
17282
- * **Note**: If your add-in calls `getItemIdAsync` on an item in compose mode (e.g., to get an `itemId` to use with EWS or the REST API),
17283
- * be aware that when Outlook is in cached mode, it may take some time before the item is synced to the server.
17284
- * Until the item is synced, the `itemId` is not recognized and using it returns an error.
17285
- *
17286
17332
  * @remarks
17287
17333
  * [Api set: Mailbox 1.8]
17288
17334
  *
@@ -17290,12 +17336,21 @@ declare namespace Office {
17290
17336
  *
17291
17337
  * **{@link https://learn.microsoft.com/office/dev/add-ins/outlook/outlook-add-ins-overview#extension-points | Applicable Outlook mode}**: Message Compose
17292
17338
  *
17339
+ * **Important**:
17340
+ *
17341
+ * - The item ID returned isn't identical to the Outlook Entry ID or the ID used by the Outlook REST API.
17342
+ * Before making REST API calls using this value, it should be converted using `Office.context.mailbox.convertToRestId`.
17343
+ *
17344
+ * - If your add-in calls `getItemIdAsync` (for example, to get an item ID to use with EWS or the REST API),
17345
+ * be aware that when Outlook is in cached mode, it may take some time before the item is synced to the server.
17346
+ * Until the item is synced, the item ID isn't recognized and using it returns an error.
17347
+ *
17293
17348
  * **Errors**:
17294
17349
  *
17295
17350
  * - `ItemNotSaved`: The ID can't be retrieved until the item is saved.
17296
17351
  *
17297
17352
  * @param callback - When the method completes, the function passed in the `callback` parameter is called with a single parameter
17298
- * of type `Office.AsyncResult`.
17353
+ * of type `Office.AsyncResult`. The EWS item ID of the item is returned in the `asyncResult.value` property.
17299
17354
  */
17300
17355
  getItemIdAsync(callback: (asyncResult: Office.AsyncResult<string>) => void): void;
17301
17356
  /**
@@ -17626,7 +17681,12 @@ declare namespace Office {
17626
17681
  * - When working with HTML-formatted content, it's important to note that the Outlook client may modify the content. This means that
17627
17682
  * subsequent calls to methods like `Body.getAsync`, `Body.setAsync`, and even `saveAsync` may not result in the same content.
17628
17683
  *
17629
- * - If your add-in calls `saveAsync` on an item in compose mode in order to get an item ID to use with EWS or the REST API, be aware that
17684
+ * - The identifier returned is the same as the
17685
+ * {@link https://learn.microsoft.com/exchange/client-developer/exchange-web-services/ews-identifiers-in-exchange | Exchange Web Services (EWS) item identifier}.
17686
+ * The item ID returned isn't identical to the Outlook Entry ID or the ID used by the Outlook REST API.
17687
+ * Before making REST API calls using this value, it should be converted using `Office.context.mailbox.convertToRestId`.
17688
+ *
17689
+ * - If your add-in calls `saveAsync` to get an item ID to use with EWS or the REST API, be aware that
17630
17690
  * when Outlook is in cached mode, it may take some time before the item is actually synced to the server.
17631
17691
  * Until the item is synced, using the item ID will return an error.
17632
17692
  *
@@ -17643,7 +17703,7 @@ declare namespace Office {
17643
17703
  * @param options - An object literal that contains one or more of the following properties:-
17644
17704
  * `asyncContext`: Developers can provide any object they wish to access in the callback function.
17645
17705
  * @param callback - When the method completes, the function passed in the `callback` parameter is called with a single parameter, `asyncResult`,
17646
- * which is an `Office.AsyncResult` object. The message ID is returned in the `asyncResult.value` property.
17706
+ * which is an `Office.AsyncResult` object. The EWS message ID is returned in the `asyncResult.value` property.
17647
17707
  */
17648
17708
  saveAsync(options: Office.AsyncContextOptions, callback: (asyncResult: Office.AsyncResult<string>) => void): void;
17649
17709
  /**
@@ -17664,7 +17724,12 @@ declare namespace Office {
17664
17724
  * - When working with HTML-formatted content, it's important to note that the Outlook client may modify the content. This means that
17665
17725
  * subsequent calls to methods like `Body.getAsync`, `Body.setAsync`, and even `saveAsync` may not result in the same content.
17666
17726
  *
17667
- * - If your add-in calls `saveAsync` on an item in compose mode in order to get an item ID to use with EWS or the REST API, be aware that
17727
+ * - The identifier returned is the same as the
17728
+ * {@link https://learn.microsoft.com/exchange/client-developer/exchange-web-services/ews-identifiers-in-exchange | Exchange Web Services (EWS) item identifier}.
17729
+ * The item ID returned isn't identical to the Outlook Entry ID or the ID used by the Outlook REST API.
17730
+ * Before making REST API calls using this value, it should be converted using `Office.context.mailbox.convertToRestId`.
17731
+ *
17732
+ * - If your add-in calls `saveAsync` to get an item ID to use with EWS or the REST API, be aware that
17668
17733
  * when Outlook is in cached mode, it may take some time before the item is actually synced to the server.
17669
17734
  * Until the item is synced, using the item ID will return an error.
17670
17735
  *
@@ -17679,7 +17744,7 @@ declare namespace Office {
17679
17744
  * - `InvalidAttachmentId`: The attachment identifier does not exist.
17680
17745
  *
17681
17746
  * @param callback - When the method completes, the function passed in the `callback` parameter is called with a single parameter, `asyncResult`,
17682
- * which is an `Office.AsyncResult` object. The message ID is returned in the `asyncResult.value` property.
17747
+ * which is an `Office.AsyncResult` object. The EWS message ID is returned in the `asyncResult.value` property.
17683
17748
  */
17684
17749
  saveAsync(callback: (asyncResult: Office.AsyncResult<string>) => void): void;
17685
17750
  /**
@@ -17969,24 +18034,23 @@ declare namespace Office {
17969
18034
  */
17970
18035
  itemClass: string;
17971
18036
  /**
17972
- * Gets the {@link https://learn.microsoft.com/exchange/client-developer/exchange-web-services/ews-identifiers-in-exchange | Exchange Web Services item identifier}
17973
- * for the current item.
17974
- *
17975
- * The `itemId` property is not available in compose mode.
17976
- * If an item identifier is required, the `saveAsync` method can be used to save the item to the store, which will return the item identifier
17977
- * in the `asyncResult.value` parameter in the callback function.
17978
- *
17979
- * **Note**: The identifier returned by the `itemId` property is the same as the
17980
- * {@link https://learn.microsoft.com/exchange/client-developer/exchange-web-services/ews-identifiers-in-exchange | Exchange Web Services item identifier}.
17981
- * The `itemId` property is not identical to the Outlook Entry ID or the ID used by the Outlook REST API.
17982
- * Before making REST API calls using this value, it should be converted using `Office.context.mailbox.convertToRestId`.
17983
- * For more details, see {@link https://learn.microsoft.com/office/dev/add-ins/outlook/use-rest-api#get-the-item-id | Use the Outlook REST APIs from an Outlook add-in}.
18037
+ * Gets the {@link https://learn.microsoft.com/exchange/client-developer/exchange-web-services/ews-identifiers-in-exchange | Exchange Web Services (EWS) item identifier}
18038
+ * of the current item.
17984
18039
  *
17985
18040
  * @remarks
17986
18041
  *
17987
18042
  * **{@link https://learn.microsoft.com/office/dev/add-ins/outlook/understanding-outlook-add-in-permissions | Minimum permission level}**: **read item**
17988
18043
  *
17989
18044
  * **{@link https://learn.microsoft.com/office/dev/add-ins/outlook/outlook-add-ins-overview#extension-points | Applicable Outlook mode}**: Message Read
18045
+ *
18046
+ * **Important**:
18047
+ *
18048
+ * - The `itemId` property isn't available in compose mode.
18049
+ * If an item identifier is required, the `Office.context.mailbox.item.saveAsync` method can be used to save the item to the store, which will return the item identifier
18050
+ * in the `asyncResult.value` parameter in the callback function. If the item is already saved, you can call the `Office.context.mailbox.item.getItemIdAsync` method instead.
18051
+ *
18052
+ * - The item ID returned isn't identical to the Outlook Entry ID or the ID used by the Outlook REST API.
18053
+ * Before making REST API calls using this value, it should be converted using `Office.context.mailbox.convertToRestId`.
17990
18054
  */
17991
18055
  itemId: string;
17992
18056
  /**
@@ -93579,6 +93643,17 @@ declare namespace Word {
93579
93643
  * @param documentCompareOptions Optional. The additional options that specifies the behavior of comparing document.
93580
93644
  */
93581
93645
  compare(filePath: string, documentCompareOptions?: Word.DocumentCompareOptions): void;
93646
+ /**
93647
+ * Displays revision marks that indicate where the specified document differs from another document.
93648
+ *
93649
+ * @remarks
93650
+ * [Api set: WordApi BETA (PREVIEW ONLY)]
93651
+ * @beta
93652
+ *
93653
+ * @param base64File Required. The Base64-encoded content of the document with which the specified document is compared.
93654
+ * @param documentCompareOptions Optional. The additional options that specify the behavior for comparing the documents. Note that the `compareTarget` option isn't allowed to be `CompareTargetSelected` in this API.
93655
+ */
93656
+ compareFromBase64(base64File: string, documentCompareOptions?: Word.DocumentCompareOptions): void;
93582
93657
  /**
93583
93658
  * Deletes a bookmark, if it exists, from the document.
93584
93659
  *
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@types/office-js-preview",
3
- "version": "1.0.520",
3
+ "version": "1.0.522",
4
4
  "description": "TypeScript definitions for office-js-preview",
5
5
  "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/office-js-preview",
6
6
  "license": "MIT",
@@ -45,7 +45,7 @@
45
45
  },
46
46
  "scripts": {},
47
47
  "dependencies": {},
48
- "typesPublisherContentHash": "572b97676af58aa2f2fe751816052413077bb7899ee68c3843f11fb85958544d",
48
+ "typesPublisherContentHash": "83834c7b28bf4e61dfea9c8a5245488657f680721bad1588fac8278fb33127ca",
49
49
  "typeScriptVersion": "4.8",
50
50
  "nonNpm": true
51
51
  }