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 / Power Automate / Ecoding/Decoding betwe...
Power Automate
Unanswered

Ecoding/Decoding between MSD webhook and power automate flows

(1) ShareShare
ReportReport
Posted on by 37

I have attached a webhook on the accounts entity in MSD. The webhook in turn passes the data into an http request triggered power automate flow. When data is received at the power automate end, the special character that was present in the accounts name is getting converted into symbols, that is, Santé which was the actual account name, when received at the power automate flows, the value in the request body is shown as Santé

How to resolve this issue?

Categories:
I have the same question (0)
  • S-Venkadesh Profile Picture
    923 Moderator on at

    Hi @midhun_heart ,
    encodeURIComponent() can be helpful in this scenario. It will ensure that special characters are properly encoded before being passed to subsequent action. 

    I hope this information is helpful. If it is, please consider giving a thumbs up.

     

    Best regards,

    Venkadesh Sundaramurthy

  • midhun_heart Profile Picture
    37 on at

    Can u elaborate
    I have a webhook that triggers the flow. And the first step where I receive the payload, there itself I get the incorrect value. So am not sure where I can utilize the method you have mentioned. Attached the screenshot as well

  • midhun_heart Profile Picture
    37 on at

    ie The first step in my power automate flow is - "When a HTTP request is received", and the raw output of the step itself shows the incorrect data.

    ie Santé instead of Santé

  • S-Venkadesh Profile Picture
    923 Moderator on at

    Hi @midhun_heart ,

    encodeURIComponent() is typically used when preparing data for an HTTP request, especially when there are special characters that need to be properly encoded. On the other hand, decodeURIComponent() is used to decode data that was previously encoded, often after receiving it from an HTTP response.

    Could you please clarify where the HTTP call is initiated from? Knowing the context would help in understanding how these functions are used in your scenario.

    I hope this information is helpful. If it is, please consider giving a thumbs up.

     

    Best regards,

    Venkadesh Sundaramurthy

  • midhun_heart Profile Picture
    37 on at

    Hi @S-Venkadesh As stated in the question, the webhook attached to the MSDs(Microsoft Dynamics CRM) Accounts entity. Whenever an update action is performed on the accounts entity, the webhook gets triggered and it in turn calls the http request connected to the power automate flow. At the place where we register the webhook we have options to provide the url to hit, and the information that needs to be included in the request body, could not find a valid step or place to mention any encoding technique.


    https://learn.microsoft.com/en-us/dynamics365/customerengagement/on-premises/developer/use-webhooks?view=op-9-1

    This link describes how we attach the webhook.

  • S-Venkadesh Profile Picture
    923 Moderator on at

    Hi @midhun_heart ,


    The encoding to be done when registering the Webhook. Make sure to apply the encoding in the appropriate parts of the endpoint URL, such as the path and the query string.

    2. After receiving a response in your Power Automate flow, decoding should be performed to correctly interpret the data.

    Unfortunately, I'm unable to provide screenshots demonstrating this scenario due to my limited knowledge of Dynamics CRM.

    I hope this information is helpful.
    👍 If it is, please consider giving a thumbs up !.

    🤝 Best regards, Venkadesh Sundaramurthy

  • midhun_heart Profile Picture
    37 on at

    Thats the problem am also facing. Not sure where can I initiate an encoding. While setting up the webhook I have option to provide the url to hit with the data and I can also select what all data needs to be passed into the power automate flow. But webhook doesn't seem to have a provision for adding encoding. Am still looking into the issue. If I find a valid solution I will post it here.

  • midhun_heart Profile Picture
    37 on at

    @S-Venkadesh Did u find any way to enable or provide encoding details when registering a webhook using the plugin registration tool?

  • midhun_heart Profile Picture
    37 on at
    Hi Everyone
    I was able to resolve the issue using a plugin, I wrote a plugin to handle the create or update of the account entity. ie the plugin will be called when a create or update happens, within the plugin captured the required details, generated the json payload, encoded the payload and hit the power automate url which was passed into the plugin as a secured config.
  • LG-14111026-0 Profile Picture
    2 on at
    Hi - wondering if you managed to resolve this issue? I'm having the same problem.
     
    Thanks

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 > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 522 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 364 Moderator

#3
abm abm Profile Picture

abm abm 243 Most Valuable Professional

Last 30 days Overall leaderboard