This CLI tool streamlines the conversion of n8n workflow JSON into skills compatible with OpenClaw. It leverages language model (LLM) technology for efficient transpilation, providing a command-line interface alongside an optional web UI. Perfect for developers looking to enhance their workflow integration.
n8n-to-claw is a robust Command Line Interface (CLI) tool designed to streamline the process of converting n8n workflow JSON into OpenClaw-compatible skills. Transform n8n workflows into functional OpenClaw skills effortlessly through the command line or via an optional web UI.
Key Features
- CLI Interface: The primary method for executing workflows is the CLI, which facilitates the conversion process.
- Web UI: An optional graphical interface allows users to upload their n8n workflows, preview results, and run the conversion without needing to install the CLI globally.
- Integration with OpenAI-compatible LLMs: Utilizes a Language Model to handle the transpilation effectively, ensuring accurate conversion.
Usage Examples
To convert a local workflow JSON file, use:
n8n-to-claw convert workflow.json
For workflows from the n8n REST API, the command is:
n8n-to-claw convert \
--n8n-url https://my-n8n.example.com \
--api-key <n8n-api-key> \
--workflow-id <workflow-id>
Capabilities of the Tool
- The tool supports various flags for operation, such as previewing parse results without completing the conversion (
--dry-run) or inspecting the generated code without executing LLM calls (--inspect). - It can override output directories and handle existing files efficiently.
- Generated skills are stored in the user's OpenClaw workspace, including a comprehensive list of warnings for any degraded or stub nodes encountered during the conversion.
Node Compatibility
The tool boasts mapping for 479 different node types, ensuring wide compatibility with various integrations and workflows. Users can easily check node coverage and example outputs, showcasing how different workflows translate into skills.
Requirements
- Node.js version 20 or greater.
- An OpenAI-compatible LLM API (such as OpenAI, Groq, OpenRouter, or Ollama).
Installation and Documentation
The repository provides detailed instructions for installation and utilization, alongside thorough documentation to assist in understanding its architecture and operational nuances.
For further exploration, examples and the complete documentation are available in the examples/ directory and the dedicated docs folder, respectively.
This tool effectively bridges the functionality of n8n workflows with OpenClaw capabilities, providing developers with an efficient pathway to enhance automation processes.
No comments yet.
Sign in to be the first to comment.