Génération automatisée de propositions commerciales IA de Google Sheets vers Google Docs
Ceci est unDocument Extraction, Multimodal AIworkflow d'automatisation du domainecontenant 16 nœuds.Utilise principalement des nœuds comme Code, GoogleDocs, GoogleDrive, Agent, GoogleSheetsTrigger. Utiliser GPT-4o, Google Sheets et Google Docs pour générer des propositions commerciales
- •Informations d'identification Google Drive API
- •Informations d'identification Google Sheets API
- •Clé API OpenAI
Nœuds utilisés (16)
{
"id": "Lim9HD2pvEN6vAIe",
"meta": {
"instanceId": "8443f10082278c46aa5cf3acf8ff0f70061a2c58bce76efac814b16290845177",
"templateCredsSetupCompleted": true
},
"name": "Generate AI-Powered Business Proposals from Google Sheets to Google Docs Automatically",
"tags": [],
"nodes": [
{
"id": "27862039-1480-43c0-a29b-e96940aad676",
"name": "Aperçu du workflow",
"type": "n8n-nodes-base.stickyNote",
"position": [
-1440,
-224
],
"parameters": {
"color": 5,
"width": 386,
"height": 576,
"content": "## 🎯 AI-Powered Proposal Generator Workflow\n\n**Purpose:** Automatically generates professional business proposals from Google Sheets data using AI\n\n**Key Features:**\n- Triggers on new Google Sheets rows\n- Uses OpenAI GPT-4o for intelligent content generation\n- Structured output with JSON schema validation\n- Automated Google Docs population\n- File management and archiving\n\n**Use Case:** Perfect for agencies generating client proposals at scale\n\n**Requirements:**\n- Google Sheets with columns: clientName, jobDescription\n- Google Docs template with placeholders\n- OpenAI API key\n- Google Drive folder for output\n\n**Flow:** Trigger → Process → Generate → Populate → Download → Archive → Reset"
},
"typeVersion": 1
},
{
"id": "370827ff-0b85-4489-92bc-23dbc5182112",
"name": "Instructions de déclenchement",
"type": "n8n-nodes-base.stickyNote",
"position": [
-1040,
-272
],
"parameters": {
"width": 280,
"height": 288,
"content": "## 📥 Step 1: Trigger Setup\n\n**Configure your Google Sheet:**\n- Column A: `clientName`\n- Column B: `jobDescription`\n\n**Replace with YOUR Sheet ID** (don't use hardcoded IDs in templates)\n\n**Polling:** Checks every minute for new rows"
},
"typeVersion": 1
},
{
"id": "1393c26b-8979-4df5-b577-55f54f4d6517",
"name": "Guide de filtrage des données",
"type": "n8n-nodes-base.stickyNote",
"position": [
-784,
176
],
"parameters": {
"width": 280,
"height": 232,
"content": "## 🔄 Step 2: Data Processing\n\n**Purpose:** Filters only the last appended row\n\n**Why?** Google Sheets trigger may return multiple rows. This ensures we process only the newest entry."
},
"typeVersion": 1
},
{
"id": "5cccf135-cd79-4a6c-a286-f9cd41a9367b",
"name": "Guide des composants IA",
"type": "n8n-nodes-base.stickyNote",
"position": [
-416,
-352
],
"parameters": {
"width": 320,
"height": 364,
"content": "## 🤖 Step 3: AI Generation\n\n**Components:**\n- **Agent:** Orchestrates the generation\n- **Memory:** Maintains context per client\n- **Parser:** Ensures JSON output format\n- **Model:** GPT-4o (temperature: 0.7)\n\n**Output Fields:**\n- Executive Summary\n- Scope of Work (formatted)\n- 4-month costing breakdown\n- Timeline & Conclusion\n\n**Customize:** Adjust system prompt for your brand voice"
},
"typeVersion": 1
},
{
"id": "76079566-7068-4264-902f-4972027a4b04",
"name": "Guide de configuration du document",
"type": "n8n-nodes-base.stickyNote",
"position": [
32,
208
],
"parameters": {
"width": 300,
"height": 432,
"content": "## 📝 Step 4: Document Population\n\n**Setup Required:**\n1. Create Google Docs template\n2. Add placeholders: `{{executive_summary}}`, `{{scope_of_work}}`, etc.\n3. Replace Document ID in node settings\n\n**Placeholders:**\n- `{{executive_summary}}`\n- `{{scope_of_work}}`\n- `{{month1_focus}}` to `{{month4_focus}}`\n- `{{month1_cost}}` to `{{month4_cost}}`\n- `{{total_cost}}`\n- `{{timeline}}`\n- `{{conclusion}}`"
},
"typeVersion": 1
},
{
"id": "4c21284b-9934-48d5-9c24-f6f966c907aa",
"name": "Guide des opérations sur fichiers",
"type": "n8n-nodes-base.stickyNote",
"position": [
352,
-304
],
"parameters": {
"width": 280,
"height": 320,
"content": "## 💾 Step 5: File Management\n\n**Process:**\n1. Download populated document as PDF\n2. Upload to designated Drive folder\n3. Reset template for next use\n\n**Configure:**\n- Set your output folder ID\n- Customize file naming (optional)"
},
"typeVersion": 1
},
{
"id": "6701d2dc-21f8-418a-96ce-77fe5941e956",
"name": "Mémoire : Contexte client",
"type": "@n8n/n8n-nodes-langchain.memoryBufferWindow",
"position": [
-288,
256
],
"parameters": {
"sessionKey": "=\"proposal_\" + $('Trigger: New Sheet Row').item.json.clientName",
"sessionIdType": "customKey"
},
"typeVersion": 1.3
},
{
"id": "464cf18b-ed47-41a4-8075-5b0aee4c1ff2",
"name": "Agent IA : Générer une proposition",
"type": "@n8n/n8n-nodes-langchain.agent",
"position": [
-368,
32
],
"parameters": {
"text": "=Job Description:\n{{ $json.jobDescription }}\n\nClient Name:\n{{ $json.clientName }}\n\nTask:\nGenerate a complete, professional business proposal for {{ $json.clientName }} based on the job description above.\n\nRequirements:\n✓ Analyze the job requirements carefully\n✓ Create a tailored executive summary (150-250 words)\n✓ Develop 4-6 detailed scope of work sections with specific deliverables\n✓ Provide realistic 4-month cost breakdown in INR (format: ₹XX,XXX)\n✓ Include implementation timeline description\n✓ Write a professional conclusion with contact details\n\nGenerate the proposal content now in the exact JSON format specified.",
"options": {
"systemMessage": "=You are an expert proposal writer for [YOUR COMPANY NAME].\n\nYou will generate complete, professional proposal content for a Google Docs template.\n\nThe Google Doc has these sections:\n- Executive Summary\n- Scope Of Work\n- Costing (table format)\n- Timeline\n- Conclusion\n\nStyle Guidelines:\n✓ Professional, confident, and persuasive tone\n✓ Clear and concise language suitable for business proposals\n✓ Match the style and format of professional SEO/development proposals\n✓ Use proper formatting that renders correctly in Google Docs\n\nCRITICAL FORMATTING RULES:\n\n1. **Executive Summary** (2-3 paragraphs, 150-250 words):\n - Write flowing paragraphs separated by blank lines\n - No bullets or numbers\n - Professional, engaging introduction\n\n2. **Scope of Work** (4-6 main sections):\n - Format EXACTLY like this:\n \n 1. Section Title\n ● First deliverable point\n ● Second deliverable point\n ● Third deliverable point\n \n 2. Next Section Title\n ● First deliverable point\n ● Second deliverable point\n \n - Use actual bullet character: ●\n - Add blank line between sections\n - Each bullet should be a complete, clear deliverable\n - 3-6 bullets per section\n\n3. **Costing** - Generate as separate fields:\n - month1_focus: Brief description (e.g., \"Technical SEO + Setup\")\n - month1_cost: Amount with ₹ symbol (e.g., \"₹1,50,000\")\n - Repeat for months 2, 3, 4\n - total_cost: Total amount\n\n4. **Timeline** (2-3 sentences, 100-150 words):\n - Describe the 4-month execution plan\n - Professional paragraph format\n - Mention structured delivery and communication\n\n5. **Conclusion** (60-100 words):\n - Professional closing paragraph\n - Express eagerness to collaborate\n - Include contact: [YOUR_EMAIL], [YOUR_PHONE]\n - Mention proposal validity: 30 days\n\nOUTPUT FORMAT:\nReturn ONLY valid JSON with these exact fields:\n{\n \"executive_summary\": \"Paragraph 1 text here.\\n\\nParagraph 2 text here.\\n\\nParagraph 3 text here.\",\n \"scope_of_work\": \"1. Section Title\\n● Deliverable one\\n● Deliverable two\\n● Deliverable three\\n\\n2. Next Section\\n● Deliverable one\\n● Deliverable two\",\n \"month1_focus\": \"Focus area description\",\n \"month1_cost\": \"₹X,XX,XXX\",\n \"month2_focus\": \"Focus area description\",\n \"month2_cost\": \"₹X,XX,XXX\",\n \"month3_focus\": \"Focus area description\",\n \"month3_cost\": \"₹X,XX,XXX\",\n \"month4_focus\": \"Focus area description\",\n \"month4_cost\": \"₹X,XX,XXX\",\n \"total_cost\": \"₹X,XX,XXX\",\n \"timeline\": \"Timeline description paragraph.\",\n \"conclusion\": \"Closing paragraph with contact details.\"\n}\n\nIMPORTANT:\n- Use \\n for single line break\n- Use \\n\\n for paragraph break\n- Use actual ● character for bullets (not asterisk or dash)\n- Never use markdown formatting\n- Ensure costs are realistic for 4-month engagements (₹1,20,000 - ₹7,00,000 range)\n- Match the professional tone of the reference SEO proposal"
},
"promptType": "define",
"hasOutputParser": true
},
"typeVersion": 2.1
},
{
"id": "fe0185ea-bd06-4a26-9299-5e0a107721ee",
"name": "Déclencheur : Nouvelle ligne de feuille",
"type": "n8n-nodes-base.googleSheetsTrigger",
"position": [
-864,
32
],
"parameters": {
"options": {},
"pollTimes": {
"item": [
{
"mode": "everyMinute"
}
]
},
"sheetName": {
"__rl": true,
"mode": "list",
"value": "gid=0",
"cachedResultName": "Sheet1"
},
"documentId": {
"__rl": true,
"mode": "list",
"value": "YOUR_GOOGLE_SHEET_ID",
"cachedResultName": "Proposal Input Sheet"
}
},
"typeVersion": 1
},
{
"id": "f7977e27-0016-4c9b-b4b4-da5bc31a5e5f",
"name": "Modèle : GPT-4o",
"type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
"position": [
-416,
256
],
"parameters": {
"model": {
"__rl": true,
"mode": "list",
"value": "gpt-4o",
"cachedResultName": "gpt-4o"
},
"options": {
"temperature": 0.7
}
},
"typeVersion": 1.2
},
{
"id": "c70c2f9e-e563-475d-91f4-c40fc2170681",
"name": "Analyseur : Sortie JSON",
"type": "@n8n/n8n-nodes-langchain.outputParserStructured",
"position": [
-160,
256
],
"parameters": {
"jsonSchemaExample": "{\n \"executive_summary\": \"Professional summary paragraph\",\n \"scope_of_work\": \"1. Section\\\\n● Item\\\\n● Item\\\\n\\\\n2. Section\\\\n● Item\",\n \"month1_focus\": \"Discovery & Planning\",\n \"month1_cost\": \"₹1,50,000\",\n \"month2_focus\": \"Development\",\n \"month2_cost\": \"₹2,00,000\",\n \"month3_focus\": \"Integration\",\n \"month3_cost\": \"₹1,80,000\",\n \"month4_focus\": \"Deployment\",\n \"month4_cost\": \"₹1,70,000\",\n \"total_cost\": \"₹7,00,000\",\n \"timeline\": \"Timeline description\",\n \"conclusion\": \"Closing with contact info\"\n }"
},
"typeVersion": 1.3
},
{
"id": "fc54a244-22a4-4149-b63b-022dc7b8471a",
"name": "Remplissage : Modèle de document",
"type": "n8n-nodes-base.googleDocs",
"position": [
64,
32
],
"parameters": {
"actionsUi": {
"actionFields": [
{
"text": "{{executive_summary}}",
"action": "replaceAll",
"replaceText": "={{ $json.output.executive_summary }}"
},
{
"text": "{{scope_of_work}}",
"action": "replaceAll",
"replaceText": "={{ $json.output.scope_of_work }}"
},
{
"text": "{{timeline}}",
"action": "replaceAll",
"replaceText": "={{ $json.output.timeline }}"
},
{
"text": "{{conclusion}}",
"action": "replaceAll",
"replaceText": "={{ $json.output.conclusion }}"
},
{
"text": "{{month1_focus}}",
"action": "replaceAll",
"replaceText": "={{ $json.output.month1_focus }}"
},
{
"text": "{{month1_cost}}",
"action": "replaceAll",
"replaceText": "={{ $json.output.month1_cost }}"
},
{
"text": "{{month2_focus}}",
"action": "replaceAll",
"replaceText": "={{ $json.output.month2_focus }}"
},
{
"text": "{{month2_cost}}",
"action": "replaceAll",
"replaceText": "={{ $json.output.month2_cost }}"
},
{
"text": "{{month3_focus}}",
"action": "replaceAll",
"replaceText": "={{ $json.output.month3_focus }}"
},
{
"text": "{{month3_cost}}",
"action": "replaceAll",
"replaceText": "={{ $json.output.month3_cost }}"
},
{
"text": "{{month4_focus}}",
"action": "replaceAll",
"replaceText": "={{ $json.output.month4_focus }}"
},
{
"text": "{{month4_cost}}",
"action": "replaceAll",
"replaceText": "={{ $json.output.month4_cost }}"
},
{
"text": "{{total_cost}}",
"action": "replaceAll",
"replaceText": "={{ $json.output.total_cost }}"
}
]
},
"operation": "update",
"documentURL": "YOUR_TEMPLATE_DOCUMENT_ID"
},
"typeVersion": 2
},
{
"id": "686245ec-056d-47de-a147-ce81478c9db7",
"name": "Téléchargement : Proposition finalisée",
"type": "n8n-nodes-base.googleDrive",
"position": [
288,
32
],
"parameters": {
"fileId": {
"__rl": true,
"mode": "id",
"value": "={{ $json.documentId }}"
},
"options": {},
"operation": "download"
},
"typeVersion": 3
},
{
"id": "91212aab-6097-471b-83fb-beeec786381a",
"name": "Archivage : Sauvegarde sur Drive",
"type": "n8n-nodes-base.googleDrive",
"position": [
512,
32
],
"parameters": {
"name": "={{ $('Trigger: New Sheet Row').item.json.clientName + '_Proposal_' + $now.format('yyyy-MM-dd') }}",
"driveId": {
"__rl": true,
"mode": "list",
"value": "My Drive"
},
"options": {},
"folderId": {
"__rl": true,
"mode": "list",
"value": "YOUR_OUTPUT_FOLDER_ID",
"cachedResultUrl": "https://drive.google.com/drive/folders/",
"cachedResultName": "Proposals Output"
}
},
"typeVersion": 3
},
{
"id": "aecc7cee-e436-4813-ac5c-c8cd86bf7d12",
"name": "Réinitialisation : Espaces réservés du modèle",
"type": "n8n-nodes-base.googleDocs",
"position": [
736,
32
],
"parameters": {
"actionsUi": {
"actionFields": [
{
"text": "={{ $('AI Agent: Generate Proposal').item.json.output.executive_summary }}",
"action": "replaceAll",
"replaceText": "{{executive_summary}}"
},
{
"text": "={{ $('AI Agent: Generate Proposal').item.json.output.scope_of_work }}",
"action": "replaceAll",
"replaceText": "{{scope_of_work}}"
},
{
"text": "={{ $('AI Agent: Generate Proposal').item.json.output.timeline }}",
"action": "replaceAll",
"replaceText": "{{timeline}}"
},
{
"text": "={{ $('AI Agent: Generate Proposal').item.json.output.conclusion }}",
"action": "replaceAll",
"replaceText": "{{conclusion}}"
},
{
"text": "={{ $('AI Agent: Generate Proposal').item.json.output.month1_focus }}",
"action": "replaceAll",
"replaceText": "{{month1_focus}}"
},
{
"text": "={{ $('AI Agent: Generate Proposal').item.json.output.month1_cost }}",
"action": "replaceAll",
"replaceText": "{{month1_cost}}"
},
{
"text": "={{ $('AI Agent: Generate Proposal').item.json.output.month2_focus }}",
"action": "replaceAll",
"replaceText": "{{month2_focus}}"
},
{
"text": "={{ $('AI Agent: Generate Proposal').item.json.output.month2_cost }}",
"action": "replaceAll",
"replaceText": "{{month2_cost}}"
},
{
"text": "={{ $('AI Agent: Generate Proposal').item.json.output.month3_focus }}",
"action": "replaceAll",
"replaceText": "{{month3_focus}}"
},
{
"text": "={{ $('AI Agent: Generate Proposal').item.json.output.month3_cost }}",
"action": "replaceAll",
"replaceText": "{{month3_cost}}"
},
{
"text": "={{ $('AI Agent: Generate Proposal').item.json.output.month4_focus }}",
"action": "replaceAll",
"replaceText": "{{month4_focus}}"
},
{
"text": "={{ $('AI Agent: Generate Proposal').item.json.output.month4_cost }}",
"action": "replaceAll",
"replaceText": "{{month4_cost}}"
},
{
"text": "={{ $('AI Agent: Generate Proposal').item.json.output.total_cost }}",
"action": "replaceAll",
"replaceText": "{{total_cost}}"
}
]
},
"operation": "update",
"documentURL": "YOUR_TEMPLATE_DOCUMENT_ID"
},
"typeVersion": 2
},
{
"id": "aff26737-275a-4c7f-9c59-8df2d196d1b4",
"name": "Filtre : Dernière ligne uniquement",
"type": "n8n-nodes-base.code",
"position": [
-640,
32
],
"parameters": {
"jsCode": "// Filter to process only the last appended row\nconst items = $input.all();\n\nif (!items || items.length === 0) {\n return [];\n}\n\n// Get the most recent entry\nconst lastItem = items[items.length - 1];\n\n// Return as single-item array\nreturn [{ json: lastItem.json }];"
},
"typeVersion": 2
}
],
"active": false,
"pinData": {},
"settings": {
"executionOrder": "v1"
},
"versionId": "2140343a-e97e-4439-befe-225b63a8595d",
"connections": {
"f7977e27-0016-4c9b-b4b4-da5bc31a5e5f": {
"ai_languageModel": [
[
{
"node": "464cf18b-ed47-41a4-8075-5b0aee4c1ff2",
"type": "ai_languageModel",
"index": 0
}
]
]
},
"c70c2f9e-e563-475d-91f4-c40fc2170681": {
"ai_outputParser": [
[
{
"node": "464cf18b-ed47-41a4-8075-5b0aee4c1ff2",
"type": "ai_outputParser",
"index": 0
}
]
]
},
"91212aab-6097-471b-83fb-beeec786381a": {
"main": [
[
{
"node": "aecc7cee-e436-4813-ac5c-c8cd86bf7d12",
"type": "main",
"index": 0
}
]
]
},
"6701d2dc-21f8-418a-96ce-77fe5941e956": {
"ai_memory": [
[
{
"node": "464cf18b-ed47-41a4-8075-5b0aee4c1ff2",
"type": "ai_memory",
"index": 0
}
]
]
},
"fe0185ea-bd06-4a26-9299-5e0a107721ee": {
"main": [
[
{
"node": "aff26737-275a-4c7f-9c59-8df2d196d1b4",
"type": "main",
"index": 0
}
]
]
},
"aff26737-275a-4c7f-9c59-8df2d196d1b4": {
"main": [
[
{
"node": "464cf18b-ed47-41a4-8075-5b0aee4c1ff2",
"type": "main",
"index": 0
}
]
]
},
"464cf18b-ed47-41a4-8075-5b0aee4c1ff2": {
"main": [
[
{
"node": "fc54a244-22a4-4149-b63b-022dc7b8471a",
"type": "main",
"index": 0
}
]
]
},
"fc54a244-22a4-4149-b63b-022dc7b8471a": {
"main": [
[
{
"node": "686245ec-056d-47de-a147-ce81478c9db7",
"type": "main",
"index": 0
}
]
]
},
"686245ec-056d-47de-a147-ce81478c9db7": {
"main": [
[
{
"node": "91212aab-6097-471b-83fb-beeec786381a",
"type": "main",
"index": 0
}
]
]
}
}
}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é - Extraction de documents, IA Multimodale
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.
Workflows recommandés
Rahul Joshi
@rahul08Rahul Joshi is a seasoned technology leader specializing in the n8n automation tool and AI-driven workflow automation. With deep expertise in building open-source workflow automation and self-hosted automation platforms, he helps organizations eliminate manual processes through intelligent n8n ai agent automation solutions.
Partager ce workflow