Issue with fetching the message id attachments, as it returns all the attachment from the email thread.
No error, but there is no way to know which attachment belong to the message id in question, as it returns all the attachments from the long email thread.
Utilizing Gmail Tried and also tried Gmail node for the purpose with Get Message and Download attachment and turning Simplify off. How to make sure when if I am getting details about a message I only get the attachments attached to that thread and not the 10 messages from the thread, as I do the the message id is unique.
Information on your n8n setup
n8n version: 1.102.4
Database (default: SQLite): Default
n8n EXECUTIONS_PROCESS setting (default: own, main): No change, using N8N Cloud
Running n8n via (Docker, npm, n8n cloud, desktop app):
The Gmail API has two approaches to retrieving messages:
messages endpoint: Returns a specific message, excluding other messages in the thread.
threads endpoint: Returns all messages and their attachments from an entire thread.
In n8n:
If the node is configured to work with messageId, it should return only the attachments for that message.
If for some reason the node uses threadId internally, it could fetch data from more than one message.
Some integrations may have inconsistent behavior if they use threadId to group results.
Thank you, @Erick_Torres for quick response, but as you shared I am only seeking data for a particular messageid and it fetches all the images from all the messages in that thread, I am not certain but would it be cause message usually has trailing messages?
So, in short, I have Gmail Node, with Get Message and single messageid not the thread id. Is there a way to mitigate this?
This is for anyone hunting the solution, I ended up doing Gmail API direct request with HTTP node by creating appropriate ClientID and Client Secret to utilize in n8n, and writing custom login to capture the attachments from the current email/message id to meet my requirement.