TABLE OF CONTENTS
Overview
The Microsoft Teams connector brings selected channel conversations into the Stack Internal knowledge base. Once connected, Stack Internal periodically reads eligible Teams content so people can find and use that knowledge through Stack Internal search, chat, and APIs.
The connector is read-only. It cannot send messages, create posts, or change anything in Microsoft Teams.
What the source ingests
The current integration can ingest:
- Messages from the public teams and channels including standard, private and shared channels that an administrator explicitly selects.
- Replies in channel threads.
- Message and reply details needed for search and citations, including timestamps, team and channel information, source links, author information including name, user principal name, and email address..
- New messages, edits, and new replies discovered during later synchronization runs.
- Read team and channel membership information needed to respect source permissions
The current integration does not ingest:
- Private teams.
- One-to-one chats, group chats, or meeting chats.
- Teams or channels that were not added to the connector configuration.
- File attachments.
Deleting a message in Teams does not currently guarantee that previously ingested content is removed from Stack Internal. Private-content permission synchronization and source-level access-control lists are also still under development. For that reason, select only public teams and standard channels whose content is appropriate for everyone authorized to use the relevant Stack Internal workspace.
On its first run, the connector will ingest the last 12 months of data. Later runs synchronize changes after the last successful checkpoint.
Before you begin
Stack Internal permission
The person configuring the connector must be a workspace administrator, or have the Stack Internal permission to manage ingestion sources (ingestion:manage).
Microsoft Graph permissions
An Entra administrator must grant tenant-wide admin consent for:
| Permission | Why it is needed |
|---|---|
| Team.ReadBasic.All | Read team names and basic team information. |
| Channel.ReadBasic.All | Read channel names, descriptions, and channel type. |
| ChannelMessage.Read.All | Read channel messages and replies. |
| User.Read.All | Resolve message authors and profile details used in citations and indexing. |
| Files.Read.All | Optional; needed only when attachment ingestion is enabled in a future deployment. |
| TeamMember.Read.All | Respecting source permissions |
| ChannelMember.ReadAll | Respecting source permissions |
These application permissions allow the Entra application to read data across the Microsoft 365 tenant.
The connector does not request Microsoft Graph write permissions. It does not require a Teams app package and does not sign in as an individual Microsoft user.
The client secret is stored through Stack Internal's protected secret-storage path and is never returned in plaintext. Treat the original secret as a credential, store it in an approved password manager, rotate it before expiry, and never send it through email or chat.
Configure the Microsoft Teams connector
Confirm prerequisites
Before starting, confirm that:
- You can manage ingestion sources in Stack Internal.
- You can register an application in the Microsoft Entra tenant that owns the Teams content.
- An Entra administrator is available to grant admin consent.
Microsoft Graph permissions
The Microsoft Teams source can only be connected with a paid Microsoft Entra plan.
Register the Microsoft Entra application
The application must be registered in the same Entra tenant as the Microsoft Teams data.
- Sign in to the Microsoft Entra admin center and select the directory that owns the Teams content.
- Go to Entra ID > App registrations > New registration.
- Give the application a recognizable name, such as Stack Internal Microsoft Teams Connector.
- Select Accounts in this organizational directory only.
- Leave Redirect URI empty and complete the registration.
- Copy the Directory (tenant) ID and Application (client) ID from the application overview.
Grant Microsoft Graph access
- Open the new app registration and select API permissions.
- Remove the default delegated User.Read permission if Microsoft added it.
- Select Add a permission > Microsoft Graph > Application permissions.
- Add Team.ReadBasic.All, Channel.ReadBasic.All, ChannelMessage.Read.All, User.Read.All, TeamMember.ReadAll and ChannelMember.ReadAll.
- Do not add Files.Read.All for the current deployed preview; attachments are not enabled.
- Select Grant admin consent, confirm the action, and verify that every required permission shows as granted.
Adding permissions and granting admin consent are separate steps. The connection will fail if consent is missing.
Create a client secret
- In the app registration, open Certificates & secrets > Client secrets.
- Create a secret with the shortest practical lifetime.
- Copy the secret Value immediately. Do not copy the Secret ID.
- Store the value in an approved password manager until setup is complete.
Collect team and channel IDs
The current setup screen requires IDs and does not yet discover teams and channels for you. Obtain the IDs for each public team and standard channel you want Stack Internal to ingest.
Include only teams whose visibility is public and channels whose membership type is standard, private or shared.
Connect in Stack Internal
- In Stack Internal, open Control Center > Sources.
- Find Microsoft Teams and select Connect.
- Enter the Entra tenant ID, client ID, and client-secret value.
- Enter one Team ID per line.
- Enter one Channel ID per line.
- Select Connect.
The current preview does not have a Test connection action. If credentials, consent, permissions, or selected resources are invalid, the problem may first appear when ingestion runs.
Content sync
After you configure the Microsoft Teams source, Stack Internal keeps the designated channels synchronized and up to date. This means the source connector watches for, and ingests, new content regularly.
To check the status of the Microsoft source (and others) in Stack Internal, click Control Center then Sources. There you can see each source's connection status and last sync (when Stack Internal last checked for new content).
Usage guide
Find Teams knowledge
After the first successful synchronization, use Stack Internal search or chat as usual. Teams messages and replies are indexed as separate items while preserving their thread relationship and source URL. When a result comes from Teams, use its citation or source link to open the original conversation, subject to Microsoft Teams availability and your Microsoft access.
Add or remove content sources
- Go to Control Center > Sources > Microsoft Teams > Manage.
- Add or remove Team IDs and Channel IDs.
- Leave the client-secret field blank to keep the stored secret.
- Select Save.
Changing the allowlist controls future synchronization. Removing a team or channel does not currently delete content that was ingested earlier.
Rotate an expired or replaced secret
- Create a new client secret in Microsoft Entra.
- Open the Microsoft Teams source management page in Stack Internal.
- Enter the new secret and save the configuration.
- Delete the old secret in Microsoft Entra after the new configuration has been confirmed working.
Disconnect and reconnect
Select Disconnect on the Microsoft Teams management page to stop future ingestion runs.
Disconnecting preserves the non-secret configuration and previously ingested content. Select Re-connect to resume using the saved configuration; enter a new secret only if the existing one has expired or been revoked.
NOTE: Disconnecting the Microsoft Teams source or removing specific MS Teams channels will not remove previously ingested Slack content. If you need previously ingested content removed, contact support.
Troubleshooting
| Symptom | What to check |
|---|---|
| Authentication fails | Confirm the tenant ID, client ID, and client-secret Value are correct and that the secret has not expired. |
| Microsoft Graph returns 403 | Confirm all required permissions are application permissions and that admin consent was granted. |
| A selected channel produces no content | Confirm its parent team is public, the channel is standard, private or shared and both IDs are present in the allowlists. |
| No Teams source appears in Control Center | Ask your Stack Overflow representative whether the limited-preview feature is enabled for your workspace. |
| Recent content has not appeared | Confirm the connector is still connected and ask your representative to verify the preview schedule and latest ingestion run. |
| A deleted Teams message remains searchable | Deletion propagation is not yet supported; contact Stack Overflow Support if the content must be removed. |