Adaptive Cards for Beginners- Monitor a Hashtag on Twitter
I wanted to work’n’play with Adaptive Cards, which are the future of notifications and I wanted to experiment with the Flow Bot in Microsoft Teams so I tried to figure out how I could monitor a hashtag and post an actionable card into a Channel or a chat into Teams.
For my purposes, I want to monitor the hashtag #LuiseINeedYourHelp on twitter, because I set up an Out-Of-Office Notification in my Outlook:
I’m traveling between conferences to learn and grow and deliver you, my precious customers, most up-to-date value. Can’t catch up on email till xx.xx. Fastest way to reach me is is on Twitter- by the way: I monitor #LuiseINeedYourHelp
The Twitter Trigger
So I started on https://flow.microsoft.com with a new Flow from blank. My trigger is: When a new tweet is posted:
The Adaptive Card Action
My only action is:
Post your own adaptive Card as the Flow Bot to a user:
I wrote my own email-address in the recipients field. After that, I opened https://adaptivecards.io/designer/ and chose Microsoft Teams dark as host app:
Now I removed a elements from the card I don’t wanted to have:
and replaced some text:
The JSON Code
After that, I copied the JSON code and pasted it into my flow-action. Now I began to replace some text of the JSON with dynamic content of my twitter-trigger. Please note that JSON 1.2 is supported.
Whenever somebody posts #LuiseINeedYourHelp on twitter, I get a private message on MicrosoftTeams in which I can view and open that tweet directly. Works on desktop, web and mobile (Because: If it doesn’t work on mobile, i doesn’t work)
Happy Vacay to me!
Do you like adaptive Cards? Want to learn more? Please clap if you like more of these posts. If you are more advanced, I’d love to point you to Tomasz Poszytek.
You May Also Like
tl;dr Using CLI Microsoft 365 you can easily add and remove owners of …
tl;dr CLI for Microsoft 365 is an amazing tool to manage your …
tl;dr Custom functions are a great way to make code reusable in Power …