Utiliser l'IA et Google Calendar pour générer automatiquement des briefs de médias sociaux pour les réunions de vente

Avancé

Ceci est unCRM, AI Summarizationworkflow d'automatisation du domainecontenant 19 nœuds.Utilise principalement des nœuds comme Set, Html, Wait, Gmail, Merge. Envoi de rapports de réunions de vente générés automatiquement avec GPT-4, données LinkedIn et WhatsApp

Prérequis
  • Compte Google et informations d'identification Gmail API
  • Clé API OpenAI
  • Peut nécessiter les informations d'identification d'authentification de l'API cible

Catégorie

Aperçu du workflow
Visualisation des connexions entre les nœuds, avec support du zoom et du déplacement
Exporter le workflow
Copiez la configuration JSON suivante dans n8n pour importer et utiliser ce workflow
{
  "id": "PfcCFOFQlF2xlsT2",
  "meta": {
    "instanceId": "dd69efaf8212c74ad206700d104739d3329588a6f3f8381a46a481f34c9cc281",
    "templateCredsSetupCompleted": true
  },
  "name": "Auto-Generate Social Media Briefs for Sales Meetings Using AI & Google Calendar",
  "tags": [],
  "nodes": [
    {
      "id": "0fa99817-27e1-4e25-a643-7f22ce1099d2",
      "name": "Enrichir l'entreprise du participant",
      "type": "n8n-nodes-base.clearbit",
      "position": [
        900,
        400
      ],
      "parameters": {
        "domain": "{{json.domain_name}}",
        "additionalFields": {}
      },
      "credentials": {
        "clearbitApi": {
          "id": "hbibCxmRK07dTKd3",
          "name": "Clearbit account - test"
        }
      },
      "typeVersion": 1
    },
    {
      "id": "4a8985d8-0e0d-4dd4-be7e-a2d853842eb7",
      "name": "Déclencheur programmé – 5h",
      "type": "n8n-nodes-base.scheduleTrigger",
      "position": [
        -420,
        400
      ],
      "parameters": {
        "rule": {
          "interval": [
            {
              "triggerAtHour": 5
            }
          ]
        }
      },
      "typeVersion": 1.1
    },
    {
      "id": "639411ec-4cf6-4caa-b333-fc5b02d72e12",
      "name": "Initialiser le workflow",
      "type": "n8n-nodes-base.set",
      "position": [
        -200,
        400
      ],
      "parameters": {
        "fields": {
          "values": [
            {
              "name": "linkedIn_API_Key"
            },
            {
              "name": "emails"
            }
          ]
        },
        "options": {}
      },
      "typeVersion": 3.2
    },
    {
      "id": "93c5de17-7e38-4590-bd76-d4b2836971e9",
      "name": "Récupérer les réunions du jour depuis le calendrier Google",
      "type": "n8n-nodes-base.googleCalendar",
      "position": [
        20,
        400
      ],
      "parameters": {
        "limit": 150,
        "options": {
          "timeMax": "={{ $today.plus({ days: 10 }) }}",
          "timeMin": "={{ $today.minus({ days: 5 }) }}",
          "singleEvents": true
        },
        "calendar": {
          "__rl": true,
          "mode": "id",
          "value": "=abc@gmail.com"
        },
        "operation": "getAll"
      },
      "credentials": {
        "googleCalendarOAuth2Api": {
          "id": "6ldLmzzYtaqng4pw",
          "name": "Google Calendar account - test"
        }
      },
      "typeVersion": 1
    },
    {
      "id": "25033b38-0417-4484-b783-f33aba39f74e",
      "name": "Extraire les domaines email des participants",
      "type": "n8n-nodes-base.set",
      "position": [
        240,
        400
      ],
      "parameters": {
        "fields": {
          "values": [
            {
              "name": "domain_name",
              "type": "arrayValue",
              "arrayValue": "={{ $json.attendees.filter(a => !a.organizer).map(a => a.email.split('@').pop()) }}"
            },
            {
              "name": "attend_Emails",
              "type": "arrayValue",
              "arrayValue": "={{ $json.attendees.filter(a => !a.organizer).map(a => a.email) }}"
            }
          ]
        },
        "options": {}
      },
      "typeVersion": 3.2
    },
    {
      "id": "4718c1f2-2eb6-4ab1-9a55-255f735289ab",
      "name": "Boucler sur les participants",
      "type": "n8n-nodes-base.splitInBatches",
      "position": [
        460,
        400
      ],
      "parameters": {
        "options": {}
      },
      "typeVersion": 3
    },
    {
      "id": "21f81aac-27a6-4d95-8581-114444fbd330",
      "name": "Diviser les détails des participants",
      "type": "n8n-nodes-base.splitOut",
      "position": [
        680,
        400
      ],
      "parameters": {
        "include": "selectedOtherFields",
        "options": {},
        "fieldToSplitOut": "domain_name",
        "fieldsToInclude": "attend_Emails, start"
      },
      "typeVersion": 1
    },
    {
      "id": "d9b3fd55-f54a-4a8c-a503-75e2ef0e6d06",
      "name": "Attendre l'enrichissement entreprise",
      "type": "n8n-nodes-base.wait",
      "position": [
        1120,
        400
      ],
      "webhookId": "9539ad1e-57c4-4420-95a7-b94b0d53d828",
      "parameters": {},
      "typeVersion": 1.1
    },
    {
      "id": "70f9669b-ccbd-48cd-b8b3-0402708ef693",
      "name": "Vérifier le statut d'enrichissement",
      "type": "n8n-nodes-base.switch",
      "position": [
        1340,
        400
      ],
      "parameters": {
        "rules": {
          "values": [
            {
              "outputKey": "linkedin",
              "conditions": {
                "options": {
                  "version": 1,
                  "leftValue": "",
                  "caseSensitive": true,
                  "typeValidation": "strict"
                },
                "combinator": "and",
                "conditions": [
                  {
                    "id": "4f3acc06-a758-4334-abf6-ce49e44f9300",
                    "operator": {
                      "type": "boolean",
                      "operation": "true",
                      "singleValue": true
                    },
                    "leftValue": "={{ $json.linkedin.handle !== null }}",
                    "rightValue": ""
                  }
                ]
              },
              "renameOutput": true
            }
          ]
        },
        "options": {
          "allMatchingOutputs": true,
          "looseTypeValidation": false
        }
      },
      "typeVersion": 3
    },
    {
      "id": "6545f48f-701c-4276-a56f-0e0b9d595bc8",
      "name": "Récupérer les derniers posts LinkedIn",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        1560,
        400
      ],
      "parameters": {
        "url": "https://fresh-linkedin-profile-data.p.rapidapi.com/get-company-posts",
        "options": {
          "batching": {
            "batch": {
              "batchSize": 150
            }
          }
        },
        "sendQuery": true,
        "sendHeaders": true,
        "queryParameters": {
          "parameters": [
            {
              "name": "linkedin_url",
              "value": "=https://www.linkedin.com/{{ $json.linkedin.handle }}"
            },
            {
              "name": "sort_by",
              "value": "recent"
            }
          ]
        },
        "headerParameters": {
          "parameters": [
            {
              "name": "X-RapidAPI-Key",
              "value": "={{ $('Initialize Workflow').item.json.linkedInAPIKey }}"
            },
            {
              "name": "X-RapidAPI-Host",
              "value": "fresh-linkedin-profile-data.p.rapidapi.com"
            }
          ]
        }
      },
      "typeVersion": 4.1
    },
    {
      "id": "f09f953e-3ec2-4e87-8d18-6b90b14a1f9e",
      "name": "Extraire les insights clés des posts",
      "type": "n8n-nodes-base.set",
      "position": [
        1780,
        400
      ],
      "parameters": {
        "fields": {
          "values": [
            {
              "name": "linkedin_posts",
              "type": "arrayValue",
              "arrayValue": "={{ $input.item.json.data.slice(0, 10).map(d => { return { text: d.text, likes: d.num_likes, comments: d.num_comments, postedAt: d.posted } } ) }}"
            },
            {
              "name": "name",
              "stringValue": "={{ $('Check Enrichment Status').item.json.name }}"
            },
            {
              "name": "meeting",
              "type": "objectValue",
              "objectValue": "={{ $('Split Attendee Details').item.json }}"
            }
          ]
        },
        "include": "none",
        "options": {}
      },
      "typeVersion": 3.2
    },
    {
      "id": "2a8b6c8f-5964-4b07-8768-0a6cfeb1dceb",
      "name": "Résumer l'activité sociale avec IA",
      "type": "n8n-nodes-base.set",
      "position": [
        2000,
        500
      ],
      "parameters": {
        "fields": {
          "values": [
            {
              "name": "attendeeEmail",
              "stringValue": "={{ $json.meeting.attendeeEmails.find(a => a.endsWith($json.meeting.domain)) }}"
            },
            {
              "name": "startHour",
              "type": "numberValue",
              "numberValue": "={{ DateTime.fromISO($json.meeting.start.dateTime).hour }}"
            },
            {
              "name": "startMinute",
              "type": "numberValue",
              "numberValue": "={{ DateTime.fromISO($json.meeting.start.dateTime).minute }}"
            }
          ]
        },
        "include": "selected",
        "options": {},
        "includeFields": "name, html_linkedin"
      },
      "typeVersion": 3.2
    },
    {
      "id": "29d13d05-6525-4f4c-8b09-f81892ab3138",
      "name": "Formater le résumé pour email",
      "type": "n8n-nodes-base.openAi",
      "position": [
        2000,
        300
      ],
      "parameters": {
        "prompt": {
          "messages": [
            {
              "content": "=Please paste the actual JSON data (not {{ JSON.stringify($json) }}) so I can generate the summary based on the real company name and post content.\n\nOnce you provide the JSON, I’ll return a short, impersonal email-style summary focusing on key sales-relevant insights from LinkedIn posts."
            }
          ]
        },
        "options": {},
        "resource": "chat",
        "chatModel": "gpt-4",
        "requestOptions": {}
      },
      "credentials": {
        "openAiApi": {
          "id": "CDQ16eImh6D4tY15",
          "name": "OpenAi account 2 - test"
        }
      },
      "typeVersion": 1.1
    },
    {
      "id": "0a1d2f8f-99b6-41f7-b2f2-b9e9b36b9db7",
      "name": "Fusionner le résumé avec le contexte",
      "type": "n8n-nodes-base.merge",
      "disabled": true,
      "position": [
        2220,
        400
      ],
      "parameters": {
        "mode": "combine",
        "options": {},
        "combinationMode": "mergeByPosition"
      },
      "typeVersion": 2.1
    },
    {
      "id": "0d8e7b58-ce7b-4704-9a06-4a1aceddfc7d",
      "name": "Attendre avant envoi",
      "type": "n8n-nodes-base.wait",
      "position": [
        2440,
        400
      ],
      "webhookId": "a823988b-ccd5-4c08-8cea-3f6eea7dff47",
      "parameters": {
        "amount": 2
      },
      "typeVersion": 1.1
    },
    {
      "id": "e9fe48eb-8297-4023-8d89-f4bc9b38974b",
      "name": "Générer un template email HTML",
      "type": "n8n-nodes-base.html",
      "position": [
        2660,
        400
      ],
      "parameters": {
        "html": "<!DOCTYPE html>\n<html>\n<head>\n  <meta charset=\"UTF-8\" />\n  <style>\n    body {\n      font-family: sans-serif;\n      margin: 1em;\n    }\n    .summary {\n      background-color: #f7f9fc;\n      padding: 0.5em 1em;\n      border-left: 4px solid #0073e6;\n      margin-top: 0.5em;\n    }\n  </style>\n</head>\n<body>\n  <h3>Meeting with {{ $json.attendeeEmail }} at {{ $json.startHour }}:{{ $json.startMinute < 10 ? `0${$json.startMinute}` : $json.startMinute }}h</h3>\n  <p><strong>Quick summary of {{ $json.name }}'s social media activity:</strong></p>\n  <div class=\"summary\">\n    {{ $json.message.content }}\n  </div>\n</body>\n</html>\n"
      },
      "typeVersion": 1.1
    },
    {
      "id": "b12bf591-6975-4b7f-b01a-d02ccbb33243",
      "name": "Envoyer via WhatsApp",
      "type": "n8n-nodes-base.whatsApp",
      "position": [
        2880,
        300
      ],
      "webhookId": "cffafb97-667e-4e19-addc-7a902e850e88",
      "parameters": {
        "textBody": "={{ $json.html }}",
        "operation": "send",
        "phoneNumberId": "=+91993388337733",
        "additionalFields": {},
        "recipientPhoneNumber": "+9198763322444"
      },
      "credentials": {
        "whatsAppApi": {
          "id": "b0PxTDPdWzznWnfG",
          "name": "WhatsApp-test "
        }
      },
      "typeVersion": 1
    },
    {
      "id": "b033a15f-4a08-4580-863a-67c78cb9d59b",
      "name": "Envoyer via Gmail",
      "type": "n8n-nodes-base.gmail",
      "position": [
        2880,
        500
      ],
      "webhookId": "5970219d-6107-437f-b590-e0936e28b80c",
      "parameters": {
        "sendTo": "={{ $('Initialize Workflow').first().json.emails }}",
        "message": "={{ $json.html }}",
        "options": {},
        "subject": "=Latest social activity for: {{ $('Merge Summary with Context').item.json.name }}"
      },
      "credentials": {
        "gmailOAuth2": {
          "id": "PcTqvGU9uCunfltE",
          "name": "Gmail account - test"
        }
      },
      "typeVersion": 2.1
    },
    {
      "id": "551f69af-a07a-4b7a-9021-29810f9995b6",
      "name": "Note adhésive",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -80,
        -1440
      ],
      "parameters": {
        "color": 2,
        "width": 1000,
        "height": 1420,
        "content": "## Workflow Purpose (Step-by-Step)\n\n### Schedule Trigger – 5 AM\n→ Triggers the workflow automatically every morning at 5 AM.\n\n### Initialize Workflow\n→ Sets up default values or configurations needed for processing.\n\n### Fetch Today’s Meetings from Google Calendar\n→ Retrieves all meetings scheduled for the current day.\n\n### Extract Attendee Email Domains\n→ Extracts email domains of meeting attendees for company identification.\n\n### Loop Through Attendees\n→ Iterates over each attendee to perform enrichment and analysis.\n\n### Split Attendee Details\n→ Separates individual attendee data for precise processing.\n\n### Enrich Company Information\n→ Looks up company details using attendee email domains.\n\n### Wait for Company Enrichment\n→ Adds a delay to ensure enrichment API finishes before next step.\n\n### Check Enrichment Status\n→ Ensures only valid/enriched companies proceed to the next steps.\n\n### Fetch Latest LinkedIn & Twitter Posts\n→ Retrieves the most recent social media posts for the company.\n### \nExtract Key Post Insights\n→ Filters out non-relevant content and keeps business-useful data.\n\n### Summarize Social Activity with AI\n→ Uses AI to generate a short, sales-relevant summary of the posts.\n\n### Format Summary for Email\n→ Prepares the summary data in a readable format.\n\n### Merge Summary with Context\n→ Wraps summary along with attendee, time, and company info.\n\n### Wait Before Sending\n→ Optional pause to manage API rate or ensure proper timing.\n\n### Generate HTML Email Template\n→ Builds a clean, short HTML email ready to send.\n\n### Send via WhatsApp\n→ Sends the summary to WhatsApp for quick access on the go.\n\n### Send via Gmail\n→ Sends the summary to email as a professional follow-up.\n\n"
      },
      "typeVersion": 1
    }
  ],
  "active": false,
  "pinData": {},
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "85e779a0-cba0-4c00-bcf0-740f108c3032",
  "connections": {
    "b12bf591-6975-4b7f-b01a-d02ccbb33243": {
      "main": [
        []
      ]
    },
    "639411ec-4cf6-4caa-b333-fc5b02d72e12": {
      "main": [
        [
          {
            "node": "93c5de17-7e38-4590-bd76-d4b2836971e9",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "0d8e7b58-ce7b-4704-9a06-4a1aceddfc7d": {
      "main": [
        [
          {
            "node": "e9fe48eb-8297-4023-8d89-f4bc9b38974b",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "4718c1f2-2eb6-4ab1-9a55-255f735289ab": {
      "main": [
        [
          {
            "node": "21f81aac-27a6-4d95-8581-114444fbd330",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "4718c1f2-2eb6-4ab1-9a55-255f735289ab",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "21f81aac-27a6-4d95-8581-114444fbd330": {
      "main": [
        [
          {
            "node": "0fa99817-27e1-4e25-a643-7f22ce1099d2",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "70f9669b-ccbd-48cd-b8b3-0402708ef693": {
      "main": [
        [
          {
            "node": "6545f48f-701c-4276-a56f-0e0b9d595bc8",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "0fa99817-27e1-4e25-a643-7f22ce1099d2": {
      "main": [
        [
          {
            "node": "d9b3fd55-f54a-4a8c-a503-75e2ef0e6d06",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "29d13d05-6525-4f4c-8b09-f81892ab3138": {
      "main": [
        [
          {
            "node": "0a1d2f8f-99b6-41f7-b2f2-b9e9b36b9db7",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "f09f953e-3ec2-4e87-8d18-6b90b14a1f9e": {
      "main": [
        [
          {
            "node": "29d13d05-6525-4f4c-8b09-f81892ab3138",
            "type": "main",
            "index": 0
          },
          {
            "node": "2a8b6c8f-5964-4b07-8768-0a6cfeb1dceb",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "4a8985d8-0e0d-4dd4-be7e-a2d853842eb7": {
      "main": [
        [
          {
            "node": "639411ec-4cf6-4caa-b333-fc5b02d72e12",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "0a1d2f8f-99b6-41f7-b2f2-b9e9b36b9db7": {
      "main": [
        [
          {
            "node": "0d8e7b58-ce7b-4704-9a06-4a1aceddfc7d",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "6545f48f-701c-4276-a56f-0e0b9d595bc8": {
      "main": [
        [
          {
            "node": "f09f953e-3ec2-4e87-8d18-6b90b14a1f9e",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "d9b3fd55-f54a-4a8c-a503-75e2ef0e6d06": {
      "main": [
        [
          {
            "node": "70f9669b-ccbd-48cd-b8b3-0402708ef693",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "e9fe48eb-8297-4023-8d89-f4bc9b38974b": {
      "main": [
        [
          {
            "node": "b12bf591-6975-4b7f-b01a-d02ccbb33243",
            "type": "main",
            "index": 0
          },
          {
            "node": "b033a15f-4a08-4580-863a-67c78cb9d59b",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "25033b38-0417-4484-b783-f33aba39f74e": {
      "main": [
        [
          {
            "node": "4718c1f2-2eb6-4ab1-9a55-255f735289ab",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "2a8b6c8f-5964-4b07-8768-0a6cfeb1dceb": {
      "main": [
        [
          {
            "node": "0a1d2f8f-99b6-41f7-b2f2-b9e9b36b9db7",
            "type": "main",
            "index": 1
          }
        ]
      ]
    },
    "93c5de17-7e38-4590-bd76-d4b2836971e9": {
      "main": [
        [
          {
            "node": "25033b38-0417-4484-b783-f33aba39f74e",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}
Foire aux questions

Comment utiliser ce workflow ?

Copiez le code de configuration JSON ci-dessus, créez un nouveau workflow dans votre instance n8n et sélectionnez "Importer depuis le JSON", collez la configuration et modifiez les paramètres d'authentification selon vos besoins.

Dans quelles scénarios ce workflow est-il adapté ?

Avancé - CRM, Résumé IA

Est-ce payant ?

Ce workflow est entièrement gratuit et peut être utilisé directement. Veuillez noter que les services tiers utilisés dans le workflow (comme l'API OpenAI) peuvent nécessiter un paiement de votre part.

Informations sur le workflow
Niveau de difficulté
Avancé
Nombre de nœuds19
Catégorie2
Types de nœuds15
Description de la difficulté

Adapté aux utilisateurs avancés, avec des workflows complexes contenant 16+ nœuds

Auteur
Oneclick AI Squad

Oneclick AI Squad

@oneclick-ai

The AI Squad Initiative is a pioneering effort to build, automate and scale AI-powered workflows using n8n.io. Our mission is to help individuals and businesses integrate AI agents seamlessly into their daily operations from automating tasks and enhancing productivity to creating innovative, intelligent solutions. We design modular, reusable AI workflow templates that empower creators, developers and teams to supercharge their automation with minimal effort and maximum impact.

Liens externes
Voir sur n8n.io

Partager ce workflow

Catégories

Catégories: 34