n8n-workflow-builder-mcp 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.cursor/rules/cursor_rules.mdc +53 -0
- package/.cursor/rules/dev_workflow.mdc +219 -0
- package/.cursor/rules/mcp.mdc +430 -0
- package/.cursor/rules/self_improve.mdc +72 -0
- package/.cursor/rules/taskmaster.mdc +382 -0
- package/.cursorignore +1 -0
- package/.cursorrules +4 -0
- package/.env.example +23 -0
- package/.eslintrc.json +38 -0
- package/.github/workflows/npm-publish-github-packages.yml +55 -0
- package/.prettierrc +9 -0
- package/.roo/rules/dev_workflow.md +219 -0
- package/.roo/rules/mcp.md +430 -0
- package/.roo/rules/roo_rules.md +53 -0
- package/.roo/rules/self_improve.md +72 -0
- package/.roo/rules/taskmaster.md +382 -0
- package/.roo/rules-architect/architect-rules +93 -0
- package/.roo/rules-ask/ask-rules +89 -0
- package/.roo/rules-boomerang/boomerang-rules +181 -0
- package/.roo/rules-code/code-rules +61 -0
- package/.roo/rules-debug/debug-rules +68 -0
- package/.roo/rules-test/test-rules +61 -0
- package/.roomodes +63 -0
- package/.taskmasterconfig +31 -0
- package/.windsurfrules +2382 -0
- package/LICENSE +21 -0
- package/README.md +210 -0
- package/config/credentials/credentials.json +1 -0
- package/config/default.js +41 -0
- package/package.json +56 -0
- package/scripts/demo-n8n-integration.js +161 -0
- package/scripts/demo-workflow-generator.js +102 -0
- package/scripts/init.sh +36 -0
- package/scripts/prd.txt +197 -0
- package/src/index.ts +1440 -0
- package/src/middleware/auth.js +273 -0
- package/src/middleware/authorize.js +183 -0
- package/src/middleware/logging.js +64 -0
- package/src/middleware/mcp.js +187 -0
- package/src/middleware/rateLimiter.js +82 -0
- package/src/middleware/validation.js +241 -0
- package/src/models/credential.js +359 -0
- package/src/models/llmService.js +236 -0
- package/src/models/n8nIntegration.js +542 -0
- package/src/models/storage.js +196 -0
- package/src/models/tool.js +148 -0
- package/src/models/user.js +164 -0
- package/src/models/workflow.js +229 -0
- package/src/routes/toolDefinitions.js +62 -0
- package/src/routes/toolExecution.js +79 -0
- package/src/tools/__index.js +242 -0
- package/src/tools/connectionManagement.js +500 -0
- package/src/tools/n8nIntegration.js +370 -0
- package/src/tools/nodeDiscovery.js +488 -0
- package/src/tools/nodeManagement.js +674 -0
- package/src/tools/toolDefinitions.js +660 -0
- package/src/tools/workflowCreation.js +100 -0
- package/src/tools/workflowGenerator.js +152 -0
- package/src/tools/workflowStorage.js +113 -0
- package/src/tools/workflowTesting.js +285 -0
- package/src/utils/encryption.js +164 -0
- package/src/utils/logger.js +84 -0
- package/src/utils/mcp.js +85 -0
- package/src/utils/securityLogger.js +109 -0
- package/tests/auth.test.js +402 -0
- package/tests/authorize.test.js +208 -0
- package/tests/run-memory-tests.js +55 -0
- package/tests/run-tests.js +55 -0
- package/tests/server.test.js +203 -0
- package/tests/unit/add-ai-connections.test.js +385 -0
- package/tests/unit/connectionManagement.test.js +309 -0
- package/tests/unit/langchain-llm-format.test.js +259 -0
- package/tests/unit/memory-connection.test.js +140 -0
- package/tests/unit/memory-integration.test.js +253 -0
- package/tests/unit/n8nIntegration.test.js +291 -0
- package/tests/unit/nodeDiscovery.test.js +270 -0
- package/tests/unit/nodeManagement.test.js +522 -0
- package/tests/unit/utils/mcp-test-utils.js +94 -0
- package/tests/unit/workflowCreation.test.js +110 -0
- package/tests/unit/workflowTesting.test.js +269 -0
- package/tests/user.test.js +181 -0
- package/tsconfig.json +20 -0
- package/workflow_nodes/Brandfetch.json +85 -0
- package/workflow_nodes/WorkflowTrigger.json +28 -0
- package/workflow_nodes/actionNetwork.json +218 -0
- package/workflow_nodes/activeCampaign.json +722 -0
- package/workflow_nodes/activeCampaignTrigger.json +52 -0
- package/workflow_nodes/acuitySchedulingTrigger.json +8 -0
- package/workflow_nodes/adalo.json +123 -0
- package/workflow_nodes/affinity.json +203 -0
- package/workflow_nodes/affinityTrigger.json +124 -0
- package/workflow_nodes/aggregate.json +119 -0
- package/workflow_nodes/agileCrm.json +503 -0
- package/workflow_nodes/aiTransform.json +17 -0
- package/workflow_nodes/airtable.json +226 -0
- package/workflow_nodes/airtableTrigger.json +120 -0
- package/workflow_nodes/airtop.json +10 -0
- package/workflow_nodes/amqp.json +62 -0
- package/workflow_nodes/amqpTrigger.json +8 -0
- package/workflow_nodes/apiTemplateIo.json +147 -0
- package/workflow_nodes/asana.json +446 -0
- package/workflow_nodes/asanaTrigger.json +52 -0
- package/workflow_nodes/automizy.json +195 -0
- package/workflow_nodes/autopilot.json +287 -0
- package/workflow_nodes/autopilotTrigger.json +8 -0
- package/workflow_nodes/awsCertificateManager.json +223 -0
- package/workflow_nodes/awsComprehend.json +125 -0
- package/workflow_nodes/awsDynamoDb.json +251 -0
- package/workflow_nodes/awsElb.json +174 -0
- package/workflow_nodes/awsLambda.json +69 -0
- package/workflow_nodes/awsRekognition.json +191 -0
- package/workflow_nodes/awsS3.json +32 -0
- package/workflow_nodes/awsSes.json +302 -0
- package/workflow_nodes/awsSns.json +110 -0
- package/workflow_nodes/awsSnsTrigger.json +47 -0
- package/workflow_nodes/awsSqs.json +140 -0
- package/workflow_nodes/awsTextract.json +43 -0
- package/workflow_nodes/awsTranscribe.json +217 -0
- package/workflow_nodes/azureCosmosDb.json +8 -0
- package/workflow_nodes/azureStorage.json +17 -0
- package/workflow_nodes/bambooHr.json +8 -0
- package/workflow_nodes/bannerbear.json +126 -0
- package/workflow_nodes/baserow.json +277 -0
- package/workflow_nodes/beeminder.json +146 -0
- package/workflow_nodes/bitbucketTrigger.json +62 -0
- package/workflow_nodes/bitly.json +130 -0
- package/workflow_nodes/bitwarden.json +224 -0
- package/workflow_nodes/box.json +457 -0
- package/workflow_nodes/boxTrigger.json +8 -0
- package/workflow_nodes/brevo.json +41 -0
- package/workflow_nodes/brevoTrigger.json +145 -0
- package/workflow_nodes/bubble.json +212 -0
- package/workflow_nodes/calTrigger.json +91 -0
- package/workflow_nodes/calendlyTrigger.json +71 -0
- package/workflow_nodes/chargebee.json +217 -0
- package/workflow_nodes/chargebeeTrigger.json +187 -0
- package/workflow_nodes/circleCi.json +89 -0
- package/workflow_nodes/ciscoWebex.json +593 -0
- package/workflow_nodes/ciscoWebexTrigger.json +159 -0
- package/workflow_nodes/clearbit.json +138 -0
- package/workflow_nodes/clickUp.json +793 -0
- package/workflow_nodes/clickUpTrigger.json +188 -0
- package/workflow_nodes/clockify.json +372 -0
- package/workflow_nodes/clockifyTrigger.json +26 -0
- package/workflow_nodes/cloudflare.json +103 -0
- package/workflow_nodes/cockpit.json +161 -0
- package/workflow_nodes/coda.json +242 -0
- package/workflow_nodes/code.json +40 -0
- package/workflow_nodes/coinGecko.json +363 -0
- package/workflow_nodes/compareDatasets.json +14 -0
- package/workflow_nodes/compression.json +66 -0
- package/workflow_nodes/contentful.json +29 -0
- package/workflow_nodes/convertKit.json +159 -0
- package/workflow_nodes/convertKitTrigger.json +109 -0
- package/workflow_nodes/convertToFile.json +64 -0
- package/workflow_nodes/copper.json +239 -0
- package/workflow_nodes/copperTrigger.json +8 -0
- package/workflow_nodes/cortex.json +348 -0
- package/workflow_nodes/crateDb.json +90 -0
- package/workflow_nodes/cron.json +23 -0
- package/workflow_nodes/crowdDev.json +8 -0
- package/workflow_nodes/crowdDevTrigger.json +8 -0
- package/workflow_nodes/crypto.json +147 -0
- package/workflow_nodes/customerIo.json +206 -0
- package/workflow_nodes/customerIoTrigger.json +185 -0
- package/workflow_nodes/dateTime.json +39 -0
- package/workflow_nodes/debughelper.json +162 -0
- package/workflow_nodes/deepL.json +103 -0
- package/workflow_nodes/demio.json +187 -0
- package/workflow_nodes/dhl.json +53 -0
- package/workflow_nodes/discord.json +81 -0
- package/workflow_nodes/discourse.json +319 -0
- package/workflow_nodes/disqus.json +254 -0
- package/workflow_nodes/drift.json +112 -0
- package/workflow_nodes/dropbox.json +258 -0
- package/workflow_nodes/dropcontact.json +154 -0
- package/workflow_nodes/e2eTest.json +70 -0
- package/workflow_nodes/editImage.json +132 -0
- package/workflow_nodes/egoi.json +220 -0
- package/workflow_nodes/elasticSecurity.json +401 -0
- package/workflow_nodes/elasticsearch.json +422 -0
- package/workflow_nodes/emailReadImap.json +88 -0
- package/workflow_nodes/emailSend.json +38 -0
- package/workflow_nodes/emelia.json +201 -0
- package/workflow_nodes/emeliaTrigger.json +57 -0
- package/workflow_nodes/erpNext.json +139 -0
- package/workflow_nodes/errorTrigger.json +15 -0
- package/workflow_nodes/evaluationMetrics.json +21 -0
- package/workflow_nodes/eventbriteTrigger.json +125 -0
- package/workflow_nodes/executeCommand.json +25 -0
- package/workflow_nodes/executeWorkflow.json +102 -0
- package/workflow_nodes/executeWorkflowTrigger.json +65 -0
- package/workflow_nodes/executionData.json +35 -0
- package/workflow_nodes/extractFromFile.json +71 -0
- package/workflow_nodes/facebookGraphApi.json +234 -0
- package/workflow_nodes/facebookLeadAdsTrigger.json +8 -0
- package/workflow_nodes/facebookTrigger.json +112 -0
- package/workflow_nodes/figmaTrigger.json +8 -0
- package/workflow_nodes/filemaker.json +268 -0
- package/workflow_nodes/filter.json +24 -0
- package/workflow_nodes/flow.json +323 -0
- package/workflow_nodes/flowTrigger.json +52 -0
- package/workflow_nodes/form.json +25 -0
- package/workflow_nodes/formIoTrigger.json +59 -0
- package/workflow_nodes/formTrigger.json +8 -0
- package/workflow_nodes/formstackTrigger.json +8 -0
- package/workflow_nodes/freshdesk.json +584 -0
- package/workflow_nodes/freshservice.json +899 -0
- package/workflow_nodes/freshworksCrm.json +772 -0
- package/workflow_nodes/ftp.json +127 -0
- package/workflow_nodes/function.json +22 -0
- package/workflow_nodes/functionItem.json +22 -0
- package/workflow_nodes/gSuiteAdmin.json +562 -0
- package/workflow_nodes/getResponse.json +310 -0
- package/workflow_nodes/getResponseTrigger.json +82 -0
- package/workflow_nodes/ghost.json +290 -0
- package/workflow_nodes/git.json +184 -0
- package/workflow_nodes/github.json +732 -0
- package/workflow_nodes/githubTrigger.json +317 -0
- package/workflow_nodes/gitlab.json +544 -0
- package/workflow_nodes/gitlabTrigger.json +61 -0
- package/workflow_nodes/gmail.json +62 -0
- package/workflow_nodes/gmailTrigger.json +127 -0
- package/workflow_nodes/goToWebinar.json +430 -0
- package/workflow_nodes/gong.json +22 -0
- package/workflow_nodes/googleAds.json +116 -0
- package/workflow_nodes/googleAnalytics.json +28 -0
- package/workflow_nodes/googleBigQuery.json +38 -0
- package/workflow_nodes/googleBooks.json +154 -0
- package/workflow_nodes/googleBusinessProfile.json +277 -0
- package/workflow_nodes/googleBusinessProfileTrigger.json +55 -0
- package/workflow_nodes/googleCalendar.json +474 -0
- package/workflow_nodes/googleCalendarTrigger.json +72 -0
- package/workflow_nodes/googleChat.json +187 -0
- package/workflow_nodes/googleCloudNaturalLanguage.json +171 -0
- package/workflow_nodes/googleCloudStorage.json +466 -0
- package/workflow_nodes/googleContacts.json +481 -0
- package/workflow_nodes/googleDocs.json +312 -0
- package/workflow_nodes/googleDrive.json +920 -0
- package/workflow_nodes/googleDriveTrigger.json +181 -0
- package/workflow_nodes/googleFirebaseCloudFirestore.json +156 -0
- package/workflow_nodes/googleFirebaseRealtimeDatabase.json +75 -0
- package/workflow_nodes/googlePerspective.json +94 -0
- package/workflow_nodes/googleSheets.json +98 -0
- package/workflow_nodes/googleSheetsTrigger.json +192 -0
- package/workflow_nodes/googleSlides.json +186 -0
- package/workflow_nodes/googleTasks.json +198 -0
- package/workflow_nodes/googleTranslate.json +80 -0
- package/workflow_nodes/gotify.json +110 -0
- package/workflow_nodes/grafana.json +155 -0
- package/workflow_nodes/graphql.json +165 -0
- package/workflow_nodes/grist.json +13 -0
- package/workflow_nodes/gumroadTrigger.json +8 -0
- package/workflow_nodes/hackerNews.json +100 -0
- package/workflow_nodes/haloPSA.json +286 -0
- package/workflow_nodes/harvest.json +699 -0
- package/workflow_nodes/helpScout.json +629 -0
- package/workflow_nodes/helpScoutTrigger.json +8 -0
- package/workflow_nodes/highLevel.json +8 -0
- package/workflow_nodes/homeAssistant.json +201 -0
- package/workflow_nodes/html.json +118 -0
- package/workflow_nodes/htmlExtract.json +87 -0
- package/workflow_nodes/httpRequest.json +472 -0
- package/workflow_nodes/hubspot.json +62 -0
- package/workflow_nodes/hubspotTrigger.json +138 -0
- package/workflow_nodes/humanticAi.json +82 -0
- package/workflow_nodes/hunter.json +168 -0
- package/workflow_nodes/iCal.json +20 -0
- package/workflow_nodes/if.json +24 -0
- package/workflow_nodes/intercom.json +335 -0
- package/workflow_nodes/interval.json +8 -0
- package/workflow_nodes/invoiceNinja.json +882 -0
- package/workflow_nodes/invoiceNinjaTrigger.json +11 -0
- package/workflow_nodes/itemLists.json +313 -0
- package/workflow_nodes/iterable.json +168 -0
- package/workflow_nodes/jenkins.json +172 -0
- package/workflow_nodes/jira.json +529 -0
- package/workflow_nodes/jiraTrigger.json +308 -0
- package/workflow_nodes/jotFormTrigger.json +44 -0
- package/workflow_nodes/jwt.json +195 -0
- package/workflow_nodes/kafka.json +132 -0
- package/workflow_nodes/kafkaTrigger.json +11 -0
- package/workflow_nodes/keap.json +915 -0
- package/workflow_nodes/keapTrigger.json +37 -0
- package/workflow_nodes/kitemaker.json +153 -0
- package/workflow_nodes/koBoToolbox.json +337 -0
- package/workflow_nodes/koBoToolboxTrigger.json +8 -0
- package/workflow_nodes/langchain_Summarization Chain.json +60 -0
- package/workflow_nodes/langchain_agent.json +145 -0
- package/workflow_nodes/langchain_allowFileUploads.json +180 -0
- package/workflow_nodes/langchain_chainLlm.json +16 -0
- package/workflow_nodes/langchain_chainSummarization.json +119 -0
- package/workflow_nodes/langchain_code.json +62 -0
- package/workflow_nodes/langchain_documentBinaryInputLoader.json +8 -0
- package/workflow_nodes/langchain_documentDefaultDataLoader.json +8 -0
- package/workflow_nodes/langchain_documentGithubLoader.json +8 -0
- package/workflow_nodes/langchain_documentJsonInputLoader.json +8 -0
- package/workflow_nodes/langchain_embeddingDimensions.json +17 -0
- package/workflow_nodes/langchain_embeddingsAwsBedrock.json +8 -0
- package/workflow_nodes/langchain_embeddingsAzureOpenAi.json +151 -0
- package/workflow_nodes/langchain_embeddingsCohere.json +8 -0
- package/workflow_nodes/langchain_embeddingsGoogleGemini.json +8 -0
- package/workflow_nodes/langchain_embeddingsGoogleVertex.json +8 -0
- package/workflow_nodes/langchain_embeddingsHuggingFaceInference.json +8 -0
- package/workflow_nodes/langchain_embeddingsMistralCloud.json +8 -0
- package/workflow_nodes/langchain_embeddingsOllama.json +8 -0
- package/workflow_nodes/langchain_informationExtractor.json +81 -0
- package/workflow_nodes/langchain_lmChatAwsBedrock.json +8 -0
- package/workflow_nodes/langchain_lmChatAzureOpenAi.json +151 -0
- package/workflow_nodes/langchain_lmChatDeepSeek.json +10 -0
- package/workflow_nodes/langchain_lmChatGoogleGemini.json +31 -0
- package/workflow_nodes/langchain_lmChatGoogleVertex.json +32 -0
- package/workflow_nodes/langchain_lmChatGroq.json +8 -0
- package/workflow_nodes/langchain_lmChatMistralCloud.json +8 -0
- package/workflow_nodes/langchain_lmChatOllama.json +8 -0
- package/workflow_nodes/langchain_lmChatOpenAi.json +155 -0
- package/workflow_nodes/langchain_lmChatOpenRouter.json +10 -0
- package/workflow_nodes/langchain_lmChatXAiGrok.json +10 -0
- package/workflow_nodes/langchain_lmCohere.json +8 -0
- package/workflow_nodes/langchain_lmOllama.json +8 -0
- package/workflow_nodes/langchain_lmOpenAi.json +251 -0
- package/workflow_nodes/langchain_lmOpenHuggingFaceInference.json +8 -0
- package/workflow_nodes/langchain_manualChatTrigger.json +11 -0
- package/workflow_nodes/langchain_mcpClientTool.json +86 -0
- package/workflow_nodes/langchain_mcpTrigger.json +8 -0
- package/workflow_nodes/langchain_memoryBufferWindow.json +13 -0
- package/workflow_nodes/langchain_memoryChatRetriever.json +22 -0
- package/workflow_nodes/langchain_memoryManager.json +106 -0
- package/workflow_nodes/langchain_memoryMongoDbChat.json +10 -0
- package/workflow_nodes/langchain_memoryMotorhead.json +13 -0
- package/workflow_nodes/langchain_memoryPostgresChat.json +13 -0
- package/workflow_nodes/langchain_memoryRedisChat.json +15 -0
- package/workflow_nodes/langchain_memoryXata.json +14 -0
- package/workflow_nodes/langchain_memoryZep.json +13 -0
- package/workflow_nodes/langchain_model.json +155 -0
- package/workflow_nodes/langchain_mongoCollection.json +16 -0
- package/workflow_nodes/langchain_notice.json +22 -0
- package/workflow_nodes/langchain_openAiAssistant.json +132 -0
- package/workflow_nodes/langchain_options.json +17 -0
- package/workflow_nodes/langchain_outputParserAutofixing.json +8 -0
- package/workflow_nodes/langchain_outputParserItemList.json +8 -0
- package/workflow_nodes/langchain_outputParserStructured.json +12 -0
- package/workflow_nodes/langchain_pineconeNamespace.json +16 -0
- package/workflow_nodes/langchain_queryName.json +16 -0
- package/workflow_nodes/langchain_retrieverContextualCompression.json +8 -0
- package/workflow_nodes/langchain_retrieverMultiQuery.json +8 -0
- package/workflow_nodes/langchain_retrieverVectorStore.json +8 -0
- package/workflow_nodes/langchain_retrieverWorkflow.json +103 -0
- package/workflow_nodes/langchain_sentimentAnalysis.json +52 -0
- package/workflow_nodes/langchain_systemPromptTemplate.json +47 -0
- package/workflow_nodes/langchain_tableName.json +23 -0
- package/workflow_nodes/langchain_textClassifier.json +66 -0
- package/workflow_nodes/langchain_textSplitterCharacterTextSplitter.json +8 -0
- package/workflow_nodes/langchain_textSplitterRecursiveCharacterTextSplitter.json +8 -0
- package/workflow_nodes/langchain_textSplitterTokenSplitter.json +8 -0
- package/workflow_nodes/langchain_toolCalculator.json +8 -0
- package/workflow_nodes/langchain_toolCode.json +12 -0
- package/workflow_nodes/langchain_toolHttpRequest.json +232 -0
- package/workflow_nodes/langchain_toolSearXng.json +8 -0
- package/workflow_nodes/langchain_toolSerpApi.json +8 -0
- package/workflow_nodes/langchain_toolThink.json +8 -0
- package/workflow_nodes/langchain_toolVectorStore.json +11 -0
- package/workflow_nodes/langchain_toolWikipedia.json +8 -0
- package/workflow_nodes/langchain_toolWolframAlpha.json +8 -0
- package/workflow_nodes/langchain_toolWorkflow.json +8 -0
- package/workflow_nodes/langchain_vectorStoreInMemoryInsert.json +29 -0
- package/workflow_nodes/langchain_vectorStoreInMemoryLoad.json +8 -0
- package/workflow_nodes/langchain_vectorStorePineconeInsert.json +37 -0
- package/workflow_nodes/langchain_vectorStorePineconeLoad.json +8 -0
- package/workflow_nodes/langchain_vectorStoreSupabaseInsert.json +32 -0
- package/workflow_nodes/langchain_vectorStoreSupabaseLoad.json +8 -0
- package/workflow_nodes/langchain_vectorStoreZepInsert.json +46 -0
- package/workflow_nodes/langchain_vectorStoreZepLoad.json +8 -0
- package/workflow_nodes/ldap.json +182 -0
- package/workflow_nodes/lemlist.json +44 -0
- package/workflow_nodes/lemlistTrigger.json +45 -0
- package/workflow_nodes/limit.json +26 -0
- package/workflow_nodes/line.json +95 -0
- package/workflow_nodes/linear.json +151 -0
- package/workflow_nodes/linearTrigger.json +71 -0
- package/workflow_nodes/lingvaNex.json +66 -0
- package/workflow_nodes/linkedIn.json +142 -0
- package/workflow_nodes/localFileTrigger.json +120 -0
- package/workflow_nodes/lonescale.json +171 -0
- package/workflow_nodes/lonescaleTrigger.json +8 -0
- package/workflow_nodes/magento2.json +164 -0
- package/workflow_nodes/mailcheck.json +46 -0
- package/workflow_nodes/mailchimp.json +507 -0
- package/workflow_nodes/mailchimpTrigger.json +100 -0
- package/workflow_nodes/mailerLite.json +24 -0
- package/workflow_nodes/mailerLiteTrigger.json +74 -0
- package/workflow_nodes/mailgun.json +81 -0
- package/workflow_nodes/mailjet.json +201 -0
- package/workflow_nodes/mailjetTrigger.json +8 -0
- package/workflow_nodes/mandrill.json +372 -0
- package/workflow_nodes/manualTrigger.json +8 -0
- package/workflow_nodes/markdown.json +376 -0
- package/workflow_nodes/marketstack.json +126 -0
- package/workflow_nodes/matrix.json +264 -0
- package/workflow_nodes/mattermost.json +8 -0
- package/workflow_nodes/mautic.json +564 -0
- package/workflow_nodes/mauticTrigger.json +54 -0
- package/workflow_nodes/medium.json +209 -0
- package/workflow_nodes/merge.json +125 -0
- package/workflow_nodes/messageBird.json +182 -0
- package/workflow_nodes/metabase.json +175 -0
- package/workflow_nodes/microsoftDynamicsCrm.json +100 -0
- package/workflow_nodes/microsoftEntra.json +51 -0
- package/workflow_nodes/microsoftExcel.json +35 -0
- package/workflow_nodes/microsoftGraphSecurity.json +113 -0
- package/workflow_nodes/microsoftOneDrive.json +232 -0
- package/workflow_nodes/microsoftOneDriveTrigger.json +80 -0
- package/workflow_nodes/microsoftOutlook.json +40 -0
- package/workflow_nodes/microsoftOutlookTrigger.json +24 -0
- package/workflow_nodes/microsoftSql.json +81 -0
- package/workflow_nodes/microsoftTeams.json +36 -0
- package/workflow_nodes/microsoftToDo.json +181 -0
- package/workflow_nodes/mindee.json +86 -0
- package/workflow_nodes/misp.json +399 -0
- package/workflow_nodes/mocean.json +103 -0
- package/workflow_nodes/mondayCom.json +290 -0
- package/workflow_nodes/mongoDb.json +16 -0
- package/workflow_nodes/monicaCrm.json +543 -0
- package/workflow_nodes/moveBinaryData.json +121 -0
- package/workflow_nodes/mqtt.json +67 -0
- package/workflow_nodes/mqttTrigger.json +47 -0
- package/workflow_nodes/msg91.json +65 -0
- package/workflow_nodes/mySql.json +111 -0
- package/workflow_nodes/n8n.json +75 -0
- package/workflow_nodes/n8nTrigger.json +27 -0
- package/workflow_nodes/nasa.json +310 -0
- package/workflow_nodes/netlify.json +87 -0
- package/workflow_nodes/netlifyTrigger.json +68 -0
- package/workflow_nodes/netscalerAdc.json +243 -0
- package/workflow_nodes/nextCloud.json +312 -0
- package/workflow_nodes/noOp.json +8 -0
- package/workflow_nodes/nocoDb.json +276 -0
- package/workflow_nodes/notion.json +8 -0
- package/workflow_nodes/notionTrigger.json +75 -0
- package/workflow_nodes/npm.json +64 -0
- package/workflow_nodes/odoo.json +344 -0
- package/workflow_nodes/okta.json +97 -0
- package/workflow_nodes/oneSimpleApi.json +281 -0
- package/workflow_nodes/onfleet.json +316 -0
- package/workflow_nodes/onfleetTrigger.json +8 -0
- package/workflow_nodes/openAi.json +154 -0
- package/workflow_nodes/openThesaurus.json +81 -0
- package/workflow_nodes/openWeatherMap.json +129 -0
- package/workflow_nodes/orbit.json +375 -0
- package/workflow_nodes/oura.json +74 -0
- package/workflow_nodes/paddle.json +403 -0
- package/workflow_nodes/pagerDuty.json +351 -0
- package/workflow_nodes/payPal.json +196 -0
- package/workflow_nodes/payPalTrigger.json +40 -0
- package/workflow_nodes/peekalink.json +41 -0
- package/workflow_nodes/phantombuster.json +172 -0
- package/workflow_nodes/philipsHue.json +177 -0
- package/workflow_nodes/pipedrive.json +860 -0
- package/workflow_nodes/pipedriveTrigger.json +11 -0
- package/workflow_nodes/plivo.json +91 -0
- package/workflow_nodes/postHog.json +122 -0
- package/workflow_nodes/postbin.json +60 -0
- package/workflow_nodes/postgres.json +109 -0
- package/workflow_nodes/postgresTrigger.json +8 -0
- package/workflow_nodes/postmarkTrigger.json +72 -0
- package/workflow_nodes/profitWell.json +305 -0
- package/workflow_nodes/pushbullet.json +186 -0
- package/workflow_nodes/pushcut.json +75 -0
- package/workflow_nodes/pushcutTrigger.json +8 -0
- package/workflow_nodes/pushover.json +159 -0
- package/workflow_nodes/questDb.json +94 -0
- package/workflow_nodes/quickChart.json +188 -0
- package/workflow_nodes/quickbase.json +205 -0
- package/workflow_nodes/quickbooks.json +550 -0
- package/workflow_nodes/rabbitmq.json +165 -0
- package/workflow_nodes/rabbitmqTrigger.json +8 -0
- package/workflow_nodes/raindrop.json +216 -0
- package/workflow_nodes/readBinaryFile.json +26 -0
- package/workflow_nodes/readBinaryFiles.json +26 -0
- package/workflow_nodes/readPDF.json +31 -0
- package/workflow_nodes/readWriteFile.json +27 -0
- package/workflow_nodes/reddit.json +309 -0
- package/workflow_nodes/redis.json +183 -0
- package/workflow_nodes/redisTrigger.json +8 -0
- package/workflow_nodes/removeDuplicates.json +8 -0
- package/workflow_nodes/renameKeys.json +67 -0
- package/workflow_nodes/respondToWebhook.json +126 -0
- package/workflow_nodes/rocketchat.json +216 -0
- package/workflow_nodes/rssFeedRead.json +28 -0
- package/workflow_nodes/rssFeedReadTrigger.json +17 -0
- package/workflow_nodes/rundeck.json +79 -0
- package/workflow_nodes/s3.json +425 -0
- package/workflow_nodes/salesforce.json +1137 -0
- package/workflow_nodes/salesforceTrigger.json +122 -0
- package/workflow_nodes/salesmate.json +467 -0
- package/workflow_nodes/scheduleTrigger.json +270 -0
- package/workflow_nodes/seaTable.json +8 -0
- package/workflow_nodes/seaTableTrigger.json +87 -0
- package/workflow_nodes/securityScorecard.json +459 -0
- package/workflow_nodes/segment.json +219 -0
- package/workflow_nodes/sendGrid.json +359 -0
- package/workflow_nodes/sendy.json +225 -0
- package/workflow_nodes/sentryIo.json +426 -0
- package/workflow_nodes/serviceNow.json +544 -0
- package/workflow_nodes/set.json +124 -0
- package/workflow_nodes/shopify.json +707 -0
- package/workflow_nodes/shopifyTrigger.json +8 -0
- package/workflow_nodes/signl4.json +133 -0
- package/workflow_nodes/simulate.json +30 -0
- package/workflow_nodes/simulateTrigger.json +8 -0
- package/workflow_nodes/slack.json +62 -0
- package/workflow_nodes/slackTrigger.json +135 -0
- package/workflow_nodes/sms77.json +121 -0
- package/workflow_nodes/snowflake.json +65 -0
- package/workflow_nodes/sort.json +57 -0
- package/workflow_nodes/splitInBatches.json +30 -0
- package/workflow_nodes/splitOut.json +62 -0
- package/workflow_nodes/splunk.json +40 -0
- package/workflow_nodes/spontit.json +123 -0
- package/workflow_nodes/spotify.json +285 -0
- package/workflow_nodes/spreadsheetFile.json +8 -0
- package/workflow_nodes/sseTrigger.json +8 -0
- package/workflow_nodes/ssh.json +105 -0
- package/workflow_nodes/stackby.json +85 -0
- package/workflow_nodes/start.json +15 -0
- package/workflow_nodes/stickyNote.json +36 -0
- package/workflow_nodes/stopAndError.json +8 -0
- package/workflow_nodes/storyblok.json +138 -0
- package/workflow_nodes/strapi.json +138 -0
- package/workflow_nodes/strava.json +427 -0
- package/workflow_nodes/stravaTrigger.json +79 -0
- package/workflow_nodes/stripe.json +357 -0
- package/workflow_nodes/stripeTrigger.json +775 -0
- package/workflow_nodes/summarize.json +124 -0
- package/workflow_nodes/supabase.json +136 -0
- package/workflow_nodes/surveyMonkeyTrigger.json +160 -0
- package/workflow_nodes/switch.json +91 -0
- package/workflow_nodes/syncroMsp.json +8 -0
- package/workflow_nodes/taiga.json +340 -0
- package/workflow_nodes/taigaTrigger.json +81 -0
- package/workflow_nodes/tapfiliate.json +241 -0
- package/workflow_nodes/telegram.json +612 -0
- package/workflow_nodes/telegramTrigger.json +142 -0
- package/workflow_nodes/theHive.json +497 -0
- package/workflow_nodes/theHiveProject.json +8 -0
- package/workflow_nodes/theHiveProjectTrigger.json +162 -0
- package/workflow_nodes/theHiveTrigger.json +101 -0
- package/workflow_nodes/timescaleDb.json +95 -0
- package/workflow_nodes/todoist.json +285 -0
- package/workflow_nodes/togglTrigger.json +24 -0
- package/workflow_nodes/totp.json +86 -0
- package/workflow_nodes/travisCi.json +142 -0
- package/workflow_nodes/trello.json +609 -0
- package/workflow_nodes/trelloTrigger.json +8 -0
- package/workflow_nodes/twake.json +76 -0
- package/workflow_nodes/twilio.json +95 -0
- package/workflow_nodes/twilioTrigger.json +46 -0
- package/workflow_nodes/twist.json +376 -0
- package/workflow_nodes/twitter.json +40 -0
- package/workflow_nodes/typeformTrigger.json +62 -0
- package/workflow_nodes/unleashedSoftware.json +154 -0
- package/workflow_nodes/uplead.json +72 -0
- package/workflow_nodes/uproc.json +26 -0
- package/workflow_nodes/uptimeRobot.json +453 -0
- package/workflow_nodes/urlScanIo.json +113 -0
- package/workflow_nodes/venafiTlsProtectCloud.json +310 -0
- package/workflow_nodes/venafiTlsProtectCloudTrigger.json +38 -0
- package/workflow_nodes/venafiTlsProtectDatacenter.json +491 -0
- package/workflow_nodes/vero.json +158 -0
- package/workflow_nodes/vonage.json +125 -0
- package/workflow_nodes/wait.json +71 -0
- package/workflow_nodes/webflow.json +38 -0
- package/workflow_nodes/webflowTrigger.json +8 -0
- package/workflow_nodes/webhook.json +55 -0
- package/workflow_nodes/wekan.json +460 -0
- package/workflow_nodes/whatsApp.json +476 -0
- package/workflow_nodes/whatsAppTrigger.json +103 -0
- package/workflow_nodes/wise.json +330 -0
- package/workflow_nodes/wiseTrigger.json +8 -0
- package/workflow_nodes/wooCommerce.json +812 -0
- package/workflow_nodes/wooCommerceTrigger.json +8 -0
- package/workflow_nodes/wordpress.json +500 -0
- package/workflow_nodes/workableTrigger.json +51 -0
- package/workflow_nodes/writeBinaryFile.json +34 -0
- package/workflow_nodes/wufooTrigger.json +37 -0
- package/workflow_nodes/xero.json +530 -0
- package/workflow_nodes/xml.json +129 -0
- package/workflow_nodes/youTube.json +578 -0
- package/workflow_nodes/yourls.json +71 -0
- package/workflow_nodes/zammad.json +406 -0
- package/workflow_nodes/zendesk.json +526 -0
- package/workflow_nodes/zendeskTrigger.json +187 -0
- package/workflow_nodes/zohoCrm.json +721 -0
- package/workflow_nodes/zoom.json +507 -0
- package/workflow_nodes/zulip.json +371 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2025 ifmelate
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,210 @@
|
|
|
1
|
+
# n8n Workflow Builder MCP
|
|
2
|
+
|
|
3
|
+
This project provides a Model Context Protocol (MCP) server for building and manipulating n8n workflows JSON in Cursor IDE. It's a way to build n8n workflows just by prompting with AI in chat.
|
|
4
|
+
|
|
5
|
+
<a href="https://glama.ai/mcp/servers/@ifmelate/n8n-workflow-builder-mcp">
|
|
6
|
+
<img width="380" height="200" src="https://glama.ai/mcp/servers/@ifmelate/n8n-workflow-builder-mcp/badge" alt="n8n-workflow-builder-mcp MCP server" />
|
|
7
|
+
</a>
|
|
8
|
+
|
|
9
|
+
# DEMO VIDEO:
|
|
10
|
+
[](https://youtu.be/MKEVLM5QmPA?si=8SJQAcYGeAIuhaBm)
|
|
11
|
+
|
|
12
|
+
## Current status of implementation
|
|
13
|
+
|
|
14
|
+
It's in early development stage. Basically, it's working - MCP server creates JSON file with n8n workflow that you can copy and paste to workflow editor in n8n UI.
|
|
15
|
+
Current problems:
|
|
16
|
+
- sometimes llm agents put wrong parameters in the request. **I plan to find a way to fix this**.
|
|
17
|
+
- sometimes connection between nodes is not setting. **I'm working to resolve it**.
|
|
18
|
+
- not all types of node are checked working. **I'm working to resolve it**.
|
|
19
|
+
- initial prompt does matter. If it's not clear, the agent will go wrong way. **I plan to find a way to fix this**.
|
|
20
|
+
|
|
21
|
+
## Key Features
|
|
22
|
+
|
|
23
|
+
- **Workflow Management**: Create, update, and execute n8n workflows programmatically (execute is not implemented yet)
|
|
24
|
+
- **Node Discovery**: Explore available n8n nodes and their capabilities
|
|
25
|
+
- **Connection Management**: Create connections between workflow nodes
|
|
26
|
+
- **AI Integration**: Special tools for connecting AI components in workflows
|
|
27
|
+
- **AI-Friendly Interface**: Designed specifically for interaction with AI agents
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
## Prerequisites
|
|
31
|
+
|
|
32
|
+
- Node.js (v14 or higher)
|
|
33
|
+
- Cursor IDE (v0.48 or newer)
|
|
34
|
+
- npm or yarn
|
|
35
|
+
- TypeScript compiler (installed as a dev dependency via `npm install`)
|
|
36
|
+
|
|
37
|
+
## Installation
|
|
38
|
+
|
|
39
|
+
1. Clone the repository:
|
|
40
|
+
```bash
|
|
41
|
+
git clone https://github.com/ifmelate/n8n-workflow-builder-mcp.git
|
|
42
|
+
cd n8n-workflow-builder-mcp
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
2. Install dependencies:
|
|
46
|
+
```bash
|
|
47
|
+
npm install
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
3. Build the TypeScript project:
|
|
51
|
+
```bash
|
|
52
|
+
npm run build
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
4. Make the MCP server script executable (if needed):
|
|
56
|
+
```bash
|
|
57
|
+
chmod +x dist/index.js
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
## Running the Server
|
|
61
|
+
|
|
62
|
+
Start the MCP server:
|
|
63
|
+
```bash
|
|
64
|
+
npm start
|
|
65
|
+
```
|
|
66
|
+
This will run the compiled code from `dist/index.js`.
|
|
67
|
+
|
|
68
|
+
For development with auto-rebuild and restart on changes:
|
|
69
|
+
```bash
|
|
70
|
+
npm run dev
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
## Cursor IDE Integration
|
|
74
|
+
|
|
75
|
+
There are two ways to set up the MCP server with Cursor:
|
|
76
|
+
|
|
77
|
+
### Method 1: Using Cursor Settings UI (Recommended)
|
|
78
|
+
|
|
79
|
+
1. Start Cursor IDE
|
|
80
|
+
2. Go to Settings > Features > MCP Servers
|
|
81
|
+
3. Click "Add Server" and provide the **absolute path** to the `dist/index.js` file
|
|
82
|
+
(e.g., `/Users/yourname/n8n-workflow-builder-mcp/dist/index.js`)
|
|
83
|
+
4. Make sure the server is enabled
|
|
84
|
+
5. Restart Cursor IDE for changes to take effect
|
|
85
|
+
|
|
86
|
+
### Method 2: Manual Configuration
|
|
87
|
+
|
|
88
|
+
1. Ensure the `.cursor` directory exists:
|
|
89
|
+
```bash
|
|
90
|
+
mkdir -p .cursor
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
2. Create the MCP configuration file:
|
|
94
|
+
```bash
|
|
95
|
+
cat > .cursor/mcp.json << 'EOF'
|
|
96
|
+
{
|
|
97
|
+
"mcpServers": {
|
|
98
|
+
"n8n-workflow-builder": {
|
|
99
|
+
"command": "node",
|
|
100
|
+
"args": ["/absolute/path/to/n8n-workflow-builder-mcp/dist/index.js"]
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
EOF
|
|
105
|
+
```
|
|
106
|
+
Make sure to replace `/absolute/path/to` with the actual path on your system.
|
|
107
|
+
|
|
108
|
+
3. Restart Cursor IDE for changes to take effect
|
|
109
|
+
|
|
110
|
+
## Available MCP Tools
|
|
111
|
+
|
|
112
|
+
The server provides the following tools for working with n8n workflows:
|
|
113
|
+
|
|
114
|
+
| Tool Name | Description | Key Parameters |
|
|
115
|
+
|-----------|-------------|----------------|
|
|
116
|
+
| **create_workflow** | Create a new n8n workflow | `workflow_name`, `workspace_dir` |
|
|
117
|
+
| **list_workflows** | List all existing workflows | (no parameters) |
|
|
118
|
+
| **get_workflow_details** | Get detailed information about a specific workflow | `workflow_name` |
|
|
119
|
+
| **add_node** | Add a new node to a workflow | `workflow_name`, `node_type`, `position`, `parameters`, `node_name`, `typeVersion` |
|
|
120
|
+
| **edit_node** | Edit an existing node in a workflow | `workflow_name`, `node_id`, `node_type`, `node_name`, `position`, `parameters` |
|
|
121
|
+
| **delete_node** | Delete a node from a workflow | `workflow_name`, `node_id` |
|
|
122
|
+
| **add_connection** | Add a connection between nodes | `workflow_name`, `source_node_id`, `source_node_output_name`, `target_node_id`, `target_node_input_name` |
|
|
123
|
+
| **add_ai_connections** | Add AI connections for LangChain nodes | `workflow_name`, `agent_node_id`, `model_node_id`, `tool_node_ids` |
|
|
124
|
+
| **list_available_nodes** | List available node types with optional filtering | `search_term` (optional) |
|
|
125
|
+
|
|
126
|
+
## Troubleshooting Cursor Integration
|
|
127
|
+
|
|
128
|
+
If you're having trouble getting the MCP server to work with Cursor, try these steps:
|
|
129
|
+
|
|
130
|
+
1. **Restart Cursor**: After setting up the MCP configuration, completely close and restart Cursor.
|
|
131
|
+
|
|
132
|
+
2. **Check Cursor MCP settings**:
|
|
133
|
+
- Open Cursor Settings
|
|
134
|
+
- Go to Features > MCP Servers
|
|
135
|
+
- Make sure your server is listed and enabled
|
|
136
|
+
- If it's listed but not working, try clicking the refresh button
|
|
137
|
+
|
|
138
|
+
3. **Check server logs**: Look for errors in the terminal where you're running the server or in the Cursor Output panel. Select "Cursor MCP" from the dropdown in the Output panel to see MCP-specific logs.
|
|
139
|
+
|
|
140
|
+
4. **Verify file permissions**: Make sure the `dist/index.js` file has execution permissions.
|
|
141
|
+
|
|
142
|
+
5. **Check for port conflicts**: If there are other MCP servers running, they might conflict. Check for other processes using the same ports.
|
|
143
|
+
|
|
144
|
+
6. **Try global installation**: Instead of using a local path, you can try installing the server globally:
|
|
145
|
+
```bash
|
|
146
|
+
npm install -g n8n-workflow-builder-mcp
|
|
147
|
+
```
|
|
148
|
+
Then update the `.cursor/mcp.json` file to use the global command.
|
|
149
|
+
|
|
150
|
+
## Common Issues and Solutions
|
|
151
|
+
|
|
152
|
+
### "Failed to create client"
|
|
153
|
+
|
|
154
|
+
This usually happens when:
|
|
155
|
+
- The MCP server isn't running
|
|
156
|
+
- There's a connectivity issue between Cursor and the server
|
|
157
|
+
- The server crashed during initialization
|
|
158
|
+
|
|
159
|
+
Try:
|
|
160
|
+
1. Running the test script to make sure the server works correctly
|
|
161
|
+
2. Checking for errors in the server logs
|
|
162
|
+
3. Restarting Cursor
|
|
163
|
+
|
|
164
|
+
### MCP Server is not showing up in Cursor
|
|
165
|
+
|
|
166
|
+
This can happen if:
|
|
167
|
+
- The `.cursor/mcp.json` file is not properly formatted
|
|
168
|
+
- Cursor hasn't detected the configuration change
|
|
169
|
+
|
|
170
|
+
Try:
|
|
171
|
+
1. Validating the JSON format of your `.cursor/mcp.json` file
|
|
172
|
+
2. Restarting Cursor
|
|
173
|
+
3. Manually selecting the server in Cursor settings (if it appears there)
|
|
174
|
+
|
|
175
|
+
### MCP Server shows up but tools aren't available
|
|
176
|
+
|
|
177
|
+
This can happen if:
|
|
178
|
+
- The server isn't properly registering its tools
|
|
179
|
+
- There's an issue with the ListOfferings request/response
|
|
180
|
+
|
|
181
|
+
Try:
|
|
182
|
+
1. Running the test script to check if tools are properly registered
|
|
183
|
+
2. Clicking the refresh button in the MCP server settings in Cursor
|
|
184
|
+
3. Checking the server logs for any errors
|
|
185
|
+
|
|
186
|
+
## Project Structure
|
|
187
|
+
|
|
188
|
+
- `/src`: Main source code
|
|
189
|
+
- `/src/tools`: MCP tools implementation
|
|
190
|
+
- `/src/models`: Data models
|
|
191
|
+
- `/src/utils`: Utility functions
|
|
192
|
+
- `/src/middleware`: Authentication and middleware
|
|
193
|
+
- `/config`: Configuration files
|
|
194
|
+
- `/tests`: Test files
|
|
195
|
+
- `/workflow_nodes`: n8n node definitions
|
|
196
|
+
- `/docs`: Additional documentation
|
|
197
|
+
|
|
198
|
+
## Contributing
|
|
199
|
+
|
|
200
|
+
Contributions are welcome! Please feel free to submit a Pull Request.
|
|
201
|
+
|
|
202
|
+
1. Fork the repository
|
|
203
|
+
2. Create your feature branch (`git checkout -b feature/amazing-feature`)
|
|
204
|
+
3. Commit your changes (`git commit -m 'Add some amazing feature'`)
|
|
205
|
+
4. Push to the branch (`git push origin feature/amazing-feature`)
|
|
206
|
+
5. Open a Pull Request
|
|
207
|
+
|
|
208
|
+
## License
|
|
209
|
+
|
|
210
|
+
Working on licence - need to have confirmation from n8n team
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"credentials":{},"meta":{"version":"1.0","keyId":"v1"}}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
module.exports = {
|
|
2
|
+
server: {
|
|
3
|
+
port: process.env.PORT || 3000,
|
|
4
|
+
env: process.env.NODE_ENV || 'development',
|
|
5
|
+
},
|
|
6
|
+
n8n: {
|
|
7
|
+
apiUrl: process.env.N8N_API_URL || 'http://localhost:5678/api/',
|
|
8
|
+
apiKey: process.env.N8N_API_KEY,
|
|
9
|
+
workflowsPath: process.env.N8N_WORKFLOWS_PATH || './n8n-workflows',
|
|
10
|
+
integrationType: process.env.N8N_INTEGRATION_TYPE || 'auto', // 'api', 'filesystem', or 'auto'
|
|
11
|
+
},
|
|
12
|
+
auth: {
|
|
13
|
+
jwtSecret: process.env.JWT_SECRET || 'default-dev-secret',
|
|
14
|
+
jwtExpiresIn: process.env.JWT_EXPIRES_IN || '1d',
|
|
15
|
+
apiKeys: process.env.API_KEYS ? process.env.API_KEYS.split(',') : ['dev-api-key'],
|
|
16
|
+
encryptionKey: process.env.ENCRYPTION_KEY,
|
|
17
|
+
keyRotationInterval: parseInt(process.env.KEY_ROTATION_INTERVAL || '30', 10), // days
|
|
18
|
+
},
|
|
19
|
+
logging: {
|
|
20
|
+
level: process.env.LOG_LEVEL || 'info',
|
|
21
|
+
},
|
|
22
|
+
credentials: {
|
|
23
|
+
storageDir: process.env.CREDENTIALS_DIR || './config/credentials',
|
|
24
|
+
},
|
|
25
|
+
storage: {
|
|
26
|
+
workflowsPath: process.env.WORKFLOWS_PATH || './workflow_nodes',
|
|
27
|
+
versioning: {
|
|
28
|
+
enabled: process.env.ENABLE_VERSIONING !== 'false',
|
|
29
|
+
maxVersions: parseInt(process.env.MAX_VERSIONS || '10', 10),
|
|
30
|
+
},
|
|
31
|
+
},
|
|
32
|
+
llm: {
|
|
33
|
+
defaultProvider: process.env.LLM_DEFAULT_PROVIDER || 'openai',
|
|
34
|
+
openaiApiKey: process.env.OPENAI_API_KEY,
|
|
35
|
+
openaiModel: process.env.OPENAI_MODEL || 'gpt-4-turbo',
|
|
36
|
+
anthropicApiKey: process.env.ANTHROPIC_API_KEY,
|
|
37
|
+
anthropicModel: process.env.ANTHROPIC_MODEL || 'claude-3-opus-20240229',
|
|
38
|
+
temperature: parseFloat(process.env.LLM_TEMPERATURE || '0.2'),
|
|
39
|
+
maxTokens: parseInt(process.env.LLM_MAX_TOKENS || '2000', 10),
|
|
40
|
+
},
|
|
41
|
+
};
|
package/package.json
ADDED
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "n8n-workflow-builder-mcp",
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"description": "MCP server for building n8n workflows",
|
|
5
|
+
"main": "src/index.js",
|
|
6
|
+
"repository": {
|
|
7
|
+
"type": "git",
|
|
8
|
+
"url": "https://github.com/ifmelate/n8n-workflow-builder-mcp.git"
|
|
9
|
+
},
|
|
10
|
+
"scripts": {
|
|
11
|
+
"start": "node dist/index.js",
|
|
12
|
+
"dev": "nodemon --watch src --ext ts,json --exec \"npm run build && node dist/index.js\"",
|
|
13
|
+
"lint": "eslint .",
|
|
14
|
+
"format": "prettier --write .",
|
|
15
|
+
"test": "jest",
|
|
16
|
+
"test:langchain": "mocha tests/unit/langchain-llm-format.test.js",
|
|
17
|
+
"mcp": "node n8n-workflow-mcp.js",
|
|
18
|
+
"build": "tsc"
|
|
19
|
+
},
|
|
20
|
+
"keywords": [
|
|
21
|
+
"n8n",
|
|
22
|
+
"mcp",
|
|
23
|
+
"workflow",
|
|
24
|
+
"automation"
|
|
25
|
+
],
|
|
26
|
+
"author": "ifmelate",
|
|
27
|
+
"license": "MIT",
|
|
28
|
+
"dependencies": {
|
|
29
|
+
"@modelcontextprotocol/sdk": "^1.11.3",
|
|
30
|
+
"@types/uuid": "^10.0.0",
|
|
31
|
+
"abort-controller": "^3.0.0",
|
|
32
|
+
"ajv": "^8.12.0",
|
|
33
|
+
"ajv-formats": "^3.0.1",
|
|
34
|
+
"cors": "^2.8.5",
|
|
35
|
+
"dotenv": "^16.3.1",
|
|
36
|
+
"express": "^4.18.2",
|
|
37
|
+
"jsonwebtoken": "^9.0.2",
|
|
38
|
+
"morgan": "^1.10.0",
|
|
39
|
+
"node-fetch": "^2.6.7",
|
|
40
|
+
"uuid": "^9.0.1",
|
|
41
|
+
"winston": "^3.10.0",
|
|
42
|
+
"zod": "^3.24.4"
|
|
43
|
+
},
|
|
44
|
+
"devDependencies": {
|
|
45
|
+
"@types/node": "^20.0.0",
|
|
46
|
+
"chai": "^4.5.0",
|
|
47
|
+
"eslint": "^8.46.0",
|
|
48
|
+
"jest": "^29.6.2",
|
|
49
|
+
"mocha": "^10.8.2",
|
|
50
|
+
"nodemon": "^3.0.1",
|
|
51
|
+
"prettier": "^3.0.1",
|
|
52
|
+
"sinon": "^20.0.0",
|
|
53
|
+
"supertest": "^7.1.1",
|
|
54
|
+
"typescript": "^5.0.0"
|
|
55
|
+
}
|
|
56
|
+
}
|
|
@@ -0,0 +1,161 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* n8n Integration Demo Script
|
|
3
|
+
*
|
|
4
|
+
* This script demonstrates how to use the n8n integration module
|
|
5
|
+
* to deploy, activate, and manage workflows in n8n.
|
|
6
|
+
*
|
|
7
|
+
* Usage:
|
|
8
|
+
* node scripts/demo-n8n-integration.js
|
|
9
|
+
*/
|
|
10
|
+
|
|
11
|
+
require('dotenv').config();
|
|
12
|
+
const path = require('path');
|
|
13
|
+
const { n8nIntegration, getIntegrationType } = require('../src/models/n8nIntegration');
|
|
14
|
+
const { workflowStorage } = require('../src/models/storage');
|
|
15
|
+
|
|
16
|
+
// Sample workflow data
|
|
17
|
+
const sampleWorkflow = {
|
|
18
|
+
name: 'Sample API Request Workflow',
|
|
19
|
+
active: false,
|
|
20
|
+
nodes: [
|
|
21
|
+
{
|
|
22
|
+
parameters: {
|
|
23
|
+
url: 'https://jsonplaceholder.typicode.com/posts/1',
|
|
24
|
+
authentication: 'none',
|
|
25
|
+
method: 'GET',
|
|
26
|
+
options: {}
|
|
27
|
+
},
|
|
28
|
+
name: 'HTTP Request',
|
|
29
|
+
type: 'n8n-nodes-base.httpRequest',
|
|
30
|
+
typeVersion: 1,
|
|
31
|
+
position: [100, 100],
|
|
32
|
+
id: 'http-node-1'
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
parameters: {},
|
|
36
|
+
name: 'No Operation',
|
|
37
|
+
type: 'n8n-nodes-base.noOp',
|
|
38
|
+
typeVersion: 1,
|
|
39
|
+
position: [300, 100],
|
|
40
|
+
id: 'no-op-node-1'
|
|
41
|
+
}
|
|
42
|
+
],
|
|
43
|
+
connections: {
|
|
44
|
+
'http-node-1': {
|
|
45
|
+
main: [
|
|
46
|
+
[
|
|
47
|
+
{
|
|
48
|
+
node: 'no-op-node-1',
|
|
49
|
+
type: 'main',
|
|
50
|
+
index: 0
|
|
51
|
+
}
|
|
52
|
+
]
|
|
53
|
+
]
|
|
54
|
+
}
|
|
55
|
+
},
|
|
56
|
+
id: 'sample-workflow-' + Date.now(),
|
|
57
|
+
createdAt: new Date().toISOString(),
|
|
58
|
+
updatedAt: new Date().toISOString()
|
|
59
|
+
};
|
|
60
|
+
|
|
61
|
+
// File path for the workflow
|
|
62
|
+
const workflowPath = path.join(process.cwd(), 'workflow_nodes', `${sampleWorkflow.id}.json`);
|
|
63
|
+
|
|
64
|
+
// Demo function
|
|
65
|
+
async function runDemo() {
|
|
66
|
+
try {
|
|
67
|
+
console.log('n8n Integration Demo');
|
|
68
|
+
console.log('===================');
|
|
69
|
+
console.log(`Integration type: ${getIntegrationType()}`);
|
|
70
|
+
console.log('');
|
|
71
|
+
|
|
72
|
+
// 1. Save workflow to filesystem
|
|
73
|
+
console.log('1. Saving workflow to filesystem...');
|
|
74
|
+
await workflowStorage.saveWorkflow(
|
|
75
|
+
sampleWorkflow.id,
|
|
76
|
+
sampleWorkflow,
|
|
77
|
+
workflowPath
|
|
78
|
+
);
|
|
79
|
+
console.log(' Workflow saved to:', workflowPath);
|
|
80
|
+
console.log('');
|
|
81
|
+
|
|
82
|
+
// 2. Deploy workflow to n8n
|
|
83
|
+
console.log('2. Deploying workflow to n8n...');
|
|
84
|
+
try {
|
|
85
|
+
const deployResult = await n8nIntegration.deployWorkflow(workflowPath);
|
|
86
|
+
console.log(' Deployment result:', JSON.stringify(deployResult, null, 2));
|
|
87
|
+
} catch (error) {
|
|
88
|
+
console.error(' Deployment error:', error.message);
|
|
89
|
+
// Continue with demo even if deploy fails
|
|
90
|
+
}
|
|
91
|
+
console.log('');
|
|
92
|
+
|
|
93
|
+
// 3. List workflows in n8n
|
|
94
|
+
console.log('3. Listing workflows in n8n...');
|
|
95
|
+
try {
|
|
96
|
+
const listResult = await n8nIntegration.listWorkflows();
|
|
97
|
+
console.log(` Found ${listResult.count} workflows:`);
|
|
98
|
+
listResult.workflows.forEach(wf => {
|
|
99
|
+
console.log(` - ${wf.name} (ID: ${wf.id}, Active: ${wf.active})`);
|
|
100
|
+
});
|
|
101
|
+
} catch (error) {
|
|
102
|
+
console.error(' List error:', error.message);
|
|
103
|
+
}
|
|
104
|
+
console.log('');
|
|
105
|
+
|
|
106
|
+
// 4. Activate workflow
|
|
107
|
+
console.log('4. Activating workflow...');
|
|
108
|
+
try {
|
|
109
|
+
const activateResult = await n8nIntegration.activateWorkflow(workflowPath, true);
|
|
110
|
+
console.log(' Activation result:', JSON.stringify(activateResult, null, 2));
|
|
111
|
+
} catch (error) {
|
|
112
|
+
console.error(' Activation error:', error.message);
|
|
113
|
+
}
|
|
114
|
+
console.log('');
|
|
115
|
+
|
|
116
|
+
// 5. Check execution status (only works with API integration)
|
|
117
|
+
if (getIntegrationType() === 'api') {
|
|
118
|
+
console.log('5. Checking execution status...');
|
|
119
|
+
try {
|
|
120
|
+
// Wait a moment for possible execution
|
|
121
|
+
await new Promise(resolve => setTimeout(resolve, 2000));
|
|
122
|
+
|
|
123
|
+
const statusResult = await n8nIntegration.checkExecutionStatus(sampleWorkflow.id);
|
|
124
|
+
if (statusResult.hasExecutions) {
|
|
125
|
+
console.log(' Latest execution:', JSON.stringify(statusResult.latestExecution, null, 2));
|
|
126
|
+
} else {
|
|
127
|
+
console.log(' No executions found for this workflow.');
|
|
128
|
+
}
|
|
129
|
+
} catch (error) {
|
|
130
|
+
console.error(' Status check error:', error.message);
|
|
131
|
+
}
|
|
132
|
+
console.log('');
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
// 6. Deactivate workflow
|
|
136
|
+
console.log('6. Deactivating workflow...');
|
|
137
|
+
try {
|
|
138
|
+
const deactivateResult = await n8nIntegration.activateWorkflow(workflowPath, false);
|
|
139
|
+
console.log(' Deactivation result:', JSON.stringify(deactivateResult, null, 2));
|
|
140
|
+
} catch (error) {
|
|
141
|
+
console.error(' Deactivation error:', error.message);
|
|
142
|
+
}
|
|
143
|
+
console.log('');
|
|
144
|
+
|
|
145
|
+
console.log('Demo completed!');
|
|
146
|
+
console.log('');
|
|
147
|
+
console.log('Notes:');
|
|
148
|
+
console.log('- For API integration, ensure n8n is running with REST API enabled');
|
|
149
|
+
console.log('- Set N8N_API_URL and N8N_API_KEY in your .env file');
|
|
150
|
+
console.log('- For filesystem integration, set N8N_WORKFLOWS_PATH in your .env file');
|
|
151
|
+
console.log('- You can explicitly set N8N_INTEGRATION_TYPE to "api" or "filesystem"');
|
|
152
|
+
|
|
153
|
+
} catch (error) {
|
|
154
|
+
console.error('Demo failed:', error);
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
// Run the demo
|
|
159
|
+
runDemo().catch(error => {
|
|
160
|
+
console.error('Unhandled error in demo:', error);
|
|
161
|
+
});
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Workflow Generator Demo Script
|
|
3
|
+
*
|
|
4
|
+
* This script demonstrates how to use the workflow generator
|
|
5
|
+
* to create n8n workflows from natural language descriptions.
|
|
6
|
+
*
|
|
7
|
+
* Usage:
|
|
8
|
+
* node scripts/demo-workflow-generator.js
|
|
9
|
+
*/
|
|
10
|
+
|
|
11
|
+
require('dotenv').config();
|
|
12
|
+
const fs = require('fs').promises;
|
|
13
|
+
const path = require('path');
|
|
14
|
+
const { generateWorkflow } = require('../src/models/llmService');
|
|
15
|
+
|
|
16
|
+
// Example workflow descriptions
|
|
17
|
+
const workflowDescriptions = [
|
|
18
|
+
{
|
|
19
|
+
name: 'API Data Fetcher',
|
|
20
|
+
description: 'Create a workflow that fetches data from a REST API every hour, ' +
|
|
21
|
+
'processes the JSON response to extract user information, and saves it to a CSV file.'
|
|
22
|
+
},
|
|
23
|
+
{
|
|
24
|
+
name: 'Email Notification System',
|
|
25
|
+
description: 'Build a workflow that monitors a folder for new files, and when a new file ' +
|
|
26
|
+
'is detected, sends an email notification with the file name and a summary of its contents.'
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
name: 'Data Transformation Pipeline',
|
|
30
|
+
description: 'Create a workflow that takes CSV data, transforms it by cleaning empty fields, ' +
|
|
31
|
+
'standardizing date formats, and calculating a new "total" column, then outputs the processed data.'
|
|
32
|
+
}
|
|
33
|
+
];
|
|
34
|
+
|
|
35
|
+
// Demo function
|
|
36
|
+
async function runDemo() {
|
|
37
|
+
try {
|
|
38
|
+
console.log('Workflow Generator Demo');
|
|
39
|
+
console.log('=======================');
|
|
40
|
+
console.log('This demo shows how natural language descriptions can be converted to n8n workflows\n');
|
|
41
|
+
|
|
42
|
+
// Create output directory if it doesn't exist
|
|
43
|
+
const outputDir = path.join(process.cwd(), 'generated-workflows');
|
|
44
|
+
await fs.mkdir(outputDir, { recursive: true });
|
|
45
|
+
console.log(`Output directory: ${outputDir}\n`);
|
|
46
|
+
|
|
47
|
+
// Select a workflow to generate
|
|
48
|
+
const workflowIndex = 0; // Change this to try different examples
|
|
49
|
+
const selectedWorkflow = workflowDescriptions[workflowIndex];
|
|
50
|
+
|
|
51
|
+
console.log(`Generating workflow: ${selectedWorkflow.name}`);
|
|
52
|
+
console.log(`Description: ${selectedWorkflow.description}\n`);
|
|
53
|
+
console.log('Processing...\n');
|
|
54
|
+
|
|
55
|
+
// Generate the workflow
|
|
56
|
+
const result = await generateWorkflow(selectedWorkflow.description);
|
|
57
|
+
|
|
58
|
+
// Create a complete workflow object
|
|
59
|
+
const workflow = {
|
|
60
|
+
name: selectedWorkflow.name,
|
|
61
|
+
active: false,
|
|
62
|
+
nodes: result.nodes,
|
|
63
|
+
connections: result.connections,
|
|
64
|
+
settings: {
|
|
65
|
+
executionOrder: 'v1',
|
|
66
|
+
saveExecutionProgress: true,
|
|
67
|
+
saveManualExecutions: true,
|
|
68
|
+
saveDataErrorExecution: 'all',
|
|
69
|
+
saveDataSuccessExecution: 'all',
|
|
70
|
+
callerPolicy: 'workflowsFromSameOwner',
|
|
71
|
+
errorWorkflow: ''
|
|
72
|
+
},
|
|
73
|
+
tags: [{ name: 'Generated' }],
|
|
74
|
+
pinData: {},
|
|
75
|
+
id: `demo-workflow-${Date.now()}`,
|
|
76
|
+
createdAt: new Date().toISOString(),
|
|
77
|
+
updatedAt: new Date().toISOString()
|
|
78
|
+
};
|
|
79
|
+
|
|
80
|
+
// Save to file
|
|
81
|
+
const outputPath = path.join(outputDir, `${workflow.name.replace(/[^a-z0-9]/gi, '_').toLowerCase()}.json`);
|
|
82
|
+
await fs.writeFile(outputPath, JSON.stringify(workflow, null, 2));
|
|
83
|
+
|
|
84
|
+
console.log('Workflow generated successfully!');
|
|
85
|
+
console.log(`Saved to: ${outputPath}`);
|
|
86
|
+
console.log(`Contains ${workflow.nodes.length} nodes\n`);
|
|
87
|
+
|
|
88
|
+
console.log('Next steps:');
|
|
89
|
+
console.log('1. Copy the workflow JSON file');
|
|
90
|
+
console.log('2. Import it into n8n through the Import from File option');
|
|
91
|
+
console.log('3. Customize any specific parameters as needed');
|
|
92
|
+
console.log('4. Activate and run your workflow!');
|
|
93
|
+
|
|
94
|
+
} catch (error) {
|
|
95
|
+
console.error('Demo failed:', error);
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
// Run the demo
|
|
100
|
+
runDemo().catch(error => {
|
|
101
|
+
console.error('Unhandled error in demo:', error);
|
|
102
|
+
});
|
package/scripts/init.sh
ADDED
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
#!/bin/bash
|
|
2
|
+
|
|
3
|
+
# Initialize n8n-workflow-builder-mcp project
|
|
4
|
+
|
|
5
|
+
# Create necessary directories
|
|
6
|
+
echo "Creating project directories..."
|
|
7
|
+
mkdir -p logs
|
|
8
|
+
mkdir -p src/tools
|
|
9
|
+
mkdir -p src/models
|
|
10
|
+
mkdir -p src/utils
|
|
11
|
+
mkdir -p src/middleware
|
|
12
|
+
mkdir -p config
|
|
13
|
+
mkdir -p tests
|
|
14
|
+
|
|
15
|
+
# Check if package.json exists
|
|
16
|
+
if [ ! -f package.json ]; then
|
|
17
|
+
echo "Creating package.json..."
|
|
18
|
+
npm init -y
|
|
19
|
+
fi
|
|
20
|
+
|
|
21
|
+
# Install dependencies
|
|
22
|
+
echo "Installing dependencies..."
|
|
23
|
+
npm install express cors dotenv ajv winston morgan
|
|
24
|
+
|
|
25
|
+
# Install dev dependencies
|
|
26
|
+
echo "Installing development dependencies..."
|
|
27
|
+
npm install --save-dev eslint prettier nodemon jest
|
|
28
|
+
|
|
29
|
+
# Create .env if it doesn't exist
|
|
30
|
+
if [ ! -f .env ]; then
|
|
31
|
+
echo "Creating .env file from example..."
|
|
32
|
+
cp .env.example .env || echo "# Server Configuration\nPORT=3000\nNODE_ENV=development\nLOG_LEVEL=info\n\n# n8n API Configuration\nN8N_API_URL=http://localhost:5678/api/\nN8N_API_KEY=your_n8n_api_key_here" > .env
|
|
33
|
+
fi
|
|
34
|
+
|
|
35
|
+
echo "Project initialized successfully!"
|
|
36
|
+
echo "Run 'npm run dev' to start the development server."
|