Created
June 12, 2025 16:28
-
-
Save Mineru98/57ea35b1cb6f6b12a34659dc5ae94bf3 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"nodes": [ | |
{ | |
"parameters": { | |
"httpMethod": "POST", | |
"path": "501f1f62-4cf0-4b00-9f1b-106bddf6dc6a", | |
"options": {} | |
}, | |
"type": "n8n-nodes-base.webhook", | |
"typeVersion": 2, | |
"position": [ | |
700, | |
-200 | |
], | |
"id": "f3330f79-fedb-49e5-9343-ca8bd12f14af", | |
"name": "Webhook", | |
"webhookId": "501f1f62-4cf0-4b00-9f1b-106bddf6dc6a" | |
}, | |
{ | |
"parameters": { | |
"name": "={{(new Date()).toISOString().replace(/[:]/g, '-').replace(/\\..+/, '') + '.jpeg'}}", | |
"driveId": { | |
"__rl": true, | |
"mode": "list", | |
"value": "My Drive" | |
}, | |
"folderId": { | |
"__rl": true, | |
"value": "", | |
"mode": "list", | |
"cachedResultName": "your folder id", | |
"cachedResultUrl": "" | |
}, | |
"options": {} | |
}, | |
"type": "n8n-nodes-base.googleDrive", | |
"typeVersion": 3, | |
"position": [ | |
960, | |
-200 | |
], | |
"id": "8d322e7d-9bc7-45bd-b79e-20b663d3f0eb", | |
"name": "Save to Google Drive", | |
"credentials": { | |
"googleDriveOAuth2Api": { | |
"id": "wsnecETV6K89Tr76", | |
"name": "Google Drive account" | |
} | |
}, | |
"onError": "continueErrorOutput" | |
}, | |
{ | |
"parameters": { | |
"operation": "download", | |
"fileId": { | |
"__rl": true, | |
"value": "={{ $json.id }}", | |
"mode": "id" | |
}, | |
"options": {} | |
}, | |
"type": "n8n-nodes-base.googleDrive", | |
"typeVersion": 3, | |
"position": [ | |
1200, | |
-200 | |
], | |
"id": "b74bc222-79f1-4b49-8173-8d59b5824725", | |
"name": "Download image File", | |
"credentials": { | |
"googleDriveOAuth2Api": { | |
"id": "wsnecETV6K89Tr76", | |
"name": "Google Drive account" | |
} | |
} | |
}, | |
{ | |
"parameters": { | |
"conditions": { | |
"options": { | |
"caseSensitive": true, | |
"leftValue": "", | |
"typeValidation": "strict", | |
"version": 2 | |
}, | |
"conditions": [ | |
{ | |
"id": "7b560ffa-bb4f-42f8-bc06-de9ce15d1b86", | |
"leftValue": "={{ $json.choices[0].message.content['수축기 혈압'] }}", | |
"rightValue": "", | |
"operator": { | |
"type": "number", | |
"operation": "notEmpty", | |
"singleValue": true | |
} | |
}, | |
{ | |
"id": "a372a831-6d02-4f0e-8082-13aac5082b50", | |
"leftValue": "={{ $json.choices[0].message.content['이완기 혈압'] }}", | |
"rightValue": "", | |
"operator": { | |
"type": "number", | |
"operation": "notEmpty", | |
"singleValue": true | |
} | |
}, | |
{ | |
"id": "315fa73b-d16a-4f8c-8c25-396c9a82199e", | |
"leftValue": "={{ $json.choices[0].message.content['심박수'] }}", | |
"rightValue": "", | |
"operator": { | |
"type": "number", | |
"operation": "notEmpty", | |
"singleValue": true | |
} | |
}, | |
{ | |
"id": "6230b2ef-b9bd-47a9-846d-50fa074f70fc", | |
"leftValue": "={{ $json.choices[0].message.content['날짜 시간'] }}", | |
"rightValue": "", | |
"operator": { | |
"type": "string", | |
"operation": "notEmpty", | |
"singleValue": true | |
} | |
} | |
], | |
"combinator": "and" | |
}, | |
"options": {} | |
}, | |
"type": "n8n-nodes-base.if", | |
"typeVersion": 2.2, | |
"position": [ | |
1280, | |
60 | |
], | |
"id": "6aed1467-26e5-415c-bc49-8405eaf47701", | |
"name": "If" | |
}, | |
{ | |
"parameters": {}, | |
"type": "n8n-nodes-base.noOp", | |
"typeVersion": 1, | |
"position": [ | |
1660, | |
80 | |
], | |
"id": "d54d2ac2-3524-4c76-9083-8a8bf1a01123", | |
"name": "No Operation, do nothing" | |
}, | |
{ | |
"parameters": { | |
"modelId": { | |
"__rl": true, | |
"value": "gpt-4o-mini-2024-07-18", | |
"mode": "list", | |
"cachedResultName": "GPT-4O-MINI-2024-07-18" | |
}, | |
"messages": { | |
"values": [ | |
{ | |
"content": "=### infomation\n\n현재시간은 {{ $now }} 입니다.", | |
"role": "system" | |
}, | |
{ | |
"content": "=### instruction\n\n혈압 측정을 위해서 측정을 하려고 합니다.\n혈압 측정을 하는 내용이 아니라면 그냥 패스해줘.\n\n- SYS mmHg : 수축기 혈압\n- DIA mmHg : 이완기 혈압\n- PULSE/min : 심박수\n\n### input\n\n```\n{{ $json.content }}\n```\n\n### output format\n\n{\n \"날짜 시간\": str, # YY년 MM월 DD일 hh시 mm분\n \"수축기 혈압\": int,\n \"이완기 혈압\": int,\n \"심박수\": int\n}" | |
} | |
] | |
}, | |
"simplify": false, | |
"jsonOutput": true, | |
"options": {} | |
}, | |
"type": "@n8n/n8n-nodes-langchain.openAi", | |
"typeVersion": 1.8, | |
"position": [ | |
920, | |
60 | |
], | |
"id": "0758cffd-12ed-48cc-a2eb-db98ab257603", | |
"name": "JSON Parser", | |
"alwaysOutputData": true, | |
"credentials": { | |
"openAiApi": { | |
"id": "TGJH5P7SbVh9aG3p", | |
"name": "OpenAi account" | |
} | |
} | |
}, | |
{ | |
"parameters": { | |
"resource": "image", | |
"operation": "analyze", | |
"modelId": { | |
"__rl": true, | |
"value": "gpt-4o-mini-2024-07-18", | |
"mode": "list", | |
"cachedResultName": "GPT-4O-MINI-2024-07-18" | |
}, | |
"text": "Extract text from the provided image and organize it into a structured JSON format.", | |
"inputType": "base64", | |
"options": {} | |
}, | |
"type": "@n8n/n8n-nodes-langchain.openAi", | |
"typeVersion": 1.8, | |
"position": [ | |
700, | |
60 | |
], | |
"id": "0c09ce20-220f-4bca-971c-9f3b2fe20417", | |
"name": "Blood Pressure OCR", | |
"credentials": { | |
"openAiApi": { | |
"id": "TGJH5P7SbVh9aG3p", | |
"name": "OpenAi account" | |
} | |
} | |
}, | |
{ | |
"parameters": { | |
"resource": "databasePage", | |
"databaseId": { | |
"__rl": true, | |
"value": "your-notion-db-node-id", | |
"mode": "list", | |
"cachedResultName": "your-notion-db-node-id", | |
"cachedResultUrl": "https://www.notion.so/your-notion-db-node-id" | |
}, | |
"title": "={{ $json.choices[0].message.content['날짜 시간'] }}", | |
"propertiesUi": { | |
"propertyValues": [ | |
{ | |
"key": "날짜|title", | |
"title": "={{ $json.choices[0].message.content['날짜 시간'] }}" | |
}, | |
{ | |
"key": "수축기 혈압|number", | |
"numberValue": "={{ $json.choices[0].message.content['수축기 혈압'] }}" | |
}, | |
{ | |
"key": "이완기 혈압|number", | |
"numberValue": "={{ $json.choices[0].message.content['이완기 혈압'] }}" | |
}, | |
{ | |
"key": "심박수|number", | |
"numberValue": "={{ $json.choices[0].message.content['심박수'] }}" | |
} | |
] | |
}, | |
"options": {} | |
}, | |
"type": "n8n-nodes-base.notion", | |
"typeVersion": 2.2, | |
"position": [ | |
1480, | |
-100 | |
], | |
"id": "d9d931e8-21a4-4f36-8fb6-cd10893be9a8", | |
"name": "Append Row", | |
"credentials": { | |
"notionApi": { | |
"id": "DiassQEtYbZb1YoM", | |
"name": "Notion account" | |
} | |
} | |
}, | |
{ | |
"parameters": { | |
"authentication": "oAuth2", | |
"select": "channel", | |
"channelId": { | |
"__rl": true, | |
"value": "C08623KATRV", | |
"mode": "list", | |
"cachedResultName": "n8n" | |
}, | |
"text": "[Blood Pressure OCR] 구글 드라이브 업로드 과정에서 에러가 발생했습니다. 구글 Oauth 인증을 다시 확인해보세요.", | |
"otherOptions": {} | |
}, | |
"type": "n8n-nodes-base.slack", | |
"typeVersion": 2.3, | |
"position": [ | |
1480, | |
-480 | |
], | |
"id": "43c97f0d-d9fd-4758-95b3-7d3452a4fcb5", | |
"name": "Slack", | |
"webhookId": "0976d355-3da8-4867-b5c4-8062828d99c7", | |
"credentials": { | |
"slackOAuth2Api": { | |
"id": "EfX0VDgyaDcfZ6Rz", | |
"name": "Slack account" | |
} | |
} | |
} | |
], | |
"connections": { | |
"Webhook": { | |
"main": [ | |
[ | |
{ | |
"node": "Save to Google Drive", | |
"type": "main", | |
"index": 0 | |
} | |
] | |
] | |
}, | |
"Save to Google Drive": { | |
"main": [ | |
[ | |
{ | |
"node": "Download image File", | |
"type": "main", | |
"index": 0 | |
} | |
], | |
[ | |
{ | |
"node": "Slack", | |
"type": "main", | |
"index": 0 | |
} | |
] | |
] | |
}, | |
"Download image File": { | |
"main": [ | |
[ | |
{ | |
"node": "Blood Pressure OCR", | |
"type": "main", | |
"index": 0 | |
} | |
] | |
] | |
}, | |
"If": { | |
"main": [ | |
[ | |
{ | |
"node": "Append Row", | |
"type": "main", | |
"index": 0 | |
} | |
], | |
[ | |
{ | |
"node": "No Operation, do nothing", | |
"type": "main", | |
"index": 0 | |
} | |
] | |
] | |
}, | |
"JSON Parser": { | |
"main": [ | |
[ | |
{ | |
"node": "If", | |
"type": "main", | |
"index": 0 | |
} | |
] | |
] | |
}, | |
"Blood Pressure OCR": { | |
"main": [ | |
[ | |
{ | |
"node": "JSON Parser", | |
"type": "main", | |
"index": 0 | |
} | |
] | |
] | |
}, | |
"Append Row": { | |
"main": [ | |
[ | |
{ | |
"node": "No Operation, do nothing", | |
"type": "main", | |
"index": 0 | |
} | |
] | |
] | |
}, | |
"Slack": { | |
"main": [ | |
[ | |
{ | |
"node": "No Operation, do nothing", | |
"type": "main", | |
"index": 0 | |
} | |
] | |
] | |
} | |
}, | |
"pinData": {}, | |
"meta": { | |
"templateCredsSetupCompleted": true, | |
"instanceId": "4bf18c844e20c0a559d4eb1659b1fc37fad6dfa4a5357f262b4860bcc490fecd" | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment