Microsoft Teams Bot icon

Microsoft Teams Bot

Use Bot Framework conversation and activity APIs for Microsoft Teams bots

Activity → Reply To Activity

AI-generated

Summary

Send a reply activity to an existing Microsoft Teams conversation activity by posting a message in response to a specified activity ID within a conversation.

Inputs

  • Service URL (required) — The Bot Framework service URL, usually retrieved from the trigger output, specifying the endpoint for Microsoft Teams API requests.
  • Conversation ID (required) — Identifier of the conversation where the reply will be sent, typically obtained from trigger output.
  • Activity ID (required) — The ID of the activity to which the reply is sent.
  • Activity Type — Type of the activity, such as message, typing, event, or end of conversation; defaults to 'message'.
  • Message Text — The textual content of the reply message for message-type activities.
  • Activity JSON — Raw JSON to define the activity payload fully; when set, it overrides other helper fields like message text and activity type.
  • Mention Options — Options for automatically mentioning users in the reply, including auto-mentioning the sender, specifying mention ID, name, and whether to prepend mention text.
  • Activity Additional Fields — Optional extra JSON fields to include in the activity such as attachments, channel data, entities, suggested actions, and text format.
  • Execution Options — Settings controlling retries, debug output, and shaping of node output data after successful execution.

Output shape

a single JSON object containing metadata about the HTTP request made and the Bot Framework response; optionally includes debug info; output may merge or replace input JSON based on execution options

The reply is delivered via an HTTP POST request to the Bot Framework API at the URL formed by combining the service URL, conversation ID, and activity ID. Retry logic is applied as configured. The node returns details about the request and response, with configurable output shaping (pass through, merge, or response only). When Activity JSON is provided, it fully defines the activity payload, overriding other fields.

Examples

Example 1: Reply to a message activity with simple text

Provide Service URL, Conversation ID, Activity ID, set Activity Type to 'message', and enter Message Text to send a text reply to the specified activity.

Example 2: Reply including mention of the original sender

Enable Auto Mention Sender in Mention Options to automatically mention the sender of the original activity, optionally prepending the mention text before the message content.

Example 3: Reply with a custom activity payload

Populate Activity JSON with fully customized activity content to override helper fields and send a complex or non-message type reply.

Links

Discussion