-
Notifications
You must be signed in to change notification settings - Fork 261
Description
Language
C#
Version
latest
Description
Setting feedbackLoopType to "custom" on a StreamingChannelData object included as ChannelData in a message Activity response from the bot does not properly enable Teams to be able to fetch a custom feedback form when clicking the feedback buttons.
This appears to be related to an issue with how the feedbackLoopType is serialized to the channelData property within the JSON. Currently, feedbackLoopType is included as a property of channelData when serialized. However, according to some docs, the bot framework API seems to expect this to be set like the following within the channelData property:
{
"feedbackLoop": {
"type": "custom"
}
}
Per #2387 , it sounds like this is a bug.
Reproduction Steps
Working example using TeamsChannelData instead of StreamingChannelData:
activity.ChannelData = new TeamsChannelData()
{
AdditionalProperties = new Dictionary<string, object>()
{
["streamSequence"] = 2,
["streamType"] = "final",
["feedbackLoop"] = new Dictionary<string, object>
{
{ "type", "custom" }
}
}
};
await turnContext.SendActivityAsync(activity, cancel);
Expected to work, but not working:
activity.ChannelData = new StreamingChannelData()
{
StreamSequence = 2,
StreamType = StreamType.Final,
feedbackLoopType = "custom"
};
await turnContext.SendActivityAsync(activity, cancel);