Skip to main content
Community site session details

Community site session details

Session Id :
Power Automate - Connector Development
Answered

Change Shape Of The Custom Connector Response

(0) ShareShare
ReportReport
Posted on by 29,987 Super User 2025 Season 1
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

 

  • murshed Profile Picture
    Microsoft Employee on at
    Re: Change Shape Of The Custom Connector Response

    Thanks for blog @mdevaney ! This is awesome!

  • Verified answer
    mdevaney Profile Picture
    29,987 Super User 2025 Season 1 on at
    Re: Change Shape Of The Custom Connector Response

    @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." 

  • mdevaney Profile Picture
    29,987 Super User 2025 Season 1 on at
    Re: Change Shape Of The Custom Connector Response

    @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!

  • murshed Profile Picture
    Microsoft Employee on at
    Re: Change Shape Of The Custom Connector Response

    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,987 Super User 2025 Season 1 on at
    Re: Change Shape Of The Custom Connector Response

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

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

Paul Stork – Community Spotlight

We are honored to recognize Paul Stork as our July 2025 Community…

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 497 Super User 2025 Season 1

#2
David_MA Profile Picture

David_MA 436 Super User 2025 Season 1

#3
Riyaz_riz11 Profile Picture

Riyaz_riz11 244 Super User 2025 Season 1

Featured topics