Skip to main content

Enrich IP addresses with country attribution using IPinfo and Slack alerts

Workflow preview

Workflow preview
100%
Enrich IP addresses with country attribution using IPinfo and Slack alerts preview
Open on n8n.io

1. Workflow Overview

Template Description IP Enrichment & Country Attribution is a lightweight cybersecurity automation that enriches IP addresses with geographic and network intelligence. It validates incoming IPs ...

Best for

  • SecOps automation workflows
  • advanced n8n builders looking for reusable templates

Tools used

n8n-nodes-base.webhook, n8n-nodes-base.code, n8n-nodes-base.if, n8n-nodes-base.respondtowebhook, n8n-nodes-base.httprequest, n8n-nodes-base.slack, n8n-nodes-base.stickynote

Source and attribution

This workflow is cataloged by N8N Workflows and links back to its original n8n.io source page by Edson Encinas.

Original n8n.io source

1.1 Workflow description

Title
Enrich IP addresses with country attribution using IPinfo and Slack alerts
Workflow name
Enrich IP addresses with country attribution using IPinfo and Slack alerts

đź§© Template Description

IP Enrichment & Country Attribution is a lightweight cybersecurity automation that enriches IP addresses with geographic and network intelligence. It validates incoming IPs, filters out private or invalid addresses, and enriches public IPs using an open-source IP enrichment service.

🔄 How It Works

  1. Receives an IP address via webhook (API or Slack).
  2. Validates the IP format and rejects invalid input.
  3. Checks for private or internal IP ranges.
  4. Ignores private IPs with a clear response.
  5. Enriches public IPs using an open-source IP intelligence service.
  6. Normalizes country, ISP, and ASN data and applies a severity label.
  7. Slack notifications are sent for enriched public IPs.
  8. Returns a structured JSON response.

⚙️ Setup Steps

  1. Import & Activate Workflow
  • Import the JSON template into n8n
  • Actvate the workflow
  1. Set Up Webhook
  • Copy the webhook URL
  • Send a POST request with the IP in the body, e.g.: { "text" : "8.8.8.8" }
  • Using curl: curl -X POST https://YOUR_N8N_WEBHOOK_URL \ -H "Content-Type: application/json" \ -d '{"text":"8.8.8.8"}'
  1. Configure Slack (Slack Alert)
  • Create or select Slack credentials in n8n
  • Make sure the bot is in your target channel
  • Update the Slack node with correct channel.
  1. Slack Slash Command Setup (Optional)
  • Enable Slash Commands and create new command (for example /ip-enrich).
  • Set the Request URL to your n8n webhook endpoint.
  • Choose POST as the request method.
  • Install the app to your workspace. Usage example: /ip-enrich 8.8.8.8

🎛️ Customization Options

  • Enrichment source: Replace or extend the IP intelligence API with additional providers (for example reputation or abuse scoring).
  • Slack formatting: Customize the Slack message text, emojis, or use threads for better alert grouping.
  • Input sources: Reuse the webhook for other integrations such as SIEM alerts or security tools.

1.2 Logical Blocks

This catalog entry is organized from the workflow JSON. The node-level section below shows the executable blocks available for review before importing the template.

2. Block-by-Block Analysis

Block 1 - Weebhook - Receive IP Input

Type / Role
n8n-nodes-base.webhook - webhook
Config choices
Version 2.1

Block 2 - Validate IP Address

Type / Role
n8n-nodes-base.code - code
Config choices
Version 2

Block 3 - If IP is Valid

Type / Role
n8n-nodes-base.if - if
Config choices
Version 2.3

Block 4 - Respond Invalid IP Address

Type / Role
n8n-nodes-base.respondToWebhook - respondToWebhook
Config choices
Version 1.5

Block 5 - Check Private / Internal IP

Type / Role
n8n-nodes-base.code - code
Config choices
Version 2

Block 6 - If IP is Private

Type / Role
n8n-nodes-base.if - if
Config choices
Version 2.3

Block 7 - Respond Private IP Ignored

Type / Role
n8n-nodes-base.respondToWebhook - respondToWebhook
Config choices
Version 1.5

Block 8 - Enrich IP (Geo & ASN Lookup)

Type / Role
n8n-nodes-base.httpRequest - httpRequest
Config choices
Version 4.3

Block 9 - Normalize Enrichment

Type / Role
n8n-nodes-base.code - code
Config choices
Version 2

Block 10 - Slack Alert: IP Enrichment Result

Type / Role
n8n-nodes-base.slack - slack
Config choices
Version 2.4

Block 11 - Respond IP Enrichment Result

Type / Role
n8n-nodes-base.respondToWebhook - respondToWebhook
Config choices
Version 1.5

Block 12 - Sticky Note

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 13 - Sticky Note1

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 14 - Sticky Note2

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 15 - Sticky Note3

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 16 - Sticky Note4

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 17 - Sticky Note5

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

3. Summary Table

Workflow Enrich IP addresses with country attribution using IPinfo and Slack alerts
Complexity advanced
Nodes 17
Categories SecOps
Author Edson Encinas
Published 06 Feb 2026

4. Reproducing the Workflow from Scratch

  1. 1. Download the workflow JSON

    Use the JSON export at /data/workflows/13239/13239.json as the source template for this automation.

  2. 2. Import the template into n8n

    Open n8n, import the downloaded JSON, and review each node before activating the workflow.

  3. 3. Configure credentials and variables

    Replace placeholder credentials, API keys, webhook URLs, account IDs, and environment-specific values with your own settings.

  4. 4. Test with sample data

    Run the workflow manually or in a staging workspace, inspect node output, and confirm downstream systems receive the expected data.

  5. 5. Activate and monitor

    Enable the workflow only after testing, then monitor executions, errors, and rate limits during the first production runs.

5. General Notes & Resources

Review imported nodes carefully before activation. This catalog entry is intended to help you inspect the workflow structure, understand required services, and find related templates faster.

Node names, credentials, schedules, webhook paths, and external service limits may need adjustment for your workspace.

Frequently asked questions

What does Enrich IP addresses with country attribution using IPinfo and Slack alerts do?

Template Description IP Enrichment & Country Attribution is a lightweight cybersecurity automation that enriches IP addresses with geographic and network intelligence. It validates incoming IPs ...

What do I need before importing this workflow?

Review the workflow JSON, configure any required credentials in n8n, and test the automation in a safe workspace before using it in production.

Can I customize this workflow?

Yes. Use the block-by-block analysis and the downloadable JSON to inspect each node, then adjust credentials, prompts, schedules, filters, or destinations for your SecOps use case.