# Microsoft Intune (Windows)

To deploy the MyZen Windows agent via Microsoft Intune, the MSI file must first be converted to the `.intunewin` format using the Microsoft Win32 Content Prep Tool.

## Prerequisites

* The MyZen Windows MSI installer downloaded from the We360.ai admin portal.
* The [Microsoft Win32 Content Prep Tool](https://github.com/Microsoft/Microsoft-Win32-Content-Prep-Tool) (`IntuneWinAppUtil.exe`).
* Access to Microsoft Endpoint Manager (Intune).
* The installer file must **not** be renamed or have extra characters appended to the filename. The stealth installer filename is tied to your organization's license.

{% hint style="danger" %}
**Do not rename the stealth installer file.** The **stealth** installer filename is tied to your organization's license. Renaming it, or allowing extra characters to be appended (e.g. `(1)` or `(2)` from duplicate downloads), will cause the installation to fail.
{% endhint %}

## Step 1: Convert the MSI to .intunewin Format

Run the Win32 Content Prep Tool from a Command Prompt or PowerShell:

```powershell
IntuneWinAppUtil.exe -c <folder-containing-msi> -s <msi-filename> -o <output-folder> -q
```

| Flag | Description                                      |
| ---- | ------------------------------------------------ |
| `-c` | Folder containing the MSI file                   |
| `-s` | The MSI filename (not including the folder path) |
| `-o` | Output folder for the `.intunewin` file          |
| `-q` | Quiet mode                                       |

### Example

```powershell
IntuneWinAppUtil.exe -c C:\Users\admin\Downloads\ -s zs.msi -o .\intune -q
```

> For full command-line parameter documentation, see the README in the [Microsoft Win32 Content Prep Tool GitHub repository](https://github.com/Microsoft/Microsoft-Win32-Content-Prep-Tool).

## Step 2: Upload to Intune

1. Open **Microsoft Endpoint Manager** (endpoint.microsoft.com).
2. Navigate to **Apps > All apps > Add**.
3. Select **Windows app (Win32)** as the app type.
4. Upload the `.intunewin` file generated in Step 1.
5. Configure the install command:

   ```
   MSIEXEC /i <msi-filename>.msi /QN
   ```
6. Configure the uninstall command:

   ```
   MSIEXEC /x <msi-filename>.msi /QN
   ```
7. Set detection rules (e.g. check for the existence of `MyZenV2.exe` or `MyZenV2s.exe` in Program Files).
8. Assign the app to the appropriate device groups.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.we360.ai/deployment-and-it-ops/agent-deployment-hub/mass-deployment/microsoft-intune.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
