Hi all – I’m running into an issue where my Zap attempts to upload email attachments (specifically PDFs) from Gmail, filter them using MIME type in a code step, and pass only the valid PDFs into the “Upload File” and “Conversation” steps for ChatGPT.
Here’s what’s happening:
-
I correctly isolate PDFs via MIME type using a JavaScript step.
-
The filtered file URLs are then passed to several “Upload File to OpenAI” steps using the “assistants” purpose.
-
The upload appears successful — the PDF shows as Ready in the OpenAI file list with the correct file- ID.
-
However, when I try to pass those uploaded file IDs into a “Create Conversation in ChatGPT” step, I receive the error:
“Non-PDF files (downloaded_file.txt…) require Code Interpreter to be enabled…”
-
I’ve confirmed that the files I’m passing are valid PDFs, not text files — but downloaded_file.txt files keep appearing in my OpenAI storage.
-
My assumption is Zapier is somehow uploading blank or non-PDF files behind the scenes, even though I’ve filtered for MIME type.
Would appreciate any help — I’m trying to reliably extract PDF attachments from Gmail and feed them into ChatGPT for summarization, and this issue is holding up the workflow.
Thanks in advance!