Hello @bitshift ,
Thanks for the ask and using the Microsoft Q&A platform .
From all in the inputs which you have provided I see that you are more inclined towards Azure Functions . I am pretty confident that you will be able to achieve the ask with that also . Since you are more code centric , this may be more helpful.
I could suggest you to evaluate the Mapping data flow (MDF ) as it does provide the the transformation option and its also lets you play with the JSON object . For MDF you will not need any coding ( just some expression ) as most of the thing are drag and drop .
Please do let me know how it goes .
Please do consider to click on "Accept Answer" and "Up-vote" on the post that helps you, as it can be beneficial to other community members