{"workflow":{"id":13536,"name":"Design scalable sync workflows with Data Tables, ProspectPro and HubSpot","views":1690,"recentViews":6,"totalViews":1690,"createdAt":"2026-02-20T09:41:54.351Z","description":"This template is a **pattern library** (one importable workflow) that shows a repeatable way to structure n8n automations so they remain **easy to extend, cheaper to run, and safer to scale**.\n\nIt’s intentionally **opinionated and dry**: the goal is not “plug & play”, but a set of proven building blocks you can copy into your own workflows.\n\n### Problems this framework solves\n- **Spaghetti workflows that are hard to change**  \n  A consistent split into *Trigger → Manager → Function → Utility* so changes don’t ripple through everything.\n- **Duplicate processing when runs overlap**  \n  Uses “in progress / success / error” indicators so the trigger can skip items that are already being processed.\n- **Unnecessary re-runs that keep failing**  \n  Items that fail can be marked/parked, so you don’t burn executions repeating the same error.\n- **Execution costs exploding over time**  \n  Offers polling + batching alternatives when “one event = one execution” becomes too expensive.\n- **Rate limits and API throttling under load**  \n  Includes rate-limited processing patterns (delays/throttling) to smooth spikes.\n- **Missed items during downtime, deploys, or restarts**  \n  Stores sync state (e.g., lastSync) in **n8n Data Tables** instead of relying on in-memory state.\n- **Long-running pagination that becomes fragile**  \n  Demonstrates manual “page-wise” pagination (fetch N → process N → checkpoint → repeat) to avoid huge in-memory batches.\n- **Debugging incidents without visibility**  \n  Includes an error workflow pattern (Error Trigger + notification) and structured error logging.\n\n### What you get in this template\n- Trigger patterns (simple and rate-limited)\n- Polling / batching patterns (basic → more robust → fully configurable with pagination)\n- A “manager” pattern for stateful processing and overlap protection\n- Function + utility workflow examples for reusability\n- Error logging to a Data Table and an example Telegram alert\n\n### Requirements / setup\n- n8n version that includes the **Data Table** node\n- Create/replace Data Tables used in the template (e.g. `Timestamps`, `Errors`)\n- Example nodes use **ProspectPro**, **HubSpot**, and **Telegram** (optional). Replace these with your own tools if you’re not using them.\n\n### Important notes\n- This is **not** a finished automation. Import it, then **choose the pattern(s)** you need and swap the example “get items / process item” steps for your own logic.\n- Some patterns include looping/recursion options—configure stop conditions carefully to avoid unintended infinite runs.\n- This framework is **one** effective route to scalable n8n systems, not the only one.\n\n**Note:** this is a living document that will be updated periodically.\n","workflow":{"id":"w0NDnlGr_-uqHUHVrgPM_","meta":{"instanceId":"04f23e4c433f478fbd7cc8c4ceff447b7061f1e9f3641a5ebf456657ac823807","templateCredsSetupCompleted":true},"name":"Workflow Patterns & Boilerplate for Scaling up","tags":[],"nodes":[{"id":"ae48b41e-015c-4bbf-b3af-93d2fb900635","name":"Sticky Note","type":"n8n-nodes-base.stickyNote","position":[-96,-2560],"parameters":{"width":560,"height":784,"content":"## A. Triggers basics\nMost triggers output one or more items that need to be processed individually, like:\n- DMs / Emails / Notifications\n- Companies / Contacts / Prospects\n- Website Visits / Form Submissions\n\n\nIn such cases, **always** process items individually in a sub-workflow, however trivial your project might seem. Building modular means building scaleable/maintainable/flexible and is usually the simpler and safer option in n8n.\n\n\n**Subflow settings:**\n- Mode -> \"Run once for each item\"\n- \"Wait For Sub-Workflow Completion\" -> \"On\" (true)\n\n\n**Rate-limits (error prevention):**\n- Most APIs have \"rate-limits\", meaning you can only make so many requests in a certain amount of time.\n- If you're processing many items simultaneously, you'll hit those limits sooner than you'd think.\n- The right trigger settings will get you far: think about the number of times you expect a trigger event to occur and set the polling time / filter options  (in your actual trigger node) accordingly.\n- Most events occur irregularly (not spread out over 24 hours). Use a \"batch-delay\" pattern to even out spikes.\n- ***Webhooks/webhook-style nodes are though to throttle in n8n, but the 3rd party service provider might be able to batch your signals.***\n\n\n**n8n's # of executions:**\n- Your n8n subscription includes a finite number of \"executions\". It's imperative you don't hit your limit, as this will cause your automations to turn off.\n- What counts as an execution, and what doesn't, differs from trigger to trigger.\n- **Important:** Subflow-executions don't count as executions in the sense of the n8n billing scheme. You can use them as much as you like (31-01-2026)."},"typeVersion":1},{"id":"ec1d57b4-9f70-4a53-90d1-821a81968a18","name":"Sticky Note7","type":"n8n-nodes-base.stickyNote","position":[768,-2160],"parameters":{"color":5,"width":656,"height":384,"content":"### A2 - Rate-limited individual processing\nUse this pattern when your trigger can output a sufficiently large number of items that it will trigger rate limits in the services you're using."},"typeVersion":1},{"id":"94a342d2-bb06-49f3-919b-12d62274ed5b","name":"Create Batches","type":"n8n-nodes-base.splitInBatches","position":[848,-2048],"parameters":{"options":{},"batchSize":10},"typeVersion":3},{"id":"8b9320b4-47c1-47f7-81dd-adaa697f9c83","name":"Process one item at a time - (1)","type":"n8n-nodes-base.executeWorkflow","position":[1056,-2384],"parameters":{"mode":"each","options":{"waitForSubWorkflow":true},"workflowId":{"__rl":true,"mode":"list","value":"IdtvYdzQ2uGp7quU","cachedResultUrl":"/workflow/IdtvYdzQ2uGp7quU","cachedResultName":"Subflow - TEMPLATE"},"workflowInputs":{"value":{},"schema":[{"id":"id","type":"string","display":true,"removed":false,"required":false,"displayName":"id","defaultMatch":false,"canBeUsedToMatch":true}],"mappingMode":"defineBelow","matchingColumns":["id"],"attemptToConvertTypes":false,"convertFieldsToString":true}},"typeVersion":1.3},{"id":"22e3ca38-0900-4a39-94b3-1386e08b19e4","name":"Process one item at a time (2)","type":"n8n-nodes-base.executeWorkflow","position":[1056,-1984],"parameters":{"mode":"each","options":{"waitForSubWorkflow":true},"workflowId":{"__rl":true,"mode":"list","value":"IdtvYdzQ2uGp7quU","cachedResultUrl":"/workflow/IdtvYdzQ2uGp7quU","cachedResultName":"Subflow - TEMPLATE"},"workflowInputs":{"value":{},"schema":[{"id":"id","type":"string","display":true,"removed":false,"required":false,"displayName":"id","defaultMatch":false,"canBeUsedToMatch":true}],"mappingMode":"defineBelow","matchingColumns":["id"],"attemptToConvertTypes":false,"convertFieldsToString":true}},"typeVersion":1.3},{"id":"80c5cc01-6bd8-444c-b553-9e1b76e56bfb","name":"Delay after each batch","type":"n8n-nodes-base.wait","position":[1248,-1984],"webhookId":"0056cbae-6dba-473d-ba7a-86180b265c98","parameters":{},"typeVersion":1.1},{"id":"72c80fa2-cc15-4c57-98c2-afd90e80f400","name":"Sticky Note9","type":"n8n-nodes-base.stickyNote","position":[-96,-2560],"parameters":{"color":7,"width":1520,"height":784,"content":""},"typeVersion":1},{"id":"4ab99321-2720-4a1b-b723-fe0227f6afdf","name":"Sticky Note10","type":"n8n-nodes-base.stickyNote","position":[768,-2560],"parameters":{"color":5,"width":656,"height":384,"content":"### A1 - Simple, individual processing.\nUse this pattern if:\n- your trigger always outputs 1 item per execution (like a webhook/webhook-style trigger that triggers for each individual event)\n- your trigger always outputs a manageable number of items, even when you go viral"},"typeVersion":1},{"id":"df602886-27ae-4698-8643-2eea0906ef68","name":"New Website Visitors","type":"@bedrijfsdatanl/n8n-nodes-prospectpro.prospectproTrigger","position":[560,-2048],"parameters":{"pollTimes":{"item":[{"mode":"everyMinute"}]}},"credentials":{"prospectproApi":{"id":"yyRRf0HzQaW21btS","name":"TESTACCOUNT"}},"typeVersion":1},{"id":"0292f068-57fd-4f48-8c87-f3a452085356","name":"Sticky Note6","type":"n8n-nodes-base.stickyNote","position":[-96,-1440],"parameters":{"width":560,"height":784,"content":"## B1. Custom polling 1: simple, versatile, limited\nWhen your trigger doesn't support batching events, you'll quickly spent a lot of n8n-executions. In such cases, polling manually is usually more cost-effective.\n\nIn other words; instead of triggering your workflow each time something happens, you can check periodically if new event(s) have happened.\n\n**When is this effective:**\n- If you don't need to respond to something immediately, but you can wait 15/30/60 minutes (or more).\n- If the total number of events that happen is larger than the number of cycles you need in a day. **For example: you get 300 emails a day. You can respond immediately 300 times, or you can respond in 24 batches (i.e. once an hour).**\n\n\n**Manual polling:**\n- Manual polling can be as simple as setting the timer (\"Schedule Trigger\"). But what happens when an issue occurs? Or when you update n8n? Well.. It breaks.\n- By leveraging Data Tables in n8n, you can build a more persistent system that's much less prone to issues.\n\n\n**Limitations:**\n- The software provider you're working with needs an API to retrieve items \"after a certain date\". Replace \"B1 - Get Items\" with your data source.\n- This pattern is easy to implement, but does leave a margin of error: when your datasource throws an error, items might be skipped. Use the next pattern (B2) when extra requirements are supported by the software provider you're working with.\n\n\n**Remarks:**\n- The database key is set once in the 2nd node (\"Set variables\").\n- Configure your service in the 5th node (\"B1 - Get Items\").\n- Error handling in not yet included (and required for proper use).\n- Always consider B2: whenever your source supports the requirements, it's just a better way of doing things."},"typeVersion":1},{"id":"43d2e748-1f55-4854-a406-8bb992faaf5f","name":"Sticky Note11","type":"n8n-nodes-base.stickyNote","position":[480,-1440],"parameters":{"color":5,"width":384,"height":304,"content":"### B1 - Start sync\nSelect your timer interval and choose a name for your data table variable."},"typeVersion":1},{"id":"c05baf28-1891-4781-85a6-23709af3bdfd","name":"Sticky Note12","type":"n8n-nodes-base.stickyNote","position":[880,-1440],"parameters":{"color":5,"width":384,"height":304,"content":"### B1 - Get/set lastSync\nGet the time of the last execution or start from 0 (first run only)."},"typeVersion":1},{"id":"5f4d67fc-e1b2-4a26-b26c-4fb8aafe30f2","name":"Sticky Note13","type":"n8n-nodes-base.stickyNote","position":[880,-1120],"parameters":{"color":5,"width":688,"height":464,"content":"### B1 - Create/update database entry\nStore the current time in the database (for next cycle). *This is not perfect: as the timestamp is set before the items are even retrieved, you could potentially skip items.*"},"typeVersion":1},{"id":"eea5a090-fa37-4545-b0d1-ac16f7412a14","name":"Sticky Note14","type":"n8n-nodes-base.stickyNote","position":[1280,-1440],"parameters":{"color":5,"width":288,"height":304,"content":"### B1 - Fetch new items\nRetrieve items that have been created/updated/.. since this workflow last ran."},"typeVersion":1},{"id":"d51f664e-7359-47ca-aff1-71396a028816","name":"Sticky Note15","type":"n8n-nodes-base.stickyNote","position":[1584,-1440],"parameters":{"color":5,"width":576,"height":304,"content":"### B1 - Validate, prepare & filter items\nTo cover all grounds, this is where you modify the results you get from the service you're using. ***Completely optional, probably even redundant.***"},"typeVersion":1},{"id":"9270e421-ec97-448e-89af-ca6724e94c31","name":"Sticky Note16","type":"n8n-nodes-base.stickyNote","position":[-96,-1440],"parameters":{"color":7,"width":2592,"height":784,"content":""},"typeVersion":1},{"id":"3ae65551-ed5e-4e84-a593-5838e0e1521b","name":"B1 - Schedule Trigger","type":"n8n-nodes-base.scheduleTrigger","position":[528,-1312],"parameters":{"rule":{"interval":[{}]}},"typeVersion":1.3},{"id":"879262aa-164a-4621-a55e-f982e8d79345","name":"B1 - Set variables","type":"n8n-nodes-base.set","position":[720,-1312],"parameters":{"options":{},"assignments":{"assignments":[{"id":"4e1e9007-e49b-432d-a4a1-7ecd35c22268","name":"timestamp_key","type":"string","value":"demo_timestamp"}]}},"typeVersion":3.4},{"id":"6512b302-61e2-423c-905a-929586324312","name":"B1 - Get timestamp","type":"n8n-nodes-base.dataTable","onError":"continueErrorOutput","position":[928,-1312],"parameters":{"limit":1,"filters":{"conditions":[{"keyName":"key","keyValue":"={{$('B1 - Set variables').first().json.timestamp_key}}"}]},"matchType":"allConditions","operation":"get","dataTableId":{"__rl":true,"mode":"list","value":"8MPVpHDnVGj4PBZR","cachedResultUrl":"/projects/tgy2Tl0HCDQH0Rbt/datatables/8MPVpHDnVGj4PBZR","cachedResultName":"Timestamps"}},"typeVersion":1,"alwaysOutputData":true},{"id":"3b149e14-a590-473c-8d75-8eaf0421116b","name":"B1 - Set lastSync","type":"n8n-nodes-base.code","position":[1120,-1312],"parameters":{"mode":"runOnceForEachItem","jsCode":"return { lastSync: Math.floor(new Date($json.value || 0).getTime() / 1000) };"},"typeVersion":2},{"id":"86d67791-a274-4399-a67e-edbdab78d907","name":"B1 - Get Items","type":"n8n-nodes-base.httpRequest","onError":"continueErrorOutput","position":[1360,-1312],"parameters":{"url":"=https://api.prospectpro.nl/v1.2/prospects","options":{},"sendQuery":true,"queryParameters":{"parameters":[{"name":"from_last_visit","value":"={{ $json.lastSync }}"},{"name":"sort_by","value":"last_visit"},{"name":"sort_order","value":"asc"}]}},"typeVersion":4.2},{"id":"ab792986-dbfa-4958-95b3-ecdb79c05720","name":"B1 - Has Items?","type":"n8n-nodes-base.if","position":[1632,-1312],"parameters":{"options":{},"conditions":{"options":{"version":2,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"84fc2faf-74e7-4bea-9d75-630f55288bef","operator":{"type":"boolean","operation":"true","singleValue":true},"leftValue":"={{ $json.found > 0 }}","rightValue":""}]}},"typeVersion":2.2},{"id":"7d6ce11a-bc53-4450-a695-34d24c71b5b7","name":"B1 - Items","type":"n8n-nodes-base.splitOut","position":[1824,-1312],"parameters":{"options":{},"fieldToSplitOut":"items"},"typeVersion":1},{"id":"971fdcbf-d4f9-4db5-b14f-b4b6c7802d40","name":"B1 - Filter Items","type":"n8n-nodes-base.filter","position":[2000,-1312],"parameters":{"options":{},"conditions":{"options":{"version":2,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"b65f03ae-26bc-4bc7-a77c-74a072a3d98b","operator":{"type":"boolean","operation":"true","singleValue":true},"leftValue":"={{ !!$json.updated_time && $json.updated_time > $('B1 - Set lastSync').first().json.lastSync }}","rightValue":""}]}},"typeVersion":2.2,"alwaysOutputData":true},{"id":"e4c2e7bd-9c6e-4e71-8ee1-fe6017ae3528","name":"B1 - Update timestamp","type":"n8n-nodes-base.dataTable","position":[1168,-1008],"parameters":{"columns":{"value":{"value":"={{ new Date().toISOString() }}"},"schema":[{"id":"key","type":"string","display":true,"removed":true,"readOnly":false,"required":false,"displayName":"key","defaultMatch":false},{"id":"value","type":"dateTime","display":true,"removed":false,"readOnly":false,"required":false,"displayName":"value","defaultMatch":false}],"mappingMode":"defineBelow","matchingColumns":[],"attemptToConvertTypes":false,"convertFieldsToString":false},"filters":{"conditions":[{"keyValue":"={{ $('B1 - Get timestamp').first().json.id }}"},{"keyName":"key","keyValue":"={{$('B1 - Set variables').first().json.timestamp_key}}"}]},"options":{},"matchType":"allConditions","operation":"update","dataTableId":{"__rl":true,"mode":"list","value":"8MPVpHDnVGj4PBZR","cachedResultUrl":"/projects/tgy2Tl0HCDQH0Rbt/datatables/8MPVpHDnVGj4PBZR","cachedResultName":"Timestamps"}},"typeVersion":1},{"id":"8dca0ece-c3ad-4b3c-980f-efbbc49ea20f","name":"B1 - Create timestamp","type":"n8n-nodes-base.dataTable","position":[1168,-848],"parameters":{"columns":{"value":{"key":"={{$('B1 - Set variables').first().json.timestamp_key}}","value":"={{ new Date().toISOString() }}"},"schema":[{"id":"key","type":"string","display":true,"removed":false,"readOnly":false,"required":false,"displayName":"key","defaultMatch":false},{"id":"value","type":"dateTime","display":true,"removed":false,"readOnly":false,"required":false,"displayName":"value","defaultMatch":false}],"mappingMode":"defineBelow","matchingColumns":[],"attemptToConvertTypes":false,"convertFieldsToString":false},"options":{},"dataTableId":{"__rl":true,"mode":"list","value":"8MPVpHDnVGj4PBZR","cachedResultUrl":"/projects/tgy2Tl0HCDQH0Rbt/datatables/8MPVpHDnVGj4PBZR","cachedResultName":"Timestamps"}},"typeVersion":1},{"id":"9ed19bca-32a9-4ac0-980a-c2dd8056dbd2","name":"B1 - No Operation, do nothing","type":"n8n-nodes-base.noOp","position":[1360,-848],"parameters":{},"typeVersion":1},{"id":"5e092d72-ddda-4e6d-87c2-4c229667aef7","name":"Sticky Note17","type":"n8n-nodes-base.stickyNote","position":[480,-624],"parameters":{"color":5,"width":384,"height":304,"content":"### B2 - Start sync\nSelect your timer interval, choose a name for your data table variable and (optionally) set a max. number of results per page."},"typeVersion":1},{"id":"c8ce4dc0-4993-40b6-8105-099cf97fdb66","name":"Sticky Note18","type":"n8n-nodes-base.stickyNote","position":[880,-624],"parameters":{"color":5,"width":384,"height":304,"content":"### B2 - Get/set lastSync\nGet the time of the last execution or start from 0 (first run only)."},"typeVersion":1},{"id":"c9bfe048-6dfd-45bb-a7cd-b99ae6917844","name":"Sticky Note19","type":"n8n-nodes-base.stickyNote","position":[1280,-304],"parameters":{"color":5,"width":880,"height":464,"content":"### B2 - Create/update database entry\nGet the timestamp that corresponds with the most recent result in the response. This works because the HTTP node is setup in a away results are filtered by \"date\", sorted \"oldest-to-newest\", and limitted to a desired amount. When there's more results than the limit, you'll pick those up automatically in the next run."},"typeVersion":1},{"id":"0cd5f950-4db7-47ab-8b91-011925176ec2","name":"Sticky Note20","type":"n8n-nodes-base.stickyNote","position":[1280,-624],"parameters":{"color":5,"width":288,"height":304,"content":"### B2 - Fetch new items\nRetrieve items that have been created/updated/.. since this workflow last ran."},"typeVersion":1},{"id":"456c5100-d977-4145-9f60-b52c3844b22e","name":"Sticky Note21","type":"n8n-nodes-base.stickyNote","position":[1584,-624],"parameters":{"color":5,"width":576,"height":304,"content":"### B2 - Validate, prepare & filter items\nTo cover all grounds, this is where you modify the results you get from the service you're using. ***Completely optional, probably even redundant.***"},"typeVersion":1},{"id":"0caee12c-64e4-4f5e-8dfd-7b0271a20500","name":"B2 - Schedule Trigger","type":"n8n-nodes-base.scheduleTrigger","position":[528,-496],"parameters":{"rule":{"interval":[{}]}},"typeVersion":1.3},{"id":"78c02fa2-a370-4e21-afb4-dcc21fefd90f","name":"B2 - Set variables","type":"n8n-nodes-base.set","position":[720,-496],"parameters":{"options":{},"assignments":{"assignments":[{"id":"4e1e9007-e49b-432d-a4a1-7ecd35c22268","name":"timestamp_key","type":"string","value":"demo_timestamp"},{"id":"3ff8a838-a321-4245-8c11-fdb4b0b819c1","name":"limit","type":"number","value":20}]}},"typeVersion":3.4},{"id":"b513e8a7-d3d1-43ad-b8b0-79e70ab509f3","name":"B2 - Get timestamp","type":"n8n-nodes-base.dataTable","onError":"continueErrorOutput","position":[928,-496],"parameters":{"limit":1,"filters":{"conditions":[{"keyName":"key","keyValue":"={{$('B2 - Set variables').first().json.timestamp_key}}"}]},"matchType":"allConditions","operation":"get","dataTableId":{"__rl":true,"mode":"list","value":"8MPVpHDnVGj4PBZR","cachedResultUrl":"/projects/tgy2Tl0HCDQH0Rbt/datatables/8MPVpHDnVGj4PBZR","cachedResultName":"Timestamps"}},"typeVersion":1,"alwaysOutputData":false},{"id":"5767ad43-3ea9-4b15-a2e0-2d8109a143ee","name":"B2 - Set lastSync","type":"n8n-nodes-base.code","position":[1120,-496],"parameters":{"mode":"runOnceForEachItem","jsCode":"return { lastSync: Math.floor(new Date($json.value || 0).getTime() / 1000) };"},"typeVersion":2},{"id":"783eed8e-99df-4ec5-9856-464b1b6b2fe0","name":"B2 - Get Items","type":"n8n-nodes-base.httpRequest","onError":"continueErrorOutput","position":[1360,-496],"parameters":{"url":"=https://api.prospectpro.nl/v1.2/prospects","options":{},"sendQuery":true,"authentication":"predefinedCredentialType","queryParameters":{"parameters":[{"name":"from_last_visit","value":"={{ $json.lastSync }}"},{"name":"sort_by","value":"last_visit"},{"name":"sort_order","value":"asc"},{"name":"limit","value":"={{ $('B2 - Set variables').first().json?.limit || undefined }}"}]},"nodeCredentialType":"prospectproApi"},"credentials":{"prospectproApi":{"id":"yyRRf0HzQaW21btS","name":"TESTACCOUNT"}},"typeVersion":4.2},{"id":"738d864a-f043-4ab4-883d-89914e454a0b","name":"B2 - Has Items?","type":"n8n-nodes-base.if","position":[1632,-496],"parameters":{"options":{},"conditions":{"options":{"version":2,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"84fc2faf-74e7-4bea-9d75-630f55288bef","operator":{"type":"boolean","operation":"true","singleValue":true},"leftValue":"={{ $json.found > 0 }}","rightValue":""}]}},"typeVersion":2.2},{"id":"997c9384-5e22-48a9-a717-58787d008453","name":"B2 - Items","type":"n8n-nodes-base.splitOut","position":[1824,-496],"parameters":{"options":{},"fieldToSplitOut":"items"},"typeVersion":1},{"id":"1337fe34-a90c-4d32-8541-55597228a7e3","name":"B2 - Filter Items","type":"n8n-nodes-base.filter","position":[2000,-496],"parameters":{"options":{},"conditions":{"options":{"version":2,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"b65f03ae-26bc-4bc7-a77c-74a072a3d98b","operator":{"type":"boolean","operation":"true","singleValue":true},"leftValue":"={{ !!$json.updated_time && $json.updated_time > $('B2 - Set lastSync').first().json.lastSync }}","rightValue":""}]}},"typeVersion":2.2,"alwaysOutputData":true},{"id":"f4ecb10b-7d61-47a3-8092-10f0857f7fb0","name":"B2 - Update timestamp","type":"n8n-nodes-base.dataTable","position":[1760,-176],"parameters":{"columns":{"value":{"value":"={{ $json.lastSync }}"},"schema":[{"id":"key","type":"string","display":true,"removed":true,"readOnly":false,"required":false,"displayName":"key","defaultMatch":false},{"id":"value","type":"dateTime","display":true,"removed":false,"readOnly":false,"required":false,"displayName":"value","defaultMatch":false}],"mappingMode":"defineBelow","matchingColumns":[],"attemptToConvertTypes":false,"convertFieldsToString":false},"filters":{"conditions":[{"keyValue":"={{ $('B2 - Get timestamp').first().json.id }}"},{"keyName":"key","keyValue":"={{$('B2 - Set variables').first().json.timestamp_key}}"}]},"options":{},"matchType":"allConditions","operation":"update","dataTableId":{"__rl":true,"mode":"list","value":"8MPVpHDnVGj4PBZR","cachedResultUrl":"/projects/tgy2Tl0HCDQH0Rbt/datatables/8MPVpHDnVGj4PBZR","cachedResultName":"Timestamps"}},"typeVersion":1},{"id":"ff5209a7-8160-49fa-8a2f-8f6d0d7ecc99","name":"B2 - Create timestamp","type":"n8n-nodes-base.dataTable","position":[1760,-16],"parameters":{"columns":{"value":{"key":"={{$('B2 - Set variables').first().json.timestamp_key}}","value":"={{ $json.lastSync }}"},"schema":[{"id":"key","type":"string","display":true,"removed":false,"readOnly":false,"required":false,"displayName":"key","defaultMatch":false},{"id":"value","type":"dateTime","display":true,"removed":false,"readOnly":false,"required":false,"displayName":"value","defaultMatch":false}],"mappingMode":"defineBelow","matchingColumns":[],"attemptToConvertTypes":false,"convertFieldsToString":false},"options":{},"dataTableId":{"__rl":true,"mode":"list","value":"8MPVpHDnVGj4PBZR","cachedResultUrl":"/projects/tgy2Tl0HCDQH0Rbt/datatables/8MPVpHDnVGj4PBZR","cachedResultName":"Timestamps"}},"typeVersion":1},{"id":"1cbdf0ed-ddad-4133-9552-17158f108c9b","name":"B2 - No Operation, do nothing","type":"n8n-nodes-base.noOp","position":[1952,-16],"parameters":{},"typeVersion":1},{"id":"a5c87103-139e-4d6b-a7b8-f335baf336a2","name":"B1 - Has timestamp / not first run?","type":"n8n-nodes-base.if","position":[976,-1008],"parameters":{"options":{},"conditions":{"options":{"version":3,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"7dfd60f6-fb39-41dd-b013-8fd4591a44a3","operator":{"type":"boolean","operation":"true","singleValue":true},"leftValue":"={{ !!$('B1 - Get timestamp').first().json.id }}","rightValue":""}]}},"typeVersion":2.3},{"id":"1baf0a76-1565-4490-8be6-104ebb5b71aa","name":"B2 - Has timestamp / not first run?","type":"n8n-nodes-base.if","position":[1568,-176],"parameters":{"options":{},"conditions":{"options":{"version":3,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"7dfd60f6-fb39-41dd-b013-8fd4591a44a3","operator":{"type":"boolean","operation":"true","singleValue":true},"leftValue":"={{ !!$('B2 - Get timestamp').first().json.id }}","rightValue":""}]}},"typeVersion":2.3},{"id":"b9a38f00-1707-4e87-ac2c-29221b3f63c9","name":"B2 - Update lastSync","type":"n8n-nodes-base.code","position":[1376,-176],"parameters":{"mode":"runOnceForEachItem","jsCode":"const companies = $json.companies || [];\n\nlet maxChangedTime = 0;\n\nfor (const c of companies) {\n  const t = Number(c.changed_time);\n  if (t > maxChangedTime) maxChangedTime = t;\n}\n\nreturn { lastSync: maxChangedTime || Math.floor(Date.now() / 1000) };"},"typeVersion":2},{"id":"47215474-0718-4f5f-b952-32d8842ec1ab","name":"Sticky Note8","type":"n8n-nodes-base.stickyNote","position":[-96,-624],"parameters":{"width":560,"height":784,"content":"## B2. Custom polling 2: optimal, more config\nWhen you're working with unstable API's, \"B1\" doesn't cover all edge cases. Sometimes there's nothing you can do about that. But when your source meets the additional requirements, and you don't mind a little extra config, **you should always prefer B2 over B1**.\n\n**Additional requirements:**\n- Datasource supports sorting by date (asc) and setting a limited number of results per API call.\n\n\n**Pagination:**\n- This pattern does not include pagination.\n- Pagination is redundant as this workflow can call itself when it's done. This is called a \"recursive loop\" pattern. **Warning:** be very careful when creating loops. It's your responsibility to stop them!\n- Need for pagination can be prevented altogether by triggering on such intervals no spillage arises.\n\n\n**Remarks:**\n- Error handling in not yet included (and required for proper use)."},"typeVersion":1},{"id":"1c9c09de-b493-40b2-8bd5-be72ced75449","name":"Sticky Note22","type":"n8n-nodes-base.stickyNote","position":[2176,-1440],"parameters":{"color":5,"width":320,"height":304,"content":"### Choose: A1 or A2?"},"typeVersion":1},{"id":"5905d68d-17c5-4f7d-8668-ad7347f0e999","name":"Sticky Note23","type":"n8n-nodes-base.stickyNote","position":[2176,-624],"parameters":{"color":5,"width":320,"height":304,"content":"### Choose: A1 or A2?"},"typeVersion":1},{"id":"d279116f-0350-49d3-a387-f861fe08ec3e","name":"Sticky Note24","type":"n8n-nodes-base.stickyNote","position":[480,-304],"parameters":{"color":3,"width":384,"height":304,"content":"### B2 - Enable looping (optional)\nAllow this workflow to call itself. **Warning:** be very careful when creating loops.\n\n\n[ Add a 2nd trigger here (\"When executed by another workflow\") ]"},"typeVersion":1},{"id":"3ca4985c-d4c9-4cb5-92d0-e4cd21fda19a","name":"Sticky Note25","type":"n8n-nodes-base.stickyNote","position":[2512,-624],"parameters":{"color":3,"width":400,"height":304,"content":"### DANGER ZONE (optional): repeat\nWarning: be very careful when creating (potentially infinite) loops. It's your responsibility to close them!"},"typeVersion":1},{"id":"783242c9-4e16-4cd8-a800-a0cae4e577b8","name":"Sticky Note26","type":"n8n-nodes-base.stickyNote","position":[480,192],"parameters":{"color":5,"width":384,"height":304,"content":"### B3 - Start sync\nSelect your timer interval, choose a name for your data table variable and (optionally) set a max. number of results per page."},"typeVersion":1},{"id":"dda2f123-2527-4631-9233-f37bc4e31749","name":"Sticky Note27","type":"n8n-nodes-base.stickyNote","position":[880,192],"parameters":{"color":5,"width":624,"height":304,"content":"### B3 - Get/set lastSync & setup pagination\nGet the time of the last execution or start from 0 (first run only). Also; reset the pagination for the last run."},"typeVersion":1},{"id":"17c308ff-5869-4d7a-a174-1bf967ab608a","name":"Sticky Note28","type":"n8n-nodes-base.stickyNote","position":[1920,832],"parameters":{"color":5,"width":880,"height":464,"content":"### B3 - Create/update database entry\nGet the timestamp that corresponds with the most recent result in the response. This works because the HTTP node is setup in a away results are filtered by \"date\", sorted \"oldest-to-newest\", and limitted to a desired amount. When there's more results than the limit, you'll pick those up automatically in the next run."},"typeVersion":1},{"id":"81464c02-5d3e-4b3c-861a-fe06a8afe03e","name":"Sticky Note29","type":"n8n-nodes-base.stickyNote","position":[1920,512],"parameters":{"color":5,"width":288,"height":304,"content":"### B3 - Fetch new items\nRetrieve items that have been created/updated/.. since this workflow last ran."},"typeVersion":1},{"id":"ca7ec11e-88c1-452c-b332-c44b2f2950e8","name":"Sticky Note30","type":"n8n-nodes-base.stickyNote","position":[2528,512],"parameters":{"color":5,"width":576,"height":304,"content":"### B3 - Validate, prepare & filter items\nTo cover all grounds, this is where you modify the results you get from the service you're using. ***Completely optional, probably even redundant.***"},"typeVersion":1},{"id":"63f3210b-acc5-4220-b6cb-351d1e2611fd","name":"Sticky Note31","type":"n8n-nodes-base.stickyNote","position":[-96,192],"parameters":{"width":560,"height":1104,"content":"## B3 - Custom polling 3: complete, most config\nSometimes you just need it all; full control over everything. This manual polling setup gives you just that. Use it only in cases where you actually need it, as this one comes with potential downsides.\n\n**Additional requirements:**\n- Datasource supports sorting by date (asc), setting limited number of results per page, setting page.\n\n\n**Remarks:**\n- Pagination in triggers isn't always desirable; it adds complexity, it increases chances of hitting rate-limits and causes long execution runs / high memory usage. Consider B2 as an alternative.\n- Delay options need to be customized for optimal use.\n- Error handling in not yet included (and required for proper use).\n- Not all pagination works the same: both paging and offsetting are available in this pattern, just complete the config according to your service's requirements.\n\n\n**Final note on pagination mechanics:**\n- You've noticed we don't use the build in pagination (HTTP node, \"B3 - Get items\"). This is has 2 reasons; consistency throughout custom nodes (not all nodes have build in pagination) and, more importantly: there's a difference between \"get 1.000 items at and process them\" and \"get 10 items, process them, than repeat until there's no items left\".\n- Or, as ChatGPT calls it: \"We intentionally paginate manually to enforce page-wise processing: fetch N items → process N items → checkpoint → repeat until empty. This avoids large in-memory batches, allows partial progress, and makes checkpointing reliable across long runs and failures.\"\n- In this pattern, pagination is stored in the workflow data. As this data is shared between executions, it's imperative you ensure executions don't overlap. That being said: you should prevent those situations anyways. Simply keep your batch size and trigger interval in balance.\n\n\n**Pro tip:** \nA **reset** *(B3 - Get/set lastSync & setup pagination)* feels like something you do \"when you're done\". And you're right. Trouble is; any unforeseen situation will prevent a reset, if you put it at the end. In other words: always reset before you start. And optionally do it again at the end if you want to be perfectionistic."},"typeVersion":1},{"id":"90dac894-c3b7-4b16-aef4-8035e4acbf8d","name":"Sticky Note35","type":"n8n-nodes-base.stickyNote","position":[-96,-624],"parameters":{"color":7,"width":3008,"height":784,"content":""},"typeVersion":1},{"id":"bf60abd5-74b2-4b48-84cc-14feae60f954","name":"Sticky Note36","type":"n8n-nodes-base.stickyNote","position":[-96,192],"parameters":{"color":7,"width":3872,"height":1104,"content":""},"typeVersion":1},{"id":"af297466-0573-4f71-b536-93da81f05280","name":"B3 - Schedule Trigger","type":"n8n-nodes-base.scheduleTrigger","position":[528,320],"parameters":{"rule":{"interval":[{}]}},"typeVersion":1.3},{"id":"e15709de-4b98-42be-8dab-c0c18dc0af1d","name":"B3 - Set variables","type":"n8n-nodes-base.set","position":[720,320],"parameters":{"options":{},"assignments":{"assignments":[{"id":"4e1e9007-e49b-432d-a4a1-7ecd35c22268","name":"timestamp_key","type":"string","value":"demo_timestamp"},{"id":"3ff8a838-a321-4245-8c11-fdb4b0b819c1","name":"limit","type":"number","value":20}]}},"typeVersion":3.4},{"id":"c6b0396e-e320-4882-8b5e-416ccffb2508","name":"B3 - Get timestamp","type":"n8n-nodes-base.dataTable","onError":"continueErrorOutput","position":[944,320],"parameters":{"limit":1,"filters":{"conditions":[{"keyName":"key","keyValue":"={{$('B3 - Set variables').first().json.timestamp_key}}"}]},"matchType":"allConditions","operation":"get","dataTableId":{"__rl":true,"mode":"list","value":"8MPVpHDnVGj4PBZR","cachedResultUrl":"/projects/tgy2Tl0HCDQH0Rbt/datatables/8MPVpHDnVGj4PBZR","cachedResultName":"Timestamps"}},"typeVersion":1,"alwaysOutputData":true},{"id":"6026d602-c3e8-4836-a366-1cbef97c669b","name":"B3 - Set lastSync","type":"n8n-nodes-base.code","position":[1152,320],"parameters":{"mode":"runOnceForEachItem","jsCode":"return { lastSync: Math.floor(new Date($json.value || 0).getTime() / 1000) };"},"typeVersion":2},{"id":"498860cb-49ff-498b-bada-97a54b58700e","name":"B3 - Get Items","type":"n8n-nodes-base.httpRequest","onError":"continueErrorOutput","position":[2000,640],"parameters":{"url":"=https://api.prospectpro.nl/v1.2/prospects","options":{},"sendQuery":true,"authentication":"predefinedCredentialType","queryParameters":{"parameters":[{"name":"from_last_visit","value":"={{ $json.lastSync }}"},{"name":"sort_by","value":"last_visit"},{"name":"sort_order","value":"asc"},{"name":"limit","value":"={{ $('B3 - Set variables').first().json?.limit || undefined }}"},{"name":"page","value":"={{ $json.page }}"}]},"nodeCredentialType":"prospectproApi"},"credentials":{"prospectproApi":{"id":"yyRRf0HzQaW21btS","name":"TESTACCOUNT"}},"typeVersion":4.2},{"id":"2172335e-50c1-450d-b994-256dd5f4bc20","name":"Sticky Note33","type":"n8n-nodes-base.stickyNote","position":[1520,192],"parameters":{"color":5,"width":384,"height":304,"content":"### B3 - Pagination\nInitiate pagination."},"typeVersion":1},{"id":"c69f89f1-7af3-43f4-992a-f12a31ac1840","name":"B3 - Has Items?","type":"n8n-nodes-base.if","position":[2576,640],"parameters":{"options":{},"conditions":{"options":{"version":2,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"84fc2faf-74e7-4bea-9d75-630f55288bef","operator":{"type":"boolean","operation":"true","singleValue":true},"leftValue":"={{ $json.found > 0 }}","rightValue":""}]}},"typeVersion":2.2},{"id":"d1098c8c-e0d2-42d6-89f8-fc8972d70b96","name":"B3 - Items","type":"n8n-nodes-base.splitOut","position":[2768,640],"parameters":{"options":{},"fieldToSplitOut":"items"},"typeVersion":1},{"id":"aa62c8c7-8cc3-4037-9641-f58d37eb1a54","name":"B3 - Filter Items","type":"n8n-nodes-base.filter","position":[2944,640],"parameters":{"options":{},"conditions":{"options":{"version":2,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"b65f03ae-26bc-4bc7-a77c-74a072a3d98b","operator":{"type":"boolean","operation":"true","singleValue":true},"leftValue":"={{ !!$json.updated_time && $json.updated_time > $('B3 - Set lastSync').first().json.lastSync }}","rightValue":""}]}},"typeVersion":2.2,"alwaysOutputData":true},{"id":"f7c0c135-723f-4e6d-81c1-734e622df93a","name":"B3 - Update lastSync","type":"n8n-nodes-base.code","position":[2016,960],"parameters":{"mode":"runOnceForEachItem","jsCode":"const companies = $json.companies || [];\n\nlet maxChangedTime = 0;\n\nfor (const c of companies) {\n  const t = Number(c.changed_time);\n  if (t > maxChangedTime) maxChangedTime = t;\n}\n\nreturn { lastSync: maxChangedTime || Math.floor(Date.now() / 1000) };"},"typeVersion":2},{"id":"07b6216f-8a09-438c-8eb9-19fb810a4605","name":"B3 - Has timestamp / not first run?","type":"n8n-nodes-base.if","position":[2208,960],"parameters":{"options":{},"conditions":{"options":{"version":3,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"7dfd60f6-fb39-41dd-b013-8fd4591a44a3","operator":{"type":"boolean","operation":"true","singleValue":true},"leftValue":"={{ !!$('B3 - Get timestamp').first().json.id }}","rightValue":""}]}},"typeVersion":2.3},{"id":"20743066-2664-4e04-ab8c-2cd9d384ef0d","name":"B3 - Update timestamp","type":"n8n-nodes-base.dataTable","position":[2400,960],"parameters":{"columns":{"value":{"value":"={{ $json.lastSync }}"},"schema":[{"id":"key","type":"string","display":true,"removed":true,"readOnly":false,"required":false,"displayName":"key","defaultMatch":false},{"id":"value","type":"dateTime","display":true,"removed":false,"readOnly":false,"required":false,"displayName":"value","defaultMatch":false}],"mappingMode":"defineBelow","matchingColumns":[],"attemptToConvertTypes":false,"convertFieldsToString":false},"filters":{"conditions":[{"keyValue":"={{ !!$('B3 - Get timestamp').first().json.id }}"},{"keyName":"key","keyValue":"={{$('B3 - Set variables').first().json.timestamp_key}}"}]},"options":{},"matchType":"allConditions","operation":"update","dataTableId":{"__rl":true,"mode":"list","value":"8MPVpHDnVGj4PBZR","cachedResultUrl":"/projects/tgy2Tl0HCDQH0Rbt/datatables/8MPVpHDnVGj4PBZR","cachedResultName":"Timestamps"}},"typeVersion":1},{"id":"be7eb158-fa65-45c0-8b9e-a747efa4e9a5","name":"B3 - Create timestamp","type":"n8n-nodes-base.dataTable","position":[2400,1120],"parameters":{"columns":{"value":{"key":"={{$('B3 - Set variables').first().json.timestamp_key}}","value":"={{ $json.lastSync }}"},"schema":[{"id":"key","type":"string","display":true,"removed":false,"readOnly":false,"required":false,"displayName":"key","defaultMatch":false},{"id":"value","type":"dateTime","display":true,"removed":false,"readOnly":false,"required":false,"displayName":"value","defaultMatch":false}],"mappingMode":"defineBelow","matchingColumns":[],"attemptToConvertTypes":false,"convertFieldsToString":false},"options":{},"dataTableId":{"__rl":true,"mode":"list","value":"8MPVpHDnVGj4PBZR","cachedResultUrl":"/projects/tgy2Tl0HCDQH0Rbt/datatables/8MPVpHDnVGj4PBZR","cachedResultName":"Timestamps"}},"typeVersion":1},{"id":"62e8e8e2-cd18-4349-9304-94769bfcc345","name":"B3 - No Operation, do nothing","type":"n8n-nodes-base.noOp","position":[2592,1120],"parameters":{},"typeVersion":1},{"id":"428f272f-292b-44ac-a60a-6a6dc7c52fb7","name":"B3 - Set pagination","type":"n8n-nodes-base.code","position":[1568,320],"parameters":{"mode":"runOnceForEachItem","jsCode":"const lastSync = $('B3 - Set lastSync').first().json.lastSync || 0;\nconst limit = $('B3 - Set variables').first().json.limit || 1;\n\nconst store = $getWorkflowStaticData('global');\nstore.page = store.page ? store.page + 1 : 1;\nstore.processed = store.processed ? store.processed + limit : limit;\n\nreturn {\n  page: store.page,\n  processed: store.processed,\n  total_pages: store.total_pages || 1,\n  offset: store.processed - limit,\n  lastSync\n};"},"typeVersion":2},{"id":"4b78191c-004e-4935-82d1-e362beb66d52","name":"B3 - Done looping?","type":"n8n-nodes-base.if","position":[1760,320],"parameters":{"options":{},"conditions":{"options":{"version":3,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"76012237-ffdf-4423-8f56-88216d1de64a","operator":{"type":"boolean","operation":"true","singleValue":true},"leftValue":"={{ $json.page > $json.total_pages }}","rightValue":""}]}},"typeVersion":2.3},{"id":"702a7097-4bbe-480c-9d00-725c25fc0fc9","name":"Sticky Note34","type":"n8n-nodes-base.stickyNote","position":[2224,512],"parameters":{"color":5,"width":288,"height":304,"content":"### B3 - Update pagination\nDetermine whether this is the last page. Needs customization depending on the service you use."},"typeVersion":1},{"id":"d5d6fedf-d616-427b-a51c-790dbabbc901","name":"B3 - Update pagination","type":"n8n-nodes-base.code","position":[2320,640],"parameters":{"mode":"runOnceForEachItem","jsCode":"const store = $getWorkflowStaticData('global');\nconst limit = $('B3 - Set variables').first().json.limit;\n\nconst wp_pages = $json.headers?.[\"x-wp-totalpages\"] ?? false;\nconst last = $json.last ?? false;\nconst total = $json.total ?? false;\nconst next = $json.next ?? false;\n\nconst total_pages = store.total_pages || 1;\n\nstore.total_pages = wp_pages || last || total ? Math.ceil(total / limit) : next ? total_pages + 1 : total_pages;\n\nreturn $json;"},"typeVersion":2},{"id":"813c9b0e-46e7-4ab9-9bb3-63850d520c1d","name":"Wait","type":"n8n-nodes-base.wait","position":[1664,640],"webhookId":"94de3a58-7ad6-412e-8f70-a78962656163","parameters":{},"typeVersion":1.1},{"id":"bcf9478c-2f5d-4bbb-8383-a692344a2609","name":"Sticky Note37","type":"n8n-nodes-base.stickyNote","position":[3120,512],"parameters":{"color":5,"width":656,"height":384,"content":"### A2 - Rate-limited individual processing\nUse this pattern when your trigger can output a sufficiently large number of items that it will trigger rate limits in the services you're using."},"typeVersion":1},{"id":"b9089c70-b198-474f-99a3-c9ab0d947262","name":"B3 - Create Batches","type":"n8n-nodes-base.splitInBatches","position":[3200,624],"parameters":{"options":{},"batchSize":10},"typeVersion":3},{"id":"2593cc27-7b52-4150-b4a3-3a70a5fa2b9b","name":"B3 - Process one item at a time","type":"n8n-nodes-base.executeWorkflow","onError":"continueRegularOutput","position":[3408,688],"parameters":{"mode":"each","options":{"waitForSubWorkflow":true},"workflowId":{"__rl":true,"mode":"list","value":"IdtvYdzQ2uGp7quU","cachedResultUrl":"/workflow/IdtvYdzQ2uGp7quU","cachedResultName":"Subflow - TEMPLATE"},"workflowInputs":{"value":{},"schema":[{"id":"id","type":"string","display":true,"removed":false,"required":false,"displayName":"id","defaultMatch":false,"canBeUsedToMatch":true}],"mappingMode":"defineBelow","matchingColumns":["id"],"attemptToConvertTypes":false,"convertFieldsToString":true}},"typeVersion":1.3},{"id":"b456e9e2-705a-4ba3-8658-b46ef21a67f7","name":"B3 - Delay after each batch","type":"n8n-nodes-base.wait","position":[3600,688],"webhookId":"0056cbae-6dba-473d-ba7a-86180b265c98","parameters":{},"typeVersion":1.1},{"id":"755a3d90-6edc-4adf-879e-44f846ec9bca","name":"Sticky Note38","type":"n8n-nodes-base.stickyNote","position":[1520,512],"parameters":{"color":5,"width":384,"height":304,"content":"### B3 - Pagination delay\nDelay after each page that has been processed."},"typeVersion":1},{"id":"57f88a7a-1e1a-4656-8f27-d9f8e2285a1d","name":"Sticky Note32","type":"n8n-nodes-base.stickyNote","position":[-96,1328],"parameters":{"width":566,"height":400,"content":"## C. Manual triggers: introduction\n\"But what do we do with the data that's already there?\" Sooner or later this question arises. Because when your automation \"works\", someone is going to want to apply it retroactively.\n\nBut there's more cases where manual triggers come in handy:\n- Re-processing events after errors\n- Bridging gaps that arise from downtime/n8n updates\n- Development and testing\n\n\n**Remarks:**\n- Manually triggering a process is obviously not that complicated *when you design your workflows modularly*.\n- But; adding pagination and rate limits is deceptively tricky. And more often than not, n8n engineers waste hours finding solutions to these generic problems. These templates are intended to eliminate that waste and speed up every day development."},"typeVersion":1},{"id":"2f70df4e-5295-448b-a2ac-4bfa045bfd84","name":"Sticky Note40","type":"n8n-nodes-base.stickyNote","position":[-96,1328],"parameters":{"color":7,"width":1152,"height":400,"content":""},"typeVersion":1},{"id":"13e8922b-7d20-4465-8440-7e636f881d48","name":"When clicking ‘Execute workflow’","type":"n8n-nodes-base.manualTrigger","disabled":true,"position":[560,1472],"parameters":{},"typeVersion":1},{"id":"0e951a9d-dfe1-43c1-995e-80278b20fc8d","name":"Sticky Note39","type":"n8n-nodes-base.stickyNote","position":[-96,1744],"parameters":{"width":566,"height":384,"content":"## C2. Manual triggers: throttled, no pagination\nUse this loop when:\n- Your service doesn't support pagination\n- There's only few items to process incidentally\n\n\n**What's \"throttling\"?**\n- Most APIs have \"rate-limits\", meaning you can only make so many requests in a certain amount of time.\n- If you're processing many items simultaneously, you'll hit those limits sooner than you'd think.\n- Rate limit issues are hard to deal when they occur as they cause cascading issues. But they're relatively easy to prevent. Simply adjust the batch size and the delays between batches and you're good to go."},"typeVersion":1},{"id":"4da72402-a55d-4881-a0ea-c63c4e085a76","name":"Sticky Note41","type":"n8n-nodes-base.stickyNote","position":[-96,1744],"parameters":{"color":7,"width":2416,"height":384,"content":""},"typeVersion":1},{"id":"ecbac8ac-23ea-468c-9879-ab00deb6dff8","name":"Sticky Note42","type":"n8n-nodes-base.stickyNote","position":[-96,2144],"parameters":{"width":566,"height":432,"content":"## C3. Manual triggers: throttled and paginated\nUse this loop when:\n- Your service supports pagination\n- You need a stable, scalable solution\n\n\nWhy not use a \"recursive\" pattern?\n-  true; having the workflow call itself after each page of results increases traceability.\n- but; when working with n8n manually, this pattern is more easily managed.\n- and; this pattern is more intuitive to beginners (i.e. whomever you'd want to handover your project to whenever you're done)\n\n\n**Remarks:**\n- This template **does not** attempt to check if there's actually more pages available after initiating another call. In other words; **if an API call doesn't yield results (\"C3 - Has Items?\"), the loop should be interrupted**.\n- We recommend sticking to this design decision, as (1) you'll be managing this flow manually and (2) this setup reduces setup time."},"typeVersion":1},{"id":"6b9958ae-1a95-4c5f-ac17-12eee9f6f0ce","name":"Sticky Note43","type":"n8n-nodes-base.stickyNote","position":[-96,2144],"parameters":{"color":7,"width":3328,"height":432,"content":""},"typeVersion":1},{"id":"6b312db7-77d6-4af9-aa8a-89f9b1b3a864","name":"C2 - Get Items","type":"n8n-nodes-base.httpRequest","onError":"continueErrorOutput","position":[864,1888],"parameters":{"url":"=https://api.prospectpro.nl/v1.2/prospects","options":{},"sendQuery":true,"queryParameters":{"parameters":[{}]}},"typeVersion":4.2},{"id":"1af798e5-d8c7-4320-b9f9-3abbba287570","name":"C2 - Has Items?","type":"n8n-nodes-base.if","position":[1136,1888],"parameters":{"options":{},"conditions":{"options":{"version":2,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"84fc2faf-74e7-4bea-9d75-630f55288bef","operator":{"type":"boolean","operation":"true","singleValue":true},"leftValue":"={{ $json.found > 0 }}","rightValue":""}]}},"typeVersion":2.2},{"id":"ea86e299-1a34-45a0-bb27-c4398bd49e95","name":"C2 - Items","type":"n8n-nodes-base.splitOut","position":[1328,1888],"parameters":{"options":{},"fieldToSplitOut":"items"},"typeVersion":1},{"id":"620a6db7-b92b-4c95-83a5-7bc72d0e6c7d","name":"C2 - Filter Items","type":"n8n-nodes-base.filter","position":[1504,1888],"parameters":{"options":{},"conditions":{"options":{"version":2,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"b65f03ae-26bc-4bc7-a77c-74a072a3d98b","operator":{"type":"boolean","operation":"true","singleValue":true},"leftValue":"={{ !!$json.updated_time && $json.updated_time > $('B1 - Set lastSync').first().json.lastSync }}","rightValue":""}]}},"typeVersion":2.2,"alwaysOutputData":true},{"id":"96ce4295-38f2-4a19-84d7-046eb320cccb","name":"C2 - Create Batches","type":"n8n-nodes-base.splitInBatches","position":[1744,1856],"parameters":{"options":{},"batchSize":10},"typeVersion":3},{"id":"81b97338-8b57-432e-bed9-8556113b1fb3","name":"C2 - Process one item at a time","type":"n8n-nodes-base.executeWorkflow","position":[1952,1920],"parameters":{"mode":"each","options":{"waitForSubWorkflow":true},"workflowId":{"__rl":true,"mode":"list","value":"IdtvYdzQ2uGp7quU","cachedResultUrl":"/workflow/IdtvYdzQ2uGp7quU","cachedResultName":"Subflow - TEMPLATE"},"workflowInputs":{"value":{},"schema":[{"id":"id","type":"string","display":true,"removed":false,"required":false,"displayName":"id","defaultMatch":false,"canBeUsedToMatch":true}],"mappingMode":"defineBelow","matchingColumns":["id"],"attemptToConvertTypes":false,"convertFieldsToString":true}},"typeVersion":1.3},{"id":"61ec2ff6-4482-472c-9100-4adc3b79d691","name":"C1 - Process one item at a time","type":"n8n-nodes-base.executeWorkflow","position":[864,1472],"parameters":{"mode":"each","options":{"waitForSubWorkflow":true},"workflowId":{"__rl":true,"mode":"list","value":"IdtvYdzQ2uGp7quU","cachedResultUrl":"/workflow/IdtvYdzQ2uGp7quU","cachedResultName":"Subflow - TEMPLATE"},"workflowInputs":{"value":{},"schema":[{"id":"id","type":"string","display":true,"removed":false,"required":false,"displayName":"id","defaultMatch":false,"canBeUsedToMatch":true}],"mappingMode":"defineBelow","matchingColumns":["id"],"attemptToConvertTypes":false,"convertFieldsToString":true}},"typeVersion":1.3},{"id":"f7389dec-d2f8-4b0e-a9db-45abdc7de3a7","name":"C2 - Delay after each batch","type":"n8n-nodes-base.wait","position":[2144,1920],"webhookId":"0056cbae-6dba-473d-ba7a-86180b265c98","parameters":{},"typeVersion":1.1},{"id":"0ca8f1e4-5334-4d35-a604-66e3df54f2cf","name":"C3 - Set variables","type":"n8n-nodes-base.set","position":[864,2288],"parameters":{"options":{},"assignments":{"assignments":[{"id":"3ff8a838-a321-4245-8c11-fdb4b0b819c1","name":"limit","type":"number","value":20}]}},"typeVersion":3.4},{"id":"7666390c-597a-41f5-b580-7bb49fb752a5","name":"C3 - Set pagination","type":"n8n-nodes-base.code","position":[1168,2288],"parameters":{"mode":"runOnceForEachItem","jsCode":"const limit = $('C3 - Set variables').first().json?.limit || 1;\n\nconst store = $getWorkflowStaticData('global');\nstore.page = store.page ? store.page + 1 : 1;\n\nstore.processed = store.processed ? store.processed + limit : limit;\n\nreturn {\n  page: store.page,\n  processed: store.processed,\n  offset: store.processed - limit\n};"},"typeVersion":2},{"id":"f318f494-9063-4970-9f93-b122ead9ee41","name":"C3 - Get Items","type":"n8n-nodes-base.httpRequest","onError":"continueErrorOutput","position":[1472,2288],"parameters":{"url":"=https://api.prospectpro.nl/v1.2/prospects","options":{},"sendQuery":true,"authentication":"predefinedCredentialType","queryParameters":{"parameters":[{"name":"limit","value":"={{ $('B3 - Set variables').first().json?.limit || undefined }}"},{"name":"page","value":"={{ $json.page }}"}]},"nodeCredentialType":"prospectproApi"},"credentials":{"prospectproApi":{"id":"yyRRf0HzQaW21btS","name":"TESTACCOUNT"}},"typeVersion":4.2},{"id":"42f38b67-5ddb-4459-bb1d-59cc513a8268","name":"C3 - Has Items?","type":"n8n-nodes-base.if","position":[1728,2288],"parameters":{"options":{},"conditions":{"options":{"version":2,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"84fc2faf-74e7-4bea-9d75-630f55288bef","operator":{"type":"boolean","operation":"true","singleValue":true},"leftValue":"={{ $json.found > 0 }}","rightValue":""}]}},"typeVersion":2.2},{"id":"4898248b-b3ce-414a-87d0-a4a7166938c3","name":"C3 - Items","type":"n8n-nodes-base.splitOut","position":[1936,2288],"parameters":{"options":{},"fieldToSplitOut":"items"},"typeVersion":1},{"id":"52a89633-8f9c-437f-95ec-2a1e0328b017","name":"C3 - Filter Items","type":"n8n-nodes-base.filter","position":[2112,2288],"parameters":{"options":{},"conditions":{"options":{"version":2,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"b65f03ae-26bc-4bc7-a77c-74a072a3d98b","operator":{"type":"boolean","operation":"true","singleValue":true},"leftValue":"={{ !!$json.updated_time && $json.updated_time > $('B3 - Set lastSync').first().json.lastSync }}","rightValue":""}]}},"typeVersion":2.2,"alwaysOutputData":true},{"id":"964595fd-c626-4514-b37b-1c8a59447859","name":"C3 - Create Batches","type":"n8n-nodes-base.splitInBatches","position":[2352,2272],"parameters":{"options":{},"batchSize":10},"typeVersion":3},{"id":"46b2dc19-f9f4-43e4-bc29-abfeb25530eb","name":"C3 - Process one item at a time","type":"n8n-nodes-base.executeWorkflow","onError":"continueRegularOutput","position":[2560,2336],"parameters":{"mode":"each","options":{"waitForSubWorkflow":true},"workflowId":{"__rl":true,"mode":"list","value":"IdtvYdzQ2uGp7quU","cachedResultUrl":"/workflow/IdtvYdzQ2uGp7quU","cachedResultName":"Subflow - TEMPLATE"},"workflowInputs":{"value":{},"schema":[{"id":"id","type":"string","display":true,"removed":false,"required":false,"displayName":"id","defaultMatch":false,"canBeUsedToMatch":true}],"mappingMode":"defineBelow","matchingColumns":["id"],"attemptToConvertTypes":false,"convertFieldsToString":true}},"typeVersion":1.3},{"id":"ea6b3241-c39c-4f6e-a66b-0df0ef751c52","name":"C3 - Delay after each batch","type":"n8n-nodes-base.wait","position":[2752,2336],"webhookId":"0056cbae-6dba-473d-ba7a-86180b265c98","parameters":{},"typeVersion":1.1},{"id":"7ca87e28-407f-4895-b6d0-6b1e0409c7e9","name":"C3 - Wait","type":"n8n-nodes-base.wait","position":[3040,2288],"webhookId":"94de3a58-7ad6-412e-8f70-a78962656163","parameters":{},"typeVersion":1.1},{"id":"e00e521c-5912-45e5-a4d8-1fd9dcd75804","name":"B2 - Needs loop?","type":"n8n-nodes-base.if","disabled":true,"position":[2560,-496],"parameters":{"options":{},"conditions":{"options":{"version":3,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"9f3162bd-aebe-43a1-8fc6-0ebd7367106f","operator":{"type":"boolean","operation":"true","singleValue":true},"leftValue":"={{ !!$('B2 - Get Items').first().json.found && !!$('B2 - Get Items').first().json.total && $('B2 - Get Items').first().json.found < $('B2 - Get Items').first().json.total }}","rightValue":""}]}},"typeVersion":2.3},{"id":"bf1a5cab-062f-44db-b242-6a0f7c1c7cbe","name":"B2 - Call [this workflow]","type":"n8n-nodes-base.executeWorkflow","disabled":true,"position":[2768,-496],"parameters":{"options":{},"workflowId":{"__rl":true,"mode":"list","value":"w0NDnlGr_-uqHUHVrgPM_","cachedResultUrl":"/workflow/w0NDnlGr_-uqHUHVrgPM_","cachedResultName":"Trigger Patterns"},"workflowInputs":{"value":{},"schema":[],"mappingMode":"defineBelow","matchingColumns":[],"attemptToConvertTypes":false,"convertFieldsToString":true}},"typeVersion":1.3},{"id":"fda99e89-be08-4e62-9df0-fdb3d0c736ce","name":"Sticky Note47","type":"n8n-nodes-base.stickyNote","position":[-96,3024],"parameters":{"width":566,"height":768,"content":"## D. Workflow types: \"Managers\"\nManagers orchestrate multi-step processes that should be applied to an item. Managers always receive the item from the trigger.\n\n**Managers are intended for 2 things:**\n1. Create and manage large processes efficiently\n2. Prevent 3 types of fundamental errors that often occur (see \"D1\" below)\n\n\nOn right the you can see how (1) works: as the manager-workflow only deals with steps (and doens't do any \"work\" itself), you're able to move stuff around, A/B-test or optimize much more quickly than you normally would.\n\nIn practise however; (2) is a much more important reason for using managers. Check out \"D1\" below to find out why.\n\n**When executed by another workflow:**\nThe \"trigger\" (in the n8n sense of the word) is always the same: \"When executed by another workflow\", or better; when executed by the **manager-workflow**. You can choose whether to accept the entire item, or just the ID. We generally opt for the latter, and **refresh*** records nice and often.\n\n**(*) Fundamental knowledge:**\nConsider trigger \"A2\" (see above). It's important to realise the trigger might not immediately pass on an item to a manager. That means it isn't necessarily \"fresh\" when it arrives: if your trigger contains delays (which it often should because of scalability) and your item changes often (like crm-records that are being edited by a sales rep.) you could potentially have missed an update at the moment the manager-workflow starts. Usually, that doesn't matter. But if you're using it in a consequential way, you should fetch the record before you start (like in \"D1 - Get prospect\")."},"typeVersion":1},{"id":"f92efe4a-3af0-4f19-97a8-e7c1a70bf526","name":"Sticky Note48","type":"n8n-nodes-base.stickyNote","position":[-96,3024],"parameters":{"color":7,"width":2496,"height":768,"content":""},"typeVersion":1},{"id":"5e34d286-03ad-41d2-abc5-79f01ac80b78","name":"Sticky Note49","type":"n8n-nodes-base.stickyNote","position":[-96,5904],"parameters":{"width":566,"height":752,"content":"## E. Workflow types: \"Functions\"\nFunction workflows perform one well-defined task on an item in a self-contained, reusable way. Nice. But what does it mean?\n\n1. Functions are called by manager-workflow or other function-workflows\n2. Functions perform a task from A-to-Z\n3. Functions may report their outcome back to their parent (1), but they shouldn't rely on they parent to process that output meaningfully\n\n\n**Examples:**\n- Sync a company record to your CRM\n- Qualify a company using AI\n- Create a response to an email\n\n\n**Remarks:**\n- In function-workflows, it's best practise to refresh the item you're working with before starting. This provides flexibility in parent workflows.\n- Adding guards should be considered non-optional: it's much better to quit early than make a bunch of API calls you know will fail.\n- Function workflows need to return the same amount of items they get (one!). Any dead ends in your workflow should be followed by a \"No nothing\"-node (i.e. not return anything).\n- Success & error indicators are optional, but recommended: it never hurts to know what process an item has gone through.\n"},"typeVersion":1},{"id":"b5464f6d-3e9e-4b27-83ea-c39b586c201c","name":"Sticky Note50","type":"n8n-nodes-base.stickyNote","position":[-96,5904],"parameters":{"color":7,"width":3696,"height":752,"content":""},"typeVersion":1},{"id":"16bd78dd-98a4-486f-a823-db4a2b0f0c60","name":"Sticky Note51","type":"n8n-nodes-base.stickyNote","position":[-96,6672],"parameters":{"width":566,"height":416,"content":"## F. Workflow types: \"Utilities\"\nUtility workflows provide helper functionality for other workflows.\n\nUtility workflows:\n1. Are called by manager- and/or function-workflows to perform tasks\n2. Return they're results and rely fully on their parent to proces the results in a meaningful way\n3. Should be designed to be used for highly specific tasks in a broad array of situations\n\n\n**Examples:**\n- Check if a company exists in your CRM and return the ID if it does\n- Calculate a lead score by specific input variables\n- Create dynamic prompts that functions require to work with agents"},"typeVersion":1},{"id":"d2497604-b165-4e81-9772-1a2f9a60d109","name":"Sticky Note52","type":"n8n-nodes-base.stickyNote","position":[-96,6672],"parameters":{"color":7,"width":2704,"height":416,"content":""},"typeVersion":1},{"id":"f75fa59e-45b9-4d2f-b20f-c3eb1d306758","name":"Sticky Note53","type":"n8n-nodes-base.stickyNote","position":[768,1328],"parameters":{"color":5,"width":288,"height":400,"content":"### C1 - Simple example."},"typeVersion":1},{"id":"968c5d04-6880-45d0-b409-da59aa62898d","name":"Sticky Note54","type":"n8n-nodes-base.stickyNote","position":[768,1744],"parameters":{"color":5,"width":288,"height":384,"content":"### C2 - All items\nRetrieve items all items at once."},"typeVersion":1},{"id":"80c7a10e-7987-49d8-998b-052f396d005b","name":"Sticky Note55","type":"n8n-nodes-base.stickyNote","position":[1072,1744],"parameters":{"color":5,"width":576,"height":384,"content":"### C2 - Validate, prepare & filter items\nTo cover all grounds, this is where you modify the results you get from the service you're using. ***Completely optional, probably even redundant.***"},"typeVersion":1},{"id":"83ee65a1-4e24-4d51-ab76-d0af2ca98c1e","name":"Sticky Note56","type":"n8n-nodes-base.stickyNote","position":[1664,1744],"parameters":{"color":5,"width":656,"height":384,"content":"### C2 - Rate-limited individual processing\nUse this pattern when your trigger can output a sufficiently large number of items that it will trigger rate limits in the services you're using."},"typeVersion":1},{"id":"fb1f6f56-1b60-474a-b9a0-92a7ce5608e7","name":"Sticky Note57","type":"n8n-nodes-base.stickyNote","position":[768,2144],"parameters":{"color":5,"width":288,"height":432,"content":"### C3 - Setup\nSetup workflow variables."},"typeVersion":1},{"id":"0471651a-7a1f-43c0-8376-fc166c7a7a06","name":"Sticky Note58","type":"n8n-nodes-base.stickyNote","position":[1072,2144],"parameters":{"color":5,"width":288,"height":432,"content":"### C3 - Loop\n(re-)Initiate loop."},"typeVersion":1},{"id":"2f6c9511-d75e-4050-b46e-59a6f03a09bd","name":"Sticky Note59","type":"n8n-nodes-base.stickyNote","position":[1376,2144],"parameters":{"color":5,"width":288,"height":432,"content":"### C3 - Get Items\nGet items from the current page. Customize according to your service's requirements."},"typeVersion":1},{"id":"70e3c125-a6e1-477c-a43b-0bd0525bbbd0","name":"Sticky Note60","type":"n8n-nodes-base.stickyNote","position":[1680,2144],"parameters":{"color":5,"width":576,"height":432,"content":"### C3 - Validate, prepare & filter items\nTo cover all grounds, this is where you modify the results you get from the service you're using. ***Completely optional, probably even redundant.***"},"typeVersion":1},{"id":"38d640a4-c4bc-4778-8392-c5ac3ce3478e","name":"Sticky Note61","type":"n8n-nodes-base.stickyNote","position":[2272,2144],"parameters":{"color":5,"width":656,"height":432,"content":"### C3 - Rate-limited individual processing\nUse this pattern when your trigger can output a sufficiently large number of items that it will trigger rate limits in the services you're using."},"typeVersion":1},{"id":"b523fbd5-4104-4e78-803d-4b48280deb6b","name":"Sticky Note62","type":"n8n-nodes-base.stickyNote","position":[2944,2144],"parameters":{"color":5,"width":288,"height":432,"content":"### C3 - Pagination delay\nDelay after each page that has been processed."},"typeVersion":1},{"id":"54318d07-032c-4109-b281-440364ee3965","name":"Sticky Note63","type":"n8n-nodes-base.stickyNote","position":[-96,2640],"parameters":{"width":566,"height":336,"content":"# Part 2: Workflows\nTriggers manage the items in an execution. But they don't perform actions on individual items. That's the job of manager/function/utility-workflows.\n\nAs scalability is the trigger's responsibility, **reliability** and **maintainability** are the names of the game here. We consider 3 types:\n\n1. **Managers:** Orchestrate the process an individual item goes through.\n2. **Functions**: Perform one well-defined task on an item in a self-contained, reusable way.\n3. **Utilities**: Provide helper functionality for other workflows (not meant to be run standalone; depends on caller context)."},"typeVersion":1},{"id":"c8151a08-01b8-446f-b4fb-21b0de04384e","name":"Sticky Note64","type":"n8n-nodes-base.stickyNote","position":[-96,-2976],"parameters":{"width":566,"height":384,"content":"# Part 1: Trigger Workflows\nTriggers are simple; if you're dealing with a single item. But if you're not, firing up an automation can require an unholy amount of boilerplate. Because triggers are where the magic happens:\n\n- Triggers manage the top-level items in an execution\n- Triggers are separated from business logic to gain proper control over an execution and it's timing\n- Triggers save running costs by optimizing n8n executions\n- Triggers are a great place to ensure you don't hit rate limits\n\n\n**Important:**\nEven when you don't need a complicated trigger setup (like when you're using a webhook), we highly recommend splitting them up into a separate workflow. Consistency is king when it comes to maintenance and troubleshooting."},"typeVersion":1},{"id":"d5c61652-c496-4a99-8528-058ea140312f","name":"Sticky Note44","type":"n8n-nodes-base.stickyNote","position":[-96,-4352],"parameters":{"width":560,"height":1248,"content":"# Part 0: Introduction\nIn n8n, you’ve got infinite ways to reach your goal. But some are more efficient than others. More often than not, the “optimal” way follows a similar path. This document contains such paths: workflow design patterns that have proven to be highly reliable and efficient.\n\n**Why use these patterns/templates?**\n- Scale your workflows\n- Optimize for n8n executions\n- Prevent errors\n- Simplify debugging\n- Respect API rate limits\n- Stop building boilerplate\n- Increase maintainability (for yourself and others)\n\n\n**Contents:**\nThis document consists of two parts: (1) triggers and (2) workflows. The distinction originates from the approach we take to modular workflow design.\n\nBuilding modular is essential for scalable, maintainable and cost-effective automations. In our approach, we do so by breaking down large workflows into several smaller workflows that fall into one of four categories:\n\n1. **Trigger workflows:** Collect and filter the items that should be processed in an execution.\n2. **Manager workflows:** Orchestrate the process an individual item goes through (& prevent common issues).\n3. **Function workflows**: Perform one well-defined task on an item in a self-contained, reusable way.\n4. **Utility workflows**: Provide helper functionality for other workflows (not meant to be run standalone; depends on caller context).\n\n\n**Flow:**"},"typeVersion":1},{"id":"f4d89747-2266-4977-88be-7c9a9c2b930a","name":"Sticky Note67","type":"n8n-nodes-base.stickyNote","position":[496,-4352],"parameters":{"color":7,"width":880,"height":816,"content":"## Modularity example 1: New Prospect"},"typeVersion":1},{"id":"e6f79aac-c981-44d4-bac7-db483c734372","name":"Sticky Note68","type":"n8n-nodes-base.stickyNote","position":[544,-4288],"parameters":{"width":528,"height":80,"content":"### Trigger-workflow\nOnce a day, get all new prospects."},"typeVersion":1},{"id":"8e8656e4-ff15-4ee0-b525-7b8ac1de0ab0","name":"Sticky Note69","type":"n8n-nodes-base.stickyNote","position":[608,-4192],"parameters":{"width":528,"height":80,"content":"### Manager-workflow\nProcess one new prospect."},"typeVersion":1},{"id":"f8797c70-ed1e-4c8d-9ef2-73abc9ce37e7","name":"Sticky Note70","type":"n8n-nodes-base.stickyNote","position":[672,-4096],"parameters":{"width":528,"height":80,"content":"### Function-workflow 1\nQualify the new prospect based on data and website content."},"typeVersion":1},{"id":"e54d7674-44bd-4162-a297-c4d9f7df0ddc","name":"Sticky Note71","type":"n8n-nodes-base.stickyNote","position":[672,-4000],"parameters":{"width":528,"height":80,"content":"### Function-workflow 2\nFind the people in the Decision Making Unit of the new prospect."},"typeVersion":1},{"id":"22c780f5-2ec8-4357-8d69-0fa1eed302e0","name":"Sticky Note73","type":"n8n-nodes-base.stickyNote","position":[672,-3904],"parameters":{"width":528,"height":80,"content":"### Function-workflow 3\nSync Company & Contacts to Hubspot."},"typeVersion":1},{"id":"ea4281c8-775e-448c-8559-c46111cfa236","name":"Sticky Note75","type":"n8n-nodes-base.stickyNote","position":[560,-3440],"parameters":{"width":528,"height":80,"content":"### Trigger-workflow\nWhen I receive a new email from a customer."},"typeVersion":1},{"id":"df7f01c5-e0f6-4095-8dea-f14cb007461f","name":"Sticky Note76","type":"n8n-nodes-base.stickyNote","position":[672,-3344],"parameters":{"width":496,"height":80,"content":"### Function-workflow\nI draft a response tailored to this customer."},"typeVersion":1},{"id":"162709d1-bf1e-4f34-b9db-b34a6e902f0b","name":"Sticky Note77","type":"n8n-nodes-base.stickyNote","position":[736,-3248],"parameters":{"width":528,"height":80,"content":"### Utility-workflow\nGet customer data from Hubspot to use in the response."},"typeVersion":1},{"id":"d8be627b-80a9-4d4e-9486-bb8559b67adc","name":"Sticky Note78","type":"n8n-nodes-base.stickyNote","position":[800,-3712],"parameters":{"width":528,"height":80,"content":"### Utility-workflow 1\nCheck if Company already exists in Hubspot"},"typeVersion":1},{"id":"36adfbca-fde6-4aec-aa6f-f1fc74c47b59","name":"Sticky Note66","type":"n8n-nodes-base.stickyNote","position":[16,-3232],"parameters":{"color":2,"width":528,"height":96,"content":"### Utility workflows\n**Managers** and **functions** sometimes ask my help for a highly specific task. Usually, they're responsible for processing my results."},"typeVersion":1},{"id":"62b2cf04-654d-4696-b7c9-0afee0c2e9ab","name":"Sticky Note65","type":"n8n-nodes-base.stickyNote","position":[-48,-3392],"parameters":{"color":6,"width":528,"height":144,"content":"### Function workflows\nThe **manager** uses me to perform **one task** in it's process. I perform my task from A-to-Z: sometimes I report my result back, but all that needs to happen is my responsibility. To do so, I require little information, because **I can fetch all i need** myself. However, sometimes I do ask a **utility** for assistance."},"typeVersion":1},{"id":"10c33ea3-a4a2-4875-848e-a230e6d1c7be","name":"Sticky Note46","type":"n8n-nodes-base.stickyNote","position":[-112,-3504],"parameters":{"color":5,"width":528,"height":96,"content":"### Manager workflows\nThe **trigger** feeds me **one item**. I guide this item through a multi step process, using **functions** & **utilities** along the way."},"typeVersion":1},{"id":"93e65219-ba26-485e-bb27-39a8d17531dc","name":"Sticky Note45","type":"n8n-nodes-base.stickyNote","position":[-176,-3616],"parameters":{"color":4,"width":528,"height":96,"content":"### Trigger workflows\nI start processing one or more items by activating a **manager** for each item individually."},"typeVersion":1},{"id":"bb20f95e-cbcb-458d-be51-bb9d00dd91b5","name":"Sticky Note74","type":"n8n-nodes-base.stickyNote","position":[736,-3808],"parameters":{"width":528,"height":80,"content":"### Function-workflow 4\nSync Company to Hubspot."},"typeVersion":1},{"id":"a26e4a8d-36f9-4a48-a0ef-d9ba37047f37","name":"Sticky Note72","type":"n8n-nodes-base.stickyNote","position":[496,-3520],"parameters":{"color":7,"width":880,"height":416,"content":"## Modularity example 2: Customer Email"},"typeVersion":1},{"id":"b96a7ab4-18ee-4027-b8a2-5a011db3a453","name":"Sticky Note1","type":"n8n-nodes-base.stickyNote","position":[3216,3856],"parameters":{"color":4,"width":624,"height":368,"content":"### D1 - Completed successfully\nRemove the \"in progress\"-indicator and optionally add a success-indicator to prevent duplicate runs.\n\n**Important:** As you can see we \"refresh\" the item before setting the indicator. We do so as (1) underlying steps may have modified the item and/of (2) a user may have modified it while the workflow was running."},"typeVersion":1},{"id":"bc177e89-a742-4e98-9bec-482dc88cff16","name":"Sticky Note2","type":"n8n-nodes-base.stickyNote","position":[1872,3856],"parameters":{"color":5,"width":1328,"height":368,"content":"### D1 - Your process\nHere you add the steps (function-workflows) in your process."},"typeVersion":1},{"id":"f15387bb-6e35-429a-9cb6-375c4429c245","name":"Sticky Note3","type":"n8n-nodes-base.stickyNote","position":[3216,4240],"parameters":{"color":3,"width":624,"height":368,"content":"### D1 - Completed with errors\nRemove the \"in progress\"-indicator and add an error-indicator to prevent unnecessary re-runs."},"typeVersion":1},{"id":"25ee2379-4919-4740-9bc5-07c524a4e140","name":"Sticky Note5","type":"n8n-nodes-base.stickyNote","position":[1072,3856],"parameters":{"color":2,"width":784,"height":368,"content":"### D1 - Set \"in progress\"-indicator\nPrevent duplicate runs and user error by setting an indicator."},"typeVersion":1},{"id":"f9422fc6-ea22-4189-9c3e-926377c10686","name":"Sticky Note79","type":"n8n-nodes-base.stickyNote","position":[768,3024],"parameters":{"color":5,"width":1328,"height":352,"content":"### D - Example: simple manager\nThis is what proper automation looks like: clean processes with clean steps and the tiniest bit of conditional logic. Why? So you can add a step. Remove one. Or hustle them around. Like we did below."},"typeVersion":1},{"id":"c9d0e505-d583-4db0-ad04-8959c5286d9b","name":"Sticky Note80","type":"n8n-nodes-base.stickyNote","position":[2112,3024],"parameters":{"color":5,"width":288,"height":400,"content":"### D - Set output\nIt's crucially important you always output one item. In doing so, you confirm the trigger knows this workflow has been completed.\n\n*More details? Check \"D1 - Set output\" (below).*"},"typeVersion":1},{"id":"cdbd2917-8bc9-483c-8efd-08b6b9a21aca","name":"Sticky Note81","type":"n8n-nodes-base.stickyNote","position":[-96,3856],"parameters":{"width":566,"height":1248,"content":"## D1. How \"manager-workflows\" prevent common issues\nManager-workflows offer solutions for three complicated problems that often have a high impact. Only apply this pattern if any one these cases applies to your situation:\n\n### 1. Duplicate runs\nOften you don't want an item to pass through a workflow twice. That's why you should set an indicator when you're done. This allows you to filter this indicator in your trigger workflow.\n\n***Example:** whenever a prospect's data has recently been enriched, you don't want to enrich it again. So, when you enrich a prospect, you add a tag \"Enriched\". And in your trigger, you filter prospects by the tag \"Enriched\".*\n\nHowever, this leaves a gap: what if this execution isn't finished before the trigger picks up the same item again? Yes: this can happen. Which at scale means; it will happen. Especially when you add more and more AI.\n\n***Example:** To qualify a prospect, you retrieve 3 pages from a website and feed in into AI. Each web page takes 2 seconds to download. AI takes a 55 seconds to analyse. The first step in your process now takes more than a minute.*\n\nSometimes a duplicate run doesn't matter. But for total prevention, there's no escaping an \"in progress\" indicator.\n\n### 2. User feedback\nAnother case in which an \"in progress\" indicator is nice-to-have, is when people might be interacting with an item **while** a workflow runs.\n\n***Example:** Each time a user adds a company to your CRM, your automation enriches the profile.*\n\nWhen you set an \"in progress\" indicator that's visible in your CRM, your user knows enrichment is in progress. This helps you prevent collisions.\n\n### 3. Unnecessary re-runs\nWhenever an issue occurs, you usually don't want to keep repeating the same errors. That's why you should set an indicator to each item that somehow hasn't managed to make it through.\n\n***Example:** Whenever a prospect's website is no longer in use, qualification and DMU selection fail. Whenever this happens, we add the tag \"workflowError\" to the prospect.*\n\n**Side note:**\nThe cases above demonstrate why \"indicators\" (recognisable states of an item) are incredibly valuable. Unfortunately, they're not always available. Sure; CRM's offer plenty of options. But not every platform allows you to store random values. Which means \"flow-error-17-a\" sometimes becomes \"n8nError: true;\". This just doesn't scale and you shouldn't try to do so anyways. Convince me wrong.\n\n**Side note 2:**\nWhen you're NOT dealing with multiple steps (like when you just want to automatically qualify a prospect), you can apply the manager-pattern to the function. This allows you to skip the manager and go straight from trigger to function. However; we feel important problems should be solved consistently. We therefor recommend always using a manager-workflow whenever aforementioned problems apply."},"typeVersion":1},{"id":"80e7bcd5-ec60-47cf-bb90-73d99429bb3b","name":"Sticky Note82","type":"n8n-nodes-base.stickyNote","position":[-96,3856],"parameters":{"color":7,"width":4240,"height":1248,"content":""},"typeVersion":1},{"id":"8fadf507-b48f-4870-a16e-8e40d82e825f","name":"Sticky Note83","type":"n8n-nodes-base.stickyNote","position":[768,3856],"parameters":{"color":5,"width":288,"height":368,"content":"### D1 - Set variables\nManage indicators centrally."},"typeVersion":1},{"id":"837295aa-d7f9-4f21-99e1-0d850f94ec22","name":"D - Qualify Prospect","type":"n8n-nodes-base.executeWorkflow","onError":"continueErrorOutput","position":[880,3200],"parameters":{"mode":"each","options":{},"workflowId":{"__rl":true,"mode":"list","value":"IdtvYdzQ2uGp7quU","cachedResultUrl":"/workflow/IdtvYdzQ2uGp7quU","cachedResultName":"Subflow - TEMPLATE"},"workflowInputs":{"value":{"id":"={{ $json.id }}"},"schema":[{"id":"id","type":"string","display":true,"removed":false,"required":false,"displayName":"id","defaultMatch":false,"canBeUsedToMatch":true}],"mappingMode":"defineBelow","matchingColumns":["id"],"attemptToConvertTypes":false,"convertFieldsToString":true}},"typeVersion":1.2},{"id":"c4fd3b01-f95b-44c9-ad2c-9d6396ce5482","name":"D - Qualification Successful?","type":"n8n-nodes-base.if","position":[1088,3200],"parameters":{"options":{},"conditions":{"options":{"version":2,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"868f43bb-9774-4aba-9b14-9dbbb6bf1c65","operator":{"type":"boolean","operation":"true","singleValue":true},"leftValue":"={{ !!$json.result }}","rightValue":""}]}},"typeVersion":2.2},{"id":"468344d1-8e9a-43d0-a1ec-d7c452af0858","name":"D - Identify DMU","type":"n8n-nodes-base.executeWorkflow","onError":"continueErrorOutput","position":[1296,3200],"parameters":{"mode":"each","options":{},"workflowId":{"__rl":true,"mode":"list","value":"IdtvYdzQ2uGp7quU","cachedResultUrl":"/workflow/IdtvYdzQ2uGp7quU","cachedResultName":"Subflow - TEMPLATE"},"workflowInputs":{"value":{"id":"={{ $('D1 - Add \"tag_in_progress\"').item.json.id }}"},"schema":[{"id":"id","type":"string","display":true,"removed":false,"required":false,"displayName":"id","defaultMatch":false,"canBeUsedToMatch":true}],"mappingMode":"defineBelow","matchingColumns":["id"],"attemptToConvertTypes":false,"convertFieldsToString":true}},"typeVersion":1.2},{"id":"68218d28-7186-46ae-b60c-a4cd54fafda5","name":"D - DMU identification successful?","type":"n8n-nodes-base.if","position":[1488,3200],"parameters":{"options":{},"conditions":{"options":{"version":2,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"8c359fee-0f62-49cd-8e64-f06fdad697ce","operator":{"type":"boolean","operation":"true","singleValue":true},"leftValue":"={{ !!$json.result }}","rightValue":""}]}},"typeVersion":2.2},{"id":"6e3e7274-f900-450c-9734-eecec0232697","name":"D - Sync Hubspot","type":"n8n-nodes-base.executeWorkflow","onError":"continueErrorOutput","position":[1680,3200],"parameters":{"options":{},"workflowId":{"__rl":true,"mode":"list","value":"IdtvYdzQ2uGp7quU","cachedResultUrl":"/workflow/IdtvYdzQ2uGp7quU","cachedResultName":"Subflow - TEMPLATE"},"workflowInputs":{"value":{"id":"={{ $('D1 - Add \"tag_in_progress\"').item.json.id }}"},"schema":[{"id":"id","type":"string","display":true,"required":false,"displayName":"id","defaultMatch":false,"canBeUsedToMatch":true}],"mappingMode":"defineBelow","matchingColumns":["id"],"attemptToConvertTypes":false,"convertFieldsToString":true}},"typeVersion":1.2},{"id":"9d6a59ae-faa8-4add-a1b0-4c2319701b82","name":"D - Hubspot sync successful?","type":"n8n-nodes-base.if","position":[1872,3200],"parameters":{"options":{},"conditions":{"options":{"version":2,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"8c359fee-0f62-49cd-8e64-f06fdad697ce","operator":{"type":"boolean","operation":"true","singleValue":true},"leftValue":"={{ !!$json.result }}","rightValue":""}]}},"typeVersion":2.2},{"id":"b3aa5278-6036-4eaa-a41e-f47e0596f246","name":"D - Set output","type":"n8n-nodes-base.set","position":[2208,3200],"parameters":{"options":{},"assignments":{"assignments":[{"id":"3ff8a838-a321-4245-8c11-fdb4b0b819c1","name":"error_code","type":"number","value":"={{ !!$json.error ? '500' : '200' }}"}]}},"typeVersion":3.4},{"id":"f28ab5a5-3867-4d8d-abb2-ef1f61b278af","name":"D1 - Set variables","type":"n8n-nodes-base.set","position":[864,4016],"parameters":{"options":{},"assignments":{"assignments":[{"id":"3ff8a838-a321-4245-8c11-fdb4b0b819c1","name":"tag_error","type":"string","value":"EnrichmentFailed"},{"id":"1702df91-fe16-4af8-aec2-2b3602e7bf2f","name":"tag_success","type":"string","value":"Enriched"}]}},"typeVersion":3.4},{"id":"1d67d0b8-fee5-4320-b058-33e3b30a5d3e","name":"D1 - Get prospect","type":"@bedrijfsdatanl/n8n-nodes-prospectpro.prospectpro","onError":"continueErrorOutput","position":[1120,4016],"parameters":{"id":"={{ $json.id }}","operation":"get","requestOptions":{}},"credentials":{"prospectproApi":{"id":"wzKM5qJt7DZvsWOD","name":"Bedrijfsdata.nl - XXX003"}},"typeVersion":1},{"id":"a467ec0e-e736-4837-beee-893a7211e096","name":"D1 - Continue?","type":"n8n-nodes-base.if","position":[1312,4016],"parameters":{"options":{},"conditions":{"options":{"version":2,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"d5156902-fb25-4b1c-b253-b44c3c6a61c0","operator":{"type":"boolean","operation":"false","singleValue":true},"leftValue":"={{ !!$json.tags?.includes($('D1 - Set variables').first().json.tag_error) || !!$json.tags?.includes($('D1 - Set variables').first().json.tag_in_progress) }}","rightValue":""}]}},"typeVersion":2.2},{"id":"a3a36c23-3999-400a-869a-8717d7cc04a9","name":"D1 - Add \"tag_in_progress\"","type":"n8n-nodes-base.code","position":[1504,4016],"parameters":{"mode":"runOnceForEachItem","jsCode":"const prospect = $('D1 - Get prospect').first().json;\nconst tags = !!prospect.tags  && prospect.tags.length > 0 ? prospect.tags.split('|') : [];\nconst tag = $('D1 - Set variables').first().json.tag_in_progress;\n\nif(tag) tags.push(tag);\n\nreturn {\n  ...prospect,\n  tags\n};"},"typeVersion":2},{"id":"16603f46-8282-43c6-9b61-b4c688294af1","name":"D1 - Update prospect","type":"@bedrijfsdatanl/n8n-nodes-prospectpro.prospectpro","onError":"continueErrorOutput","position":[1696,4016],"parameters":{"id":"={{ $json.id }}","operation":"patch","updateOptions":{"tags":"={{ $json.tags }}"},"requestOptions":{}},"credentials":{"prospectproApi":{"id":"wzKM5qJt7DZvsWOD","name":"Bedrijfsdata.nl - XXX003"}},"typeVersion":1},{"id":"ff93ed38-9103-4cc2-9fbc-6c52ed2e9602","name":"D1 - Automatically Qualify Prospect","type":"n8n-nodes-base.executeWorkflow","onError":"continueErrorOutput","position":[2000,4016],"parameters":{"mode":"each","options":{},"workflowId":{"__rl":true,"mode":"list","value":"IdtvYdzQ2uGp7quU","cachedResultUrl":"/workflow/IdtvYdzQ2uGp7quU","cachedResultName":"Subflow - TEMPLATE"},"workflowInputs":{"value":{"id":"={{ $json.id }}"},"schema":[{"id":"id","type":"string","display":true,"removed":false,"required":false,"displayName":"id","defaultMatch":false,"canBeUsedToMatch":true}],"mappingMode":"defineBelow","matchingColumns":["id"],"attemptToConvertTypes":false,"convertFieldsToString":true}},"typeVersion":1.2},{"id":"0faafa67-4dc0-4b44-9985-f74f63a76f26","name":"D1 - Qualification Successful?","type":"n8n-nodes-base.if","position":[2192,4016],"parameters":{"options":{},"conditions":{"options":{"version":2,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"868f43bb-9774-4aba-9b14-9dbbb6bf1c65","operator":{"type":"boolean","operation":"true","singleValue":true},"leftValue":"={{ !!$json.result }}","rightValue":""}]}},"typeVersion":2.2},{"id":"a1fff0d7-e0db-4662-97a7-408f67c35c0b","name":"D1 - Get Contacts","type":"n8n-nodes-base.executeWorkflow","onError":"continueErrorOutput","position":[2400,4016],"parameters":{"mode":"each","options":{},"workflowId":{"__rl":true,"mode":"list","value":"IdtvYdzQ2uGp7quU","cachedResultUrl":"/workflow/IdtvYdzQ2uGp7quU","cachedResultName":"Subflow - TEMPLATE"},"workflowInputs":{"value":{"id":"={{ $('D1 - Add \"tag_in_progress\"').item.json.id }}"},"schema":[{"id":"id","type":"string","display":true,"removed":false,"required":false,"displayName":"id","defaultMatch":false,"canBeUsedToMatch":true}],"mappingMode":"defineBelow","matchingColumns":["id"],"attemptToConvertTypes":false,"convertFieldsToString":true}},"typeVersion":1.2},{"id":"bffd83db-4f22-4299-ab9a-6a65b085db54","name":"D1 - Contacts search successful?","type":"n8n-nodes-base.if","position":[2592,4016],"parameters":{"options":{},"conditions":{"options":{"version":2,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"8c359fee-0f62-49cd-8e64-f06fdad697ce","operator":{"type":"boolean","operation":"true","singleValue":true},"leftValue":"={{ !!$json.result }}","rightValue":""}]}},"typeVersion":2.2},{"id":"274e6a7a-4657-4dd6-afd0-47f90e749090","name":"D1 - Sync Hubspot","type":"n8n-nodes-base.executeWorkflow","onError":"continueErrorOutput","position":[2784,4016],"parameters":{"options":{},"workflowId":{"__rl":true,"mode":"list","value":"IdtvYdzQ2uGp7quU","cachedResultUrl":"/workflow/IdtvYdzQ2uGp7quU","cachedResultName":"Subflow - TEMPLATE"},"workflowInputs":{"value":{"id":"={{ $('D1 - Add \"tag_in_progress\"').item.json.id }}"},"schema":[{"id":"id","type":"string","display":true,"required":false,"displayName":"id","defaultMatch":false,"canBeUsedToMatch":true}],"mappingMode":"defineBelow","matchingColumns":["id"],"attemptToConvertTypes":false,"convertFieldsToString":true}},"typeVersion":1.2},{"id":"dd8b301b-f7c0-41a1-a11d-e9b74d8808e0","name":"D1 - Hubspot sync successful?","type":"n8n-nodes-base.if","position":[2976,4016],"parameters":{"options":{},"conditions":{"options":{"version":2,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"8c359fee-0f62-49cd-8e64-f06fdad697ce","operator":{"type":"boolean","operation":"true","singleValue":true},"leftValue":"={{ !!$json.result }}","rightValue":""}]}},"typeVersion":2.2},{"id":"64a4b182-edfc-42b2-8d58-d2b2c1e01e9b","name":"D1 - Get prospect for final update: Success","type":"@bedrijfsdatanl/n8n-nodes-prospectpro.prospectpro","position":[3296,4016],"parameters":{"id":"={{ $('D1 - Get prospect').item.json.id }}","operation":"get","requestOptions":{}},"credentials":{"prospectproApi":{"id":"wzKM5qJt7DZvsWOD","name":"Bedrijfsdata.nl - XXX003"}},"typeVersion":1},{"id":"9ee62d21-d787-4658-b006-4e1a4f29c566","name":"D1 - Add \"tag_success\", remove \"tag_in_processing\"","type":"n8n-nodes-base.code","position":[3488,4016],"parameters":{"mode":"runOnceForEachItem","jsCode":"const prospect = $json;\nconst vars = $('D1 - Set variables').first().json;\nconst tagInProgress = vars.tag_in_progress || 'nothing_to_see_here';\nconst tagSuccess = vars.tag_success;\n\nconst tags = (prospect.tags ?? \"\")\n  .split(\"|\")\n  .map(t => t.trim())\n  .filter(Boolean)\n  .filter(t => t !== tagInProgress);\n\nif (tagSuccess) tags.push(tagSuccess);\n\nconst uniqueTags = [...new Set(tags)];\n\nreturn {\n  ...prospect,\n  tags: uniqueTags\n};"},"typeVersion":2},{"id":"6afd7dc3-b9df-484a-934f-002875e664cf","name":"D1 - Update Tags: Success","type":"@bedrijfsdatanl/n8n-nodes-prospectpro.prospectpro","onError":"continueRegularOutput","position":[3680,4016],"parameters":{"id":"={{ $json.id }}","operation":"patch","updateOptions":{"tags":"={{ $json.tags }}"},"requestOptions":{}},"credentials":{"prospectproApi":{"id":"wzKM5qJt7DZvsWOD","name":"Bedrijfsdata.nl - XXX003"}},"typeVersion":1,"alwaysOutputData":true},{"id":"33f78a05-2d16-4cbb-9c00-ae49ed3fa621","name":"D1 - Get prospect for final update: Fail","type":"@bedrijfsdatanl/n8n-nodes-prospectpro.prospectpro","position":[3296,4400],"parameters":{"id":"={{ $('D1 - Get prospect').item.json.id }}","operation":"get","requestOptions":{}},"credentials":{"prospectproApi":{"id":"wzKM5qJt7DZvsWOD","name":"Bedrijfsdata.nl - XXX003"}},"typeVersion":1},{"id":"05494b19-29a1-4c6a-8860-90bd3f8833ac","name":"D1 - Add \"tag_error\", remove \"tag_in_progress\"","type":"n8n-nodes-base.code","position":[3488,4400],"parameters":{"mode":"runOnceForEachItem","jsCode":"const prospect = $json;\nconst vars = $('D1 - Set variables').first().json;\nconst tagInProgress = vars.tag_in_progress || 'nothing_to_see_here';\nconst tagError = vars.tag_error;\n\nconst tags = (prospect.tags ?? \"\")\n  .split(\"|\")\n  .map(t => t.trim())\n  .filter(Boolean)\n  .filter(t => t !== tagInProgress);\n\nif (tagError) tags.push(tagError);\n\nconst uniqueTags = [...new Set(tags)];\n\nreturn {\n  ...prospect,\n  tags: uniqueTags\n};"},"typeVersion":2},{"id":"e596ba86-f841-42f1-9b01-e2fa83ffed0b","name":"D1 - Update Tags: Fail","type":"@bedrijfsdatanl/n8n-nodes-prospectpro.prospectpro","onError":"continueRegularOutput","position":[3680,4400],"parameters":{"id":"={{ $json.id }}","operation":"patch","updateOptions":{"tags":"={{ $json.tags }}"},"requestOptions":{}},"credentials":{"prospectproApi":{"id":"wzKM5qJt7DZvsWOD","name":"Bedrijfsdata.nl - XXX003"}},"typeVersion":1,"alwaysOutputData":true},{"id":"8f40b0d6-7c32-4b48-9c1c-33f2fcdc0928","name":"Sticky Note4","type":"n8n-nodes-base.stickyNote","position":[1872,4240],"parameters":{"color":3,"width":352,"height":368,"content":"### D1 - Guard Error\nWhen an item can't be retrieved or updated, or a guard is activated, your manager should quit the automation immediately. In such cases, it's required to let the trigger-workflow know you've quit before processing has even started."},"typeVersion":1},{"id":"4eb80f14-4b1e-486b-96cc-f141f7038607","name":"D1 - Stop and Error","type":"n8n-nodes-base.stopAndError","position":[2000,4416],"parameters":{"errorType":"errorObject","errorObject":"{\n  \"code\": 404,\n  \"message\": \"Prospect not found\"\n}"},"typeVersion":1},{"id":"cfce8485-6ea7-46da-a167-b6e57ff1ee6a","name":"Sticky Note84","type":"n8n-nodes-base.stickyNote","position":[3856,3856],"parameters":{"color":5,"width":288,"height":752,"content":"### D1 - Set output\nIt's crucially important you always output **one item**.\n\n**Why?**\n- Consider the trigger-workflow that calls this manager workflow.\n- When the trigger-workflow is processing multiple items, it might add delays between batches of items. In such a setup, the trigger-workflow wait for this manager-workflow to finish. It does so by waiting for signals (items) that are returned to it by this workflow.\n- As we're building for scale, it's just good practise to build like such a system exists, even when it doesn't. This will prevent loads of issues in production.\n\n\n**What do I return?**\n- It depends on whether your trigger-workflow actually uses the output you return here.\n- If your trigger just needs a signal, the actual content doesn't matter (any json or error object is treated the same).\n- However; it's conceivable you want your trigger to do something with your output. Like notify you: \"23 prospects enriched, 1 error occurred\". In such a case you need to provide more meaningful data to your trigger-workflow here."},"typeVersion":1},{"id":"21aa9159-4f5f-4d29-a5a2-0dc24aff2d87","name":"When Executed by [trigger workflow]","type":"n8n-nodes-base.executeWorkflowTrigger","disabled":true,"position":[560,3200],"parameters":{"inputSource":"passthrough"},"typeVersion":1.1},{"id":"439f2f0c-fc56-451d-a3fe-1d73c5977075","name":"D - Qualify Prospect (var b)","type":"n8n-nodes-base.executeWorkflow","onError":"continueErrorOutput","position":[1088,3440],"parameters":{"mode":"each","options":{},"workflowId":{"__rl":true,"mode":"list","value":"IdtvYdzQ2uGp7quU","cachedResultUrl":"/workflow/IdtvYdzQ2uGp7quU","cachedResultName":"Subflow - TEMPLATE"},"workflowInputs":{"value":{"id":"={{ $json.id }}"},"schema":[{"id":"id","type":"string","display":true,"removed":false,"required":false,"displayName":"id","defaultMatch":false,"canBeUsedToMatch":true}],"mappingMode":"defineBelow","matchingColumns":["id"],"attemptToConvertTypes":false,"convertFieldsToString":true}},"typeVersion":1.2},{"id":"49e9289d-7625-439a-ba30-30aad94b1163","name":"D - Identify DMU (var b)","type":"n8n-nodes-base.executeWorkflow","onError":"continueErrorOutput","position":[1504,3600],"parameters":{"mode":"each","options":{},"workflowId":{"__rl":true,"mode":"list","value":"IdtvYdzQ2uGp7quU","cachedResultUrl":"/workflow/IdtvYdzQ2uGp7quU","cachedResultName":"Subflow - TEMPLATE"},"workflowInputs":{"value":{"id":"={{ $('D1 - Add \"tag_in_progress\"').item.json.id }}"},"schema":[{"id":"id","type":"string","display":true,"removed":false,"required":false,"displayName":"id","defaultMatch":false,"canBeUsedToMatch":true}],"mappingMode":"defineBelow","matchingColumns":["id"],"attemptToConvertTypes":false,"convertFieldsToString":true}},"typeVersion":1.2},{"id":"d388a027-bbf5-4e8b-aa45-7e2996ed120c","name":"D - Switch (var b)","type":"n8n-nodes-base.switch","position":[880,3440],"parameters":{"rules":{"values":[{"outputKey":"Path A","conditions":{"options":{"version":3,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"6e5a91ab-205c-42cd-ba7e-3905227f6974","operator":{"type":"string","operation":"equals"},"leftValue":"","rightValue":""}]},"renameOutput":true},{"outputKey":"Path B","conditions":{"options":{"version":3,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"15c7389b-657a-41f6-98a1-0b7d3a28daff","operator":{"name":"filter.operator.equals","type":"string","operation":"equals"},"leftValue":"","rightValue":""}]},"renameOutput":true}]},"options":{}},"typeVersion":3.4},{"id":"a1c81c43-7a26-4967-8ffd-11e36d543d91","name":"D - Qualification Successful? (var b)","type":"n8n-nodes-base.if","position":[1296,3440],"parameters":{"options":{},"conditions":{"options":{"version":2,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"868f43bb-9774-4aba-9b14-9dbbb6bf1c65","operator":{"type":"boolean","operation":"true","singleValue":true},"leftValue":"={{ !!$json.result }}","rightValue":""}]}},"typeVersion":2.2},{"id":"0658dd0f-6334-4b9b-a084-1c0553882209","name":"D - Sync Hubspot (var b)","type":"n8n-nodes-base.executeWorkflow","onError":"continueErrorOutput","position":[1680,3456],"parameters":{"options":{},"workflowId":{"__rl":true,"mode":"list","value":"IdtvYdzQ2uGp7quU","cachedResultUrl":"/workflow/IdtvYdzQ2uGp7quU","cachedResultName":"Subflow - TEMPLATE"},"workflowInputs":{"value":{"id":"={{ $('D1 - Add \"tag_in_progress\"').item.json.id }}"},"schema":[{"id":"id","type":"string","display":true,"required":false,"displayName":"id","defaultMatch":false,"canBeUsedToMatch":true}],"mappingMode":"defineBelow","matchingColumns":["id"],"attemptToConvertTypes":false,"convertFieldsToString":true}},"typeVersion":1.2},{"id":"8bdec009-fc02-4237-a0b6-f5df5966e4f2","name":"D - Hubspot sync successful? (var b)","type":"n8n-nodes-base.if","position":[1872,3456],"parameters":{"options":{},"conditions":{"options":{"version":2,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"8c359fee-0f62-49cd-8e64-f06fdad697ce","operator":{"type":"boolean","operation":"true","singleValue":true},"leftValue":"={{ !!$json.result }}","rightValue":""}]}},"typeVersion":2.2},{"id":"ee52058c-b3c1-4ad3-9eba-4898f72efb50","name":"Sticky Note85","type":"n8n-nodes-base.stickyNote","position":[-96,5152],"parameters":{"width":566,"height":720,"content":"## Quick recap & introduction E + F\nSo far we've been dealing exclusively with \"overhead\": stuff to ensure consistency, optimize cost and prevent issues. Now it's time to actually do stuff. But before we do, let's quickly recap what we've seen so far:\n\n- Trigger-workflows are responsible for **managing items in executions**, both to save cost and to prevent rate limit issues throughout your automation.\n- Manager-workflows are responsible for **managing processes** and **preventing duplicate runs, unnecessary re-runs and user feedback**.\n\n\nThis means all issues that prevent you from scaling your automations have now been dealt with **structurally**. Yes; it will take you some time you wrap your head around the mechanics. Getting used to copy-pasting the scaffolding before you start a project will also feel counterintuitive for a while. However; the total lack of errors you'll see in production will more than make up for it.\n\nNow, let's move on to the good stuff: function- and utility-workflows:\n- **Function workflows**: Perform one well-defined task on an item in a self-contained, reusable way.\n- **Utility workflows**: Provide helper functionality for other workflows (not meant to be run standalone; relies on caller for context).\n\n\n**Important:**\n- Modularity is key when it comes to functions/utilities. If you don't have any coding experience, please talk to Claude/ChatGPT about this topic before you start refactoring your features into nice single-purpose functions/utilities.\n- Just like manager-workflows (D, D1), functions/utilities always start when \"Executed by another workflow\" (obviously)\n- Just like manager-workflows (D, D1), functions/utilities always need to output the exact same amount of items as it is provided (usually 1), even when an error occurs."},"typeVersion":1},{"id":"e4406e4f-2e7d-4cac-860e-0cff8f1e3fc3","name":"Sticky Note86","type":"n8n-nodes-base.stickyNote","position":[736,-3616],"parameters":{"width":528,"height":80,"content":"### Utility-workflow 2\nSync Contact to Hubspot."},"typeVersion":1},{"id":"75b26fb8-e429-48df-97ae-d270ead7ce0e","name":"Sticky Note87","type":"n8n-nodes-base.stickyNote","position":[768,3392],"parameters":{"color":5,"width":1328,"height":400,"content":""},"typeVersion":1},{"id":"3962532d-d8aa-451b-b88a-c539d70f84dd","name":"Sticky Note88","type":"n8n-nodes-base.stickyNote","position":[1072,5904],"parameters":{"color":5,"width":288,"height":368,"content":"### E1 - Refresh item\nYou probably get the gist of this by now; before doing important stuff, make sure you fetch any that have been made to the item between the moment the trigger-workflow started and \"now\"."},"typeVersion":1},{"id":"b50424fb-c3fd-4c62-8874-8f77d0cba662","name":"Sticky Note89","type":"n8n-nodes-base.stickyNote","position":[3344,5904],"parameters":{"color":5,"width":256,"height":752,"content":"### E1 - Set output\nIt's crucially important you always output one item. In doing so, you confirm the trigger knows this workflow has been completed.\n\n*More details? Check \"D1 - Set output\" (below).*"},"typeVersion":1},{"id":"e46a50b9-f668-431f-b04d-a4dcc408cd44","name":"Sticky Note90","type":"n8n-nodes-base.stickyNote","position":[1376,5904],"parameters":{"color":5,"width":432,"height":368,"content":"### E1 - Guard your workflow\nAlways double check if you should perform actions before you actually do it. Yes; this might seem redundant. But remember: when you scale your automation, everything that can go wrong, will go wrong. This isn't Murphy's law; it's Statistics 101."},"typeVersion":1},{"id":"2d138bbb-d20f-448a-9d42-26f35eadc4c7","name":"Sticky Note91","type":"n8n-nodes-base.stickyNote","position":[2352,5904],"parameters":{"color":2,"width":512,"height":368,"content":"### E1 - Your workflow\nThis is just for demonstration purposes. Replace with your own workflow."},"typeVersion":1},{"id":"def52fb8-f08b-49b4-87a6-5de2c8f29ae9","name":"Sticky Note92","type":"n8n-nodes-base.stickyNote","position":[2352,6288],"parameters":{"color":2,"width":512,"height":368,"content":"### E1 - Your workflow\nThis is just for demonstration purposes. Replace with your own workflow."},"typeVersion":1},{"id":"57451652-aff3-4b7c-a606-822db5694a00","name":"Sticky Note93","type":"n8n-nodes-base.stickyNote","position":[2880,6288],"parameters":{"color":3,"width":448,"height":368,"content":"### E1 - Add a error indicator (optional)\nIf you want to prevent this function to be executed for this item again, you should indicate this job has already been done.\n\n**Please note:** unlike earlier we're not refreshing before adding the indicator. This is because this workflow has a predictably low runtime. There's only simple, quick steps. Therefor there's no need for a refresh. This would be very different if we would have used AI (or Hubspot MCP for that matter)."},"typeVersion":1},{"id":"df5481b3-1db2-4b2d-8d09-aa4a7523b4b0","name":"Sticky Note95","type":"n8n-nodes-base.stickyNote","position":[2880,5904],"parameters":{"color":4,"width":448,"height":368,"content":"### E1 - Add a success indicator (optional)\nIf you want to prevent this function to be executed for this item again, you should indicate this job has already been done.\n\n**Please note:** unlike earlier we're not refreshing before adding the indicator. This is because this workflow has a predictably low runtime. There's only simple, quick steps. Therefor there's no need for a refresh. This would be very different if we would have used AI (or Hubspot MCP for that matter)."},"typeVersion":1},{"id":"676f7506-a920-41e1-be88-bea4f1d5f7db","name":"Sticky Note96","type":"n8n-nodes-base.stickyNote","position":[1824,5904],"parameters":{"color":2,"width":512,"height":368,"content":"### E1 - Your workflow\nThis is just for demonstration purposes. Replace with your own workflow.\n\n*\"E1 - Find Company in Hubspot\" is a reference to the function workflow (F1, below). Follow the path to get a proper look at how this works.*"},"typeVersion":1},{"id":"343a5c66-0238-4546-b425-df991f85638a","name":"Sticky Note94","type":"n8n-nodes-base.stickyNote","position":[1824,6288],"parameters":{"color":3,"width":512,"height":368,"content":"### E1 - Guard Error\nWhen an item can't be retrieved or a guard is activated, your workflow should be quit. For simplicity's sake we just throw an error in this example.\n\n**However;** if the workflow that calls this workflow needs to know if this action has been successful (i.e. the company is now in Hubspot), or perhaps even needs data from Hubspot (like the companyId to associate contacts with it), **this is not good enough!**"},"typeVersion":1},{"id":"691309f0-d9ef-4d22-a776-b7e15189dc7a","name":"E1 - Stop and Error","type":"n8n-nodes-base.stopAndError","position":[2032,6512],"parameters":{"errorType":"errorObject","errorObject":"{\n  \"code\": 404,\n  \"message\": \"Prospect not found\"\n}"},"typeVersion":1},{"id":"a420f9a9-488f-4596-9f5f-4e9c6b5340ac","name":"Search Companies by Bedrijfsdata ID","type":"n8n-nodes-base.httpRequest","onError":"continueErrorOutput","position":[848,6848],"parameters":{"url":"https://api.hubapi.com/crm/v3/objects/companies/search","method":"POST","options":{},"jsonBody":"={\n  \"properties\": [\"prospectpro_id\", \"domain\", \"name\", \"lifecyclestage\"],\n  \"filterGroups\": [\n    {\n      \"filters\": [\n        {\n          \"propertyName\": \"prospectpro_id\",\n          \"operator\": \"EQ\",\n          \"value\": \"{{ $json.id }}\"\n        }\n      ]\n    }\n  ]\n}","sendBody":true,"specifyBody":"json","authentication":"predefinedCredentialType","nodeCredentialType":"hubspotOAuth2Api"},"credentials":{"hubspotOAuth2Api":{"id":"8J6vWIspjToV6Qwv","name":"HubSpot account 2"}},"typeVersion":4.2},{"id":"7b81fd4c-8eab-489a-8aac-a4ce3dfc4a3c","name":"Found by ID?","type":"n8n-nodes-base.if","position":[1056,6848],"parameters":{"options":{},"conditions":{"options":{"version":2,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"da65345b-7d49-4576-bbaf-ab23f7e1cdb8","operator":{"type":"boolean","operation":"true","singleValue":true},"leftValue":"={{ $json.total > 0 }}","rightValue":""}]}},"typeVersion":2.2},{"id":"a35cd042-2c4c-4c00-9d40-5ba89a90c984","name":"Search Companies by Domain","type":"n8n-nodes-base.httpRequest","onError":"continueErrorOutput","position":[1472,6848],"parameters":{"url":"https://api.hubapi.com/crm/v3/objects/companies/search","method":"POST","options":{},"jsonBody":"={\n  \"properties\": [\"prospectpro_id\", \"domain\", \"name\"],\n  \"filterGroups\": [\n    {\n      \"filters\": [\n        {\n          \"propertyName\": \"domain\",\n          \"operator\": \"EQ\",\n          \"value\": \"{{ $('E1 - Get prospect').item.json.domain }}\"\n        }\n      ]\n    }\n  ]\n}","sendBody":true,"specifyBody":"json","authentication":"predefinedCredentialType","nodeCredentialType":"hubspotOAuth2Api"},"credentials":{"hubspotOAuth2Api":{"id":"8J6vWIspjToV6Qwv","name":"HubSpot account 2"}},"typeVersion":4.2},{"id":"d924425e-8a6a-4c90-bedf-24b57bab0350","name":"Has Domain?","type":"n8n-nodes-base.if","position":[1264,6848],"parameters":{"options":{},"conditions":{"options":{"version":2,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"b3a44f7a-7b55-49b0-90e5-c3abb0c9c815","operator":{"type":"boolean","operation":"true","singleValue":true},"leftValue":"={{ !!$('E1 - Get prospect').item.json.domain }}","rightValue":""}]}},"typeVersion":2.2},{"id":"95a3cbfb-7515-4034-af9b-d293b589cdb3","name":"Found by Domain?","type":"n8n-nodes-base.if","position":[1680,6848],"parameters":{"options":{},"conditions":{"options":{"version":2,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"da65345b-7d49-4576-bbaf-ab23f7e1cdb8","operator":{"type":"boolean","operation":"true","singleValue":true},"leftValue":"={{ $json.total > 0 }}","rightValue":""}]}},"typeVersion":2.2},{"id":"dc1ffcbd-43b0-4be9-9126-5c42171e7911","name":"Sticky Note97","type":"n8n-nodes-base.stickyNote","position":[768,6672],"parameters":{"color":2,"width":1280,"height":416,"content":"### F1 - Your workflow\nThis is just for demonstration purposes. Replace with your own workflow.\n\n*Example workflow below is an extension of the function-workflow example in E1. Which in turn is an extension of the manager-workflow example in D1.*"},"typeVersion":1},{"id":"0333525b-9593-434a-86bc-0ff618b60c5a","name":"Sticky Note98","type":"n8n-nodes-base.stickyNote","position":[528,5904],"parameters":{"width":224,"height":368,"content":"### E1 - Example input\n`{\n \"id\": 1234567890\n}`"},"typeVersion":1},{"id":"7931da8d-b44b-4a6e-8716-74263487d3e8","name":"Sticky Note99","type":"n8n-nodes-base.stickyNote","position":[528,6672],"parameters":{"width":224,"height":416,"content":"### F1 - Example input\n\n`{\n \"id\": 1234567890,\n \"domain\": \"bedrijfsdata.nl\",\n\"name\": \"Bedrijfsdata.nl B.V.\",\n...\n}`"},"typeVersion":1},{"id":"d30f3819-0a5d-47ee-8c7f-3dbc2bc55401","name":"Sticky Note100","type":"n8n-nodes-base.stickyNote","position":[2064,6672],"parameters":{"color":5,"width":272,"height":416,"content":"### F1 - Set output\nIt's crucially important you always output one item that contains the results the parent workflow needs. We suggest using a default structure, like in the example, that allows you to process utility workflows consistently.\n\n**Side note:**\nYou may consider to return an error-object whenever a utility workflow couldn't get the desired results. We recommend you only consider this for actual errors, as \"fake errors\" make troubleshooting more difficult."},"typeVersion":1},{"id":"426c96c5-8da5-4ccf-81ae-38cbcad627f5","name":"E1 - Get prospect","type":"@bedrijfsdatanl/n8n-nodes-prospectpro.prospectpro","onError":"continueErrorOutput","position":[1168,6080],"parameters":{"id":"={{ $json.id }}","operation":"get","requestOptions":{}},"credentials":{"prospectproApi":{"id":"wzKM5qJt7DZvsWOD","name":"Bedrijfsdata.nl - XXX003"}},"typeVersion":1,"alwaysOutputData":false},{"id":"21a6754c-ba76-4d02-a6f6-c0fa5056092a","name":"E1 - No Existing Errors?","type":"n8n-nodes-base.if","position":[1440,6080],"parameters":{"options":{},"conditions":{"options":{"version":2,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"c3696744-f335-4b14-852c-76a7659f3303","operator":{"type":"boolean","operation":"false","singleValue":true},"leftValue":"={{ !!$json.tags.includes(\"HubspotSyncFailed\") }}","rightValue":""}]}},"typeVersion":2.2},{"id":"7763fc88-3950-4891-9b1b-7055452d5009","name":"E1 - Continue?","type":"n8n-nodes-base.if","position":[1648,6080],"parameters":{"options":{},"conditions":{"options":{"version":2,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"15bc7f88-124b-4ace-9b9b-d211b83dd524","operator":{"type":"boolean","operation":"true","singleValue":true},"leftValue":"={{ !!$json.domain }}","rightValue":""},{"id":"2ab83e0c-e511-4b0a-bb97-c76198116e07","operator":{"type":"boolean","operation":"true","singleValue":true},"leftValue":"={{ !!$json.id }}","rightValue":""},{"id":"7dc88f3a-2aa2-4e17-9b67-1298ba06c27b","operator":{"name":"filter.operator.equals","type":"string","operation":"equals"},"leftValue":"","rightValue":""}]}},"typeVersion":2.2},{"id":"09f6ba92-176e-46c4-bdb7-5745b15bd728","name":"E1 - Find Company in Hubspot","type":"n8n-nodes-base.executeWorkflow","onError":"continueErrorOutput","position":[1904,6080],"parameters":{"options":{},"workflowId":{"__rl":true,"mode":"list","value":"IdtvYdzQ2uGp7quU","cachedResultUrl":"/workflow/IdtvYdzQ2uGp7quU","cachedResultName":"Subflow - TEMPLATE"},"workflowInputs":{"value":{"id":"={{ $('D1 - Add \"tag_in_progress\"').item.json.id }}"},"schema":[{"id":"id","type":"string","display":true,"required":false,"displayName":"id","defaultMatch":false,"canBeUsedToMatch":true}],"mappingMode":"defineBelow","matchingColumns":["id"],"attemptToConvertTypes":false,"convertFieldsToString":true}},"typeVersion":1.2},{"id":"39cdbb67-3691-4770-a378-1ee65b934d08","name":"E1 - Found?","type":"n8n-nodes-base.if","position":[2112,6032],"parameters":{"options":{},"conditions":{"options":{"version":2,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"da65345b-7d49-4576-bbaf-ab23f7e1cdb8","operator":{"type":"boolean","operation":"true","singleValue":true},"leftValue":"={{ !!$json.companyId }}","rightValue":""}]}},"typeVersion":2.2},{"id":"0872b866-f194-4332-97dd-f9479d7fc5da","name":"E1 - Update a company","type":"n8n-nodes-base.hubspot","onError":"continueErrorOutput","position":[2448,6080],"parameters":{"resource":"company","companyId":{"__rl":true,"mode":"id","value":"={{ $json.id }}"},"operation":"update","updateFields":{"companyDomainName":"={{ $json.properties.domain || $('E1 - Get prospect').item.json.domain || undefined }}","customPropertiesUi":{"customPropertiesValues":[{"value":"={{ $('E1 - Get prospect').item.json.id }}","property":"prospectpro_id"},{"value":"={{ $('E1 - Get prospect').item.json.coc }}","property":"kvk"}]}},"authentication":"oAuth2"},"credentials":{"hubspotOAuth2Api":{"id":"8J6vWIspjToV6Qwv","name":"HubSpot account 2"}},"typeVersion":2.1},{"id":"0726c340-cd22-4582-85de-00ddc34a6d00","name":"E1 - Update Successful?","type":"n8n-nodes-base.if","position":[2656,6080],"parameters":{"options":{},"conditions":{"options":{"version":2,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"239351e0-f10a-4dc2-a47f-b5e0978bcda4","operator":{"type":"boolean","operation":"true","singleValue":true},"leftValue":"={{ !!$json.companyId }}","rightValue":""}]}},"typeVersion":2.2},{"id":"bebc10ae-8681-4135-a189-79c2fd5bb135","name":"E1 - Create a company","type":"n8n-nodes-base.hubspot","onError":"continueErrorOutput","position":[2448,6464],"parameters":{"name":"={{ $('E1 - Get prospect').item.json.name }}","resource":"company","authentication":"oAuth2","additionalFields":{"city":"={{ $('E1 - Get prospect').item.json.city || undefined }}","postalCode":"={{ $('E1 - Get prospect').item.json.postcode || undefined }}","websiteUrl":"={{ $('E1 - Get prospect').item.json.url || undefined }}","phoneNumber":"={{ $('E1 - Get prospect').item.json.phone_international || undefined }}","annualRevenue":"={{ $('E1 - Get prospect').item.json.revenue || undefined }}","countryRegion":"={{ $('E1 - Get prospect').item.json.country_code || undefined }}","streetAddress":"={{ $('E1 - Get prospect').item.json.address || undefined }}","companyDomainName":"={{ $('E1 - Get prospect').item.json.domain || undefined }}","numberOfEmployees":"={{ $('E1 - Get prospect').item.json.employees || undefined }}","customPropertiesUi":{"customPropertiesValues":[{"value":"={{ $('E1 - Get prospect').item.json.id }}","property":"prospectpro_id"},{"value":"={{ $('E1 - Get prospect').item.json.coc || undefined }}","property":"kvk"}]},"linkedInCompanyPage":"={{ $('E1 - Get prospect').item.json.linkedin_link || undefined }}"}},"credentials":{"hubspotOAuth2Api":{"id":"8J6vWIspjToV6Qwv","name":"HubSpot account 2"}},"typeVersion":2.1},{"id":"e439c1c0-1075-43ad-8a56-0a5529366782","name":"E1 - Creation Successful?","type":"n8n-nodes-base.if","position":[2656,6464],"parameters":{"options":{},"conditions":{"options":{"version":2,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"239351e0-f10a-4dc2-a47f-b5e0978bcda4","operator":{"type":"boolean","operation":"true","singleValue":true},"leftValue":"={{ !!$json.companyId }}","rightValue":""}]}},"typeVersion":2.2},{"id":"1ae2f474-8406-438e-91ea-305b0b795dcf","name":"E1 - Update Tags: Fail","type":"@bedrijfsdatanl/n8n-nodes-prospectpro.prospectpro","onError":"continueRegularOutput","position":[3152,6496],"parameters":{"id":"={{ $json.id }}","operation":"patch","updateOptions":{"tags":"={{ $json.tags }}"},"requestOptions":{}},"credentials":{"prospectproApi":{"id":"wzKM5qJt7DZvsWOD","name":"Bedrijfsdata.nl - XXX003"}},"typeVersion":1,"alwaysOutputData":true},{"id":"788bc02c-99ed-4ec3-a80f-763bfae3f5ce","name":"E1 - Update Tags: Success","type":"@bedrijfsdatanl/n8n-nodes-prospectpro.prospectpro","onError":"continueRegularOutput","position":[3152,6112],"parameters":{"id":"={{ $json.id }}","operation":"patch","updateOptions":{"tags":"={{ $json.tags }}"},"requestOptions":{}},"credentials":{"prospectproApi":{"id":"wzKM5qJt7DZvsWOD","name":"Bedrijfsdata.nl - XXX003"}},"typeVersion":1,"alwaysOutputData":true},{"id":"ff1feadb-a483-4178-92e0-0dd1644c7e04","name":"E1 - return { result: false };","type":"n8n-nodes-base.code","position":[3424,6496],"parameters":{"mode":"runOnceForEachItem","jsCode":"return { result: false };"},"typeVersion":2},{"id":"798c354d-35a1-4174-a332-64eac5018394","name":"F1 - return Hubspot Company object","type":"n8n-nodes-base.code","position":[1872,6848],"parameters":{"mode":"runOnceForEachItem","jsCode":"const hsCompany = $json.results[0];\n\nreturn { ...hsCompany };"},"typeVersion":2},{"id":"859ca841-b7c3-4d42-898e-36ecd7a4d755","name":"F1 - return { result: false };","type":"n8n-nodes-base.code","position":[2416,6912],"parameters":{"mode":"runOnceForEachItem","jsCode":"return { result: false };"},"typeVersion":2},{"id":"e36293c3-16b6-43fd-8576-c8cdf2ab9ca3","name":"F1 - return { result: true, hsCompany: Object };","type":"n8n-nodes-base.code","position":[2416,6720],"parameters":{"mode":"runOnceForEachItem","jsCode":"return { result: true, hsCompany: $json };"},"typeVersion":2},{"id":"fcca107e-54b4-42f6-87ee-84506b1023ba","name":"Sticky Note101","type":"n8n-nodes-base.stickyNote","position":[528,3856],"parameters":{"width":224,"height":368,"content":"### E1 - Example input\n\n`{\n \"id\": 1234567890\n}`"},"typeVersion":1},{"id":"4beb6014-46a9-4b52-b2df-c3a1e7957539","name":"Sticky Note102","type":"n8n-nodes-base.stickyNote","position":[768,5904],"parameters":{"color":5,"width":288,"height":368,"content":"### E1 - Set variables\nManage indicators centrally."},"typeVersion":1},{"id":"a4190e75-9081-45d1-b514-1d649aa3c436","name":"E1 - Set variables","type":"n8n-nodes-base.set","position":[864,6080],"parameters":{"options":{},"assignments":{"assignments":[{"id":"3ff8a838-a321-4245-8c11-fdb4b0b819c1","name":"tag_error","type":"string","value":"EnrichmentFailed"},{"id":"1702df91-fe16-4af8-aec2-2b3602e7bf2f","name":"tag_success","type":"string","value":"Enriched"}]}},"typeVersion":3.4},{"id":"cd01cfbd-0dc2-47ed-a5da-d6d180745c9c","name":"E1 - Add \"tag_success\"","type":"n8n-nodes-base.code","position":[2960,6112],"parameters":{"mode":"runOnceForEachItem","jsCode":"const prospect = $(\"E1 - Get prospect\").first().json;\nconst vars = $('E1 - Set variables').first().json;\nconst tagSuccess = vars.tag_success;\n\nconst tags = (prospect.tags ?? \"\")\n  .split(\"|\")\n  .map(t => t.trim())\n  .filter(Boolean);\n\nif (tagSuccess) tags.push(tagSuccess);\n\nconst uniqueTags = [...new Set(tags)];\n\nreturn {\n  ...prospect,\n  tags: uniqueTags\n};"},"typeVersion":2},{"id":"2e188da5-9f27-426d-acac-d88d917430a5","name":"E1 - Add \"tag_error\"","type":"n8n-nodes-base.code","position":[2960,6496],"parameters":{"mode":"runOnceForEachItem","jsCode":"const prospect = $(\"E1 - Get prospect\").first().json;\nconst vars = $('E1 - Set variables').first().json;\nconst tagError = vars.tag_error;\n\nconst tags = (prospect.tags ?? \"\")\n  .split(\"|\")\n  .map(t => t.trim())\n  .filter(Boolean);\n\nif (tagError) tags.push(tagError);\n\nconst uniqueTags = [...new Set(tags)];\n\nreturn {\n  ...prospect,\n  tags: uniqueTags\n};"},"typeVersion":2},{"id":"9125eea6-7a26-4e41-8a4f-0f0588c713de","name":"E1 - return { result: true };","type":"n8n-nodes-base.code","position":[3424,6112],"parameters":{"mode":"runOnceForEachItem","jsCode":"return { result: true };"},"typeVersion":2},{"id":"7920b54c-a141-4ffa-89f1-459698f3603e","name":"B3 - Initiate pagination","type":"n8n-nodes-base.code","position":[1344,320],"parameters":{"jsCode":"const input = $json;\n\nconst store = $getWorkflowStaticData('global');\nstore.page = 0;\nstore.processed = 0;\nstore.total_pages = 0;\n\nreturn input;"},"typeVersion":2},{"id":"a33d6916-8adb-4a89-9259-a084c6725d1f","name":"Webhook","type":"n8n-nodes-base.webhook","position":[560,-2384],"webhookId":"13d8ae1f-c78f-4e1e-a818-438fbad61fe6","parameters":{"path":"13d8ae1f-c78f-4e1e-a818-438fbad61fe6","options":{}},"typeVersion":2.1},{"id":"286e77f0-2534-4e73-9253-981e6687956a","name":"Sticky Note104","type":"n8n-nodes-base.stickyNote","position":[-96,-1760],"parameters":{"width":560,"height":80,"content":"*On your first read, B and C. Go directly to \"Part 2: Workflows\". It's important to first understand the mechanics of the basic pattern before you dive into details.*"},"typeVersion":1},{"id":"8f6f400d-27ee-40cf-9085-276874d38657","name":"Sticky Note105","type":"n8n-nodes-base.stickyNote","position":[-96,7104],"parameters":{"width":560,"height":80,"content":"*It must seem like ages ago, but do you remember skipping B and C? Going straight to \"Part 2: Workflows\"? It doesn't matter: if you haved read B/C yet, you should!*"},"typeVersion":1},{"id":"2185b3c7-4a02-4272-bae3-c3432ead1c44","name":"Sticky Note103","type":"n8n-nodes-base.stickyNote","position":[-96,7408],"parameters":{"width":566,"height":416,"content":"## 1 - Errors\nSome errors, you just can't prevent. In such cases, you need to get notified. Immediately.\n\nWe suggest you use something like this.\n\n**Please note** you shouldn't assume your messaging-channel *isn't* the cause of the error to begin with. You should therefor add a fallback, like Slack in this example.\n\nUh. What was the problem again? See example: if Telegram is down, a workflow fails to send an important report. This event triggers this error workflow. If Telegram hasn't come back online (which is very likely), the message (on the right) won't send."},"typeVersion":1},{"id":"66455aeb-05e2-456f-9199-279440d67f46","name":"Sticky Note106","type":"n8n-nodes-base.stickyNote","position":[-96,7408],"parameters":{"color":7,"width":1680,"height":400,"content":""},"typeVersion":1},{"id":"c17dfa88-09cf-4dbe-aab1-2d6fa3c3873d","name":"Sticky Note107","type":"n8n-nodes-base.stickyNote","position":[1296,7408],"parameters":{"color":5,"width":288,"height":192,"content":"### 1 - Errors - Log the issue\nLog the issue in a local error log."},"typeVersion":1},{"id":"5e85acb5-c5df-45c6-b3c2-fcbb2f151dc8","name":"Sticky Note108","type":"n8n-nodes-base.stickyNote","position":[-96,7264],"parameters":{"width":566,"height":112,"content":"# Bonus\nMisc. re-usable patterns. Well. For now it's just one. But more will follow."},"typeVersion":1},{"id":"0d2068d6-66f2-4eb5-8c9d-bc4b52722470","name":"1 - Errors - Error Trigger","type":"n8n-nodes-base.errorTrigger","position":[560,7552],"parameters":{},"typeVersion":1},{"id":"c8a5be3b-5f71-4ad0-b503-5589ecd5bd2d","name":"1 - Errors - Insert row","type":"n8n-nodes-base.dataTable","onError":"continueRegularOutput","maxTries":2,"position":[1040,7472],"parameters":{"columns":{"value":{"url":"={{ $json.execution.url }}","workflow_id":"={{ $json.workflow.id }}","execution_id":"={{ $json.execution.id }}"},"schema":[{"id":"workflow_id","type":"string","display":true,"removed":false,"readOnly":false,"required":false,"displayName":"workflow_id","defaultMatch":false},{"id":"execution_id","type":"string","display":true,"removed":false,"readOnly":false,"required":false,"displayName":"execution_id","defaultMatch":false},{"id":"url","type":"string","display":true,"removed":false,"readOnly":false,"required":false,"displayName":"url","defaultMatch":false}],"mappingMode":"defineBelow","matchingColumns":[],"attemptToConvertTypes":false,"convertFieldsToString":false},"options":{},"dataTableId":{"__rl":true,"mode":"list","value":"riCDybFTyQ6SaMzL","cachedResultUrl":"/projects/tgy2Tl0HCDQH0Rbt/datatables/riCDybFTyQ6SaMzL","cachedResultName":"Errors"}},"retryOnFail":true,"typeVersion":1.1},{"id":"785531af-c7ae-4978-bb2d-a6ada3ad0f91","name":"1 - Errors - Send a text message","type":"n8n-nodes-base.telegram","maxTries":5,"position":[1040,7632],"webhookId":"b9422dd1-5518-42e1-a119-4d45c750bf06","parameters":{"text":"=\"n8n issue - workflow #{{ $json.workflow.id }} - execution #{{ $json.execution.id }} - {{ $json.execution.url }}\"","chatId":"000","additionalFields":{}},"credentials":{"telegramApi":{"id":"hf8c8BHfEIhCY9hs","name":"Telegram account"}},"retryOnFail":true,"typeVersion":1.2,"waitBetweenTries":5000},{"id":"6f92af84-d384-463a-bbc2-756ba3feaa5f","name":"Sticky Note109","type":"n8n-nodes-base.stickyNote","position":[1296,7616],"parameters":{"color":5,"width":288,"height":192,"content":"### 1 - Errors - Notify yourself\nNotify yourself. Add a fallback channel to ensure the message gets through."},"typeVersion":1},{"id":"78c90357-25e3-4458-a0dd-a4edf6b441a0","name":"Sticky Note110","type":"n8n-nodes-base.stickyNote","position":[-96,-4832],"parameters":{"width":566,"height":448,"content":"## About this document\nWe’ve rit rate limits. We’ve had workflows spin out of control. And we’ve made many other mistakes in n8n.\n\nOver time, a system developed. A system that works. Even if you enrich a thousand companies in **one execution**.\n\nIt’s highly opinionated. And a bit complicated. Especially if you haven’t done a lot of coding.\n\nBut it works.\n\nAnd we’ve tried our best to explain **why** it works.\n\n**Warning:** this is only for you if (1) you’ve build a dozen workflows, (2) you’ve published a couple and (3) raked up 1000+ executions. If you haven’t: this is not for you yet. But if you have; we believe we can show you a neat trick or two.\n\n*Primary contributor has 17+ years of coding experience, many of which dealing with sync-related systems. This didn't improve his writing. Our apologies.*"},"typeVersion":1}],"active":false,"pinData":{},"settings":{"availableInMCP":false,"executionOrder":"v1"},"versionId":"fa54e312-9652-4515-858b-8dcf42a4d670","connections":{"Wait":{"main":[[{"node":"B3 - Set pagination","type":"main","index":0}]]},"Webhook":{"main":[[{"node":"Process one item at a time - (1)","type":"main","index":0}]]},"C3 - Wait":{"main":[[{"node":"C3 - Set pagination","type":"main","index":0}]]},"B1 - Items":{"main":[[{"node":"B1 - Filter Items","type":"main","index":0}]]},"B2 - Items":{"main":[[{"node":"B2 - Filter Items","type":"main","index":0}]]},"B3 - Items":{"main":[[{"node":"B3 - Filter Items","type":"main","index":0}]]},"C2 - Items":{"main":[[{"node":"C2 - Filter Items","type":"main","index":0}]]},"C3 - Items":{"main":[[{"node":"C3 - Filter Items","type":"main","index":0}]]},"E1 - Found?":{"main":[[{"node":"E1 - Update a company","type":"main","index":0}],[{"node":"E1 - Create a company","type":"main","index":0}]]},"Has Domain?":{"main":[[{"node":"Search Companies by Domain","type":"main","index":0}],[{"node":"F1 - return { result: false };","type":"main","index":0}]]},"Found by ID?":{"main":[[{"node":"F1 - return Hubspot Company object","type":"main","index":0}],[{"node":"Has Domain?","type":"main","index":0}]]},"B1 - Get Items":{"main":[[{"node":"B1 - Has Items?","type":"main","index":0}],[]]},"B2 - Get Items":{"main":[[{"node":"B2 - Has Items?","type":"main","index":0},{"node":"B2 - Update lastSync","type":"main","index":0}]]},"B3 - Get Items":{"main":[[{"node":"B3 - Update lastSync","type":"main","index":0},{"node":"B3 - Update pagination","type":"main","index":0}]]},"C2 - Get Items":{"main":[[{"node":"C2 - Has Items?","type":"main","index":0}]]},"C3 - Get Items":{"main":[[{"node":"C3 - Has Items?","type":"main","index":0}]]},"Create Batches":{"main":[[],[{"node":"Process one item at a time (2)","type":"main","index":0}]]},"D1 - Continue?":{"main":[[{"node":"D1 - Add \"tag_in_progress\"","type":"main","index":0}],[]]},"E1 - Continue?":{"main":[[{"node":"E1 - Find Company in Hubspot","type":"main","index":0}],[{"node":"E1 - Stop and Error","type":"main","index":0}]]},"B1 - Has Items?":{"main":[[{"node":"B1 - Items","type":"main","index":0}]]},"B2 - Has Items?":{"main":[[{"node":"B2 - Items","type":"main","index":0}]]},"B3 - Has Items?":{"main":[[{"node":"B3 - Items","type":"main","index":0}]]},"C2 - Has Items?":{"main":[[{"node":"C2 - Items","type":"main","index":0}]]},"C3 - Has Items?":{"main":[[{"node":"C3 - Items","type":"main","index":0}]]},"B2 - Needs loop?":{"main":[[{"node":"B2 - Call [this workflow]","type":"main","index":0}]]},"D - Identify DMU":{"main":[[{"node":"D - DMU identification successful?","type":"main","index":0}],[{"node":"D - DMU identification successful?","type":"main","index":0}]]},"D - Sync Hubspot":{"main":[[{"node":"D - Hubspot sync successful?","type":"main","index":0}],[{"node":"D - Set output","type":"main","index":0}]]},"Found by Domain?":{"main":[[{"node":"F1 - return Hubspot Company object","type":"main","index":0}],[{"node":"F1 - return { result: false };","type":"main","index":0}]]},"B1 - Set lastSync":{"main":[[{"node":"B1 - Get Items","type":"main","index":0}]]},"B2 - Filter Items":{"main":[[{"node":"B2 - Needs loop?","type":"main","index":0}]]},"B2 - Set lastSync":{"main":[[{"node":"B2 - Get Items","type":"main","index":0}]]},"B3 - Filter Items":{"main":[[{"node":"B3 - Create Batches","type":"main","index":0}]]},"B3 - Set lastSync":{"main":[[{"node":"B3 - Initiate pagination","type":"main","index":0}]]},"C2 - Filter Items":{"main":[[{"node":"C2 - Create Batches","type":"main","index":0}]]},"C3 - Filter Items":{"main":[[{"node":"C3 - Create Batches","type":"main","index":0}]]},"D1 - Get Contacts":{"main":[[{"node":"D1 - Contacts search successful?","type":"main","index":0}],[{"node":"D1 - Get prospect for final update: Fail","type":"main","index":0}]]},"D1 - Get prospect":{"main":[[{"node":"D1 - Continue?","type":"main","index":0}],[{"node":"D1 - Stop and Error","type":"main","index":0}]]},"D1 - Sync Hubspot":{"main":[[{"node":"D1 - Hubspot sync successful?","type":"main","index":0}],[{"node":"D1 - Get prospect for final update: Fail","type":"main","index":0}]]},"E1 - Get prospect":{"main":[[{"node":"E1 - No Existing Errors?","type":"main","index":0}],[{"node":"E1 - Stop and Error","type":"main","index":0}]]},"B1 - Get timestamp":{"main":[[{"node":"B1 - Set lastSync","type":"main","index":0},{"node":"B1 - Has timestamp / not first run?","type":"main","index":0}],[]]},"B1 - Set variables":{"main":[[{"node":"B1 - Get timestamp","type":"main","index":0}]]},"B2 - Get timestamp":{"main":[[{"node":"B2 - Set lastSync","type":"main","index":0}],[{"node":"B2 - Set lastSync","type":"main","index":0}]]},"B2 - Set variables":{"main":[[{"node":"B2 - Get timestamp","type":"main","index":0}]]},"B3 - Done looping?":{"main":[[],[{"node":"B3 - Get Items","type":"main","index":0}]]},"B3 - Get timestamp":{"main":[[{"node":"B3 - Set lastSync","type":"main","index":0}]]},"B3 - Set variables":{"main":[[{"node":"B3 - Get timestamp","type":"main","index":0}]]},"C3 - Set variables":{"main":[[{"node":"C3 - Set pagination","type":"main","index":0}]]},"D - Switch (var b)":{"main":[[{"node":"D - Qualify Prospect (var b)","type":"main","index":0}],[{"node":"D - Identify DMU (var b)","type":"main","index":0}]]},"D1 - Set variables":{"main":[[{"node":"D1 - Get prospect","type":"main","index":0}]]},"E1 - Set variables":{"main":[[{"node":"E1 - Get prospect","type":"main","index":0}]]},"B3 - Create Batches":{"main":[[{"node":"Wait","type":"main","index":0}],[{"node":"B3 - Process one item at a time","type":"main","index":0}]]},"B3 - Set pagination":{"main":[[{"node":"B3 - Done looping?","type":"main","index":0}]]},"C2 - Create Batches":{"main":[[],[{"node":"C2 - Process one item at a time","type":"main","index":0}]]},"C3 - Create Batches":{"main":[[{"node":"C3 - Wait","type":"main","index":0}],[{"node":"C3 - Process one item at a time","type":"main","index":0}]]},"C3 - Set pagination":{"main":[[{"node":"C3 - Get Items","type":"main","index":0}]]},"B2 - Update lastSync":{"main":[[{"node":"B2 - Has timestamp / not first run?","type":"main","index":0}]]},"B3 - Update lastSync":{"main":[[{"node":"B3 - Has timestamp / not first run?","type":"main","index":0}]]},"D - Qualify Prospect":{"main":[[{"node":"D - Qualification Successful?","type":"main","index":0}],[{"node":"D - Qualification Successful?","type":"main","index":0}]]},"D1 - Update prospect":{"main":[[{"node":"D1 - Automatically Qualify Prospect","type":"main","index":0}],[{"node":"D1 - Stop and Error","type":"main","index":0}]]},"E1 - Add \"tag_error\"":{"main":[[{"node":"E1 - Update Tags: Fail","type":"main","index":0}]]},"New Website Visitors":{"main":[[{"node":"Process one item at a time - (1)","type":"main","index":0},{"node":"Create Batches","type":"main","index":0}]]},"B1 - Create timestamp":{"main":[[{"node":"B1 - No Operation, do nothing","type":"main","index":0}]]},"B1 - Schedule Trigger":{"main":[[{"node":"B1 - Set variables","type":"main","index":0}]]},"B1 - Update timestamp":{"main":[[{"node":"B1 - No Operation, do nothing","type":"main","index":0}]]},"B2 - Create timestamp":{"main":[[{"node":"B2 - No Operation, do nothing","type":"main","index":0}]]},"B2 - Schedule Trigger":{"main":[[{"node":"B2 - Set variables","type":"main","index":0}]]},"B2 - Update timestamp":{"main":[[{"node":"B2 - No Operation, do nothing","type":"main","index":0}]]},"B3 - Create timestamp":{"main":[[{"node":"B3 - No Operation, do nothing","type":"main","index":0}]]},"B3 - Schedule Trigger":{"main":[[{"node":"B3 - Set variables","type":"main","index":0}]]},"B3 - Update timestamp":{"main":[[{"node":"B3 - No Operation, do nothing","type":"main","index":0}]]},"E1 - Create a company":{"main":[[{"node":"E1 - Creation Successful?","type":"main","index":0}],[{"node":"E1 - Add \"tag_error\"","type":"main","index":0}]]},"E1 - Update a company":{"main":[[{"node":"E1 - Update Successful?","type":"main","index":0}],[{"node":"E1 - Add \"tag_error\"","type":"main","index":0}]]},"B3 - Update pagination":{"main":[[{"node":"B3 - Has Items?","type":"main","index":0}]]},"Delay after each batch":{"main":[[{"node":"Create Batches","type":"main","index":0}]]},"E1 - Add \"tag_success\"":{"main":[[{"node":"E1 - Update Tags: Success","type":"main","index":0}]]},"E1 - Update Tags: Fail":{"main":[[{"node":"E1 - return { result: false };","type":"main","index":0}]]},"1 - Errors - Insert row":{"main":[[]]},"E1 - Update Successful?":{"main":[[{"node":"E1 - Add \"tag_success\"","type":"main","index":0}],[{"node":"E1 - Add \"tag_error\"","type":"main","index":0}]]},"B3 - Initiate pagination":{"main":[[{"node":"B3 - Set pagination","type":"main","index":0}]]},"D - Identify DMU (var b)":{"main":[[{"node":"D - Sync Hubspot (var b)","type":"main","index":0}],[{"node":"D - Sync Hubspot (var b)","type":"main","index":0}]]},"D - Sync Hubspot (var b)":{"main":[[{"node":"D - Hubspot sync successful? (var b)","type":"main","index":0}],[{"node":"D - Set output","type":"main","index":0}]]},"E1 - No Existing Errors?":{"main":[[{"node":"E1 - Continue?","type":"main","index":0}],[{"node":"E1 - Stop and Error","type":"main","index":0}]]},"B2 - Call [this workflow]":{"main":[[]]},"E1 - Creation Successful?":{"main":[[{"node":"E1 - Add \"tag_success\"","type":"main","index":0}],[{"node":"E1 - Add \"tag_error\"","type":"main","index":0}]]},"E1 - Update Tags: Success":{"main":[[{"node":"E1 - return { result: true };","type":"main","index":0}]]},"1 - Errors - Error Trigger":{"main":[[{"node":"1 - Errors - Insert row","type":"main","index":0},{"node":"1 - Errors - Send a text message","type":"main","index":0}]]},"D1 - Add \"tag_in_progress\"":{"main":[[{"node":"D1 - Update prospect","type":"main","index":0}]]},"Search Companies by Domain":{"main":[[{"node":"Found by Domain?","type":"main","index":0}],[{"node":"F1 - return { result: false };","type":"main","index":0}]]},"B3 - Delay after each batch":{"main":[[{"node":"B3 - Create Batches","type":"main","index":0}]]},"C2 - Delay after each batch":{"main":[[{"node":"C2 - Create Batches","type":"main","index":0}]]},"C3 - Delay after each batch":{"main":[[{"node":"C3 - Create Batches","type":"main","index":0}]]},"D - Hubspot sync successful?":{"main":[[{"node":"D - Set output","type":"main","index":0}],[{"node":"D - Set output","type":"main","index":0}]]},"D - Qualify Prospect (var b)":{"main":[[{"node":"D - Qualification Successful? (var b)","type":"main","index":0}],[{"node":"D - Sync Hubspot (var b)","type":"main","index":0}]]},"E1 - Find Company in Hubspot":{"main":[[{"node":"E1 - Found?","type":"main","index":0}],[{"node":"E1 - Create a company","type":"main","index":0}]]},"D - Qualification Successful?":{"main":[[{"node":"D - Identify DMU","type":"main","index":0}],[{"node":"D - Sync Hubspot","type":"main","index":0}]]},"D1 - Hubspot sync successful?":{"main":[[{"node":"D1 - Get prospect for final update: Success","type":"main","index":0}],[{"node":"D1 - Get prospect for final update: Success","type":"main","index":0}]]},"D1 - Qualification Successful?":{"main":[[{"node":"D1 - Get Contacts","type":"main","index":0}],[{"node":"D1 - Get Contacts","type":"main","index":0}]]},"Process one item at a time (2)":{"main":[[{"node":"Delay after each batch","type":"main","index":0}]]},"B3 - Process one item at a time":{"main":[[{"node":"B3 - Delay after each batch","type":"main","index":0}]]},"C2 - Process one item at a time":{"main":[[{"node":"C2 - Delay after each batch","type":"main","index":0}]]},"C3 - Process one item at a time":{"main":[[{"node":"C3 - Delay after each batch","type":"main","index":0}]]},"D1 - Contacts search successful?":{"main":[[{"node":"D1 - Sync Hubspot","type":"main","index":0}],[{"node":"D1 - Sync Hubspot","type":"main","index":0}]]},"D - DMU identification successful?":{"main":[[{"node":"D - Sync Hubspot","type":"main","index":0}],[{"node":"D - Set output","type":"main","index":0}]]},"F1 - return Hubspot Company object":{"main":[[{"node":"F1 - return { result: true, hsCompany: Object };","type":"main","index":0}]]},"B1 - Has timestamp / not first run?":{"main":[[{"node":"B1 - Update timestamp","type":"main","index":0}],[{"node":"B1 - Create timestamp","type":"main","index":0}]]},"B2 - Has timestamp / not first run?":{"main":[[{"node":"B2 - Update timestamp","type":"main","index":0}],[{"node":"B2 - Create timestamp","type":"main","index":0}]]},"B3 - Has timestamp / not first run?":{"main":[[{"node":"B3 - Update timestamp","type":"main","index":0}],[{"node":"B3 - Create timestamp","type":"main","index":0}]]},"D1 - Automatically Qualify Prospect":{"main":[[{"node":"D1 - Qualification Successful?","type":"main","index":0}],[{"node":"D1 - Get prospect for final update: Fail","type":"main","index":0}]]},"Search Companies by Bedrijfsdata ID":{"main":[[{"node":"Found by ID?","type":"main","index":0}],[{"node":"Has Domain?","type":"main","index":0}]]},"When Executed by [trigger workflow]":{"main":[[{"node":"D - Qualify Prospect","type":"main","index":0},{"node":"D - Switch (var b)","type":"main","index":0},{"node":"D1 - Set variables","type":"main","index":0},{"node":"E1 - Get prospect","type":"main","index":0},{"node":"Search Companies by Bedrijfsdata ID","type":"main","index":0}]]},"D - Hubspot sync successful? (var b)":{"main":[[{"node":"D - Set output","type":"main","index":0}],[{"node":"D - Set output","type":"main","index":0}]]},"When clicking ‘Execute workflow’":{"main":[[{"node":"C1 - Process one item at a time","type":"main","index":0},{"node":"C2 - Get Items","type":"main","index":0},{"node":"C3 - Set variables","type":"main","index":0}]]},"D - Qualification Successful? (var b)":{"main":[[{"node":"D - Identify DMU (var b)","type":"main","index":0}],[{"node":"D - Set output","type":"main","index":0}]]},"D1 - Get prospect for final update: Fail":{"main":[[{"node":"D1 - Add \"tag_error\", remove \"tag_in_progress\"","type":"main","index":0}]]},"D1 - Get prospect for final update: Success":{"main":[[{"node":"D1 - Add \"tag_success\", remove \"tag_in_processing\"","type":"main","index":0}]]},"D1 - Add \"tag_error\", remove \"tag_in_progress\"":{"main":[[{"node":"D1 - Update Tags: Fail","type":"main","index":0}]]},"D1 - Add \"tag_success\", remove \"tag_in_processing\"":{"main":[[{"node":"D1 - Update Tags: Success","type":"main","index":0}]]}}},"lastUpdatedBy":1,"workflowInfo":{"nodeCount":244,"nodeTypes":{"n8n-nodes-base.if":{"count":27},"n8n-nodes-base.set":{"count":7},"n8n-nodes-base.code":{"count":19},"n8n-nodes-base.noOp":{"count":3},"n8n-nodes-base.wait":{"count":6},"n8n-nodes-base.filter":{"count":5},"n8n-nodes-base.switch":{"count":1},"n8n-nodes-base.hubspot":{"count":2},"n8n-nodes-base.webhook":{"count":1},"n8n-nodes-base.splitOut":{"count":5},"n8n-nodes-base.telegram":{"count":1},"n8n-nodes-base.dataTable":{"count":10},"n8n-nodes-base.stickyNote":{"count":111},"n8n-nodes-base.httpRequest":{"count":7},"n8n-nodes-base.errorTrigger":{"count":1},"n8n-nodes-base.stopAndError":{"count":2},"n8n-nodes-base.manualTrigger":{"count":1},"n8n-nodes-base.splitInBatches":{"count":4},"n8n-nodes-base.executeWorkflow":{"count":17},"n8n-nodes-base.scheduleTrigger":{"count":3},"n8n-nodes-base.executeWorkflowTrigger":{"count":1},"@bedrijfsdatanl/n8n-nodes-prospectpro.prospectpro":{"count":9},"@bedrijfsdatanl/n8n-nodes-prospectpro.prospectproTrigger":{"count":1}}},"status":"published","readyToDemo":null,"user":{"name":"Olivier","username":"olivier-nl","bio":"","verified":true,"links":[],"avatar":"https://gravatar.com/avatar/028f79e14efaca7962fdc9a594b7ba252058048514ce4db459c95b6ebcdb3609?r=pg&d=retro&size=200"},"nodes":[{"id":12,"icon":"fa:bug","name":"n8n-nodes-base.errorTrigger","codex":{"data":{"details":"In n8n, when a workflow execution fails, it can start another workflow. This second workflow can be any arbitrary workflow on your n8n instance. Use the Error Trigger node as your Trigger in the Error workflow.","resources":{"generic":[{"url":"https://n8n.io/blog/creating-error-workflows-in-n8n/","icon":"🌪","label":"Creating Error Workflows in n8n"}],"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-base.errortrigger/"}]},"categories":["Development","Core Nodes"],"nodeVersion":"1.0","codexVersion":"1.0","subcategories":{"Core Nodes":["Other Trigger Nodes"]}}},"group":"[\"trigger\"]","defaults":{"name":"Error Trigger","color":"#0000FF"},"iconData":{"icon":"bug","type":"icon"},"displayName":"Error Trigger","typeVersion":1,"nodeCategories":[{"id":5,"name":"Development"},{"id":9,"name":"Core Nodes"}]},{"id":19,"icon":"file:httprequest.svg","name":"n8n-nodes-base.httpRequest","codex":{"data":{"alias":["API","Request","URL","Build","cURL"],"resources":{"generic":[{"url":"https://n8n.io/blog/2021-the-year-to-automate-the-new-you-with-n8n/","icon":"☀️","label":"2021: The Year to Automate the New You with n8n"},{"url":"https://n8n.io/blog/why-business-process-automation-with-n8n-can-change-your-daily-life/","icon":"🧬","label":"Why business process automation with n8n can change your daily life"},{"url":"https://n8n.io/blog/automatically-pulling-and-visualizing-data-with-n8n/","icon":"📈","label":"Automatically pulling and visualizing data with n8n"},{"url":"https://n8n.io/blog/learn-how-to-automatically-cross-post-your-content-with-n8n/","icon":"✍️","label":"Learn how to automatically cross-post your content with n8n"},{"url":"https://n8n.io/blog/automatically-adding-expense-receipts-to-google-sheets-with-telegram-mindee-twilio-and-n8n/","icon":"🧾","label":"Automatically Adding Expense Receipts to Google Sheets with Telegram, Mindee, Twilio, and n8n"},{"url":"https://n8n.io/blog/running-n8n-on-ships-an-interview-with-maranics/","icon":"🛳","label":"Running n8n on ships: An interview with Maranics"},{"url":"https://n8n.io/blog/what-are-apis-how-to-use-them-with-no-code/","icon":" 🪢","label":"What are APIs and how to use them with no code"},{"url":"https://n8n.io/blog/5-tasks-you-can-automate-with-notion-api/","icon":"⚡️","label":"5 tasks you can automate with the new Notion API "},{"url":"https://n8n.io/blog/world-poetry-day-workflow/","icon":"📜","label":"Celebrating World Poetry Day with a daily poem in Telegram"},{"url":"https://n8n.io/blog/automate-google-apps-for-productivity/","icon":"💡","label":"15 Google apps you can combine and automate to increase productivity"},{"url":"https://n8n.io/blog/automate-designs-with-bannerbear-and-n8n/","icon":"🎨","label":"Automate Designs with Bannerbear and n8n"},{"url":"https://n8n.io/blog/how-uproc-scraped-a-multi-page-website-with-a-low-code-workflow/","icon":" 🕸️","label":"How uProc scraped a multi-page website with a low-code workflow"},{"url":"https://n8n.io/blog/building-an-expense-tracking-app-in-10-minutes/","icon":"📱","label":"Building an expense tracking app in 10 minutes"},{"url":"https://n8n.io/blog/5-workflow-automations-for-mattermost-that-we-love-at-n8n/","icon":"🤖","label":"5 workflow automations for Mattermost that we love at n8n"},{"url":"https://n8n.io/blog/how-to-use-the-http-request-node-the-swiss-army-knife-for-workflow-automation/","icon":"🧰","label":"How to use the HTTP Request Node - The Swiss Army Knife for Workflow Automation"},{"url":"https://n8n.io/blog/learn-how-to-use-webhooks-with-mattermost-slash-commands/","icon":"🦄","label":"Learn how to use webhooks with Mattermost slash commands"},{"url":"https://n8n.io/blog/how-a-membership-development-manager-automates-his-work-and-investments/","icon":"📈","label":"How a Membership Development Manager automates his work and investments"},{"url":"https://n8n.io/blog/a-low-code-bitcoin-ticker-built-with-questdb-and-n8n-io/","icon":"📈","label":"A low-code bitcoin ticker built with QuestDB and n8n.io"},{"url":"https://n8n.io/blog/how-to-set-up-a-ci-cd-pipeline-with-no-code/","icon":"🎡","label":"How to set up a no-code CI/CD pipeline with GitHub and TravisCI"},{"url":"https://n8n.io/blog/automations-for-activists/","icon":"✨","label":"How Common Knowledge use workflow automation for activism"},{"url":"https://n8n.io/blog/creating-scheduled-text-affirmations-with-n8n/","icon":"🤟","label":"Creating scheduled text affirmations with n8n"},{"url":"https://n8n.io/blog/how-goomer-automated-their-operations-with-over-200-n8n-workflows/","icon":"🛵","label":"How Goomer automated their operations with over 200 n8n workflows"},{"url":"https://n8n.io/blog/aws-workflow-automation/","label":"7 no-code workflow automations for Amazon Web Services"}],"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-base.httprequest/"}]},"categories":["Development","Core Nodes"],"nodeVersion":"1.0","codexVersion":"1.0","subcategories":{"Core Nodes":["Helpers"]}}},"group":"[\"output\"]","defaults":{"name":"HTTP Request","color":"#0004F5"},"iconData":{"type":"file","fileBuffer":"data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNDAiIGhlaWdodD0iNDAiIHZpZXdCb3g9IjAgMCA0MCA0MCIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZmlsbC1ydWxlPSJldmVub2RkIiBjbGlwLXJ1bGU9ImV2ZW5vZGQiIGQ9Ik00MCAyMEM0MCA4Ljk1MzE0IDMxLjA0NjkgMCAyMCAwQzguOTUzMTQgMCAwIDguOTUzMTQgMCAyMEMwIDMxLjA0NjkgOC45NTMxNCA0MCAyMCA0MEMzMS4wNDY5IDQwIDQwIDMxLjA0NjkgNDAgMjBaTTIwIDM2Ljk0NThDMTguODg1MiAzNi45NDU4IDE3LjEzNzggMzUuOTY3IDE1LjQ5OTggMzIuNjk4NUMxNC43OTY0IDMxLjI5MTggMTQuMTk2MSAyOS41NDMxIDEzLjc1MjYgMjcuNjg0N0gyNi4xODk4QzI1LjgwNDUgMjkuNTQwMyAyNS4yMDQ0IDMxLjI5MDEgMjQuNTAwMiAzMi42OTg1QzIyLjg2MjIgMzUuOTY3IDIxLjExNDggMzYuOTQ1OCAyMCAzNi45NDU4Wk0xMi45MDY0IDIwQzEyLjkwNjQgMjEuNjA5NyAxMy4wMDg3IDIzLjE2NCAxMy4yMDAzIDI0LjYzMDVIMjYuNzk5N0MyNi45OTEzIDIzLjE2NCAyNy4wOTM2IDIxLjYwOTcgMjcuMDkzNiAyMEMyNy4wOTM2IDE4LjM5MDMgMjYuOTkxMyAxNi44MzYgMjYuNzk5NyAxNS4zNjk1SDEzLjIwMDNDMTMuMDA4NyAxNi44MzYgMTIuOTA2NCAxOC4zOTAzIDEyLjkwNjQgMjBaTTIwIDMuMDU0MTlDMjEuMTE0OSAzLjA1NDE5IDIyLjg2MjIgNC4wMzA3OCAyNC41MDAxIDcuMzAwMzlDMjUuMjA2NiA4LjcxNDA4IDI1LjgwNzIgMTAuNDA2NyAyNi4xOTIgMTIuMzE1M0gxMy43NTAxQzE0LjE5MzMgMTAuNDA0NyAxNC43OTQyIDguNzEyNTQgMTUuNDk5OCA3LjMwMDY0QzE3LjEzNzcgNC4wMzA4MyAxOC44ODUxIDMuMDU0MTkgMjAgMy4wNTQxOVpNMzAuMTQ3OCAyMEMzMC4xNDc4IDE4LjQwOTkgMzAuMDU0MyAxNi44NjE3IDI5LjgyMjcgMTUuMzY5NUgzNi4zMDQyQzM2LjcyNTIgMTYuODQyIDM2Ljk0NTggMTguMzk2NCAzNi45NDU4IDIwQzM2Ljk0NTggMjEuNjAzNiAzNi43MjUyIDIzLjE1OCAzNi4zMDQyIDI0LjYzMDVIMjkuODIyN0MzMC4wNTQzIDIzLjEzODMgMzAuMTQ3OCAyMS41OTAxIDMwLjE0NzggMjBaTTI2LjI3NjcgNC4yNTUxMkMyNy42MzY1IDYuMzYwMTkgMjguNzExIDkuMTMyIDI5LjM3NzQgMTIuMzE1M0gzNS4xMDQ2QzMzLjI1MTEgOC42NjggMzAuMTA3IDUuNzgzNDYgMjYuMjc2NyA0LjI1NTEyWk0xMC42MjI2IDEyLjMxNTNINC44OTI5M0M2Ljc1MTQ3IDguNjY3ODQgOS44OTM1MSA1Ljc4MzQxIDEzLjcyMzIgNC4yNTUxM0MxMi4zNjM1IDYuMzYwMjEgMTEuMjg5IDkuMTMyMDEgMTAuNjIyNiAxMi4zMTUzWk0zLjA1NDE5IDIwQzMuMDU0MTkgMjEuNjAzIDMuMjc3NDMgMjMuMTU3NSAzLjY5NDg0IDI0LjYzMDVIMTAuMTIxN0M5Ljk0NjE5IDIzLjE0MiA5Ljg1MjIyIDIxLjU5NDMgOS44NTIyMiAyMEM5Ljg1MjIyIDE4LjQwNTcgOS45NDYxOSAxNi44NTggMTAuMTIxNyAxNS4zNjk1SDMuNjk0ODRDMy4yNzc0MyAxNi44NDI1IDMuMDU0MTkgMTguMzk3IDMuMDU0MTkgMjBaTTI2LjI3NjYgMzUuNzQyN0MyNy42MzY1IDMzLjYzOTMgMjguNzExIDMwLjg2OCAyOS4zNzc0IDI3LjY4NDdIMzUuMTA0NkMzMy4yNTEgMzEuMzMyMiAzMC4xMDY4IDM0LjIxNzkgMjYuMjc2NiAzNS43NDI3Wk0xMy43MjM0IDM1Ljc0MjdDOS44OTM2OSAzNC4yMTc5IDYuNzUxNTUgMzEuMzMyNCA0Ljg5MjkzIDI3LjY4NDdIMTAuNjIyNkMxMS4yODkgMzAuODY4IDEyLjM2MzUgMzMuNjM5MyAxMy43MjM0IDM1Ljc0MjdaIiBmaWxsPSIjM0E0MkU5Ii8+Cjwvc3ZnPgo="},"displayName":"HTTP Request","typeVersion":4,"nodeCategories":[{"id":5,"name":"Development"},{"id":9,"name":"Core Nodes"}]},{"id":20,"icon":"fa:map-signs","name":"n8n-nodes-base.if","codex":{"data":{"alias":["Router","Filter","Condition","Logic","Boolean","Branch"],"details":"The IF node can be used to implement binary conditional logic in your workflow. You can set up one-to-many conditions to evaluate each item of data being inputted into the node. That data will either evaluate to TRUE or FALSE and route out of the node accordingly.\n\nThis node has multiple types of conditions: Bool, String, Number, and Date & Time.","resources":{"generic":[{"url":"https://n8n.io/blog/learn-to-automate-your-factorys-incident-reporting-a-step-by-step-guide/","icon":"🏭","label":"Learn to Automate Your Factory's Incident Reporting: A Step by Step Guide"},{"url":"https://n8n.io/blog/2021-the-year-to-automate-the-new-you-with-n8n/","icon":"☀️","label":"2021: The Year to Automate the New You with n8n"},{"url":"https://n8n.io/blog/why-business-process-automation-with-n8n-can-change-your-daily-life/","icon":"🧬","label":"Why business process automation with n8n can change your daily life"},{"url":"https://n8n.io/blog/create-a-toxic-language-detector-for-telegram/","icon":"🤬","label":"Create a toxic language detector for Telegram in 4 step"},{"url":"https://n8n.io/blog/no-code-ecommerce-workflow-automations/","icon":"store","label":"6 e-commerce workflows to power up your Shopify s"},{"url":"https://n8n.io/blog/how-to-build-a-low-code-self-hosted-url-shortener/","icon":"🔗","label":"How to build a low-code, self-hosted URL shortener in 3 steps"},{"url":"https://n8n.io/blog/automate-your-data-processing-pipeline-in-9-steps-with-n8n/","icon":"⚙️","label":"Automate your data processing pipeline in 9 steps"},{"url":"https://n8n.io/blog/how-to-get-started-with-crm-automation-and-no-code-workflow-ideas/","icon":"👥","label":"How to get started with CRM automation (with 3 no-code workflow ideas"},{"url":"https://n8n.io/blog/5-tasks-you-can-automate-with-notion-api/","icon":"⚡️","label":"5 tasks you can automate with the new Notion API "},{"url":"https://n8n.io/blog/automate-google-apps-for-productivity/","icon":"💡","label":"15 Google apps you can combine and automate to increase productivity"},{"url":"https://n8n.io/blog/automation-for-maintainers-of-open-source-projects/","icon":"🏷️","label":"How to automatically manage contributions to open-source projects"},{"url":"https://n8n.io/blog/how-uproc-scraped-a-multi-page-website-with-a-low-code-workflow/","icon":" 🕸️","label":"How uProc scraped a multi-page website with a low-code workflow"},{"url":"https://n8n.io/blog/5-workflow-automations-for-mattermost-that-we-love-at-n8n/","icon":"🤖","label":"5 workflow automations for Mattermost that we love at n8n"},{"url":"https://n8n.io/blog/why-this-product-manager-loves-workflow-automation-with-n8n/","icon":"🧠","label":"Why this Product Manager loves workflow automation with n8n"},{"url":"https://n8n.io/blog/sending-automated-congratulations-with-google-sheets-twilio-and-n8n/","icon":"🙌","label":"Sending Automated Congratulations with Google Sheets, Twilio, and n8n "},{"url":"https://n8n.io/blog/how-to-set-up-a-ci-cd-pipeline-with-no-code/","icon":"🎡","label":"How to set up a no-code CI/CD pipeline with GitHub and TravisCI"},{"url":"https://n8n.io/blog/benefits-of-automation-and-n8n-an-interview-with-hubspots-hugh-durkin/","icon":"🎖","label":"Benefits of automation and n8n: An interview with HubSpot's Hugh Durkin"},{"url":"https://n8n.io/blog/aws-workflow-automation/","label":"7 no-code workflow automations for Amazon Web Services"}],"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-base.if/"}]},"categories":["Core Nodes"],"nodeVersion":"1.0","codexVersion":"1.0","subcategories":{"Core Nodes":["Flow"]}}},"group":"[\"transform\"]","defaults":{"name":"If","color":"#408000"},"iconData":{"icon":"map-signs","type":"icon"},"displayName":"If","typeVersion":2,"nodeCategories":[{"id":9,"name":"Core Nodes"}]},{"id":26,"icon":"fa:arrow-right","name":"n8n-nodes-base.noOp","codex":{"data":{"alias":["nothing"],"resources":{"generic":[{"url":"https://n8n.io/blog/learn-to-automate-your-factorys-incident-reporting-a-step-by-step-guide/","icon":"🏭","label":"Learn to Automate Your Factory's Incident Reporting: A Step by Step Guide"},{"url":"https://n8n.io/blog/2021-the-year-to-automate-the-new-you-with-n8n/","icon":"☀️","label":"2021: The Year to Automate the New You with n8n"},{"url":"https://n8n.io/blog/create-a-toxic-language-detector-for-telegram/","icon":"🤬","label":"Create a toxic language detector for Telegram in 4 step"},{"url":"https://n8n.io/blog/no-code-ecommerce-workflow-automations/","icon":"store","label":"6 e-commerce workflows to power up your Shopify s"},{"url":"https://n8n.io/blog/automate-your-data-processing-pipeline-in-9-steps-with-n8n/","icon":"⚙️","label":"Automate your data processing pipeline in 9 steps"},{"url":"https://n8n.io/blog/how-to-get-started-with-crm-automation-and-no-code-workflow-ideas/","icon":"👥","label":"How to get started with CRM automation (with 3 no-code workflow ideas"},{"url":"https://n8n.io/blog/5-tasks-you-can-automate-with-notion-api/","icon":"⚡️","label":"5 tasks you can automate with the new Notion API "},{"url":"https://n8n.io/blog/5-workflow-automations-for-mattermost-that-we-love-at-n8n/","icon":"🤖","label":"5 workflow automations for Mattermost that we love at n8n"},{"url":"https://n8n.io/blog/sending-automated-congratulations-with-google-sheets-twilio-and-n8n/","icon":"🙌","label":"Sending Automated Congratulations with Google Sheets, Twilio, and n8n "},{"url":"https://n8n.io/blog/how-to-set-up-a-ci-cd-pipeline-with-no-code/","icon":"🎡","label":"How to set up a no-code CI/CD pipeline with GitHub and TravisCI"},{"url":"https://n8n.io/blog/benefits-of-automation-and-n8n-an-interview-with-hubspots-hugh-durkin/","icon":"🎖","label":"Benefits of automation and n8n: An interview with HubSpot's Hugh Durkin"},{"url":"https://n8n.io/blog/aws-workflow-automation/","label":"7 no-code workflow automations for Amazon Web Services"}],"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-base.noop/"}]},"categories":["Core Nodes"],"nodeVersion":"1.0","codexVersion":"1.0","subcategories":{"Core Nodes":["Helpers"]}}},"group":"[\"organization\"]","defaults":{"name":"No Operation, do nothing","color":"#b0b0b0"},"iconData":{"icon":"arrow-right","type":"icon"},"displayName":"No Operation, do nothing","typeVersion":1,"nodeCategories":[{"id":9,"name":"Core Nodes"}]},{"id":38,"icon":"fa:pen","name":"n8n-nodes-base.set","codex":{"data":{"alias":["Set","JS","JSON","Filter","Transform","Map"],"resources":{"generic":[{"url":"https://n8n.io/blog/learn-to-automate-your-factorys-incident-reporting-a-step-by-step-guide/","icon":"🏭","label":"Learn to Automate Your Factory's Incident Reporting: A Step by Step Guide"},{"url":"https://n8n.io/blog/2021-the-year-to-automate-the-new-you-with-n8n/","icon":"☀️","label":"2021: The Year to Automate the New You with n8n"},{"url":"https://n8n.io/blog/automatically-pulling-and-visualizing-data-with-n8n/","icon":"📈","label":"Automatically pulling and visualizing data with n8n"},{"url":"https://n8n.io/blog/database-monitoring-and-alerting-with-n8n/","icon":"📡","label":"Database Monitoring and Alerting with n8n"},{"url":"https://n8n.io/blog/automatically-adding-expense-receipts-to-google-sheets-with-telegram-mindee-twilio-and-n8n/","icon":"🧾","label":"Automatically Adding Expense Receipts to Google Sheets with Telegram, Mindee, Twilio, and n8n"},{"url":"https://n8n.io/blog/no-code-ecommerce-workflow-automations/","icon":"store","label":"6 e-commerce workflows to power up your Shopify s"},{"url":"https://n8n.io/blog/how-to-build-a-low-code-self-hosted-url-shortener/","icon":"🔗","label":"How to build a low-code, self-hosted URL shortener in 3 steps"},{"url":"https://n8n.io/blog/automate-your-data-processing-pipeline-in-9-steps-with-n8n/","icon":"⚙️","label":"Automate your data processing pipeline in 9 steps"},{"url":"https://n8n.io/blog/how-to-get-started-with-crm-automation-and-no-code-workflow-ideas/","icon":"👥","label":"How to get started with CRM automation (with 3 no-code workflow ideas"},{"url":"https://n8n.io/blog/5-tasks-you-can-automate-with-notion-api/","icon":"⚡️","label":"5 tasks you can automate with the new Notion API "},{"url":"https://n8n.io/blog/automate-google-apps-for-productivity/","icon":"💡","label":"15 Google apps you can combine and automate to increase productivity"},{"url":"https://n8n.io/blog/how-uproc-scraped-a-multi-page-website-with-a-low-code-workflow/","icon":" 🕸️","label":"How uProc scraped a multi-page website with a low-code workflow"},{"url":"https://n8n.io/blog/building-an-expense-tracking-app-in-10-minutes/","icon":"📱","label":"Building an expense tracking app in 10 minutes"},{"url":"https://n8n.io/blog/the-ultimate-guide-to-automate-your-video-collaboration-with-whereby-mattermost-and-n8n/","icon":"📹","label":"The ultimate guide to automate your video collaboration with Whereby, Mattermost, and n8n"},{"url":"https://n8n.io/blog/5-workflow-automations-for-mattermost-that-we-love-at-n8n/","icon":"🤖","label":"5 workflow automations for Mattermost that we love at n8n"},{"url":"https://n8n.io/blog/learn-to-build-powerful-api-endpoints-using-webhooks/","icon":"🧰","label":"Learn to Build Powerful API Endpoints Using Webhooks"},{"url":"https://n8n.io/blog/how-a-membership-development-manager-automates-his-work-and-investments/","icon":"📈","label":"How a Membership Development Manager automates his work and investments"},{"url":"https://n8n.io/blog/a-low-code-bitcoin-ticker-built-with-questdb-and-n8n-io/","icon":"📈","label":"A low-code bitcoin ticker built with QuestDB and n8n.io"},{"url":"https://n8n.io/blog/how-to-set-up-a-ci-cd-pipeline-with-no-code/","icon":"🎡","label":"How to set up a no-code CI/CD pipeline with GitHub and TravisCI"},{"url":"https://n8n.io/blog/benefits-of-automation-and-n8n-an-interview-with-hubspots-hugh-durkin/","icon":"🎖","label":"Benefits of automation and n8n: An interview with HubSpot's Hugh Durkin"},{"url":"https://n8n.io/blog/how-goomer-automated-their-operations-with-over-200-n8n-workflows/","icon":"🛵","label":"How Goomer automated their operations with over 200 n8n workflows"},{"url":"https://n8n.io/blog/aws-workflow-automation/","label":"7 no-code workflow automations for Amazon Web Services"}],"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-base.set/"}]},"categories":["Core Nodes"],"nodeVersion":"1.0","codexVersion":"1.0","subcategories":{"Core Nodes":["Data Transformation"]}}},"group":"[\"input\"]","defaults":{"name":"Edit Fields"},"iconData":{"icon":"pen","type":"icon"},"displayName":"Edit Fields (Set)","typeVersion":3,"nodeCategories":[{"id":9,"name":"Core Nodes"}]},{"id":39,"icon":"fa:sync","name":"n8n-nodes-base.splitInBatches","codex":{"data":{"alias":["Loop","Concatenate","Batch","Split","Split In Batches"],"resources":{"generic":[{"url":"https://n8n.io/blog/how-uproc-scraped-a-multi-page-website-with-a-low-code-workflow/","icon":" 🕸️","label":"How uProc scraped a multi-page website with a low-code workflow"},{"url":"https://n8n.io/blog/benefits-of-automation-and-n8n-an-interview-with-hubspots-hugh-durkin/","icon":"🎖","label":"Benefits of automation and n8n: An interview with HubSpot's Hugh Durkin"}],"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-base.splitinbatches/"}]},"categories":["Core Nodes"],"nodeVersion":"1.0","codexVersion":"1.0","subcategories":{"Core Nodes":["Flow"]}}},"group":"[\"organization\"]","defaults":{"name":"Loop Over Items","color":"#007755"},"iconData":{"icon":"sync","type":"icon"},"displayName":"Loop Over Items (Split in Batches)","typeVersion":3,"nodeCategories":[{"id":9,"name":"Core Nodes"}]},{"id":47,"icon":"file:webhook.svg","name":"n8n-nodes-base.webhook","codex":{"data":{"alias":["HTTP","API","Build","WH"],"resources":{"generic":[{"url":"https://n8n.io/blog/learn-how-to-automatically-cross-post-your-content-with-n8n/","icon":"✍️","label":"Learn how to automatically cross-post your content with n8n"},{"url":"https://n8n.io/blog/running-n8n-on-ships-an-interview-with-maranics/","icon":"🛳","label":"Running n8n on ships: An interview with Maranics"},{"url":"https://n8n.io/blog/how-to-build-a-low-code-self-hosted-url-shortener/","icon":"🔗","label":"How to build a low-code, self-hosted URL shortener in 3 steps"},{"url":"https://n8n.io/blog/what-are-apis-how-to-use-them-with-no-code/","icon":" 🪢","label":"What are APIs and how to use them with no code"},{"url":"https://n8n.io/blog/5-tasks-you-can-automate-with-notion-api/","icon":"⚡️","label":"5 tasks you can automate with the new Notion API "},{"url":"https://n8n.io/blog/how-a-digital-strategist-uses-n8n-for-online-marketing/","icon":"💻","label":"How a digital strategist uses n8n for online marketing"},{"url":"https://n8n.io/blog/the-ultimate-guide-to-automate-your-video-collaboration-with-whereby-mattermost-and-n8n/","icon":"📹","label":"The ultimate guide to automate your video collaboration with Whereby, Mattermost, and n8n"},{"url":"https://n8n.io/blog/how-to-automatically-give-kudos-to-contributors-with-github-slack-and-n8n/","icon":"👏","label":"How to automatically give kudos to contributors with GitHub, Slack, and n8n"},{"url":"https://n8n.io/blog/5-workflow-automations-for-mattermost-that-we-love-at-n8n/","icon":"🤖","label":"5 workflow automations for Mattermost that we love at n8n"},{"url":"https://n8n.io/blog/why-this-product-manager-loves-workflow-automation-with-n8n/","icon":"🧠","label":"Why this Product Manager loves workflow automation with n8n"},{"url":"https://n8n.io/blog/creating-custom-incident-response-workflows-with-n8n/","label":"How to automate every step of an incident response workflow"},{"url":"https://n8n.io/blog/learn-to-build-powerful-api-endpoints-using-webhooks/","icon":"🧰","label":"Learn to Build Powerful API Endpoints Using Webhooks"},{"url":"https://n8n.io/blog/learn-how-to-use-webhooks-with-mattermost-slash-commands/","icon":"🦄","label":"Learn how to use webhooks with Mattermost slash commands"},{"url":"https://n8n.io/blog/how-goomer-automated-their-operations-with-over-200-n8n-workflows/","icon":"🛵","label":"How Goomer automated their operations with over 200 n8n workflows"}],"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-base.webhook/"}]},"categories":["Development","Core Nodes"],"nodeVersion":"1.0","codexVersion":"1.0","subcategories":{"Core Nodes":["Helpers"]}}},"group":"[\"trigger\"]","defaults":{"name":"Webhook"},"iconData":{"type":"file","fileBuffer":"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSI0OCIgaGVpZ2h0PSI0OCI+PHBhdGggZmlsbD0iIzM3NDc0ZiIgZD0iTTM1IDM3Yy0yLjIgMC00LTEuOC00LTRzMS44LTQgNC00IDQgMS44IDQgNC0xLjggNC00IDQiLz48cGF0aCBmaWxsPSIjMzc0NzRmIiBkPSJNMzUgNDNjLTMgMC01LjktMS40LTcuOC0zLjdsMy4xLTIuNWMxLjEgMS40IDIuOSAyLjMgNC43IDIuMyAzLjMgMCA2LTIuNyA2LTZzLTIuNy02LTYtNmMtMSAwLTIgLjMtMi45LjdsLTEuNyAxTDIzLjMgMTZsMy41LTEuOSA1LjMgOS40YzEtLjMgMi0uNSAzLS41IDUuNSAwIDEwIDQuNSAxMCAxMFM0MC41IDQzIDM1IDQzIi8+PHBhdGggZmlsbD0iIzM3NDc0ZiIgZD0iTTE0IDQzQzguNSA0MyA0IDM4LjUgNCAzM2MwLTQuNiAzLjEtOC41IDcuNS05LjdsMSAzLjlDOS45IDI3LjkgOCAzMC4zIDggMzNjMCAzLjMgMi43IDYgNiA2czYtMi43IDYtNnYtMmgxNXY0SDIzLjhjLS45IDQuNi01IDgtOS44IDgiLz48cGF0aCBmaWxsPSIjZTkxZTYzIiBkPSJNMTQgMzdjLTIuMiAwLTQtMS44LTQtNHMxLjgtNCA0LTQgNCAxLjggNCA0LTEuOCA0LTQgNCIvPjxwYXRoIGZpbGw9IiMzNzQ3NGYiIGQ9Ik0yNSAxOWMtMi4yIDAtNC0xLjgtNC00czEuOC00IDQtNCA0IDEuOCA0IDQtMS44IDQtNCA0Ii8+PHBhdGggZmlsbD0iI2U5MWU2MyIgZD0ibTE1LjcgMzQtMy40LTIgNS45LTkuN2MtMi0xLjktMy4yLTQuNS0zLjItNy4zIDAtNS41IDQuNS0xMCAxMC0xMHMxMCA0LjUgMTAgMTBjMCAuOS0uMSAxLjctLjMgMi41bC0zLjktMWMuMS0uNS4yLTEgLjItMS41IDAtMy4zLTIuNy02LTYtNnMtNiAyLjctNiA2YzAgMi4xIDEuMSA0IDIuOSA1LjFsMS43IDF6Ii8+PC9zdmc+"},"displayName":"Webhook","typeVersion":2,"nodeCategories":[{"id":5,"name":"Development"},{"id":9,"name":"Core Nodes"}]},{"id":49,"icon":"file:telegram.svg","name":"n8n-nodes-base.telegram","codex":{"data":{"alias":["human","form","wait","hitl","approval"],"resources":{"generic":[{"url":"https://n8n.io/blog/why-business-process-automation-with-n8n-can-change-your-daily-life/","icon":"🧬","label":"Why business process automation with n8n can change your daily life"},{"url":"https://n8n.io/blog/create-a-toxic-language-detector-for-telegram/","icon":"🤬","label":"Create a toxic language detector for Telegram in 4 step"},{"url":"https://n8n.io/blog/automatically-adding-expense-receipts-to-google-sheets-with-telegram-mindee-twilio-and-n8n/","icon":"🧾","label":"Automatically Adding Expense Receipts to Google Sheets with Telegram, Mindee, Twilio, and n8n"},{"url":"https://n8n.io/blog/no-code-ecommerce-workflow-automations/","icon":"store","label":"6 e-commerce workflows to power up your Shopify s"},{"url":"https://n8n.io/blog/world-poetry-day-workflow/","icon":"📜","label":"Celebrating World Poetry Day with a daily poem in Telegram"},{"url":"https://n8n.io/blog/using-automation-to-boost-productivity-in-the-workplace/","icon":"💪","label":"Using Automation to Boost Productivity in the Workplace"},{"url":"https://n8n.io/blog/how-to-set-up-a-ci-cd-pipeline-with-no-code/","icon":"🎡","label":"How to set up a no-code CI/CD pipeline with GitHub and TravisCI"},{"url":"https://n8n.io/blog/creating-scheduled-text-affirmations-with-n8n/","icon":"🤟","label":"Creating scheduled text affirmations with n8n"},{"url":"https://n8n.io/blog/creating-telegram-bots-with-n8n-a-no-code-platform/","icon":"💬","label":"Creating Telegram Bots with n8n, a No-Code Platform"},{"url":"https://n8n.io/blog/aws-workflow-automation/","label":"7 no-code workflow automations for Amazon Web Services"}],"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/app-nodes/n8n-nodes-base.telegram/"}],"credentialDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/credentials/telegram/"}]},"categories":["Communication","HITL"],"nodeVersion":"1.0","codexVersion":"1.0","subcategories":{"HITL":["Human in the Loop"]}}},"group":"[\"output\"]","defaults":{"name":"Telegram"},"iconData":{"type":"file","fileBuffer":"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBmaWxsPSIjZmZmIiBmaWxsLXJ1bGU9ImV2ZW5vZGQiIHN0cm9rZT0iIzAwMCIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIiB2aWV3Qm94PSIwIDAgNjYgNjYiPjx1c2UgeGxpbms6aHJlZj0iI2EiIHg9Ii41IiB5PSIuNSIvPjxzeW1ib2wgaWQ9ImEiIG92ZXJmbG93PSJ2aXNpYmxlIj48ZyBmaWxsLXJ1bGU9Im5vbnplcm8iIHN0cm9rZT0ibm9uZSI+PHBhdGggZmlsbD0iIzM3YWVlMiIgZD0iTTAgMzJjMCAxNy42NzMgMTQuMzI3IDMyIDMyIDMyczMyLTE0LjMyNyAzMi0zMlM0OS42NzMgMCAzMiAwIDAgMTQuMzI3IDAgMzIiLz48cGF0aCBmaWxsPSIjYzhkYWVhIiBkPSJtMjEuNjYxIDM0LjMzOCAzLjc5NyAxMC41MDhzLjQ3NS45ODMuOTgzLjk4MyA4LjA2OC03Ljg2NCA4LjA2OC03Ljg2NGw4LjQwNy0xNi4yMzctMjEuMTE5IDkuODk4eiIvPjxwYXRoIGZpbGw9IiNhOWM2ZDgiIGQ9Im0yNi42OTUgMzcuMDM0LS43MjkgNy43NDZzLS4zMDUgMi4zNzMgMi4wNjggMGw0LjY0NC00LjIwMyIvPjxwYXRoIGQ9Im0yMS43MyAzNC43MTItNy44MDktMi41NDVzLS45MzItLjM3OC0uNjMzLTEuMjM3Yy4wNjItLjE3Ny4xODYtLjMyOC41NTktLjU4OCAxLjczMS0xLjIwNiAzMi4wMjgtMTIuMDk2IDMyLjAyOC0xMi4wOTZzLjg1Ni0uMjg4IDEuMzYxLS4wOTdjLjIzMS4wODguMzc4LjE4Ny41MDMuNTQ4LjA0NS4xMzIuMDcxLjQxMS4wNjguNjg5LS4wMDMuMjAxLS4wMjcuMzg2LS4wNDUuNjc4LS4xODQgMi45NzgtNS43MDYgMjUuMTk4LTUuNzA2IDI1LjE5OHMtLjMzIDEuMy0xLjUxNCAxLjM0NWMtLjQzMi4wMTYtLjk1Ni0uMDcxLTEuNTgyLS42MS0yLjMyMy0xLjk5OC0xMC4zNTItNy4zOTQtMTIuMTI2LTguNThhLjM0LjM0IDAgMCAxLS4xNDYtLjIzOWMtLjAyNS0uMTI1LjEwOC0uMjguMTA4LS4yOHMxMy45OC0xMi40MjcgMTQuMzUyLTEzLjczMWMuMDI5LS4xMDEtLjA3OS0uMTUxLS4yMjYtLjEwNy0uOTI5LjM0Mi0xNy4wMjUgMTAuNTA2LTE4LjgwMSAxMS42MjktLjEwNC4wNjYtLjM5NS4wMjMtLjM5NS4wMjMiLz48L2c+PC9zeW1ib2w+PC9zdmc+"},"displayName":"Telegram","typeVersion":1,"nodeCategories":[{"id":6,"name":"Communication"},{"id":28,"name":"HITL"}]},{"id":76,"icon":"file:hubspot.svg","name":"n8n-nodes-base.hubspot","codex":{"data":{"resources":{"generic":[{"url":"https://n8n.io/blog/how-to-sync-data-between-two-systems/","icon":"🏬","label":"How to synchronize data between two systems (one-way vs. two-way sync"},{"url":"https://n8n.io/blog/how-to-get-started-with-crm-automation-and-no-code-workflow-ideas/","icon":"👥","label":"How to get started with CRM automation (with 3 no-code workflow ideas"},{"url":"https://n8n.io/blog/your-business-doesnt-need-you-to-operate/","icon":" 🖥️","label":"Hey founders! Your business doesn't need you to operate"},{"url":"https://n8n.io/blog/benefits-of-automation-and-n8n-an-interview-with-hubspots-hugh-durkin/","icon":"🎖","label":"Benefits of automation and n8n: An interview with HubSpot's Hugh Durkin"},{"url":"https://n8n.io/blog/how-goomer-automated-their-operations-with-over-200-n8n-workflows/","icon":"🛵","label":"How Goomer automated their operations with over 200 n8n workflows"}],"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/app-nodes/n8n-nodes-base.hubspot/"}],"credentialDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/credentials/hubspot/"}]},"categories":["Sales"],"nodeVersion":"1.0","codexVersion":"1.0"}},"group":"[\"output\"]","defaults":{"name":"HubSpot"},"iconData":{"type":"file","fileBuffer":"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiBmaWxsPSIjZmZmIiBmaWxsLXJ1bGU9ImV2ZW5vZGQiIHN0cm9rZT0iIzAwMCIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIiB2aWV3Qm94PSIwIDAgNjIuODgzIDY5Ljg4MyI+PHVzZSB4bGluazpocmVmPSIjYSIgeD0iMi40NDIiIHk9IjIuNDQyIi8+PHN5bWJvbCBpZD0iYSIgb3ZlcmZsb3c9InZpc2libGUiPjxwYXRoIGZpbGw9IiNmODc2MWYiIGZpbGwtcnVsZT0ibm9uemVybyIgc3Ryb2tlPSJub25lIiBkPSJNNTUuNTA0IDMwLjQwMWExNi4yNiAxNi4yNiAwIDAgMC01LjkwNC01Ljg2NGMtMS44NjUtMS4wODQtMy43OTQtMS43NzMtNS45NzItMi4wN3YtNy43OThhNS43MSA1LjcxIDAgMCAwIDMuNTI1LTUuMzU3IDUuODYgNS44NiAwIDAgMC01Ljg1OS01Ljg4OSA1LjkxIDUuOTEgMCAwIDAtNS45MDggNS44ODljMCAyLjM5MyAxLjI3IDQuNDM0IDMuNDUyIDUuMzU3djcuNzU0YTE3IDE3IDAgMCAwLTUuMTk1IDEuNjMxTDEyLjc2OSA4LjI0N2MuMTQ2LS41NTIuMjczLTEuMTIzLjI3My0xLjcyNEE2LjUyIDYuNTIgMCAwIDAgNi41MTkgMCA2LjUyIDYuNTIgMCAwIDAgMCA2LjUyNGE2LjUyMyA2LjUyMyAwIDAgMCA2LjUyNCA2LjUyNCA2LjQ3IDYuNDcgMCAwIDAgMy4zNS0uOTUybDEuMzY3IDEuMDM1IDE4LjcyNiAxMy41MDFjLS45OTEuOTA4LTEuOTE0IDEuOTQzLTIuNjUxIDMuMTA1LTEuNDk0IDIuMzY4LTIuNDA3IDQuOTcxLTIuNDA3IDcuODEzdi41ODZhMTYuNCAxNi40IDAgMCAwIDEuMDI1IDUuNjQ1QzI2LjUgNDUuMzI0IDI3LjMzIDQ2LjczIDI4LjM2MSA0OGwtNi4yMjEgNi4yMzVhNS4wMSA1LjAxIDAgMCAwLTUuMjk4IDEuMTYyYy0uOTQ3Ljk0Mi0xLjQ4IDIuMjI3LTEuNDc1IDMuNTY1cy41MjcgMi42MTIgMS40NzkgMy41NjQgMi4yMjcgMS40OCAzLjU2NSAxLjQ4YTUgNSAwIDAgMCAzLjU2NS0xLjQ4IDUuMDUgNS4wNSAwIDAgMCAxLjQ3NS0zLjU2NCA1IDUgMCAwIDAtLjIzNC0xLjUxNGw2LjQyNi02LjQyNmExNiAxNiAwIDAgMCAyLjg1NiAxLjU2MyAxNi43IDE2LjcgMCAwIDAgNi42ODUgMS40MDZoLjQzOWExNS43NiAxNS43NiAwIDAgMCA3LjYyNy0xLjkyOSAxNS43NyAxNS43NyAwIDAgMCA1Ljk3Ny01LjYzYzEuNDk5LTIuMzkzIDIuMzE5LTUuMDQ0IDIuMzE5LTcuOTU5di0uMTQ2YzAtMi44NjYtLjY2NC01LjUwOC0yLjA1MS03Ljkzem0tNy44NDcgMTMuNDg3Yy0xLjc0MyAxLjkzOC0zLjc1IDMuMTM1LTYuMDE2IDMuMTM1aC0uNDNjLTEuMjk0IDAtMi41NjQtLjM1Ni0zLjc5OS0xLjAxMWE4LjggOC44IDAgMCAxLTMuMzMtMy4wMzJjLS44OTgtMS4yNy0xLjM4Ny0yLjY1Ni0xLjM4Ny00LjEyNnYtLjQzOWMwLTEuNDQ1LjI3OC0yLjgxNy45NzctNC4xMTEuNzQ3LTEuNDY1IDEuNzU4LTIuNTE1IDMuMTAxLTMuMzg5YTcuNiA3LjYgMCAwIDEgNC4yOTctMS4yOTRoLjE0N2MxLjQxNiAwIDIuNzY5LjI3OCA0LjAzOC45MjhhOC41NiA4LjU2IDAgMCAxIDMuMTc0IDIuODg2IDkuMiA5LjIgMCAwIDEgMS40MjEgNC4wNTNsLjAzNC45MTNjMCAxLjk4Ny0uNzYyIDMuODI4LTIuMjggNS40OTh6Ii8+PC9zeW1ib2w+PC9zdmc+"},"displayName":"HubSpot","typeVersion":2,"nodeCategories":[{"id":2,"name":"Sales"}]},{"id":111,"icon":"fa:sign-in-alt","name":"n8n-nodes-base.executeWorkflow","codex":{"data":{"alias":["n8n","call","sub","workflow","sub-workflow","subworkflow"],"details":"The Execute Workflow node can be used when you want your workflow to treat another workflow as a step in your flow. It allows you to modularize your workflows and have a single source of truth for series of actions you perform often. ","resources":{"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-base.executeworkflow/"}]},"categories":["Core Nodes"],"nodeVersion":"1.0","codexVersion":"1.0","subcategories":{"Core Nodes":["Helpers","Flow"]}}},"group":"[\"transform\"]","defaults":{"name":"Execute Workflow","color":"#ff6d5a"},"iconData":{"icon":"sign-in-alt","type":"icon"},"displayName":"Execute Sub-workflow","typeVersion":1,"nodeCategories":[{"id":9,"name":"Core Nodes"}]},{"id":112,"icon":"fa:map-signs","name":"n8n-nodes-base.switch","codex":{"data":{"alias":["Router","If","Path","Filter","Condition","Logic","Branch","Case"],"resources":{"generic":[{"url":"https://n8n.io/blog/2021-the-year-to-automate-the-new-you-with-n8n/","icon":"☀️","label":"2021: The Year to Automate the New You with n8n"},{"url":"https://n8n.io/blog/how-to-get-started-with-crm-automation-and-no-code-workflow-ideas/","icon":"👥","label":"How to get started with CRM automation (with 3 no-code workflow ideas"},{"url":"https://n8n.io/blog/build-your-own-virtual-assistant-with-n8n-a-step-by-step-guide/","icon":"👦","label":"Build your own virtual assistant with n8n: A step by step guide"},{"url":"https://n8n.io/blog/automation-for-maintainers-of-open-source-projects/","icon":"🏷️","label":"How to automatically manage contributions to open-source projects"}],"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-base.switch/"}]},"categories":["Core Nodes"],"nodeVersion":"1.0","codexVersion":"1.0","subcategories":{"Core Nodes":["Flow"]}}},"group":"[\"transform\"]","defaults":{"name":"Switch","color":"#506000"},"iconData":{"icon":"map-signs","type":"icon"},"displayName":"Switch","typeVersion":3,"nodeCategories":[{"id":9,"name":"Core Nodes"}]},{"id":514,"icon":"fa:pause-circle","name":"n8n-nodes-base.wait","codex":{"data":{"alias":["pause","sleep","delay","timeout"],"resources":{"generic":[{"url":"https://n8n.io/blog/how-to-get-started-with-crm-automation-and-no-code-workflow-ideas/","icon":"👥","label":"How to get started with CRM automation (with 3 no-code workflow ideas"},{"url":"https://n8n.io/blog/aws-workflow-automation/","label":"7 no-code workflow automations for Amazon Web Services"}],"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-base.wait/"}]},"categories":["Core Nodes"],"nodeVersion":"1.0","codexVersion":"1.0","subcategories":{"Core Nodes":["Helpers","Flow"]}}},"group":"[\"organization\"]","defaults":{"name":"Wait","color":"#804050"},"iconData":{"icon":"pause-circle","type":"icon"},"displayName":"Wait","typeVersion":1,"nodeCategories":[{"id":9,"name":"Core Nodes"}]},{"id":528,"icon":"fa:exclamation-triangle","name":"n8n-nodes-base.stopAndError","codex":{"data":{"alias":["Throw error","Error","Exception"],"resources":{"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-base.stopanderror/"}]},"categories":["Core Nodes","Utility"],"nodeVersion":"1.0","codexVersion":"1.0","subcategories":{"Core Nodes":["Flow"]}}},"group":"[\"input\"]","defaults":{"name":"Stop and Error","color":"#ff0000"},"iconData":{"icon":"exclamation-triangle","type":"icon"},"displayName":"Stop and Error","typeVersion":1,"nodeCategories":[{"id":7,"name":"Utility"},{"id":9,"name":"Core Nodes"}]},{"id":565,"icon":"fa:sticky-note","name":"n8n-nodes-base.stickyNote","codex":{"data":{"alias":["Comments","Notes","Sticky"],"categories":["Core Nodes"],"nodeVersion":"1.0","codexVersion":"1.0","subcategories":{"Core Nodes":["Helpers"]}}},"group":"[\"input\"]","defaults":{"name":"Sticky Note","color":"#FFD233"},"iconData":{"icon":"sticky-note","type":"icon"},"displayName":"Sticky Note","typeVersion":1,"nodeCategories":[{"id":9,"name":"Core Nodes"}]},{"id":834,"icon":"file:code.svg","name":"n8n-nodes-base.code","codex":{"data":{"alias":["cpde","Javascript","JS","Python","Script","Custom Code","Function"],"details":"The Code node allows you to execute JavaScript in your workflow.","resources":{"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-base.code/"}]},"categories":["Development","Core Nodes"],"nodeVersion":"1.0","codexVersion":"1.0","subcategories":{"Core Nodes":["Helpers","Data Transformation"]}}},"group":"[\"transform\"]","defaults":{"name":"Code"},"iconData":{"type":"file","fileBuffer":"data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTEyIiBoZWlnaHQ9IjUxMiIgdmlld0JveD0iMCAwIDUxMiA1MTIiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CjxnIGNsaXAtcGF0aD0idXJsKCNjbGlwMF8xMTcxXzQ0MSkiPgo8cGF0aCBkPSJNMTcwLjI4MyA0OEgxOTYuNUMyMDMuMTI3IDQ4IDIwOC41IDQyLjYyNzQgMjA4LjUgMzZWMTJDMjA4LjUgNS4zNzI1OCAyMDMuMTI3IDAgMTk2LjUgMEgxNzAuMjgzQzEyNi4xIDAgOTAuMjgzIDM1LjgxNzIgOTAuMjgzIDgwVjE3NkM5MC4yODMgMjA2LjkyOCA2NS4yMTA5IDIzMiAzNC4yODMgMjMySDIzQzE2LjM3MjYgMjMyIDExIDIzNy4zNzIgMTEgMjQ0VjI2OEMxMSAyNzQuNjI3IDE2LjM3MjQgMjgwIDIyLjk5OTYgMjgwTDM0LjI4MyAyODBDNjUuMjEwOSAyODAgOTAuMjgzIDMwNS4wNzIgOTAuMjgzIDMzNlY0NDBDOTAuMjgzIDQ3OS43NjQgMTIyLjUxOCA1MTIgMTYyLjI4MyA1MTJIMTk2LjVDMjAzLjEyNyA1MTIgMjA4LjUgNTA2LjYyNyAyMDguNSA1MDBWNDc2QzIwOC41IDQ2OS4zNzMgMjAzLjEyNyA0NjQgMTk2LjUgNDY0SDE2Mi4yODNDMTQ5LjAyOCA0NjQgMTM4LjI4MyA0NTMuMjU1IDEzOC4yODMgNDQwVjMzNkMxMzguMjgzIDMwOS4wMjIgMTI4LjAxMSAyODQuNDQzIDExMS4xNjQgMjY1Ljk2MUMxMDYuMTA5IDI2MC40MTYgMTA2LjEwOSAyNTEuNTg0IDExMS4xNjQgMjQ2LjAzOUMxMjguMDExIDIyNy41NTcgMTM4LjI4MyAyMDIuOTc4IDEzOC4yODMgMTc2VjgwQzEzOC4yODMgNjIuMzI2OSAxNTIuNjEgNDggMTcwLjI4MyA0OFoiIGZpbGw9IiNGRjk5MjIiLz4KPHBhdGggZD0iTTMwNSAzNkMzMDUgNDIuNjI3NCAzMTAuMzczIDQ4IDMxNyA0OEgzNDIuOTc5QzM2MC42NTIgNDggMzc0Ljk3OCA2Mi4zMjY5IDM3NC45NzggODBWMTc2QzM3NC45NzggMjAyLjk3OCAzODUuMjUxIDIyNy41NTcgNDAyLjA5OCAyNDYuMDM5QzQwNy4xNTMgMjUxLjU4NCA0MDcuMTUzIDI2MC40MTYgNDAyLjA5OCAyNjUuOTYxQzM4NS4yNTEgMjg0LjQ0MyAzNzQuOTc4IDMwOS4wMjIgMzc0Ljk3OCAzMzZWNDMyQzM3NC45NzggNDQ5LjY3MyAzNjAuNjUyIDQ2NCAzNDIuOTc5IDQ2NEgzMTdDMzEwLjM3MyA0NjQgMzA1IDQ2OS4zNzMgMzA1IDQ3NlY1MDBDMzA1IDUwNi42MjcgMzEwLjM3MyA1MTIgMzE3IDUxMkgzNDIuOTc5QzM4Ny4xNjEgNTEyIDQyMi45NzggNDc2LjE4MyA0MjIuOTc4IDQzMlYzMzZDNDIyLjk3OCAzMDUuMDcyIDQ0OC4wNTEgMjgwIDQ3OC45NzkgMjgwSDQ5MEM0OTYuNjI3IDI4MCA1MDIgMjc0LjYyOCA1MDIgMjY4VjI0NEM1MDIgMjM3LjM3MyA0OTYuNjI4IDIzMiA0OTAgMjMyTDQ3OC45NzkgMjMyQzQ0OC4wNTEgMjMyIDQyMi45NzggMjA2LjkyOCA0MjIuOTc4IDE3NlY4MEM0MjIuOTc4IDM1LjgxNzIgMzg3LjE2MSAwIDM0Mi45NzkgMEgzMTdDMzEwLjM3MyAwIDMwNSA1LjM3MjU4IDMwNSAxMlYzNloiIGZpbGw9IiNGRjk5MjIiLz4KPC9nPgo8ZGVmcz4KPGNsaXBQYXRoIGlkPSJjbGlwMF8xMTcxXzQ0MSI+CjxyZWN0IHdpZHRoPSI1MTIiIGhlaWdodD0iNTEyIiBmaWxsPSJ3aGl0ZSIvPgo8L2NsaXBQYXRoPgo8L2RlZnM+Cjwvc3ZnPgo="},"displayName":"Code","typeVersion":2,"nodeCategories":[{"id":5,"name":"Development"},{"id":9,"name":"Core Nodes"}]},{"id":837,"icon":"fa:sign-out-alt","name":"n8n-nodes-base.executeWorkflowTrigger","codex":{"data":{"resources":{"generic":[],"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-base.executeworkflowtrigger/"}]},"categories":["Core Nodes"],"nodeVersion":"1.0","codexVersion":"1.0","subcategories":{"Core Nodes":["Helpers"]}}},"group":"[\"trigger\"]","defaults":{"name":"When Executed by Another Workflow","color":"#ff6d5a"},"iconData":{"icon":"sign-out-alt","type":"icon"},"displayName":"Execute Workflow Trigger","typeVersion":1,"nodeCategories":[{"id":9,"name":"Core Nodes"}]},{"id":838,"icon":"fa:mouse-pointer","name":"n8n-nodes-base.manualTrigger","codex":{"data":{"resources":{"generic":[],"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-base.manualworkflowtrigger/"}]},"categories":["Core Nodes"],"nodeVersion":"1.0","codexVersion":"1.0"}},"group":"[\"trigger\"]","defaults":{"name":"When clicking ‘Execute workflow’","color":"#909298"},"iconData":{"icon":"mouse-pointer","type":"icon"},"displayName":"Manual Trigger","typeVersion":1,"nodeCategories":[{"id":9,"name":"Core Nodes"}]},{"id":839,"icon":"fa:clock","name":"n8n-nodes-base.scheduleTrigger","codex":{"data":{"alias":["Time","Scheduler","Polling","Cron","Interval"],"resources":{"generic":[],"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-base.scheduletrigger/"}]},"categories":["Core Nodes"],"nodeVersion":"1.0","codexVersion":"1.0"}},"group":"[\"trigger\",\"schedule\"]","defaults":{"name":"Schedule Trigger","color":"#31C49F"},"iconData":{"icon":"clock","type":"icon"},"displayName":"Schedule Trigger","typeVersion":1,"nodeCategories":[{"id":9,"name":"Core Nodes"}]},{"id":844,"icon":"fa:filter","name":"n8n-nodes-base.filter","codex":{"data":{"alias":["Router","Filter","Condition","Logic","Boolean","Branch"],"details":"The Filter node can be used to filter items based on a condition. If the condition is met, the item will be passed on to the next node. If the condition is not met, the item will be omitted. Conditions can be combined together by AND(meet all conditions), or OR(meet at least one condition).","resources":{"generic":[],"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-base.filter/"}]},"categories":["Core Nodes"],"nodeVersion":"1.0","codexVersion":"1.0","subcategories":{"Core Nodes":["Flow","Data Transformation"]}}},"group":"[\"transform\"]","defaults":{"name":"Filter","color":"#229eff"},"iconData":{"icon":"filter","type":"icon"},"displayName":"Filter","typeVersion":2,"nodeCategories":[{"id":9,"name":"Core Nodes"}]},{"id":1239,"icon":"file:splitOut.svg","name":"n8n-nodes-base.splitOut","codex":{"data":{"alias":["Split","Nested","Transform","Array","List","Item"],"details":"","resources":{"generic":[],"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-base.splitout/"}]},"categories":["Core Nodes"],"nodeVersion":"1.0","codexVersion":"1.0","subcategories":{"Core Nodes":["Data Transformation"]}}},"group":"[\"transform\"]","defaults":{"name":"Split Out"},"iconData":{"type":"file","fileBuffer":"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSI1MTIiIGhlaWdodD0iNTEyIiBmaWxsPSJub25lIj48ZyBmaWxsPSIjOUI2REQ1IiBjbGlwLXBhdGg9InVybCgjYSkiPjxwYXRoIGZpbGwtcnVsZT0iZXZlbm9kZCIgZD0iTTQ4MCAxNDhjMC02LjYyNy01LjM3My0xMi0xMi0xMkgzMjJjLTYuNjI3IDAtMTIgNS4zNzMtMTIgMTJ2MjRjMCA2LjYyNyA1LjM3MyAxMiAxMiAxMmgxNDZjNi42MjcgMCAxMi01LjM3MyAxMi0xMnptMCA5NmMwLTYuNjI3LTUuMzczLTEyLTEyLTEySDMyMmMtNi42MjcgMC0xMiA1LjM3My0xMiAxMnYyNGMwIDYuNjI3IDUuMzczIDEyIDEyIDEyaDE0NmM2LjYyNyAwIDEyLTUuMzczIDEyLTEyem0wIDk2YzAtNi42MjctNS4zNzMtMTItMTItMTJIMzIyYy02LjYyNyAwLTEyIDUuMzczLTEyIDEydjI0YzAgNi42MjcgNS4zNzMgMTIgMTIgMTJoMTQ2YzYuNjI3IDAgMTItNS4zNzMgMTItMTJ6IiBjbGlwLXJ1bGU9ImV2ZW5vZGQiLz48cGF0aCBkPSJNNDM4IDc2YzAgNi42MjctNS4zNzMgMTItMTIgMTJIMzA5Ljc4M2MtMTcuNjczIDAtMzIgMTQuMzI3LTMyIDMydjU2YzAgMjYuOTc4LTEwLjI3MiA1MS41NTctMjcuMTE5IDcwLjAzOS01LjA1NSA1LjU0NS01LjA1NSAxNC4zNzcgMCAxOS45MjIgMTYuODQ3IDE4LjQ4MiAyNy4xMTkgNDMuMDYxIDI3LjExOSA3MC4wMzl2NTZjMCAxNy42NzMgMTQuMzI3IDMyIDMyIDMySDQyNmM2LjYyNyAwIDEyIDUuMzczIDEyIDEydjI0YzAgNi42MjctNS4zNzMgMTItMTIgMTJIMzA5Ljc4M2MtNDQuMTgzIDAtODAtMzUuODE3LTgwLTgwdi01NmMwLTMwLjkyOC0yNS4wNzItNTYtNTYtNTZhNS43ODMgNS43ODMgMCAwIDEtNS43ODMtNS43ODN2LTM2LjQzNGE1Ljc4MyA1Ljc4MyAwIDAgMSA1Ljc4My01Ljc4M2MzMC45MjggMCA1Ni0yNS4wNzIgNTYtNTZ2LTU2YzAtNDQuMTgzIDM1LjgxNy04MCA4MC04MEg0MjZjNi42MjcgMCAxMiA1LjM3MyAxMiAxMnoiLz48cGF0aCBmaWxsLXJ1bGU9ImV2ZW5vZGQiIGQ9Ik0xMzYgMjQ0YzAtNi42MjctNS4zNzMtMTItMTItMTJIMTJjLTYuNjI3IDAtMTIgNS4zNzMtMTIgMTJ2MjRjMCA2LjYyNyA1LjM3MyAxMiAxMiAxMmgxMTJjNi42MjcgMCAxMi01LjM3MyAxMi0xMnoiIGNsaXAtcnVsZT0iZXZlbm9kZCIvPjwvZz48ZGVmcz48Y2xpcFBhdGggaWQ9ImEiPjxwYXRoIGZpbGw9IiNmZmYiIGQ9Ik01MTIgMEgwdjUxMmg1MTJ6Ii8+PC9jbGlwUGF0aD48L2RlZnM+PC9zdmc+"},"displayName":"Split Out","typeVersion":1,"nodeCategories":[{"id":9,"name":"Core Nodes"}]},{"id":1315,"icon":"fa:table","name":"n8n-nodes-base.dataTable","codex":{"data":{"alias":["data","table","knowledge","data table","table","sheet","database","data base","mysql","postgres","postgresql","airtable","supabase","noco","notion"],"details":"Data table","resources":{"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-base.datatable/"}]},"categories":["Core Nodes","Development"],"nodeVersion":"1.0","codexVersion":"1.0","subcategories":{"Core Nodes":["Helpers"]}}},"group":"[\"input\",\"transform\"]","defaults":{"name":"Data table"},"iconData":{"icon":"table","type":"icon"},"displayName":"Data table","typeVersion":1,"nodeCategories":[{"id":5,"name":"Development"},{"id":9,"name":"Core Nodes"}]}],"categories":[{"id":5,"name":"Engineering"}],"image":[]}}