How to extract or convert a bin file into a PNG file

Hello,

I encounter an issue which I’m sure should be easy to solve. But I haven’t found the answer anywhere.

I created a PNG file (an image) by using AI. Then used the get a file module. I wanted to upload the file to Google Drive. Unfortunately it uploaded the BIN file which I can’t use. I need to convert the file back to PNG while uploading it to Google Drive.

I tried to use the goString function and encode URL but nothing had worked for me.

Could you kindly instruct on which function should I use to extract automatically the PNG out of the binary? Perhaps I should upload the file and then try to convert it while it is stored on Google Drive…

Thank you


@ori_dror
Hi, AI Assistant gave me a answer.

Data Conversion: You will need to add an appropriate module to convert the binary data to PNG format. Make might not have a direct conversion module, but you can use an external API to perform the conversion.

Thank you!

Actually, I asked also Make directly. You can change the Bin file to PNG by mapping the Uploading a file in the Google Drive. Then use this function in the mapping: {{replace(1.fileName; “.bin”; “.pdf”)}}

2 Likes

@ori_dror
Thank you! I didn’t know that either, so that helps.

1 Like