n8n can send leads from any source it handles into GuardenerAI through the public API. GuardenerAI has no n8n node, so this is a connection you build yourself with the HTTP Request node: the workflow looks the person up by email, then an If node creates a new lead or updates the one it found.
Not a native integration. An n8n workflow sends lead details to your workspace’s API. Leads land in GuardenerAI. Nothing flows back to n8n on its own.
https://YOUR-ORG.guardenerai.com.In an HTTP Request node set Authentication to Generic Credential Type, then Header Auth. Create the credential with Name X-Api-Key and your key as the Value. Every GuardenerAI request in the workflow can reuse it.
Use the trigger for the app where your leads arrive, or a Webhook node if another system can post to n8n.
Add an HTTP Request node, method GET, with the Header Auth credential. Lower-case the email in the expression, because the match is case-sensitive.
https://YOUR-ORG.guardenerai.com/api/leads?filter=email:equals:{{ $json.email.toLowerCase() }} Add an If node that checks whether totalElements equals 0. The true branch is a new lead. The false branch is a lead you already have, and content[0].id is its id.
On the true branch add an HTTP Request node, method POST, to /api/leads, with Send Body on and JSON as the body. firstName, lastName and email are required. On the false branch send a PUT to /api/leads/{id} with every field you want to keep, because a PUT replaces the whole record. Then publish the workflow.
{
"firstName": "{{ $('Webhook').item.json.first_name }}",
"lastName": "{{ $('Webhook').item.json.last_name }}",
"email": "{{ $('Webhook').item.json.email.toLowerCase() }}",
"message": "{{ $('Webhook').item.json.message }}",
"sourceMedium": "n8n",
"sourceCampaign": "contact form"
} Retry-After: 1, so wait a second and retry.PUT replaces the whole record. Send every field you want to keep, not only the one that changed.duplicate_blocked with the matching records. Update the match instead of forcing a second copy.Checked against n8n’s own documentation: HTTP Request node, HTTP Request credentials, Handling rate limits, Webhook node, If node. Their plans and features change, so confirm the current details there.
We use analytics cookies to see which pages help and which don't. No advertising cookies. How we use them