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 Apps / Parsing the conversati...
Power Apps
Unanswered

Parsing the conversation transcript JSON from annotation.documentBody

(1) ShareShare
ReportReport
Posted on by 3
Looking for guidance on how to parse and transform the annotation.documentBody value from a Dynamics 365 Customer Service environment
 
The values in this column are BASE64 encoded. After decoding them, the values are JSON formatted, however include a lot of (seemingly) unnecessary backslashes
 
When I paste the decoded value into a JSON formatter, the formatter gives me errors such as 'Expecting 'EOF', '}', ':', ',', ']', got 'undefined''
 
Does anyone have or know of a documented way to successfully decode and parse the annotation.documentBody values into a usable format, similar to conversationTranscript.content?
 
TIA
I have the same question (0)
  • Michael E. Gernaey Profile Picture
    53,969 Moderator on at
     
    So the thing you are seeing are all the escape slashes in the string.
     
    Can you share a full example. Then I can help you no problem. If you are concerned you can DM it to me.
  • CU13030700-0 Profile Picture
    3 on at
    Hi @Michael E. Gernaey ,, I am unable to share due to confidentiality and data classification policies within our business
     
    I have simply used an online decode, as well as Power Query
    Lines.FromBinary(Binary.FromText(text,BinaryEncoding.Base64), null, null, 1252){0}
     
    Are you able to point me to any open-source code or logic to decode and parse the JSON, or make your suggestion and I will attempt to apply to our data
     
    Thanks!
  • Michael E. Gernaey Profile Picture
    53,969 Moderator on at
    HI
     
    You are doing what you should based on what you have. WIthout seeing it though I cannot tell you what is wrong.
     
    You will need however to do a replace to any of the characters you do not want., This means you can replace the \ slashes, since you dont need them escaped, if its jus giving you "text" escaped.
     
    literally do a compose action
    replace(string(myjson, '\', '')
     
    Now again since I can't see it thats just one thing you may need to do.

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 Apps

#1
11manish Profile Picture

11manish 530

#2
WarrenBelz Profile Picture

WarrenBelz 459 Most Valuable Professional

#3
Haque Profile Picture

Haque 314

Last 30 days Overall leaderboard