Extract Pay Slip Data with LINE Chatbot and Geminio to Google Sheets - n8n Workflow | Neura Market
Extract Pay Slip Data with LINE Chatbot and Geminio to Google Sheets
## Workflow Overview:
Extracting text from an image using AI is worthwhile because it requires no code. It incorporates the Google Gemini 2.0 Flash model for important text extraction from images. If you code without AI, you have to use multiple conditions and may cause a lot of bugs, but with Google Gemini, you don't need any coding, and if the Pay Slip is different, Gemini will extract it automatically.
## Workflow Description:
1. The user uses the Line Messaging API to send a Pay Slip image or message to the chatbot. Create a Line Business ID from here: [Line Business](https://account.line.biz/login).
2. Classify the message as either an image or text.
3. If the message is a Pay Slip image, it will be processed using Gemini 2.0 Flash EXP and extract important information and respond in JSON format without coding by using the following prompt: Analyze the image and then return in JSON Response that has the only following values: **Status, From, To, Date, Amount**.

To get the Google AI Studio API Key, you can find it from the following link: [Google AI Studio API Key](https://aistudio.google.com/apikey).
4. Create Google Sheets which include the fields **(Status, From, To, Date, Amount)** that we have created related to the AI prompt [Google Sheets](http://docs.google.com/spreadsheets) as the following example:

5. If the message is text, it will process using the Gemini 2.0 Flash EXP model as the AI Assistant; else if the message is an image, it will extract the important fields, then reply to the user and insert into Google Sheets.
## Key Features:
* **Extract text from image with No Code** - Without N8N, we have to write code to extract text from an image, but with N8N and Google Gemini 2.0 Flash EXP together, we don't need to code, and it will process all slip vendors or other document vendors.
* **Multipurpose Chatbot** - This chatbot accepts both text and image, so we don't have to create many chatbot accounts.
* **Reduce human error** - This workflow lets any officer verify document status when the job ends.
**Note:** You can change the information by changing your prompt and also Google Sheets Column names relatively.
Platform
n8n
Category
AI
Price
Free
Creator
Sirisak Chantanate
set
switch
webhook
stickyNote
httpRequest
googleSheets
agent
chainLlm
lmChatGoogleGemini
memoryBufferWindow
How to import this workflow into n8n
1Purchase or download the workflow to get the n8n workflow JSON file.
2In your n8n instance, open Workflows and choose "Import from File" (or paste the JSON with Ctrl+V on the canvas).
3Open each node marked with a credential warning and connect your own accounts and API keys.
4Run the workflow once manually to verify the data flow, then toggle it to Active.