How to attach an .JPG to the OpenAI API Assistant?

Hello everybody,

I´m new using Make…

I was trying to send an Image to the Assistant in order to get some text via OCR through ChatGPT 4o

This are the steps:
-Trigger once new file is created in specific Drives folder
-Download the new file from drive
-Upload the file to Open AI
-Send the file to the Assistant (Here i got the error)

Any advice of how to do it? I tried sending ID, Object… and it didn´t work.

Thank you in advance!

If you don’t have a specific reason to try to use the Assistant API, perhaps use the OpenAI “Analyze Images (Vision)” module, with the “gpt-4o” multi-modal modal. I’ve attached some screenshots + a scenario blueprint. Hope it helps.

Dr Nic




Make - JPG to OCR with OpenAI Vision.json (17.9 KB)

@drnic good solution, but I think it may be possible to remove the Match Pattern module to save an operation. What do you think?

Don’t get me wrong, I LOVE using the Match Pattern module too!

Perhaps one of the string functions can help?

samliew – request private consultation

Join the Make Fans Discord server to chat with other makers!

Hello!

Finally, i did it in that way.

This is how my automation looks like now…

I asked the OpenAi vision module for an array, then i processed it by the JSON module and i was able to continue with the automation

Thank you all for your support :wink: