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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Copilot Studio / Populating an Adaptive...
Copilot Studio
Unanswered

Populating an Adaptive Card RichTextBlock from output from Gen AI

(0) ShareShare
ReportReport
Posted on by 12

Rather than plain text responses from Gen AI, I'd like it to be more well-formatted and hierarchal.
With a little prompt engineering, I can have OpenAI respond with a RichTextBlock formatted response (something like below).

 

Detail what's involved in a Microsoft Partnership. Provide the well-formatted response as code for inclusion within a Microsoft AdaptiveCard RichTextBlock. The json schema will be 

[{ "type": "TextRun",
 "text": "Microsoft Partnership Overview\n",
 "weight": "Bolder", // lighter, default
 "size": "Large", // small, default, medium, extraLarge,
 "italic": true // optional
 }, {}..]

 

 

I can parse the result into a table variable that works when copied and pasted into AdaptiveCardDesigner (with a 1.5 schema).

My question is; for CopilotStudio, how do I bind the table so that can populate the adaptive card correctly?
Below is the Adaptive Card portion of the Topic:

 

- kind: SendActivity
 id: sendActivity_IGejwb
 activity:
 attachments:
 - kind: AdaptiveCardTemplate
 cardContent: |-
 ={
 type: "AdaptiveCard",
 '$schema': "http://adaptivecards.io/schemas/adaptive-card.json",
 version: "1.6",
 body: [
 {
 type: "RichTextBlock",
 inlines: 
 ForAll(Topic.VarTable,
 {
 type: "TextRun",
 text: text,
 weight: weight,
 size: size,
 italic: italic,
 wrap: true
 }
 )
 }
 ]
 }

 


Unfortunately, it simply displays an empty message.
Earlier messages confirm the table var is correctly populated.

Categories:
I have the same question (0)

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Copilot Studio

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 250 Super User 2025 Season 2

#2
Romain The Low-Code Bearded Bear Profile Picture

Romain The Low-Code... 197 Super User 2025 Season 2

#3
S-Venkadesh Profile Picture

S-Venkadesh 103 Moderator

Last 30 days Overall leaderboard