microsoft / botframework-sdk

Bot Framework provides the most comprehensive experience for building conversation applications.
MIT License
7.47k stars 2.44k forks source link

Question: How to reply in a new thread on Slack? #6555

Closed digitaldias closed 1 year ago

digitaldias commented 1 year ago

I realize this question has been asked before, but I do not get my code working. The proposed way of creating a new thread to reply in was the following:

            const string noValueMessage = "Find what? I need a room name to find, i.e. '!find Pusterom'";
            var reply = turnContext.Activity.CreateReply(noValueMessage);

           reply.Conversation.Properties["thread_ts"] = turnContext.Activity.Id;
           await turnContext.SendActivityAsync(reply, cancellationToken);

What I am after is the following: If the user is in a channel, and interacts with the bot, the bot should create a new thread and submit it's reply there. If the user is already in a thread conversation, the bot should just reply there.

Is this doable?

dmvtech commented 1 year ago

The Microsoft Bot Framework team prefers that how to questions be submitted on Stack Overflow. The official Bot Framework Github repos are the preferred platform for submitting bug fixes and feature requests.

dmvtech commented 1 year ago

Hi @digitaldias If you open a question on SO, please link to where this question has been asked before. You should also mention whether you are using Slack bot channel, or the Slack adapter.

digitaldias commented 1 year ago

Posted question in SO https://stackoverflow.com/questions/74683326/unable-to-make-bot-reply-in-thread-on-slack

I am using the Slack Bot channel (on the Azure portal), and also attempted to use the Community Slack Adapter, however I can't get that to authorize properly (see SO).