Skip to content

Commit 5d620de

Browse files
[All Hosts] (sideloading) sideloading with Teams CLI update (#5072)
* [All Hosts] (sideloading) sideloading with Teams CLI update * Apply suggestions from code review Co-authored-by: Sam Ramon <[email protected]> --------- Co-authored-by: Sam Ramon <[email protected]>
1 parent 2cda58e commit 5d620de

File tree

2 files changed

+19
-5
lines changed

2 files changed

+19
-5
lines changed

docs/images/teams-cli-install.png

51.3 KB
Loading

docs/testing/sideload-add-in-with-unified-manifest.md

Lines changed: 19 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: Sideload Office Add-ins that use the unified manifest for Microsoft 365
33
description: Test your Office Add-in on Windows by sideloading.
4-
ms.date: 02/12/2025
4+
ms.date: 02/26/2025
55
ms.localizationpriority: medium
66
---
77

@@ -65,16 +65,30 @@ There are two tools you can use to sideload.
6565
1. Use any zip utility to create a zip file that contains the unified manifest and the two image files. *The image files must have the same relative path in the zip file as they do in the project.* For example, if the relative path is "assets/icon-64.png" and "assets/icon-128.png", then you must include the "assets" folder with the two files in the zip package.
6666
1. If the folder contains other files, such as image files used in the Office ribbon, remove these from the zip package. It should have only the two image files specified in the "icons" property (in addition to the manifest in the root of the zip package).
6767
68-
1. In the root of the project, open a command prompt or bash shell and run the following commands.
68+
1. In the root of the project, open a command prompt or bash shell and run the following command to install the Teams Toolkit CLI.
6969
7070
```command&nbsp;line
7171
npm install -g @microsoft/teamsapp-cli
72+
```
73+
74+
1. Run the following command to sideload the add-in.
7275
76+
```command&nbsp;line
7377
teamsapp install --file-path <relative-path-to-zip-file>
74-
```
78+
```
79+
80+
> [!IMPORTANT]
81+
> This command returns some information about the add-in including an autogenerated title ID as shown in the following example.
82+
>
83+
> :::image type="content" source="../images/teams-cli-install.png" alt-text="The command 'teamsapp install --file-path manifests/contoso/contoso.zip' and the system response including the user's account name, the title id GUID and the app id GUID.":::
84+
>
85+
> You'll need this title ID to end the sideloading and debugging session, so save it. We recommend that you put it in a text file in the root of the project and name the file **TitleID.txt**.
7586
76-
1. When you use the Teams Toolkit CLI to start an add-in, *always stop the session with the following command*. Closing the server window doesn't reliably stop the server and closing the Office application doesn't reliably cause Office to unacquire the add-in. Replace the "{GUID of the add-in}" with the GUID in the "id" property of the unified manifest.
87+
1. When you use the Teams Toolkit CLI to start an add-in, *always stop the session with the following command*. Closing the server window doesn't reliably stop the server and closing the Office application doesn't reliably cause Office to unacquire the add-in. Replace "{title ID}" with the title ID of the add-in including the "U_" prefix; for example, `U_90d141c6-cf4f-40ee-b714-9df9ea593f39`.
7788
7889
```command&nbsp;line
79-
teamsapp uninstall -manifest-id {GUID of the add-in}
90+
teamsapp uninstall --mode title-id --title-id {title ID} --interactive false
8091
```
92+
93+
> [!IMPORTANT]
94+
> The [documentation for the `uninstall` command](/microsoftteams/platform/toolkit/teams-toolkit-cli?pivots=version-three#teamsapp-uninstall) describes a way to use the add-in's manifest ID instead of the title ID. Due to a bug in an API that the CLI calls, this option doesn't currently work. You must use the `uninstall` command given above and you must include the `--interactive false` option.

0 commit comments

Comments
 (0)