> ## Documentation Index
> Fetch the complete documentation index at: https://www.bugzy.ai/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Microsoft Teams

> Talk to Bugzy like any other team member — receive test results, dispute findings, ask questions, and trigger test runs from Microsoft Teams.

Microsoft Teams gives Bugzy the same communication capabilities as Slack. Once connected, Bugzy posts test results, responds to questions, accepts disputed findings, and executes tasks — all through normal Teams conversations. Think of it as adding a QA teammate to your channel.

## What you can do in Teams

| Action                 | How                                      | What happens                               |
| ---------------------- | ---------------------------------------- | ------------------------------------------ |
| Ask Bugzy to run tests | "Hey Bugzy, run smoke tests on checkout" | Bugzy confirms and executes                |
| Verify a PR            | "Bugzy, verify PR #42"                   | Bugzy runs relevant tests, posts results   |
| Dispute a finding      | Reply to a finding notification          | Bugzy re-evaluates, updates knowledge base |
| Ask about test results | "What failed in the last run?"           | Bugzy responds with context                |
| Get status             | "Bugzy, what's the test status?"         | Bugzy summarizes recent results            |

## The conversation model

Bugzy interacts via the inbox agent conversation model:

1. An event triggers Bugzy (message, webhook, schedule)
2. Bugzy proposes an action in the channel: "I'd like to run smoke tests on the checkout flow. Should I proceed?"
3. A team member responds (thumbs up, "yes", or custom instructions)
4. Bugzy executes and posts results in the same thread

For automated triggers (cron, deployment hooks), Bugzy executes without confirmation and posts results directly.

## Disputed findings

When Bugzy reports a finding that's incorrect:

1. Reply to the finding message with your reasoning
2. Bugzy's `handle-message` task processes the reply
3. If the dispute is valid, the finding is updated
4. Knowledge base adjusted to avoid similar false positives
5. Bugzy confirms the resolution in the thread

## Setup

<Steps>
  <Step title="Ensure bot is installed">
    Your organization's Teams admin must install the Bugzy bot in your Teams tenant. This is a one-time setup for the entire organization.
  </Step>

  <Step title="Add bot to your team">
    In Microsoft Teams, go to **Apps**, find the Bugzy bot, and add it to your team.
  </Step>

  <Step title="Get your BUGZY_CONNECT code">
    In the Bugzy dashboard, go to **Dashboard > Projects > \[Your Project] > Connections** and click **Connect Teams**. Copy the generated code.
  </Step>

  <Step title="Link the channel">
    In the Teams channel you want to connect, mention the Bugzy bot and paste your `BUGZY_CONNECT` code. The bot will confirm the link.
  </Step>
</Steps>

<Note>
  Each Teams channel links to exactly one Bugzy project. To connect multiple projects, use different channels.
</Note>

## Admin setup

The Azure Bot registration is a one-time platform-level setup performed by an organization admin:

1. Register an application in Microsoft Entra (Azure AD)
2. Create a client secret for the application
3. Create an Azure Bot resource linked to the application
4. Enable the Microsoft Teams channel on the bot
5. Set the messaging endpoint to the Bugzy webhook URL
6. Install the bot in your Teams tenant

<Info>
  End users do not need admin access. After the initial bot setup, connecting projects is as simple as generating and pasting a `BUGZY_CONNECT` code.
</Info>

## Troubleshooting

**Bot not responding** — Verify the bot has been added to the team and channel. Check with your Teams admin that the Azure Bot is configured correctly.

**Channel not linked** — Re-run the `BUGZY_CONNECT` flow from the project connections page. Ensure the code was sent in the correct channel.

**Messages not reaching Bugzy** — Confirm the channel-to-project link is active in the dashboard. Check that the bot has not been removed from the team.
