Skip to main content

Save business card contacts from LINE photos to Google Sheets using Gemini

Workflow preview

Workflow preview
100%
Save business card contacts from LINE photos to Google Sheets using Gemini preview
Open on n8n.io

1. Workflow Overview

Save business card contacts from LINE photos to Google Sheets with Gemini Who is this for Sales professionals, account managers, and anyone who exchanges business cards regularly. Designed especial...

Best for

  • Document Extraction automation workflows
  • AI Summarization automation workflows
  • advanced n8n builders looking for reusable templates

Tools used

n8n-nodes-base.stickynote, n8n-nodes-base.set, n8n-nodes-base.webhook, n8n-nodes-base.if, n8n-nodes-base.httprequest, n8n-nodes-base.code, @n8n/n8n-nodes-langchain.lmchatgooglegemini, @n8n/n8n-nodes-langchain.chainllm

Source and attribution

This workflow is cataloged by N8N Workflows and links back to its original n8n.io source page by TakatoYamada.

Original n8n.io source

1.1 Workflow description

Title
Save business card contacts from LINE photos to Google Sheets using Gemini
Workflow name
Save business card contacts from LINE photos to Google Sheets using Gemini

Save business card contacts from LINE photos to Google Sheets with Gemini


Who is this for

Sales professionals, account managers, and anyone who exchanges business cards regularly. Designed especially for LINE users (Japan, Taiwan, Thailand, etc.) who want to eliminate manual data entry after networking events or client meetings.

What this workflow does

When a user sends a business card photo to a LINE bot, Gemini AI automatically extracts contact information (name, company, job title, phone number, email, postal address) and saves it to Google Sheets. Duplicate entries are detected by email address and skipped automatically. The team receives a Slack notification for every new contact, and the user gets an instant LINE confirmation.

How to set up

  1. Create a LINE Messaging API channel and obtain a Channel Access Token
  2. Prepare a Google Sheet with columns: Timestamp, Name, Company, Title, Phone, Email, Address, LINE_UID
  3. Get a Google Gemini API key from Google AI Studio
  4. Set up a Slack Incoming Webhook URL
  5. Enter all credentials in the Set Configuration Parameters node
  6. Register the n8n Webhook URL in LINE Developer Console

Requirements

  • LINE Messaging API account (free tier available)
  • Google Sheets (any Google account)
  • Google Gemini API key (free tier available)
  • Slack workspace with Incoming Webhooks enabled

How to customize

Adjust Google Sheets columns to match your CRM fields. Add a HubSpot or Salesforce node after the Sheets node to sync contacts directly to your CRM. Replace Slack with Microsoft Teams or Discord for team notifications.


Node List

# Node Name Type Role
1 Set Configuration Parameters Set Centralizes all credentials and config values
2 When LINE Event Received Webhook Receives LINE Webhook events (POST)
3 If Image Message If Checks whether the message contains an image
4 Fetch Image from LINE API HTTP Request Downloads image from LINE Content API
5 Encode Image as Base64 Code Converts image binary to Base64 string
6 Setup Gemini for Card Data Gemini Chat Model Gemini 1.5 Flash model definition
7 Extract Card Info with Gemini LLM Chain Extracts contact info from card image as JSON
8 Parse Gemini Output Data Code Parses Gemini response into structured data
9 Read Contacts from Sheets Google Sheets Searches existing records by email address
10 If Contact Exists If Checks whether a duplicate record exists
11 Append Contact to Sheets Google Sheets Appends new contact to Google Sheets
12 Post New Contact to Slack HTTP Request Sends Slack notification for new contact
13 Send Success Reply via LINE HTTP Request Sends registration confirmation via LINE
14 Send Duplicate Reply via LINE HTTP Request Sends duplicate notification via LINE
15 Respond Not Image to LINE Respond to Webhook Responds to non-image messages
16 Acknowledge OK Webhook Respond to Webhook Returns HTTP 200 on success
17 Acknowledge Duplicate Webhook Respond to Webhook Returns HTTP 200 on duplicate

Total: 17 nodes (+ 8 Sticky Notes)


Sticky Note Compliance

# Sticky Note Title Color Role
1 Main Sticky Note (Overview) Yellow Workflow overview, How it works, Setup steps, Customization
2 Configuration setup White Covers credentials and config
3 Webhook event handling White Covers LINE webhook reception and image check
4 Image download and conversion White Covers image fetch and Base64 encoding
5 Card data extraction White Covers Gemini extraction and parsing
6 Duplicate check and contact saving White Covers Sheets read/write and duplicate logic
7 Messaging and webhook response White Covers Slack post, LINE replies, and webhook responses
8 Gemini configuration White Covers Gemini model setup

All sticky notes use H2 headings (## ) and follow n8n public guidelines.


Setup Guide

1. Create a LINE Messaging API channel

  1. Log in to LINE Developers Console
  2. Create a new provider (or select an existing one)
  3. Create a Messaging API channel
  4. Issue a long-lived Channel Access Token and copy it
  5. Set the Webhook URL after configuring n8n

2. Prepare Google Sheets

  1. Create a new spreadsheet
  2. Add the following headers in row 1:
A B C D E F G H
Timestamp Name Company Title Phone Email Address LINE_UID
  1. Copy the spreadsheet ID from the URL (between /d/ and /edit)

3. Set up Slack Incoming Webhook

  1. Create a new app at Slack API
  2. Enable Incoming Webhooks
  3. Select a channel and copy the Webhook URL

4. Get a Google Gemini API key

  1. Go to Google AI Studio
  2. Create an API key
  3. Add it as a Google PaLM API credential in n8n

5. Configure the n8n workflow

  1. Import the workflow JSON into n8n
  2. Open the Set Configuration Parameters node and enter:
  • LINE_CHANNEL_ACCESS_TOKEN
  • GOOGLE_SHEET_ID
  • SLACK_WEBHOOK_URL
  1. Set up Google Sheets OAuth2 credentials
  2. Set up Gemini Chat Model credentials

6. Register the LINE Webhook URL

  1. Return to LINE Developers Console
  2. Enter the n8n Webhook URL
  3. Enable Webhook usage
  4. Disable auto-reply messages

7. Test

  1. Activate the workflow
  2. Send a business card photo to your LINE bot
  3. Confirm the contact is saved in Google Sheets
  4. Confirm the Slack notification is received
  5. Confirm the LINE confirmation message is received

Tags

ai gemini line google-sheets slack crm image-recognition automation

1.2 Logical Blocks

This catalog entry is organized from the workflow JSON. The node-level section below shows the executable blocks available for review before importing the template.

2. Block-by-Block Analysis

Block 1 - Sticky Note

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 2 - Sticky Note1

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 3 - Sticky Note2

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 4 - Sticky Note3

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 5 - Sticky Note4

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 6 - Sticky Note5

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 7 - Sticky Note6

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 8 - Sticky Note7

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 9 - Set Configuration Parameters

Type / Role
n8n-nodes-base.set - set
Config choices
Version 3.4

Block 10 - When LINE Event Received

Type / Role
n8n-nodes-base.webhook - webhook
Config choices
Version 2

Block 11 - If Image Message

Type / Role
n8n-nodes-base.if - if
Config choices
Version 2

Block 12 - Fetch Image from LINE API

Type / Role
n8n-nodes-base.httpRequest - httpRequest
Config choices
Version 4.2

Block 13 - Encode Image as Base64

Type / Role
n8n-nodes-base.code - code
Config choices
Version 2

Block 14 - Setup Gemini for Card Data

Type / Role
@n8n/n8n-nodes-langchain.lmChatGoogleGemini - lmChatGoogleGemini
Config choices
Version 1

Block 15 - Extract Card Info with Gemini

Type / Role
@n8n/n8n-nodes-langchain.chainLlm - chainLlm
Config choices
Version 1.4

Block 16 - Parse Gemini Output Data

Type / Role
n8n-nodes-base.code - code
Config choices
Version 2

Block 17 - Read Contacts from Sheets

Type / Role
n8n-nodes-base.googleSheets - googleSheets
Config choices
Version 4.5

Block 18 - If Contact Exists

Type / Role
n8n-nodes-base.if - if
Config choices
Version 2

Block 19 - Append Contact to Sheets

Type / Role
n8n-nodes-base.googleSheets - googleSheets
Config choices
Version 4.5

Block 20 - Post New Contact to Slack

Type / Role
n8n-nodes-base.httpRequest - httpRequest
Config choices
Version 4.2

Block 21 - Send Success Reply via LINE

Type / Role
n8n-nodes-base.httpRequest - httpRequest
Config choices
Version 4.2

Block 22 - Send Duplicate Reply via LINE

Type / Role
n8n-nodes-base.httpRequest - httpRequest
Config choices
Version 4.2

Block 23 - Respond Not Image to LINE

Type / Role
n8n-nodes-base.respondToWebhook - respondToWebhook
Config choices
Version 1.1

Block 24 - Acknowledge OK Webhook

Type / Role
n8n-nodes-base.respondToWebhook - respondToWebhook
Config choices
Version 1.1

Showing the first 24 of 25 workflow blocks. Download the JSON for the full node graph.

3. Summary Table

Workflow Save business card contacts from LINE photos to Google Sheets using Gemini
Complexity advanced
Nodes 25
Categories Document Extraction, AI Summarization
Author TakatoYamada
Published 26 Apr 2026

4. Reproducing the Workflow from Scratch

  1. 1. Download the workflow JSON

    Use the JSON export at /data/workflows/15308/15308.json as the source template for this automation.

  2. 2. Import the template into n8n

    Open n8n, import the downloaded JSON, and review each node before activating the workflow.

  3. 3. Configure credentials and variables

    Replace placeholder credentials, API keys, webhook URLs, account IDs, and environment-specific values with your own settings.

  4. 4. Test with sample data

    Run the workflow manually or in a staging workspace, inspect node output, and confirm downstream systems receive the expected data.

  5. 5. Activate and monitor

    Enable the workflow only after testing, then monitor executions, errors, and rate limits during the first production runs.

5. General Notes & Resources

Review imported nodes carefully before activation. This catalog entry is intended to help you inspect the workflow structure, understand required services, and find related templates faster.

Node names, credentials, schedules, webhook paths, and external service limits may need adjustment for your workspace.

Frequently asked questions

What does Save business card contacts from LINE photos to Google Sheets using Gemini do?

Save business card contacts from LINE photos to Google Sheets with Gemini Who is this for Sales professionals, account managers, and anyone who exchanges business cards regularly. Designed especial...

What do I need before importing this workflow?

Review the workflow JSON, configure any required credentials in n8n, and test the automation in a safe workspace before using it in production.

Can I customize this workflow?

Yes. Use the block-by-block analysis and the downloadable JSON to inspect each node, then adjust credentials, prompts, schedules, filters, or destinations for your Document Extraction, AI Summarization use case.