npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@cdmx/n8n-nodes-schema-validator

v0.1.15

Published

AJV JSON Schema validation node for n8n workflows with support for multiple schemas, formats, and enhanced error messages

Readme

n8n-nodes-schema-validator

npm version License: MIT

Advanced JSON Schema validation node for n8n workflows. Validate your data against JSON Schema standards with support for multiple schemas, format validation, and custom error messages.

Features

  • Single & Multiple Schema Validation - Validate against one or multiple schemas per item
  • 📧 Format Validation - Built-in support for email, URI, UUID, date, date-time, IPv4, IPv6, and more via ajv-formats
  • 💬 Custom Error Messages - Define custom error messages in your schemas via ajv-errors
  • 🔀 Dual Output - Valid items go to one output, invalid items go to another
  • 🎯 Data Path Extraction - Validate specific parts of your data using JSON paths
  • ⚙️ Configurable Options - Control strict mode, all errors collection, and more

Installation

Community Nodes Installation

  1. Go to Settings > Community Nodes in your n8n instance
  2. Select Install
  3. Enter n8n-nodes-schema-validator in the search field
  4. Click Install

Manual Installation

For self-hosted n8n instances:

npm install n8n-nodes-schema-validator

Then restart your n8n instance.

Usage

Single Schema Mode

Validate all incoming items against a single JSON schema:

{
  "type": "object",
  "properties": {
    "name": { "type": "string", "minLength": 1 },
    "email": { "type": "string", "format": "email" },
    "age": { "type": "number", "minimum": 0 }
  },
  "required": ["name", "email"]
}

Multiple Schemas Mode

Validate different parts of your data against different schemas:

  1. Set Validation Mode to "Multiple Schemas"
  2. Add multiple schema definitions
  3. For each schema, specify:
    • Schema Name: A descriptive name for error messages
    • JSON Schema: The validation schema
    • Data Path: Optional path to extract data (e.g., user.profile or items[0])

Match Modes

When using multiple schemas:

  • All Must Pass: Item is valid only if ALL schemas pass
  • Any Must Pass: Item is valid if ANY schema passes

Supported Formats

Thanks to ajv-formats, the following formats are supported:

  • email - Email addresses
  • uri / url - URIs and URLs
  • uuid - UUIDs
  • date - ISO 8601 dates (YYYY-MM-DD)
  • time - ISO 8601 times
  • date-time - ISO 8601 date-times
  • ipv4 / ipv6 - IP addresses
  • hostname - Hostnames
  • regex - Regular expressions
  • And more...

Custom Error Messages

Use ajv-errors syntax to define custom messages:

{
  "type": "object",
  "properties": {
    "email": {
      "type": "string",
      "format": "email",
      "errorMessage": {
        "format": "Please provide a valid email address"
      }
    }
  },
  "required": ["email"],
  "errorMessage": {
    "required": {
      "email": "Email address is required"
    }
  }
}

Output

Valid Items (Output 1)

Items that pass validation are output unchanged.

Invalid Items (Output 2)

Items that fail validation include:

  • _validationMessage: Human-readable error summary
  • _validationErrors (single mode) or _validationResults (multiple mode): Detailed error information

Options

| Option | Default | Description | |--------|---------|-------------| | Enable Formats | true | Enable ajv-formats for format validation | | Enable Custom Errors | true | Enable ajv-errors for custom messages | | Strict Mode | true | Enable strict schema validation | | All Errors | true | Collect all errors vs. stop at first | | Include Error Details | true | Include detailed errors in output |

Development

# Install dependencies
pnpm install

# Build the project
pnpm run build

# Run tests
pnpm test

# Run tests with coverage
pnpm test:coverage

# Lint code
pnpm run lint

Resources

License

MIT

Contributing

Contributions are welcome! Please feel free to submit a Pull Request.