Undrill Auth icon

Undrill Auth

Undrill Authentication node for protecting n8n workflows

Overview

This node, named "Undrill Auth," is designed to validate a license key for an n8n workflow using a client ID and the workflow's unique identifier. It ensures that the workflow is authorized by verifying a cryptographic hash against a stored license key. This validation helps protect workflows from unauthorized use.

Common scenarios include:

  • Ensuring only licensed users can execute specific workflows.
  • Integrating license checks into automation pipelines to enforce compliance.
  • Protecting proprietary or sensitive workflows by requiring valid licenses.

For example, before running a critical data processing workflow, this node can verify that the user holds a valid license, preventing unauthorized execution.

Properties

Name Meaning
Client ID Your Undrill client ID (string)

The node supports one operation: Validate License, which checks if the provided client ID and current workflow ID match a valid license.

Output

The node outputs a JSON object with the following structure upon successful validation:

{
  "valid": true,
  "message": "License validated successfully",
  "clientId": "<provided client ID>",
  "workflowId": "<current workflow ID>"
}

If validation fails and the node is set to continue on failure, it outputs an error JSON object:

{
  "error": "<error message>"
}

No binary data output is produced by this node.

Dependencies

  • Requires an API authentication token credential (referred generically as an API key credential) containing a licenseKey value.
  • Uses Node.js built-in crypto module for SHA-256 hashing.
  • The node depends on the workflow's unique identifier (workflow.id) available at runtime.

Troubleshooting

  • Invalid license key error: If the license key does not match the expected hash, the node throws an error stating "Invalid license key. Please contact Undrill support." Ensure that the client ID and license key are correct and correspond to the current workflow ID.
  • Credential issues: Missing or incorrect API authentication credentials will cause failures. Verify that the required API key credential is configured properly.
  • Continue on Fail behavior: If enabled, errors during validation will be returned as JSON error messages instead of stopping the workflow execution.

Links and References

Discussion