AutomationFlowsAI & RAG › Summarize Sales Emails and Save to Odoo

Summarize Sales Emails and Save to Odoo

Original n8n title: Summarize Emails and Save Them as Notes on Sales Opportunity in Odoo

ByMihai Farcas @mihailtd on n8n.io

This n8n workflow automates the process of extracting information from emails. It uses OpenAI to summarize sales emails and adds this information in Odoo. When an email is received with a certain label, it sends the email to OpenAI for summarization A sales opportunity is…

Event trigger★★☆☆☆ complexityAI-powered5 nodesGmail TriggerOdooLm Open AiChain Summarization
AI & RAG Trigger: Event Nodes: 5 Complexity: ★★☆☆☆ AI nodes: yes Added:

This workflow corresponds to n8n.io template #2336 — we link there as the canonical source.

The workflow JSON

Copy or download the full n8n JSON below. Paste it into a new n8n workflow, add your credentials, activate. Full import guide →

Download .json
{
  "id": "NPGAfBzz4nv8lTpl",
  "meta": {
    "templateCredsSetupCompleted": true
  },
  "name": "Save New Sales Opportunities",
  "tags": [],
  "nodes": [
    {
      "id": "64b02b70-e7f2-4df0-852f-b6959af8d8c5",
      "name": "Received Emails with Sales Label",
      "type": "n8n-nodes-base.gmailTrigger",
      "position": [
        760,
        540
      ],
      "parameters": {
        "simple": false,
        "filters": {
          "labelIds": [
            "Label_8035866011660570111"
          ]
        },
        "options": {},
        "pollTimes": {
          "item": [
            {
              "mode": "everyHour"
            }
          ]
        }
      },
      "credentials": {
        "gmailOAuth2": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 1.1
    },
    {
      "id": "6dca3c61-98ba-4d18-bc5c-9c762e12f13b",
      "name": "Odoo - Create Opportunity",
      "type": "n8n-nodes-base.odoo",
      "position": [
        1500,
        540
      ],
      "parameters": {
        "resource": "opportunity",
        "opportunityName": "={{ $('Received Emails with Sales Label').item.json.headers.subject }}",
        "additionalFields": {
          "email_from": "={{ $('Received Emails with Sales Label').item.json.from.value[0].address }}",
          "description": "={{ $json.response.text }}"
        }
      },
      "credentials": {
        "odooApi": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 1
    },
    {
      "id": "a57e0e51-50d3-49de-8dc6-6fe592604765",
      "name": "OpenAI Model",
      "type": "@n8n/n8n-nodes-langchain.lmOpenAi",
      "position": [
        1040,
        720
      ],
      "parameters": {
        "model": {
          "__rl": true,
          "mode": "list",
          "value": "gpt-3.5-turbo-instruct"
        },
        "options": {}
      },
      "credentials": {
        "openAiApi": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 1
    },
    {
      "id": "a6de25a3-3967-4957-bc98-4cb774a53dda",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        700,
        220
      ],
      "parameters": {
        "width": 446.44549763033154,
        "height": 261.8821936357484,
        "content": "## Summarize emails and save them as notes on sales opportunity in Odoo\n\nSet up steps:\n* Configure Google Cloud credentials with Gmail access\n* Configure OpenAI credentials\n* Configure Odoo credentials\n "
      },
      "typeVersion": 1
    },
    {
      "id": "8705b4de-1334-4ff2-8d5d-60ec96cfb8cd",
      "name": "Summarize Email Content",
      "type": "@n8n/n8n-nodes-langchain.chainSummarization",
      "position": [
        1060,
        540
      ],
      "parameters": {
        "options": {
          "summarizationMethodAndPrompts": {
            "values": {
              "prompt": "=Write a concise summary of the following sales inquiry:\n\" {{ $json.text }}\"\nInclude structured information such as project budget, timelines, industry and a general summary\n\nCONCISE SUMMARY: \n",
              "combineMapPrompt": "=Write a concise summary of the following sales inquiry:\n\"{{ $json.text }}\"\nExtract information such as project budget, timelines and a general summary.\n\nCONCISE SUMMARY: \n"
            }
          }
        }
      },
      "typeVersion": 2
    }
  ],
  "active": false,
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "8c905538-5613-464b-b5a0-87e266a507c7",
  "connections": {
    "OpenAI Model": {
      "ai_languageModel": [
        [
          {
            "node": "Summarize Email Content",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "Summarize Email Content": {
      "main": [
        [
          {
            "node": "Odoo - Create Opportunity",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Received Emails with Sales Label": {
      "main": [
        [
          {
            "node": "Summarize Email Content",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}

Credentials you'll need

Each integration node will prompt for credentials when you import. We strip credential IDs before publishing — you'll add your own.

Pro

For the full experience including quality scoring and batch install features for each workflow upgrade to Pro

About this workflow

This n8n workflow automates the process of extracting information from emails. It uses OpenAI to summarize sales emails and adds this information in Odoo. When an email is received with a certain label, it sends the email to OpenAI for summarization A sales opportunity is…

Source: https://n8n.io/workflows/2336/ — original creator credit. Request a take-down →

More AI & RAG workflows → · Browse all categories →

Related workflows

Workflows that share integrations, category, or trigger type with this one. All free to copy and import.

AI & RAG

This template and YouTube video goes over 5 different implementations of evaluations within n8n. Categorization Correctness Tools used String similarity Helpfulness

Evaluation, Evaluation Trigger, Google Gemini Chat +8
AI & RAG

Marketing agencies, digital agencies, and freelancers who need to streamline their client onboarding process and create consistent, professional documentation for new clients. Perfect for teams handli

Google Drive, Slack, Typeform Trigger +3
AI & RAG

Clone_Viral_TikToks_with_AI_Avatars___Auto_Post_to_9_Platforms_using_Perplexity___Blotato. Uses httpRequest, telegramTrigger, openAi, googleSheets. Event-driven trigger; 42 nodes.

HTTP Request, Telegram Trigger, OpenAI +2
AI & RAG

1-Clone_Viral_TikToks_with_AI_Avatars___Auto_Post_to_9_Platforms_using_Perplexity___Blotato. Uses httpRequest, telegramTrigger, openAi, googleSheets. Event-driven trigger; 42 nodes.

HTTP Request, Telegram Trigger, OpenAI +2
AI & RAG

1-Clone_Viral_TikToks_with_AI_Avatars___Auto_Post_to_9_Platforms_using_Perplexity___Blotato. Uses httpRequest, telegramTrigger, openAi, googleSheets. Event-driven trigger; 42 nodes.

HTTP Request, Telegram Trigger, OpenAI +2