This blog tells you about BOM in Azure Logic Apps and what to do about it.
This started with a customer request that said “Can the Brand & Pack Size values be stitched/concatenated into the Product description value?
I.e. (~ = Separator. This can be up to you. My example was with a ~)
Product Description = Product Description + ~ + Brand + ~ + Pack size”. This sounds pretty simple. The logic app simply sends a JSON message to a SFTP folder and then renames it.
The customer reports on testing that they can’t process message “as they are JSON with BOM”. (their words). Now the fun starts.
BOM in Azure Logic Apps
Firstly, retrieving a copy of the JSON file from the SFTP server it indeed has a BOM.
This is nasty and looks like a bug in the JSON-JSON map action. There is a byte order mark(BOM) added. Why are you doing this Microsoft?
David Burg gives a solution here.
Thus, I added this piece of Logic App definition language snippet to my Logic App.
The Transform JSON to JSON Logic App action is adding a BOM and I have shown how to work around this. Does this occur all the time? Can anyone confirm this? If so it is a bug and I think it should be fixed.