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 / Copilot Studio Agent i...
Copilot Studio
Unanswered

Copilot Studio Agent in Teams - error message when showing output.text of a prompt

(2) ShareShare
ReportReport
Posted on by 9

I created an Agent in Copilot Studio, which works completely fine. When I open the same Agent in Teams it gives an error message when I give the result of a prompt back in a message (like result_prompt.text).

Error message:

Sorry, something unexpected happened. We’re looking into it. Error code: SystemError. Conversation ID: a:13tPKR4s-M3Rbu3lAm6rgcoqpbUQjPngaqGkAZtTQXlBjx8erPEOKEMUPC9FHPFlDxviaVHm3-uo2rYqFHJNz7KrOnGv-OrnwFdYve3fsb82tKnIeEw_HjFeGy_kxSLcz. Time (UTC): 5/16/2025 2:04:08 PM.

However, when I show the same result in a different fashion (result_prompt.record) the result will appear. Unfortunately, in this way the text is not nicely formatted for the Teams user. How do I make sure that the result of the prompt is a nicely formatted text message in Teams?

I have the same question (0)
  • Romain The Low-Code Bearded Bear Profile Picture
    2,111 Super User 2025 Season 2 on at
    mostly probably a conversion problem : is there a " .value" after text ? it happen sometime. if you don't find what happen, a trick could be to store the result in string variable before sending it to the tchat or use a powerFX force conversion in the formula bar
  • Suggested answer
    Michael E. Gernaey Profile Picture
    53,335 Super User 2025 Season 2 on at
     
    When you say it works, do you mean in the Test portion of Copilot Studio or in some other embedded location?
     
    It would be good to see, what actions you are doing, to get the data and how you are applying that to the variable (or however you are doing it), that you then try to push to the UI.
     
    As @Romain The Low-Code Bearded Bear said, it is very possible it simply needs you change to the Formula Mode, and add in the Text formatting you need, but would see to see a picture of what it is when its nice, and when its not to show exactly how to fix it.
  • JV-16051525-0 Profile Picture
    9 on at
    Thanks for the replies!
     
    To clarify: the tests in the Test Portion of Copilot Studio are fine. I attached a part of the flow below. In Copilot Studio I see both messages (Bericht) properly . The record version (result_prompt.record) shows something like: 
     
    {"completionTokens":88,"finishReason":"stop","imagesCount":0,"modelName":"gpt-4o-mini","modelType":"default","promptTokens":1186,"text":"Extracted information document","totalTokens":1274}
     
    Whereas the string version (result_prompt.text) shows Extracted information document
     
    However, in Teams the string (result_prompt.text) gives the error message as listed earlier. 
  • JV-16051525-0 Profile Picture
    9 on at
    Thanks! The powerFX force conversion in the formula bar indeed did the trick in the end. 

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 255 Super User 2025 Season 2

#2
Romain The Low-Code Bearded Bear Profile Picture

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

#3
S-Venkadesh Profile Picture

S-Venkadesh 101 Moderator

Last 30 days Overall leaderboard