{ "name": "Find LinkedIn Profiles for Sheet Rows", "tags": [ { "id": "a8B9vqj0vNLXcKVQ", "name": "template", "createdAt": "2025-04-04T15:38:37.785Z", "updatedAt": "2025-04-04T15:38:37.785Z" } ], "nodes": [ { "id": "find-linkedin-profiles-for-sheet-rows-0", "name": "When clicking ‘Test workflow’", "type": "n8n-nodes-base.manualTrigger", "position": [ 0, 0 ], "parameters": {}, "typeVersion": 1 }, { "id": "find-linkedin-profiles-for-sheet-rows-1", "name": "Person info", "type": "n8n-nodes-base.googleSheets", "position": [ 220, 0 ], "parameters": { "options": {}, "sheetName": { "__rl": true, "mode": "name", "value": "Sheet1" }, "documentId": { "__rl": true, "mode": "id", "value": "YOUR_SPREADSHEET_ID" } }, "typeVersion": 4.5 }, { "id": "find-linkedin-profiles-for-sheet-rows-2", "name": "Search profile", "type": "n8n-nodes-base.airtop", "notes": "This could take a few minutes depending on the number of rows", "position": [ 440, 0 ], "parameters": { "url": "=https://www.google.com/search?q={{ encodeURI($json['Person Info']) }}", "prompt": "=This is Google Search results. the first results should be the Linkedin Page of {{ $json['Person Info'] }} \nReturn the Linkedin URL and nothing else.\nIf you cannot find the Linkedin URL, return an empty string. \nA valid Linkedin profile URL starts with \"https://www.linkedin.com/in/\"", "resource": "extraction", "operation": "query", "sessionMode": "new", "additionalFields": {} }, "notesInFlow": true, "typeVersion": 1 }, { "id": "find-linkedin-profiles-for-sheet-rows-3", "name": "Parse response", "type": "n8n-nodes-base.code", "position": [ 660, 0 ], "parameters": { "mode": "runOnceForEachItem", "jsCode": "const s=$json.data.modelResponse;if(typeof s!=='string')throw Error('Invalid Airtop response');const url=s.trim();if(url&&!/^https:\\/\\/www\\.linkedin\\.com\\/in\\/[^\\s]+$/i.test(url))throw Error('Invalid profile URL');return {json:{...$('Person info').item.json,'Linkedin URL':url}};" }, "typeVersion": 2 }, { "id": "find-linkedin-profiles-for-sheet-rows-4", "name": "Update row", "type": "n8n-nodes-base.googleSheets", "position": [ 880, 0 ], "parameters": { "columns": { "value": {}, "schema": [ { "id": "Person Info", "type": "string", "display": true, "required": false, "displayName": "Person Info", "defaultMatch": false, "canBeUsedToMatch": true }, { "id": "Linkedin URL", "type": "string", "display": true, "required": false, "displayName": "Linkedin URL", "defaultMatch": false, "canBeUsedToMatch": true }, { "id": "Validated", "type": "string", "display": true, "required": false, "displayName": "Validated", "defaultMatch": false, "canBeUsedToMatch": true }, { "id": "row_number", "type": "string", "display": true, "removed": false, "readOnly": true, "required": false, "displayName": "row_number", "defaultMatch": false, "canBeUsedToMatch": true } ], "mappingMode": "autoMapInputData", "matchingColumns": [ "row_number" ], "attemptToConvertTypes": false, "convertFieldsToString": false }, "options": {}, "operation": "update", "sheetName": { "__rl": true, "mode": "name", "value": "Sheet1" }, "documentId": { "__rl": true, "mode": "id", "value": "YOUR_SPREADSHEET_ID" } }, "typeVersion": 4.5 }, { "id": "find-linkedin-profiles-for-sheet-rows-filter", "name": "Skip empty descriptions", "type": "n8n-nodes-base.code", "typeVersion": 2, "parameters": { "mode": "runOnceForAllItems", "jsCode": "return $input.all().map((item,index)=>({...item,pairedItem:{item:index}})).filter(item=>String(item.json['Person Info']??'').trim());" } } ], "active": false, "pinData": {}, "settings": { "executionOrder": "v1" }, "connections": { "Person info": { "main": [ [ { "node": "Skip empty descriptions", "type": "main", "index": 0 } ] ] }, "Parse response": { "main": [ [ { "node": "Update row", "type": "main", "index": 0 } ] ] }, "Search profile": { "main": [ [ { "node": "Parse response", "type": "main", "index": 0 } ] ] }, "When clicking ‘Test workflow’": { "main": [ [ { "node": "Person info", "type": "main", "index": 0 } ] ] }, "Skip empty descriptions": { "main": [ [ { "node": "Search profile", "type": "main", "index": 0 } ] ] } } }