Skip to content
This repository was archived by the owner on Jan 5, 2026. It is now read-only.
This repository was archived by the owner on Jan 5, 2026. It is now read-only.

In Microsoft Teams, <Conversation>.ReplyToActivity does not send a reply, it creates a new message to the conversation #6626

@tomorgan

Description

@tomorgan

Github issues should be used for bugs and feature requests. Use Stack Overflow for general "how-to" questions.

Version

Microsoft.Bot.Builder 4.21.2 .NET SDK

Describe the bug

The ConnectorClient.Conversations object has a method, SendToConversation(Async), which is used to send new message threads into a conversation. (a conversation in this instance could be 1:1 conversation with a user, or a channel chat). The method accepts an activity object and a conversation ID, and returns an Activity ID of the newly created activity.
There is also a ReplyToActivityAsync method, which takes a single parameter, an Activity object. However, even when a message has a valid ReplyToID value, the reply is sent to Microsoft Teams as a new message, not a threaded reply.
There is also a ConversationExtension method ReplyToActivityAsync, which exhibits the same behaviour.

To Reproduce

  1. Create a new activity, using a ReplyToId of an existing activity that has previously been sent to Microsoft Teams, using the existing activity ID and conversation ID where the original message was sent:
    IMessageActivity newMessage = Activity.CreateMessageActivity();
    newMessage.Type = ActivityTypes.Message;
    newMessage.Text = messageText;
    newMessage.ReplyToId = {activity_id};
    newMessage.Conversation = new ConversationAccount();
    newMessage.Conversation.Id = {conversation_id};
  2. Use ReplyToActivityAsync to send the message:
    var response = await connector.Conversations.ReplyToActivityAsync((Activity)message);
  3. Message is sent to Microsoft Teams as a new message, not as a threaded reply. No error is produced. This is most obvious in channel conversations, which can have multiple concurrent conversations happening at any one time.

Expected behavior

The message should be sent as a threaded reply to the provided activity.

Tracking Status

Dotnet SDK TODO

  • PR
  • Merged

Javascript SDK TODO

  • PR
  • Merged

Python SDK TODO

  • PR
  • Merged

Java SDK TODO

  • PR
  • Merged

Samples TODO

  • PR
  • Merged

Docs TODO

  • PR
  • Merged

Tools TODO

  • PR
  • Merged

Metadata

Metadata

Assignees

No one assigned

    Labels

    Area: TeamsThe issue is related to Teams support

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions