Skip to main content

Notifications

Community site session details

Community site session details

Session Id : aZV8RTKves1HxlQLxJ/ghJ
Power Automate - Building Flows
Answered

Parse x-www-form-urlencoded from HTTP POST

Like (0) ShareShare
ReportReport
Posted on 24 Jan 2022 08:14:47 by 14

Hey

I am not the most advanced user but I want to receive an SMS via a HTTP request.
The problem I encounter is that the payload I get from the SMS provider is in x-www-form-urlencoded and not json. So how can I parse the payload to get it in dynamic content to handle into teams?

The flow I have started with:

Fredd_0-1643011964535.png

 

Payload example I get from provider. 
direction=incoming& id=sf8425555e5d8db61dda7a7b3f1b91bdb& from=%2B46706861004&to=%2B46706861020& created=2018-07-13T13%3A57%3A23.741000& message=Hello%20how%20are%20you%3F

  • Fredd Profile Picture
    14 on 26 Jan 2022 at 09:22:38
    Re: Parse x-www-form-urlencoded from HTTP POST

    Thanks a lot!

  • Verified answer
    v-xiaochen-msft Profile Picture
    on 26 Jan 2022 at 06:07:29
    Re: Parse x-www-form-urlencoded from HTTP POST

    Hi @Fredd ,

     

    I did a sample for you.

    vxiaochenmsft_0-1643177096601.png

    vxiaochenmsft_1-1643177104520.png

    split(decodeUriComponent(variables('var')),'&')
    vxiaochenmsft_2-1643177128454.png
    split(items('Apply_to_each'),'=')
    {"@{trim(outputs('Compose_2')[0])}":"@{trim(outputs('Compose_2')[1])}"}
     
    vxiaochenmsft_3-1643177166158.png
     

     

     

    [
     {
     "direction": "incoming"
     },
     {
     "id": "sf8425555e5d8db61dda7a7b3f1b91bdb"
     },
     {
     "from": "+46706861004"
     },
     {
     "to": "+46706861020"
     },
     {
     "created": "2018-07-13T13:57:23.741000"
     },
     {
     "message": "Hello how are you?"
     }
    ]

     

     

    // Besides, If you want to parse the Json, you could use 'Parse JSON' action.

     

    Best Regards,

    Wearsky

     

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

Understanding Microsoft Agents - Introductory Session

Confused about how agents work across the Microsoft ecosystem? Register today!

Markus Franz – Community Spotlight

We are honored to recognize Markus Franz as our April 2025 Community…

Kudos to the March Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 146,670 Most Valuable Professional

#2
RandyHayes Profile Picture

RandyHayes 76,287 Super User 2024 Season 1

#3
Pstork1 Profile Picture

Pstork1 66,011 Most Valuable Professional

Leaderboard
Loading started
Loading complete