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

# MS Teams

> TextQL Microsoft Teams Integration

TextQL's integration for Microsoft Teams allows you to seamlessly interact with Ana directly within your Teams workspace.
Below you'll find instructions on how to add Ana to your Teams, use its features, and understand its capabilities.

## Organization Defaults

<Info>
  **Important for System Administrators**: Ana in Teams uses your organization's default settings for data connectors and available tools. Only system administrators can view and modify these defaults in the Configuration settings. All Teams users will have access to the same default connector and tool set configured by your organization administrators.
</Info>

## Add Ana to Your Teams

1. **Download the Teams app package**: From TextQL, navigate to **Connectors > Teams** and click **Download Teams app (.zip)** to save the app package.

<Tabs>
  <Tab title="Step 1: Navigate to Teams">
    <Frame caption="Navigate to Connectors > Teams in TextQL">
      <img src="https://mintcdn.com/textql/XqTcF1iTGZELKT6P/images/connectors/Teams%20setup0.png?fit=max&auto=format&n=XqTcF1iTGZELKT6P&q=85&s=bb41b2eb79b78fc5b4a9bfbf11195be0" alt="TextQL Connectors Teams page" width="3024" height="1716" data-path="images/connectors/Teams setup0.png" />
    </Frame>
  </Tab>

  <Tab title="Step 2: Download App">
    <Frame caption="Click Download Teams app (.zip) to save the app package">
      <img src="https://mintcdn.com/textql/XqTcF1iTGZELKT6P/images/connectors/Teams%20app%20download.png?fit=max&auto=format&n=XqTcF1iTGZELKT6P&q=85&s=1e48490b4bcce54ddf536e500c9d0dc8" alt="Download Teams app button" width="380" height="194" data-path="images/connectors/Teams app download.png" />
    </Frame>
  </Tab>
</Tabs>

<Note>
  The download is only available on TextQL hosted deployments. For on-prem or VPC deployments, contact [support@textql.com](mailto:support@textql.com) for a custom build.
</Note>

2. **Upload to Teams Admin Center**: Your Microsoft 365 tenant admin should sign in to the [Microsoft Teams Admin Center](https://admin.teams.microsoft.com/), navigate to **Teams apps > Manage apps**, click **Upload new app**, and select the `textql-teams-app.zip`. Make sure the app is **Allowed** for your organization.

<Tabs>
  <Tab title="Step 1: Manage Apps">
    <Frame caption="In Teams Admin Center, navigate to Teams apps > Manage apps">
      <img src="https://mintcdn.com/textql/XqTcF1iTGZELKT6P/images/connectors/Teams%20setup1.png?fit=max&auto=format&n=XqTcF1iTGZELKT6P&q=85&s=78237025917093b2411d4e29628ac709" alt="Teams Admin Center - Manage Apps" width="3024" height="1716" data-path="images/connectors/Teams setup1.png" />
    </Frame>
  </Tab>

  <Tab title="Step 2: Upload New App">
    <Frame caption="Click Upload new app and select the textql-teams-app.zip">
      <img src="https://mintcdn.com/textql/XqTcF1iTGZELKT6P/images/connectors/Teams%20setup2.png?fit=max&auto=format&n=XqTcF1iTGZELKT6P&q=85&s=cf2db2ac9e81a157d940563a1f19de7d" alt="Teams Admin Center - Upload New App" width="3024" height="1714" data-path="images/connectors/Teams setup2.png" />
    </Frame>
  </Tab>

  <Tab title="Step 3: Allow the App">
    <Frame caption="Confirm the app is set to Allowed for your organization">
      <img src="https://mintcdn.com/textql/XqTcF1iTGZELKT6P/images/connectors/Teams%20setup3.png?fit=max&auto=format&n=XqTcF1iTGZELKT6P&q=85&s=d7c4b98739459bc8d53e56eef2c929c5" alt="Teams Admin Center - Allow App" width="3024" height="1718" data-path="images/connectors/Teams setup3.png" />
    </Frame>
  </Tab>
</Tabs>

3. **Grant admin consent**: Open the [Microsoft Entra Admin Center](https://entra.microsoft.com/), find **Ana by TextQL** under **Enterprise applications**, open the **Permissions** tab, and click **Grant admin consent for \[your tenant]**.

   The permissions Ana requests are:

   | Permission                  | Purpose                                                                                                                                |
   | --------------------------- | -------------------------------------------------------------------------------------------------------------------------------------- |
   | `User.ReadBasic.All`        | Resolve `@`-mentions to names and emails.                                                                                              |
   | `Team.ReadBasic.All`        | List the teams Ana is installed in.                                                                                                    |
   | `Channel.ReadBasic.All`     | List channels for the Channel Context picker.                                                                                          |
   | `TeamMember.Read.All`       | Resolve channel members when delivering reports and DMs.                                                                               |
   | `Files.Read.All`            | Download files (CSV, Excel, PDF, etc.) that users attach in chats and channels.                                                        |
   | `ChannelMessage.Read.Group` | Read prior messages in a thread when a user replies and `@`-mentions Ana, so Ana has thread context. Granted per-team at install time. |

4. **Connect Ana to TextQL**: Back in TextQL on **Connectors > Teams**, click **Connect to Teams** to complete the OAuth flow that links the installed Teams bot to your TextQL organization.

<Frame caption="Complete the OAuth flow to link Ana to your TextQL organization">
  <img src="https://mintcdn.com/textql/XqTcF1iTGZELKT6P/images/connectors/Ana%20in%20teams%204.png?fit=max&auto=format&n=XqTcF1iTGZELKT6P&q=85&s=4f46b167e2671cd854712d0f085b78b5" alt="Connect Ana to TextQL via OAuth" width="3016" height="1624" data-path="images/connectors/Ana in teams 4.png" />
</Frame>

5. **Install Ana into teams**: Users can install Ana from the Teams app catalog (search "Ana"), or your admin can deploy it org-wide or to specific groups from Teams Admin Center.

## Features

Ana offers the following capabilities within Teams:

* **Answer Questions**: Pose questions to Ana and receive detailed answers based on your organization's data.

* **Send Back Datasets and Figures**: Receive datasets and visualizations directly in your Teams conversations.

* **Read User-Uploaded Files**: Attach files (CSV, Excel, PDF, images) via the paperclip in a 1:1 chat with Ana, or in a channel where Ana is installed.

## Using Ana in Teams

Once Ana has been added to your Teams tenant, you can start chats with her in the following ways:

* **In a Channel**: Use `@Ana` in your message to start a new chat with Ana.
  To send follow-up messages to Ana and continue her analysis, simply reply to her in the same thread.

<Frame caption="@mention Ana in a channel and reply in thread to continue the analysis">
  <img src="https://mintcdn.com/textql/XqTcF1iTGZELKT6P/images/connectors/ana%20in%20teams%20threads.png?fit=max&auto=format&n=XqTcF1iTGZELKT6P&q=85&s=c005b58144a2d1ed29b6a672337dbb50" alt="Ana in Teams channel thread" width="3024" height="1782" data-path="images/connectors/ana in teams threads.png" />
</Frame>

* **With a Direct Message**: Open the Ana app from the Teams sidebar (or search "Ana" in chat) and message her directly to start a new chat and receive responses privately.
  To send follow-up messages to Ana and continue her analysis, simply reply in the direct message.

<Frame caption="Message Ana directly in Teams via DM">
  <img src="https://mintcdn.com/textql/XqTcF1iTGZELKT6P/images/connectors/Ana%20in%20teams%20dm.png?fit=max&auto=format&n=XqTcF1iTGZELKT6P&q=85&s=904cee11b62f9c072db5ea500b2a94ac" alt="Ana in Teams direct message" width="3024" height="1688" data-path="images/connectors/Ana in teams dm.png" />
</Frame>

* **Scheduled Playbook Reports**: Playbooks can be configured to deliver reports directly to a Teams channel on a schedule. Ana posts the results as a message in the channel at the configured interval — no manual prompting required. From there, anyone in the channel can reply in the thread to ask follow-up questions and continue the analysis without starting a new conversation.

<Tabs>
  <Tab title="Step 1: Configure Delivery">
    <Frame caption="Set a Teams channel as the delivery destination in the playbook editor">
      <img src="https://mintcdn.com/textql/XqTcF1iTGZELKT6P/images/connectors/Playbook%20-%20teams.png?fit=max&auto=format&n=XqTcF1iTGZELKT6P&q=85&s=37d66fd38cb382bd363587b5a54e982c" alt="Playbook Teams delivery configuration" width="3024" height="1712" data-path="images/connectors/Playbook - teams.png" />
    </Frame>
  </Tab>

  <Tab title="Step 2: Deliver Report to Teams Channel">
    <Frame caption="Ana delivers the report to the channel and team members can reply in thread to continue the analysis">
      <img src="https://mintcdn.com/textql/XqTcF1iTGZELKT6P/images/connectors/Ana%20in%20teams%202.png?fit=max&auto=format&n=XqTcF1iTGZELKT6P&q=85&s=3893bc2b5f0744eb83ed731fd64b305c" alt="Ana delivering a playbook report in Teams" width="3016" height="1710" data-path="images/connectors/Ana in teams 2.png" />
    </Frame>
  </Tab>

  <Tab title="Step 3: View Report in Channel">
    <Frame caption="Ana delivering a scheduled playbook report to a Teams channel">
      <img src="https://mintcdn.com/textql/XqTcF1iTGZELKT6P/images/connectors/ana%20in%20teams%20playbooks%20sent.png?fit=max&auto=format&n=XqTcF1iTGZELKT6P&q=85&s=ed1d760f9742346d906cbffcbdd51399" alt="Ana playbook report delivered to Teams channel" width="2898" height="1720" data-path="images/connectors/ana in teams playbooks sent.png" />
    </Frame>
  </Tab>
</Tabs>

## Teams Channel Context

In addition to answering questions, Ana can also use channel-specific context.
Channel context ensures that whenever Ana is mentioned in a specific Teams channel, she has the right background information to guide her responses.

Channel context is managed through Playbooks:

1. **Create a New Playbook:** Navigate to the Playbooks section in the TextQL platform and click **Create Playbook**.

2. **Write the Channel Context:**
   Use the provided prompt box to write instructions for Ana specific to this channel — the tone she should use, the audience she's speaking to, background knowledge she should assume, and any definitions she needs (metrics, KPIs, business terms). This is how you tailor Ana's behavior so her responses are relevant to the people in that channel.

3. **Select a Teams Channel:**
   Click the **Delivery** button in the top right corner of the playbook editor, then use the channel selector to choose the Teams channel you want to associate with this playbook. Click **Set as Channel Context**, and then hit Save.

<Tabs>
  <Tab title="Step 1: Open Delivery">
    <Frame caption="Click Delivery in the top right corner to open the channel selector">
      <img src="https://mintcdn.com/textql/XqTcF1iTGZELKT6P/images/connectors/Ana%20in%20teams%204.png?fit=max&auto=format&n=XqTcF1iTGZELKT6P&q=85&s=4f46b167e2671cd854712d0f085b78b5" alt="Playbook delivery button - Teams channel selector" width="3016" height="1624" data-path="images/connectors/Ana in teams 4.png" />
    </Frame>
  </Tab>

  <Tab title="Step 2: Set Channel Context">
    <Frame caption="Select the Teams channel and click Set as Channel Context">
      <img src="https://mintcdn.com/textql/XqTcF1iTGZELKT6P/images/connectors/Ana%20in%20teams%201.png?fit=max&auto=format&n=XqTcF1iTGZELKT6P&q=85&s=4f349890514b9202027733cc9960a5ba" alt="Set as Channel Context in playbook editor" width="3016" height="1626" data-path="images/connectors/Ana in teams 1.png" />
    </Frame>
  </Tab>
</Tabs>

4. **Keep the Playbook deactivated:**
   The playbook must remain **deactivated** to function as channel context.

<Note>
  Any datasets and dashboards attached to the playbook are automatically included in the Teams conversation when channel context is applied. If an attachment fails, Ana will post a warning in the thread so you know to investigate.
</Note>

This feature allows you to maintain different contexts across different Teams channels—for example, one channel may hold context about sales performance, while another focuses on product metrics.

## Need Help?

For further assistance or to request early access, please contact [support@textql.com](mailto:support@textql.com).

## Privacy Policy

For information about how we handle your data and protect your privacy when using TextQL's integration for Microsoft Teams, please review our [Privacy Policy](https://textql.com/privacy).
