Azure Logic Apps: files get corrupted when sent via http RRS feed

  • Question

  • Hello,

    I'm using logic apps to call the Connectwise Document API to attach images, pdfs, emails, etc. to tickets. I can call the endpoint directly via postman and everything works fine, and when I try to replicate the request in Logic Apps, it looks like everything is working fine, but when I get the file at the end (attached to my Connectwise ticket), the image, excel sheet, whatever is corrupted. Text attachments work somehow.

    The logic app listens to a mailbox, so I've been extracting the attachments and uploading to BLOB storage and sending the file content of that (Obtained via GET BLOB) in my request. When the files are in azure storage, they are fine (I can download them and send them via postman and they show up fine).

    Any idea what might be going on here? Details below:

    And here's the code representation:

    Content-Dis-data; name="recordId"
    Content-Dis-data; name="recordType"
    Content-Dis-data; name="title"
    Content-Dis-data; name="file"; filename="@{items('For_each')['Name']}"

    Is Get Blob the best way to get my Blobs from storage? I haven't been able to find any other methods and it feels like this should work. 

    Thanks in advance for any help! Let me know if you need more details!


    Friday, February 22, 2019 9:25 PM

All replies

  • Hello ,

    I assume you are facing issue with the content type ,Open your Logic Apps run and validate the HTTP output.

    If the request matches your postman request , i do not see any issue and you should be able to POST the right request 

    If this answers your question please mark it accordingly. If this post is helpful, please vote as helpful by clicking the upward arrow mark next to my reply

    Sunday, February 24, 2019 7:30 PM
  • Hey Abishek, thanks for your reply. 

    I was wondering what the best way to do that is because the binary version of the file that's used in the request is obviously very hard to visually compare and make sure it's correct.  Do you know if there are any quirks to using the Get BLOB functionality in Azure? or suggest another way to compare these binary outputs?



    Monday, February 25, 2019 6:36 PM