> For the complete documentation index, see [llms.txt](https://docs.eesel.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.eesel.ai/integrations/communication/microsoft-teams.md).

# Microsoft Teams

Set up an AI agent in Microsoft Teams. It answers mentions and direct messages, follows its threads, and reads and searches your channels when asked.

eesel's AI agent for Microsoft Teams answers your team when they mention it in a channel or send it a direct message, reading the thread first and answering from your connected knowledge.

<figure><img src="https://3732419023-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2xXO0947TYoPIhGoBgSE%2Fuploads%2Fgit-blob-e8ec286db0b5cd21a9566014d075b2bb90ae9431%2Fmicrosoft-teams-hero.png?alt=media" alt="A Microsoft Teams channel where a teammate @mentions eesel about the refund window on annual subscriptions, and eesel answers in the channel citing the refund policy"><figcaption><p>Your agent answers in the Teams channel your team already uses, from the knowledge you have connected.</p></figcaption></figure>

## What your agent sees

* **The message, and the conversation around it.** In a channel thread it reads the first post and the newest 100 replies, including messages that did not mention it. In a group chat it reads the last 30 messages from the past week. Very long messages and threads are shortened, and the oldest replies go first.
* **In a direct message, only what reached it.** Teams does not let an app read one-to-one chats, so your agent sees the last 20 messages from the past week that were sent to it, and its own replies.
* **Images in the message that asks.** Up to five images pasted into that message. Files, PDFs and images from earlier messages are not opened.
* **Who is asking.** Their name and Teams email address, matched to your eesel workspace. People in your Microsoft 365 organization count as your team. Guests from other organizations are treated as people outside it.
* **A note when it can't read Teams.** If the permission to read messages was not approved, or Teams is slow, your agent is told it couldn't read the conversation. When someone refers to a message it can't see, it says so instead of guessing.

### Sources

Your agent reads Teams live as it answers, and nothing from Teams is copied into its knowledge. When someone asks, it can also read a channel's recent posts and search recent messages. Outside the conversation it was asked in, it only reads and searches channels the eesel app has been added to, in teams the person asking is a member of. It includes private and shared channels only if the person asking is also in your eesel workspace. If your agent cannot identify the person asking, it does not search, and it only reads the conversation it was asked in.

Your agent also answers from your other connected sources, such as [Confluence](https://docs.eesel.ai/integrations/knowledge/confluence.md), [Notion](https://docs.eesel.ai/integrations/knowledge/notion.md), [Google Drive](https://docs.eesel.ai/integrations/knowledge/google-drive.md) and your help center. See [Integrations](https://docs.eesel.ai/integrations/overview.md).

## What it can do

### Triggers

| Trigger     | Runs when                                                                                                                                 | Best for                       | Key                               |
| ----------- | ----------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------ | --------------------------------- |
| **Mention** | Someone mentions your agent in a channel or group chat, sends it a direct message, or replies in a channel thread your agent is following | Answering questions on request | `microsoft_teams_eesel_mentioned` |

When someone mentions your agent in a channel, it posts "On it" straight away, and then edits that message into its answer.

After someone mentions your agent in a channel thread, or after your agent posts there, people can keep replying without a mention for up to 14 days of quiet. Your agent replies when a message is meant for it, and stays silent when people are talking among themselves. In a group chat, every message needs a mention. New channel posts that do not mention your agent do not run the automation.

### Actions

| Action            | What it does                                                                                                                                                                      |
| ----------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Send message      | Replies in a conversation, starts a new post in a channel, or messages a person directly. It can message people in the teams the eesel app is in, or who added the app themselves |
| Look up person    | Finds someone by name or email among the members of the teams the eesel app is in                                                                                                 |
| List channels     | Lists the channels of the teams the eesel app is in                                                                                                                               |
| Read conversation | Reads a channel thread or group chat, including messages that did not mention your agent                                                                                          |
| Read channel      | Reads a channel's recent posts and their replies, from the last 30 days by default and up to 90                                                                                   |
| Search messages   | Looks through recent messages in up to 20 channels the person asking is a member of, and returns the newest 25 matches                                                            |

You can choose which knowledge your agent can use and which actions need approval. See [Actions and Approvals](https://docs.eesel.ai/instructions-and-memory/actions-and-approvals.md).

## Set up eesel in Microsoft Teams

eesel is not listed in the Microsoft Teams store yet, so a Teams admin uploads the app for your organization.

{% stepper %}
{% step %}

### Download the Teams package

In eesel, open **Integrations > Microsoft Teams** on your agent and download the eesel package.
{% endstep %}

{% step %}

### Upload the package in the Teams admin center

A Teams admin uploads the package in the Teams admin center, under **Teams apps > Manage apps > Upload new app**. Microsoft does not need to approve the upload. The app appears for your organization within a few hours.
{% endstep %}

{% step %}

### Add eesel in Teams

In Teams, go to **Apps**, search for eesel and click **Add**. eesel then sends the person who added it a message with a link to choose which agent answers.

While you add the app, Teams asks whether eesel can read messages in the teams and chats it is added to. Approve this permission. It lets your agent follow a thread without a mention, read a thread before it answers, and read and search channels. Without it, your agent only answers when someone mentions it or sends it a direct message.

The person who chooses the agent from the link needs edit access to your eesel workspace. The link works once and expires after 30 minutes. eesel recognizes people by their Teams email address, so invite your teammates to your eesel workspace with the email address they use in Teams.
{% endstep %}

{% step %}

### Add the app to your teams and channels

Add the eesel app to the teams and channels where your team asks questions. A person must add it, because the app cannot join a team on its own. You can do this before or after you choose the agent.
{% endstep %}
{% endstepper %}

## Approve actions from Teams

When an action needs approval, your agent posts an approval card in the Teams thread or chat where it was asked. You can approve or deny the action from the card, or open it for review in eesel. Only editors of your eesel workspace can decide from the card, and eesel matches them by their Teams email address. Anyone else receives a message that only they can see. After someone decides, in Teams or in the eesel dashboard, the card shows who decided and what happened, and its buttons are removed.

## Who can do what from Teams

Editors of your eesel workspace can change your agent's setup by asking it in Teams, the same way they do in the dashboard. This includes its instructions, automations and integrations. Viewers can ask questions, but your agent refuses their setup changes. People in your Microsoft 365 organization without an eesel account count as your team, so they get answers meant for your team but can't change settings. Your agent tells anyone else who to ask for an invitation.

## Several agents in one organization

You can connect more than one agent to your company's Teams (its Microsoft 365 organization). When you connect Teams on a second agent, eesel adds it alongside the first.

* **You can limit an agent to some channels.** Each agent's mention automation has a channels setting. Leave it empty to answer in every channel. An agent that is limited to channels does not answer direct messages or group chats. You can also ask your agent in the dashboard chat to limit itself to channels.
* **eesel chooses an agent when a mention could go to more than one.** It picks the agent that fits the question. If it cannot tell, it asks which agent to use, and the person who asked replies with the agent's name.
* **You can name an agent yourself.** Write `agent="Name"` in your message. The name only reaches an agent that answers in that channel.
* **A thread keeps the agent that answered it first.** A mention with `agent="Name"` gets that agent for one answer, and later replies go back to the first agent. The thread moves only when someone answers eesel's "which agent?" question.

## Things to know

* **eesel is not in the Microsoft Teams store yet.** A Teams admin must upload the app, and it can take a few hours before eesel appears in Teams.
* **Your agent only works where it has been added.** A person adds the app to a team, and a channel owner adds it to a private or shared channel.
* **Reading messages needs approval.** If nobody approved the permission to read messages when adding eesel, your agent answers mentions and direct messages only, and only knows the messages that reached it directly.
* **"help", "hi" and "hello" get a help card.** A message that is only one of those words gets eesel's help card instead of an answer from your agent.
* **It can't react, edit, delete or send files.** Its only edit is turning its own "On it" message into the answer.
* **Search is a quick scan, not a full search.** It covers up to 20 channels and the newest 25 matches, from the last 30 days by default.
* **Your agent cannot search your whole organization's directory.** Looking someone up covers the members of the teams the eesel app is in.
* **A Microsoft 365 organization connects to one eesel workspace.** If you connect it from a second eesel workspace, it moves to that workspace, and the first workspace's Teams connection is removed.

## Troubleshooting

<details>

<summary>eesel shows as connected, but your agent does not reply</summary>

If eesel replies "no eesel agent is set to answer here", your organization is connected, but no agent answers in that chat or channel. In eesel, open the Microsoft Teams integration on the agent you want and add Teams to it, or add the channel to the agent's channels setting. If eesel does not reply at all, check that the app was added to that team or chat.

</details>

<details>

<summary>Your agent cannot read a private channel</summary>

The eesel app must be added to each private or shared channel separately. A channel owner adds it from the channel's app settings.

</details>

## FAQ

<details>

<summary>How do I add an AI agent to Microsoft Teams?</summary>

Download the eesel package from the Microsoft Teams integration in eesel, and ask a Teams admin to upload it in the Teams admin center. Then add eesel from the apps list in Teams, and choose your agent from the link eesel sends you. See [Set up eesel in Microsoft Teams](#set-up-eesel-in-microsoft-teams).

</details>

<details>

<summary>Is the Microsoft Teams AI agent available to everyone?</summary>

Yes, apart from HIPAA workspaces, where Teams is not offered. Until eesel is in the Microsoft Teams store, a Teams admin uploads the app for your organization.

</details>

<details>

<summary>Can the Microsoft Teams AI agent auto reply to messages?</summary>

Yes. Your agent replies when someone mentions it or sends it a direct message. It keeps replying in a channel thread it is part of without another mention, and stays silent when people are talking among themselves. It does not reply to new channel posts that do not mention it, and a group chat always needs a mention.

</details>

<details>

<summary>Does the Microsoft Teams AI agent read our channel history?</summary>

Yes, when someone asks, and only in the teams and chats the eesel app has been added to. Your agent reads a thread or group chat before it answers, and it can read a channel's recent posts or search recent messages. Outside the conversation it was asked in, it only reads and searches channels the person asking is a member of. It includes private or shared channels only if that person is also in your eesel workspace. eesel does not copy your Teams messages into your agent's knowledge.

</details>

<details>

<summary>Can I connect Microsoft Teams to ChatGPT or Claude?</summary>

Yes, through eesel. You can talk to the same eesel agent from ChatGPT, Claude or Cursor. See [Use eesel from ChatGPT](https://docs.eesel.ai/apis-and-developer-resources/use-eesel-from-chatgpt.md), [Use eesel from Claude and other assistants](https://docs.eesel.ai/apis-and-developer-resources/use-eesel-from-claude-and-other-assistants.md) and [Claude Code and MCP clients](https://docs.eesel.ai/apis-and-developer-resources/claude-code-and-mcp-clients.md).

</details>

<details>

<summary>How long does Microsoft Teams setup take?</summary>

Most of the time is spent waiting for Microsoft. After a Teams admin uploads the eesel package, it can take a few hours before the app appears for your organization. Adding the app in Teams and choosing your agent then takes a few clicks.

</details>

## Related pages

* [Slack](https://docs.eesel.ai/integrations/communication/slack.md) for the same workflow in Slack
* [Internal operations](https://docs.eesel.ai/use-cases/internal-operations.md) for the job your agent does for your team
* [Actions and Approvals](https://docs.eesel.ai/instructions-and-memory/actions-and-approvals.md) for choosing what your agent can do
* [Integrations overview](https://docs.eesel.ai/integrations/overview.md) for how sources, triggers and actions work together


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

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

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.eesel.ai/integrations/communication/microsoft-teams.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
