feat: add folder support for workflows (fixes #70)
This commit is contained in:
@@ -0,0 +1,380 @@
|
||||
{
|
||||
"id": "A4hqQNFLymCRKnYK",
|
||||
"meta": {
|
||||
"instanceId": "5a64ae2dac98d415b280f5a86dd824858150b2ae6e4b41f2e62e7315042262b3",
|
||||
"templateCredsSetupCompleted": true
|
||||
},
|
||||
"name": "Discord Agent",
|
||||
"tags": [],
|
||||
"nodes": [
|
||||
{
|
||||
"id": "b0f78e4d-e6f9-496c-a9d1-f2ec17612770",
|
||||
"name": "When Executed by Another Workflow",
|
||||
"type": "n8n-nodes-base.executeWorkflowTrigger",
|
||||
"position": [
|
||||
80,
|
||||
60
|
||||
],
|
||||
"parameters": {
|
||||
"workflowInputs": {
|
||||
"values": [
|
||||
{
|
||||
"name": "Task"
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
"typeVersion": 1.1
|
||||
},
|
||||
{
|
||||
"id": "3e185fb3-0b5f-4ba6-b382-c332cefa727e",
|
||||
"name": "AI Agent",
|
||||
"type": "@n8n/n8n-nodes-langchain.agent",
|
||||
"position": [
|
||||
380,
|
||||
120
|
||||
],
|
||||
"parameters": {
|
||||
"text": "={{ $json.Task }}{{ $json.chatInput }}",
|
||||
"options": {
|
||||
"systemMessage": "You are a helpful assistant In Charge OF managing Discord always use channel id to reference channels. Always convert and output text in stylish discord formats. Reduce Text To 1800 characters Max.\n\nBefore sending any message absolutely ensure it is less than 1800 characters\n\nYou can Use One tool to send to free guides channel and another for ai-tools channel. make sure to read tool descriptions"
|
||||
},
|
||||
"promptType": "define"
|
||||
},
|
||||
"typeVersion": 1.7
|
||||
},
|
||||
{
|
||||
"id": "1aa1b4df-71af-4b85-9a6e-b371a2349598",
|
||||
"name": "OpenAI Chat Model",
|
||||
"type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
|
||||
"position": [
|
||||
380,
|
||||
280
|
||||
],
|
||||
"parameters": {
|
||||
"model": {
|
||||
"__rl": true,
|
||||
"mode": "list",
|
||||
"value": "gpt-4o-mini"
|
||||
},
|
||||
"options": {}
|
||||
},
|
||||
"credentials": {
|
||||
"openAiApi": {
|
||||
"id": "F4px3oxuWY5zBrvn",
|
||||
"name": "OpenAi account"
|
||||
}
|
||||
},
|
||||
"typeVersion": 1.2
|
||||
},
|
||||
{
|
||||
"id": "d6f59c6e-3bc0-4e85-8b89-b1a480db5317",
|
||||
"name": "When chat message received",
|
||||
"type": "@n8n/n8n-nodes-langchain.chatTrigger",
|
||||
"position": [
|
||||
80,
|
||||
240
|
||||
],
|
||||
"webhookId": "913628ac-d409-49fa-8a34-a11349a30da6",
|
||||
"parameters": {
|
||||
"options": {}
|
||||
},
|
||||
"typeVersion": 1.1
|
||||
},
|
||||
{
|
||||
"id": "f0aa9420-0207-4f6b-a659-ef89104e4925",
|
||||
"name": "Window Buffer Memory",
|
||||
"type": "@n8n/n8n-nodes-langchain.memoryBufferWindow",
|
||||
"position": [
|
||||
540,
|
||||
280
|
||||
],
|
||||
"parameters": {
|
||||
"sessionKey": "={{ $json.Task }}",
|
||||
"sessionIdType": "customKey"
|
||||
},
|
||||
"typeVersion": 1.3
|
||||
},
|
||||
{
|
||||
"id": "6b77b8f1-8fd2-4b0b-8993-3567d03b8b9b",
|
||||
"name": "Sticky Note",
|
||||
"type": "n8n-nodes-base.stickyNote",
|
||||
"position": [
|
||||
780,
|
||||
320
|
||||
],
|
||||
"parameters": {
|
||||
"color": 4,
|
||||
"width": 460,
|
||||
"height": 260,
|
||||
"content": "## Discord Management Tools"
|
||||
},
|
||||
"typeVersion": 1
|
||||
},
|
||||
{
|
||||
"id": "8947bfd3-88ed-48e5-a07f-c012cc3202c6",
|
||||
"name": "Sticky Note2",
|
||||
"type": "n8n-nodes-base.stickyNote",
|
||||
"position": [
|
||||
340,
|
||||
40
|
||||
],
|
||||
"parameters": {
|
||||
"color": 5,
|
||||
"width": 360,
|
||||
"height": 380,
|
||||
"content": "## Main Discord Manager Agent"
|
||||
},
|
||||
"typeVersion": 1
|
||||
},
|
||||
{
|
||||
"id": "7fb0e4b2-5e66-4b3a-a976-926a4427f3c5",
|
||||
"name": "Sticky Note1",
|
||||
"type": "n8n-nodes-base.stickyNote",
|
||||
"position": [
|
||||
0,
|
||||
0
|
||||
],
|
||||
"parameters": {
|
||||
"color": 3,
|
||||
"width": 260,
|
||||
"height": 400,
|
||||
"content": "## Trigger Automation "
|
||||
},
|
||||
"typeVersion": 1
|
||||
},
|
||||
{
|
||||
"id": "d100828e-6877-427d-ab8c-8486970b17e6",
|
||||
"name": "Discord",
|
||||
"type": "n8n-nodes-base.discordTool",
|
||||
"position": [
|
||||
960,
|
||||
420
|
||||
],
|
||||
"webhookId": "aa558762-c5da-491d-9881-1a091632864f",
|
||||
"parameters": {
|
||||
"sendTo": "=channel",
|
||||
"userId": {
|
||||
"__rl": true,
|
||||
"mode": "list",
|
||||
"value": ""
|
||||
},
|
||||
"content": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Message', ``, 'string') }}",
|
||||
"guildId": {
|
||||
"__rl": true,
|
||||
"mode": "list",
|
||||
"value": "1236784625196601386",
|
||||
"cachedResultUrl": "https://discord.com/channels/1236784625196601386",
|
||||
"cachedResultName": "YungCEO SOCIETY💰"
|
||||
},
|
||||
"options": {},
|
||||
"resource": "message",
|
||||
"channelId": {
|
||||
"__rl": true,
|
||||
"mode": "list",
|
||||
"value": "1352547978308485192",
|
||||
"cachedResultUrl": "https://discord.com/channels/1236784625196601386/1352547978308485192",
|
||||
"cachedResultName": "ai-tools"
|
||||
},
|
||||
"descriptionType": "manual",
|
||||
"toolDescription": "Use this tool to post a message in ai-tools discord channel"
|
||||
},
|
||||
"credentials": {
|
||||
"discordBotApi": {
|
||||
"id": "ENuG6EzBN712IDLU",
|
||||
"name": "Motion Assistant"
|
||||
}
|
||||
},
|
||||
"typeVersion": 2
|
||||
},
|
||||
{
|
||||
"id": "d6dc1210-4049-4fa6-9896-67e8353db922",
|
||||
"name": "Discord1",
|
||||
"type": "n8n-nodes-base.discordTool",
|
||||
"position": [
|
||||
1080,
|
||||
420
|
||||
],
|
||||
"webhookId": "7e07794e-e474-46c8-a23c-e9440a61d87b",
|
||||
"parameters": {
|
||||
"guildId": {
|
||||
"__rl": true,
|
||||
"mode": "list",
|
||||
"value": "1236784625196601386",
|
||||
"cachedResultUrl": "https://discord.com/channels/1236784625196601386",
|
||||
"cachedResultName": "YungCEO SOCIETY💰"
|
||||
},
|
||||
"options": {},
|
||||
"operation": "getAll",
|
||||
"returnAll": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Return_All', ``, 'boolean') }}"
|
||||
},
|
||||
"credentials": {
|
||||
"discordBotApi": {
|
||||
"id": "ENuG6EzBN712IDLU",
|
||||
"name": "Motion Assistant"
|
||||
}
|
||||
},
|
||||
"typeVersion": 2
|
||||
},
|
||||
{
|
||||
"id": "1908e48f-51a7-4d42-a543-622a28c22136",
|
||||
"name": "Discord2",
|
||||
"type": "n8n-nodes-base.discordTool",
|
||||
"position": [
|
||||
820,
|
||||
420
|
||||
],
|
||||
"webhookId": "aa558762-c5da-491d-9881-1a091632864f",
|
||||
"parameters": {
|
||||
"sendTo": "=channel",
|
||||
"userId": {
|
||||
"__rl": true,
|
||||
"mode": "list",
|
||||
"value": ""
|
||||
},
|
||||
"content": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Message', ``, 'string') }}",
|
||||
"guildId": {
|
||||
"__rl": true,
|
||||
"mode": "list",
|
||||
"value": "1236784625196601386",
|
||||
"cachedResultUrl": "https://discord.com/channels/1236784625196601386",
|
||||
"cachedResultName": "YungCEO SOCIETY💰"
|
||||
},
|
||||
"options": {},
|
||||
"resource": "message",
|
||||
"channelId": {
|
||||
"__rl": true,
|
||||
"mode": "list",
|
||||
"value": "1352242462520901632",
|
||||
"cachedResultUrl": "https://discord.com/channels/1236784625196601386/1352242462520901632",
|
||||
"cachedResultName": "free-guides"
|
||||
},
|
||||
"descriptionType": "manual",
|
||||
"toolDescription": "Use this tool to post a message in free-guides discord channel"
|
||||
},
|
||||
"credentials": {
|
||||
"discordBotApi": {
|
||||
"id": "ENuG6EzBN712IDLU",
|
||||
"name": "Motion Assistant"
|
||||
}
|
||||
},
|
||||
"typeVersion": 2
|
||||
},
|
||||
{
|
||||
"id": "557189d6-d5f3-4059-b349-9c3a9b642083",
|
||||
"name": "Sticky Note3",
|
||||
"type": "n8n-nodes-base.stickyNote",
|
||||
"position": [
|
||||
-1000,
|
||||
-1300
|
||||
],
|
||||
"parameters": {
|
||||
"color": 4,
|
||||
"width": 1340,
|
||||
"height": 1220,
|
||||
"content": "# N8N Discord Workflow Setup Guide\n\n## Prerequisites\n- N8N account\n- Discord bot\n- OpenAI API key\n- Discord server access\n\n## 1. Discord Bot Creation\n### Steps\n- Open Discord Developer Portal\n- Create new application\n- Generate bot token\n- Add bot to server\n- Set permissions:\n - Send Messages\n - Read Message History\n - View Channels\n\n### Required Info\n- Guild (Server) ID\n- Channel IDs:\n - AI Tools Channel\n - Free Guides Channel\n\n## 2. Credential Configuration\n### Discord Bot Credentials\n- Go to N8N Credentials section\n- Create 'Discord Bot API' credential\n- Enter bot token\n- Name credential (e.g., 'Motion Assistant')\n\n### OpenAI Credentials\n- Create 'OpenAI API' credential\n- Enter API key\n- Name credential (e.g., 'OpenAI Account')\n\n## 3. Workflow Setup\n### AI Agent Configuration\n- Customize system message\n- Define character limits\n- Specify output format\n\n### Trigger Types\n1. Workflow Execution Trigger\n2. Direct Chat Message Trigger\n\n"
|
||||
},
|
||||
"typeVersion": 1
|
||||
},
|
||||
{
|
||||
"id": "9b554c72-cb38-43d8-abcf-1bf48ee4fcec",
|
||||
"name": "Sticky Note4",
|
||||
"type": "n8n-nodes-base.stickyNote",
|
||||
"position": [
|
||||
420,
|
||||
-1200
|
||||
],
|
||||
"parameters": {
|
||||
"width": 1200,
|
||||
"height": 880,
|
||||
"content": "## Workflow Operation Modes\n### Mode 1: Workflow Trigger\n- Execute from another workflow\n- Input: Task/message string\n- Use cases:\n - Automated messaging\n - Scheduled updates\n - External event triggers\n\n### Mode 2: Chat Trigger\n- Webhook-based activation\n- Process flow:\n 1. Receive message\n 2. AI Agent processing\n 3. Generate response\n 4. Maintain context\n\n## Customization Points\n- Modify AI system message\n- Adjust character limits\n- Configure channel interactions\n- Select OpenAI model\n\n## Potential Enhancements\n- Error handling\n- Advanced conversation memory\n- Additional channel tools\n- Message filtering\n\n## Troubleshooting\n- Verify bot permissions\n- Check API credentials\n- Validate character limits\n- Confirm channel IDs"
|
||||
},
|
||||
"typeVersion": 1
|
||||
}
|
||||
],
|
||||
"active": false,
|
||||
"pinData": {},
|
||||
"settings": {
|
||||
"executionOrder": "v1"
|
||||
},
|
||||
"versionId": "8a8376c5-04e5-42da-9031-a9be0a34c211",
|
||||
"connections": {
|
||||
"Discord": {
|
||||
"ai_tool": [
|
||||
[
|
||||
{
|
||||
"node": "AI Agent",
|
||||
"type": "ai_tool",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"Discord1": {
|
||||
"ai_tool": [
|
||||
[
|
||||
{
|
||||
"node": "AI Agent",
|
||||
"type": "ai_tool",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"Discord2": {
|
||||
"ai_tool": [
|
||||
[
|
||||
{
|
||||
"node": "AI Agent",
|
||||
"type": "ai_tool",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"OpenAI Chat Model": {
|
||||
"ai_languageModel": [
|
||||
[
|
||||
{
|
||||
"node": "AI Agent",
|
||||
"type": "ai_languageModel",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"Window Buffer Memory": {
|
||||
"ai_memory": [
|
||||
[
|
||||
{
|
||||
"node": "AI Agent",
|
||||
"type": "ai_memory",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"When chat message received": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "AI Agent",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"When Executed by Another Workflow": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "AI Agent",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,495 @@
|
||||
{
|
||||
"id": "ly8aZhPk5ZI8uB0Y",
|
||||
"meta": {
|
||||
"instanceId": "8931e7db592c2960ce253801ea290c1dc66e447734ce3d968310365665cefc80",
|
||||
"templateCredsSetupCompleted": true
|
||||
},
|
||||
"name": "Discord MCP Server",
|
||||
"tags": [],
|
||||
"nodes": [
|
||||
{
|
||||
"id": "6e87d612-3006-4683-b978-87718f89257d",
|
||||
"name": "Send Discord Message to Channel",
|
||||
"type": "n8n-nodes-base.discordTool",
|
||||
"position": [
|
||||
360,
|
||||
280
|
||||
],
|
||||
"webhookId": "90b1dca9-c742-4c7e-aef3-ba5a47c5f86d",
|
||||
"parameters": {
|
||||
"content": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Message', ``, 'string') }}",
|
||||
"guildId": {
|
||||
"__rl": true,
|
||||
"mode": "id",
|
||||
"value": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Server', ``, 'string') }}"
|
||||
},
|
||||
"options": {},
|
||||
"resource": "message",
|
||||
"channelId": {
|
||||
"__rl": true,
|
||||
"mode": "id",
|
||||
"value": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Channel', ``, 'string') }}"
|
||||
}
|
||||
},
|
||||
"credentials": {
|
||||
"discordBotApi": {
|
||||
"id": "SJhr2V3Xw4B3fVqW",
|
||||
"name": "Gopher"
|
||||
}
|
||||
},
|
||||
"typeVersion": 2
|
||||
},
|
||||
{
|
||||
"id": "32a17a73-8953-4474-a49f-9d1cc0cc3eb2",
|
||||
"name": "Add Role To Member",
|
||||
"type": "n8n-nodes-base.discordTool",
|
||||
"position": [
|
||||
-200,
|
||||
560
|
||||
],
|
||||
"webhookId": "e41a85ec-3f16-44fc-ad87-4617c0d0f1c0",
|
||||
"parameters": {
|
||||
"role": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Role', ``, 'string') }}",
|
||||
"userId": {
|
||||
"__rl": true,
|
||||
"mode": "id",
|
||||
"value": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('User', ``, 'string') }}"
|
||||
},
|
||||
"guildId": {
|
||||
"__rl": true,
|
||||
"mode": "id",
|
||||
"value": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Server', ``, 'string') }}"
|
||||
},
|
||||
"resource": "member",
|
||||
"operation": "roleAdd"
|
||||
},
|
||||
"credentials": {
|
||||
"discordBotApi": {
|
||||
"id": "SJhr2V3Xw4B3fVqW",
|
||||
"name": "Gopher"
|
||||
}
|
||||
},
|
||||
"typeVersion": 2
|
||||
},
|
||||
{
|
||||
"id": "688ea823-b8ea-4bbf-96cb-a64925fc29a9",
|
||||
"name": "Remove Role from member",
|
||||
"type": "n8n-nodes-base.discordTool",
|
||||
"position": [
|
||||
-20,
|
||||
560
|
||||
],
|
||||
"webhookId": "e41a85ec-3f16-44fc-ad87-4617c0d0f1c0",
|
||||
"parameters": {
|
||||
"role": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Role', ``, 'string') }}",
|
||||
"userId": {
|
||||
"__rl": true,
|
||||
"mode": "id",
|
||||
"value": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('User', ``, 'string') }}"
|
||||
},
|
||||
"guildId": {
|
||||
"__rl": true,
|
||||
"mode": "id",
|
||||
"value": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Server', ``, 'string') }}"
|
||||
},
|
||||
"resource": "member",
|
||||
"operation": "roleRemove"
|
||||
},
|
||||
"credentials": {
|
||||
"discordBotApi": {
|
||||
"id": "SJhr2V3Xw4B3fVqW",
|
||||
"name": "Gopher"
|
||||
}
|
||||
},
|
||||
"typeVersion": 2
|
||||
},
|
||||
{
|
||||
"id": "1d8a14f1-8e63-4112-8076-15b4408c844f",
|
||||
"name": "Discord MCP Server Trigger",
|
||||
"type": "@n8n/n8n-nodes-langchain.mcpTrigger",
|
||||
"position": [
|
||||
20,
|
||||
-280
|
||||
],
|
||||
"webhookId": "404f083e-f3f4-4358-83ef-9804099ee253",
|
||||
"parameters": {
|
||||
"path": "404f083e-f3f4-4358-83ef-9804099ee253"
|
||||
},
|
||||
"typeVersion": 1
|
||||
},
|
||||
{
|
||||
"id": "67602807-3126-4564-8fed-912551eb824b",
|
||||
"name": "Get channels of server by server ID",
|
||||
"type": "n8n-nodes-base.discordTool",
|
||||
"position": [
|
||||
420,
|
||||
20
|
||||
],
|
||||
"webhookId": "73c49e13-24e9-4481-902d-a5f3e1f50032",
|
||||
"parameters": {
|
||||
"guildId": {
|
||||
"__rl": true,
|
||||
"mode": "id",
|
||||
"value": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Server', ``, 'string') }}"
|
||||
},
|
||||
"options": {},
|
||||
"operation": "getAll",
|
||||
"returnAll": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Return_All', ``, 'boolean') }}"
|
||||
},
|
||||
"credentials": {
|
||||
"discordBotApi": {
|
||||
"id": "SJhr2V3Xw4B3fVqW",
|
||||
"name": "Gopher"
|
||||
}
|
||||
},
|
||||
"typeVersion": 2
|
||||
},
|
||||
{
|
||||
"id": "5f1c3039-7042-48b8-997c-12bcaa6a1256",
|
||||
"name": "Get members of server by server ID",
|
||||
"type": "n8n-nodes-base.discordTool",
|
||||
"position": [
|
||||
-80,
|
||||
20
|
||||
],
|
||||
"webhookId": "ebd6d7dd-bcfa-4546-b48d-5e7862129caa",
|
||||
"parameters": {
|
||||
"after": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('After', ``, 'string') }}",
|
||||
"guildId": {
|
||||
"__rl": true,
|
||||
"mode": "id",
|
||||
"value": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Server', ``, 'string') }}"
|
||||
},
|
||||
"options": {},
|
||||
"resource": "member",
|
||||
"returnAll": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Return_All', ``, 'boolean') }}"
|
||||
},
|
||||
"credentials": {
|
||||
"discordBotApi": {
|
||||
"id": "SJhr2V3Xw4B3fVqW",
|
||||
"name": "Gopher"
|
||||
}
|
||||
},
|
||||
"typeVersion": 2
|
||||
},
|
||||
{
|
||||
"id": "ece7a065-36bb-4667-aa61-610e54f0b22d",
|
||||
"name": "Send DM and Wait for reply",
|
||||
"type": "n8n-nodes-base.discordTool",
|
||||
"position": [
|
||||
-280,
|
||||
280
|
||||
],
|
||||
"webhookId": "90b1dca9-c742-4c7e-aef3-ba5a47c5f86d",
|
||||
"parameters": {
|
||||
"sendTo": "user",
|
||||
"userId": {
|
||||
"__rl": true,
|
||||
"mode": "id",
|
||||
"value": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('User', ``, 'string') }}"
|
||||
},
|
||||
"guildId": {
|
||||
"__rl": true,
|
||||
"mode": "id",
|
||||
"value": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Server', ``, 'string') }}"
|
||||
},
|
||||
"message": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Message', ``, 'string') }}",
|
||||
"options": {},
|
||||
"resource": "message",
|
||||
"operation": "sendAndWait",
|
||||
"responseType": "freeText"
|
||||
},
|
||||
"credentials": {
|
||||
"discordBotApi": {
|
||||
"id": "SJhr2V3Xw4B3fVqW",
|
||||
"name": "Gopher"
|
||||
}
|
||||
},
|
||||
"typeVersion": 2
|
||||
},
|
||||
{
|
||||
"id": "c37d0478-5b00-4d21-b0fd-7e2fa34708ec",
|
||||
"name": "Send to Channel and Wait for Reply",
|
||||
"type": "n8n-nodes-base.discordTool",
|
||||
"position": [
|
||||
580,
|
||||
280
|
||||
],
|
||||
"webhookId": "90b1dca9-c742-4c7e-aef3-ba5a47c5f86d",
|
||||
"parameters": {
|
||||
"guildId": {
|
||||
"__rl": true,
|
||||
"mode": "id",
|
||||
"value": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Server', ``, 'string') }}"
|
||||
},
|
||||
"message": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Message', ``, 'string') }}",
|
||||
"options": {},
|
||||
"resource": "message",
|
||||
"channelId": {
|
||||
"__rl": true,
|
||||
"mode": "id",
|
||||
"value": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Channel', ``, 'string') }}"
|
||||
},
|
||||
"operation": "sendAndWait",
|
||||
"responseType": "freeText"
|
||||
},
|
||||
"credentials": {
|
||||
"discordBotApi": {
|
||||
"id": "SJhr2V3Xw4B3fVqW",
|
||||
"name": "Gopher"
|
||||
}
|
||||
},
|
||||
"typeVersion": 2
|
||||
},
|
||||
{
|
||||
"id": "fb8091b5-114b-422e-be5a-6413d9aec599",
|
||||
"name": "Send DM to User",
|
||||
"type": "n8n-nodes-base.discordTool",
|
||||
"position": [
|
||||
-60,
|
||||
280
|
||||
],
|
||||
"webhookId": "90b1dca9-c742-4c7e-aef3-ba5a47c5f86d",
|
||||
"parameters": {
|
||||
"sendTo": "user",
|
||||
"userId": {
|
||||
"__rl": true,
|
||||
"mode": "id",
|
||||
"value": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('User', ``, 'string') }}"
|
||||
},
|
||||
"content": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Message', ``, 'string') }}",
|
||||
"guildId": {
|
||||
"__rl": true,
|
||||
"mode": "id",
|
||||
"value": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Server', ``, 'string') }}"
|
||||
},
|
||||
"options": {},
|
||||
"resource": "message"
|
||||
},
|
||||
"credentials": {
|
||||
"discordBotApi": {
|
||||
"id": "SJhr2V3Xw4B3fVqW",
|
||||
"name": "Gopher"
|
||||
}
|
||||
},
|
||||
"typeVersion": 2
|
||||
},
|
||||
{
|
||||
"id": "6f61b18a-8d96-4acb-994a-45ef32c10f16",
|
||||
"name": "Get Discord Server IDs",
|
||||
"type": "n8n-nodes-base.httpRequestTool",
|
||||
"position": [
|
||||
180,
|
||||
-60
|
||||
],
|
||||
"parameters": {
|
||||
"url": "https://discord.com/api/v10/users/@me/guilds",
|
||||
"options": {},
|
||||
"authentication": "predefinedCredentialType",
|
||||
"toolDescription": "Retrieves the ID of each discord server the bot is in.",
|
||||
"nodeCredentialType": "discordBotApi"
|
||||
},
|
||||
"credentials": {
|
||||
"discordBotApi": {
|
||||
"id": "SJhr2V3Xw4B3fVqW",
|
||||
"name": "Gopher"
|
||||
}
|
||||
},
|
||||
"typeVersion": 4.2
|
||||
},
|
||||
{
|
||||
"id": "3fe9b9ab-d9c8-4414-b3a4-01dace75da77",
|
||||
"name": "Sticky Note",
|
||||
"type": "n8n-nodes-base.stickyNote",
|
||||
"position": [
|
||||
100,
|
||||
-60
|
||||
],
|
||||
"parameters": {
|
||||
"height": 600,
|
||||
"content": "\n\n\n\n\n\n\n\n\n\n\n\nThis gets all of the servers that your discord bot is currently in. If you have a bot in more than one server, you will need to let it know or at least hint at which server it is, or it may get stuck. If you specify a channel through your natural language request, then the model may keep trying to get servers' channels via the get channel node or it may give up before getting to the right one).\n\nNote: This is a custom API call using the same Discord bot auth, not a built-in \"Discord tool\" - I encourage you to go well beyond the 15 included tools that n8n provides for you. It is *easy* to do, and there are, literally, no limits to what you can do with n8n!"
|
||||
},
|
||||
"typeVersion": 1
|
||||
},
|
||||
{
|
||||
"id": "c886422d-f034-49dc-ad77-bc6e1cd495a8",
|
||||
"name": "Sticky Note1",
|
||||
"type": "n8n-nodes-base.stickyNote",
|
||||
"position": [
|
||||
360,
|
||||
280
|
||||
],
|
||||
"parameters": {
|
||||
"width": 300,
|
||||
"height": 240,
|
||||
"content": "\n\n\n\n\n\n\n\n\n\n\n\nThese nodes either send a basic message from your bot to a channel or sends a message and waits for a response from a human (HITL)."
|
||||
},
|
||||
"typeVersion": 1
|
||||
},
|
||||
{
|
||||
"id": "36d5bcc3-f9f2-4161-83d8-d76083ea9e8c",
|
||||
"name": "Sticky Note2",
|
||||
"type": "n8n-nodes-base.stickyNote",
|
||||
"position": [
|
||||
-280,
|
||||
280
|
||||
],
|
||||
"parameters": {
|
||||
"width": 300,
|
||||
"height": 240,
|
||||
"content": "\n\n\n\n\n\n\n\n\n\n\n\nThese nodes either send a basic message from your bot to a user via DM or sends a DM and waits for a response from the human (HITL)."
|
||||
},
|
||||
"typeVersion": 1
|
||||
},
|
||||
{
|
||||
"id": "65b6d13e-6f97-4b4c-9a0d-85b07b666c81",
|
||||
"name": "Sticky Note3",
|
||||
"type": "n8n-nodes-base.stickyNote",
|
||||
"position": [
|
||||
-200,
|
||||
560
|
||||
],
|
||||
"parameters": {
|
||||
"width": 520,
|
||||
"height": 360,
|
||||
"content": "\n\n\n\n\n\n\n\n\n\n\n\nProgrammatic role addition and removal are just two examples of the many, many tools/API calls that you can make to Discord.\n\nYou could monitor for spam, mod abuse, or anything else you wanted and respond automatically by removing perms until you can check it out.\n\nYou can create amazing workflows that include discord webhooks, your existing other workflows, or anything else you can imagine and have it running on your bot in minutes via a MCP client node in a new or existing workflow!"
|
||||
},
|
||||
"typeVersion": 1
|
||||
},
|
||||
{
|
||||
"id": "e39211f7-7471-4b0b-a253-79b1e3026354",
|
||||
"name": "Sticky Note4",
|
||||
"type": "n8n-nodes-base.stickyNote",
|
||||
"position": [
|
||||
-280,
|
||||
-60
|
||||
],
|
||||
"parameters": {
|
||||
"width": 280,
|
||||
"content": "Once we have the server ID of the server we want to interact with, we can grab all members of the server that the bot can see."
|
||||
},
|
||||
"typeVersion": 1
|
||||
},
|
||||
{
|
||||
"id": "84f36c6d-c990-48d0-9328-32a40c803956",
|
||||
"name": "Sticky Note5",
|
||||
"type": "n8n-nodes-base.stickyNote",
|
||||
"position": [
|
||||
420,
|
||||
-60
|
||||
],
|
||||
"parameters": {
|
||||
"width": 280,
|
||||
"content": "Once we have the server ID of the server we want to interact with, we can grab all channels the bot can see."
|
||||
},
|
||||
"typeVersion": 1
|
||||
}
|
||||
],
|
||||
"active": true,
|
||||
"pinData": {},
|
||||
"settings": {
|
||||
"executionOrder": "v1"
|
||||
},
|
||||
"versionId": "bedf1c45-22f0-422c-8d77-ab058c1cceab",
|
||||
"connections": {
|
||||
"Send DM to User": {
|
||||
"ai_tool": [
|
||||
[
|
||||
{
|
||||
"node": "Discord MCP Server Trigger",
|
||||
"type": "ai_tool",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"Add Role To Member": {
|
||||
"ai_tool": [
|
||||
[
|
||||
{
|
||||
"node": "Discord MCP Server Trigger",
|
||||
"type": "ai_tool",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"Get Discord Server IDs": {
|
||||
"ai_tool": [
|
||||
[
|
||||
{
|
||||
"node": "Discord MCP Server Trigger",
|
||||
"type": "ai_tool",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"Remove Role from member": {
|
||||
"ai_tool": [
|
||||
[
|
||||
{
|
||||
"node": "Discord MCP Server Trigger",
|
||||
"type": "ai_tool",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"Send DM and Wait for reply": {
|
||||
"ai_tool": [
|
||||
[
|
||||
{
|
||||
"node": "Discord MCP Server Trigger",
|
||||
"type": "ai_tool",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"Send Discord Message to Channel": {
|
||||
"ai_tool": [
|
||||
[
|
||||
{
|
||||
"node": "Discord MCP Server Trigger",
|
||||
"type": "ai_tool",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"Get members of server by server ID": {
|
||||
"ai_tool": [
|
||||
[
|
||||
{
|
||||
"node": "Discord MCP Server Trigger",
|
||||
"type": "ai_tool",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"Send to Channel and Wait for Reply": {
|
||||
"ai_tool": [
|
||||
[
|
||||
{
|
||||
"node": "Discord MCP Server Trigger",
|
||||
"type": "ai_tool",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"Get channels of server by server ID": {
|
||||
"ai_tool": [
|
||||
[
|
||||
{
|
||||
"node": "Discord MCP Server Trigger",
|
||||
"type": "ai_tool",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user