microsoft / botbuilder-python

The Microsoft Bot Framework provides what you need to build and connect intelligent bots that interact naturally wherever your users are talking, from text/sms to Skype, Slack, Office 365 mail and other popular services.
http://botframework.com
MIT License
710 stars 281 forks source link

Method for rendering an Adaptive Card as an Image #1979

Closed Kevv-J closed 4 months ago

Kevv-J commented 2 years ago

Is your feature request related to a problem? Please describe. I have a web app running bot framework. I am using Whatsapp Business APIs to connect this app to Whatsapp directly instead of using channels like Twilio. I want a way to render adaptive cards as images for Whatsapp, similarly to how its done in the Azure Bot for channels like Skype and Slack where interactive adaptive cards are not compatible yet.

Describe the solution you'd like Ideally I'd want to have a method in Bot Framework that will render adaptive cards from JSON to an image.

Describe alternatives you've considered Not sure if there are alternatives since the adaptive cards in my app can have dynamic information. For static cards I was planning to render it in Adaptive Card Designer and create images from that.

Additional context NA

tracyboehrer commented 4 months ago

This is not within the scope of Bot Framework SDK. We don't render the card in this stack. At the application (bot) level, something like https://npmjs.com/package/adaptivecards could be used to render to HTML, then some other functionality to render that HTML to an image.

Kevv-J commented 4 months ago

Thanks for your response.

for others' reference, We have used WhatsApp's latest feature "WhatsApp Flows" in WhatsApp to get a similar experience of using Adaptive Cards in MS Teams.