Dispatcher utter_button_message not showing up in MS Teams

I have been trying to use dispatcher.utter_button_message in my custom actions for rasa. I have also integrated with MS Teams, and when I use the utter_button_message, I get a response on teams that says “This card’s content could not be displayed”. Is this an issue with how I am implementing the button, or could it be an issue with teams? I have attached a part of my debugger.

Core Version: 0.14.0 NLU Version: 0.15.0-spacy custom_core_sdk: 0.13.1

I got working buttons by adding type parameter:

type: 'imBack'
payload: '/affrm
title: 'Ok'

or type: 'postBack'

Source: Add rich card attachments to messages - Bot Service | Microsoft Docs

Thank you so much. That was very helpful

Do you think there is any way to dispatch adaptive cards from microsoft teams using custom actions?

1 Like

I want to send some MS card to ms teams bot,I am trying to send this url by using the format given on the link : https://docs.microsoft.com/en-us/microsoftteams/platform/task-modules-and-cards/cards/cards-actions

But i get an error : 2020-02-26 01:21:45 ERROR rasa.core.channels.botframework - Error trying to send botframework messge. Response: {“error”:{“code”:“BadArgument”,“message”:“Unknown activity type”}

Below is my custom action which is invoked.

class ActionHelloWorld(Action):

def name(self) -> Text:
    return "action_hello_world"

def run(self, dispatcher: CollectingDispatcher,
        tracker: Tracker,
        domain: Dict[Text, Any]) -> List[Dict[Text, Any]]:
    message = {
        "type": "openUrl",
        "title": "Tabs in Teams",
        "value": "https://msdn.microsoft.com/microsoft-teams/tabs"


    return []