{ "name": "Telegram Manual Trade (Polling) - Import to Money Machine", "nodes": [ { "parameters": { "resource": "message", "operation": "get", "chatId": "579304651", "returnAll": false, "limit": 1, "options": {} }, "id": "telegram-poll-messages", "name": "Poll Telegram Messages", "type": "n8n-nodes-base.telegram", "typeVersion": 1.1, "position": [ -1020, 460 ], "credentials": { "telegramApi": { "id": "Csk5cg4HtaSqP5jJ", "name": "Telegram account" } } }, { "parameters": { "conditions": { "string": [ { "value1": "={{ $json.text }}", "operation": "regex", "value2": "\\b(buy|sell|long|short)\\b" } ] } }, "id": "filter-trade-commands", "name": "Filter Trade Commands", "type": "n8n-nodes-base.if", "typeVersion": 1, "position": [ -840, 460 ] }, { "parameters": { "fields": { "values": [ { "name": "rawMessage", "stringValue": "={{ $json.text }}" }, { "name": "symbol", "stringValue": "={{ $json.text.match(/\\b(SOL|BTC|ETH)\\b/i) ? $json.text.match(/\\b(SOL|BTC|ETH)\\b/i)[0].toUpperCase() + '-PERP' : 'SOL-PERP' }}" }, { "name": "direction", "stringValue": "={{ $json.text.match(/\\b(sell|short)\\b/i) ? 'short' : 'long' }}" }, { "name": "timeframe", "stringValue": "5" } ] }, "options": {} }, "id": "parse-command", "name": "Parse Trade Command", "type": "n8n-nodes-base.set", "typeVersion": 3.2, "position": [ -660, 460 ] }, { "parameters": { "chatId": "579304651", "text": "šŸ¤– Manual trade:\n\nšŸ“Š {{ $json.symbol }}\n{{ $json.direction === 'long' ? 'šŸ“ˆ' : 'šŸ“‰' }} {{ $json.direction.toUpperCase() }}\nā° {{ $now.toFormat('HH:mm:ss') }}\n\nā³ Processing...", "additionalFields": { "appendAttribution": false } }, "id": "send-ack", "name": "Send Acknowledgment", "type": "n8n-nodes-base.telegram", "typeVersion": 1.1, "position": [ -480, 460 ], "credentials": { "telegramApi": { "id": "Csk5cg4HtaSqP5jJ", "name": "Telegram account" } } }, { "parameters": { "mode": "raw", "jsonOutput": "={{ $json }}", "options": {} }, "id": "output-node", "name": "āž”ļø Connect to Check Risk", "type": "n8n-nodes-base.set", "typeVersion": 3.3, "position": [ -300, 460 ], "notes": "Connect this node's output to Money Machine's Check Risk node" } ], "pinData": {}, "connections": { "Poll Telegram Messages": { "main": [ [ { "node": "Filter Trade Commands", "type": "main", "index": 0 } ] ] }, "Filter Trade Commands": { "main": [ [ { "node": "Parse Trade Command", "type": "main", "index": 0 } ] ] }, "Parse Trade Command": { "main": [ [ { "node": "Send Acknowledgment", "type": "main", "index": 0 } ] ] }, "Send Acknowledgment": { "main": [ [ { "node": "āž”ļø Connect to Check Risk", "type": "main", "index": 0 } ] ] } }, "active": false, "settings": { "executionOrder": "v1" }, "versionId": "telegram-polling-v1", "meta": { "instanceId": "e766d4f0b5def8ee8cb8561cd9d2b9ba7733e1907990b6987bca40175f82c379" }, "tags": [] }