⚡ Public holiday lookup with Nager.Date API via webhook

590 views · ⚡ Personal Productivity

Description

This n8n template empowers you to instantly fetch a list of public holidays for any given year and country using the Nager.Date API. This is incredibly useful for scheduling, planning, or integrating holiday data into various business and personal automation workflows.


🔧 How it works


👤 Who is it for?

This workflow is ideal for:


📑 Data Structure

When you trigger the webhook, send a POST request with a JSON body structured as follows:

{
  "year": 2025,
  "countryCode": "PH" // Example: "US", "DE", "GB", etc.
}

You can find a comprehensive list of supported country codes on the Nager.Date API documentation: https://www.nager.at/Country

The workflow will return a JSON array, where each element is a holiday object, like this example for a single holiday:

[
  {
    "date": "2025-01-01",
    "localName": "New Year's Day",
    "name": "New Year's Day",
    "countryCode": "PH",
    "fixed": true,
    "global": true,
    "counties": null,
    "launchYear": null,
    "types": [
      "Public"
    ]
  }
  // ... more holiday objects
]

⚙️ Setup Instructions


📝 Tips

This workflow is a foundation for many powerful automations:

🔗 Nodes Used

HTTP Request, Webhook

📥 Import

Download workflow.json and import into n8n: Workflow menu → Import from File

📖 Importing guide · 🔑 Credential setup