I have a case where I need to send an Attachment as a BLOB to a Dynamics endpoint. I have seen the built in field in the Attachment object with data type blob, so I hope there is a way to use it. In my case I want users to upload a .pdf file and send it to Dynamics.
Thanks
Do you have any specifications of the recipient endpoint?
I guess it’s a POST request. But if the Body type is “Form data” (which is most common for such uploads) I believe you may add a Key with data type File, select the File Content property and a Blob will be sent.
Yep, correct. I’ve tested i few different versions of this now. One of them as you suggest. It seems however that I cannot reach the File Content property you are referring to. I might be missing something(?).
When i create the Attachment object as a runtime object with cardinality 1, I do see the field File Data created as a Blob, this field, however, is not reachable from data binding or the functions interface… When you say the File Content property are you referring to the File Content Url?
Using Body Type Form Data you are only allowed to databind the File Content URL (see screenshot). The action node should convert it to a blob upon sending.
Hi, do you haven any more information about the endpoint you are using? Is is it made for this case or is it a std. endpoint in what I assume is MS Dynamics 365 Finance and Operations?
Normally when sending files (pdf) to D365FO, std. endpoints must receive the file in a base64 string. But this endpoint could be different.
Hi.
It is made specifically for this case. It is not a blackbox, but lacking proper documentation for the created endpoint. It is made for MS Dynamics 365 Finance and Operations, correct!
I’m now sending it as a base64 string, but the MS developer wanted it as a blob without providing more details. The base64 string solution is working ok for now, but the blob solution will be brought up again in a few weeks.
I’ve commented out where I tried to create the blob.
If I try to store the Blob in a field, what data type should the field have?
My understanding is that I should send Binary code with the PATCH request I’m doing to the MS FO-endpoint, and I was hoping I could use the field on the Attachment object in Appfarm directly, with the datatype Blob
I’ve tested several different versions now without any luck, so I’m note sure if the current version is the best I can do for now.