{"product_id":"n8n-gmail-triage-openai-draft-replies-google-sheets-log","title":"n8n Gmail Triage: OpenAI Draft Replies + Google Sheets Log","description":"\u003ch3\u003eTriaging your Gmail inbox with OpenAI—labels, draft replies, and a Google Sheets audit log (every 10 minutes)\u003c\/h3\u003e\n\u003cp\u003e\u003cstrong\u003en8n Gmail Triage: OpenAI Draft Replies + Google Sheets Log\u003c\/strong\u003e automatically reviews new inbox emails, uses \u003cstrong\u003eOpenAI Chat Completions\u003c\/strong\u003e to categorize and prioritize them, applies Gmail labels, and (when appropriate) creates \u003cstrong\u003eGmail reply drafts\u003c\/strong\u003e. Every processed message is recorded in \u003cstrong\u003eGoogle Sheets\u003c\/strong\u003e so you can track what happened.\u003c\/p\u003e\n\n\u003ch3\u003eWhat this workflow does\u003c\/h3\u003e\n\u003cul\u003e\n  \u003cli\u003e\n\u003cstrong\u003eRuns every 10 minutes\u003c\/strong\u003e and loads configuration values like the Gmail search query, label names, the OpenAI model, and the Google Sheets destination.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eEnsures AI-related Gmail labels exist\u003c\/strong\u003e (optionally creating missing labels used for triage and categorization).\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eFetches a limited batch\u003c\/strong\u003e of untriaged Gmail inbox messages matching your query and cleans the email body (removing HTML and quoted history).\u003c\/li\u003e\n  \u003cli\u003eSends each email to \u003cstrong\u003eOpenAI Chat Completions\u003c\/strong\u003e to return structured \u003cstrong\u003eJSON\u003c\/strong\u003e: category, priority, sentiment, summary, next steps, and an optional reply draft.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eValidates and acts on the AI output\u003c\/strong\u003e: decides whether to apply labels, flag for review, create a Gmail reply draft, and\/or trigger an urgent owner alert.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eNon–dry-run mode\u003c\/strong\u003e applies selected labels as a processed lock, creates \u003cstrong\u003ethreaded Gmail draft replies\u003c\/strong\u003e when allowed, and can send urgent alert emails via Gmail when configured.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eLogs results to Google Sheets\u003c\/strong\u003e by appending or updating a row with triage details, draft content, applied labels, and status\/error information.\u003c\/li\u003e\n\u003c\/ul\u003e\n\n\u003ch3\u003eUse cases\u003c\/h3\u003e\n\u003cul\u003e\n  \u003cli\u003eSaaS teams triaging inbound customer emails and drafting responses for fast follow-up.\u003c\/li\u003e\n  \u003cli\u003eOps or support workflows that need priority scoring, summaries, and sentiment tracking.\u003c\/li\u003e\n  \u003cli\u003eOperators who want a reliable audit trail of email processing in \u003cstrong\u003eGoogle Sheets\u003c\/strong\u003e.\u003c\/li\u003e\n  \u003cli\u003eUrgent escalation when certain emails meet your configured criteria.\u003c\/li\u003e\n\u003c\/ul\u003e\n\n\u003ch3\u003eTechnical details\u003c\/h3\u003e\n\u003cul\u003e\n  \u003cli\u003eBuilt with n8n nodes including \u003cstrong\u003egmail\u003c\/strong\u003e, \u003cstrong\u003ehttp request\u003c\/strong\u003e, \u003cstrong\u003egoogle sheets\u003c\/strong\u003e, \u003cstrong\u003eif\u003c\/strong\u003e, \u003cstrong\u003ecode\u003c\/strong\u003e, and a \u003cstrong\u003esticky note\u003c\/strong\u003e.\u003c\/li\u003e\n  \u003cli\u003eIntegrations: \u003cstrong\u003eGmail OAuth2\u003c\/strong\u003e (read\/label\/draft\/send), \u003cstrong\u003eOpenAI API\u003c\/strong\u003e credentials, and \u003cstrong\u003eGoogle Sheets OAuth2\u003c\/strong\u003e.\u003c\/li\u003e\n\u003c\/ul\u003e","brand":"N8N Commerce","offers":[{"title":"Default Title","offer_id":46172950266035,"sku":"N8N-20570","price":48.99,"currency_code":"GBP","in_stock":true}],"thumbnail_url":"\/\/cdn.shopify.com\/s\/files\/1\/0749\/6279\/6723\/files\/IBIsUMNdD4hSDgrB7Lgvo_REeasEYw.png?v=1791364766","url":"https:\/\/buyflowscripts.com\/products\/n8n-gmail-triage-openai-draft-replies-google-sheets-log","provider":"N8N Commerce","version":"1.0","type":"link"}