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 Automate / Change Shape Of The Cu...
Power Automate
Answered

Change Shape Of The Custom Connector Response

(0) ShareShare
ReportReport
Posted on by 29,991 Moderator
I built a custom connector whose default response is a nested JSON object (left-side) but I want to make it look like the JSON object on the right-side:
 
  • Remove nesting
  • Rename keys to my own preferred names
  • Change text to numbers for some pairs
Is there a way to shape a custom connector response?  I am willing to write code in other languages to do it.

 
mdevaney_1-1627995105924.png

 

Categories:
I have the same question (0)
  • mdevaney Profile Picture
    29,991 Moderator on at

    @Syndicate_Admin 
    I would prefer to code the connector so it gives the desired JSON object instead.  Is this possible?

  • murshed Profile Picture
    Microsoft Employee on at

    While we expect your API to do any type of transform and use connector as a pass through, we released a new feature yesterday that will allow you to write custom code: https://docs.microsoft.com/en-us/connectors/custom-connectors/write-code

    If this reply answers your question or solves your issue, please ACCEPT AS SOLUTION ☑️. If you find this reply helpful, please consider giving it a LIKE 👍.

  • mdevaney Profile Picture
    29,991 Moderator on at

    @murshed 

    Thank you very much for linking me to this announcement.  I will attempt to implement it and mark your answer as the solution once I’ve verified it works. This is awesome!

  • Verified answer
    mdevaney Profile Picture
    29,991 Moderator on at

    @murshed 
    I figured out how to transform the response using some C# code and detailed the steps on my blog:
    https://matthewdevaney.com/transform-a-custom-connector-response-with-c-code/

     

    ---
    Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up." 

  • murshed Profile Picture
    Microsoft Employee on at

    Thanks for blog @mdevaney ! This is awesome!

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
David_MA Profile Picture

David_MA 238 Super User 2026 Season 1

#2
11manish Profile Picture

11manish 225

#3
Haque Profile Picture

Haque 181

Last 30 days Overall leaderboard