Skip to main content
Microsoft Teams logo

Overview

Add Microsoft Teams to any ModuleX agent or workflow. Create channels, send channel and chat messages, list teams / channels / chats / messages / shifts, search messages, and retrieve the current user via the Microsoft Graph REST API (graph.microsoft.com/v1.0).
Categories: Communication · Productivity & Collaboration · Auth: OAuth2 · Actions: 12

Authentication

OAuth2 Authentication

Connect with your Microsoft work or school account using OAuth 2.0. Personal accounts are not supported by Microsoft Teams APIs.
1

Step 1

Go to https://entra.microsoft.com (Microsoft Entra admin center) and open ‘App registrations’
2

Step 2

Create a new registration (single-tenant or multi-tenant, as required by your deployment)
3

Step 3

Under Authentication, add the redirect URI: https://api.modulex.dev/credentials/oauth2/callback (type: Web)
4

Step 4

Under API permissions, add Microsoft Graph delegated permissions: User.Read, Team.ReadBasic.All, Channel.ReadBasic.All, ChannelMessage.Read.All, ChannelMessage.Send, Chat.ReadWrite, ChatMessage.Send, Schedule.Read.All, Mail.Read, and offline_access
5

Step 5

Grant admin consent for the tenant if your organization requires it
6

Step 6

Under Certificates & secrets, create a Client Secret and copy its Value
7

Step 7

Copy the Application (client) ID and the Client Secret Value into ModuleX

Required Credentials

OAuth Configuration

  • Authorization URL: https://login.microsoftonline.com/common/oauth2/v2.0/authorize
  • Token URL: https://login.microsoftonline.com/common/oauth2/v2.0/token
  • Scopes: offline_access, User.Read, Team.ReadBasic.All, Channel.ReadBasic.All, ChannelMessage.Read.All, ChannelMessage.Send, Chat.ReadWrite, ChatMessage.Send, Schedule.Read.All, Mail.Read

Available Actions

Parameters

string
required
ID of the Microsoft Team. Obtain it via list_teams.
string
required
Display name of the channel.
string
Description of the channel.

Response

Parameters

string
required
ID of the chat. Obtain it via list_chats.
string
required
ID of the message to retrieve. Obtain it via list_messages_in_chat.

Response

Response

Parameters

string
required
ID of the Microsoft Team.
string
required
ID of the channel within the team.
integer
The maximum number of messages to return. Omit to fetch all available pages.

Response

Parameters

string
required
ID of the Microsoft Team.

Response

Response

Parameters

string
required
ID of the chat.
integer
The maximum number of results to return. Omit to fetch all available pages.

Response

Parameters

string
required
ID of the Microsoft Team whose schedule is being queried.

Response

Response

Parameters

string
required
The type of entity to search for. Valid values: message for email, chatMessage for Teams chat messages.
string
required
The query string to search for.
integer
The index of the first result to return. (Default: 0)
integer
The number of results to return (max 25). (Default: 25)

Response

Parameters

string
required
ID of the Microsoft Team.
string
required
ID of the channel within the team.
string
required
Message to be sent.
string
Whether the message body is plain text or HTML. Valid values: text, html. (Default: text)
array
An array of JSON strings, each representing an inline hosted image. Each item must be a JSON object with @microsoft.graph.temporaryId (string), contentBytes (base64-encoded image data), and contentType (MIME type, e.g. image/png). Reference each image in HTML message bodies using <img src="../hostedContents/1/$value">.

Response

Parameters

string
required
ID of the chat to post the message to.
string
required
Message to be sent.
string
Whether the message body is plain text or HTML. Valid values: text, html. (Default: text)

Response

Limits & Quotas

  • Microsoft Graph applies per-app, per-tenant, and per-resource throttling. Teams messaging endpoints have specific RU-based limits documented at https://learn.microsoft.com/en-us/graph/throttling. Retry on HTTP 429 honoring the Retry-After header.
  • search_messages returns at most 25 results per call (upper bound enforced by the Microsoft Graph search API for this entity-type set). Use the from_ parameter to page beyond the first window.
  • Dynamic team / channel / chat / message pickers are not available — pass IDs directly; use the corresponding list_* action to enumerate IDs.
  • Webhook / change-notification subscriptions are not part of this integration; polling via the list_* actions is the supported pattern.
  • Error model: non-2xx responses and timeouts are caught and returned as success=False plus an error string rather than raising. Plan for retries on the agent side based on the error text.

Google Meet

Zoom

AgentMail