Extracción de datos de tarjetas de presentación de Slack a Google Sheets con GPT-4o OCR

Intermedio

Este es unMiscellaneous, AI Summarization, Multimodal AIflujo de automatización del dominio deautomatización que contiene 10 nodos.Utiliza principalmente nodos como Slack, SplitOut, HttpRequest, GoogleSheets, SlackTrigger. Extraer datos de tarjetas de visita de Slack a Google Sheets con GPT-4o OCR

Requisitos previos
  • Bot Token de Slack o URL de Webhook
  • Pueden requerirse credenciales de autenticación para la API de destino
  • Credenciales de API de Google Sheets
  • Clave de API de OpenAI
Vista previa del flujo de trabajo
Visualización de las conexiones entre nodos, con soporte para zoom y panorámica
Exportar flujo de trabajo
Copie la siguiente configuración JSON en n8n para importar y usar este flujo de trabajo
{
  "meta": {
    "instanceId": "e04cc86c30b0cecda8e6bbc7cc41459d9bf4d76816638a14d42d636b91913ebc",
    "templateCredsSetupCompleted": true
  },
  "nodes": [
    {
      "id": "21c87864-6365-4d62-95e6-01576fb3f01d",
      "name": "Slack Trigger",
      "type": "n8n-nodes-base.slackTrigger",
      "position": [
        -496,
        0
      ],
      "webhookId": "82952e59-1102-42c9-811e-db9c35954466",
      "parameters": {
        "options": {},
        "trigger": [
          "message"
        ],
        "channelId": {
          "__rl": true,
          "mode": "list",
          "value": "C09DW6Q03T8",
          "cachedResultName": "card"
        }
      },
      "credentials": {
        "slackApi": {
          "id": "VLK4L2mMCF7UFZXF",
          "name": "Slack account 4"
        }
      },
      "notesInFlow": false,
      "typeVersion": 1
    },
    {
      "id": "bd53e180-a97f-4ffc-af2e-e95408c52fbf",
      "name": "Agregar fila en hoja",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        528,
        0
      ],
      "parameters": {
        "columns": {
          "value": {
            "Name": "={{ $json.output['full names'] }}",
            "Email": "={{ $json.output.email }}",
            "Phone": "={{ $json.output['phone numbers'] }}",
            "Company": "={{ $json.output['company names'] }}",
            "Job Title": "={{ $json.output['job titles'] }}"
          },
          "schema": [
            {
              "id": "Name",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "Name",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Company",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "Company",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Job Title",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "Job Title",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Phone",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "Phone",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Email",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "Email",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            }
          ],
          "mappingMode": "defineBelow",
          "matchingColumns": [],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        },
        "options": {},
        "operation": "append",
        "sheetName": {
          "__rl": true,
          "mode": "list",
          "value": "gid=0",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1NEmgb1BU706kR4k-H2e3L6T8AnUPxFsNzkQZNhVAP90/edit#gid=0",
          "cachedResultName": "総合リスト"
        },
        "documentId": {
          "__rl": true,
          "mode": "list",
          "value": "1NEmgb1BU706kR4k-H2e3L6T8AnUPxFsNzkQZNhVAP90",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1NEmgb1BU706kR4k-H2e3L6T8AnUPxFsNzkQZNhVAP90/edit?usp=drivesdk",
          "cachedResultName": "名刺リスト"
        }
      },
      "credentials": {
        "googleSheetsOAuth2Api": {
          "id": "OADOUEa3B96W0iqk",
          "name": "Google Sheets account 2"
        }
      },
      "typeVersion": 4.7
    },
    {
      "id": "c0881266-4f48-47e4-9da9-5a9c15c019f4",
      "name": "Transformar datos",
      "type": "n8n-nodes-base.splitOut",
      "position": [
        304,
        0
      ],
      "parameters": {
        "include": "allOtherFields",
        "options": {},
        "fieldToSplitOut": "output"
      },
      "typeVersion": 1
    },
    {
      "id": "8183cd9c-512f-4f5c-aaa6-6897a89e1fb7",
      "name": "Enviar un mensaje",
      "type": "n8n-nodes-base.slack",
      "position": [
        752,
        0
      ],
      "webhookId": "c67bd6d3-d8d3-41ec-b12f-f4ee57b536d0",
      "parameters": {
        "text": "=---\nName: {{ $json.Name }}\nTitle: {{ $json['Job Title']}}\nCompany: {{ $json.Company }}\nPhone: {{ $json.Phone }}\nEmail: {{ $json.Email }}",
        "select": "channel",
        "channelId": {
          "__rl": true,
          "mode": "list",
          "value": "C09DW6Q03T8",
          "cachedResultName": "card"
        },
        "otherOptions": {}
      },
      "credentials": {
        "slackApi": {
          "id": "VLK4L2mMCF7UFZXF",
          "name": "Slack account 4"
        }
      },
      "typeVersion": 2.3
    },
    {
      "id": "59ea6f4b-f9c4-4873-856e-356599ae22ea",
      "name": "Estructurar salida",
      "type": "@n8n/n8n-nodes-langchain.outputParserStructured",
      "position": [
        96,
        224
      ],
      "parameters": {
        "jsonSchemaExample": "[{\n\t\"full names\": \"Toshiki Hirao\",\n\t\"job titles\": \"CEO\",\n  \"company names\": \"dTosh\",\n  \"phone numbers\": \"012-3456-938\",\n  \"email\": \"xxx@yyy.jp\"\n}]"
      },
      "typeVersion": 1.3
    },
    {
      "id": "8ca7e36b-2066-4a45-b09b-de49648111c5",
      "name": "Modelo de IA",
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "position": [
        -48,
        224
      ],
      "parameters": {
        "model": {
          "__rl": true,
          "mode": "list",
          "value": "gpt-4o",
          "cachedResultName": "gpt-4o"
        },
        "options": {}
      },
      "credentials": {
        "openAiApi": {
          "id": "in4FUooE7goQS8l0",
          "name": "OpenAi account 2"
        }
      },
      "typeVersion": 1.2
    },
    {
      "id": "7153c21f-d2d7-455d-9d88-a3cb4b1a20c2",
      "name": "Nota adhesiva",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1040,
        -48
      ],
      "parameters": {
        "width": 448,
        "height": 880,
        "content": "## How it works\n1. Slack Trigger – The workflow starts when a business card photo is uploaded to Slack.\n2. HTTP Request – The uploaded image is fetched from Slack.\n3. AI/OCR Parsing – The card image is analyzed by an AI model and structured into contact fields (name, company, email, phone, etc.).\n4. Transform Data – The extracted data is cleaned and mapped into the correct format.\n5. Google Sheets – A new row is appended to your designated Google Sheet, creating an organized contact database.\n6. Slack Notification – Finally, a confirmation message is sent back to Slack to let you know the contact has been successfully saved.\n\n## How to use\n1. Copy the template into your n8n instance.\n2. Connect your Slack account to capture uploaded images.\n3. Set up your Google Sheets connection and choose the spreadsheet where contacts should be stored.\n4. Adjust the Contact Information extraction node if you want to capture custom fields (e.g., job title, address).\n5. Deploy and test: upload a business card image in Slack and confirm it’s added to Google Sheets automatically.\n\n## Requirements\n1. n8n running (cloud).\n2. A Slack account with access to the channel where photos will be uploaded.\n3. A Google Sheets account with a target sheet prepared for storing contacts.\n4. AI/OCR capability enabled in your n8n (e.g., OpenAI, Google Vision, or another OCR/LLM provider).\n5. Basic access rights in both Slack and Google Sheets to read and write data."
      },
      "typeVersion": 1
    },
    {
      "id": "2b3d9219-4616-4a95-b255-dbb1eab2ffd3",
      "name": "Nota adhesiva1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1040,
        -272
      ],
      "parameters": {
        "width": 608,
        "height": 192,
        "content": "## Scan Business Cards in Slack to Google Sheets\n\nYou can turn messy business card photos into organized contact data automatically.\nWith this workflow, you can upload a business card photo to Slack and instantly capture the contact details into Google Sheets using OCR. No more manual typing—each new card is scanned, structured, saved, and confirmed back in Slack, making contact management fast and effortless."
      },
      "typeVersion": 1
    },
    {
      "id": "2e313bd5-2046-4ed0-a521-d28dc962b0b9",
      "name": "Obtener imágenes",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        -272,
        0
      ],
      "parameters": {
        "url": "={{ $json.files[0].url_private_download }}",
        "options": {
          "response": {
            "response": {
              "responseFormat": "file"
            }
          }
        },
        "authentication": "predefinedCredentialType",
        "nodeCredentialType": "slackApi"
      },
      "credentials": {
        "slackApi": {
          "id": "VLK4L2mMCF7UFZXF",
          "name": "Slack account 4"
        }
      },
      "typeVersion": 4.2
    },
    {
      "id": "3d8e76d9-9bcb-4e52-ac45-b560d9086e47",
      "name": "Escanear información de contacto",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        -48,
        0
      ],
      "parameters": {
        "text": "Please identify and extract all professional contact information from the image containing several business cards. You have to include details that are full names, job titles, company names, phone numbers, and email addresses.",
        "options": {
          "systemMessage": "You assist sales/BD teams by parsing images with several business cards. Identify every card and pull the essentials—full names, job titles, companies, phone numbers, and emails."
        },
        "promptType": "define",
        "hasOutputParser": true
      },
      "typeVersion": 2.1
    }
  ],
  "pinData": {},
  "connections": {
    "8ca7e36b-2066-4a45-b09b-de49648111c5": {
      "ai_languageModel": [
        [
          {
            "node": "3d8e76d9-9bcb-4e52-ac45-b560d9086e47",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "2e313bd5-2046-4ed0-a521-d28dc962b0b9": {
      "main": [
        [
          {
            "node": "3d8e76d9-9bcb-4e52-ac45-b560d9086e47",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "21c87864-6365-4d62-95e6-01576fb3f01d": {
      "main": [
        [
          {
            "node": "2e313bd5-2046-4ed0-a521-d28dc962b0b9",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "8183cd9c-512f-4f5c-aaa6-6897a89e1fb7": {
      "main": [
        []
      ]
    },
    "59ea6f4b-f9c4-4873-856e-356599ae22ea": {
      "ai_outputParser": [
        [
          {
            "node": "3d8e76d9-9bcb-4e52-ac45-b560d9086e47",
            "type": "ai_outputParser",
            "index": 0
          }
        ]
      ]
    },
    "c0881266-4f48-47e4-9da9-5a9c15c019f4": {
      "main": [
        [
          {
            "node": "bd53e180-a97f-4ffc-af2e-e95408c52fbf",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "bd53e180-a97f-4ffc-af2e-e95408c52fbf": {
      "main": [
        [
          {
            "node": "8183cd9c-512f-4f5c-aaa6-6897a89e1fb7",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "3d8e76d9-9bcb-4e52-ac45-b560d9086e47": {
      "main": [
        [
          {
            "node": "c0881266-4f48-47e4-9da9-5a9c15c019f4",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}
Preguntas frecuentes

¿Cómo usar este flujo de trabajo?

Copie el código de configuración JSON de arriba, cree un nuevo flujo de trabajo en su instancia de n8n y seleccione "Importar desde JSON", pegue la configuración y luego modifique la configuración de credenciales según sea necesario.

¿En qué escenarios es adecuado este flujo de trabajo?

Intermedio - Varios, Resumen de IA, IA Multimodal

¿Es de pago?

Este flujo de trabajo es completamente gratuito, puede importarlo y usarlo directamente. Sin embargo, tenga en cuenta que los servicios de terceros utilizados en el flujo de trabajo (como la API de OpenAI) pueden requerir un pago por su cuenta.

Flujos de trabajo relacionados recomendados

Información del flujo de trabajo
Nivel de dificultad
Intermedio
Número de nodos10
Categoría3
Tipos de nodos9
Descripción de la dificultad

Adecuado para usuarios con experiencia intermedia, flujos de trabajo de complejidad media con 6-15 nodos

Autor
Toshiki Hirao

Toshiki Hirao

@hirao

dTosh Inc., CEO Nara Institute of Science and Technology, Assistant Professor

Enlaces externos
Ver en n8n.io

Compartir este flujo de trabajo

Categorías

Categorías: 34