web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Working within JSON ob...
Power Automate
Answered

Working within JSON objects and getting Adaptive Cards to display in Teams

(0) ShareShare
ReportReport
Posted on by 34
 {
 "type": "Container",
 "separator": true,
 "items": [
 {
 "type": "TextBlock",
 "size": "Large",
 "weight": "Bolder",
 "color": "Accent",
 "text": "Project Links"
 },
 {
 "type": "TextBlock",
 "spacing": "Small",
 "size": "Small",
 "text": "Project Links Dynamic Multiple",
 "wrap": true
 }
 ]
 },

This is an example chunk of an adaptive card I am building. For the second text block, I want to be able to split a Forms response (already have that part) and do a for-each where a new text block using the parameters of the last text box above and the output of the split in the text field. 

 

I'm trying to return an Adaptive Card to Teams using objects instead of strings since supplying a string of the JSON returned this at the final action to submit the card to Teams:

"error": {
 "code": "MissingOrInvalidBotAdaptiveCardRequest",
 "message": "The specified Teams flowbot adaptive card request is missing or invalid."
}

Either I'm not submitting the data properly using Flow, or something is not right on the Teams side. Thank you!

Categories:
I have the same question (0)
  • dgpadia Profile Picture
    34 on at

    Now I am finding that the message body for the action "Post your own adaptive card as the Flow bot to a channel (preview)" absolutely HAS to be a string. It won't allow me to insert a variable of the type 'object' into the message body. So there's that, I guess. I'll have to do everything via strings. Either way, I'm still getting this error message no matter how I enter the card information. 

  • RyanMesser Profile Picture
    36 on at

    Haing exactly the same issue, did you manage to work anything out?


    @dgpadia wrote:

    Now I am finding that the message body for the action "Post your own adaptive card as the Flow bot to a channel (preview)" absolutely HAS to be a string. It won't allow me to insert a variable of the type 'object' into the message body. So there's that, I guess. I'll have to do everything via strings. Either way, I'm still getting this error message no matter how I enter the card information. 




  • dgpadia Profile Picture
    34 on at
    I also posed the question here: https://stackoverflow.com/questions/55070910/microsoft-flow-teams-adaptive-card?noredirect=1#comment97005869_55070910
    No real answers, but one user did know to put in an issue/request at the Microsoft documentation GitHub to see if they could provide answers: https://github.com/MicrosoftDocs/flow-docs/issues/100
    Knowing Microsoft, maybe we'll get an answer sometime next year . . . Or the year after . . .
  • RyanMesser Profile Picture
    36 on at

    Was just wondering if you are doing it via json did you put the schema in ? I tried this and managed to get it to post by putting this at the end of my code. 

  • dgpadia Profile Picture
    34 on at
    Yeah, I even tried just submitting the example card json as static text (no variables or anything dynamic) and I still get the same error.
  • Verified answer
    RyanMesser Profile Picture
    36 on at

    I see, have you tried going here ? https://adaptivecards.io/designer

     

    Also I had to install both App Studio in Teams and install the Flow Bot on the Team where I wanted to post tickets from flow I assume you've done this?

    Its working for me so far

  • dgpadia Profile Picture
    34 on at

    Everything works now. Apparently, my corporate IT did have permissions accepted for the TeamsFlowTab app for our corporate Office 365. Once that was done, we can now post adaptive cards. I also did install App Studio, but I'm not sure if it was necessary or not, as they approved the permissions after I left on Friday. I come in Monday and right away get to adding the App Studio app. Maybe it was one or the other, maybe it was both. Either way, the double check for permissions is to open the Flow app in Teams and try to go to the Flows or Approvals tabs and see if it will let you sign in. 

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Haque Profile Picture

Haque 608

#2
Valantis Profile Picture

Valantis 416

#3
11manish Profile Picture

11manish 348

Last 30 days Overall leaderboard