Card Action button is not working with hero card in facebook messenger
See original GitHub issueBot info
- SDK Platform: .NET
- SDK Version: 3.0.10.
- Active Channels: WebChat, Facebook
- Deployment Environment: Azure App Service
Issue Description
- I created a HeroCard. It have a button (CardAction) to select the item. If the user clicks on the button (the button title should be “click me”), I expect the user to see the response of “click me” intent. After clicking on button in messenger it gives error like “Object Serialized to String. JObject instance expected”.
- In the emulator it works perfectly. but in messenger it is not getting value, it is getting title as text and giving the above mentioned error.
Code Example
# HeroCard
[HeroCard
title = Lets Begin
subtitle = Microsoft Bot Framework
text = Build and connect intelligent bots to interact with your users naturally wherever they are, from text/sms to Skype, Slack, Office 365 mail and other popular services.
image = https://greatsmilesbirmingham.com/wp-content/uploads/2017/09/canstockphoto30606317.jpg
buttons = @{cardActionTemplate( 'imBack', 'click me', 'click me intent' )}
]
# cardActionTemplate( type, title, value)
[CardAction
Types = @{if(type == null, 'imBack', type)}
Title = @{title}
Value = @{value}
Text = @{value}
]
Issue Analytics
- State:
- Created 4 years ago
- Comments:25 (12 by maintainers)
Top Results From Across the Web
Card Action button is not working with hero card in facebook ...
There seems to be some misunderstanding here. The problem was never that card actions don't render correctly in Facebook Messenger. This ...
Read more >Node.js Botframework 4 - Hero Card with buttons doesn't work ...
I'm using botframework with Node.js SDK version 4, and i'm try to send an HeroCard to Facebook Messanger. If i send the card...
Read more >Add card actions in a bot - Teams - Microsoft Learn
The actions do not work while the card is in the compose message box. ... Your bot doesn't receive any notice on which...
Read more >Generic Template - Messenger Platform - Meta for Developers
The generic template is a simple structured message that includes a title, subtitle, image, and up to three buttons. You may also specify...
Read more >Using Adaptive Cards with the Microsoft Bot Framework
While Adaptive Cards have not been designed specifically for the Bot ... actions” which remedy the card problem by showing the buttons only ......
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
This is my code for Action Button. I am testing this in bot framework emulator it is working fine. But when I m integrating this with facebook messenger and after clicking on the button it is giving error like this.
@swaraj27 Hi Swaraj, I will close this issue since the issue could not be reproduced, If you have any questions please reopen this issue and provide more details.