社区节点验证指南#
¥Community node verification guidelines
Do you want n8n to verify your node?
如果你希望将节点提交给 n8n 进行验证,请在构建节点时遵循以下指南。任何启用了已验证社区节点的用户均可从 n8n 的节点面板中发现并安装已验证节点,支持所有部署类型(自托管和 n8n 云)。
¥Consider following these guidelines while building your node if you want to submit it for verification by n8n. Any user with verified community nodes enabled can discover and install verified nodes from n8n's nodes panel across all deployment types (self-hosted and n8n Cloud).
使用 n8n 节点工具#
¥Use the n8n-node tool
所有已验证的社区节点作者强烈建议使用 n8n-node 工具 来创建和检查他们的软件包。这有助于 n8n 通过以下方式确保质量和一致性:
¥All verified community node authors should strongly consider using the n8n-node tool to create and check their package. This helps n8n ensure quality and consistency by:
- 生成预期的软件包文件结构。
¥Generating the expected package file structure
- 向
package.json文件添加所需的元数据和配置
¥Adding the required metadata and configuration to the package.json file
- 方便你根据 n8n 标准检查代码。
¥Making it easy to lint your code against n8n's standards
- 允许你在本地 n8n 实例中加载节点进行测试
¥Allowing you to load your node in a local n8n instance for testing
软件包来源验证#
¥Package source verification
- 验证你的 npm 包仓库 URL 是否与预期的 GitHub(或其他平台)仓库匹配。
¥Verify that your npm package repository URL matches the expected GitHub (or other platform) repository.
- 确认 npm 和仓库中的包作者/维护者一致。
¥Confirm that the package author / maintainer matches between npm and the repository.
- 确认 npm 中的 Git 链接有效,并且该仓库是公开的。
¥Confirm that the git link in npm works and that the repository is public.
- 确保你的软件包拥有完善的文档(README、使用示例等)。
¥Make sure your package has proper documentation (README, usage examples, etc.).
- 确保你的软件包许可证为 MIT 许可证。
¥Make sure your package license is MIT.
无外部依赖#
¥No external dependencies
- 确保你的软件包不包含任何外部依赖,以保持其轻量级和易于维护。
¥Ensure that your package does not include any external dependencies to keep it lightweight and easy to maintain.
完整文档#
¥Proper documentation
- 提供清晰的文档,例如 GitHub 上的 README 文件或相关 API 文档的链接。
¥Provide clear documentation, whether it’s a README on GitHub or links to relevant API documentation.
- 包含使用说明、示例工作流以及任何必要的身份验证详细信息。
¥Include usage instructions, example workflows, and any necessary authentication details.
无法访问环境变量或文件系统#
¥No access to environment variables or file system
- 代码不得与环境变量交互或尝试读取/写入文件。
¥The code must not interact with environment variables or attempt to read/write files.
- 通过节点参数传递所有必要数据。
¥Pass all necessary data through node parameters.
遵循 n8n 最佳实践#
¥Follow n8n best practices
- 保持清晰一致的编码风格。
¥Maintain a clear and consistent coding style.
- 使用 TypeScript 并遵循 n8n 的 node 开发指南。
¥Use TypeScript and follow n8n's node development guidelines.
- 确保正确的错误处理和验证。
¥Ensure proper error handling and validation.
- 请确保代码检查工具通过(换句话说,确保运行
npx @n8n/scan-community-package n8n-nodes-PACKAGE成功)。
¥Make sure the linter passes (in other words, make sure running npx @n8n/scan-community-package n8n-nodes-PACKAGE passes).
仅使用英语#
¥Use English language only
- 节点界面和所有文档都必须仅提供英文版本。
¥Both the node interface and all documentation must be in English only.
- 这包括参数名称、描述、帮助文本、错误消息和 README 内容。
¥This includes parameter names, descriptions, help text, error messages and README content.