Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- [
- {
- "id": "617f0f21.4c48d",
- "type": "tab",
- "label": "Cryptosignals_BollingerAlerts",
- "disabled": false,
- "info": ""
- },
- {
- "id": "3f3c9684.7f08fa",
- "type": "http in",
- "z": "617f0f21.4c48d",
- "name": "Crypto-Signals",
- "url": "/cryptosignals",
- "method": "post",
- "upload": false,
- "swaggerDoc": "",
- "x": 150,
- "y": 96,
- "wires": [
- [
- "d03bfb1a.038d08",
- "d03a687e.aaaa38"
- ]
- ]
- },
- {
- "id": "d03bfb1a.038d08",
- "type": "http response",
- "z": "617f0f21.4c48d",
- "name": "",
- "statusCode": "",
- "headers": {},
- "x": 387,
- "y": 96,
- "wires": []
- },
- {
- "id": "d03a687e.aaaa38",
- "type": "function",
- "z": "617f0f21.4c48d",
- "name": "Parser",
- "func": "var string = msg.payload.messages;\nvar obj = JSON.parse(string);\nmsg.payload = obj;\nreturn msg;",
- "outputs": 1,
- "noerr": 0,
- "x": 117.00003051757812,
- "y": 183,
- "wires": [
- [
- "2b2e9c57.32ef64"
- ]
- ]
- },
- {
- "id": "2b2e9c57.32ef64",
- "type": "split",
- "z": "617f0f21.4c48d",
- "name": "Splitter",
- "splt": "\\n",
- "spltType": "str",
- "arraySplt": 1,
- "arraySpltType": "len",
- "stream": false,
- "addname": "",
- "x": 263.0000305175781,
- "y": 183,
- "wires": [
- [
- "5407cd5e.d28214"
- ]
- ]
- },
- {
- "id": "5407cd5e.d28214",
- "type": "switch",
- "z": "617f0f21.4c48d",
- "name": "IndicatorType",
- "property": "payload.indicator",
- "propertyType": "msg",
- "rules": [
- {
- "t": "eq",
- "v": "rsi",
- "vt": "str"
- },
- {
- "t": "eq",
- "v": "stoch_rsi",
- "vt": "str"
- },
- {
- "t": "eq",
- "v": "momentum",
- "vt": "str"
- },
- {
- "t": "eq",
- "v": "mfi",
- "vt": "str"
- },
- {
- "t": "eq",
- "v": "std_crossover",
- "vt": "str"
- }
- ],
- "checkall": "true",
- "repair": false,
- "outputs": 5,
- "x": 441.0000305175781,
- "y": 183,
- "wires": [
- [
- "2e36bea3.116992"
- ],
- [
- "6f4b362b.85a648"
- ],
- [
- "f9c9eaca.377a68"
- ],
- [
- "7edf3fc1.3483e"
- ],
- [
- "f4f1b970.2c64f8"
- ]
- ]
- },
- {
- "id": "2e36bea3.116992",
- "type": "change",
- "z": "617f0f21.4c48d",
- "name": "Convert RSI to number",
- "rules": [
- {
- "t": "set",
- "p": "payload.values.rsi",
- "pt": "msg",
- "to": "$number(payload.values.rsi)",
- "tot": "jsonata"
- }
- ],
- "action": "",
- "property": "",
- "from": "",
- "to": "",
- "reg": false,
- "x": 720.2500381469727,
- "y": 124.2500057220459,
- "wires": [
- [
- "fb9e2d75.cb6c8"
- ]
- ]
- },
- {
- "id": "6f4b362b.85a648",
- "type": "change",
- "z": "617f0f21.4c48d",
- "name": "Convert Stoch_RSI to number",
- "rules": [
- {
- "t": "set",
- "p": "payload.values.stoch_rsi",
- "pt": "msg",
- "to": "$number(payload.values.stoch_rsi)",
- "tot": "jsonata"
- }
- ],
- "action": "",
- "property": "",
- "from": "",
- "to": "",
- "reg": false,
- "x": 750.2500381469727,
- "y": 176.2500057220459,
- "wires": [
- [
- "674f2be7.cda6a4"
- ]
- ]
- },
- {
- "id": "fb9e2d75.cb6c8",
- "type": "change",
- "z": "617f0f21.4c48d",
- "name": "Set flow variables for Current Prices and RSI",
- "rules": [
- {
- "t": "set",
- "p": "currentprices",
- "pt": "flow",
- "to": "payload.prices",
- "tot": "jsonata"
- },
- {
- "t": "set",
- "p": "currentrsivalue",
- "pt": "flow",
- "to": "payload.values.rsi",
- "tot": "jsonata"
- }
- ],
- "action": "",
- "property": "",
- "from": "",
- "to": "",
- "reg": false,
- "x": 1196.2500305175781,
- "y": 124.25,
- "wires": [
- []
- ]
- },
- {
- "id": "674f2be7.cda6a4",
- "type": "change",
- "z": "617f0f21.4c48d",
- "name": "Set flow variable for Stoch_RSI",
- "rules": [
- {
- "t": "set",
- "p": "currentstochrsivalue",
- "pt": "flow",
- "to": "\"Stoch_RSI : \" & msg.payload.values.stoch_rsi",
- "tot": "jsonata"
- }
- ],
- "action": "",
- "property": "",
- "from": "",
- "to": "",
- "reg": false,
- "x": 1156.2500381469727,
- "y": 176.2500057220459,
- "wires": [
- []
- ]
- },
- {
- "id": "f9c9eaca.377a68",
- "type": "change",
- "z": "617f0f21.4c48d",
- "name": "Convert momentum to number",
- "rules": [
- {
- "t": "set",
- "p": "payload.values.momentum",
- "pt": "msg",
- "to": "$number(payload.values.momentum)",
- "tot": "jsonata"
- }
- ],
- "action": "",
- "property": "",
- "from": "",
- "to": "",
- "reg": false,
- "x": 748.2500381469727,
- "y": 225.2500057220459,
- "wires": [
- [
- "276d4541.d03a6a"
- ]
- ]
- },
- {
- "id": "7edf3fc1.3483e",
- "type": "change",
- "z": "617f0f21.4c48d",
- "name": "Convert mfi to number",
- "rules": [
- {
- "t": "set",
- "p": "payload.values.mfi",
- "pt": "msg",
- "to": "$number(payload.values.mfi)",
- "tot": "jsonata"
- }
- ],
- "action": "",
- "property": "",
- "from": "",
- "to": "",
- "reg": false,
- "x": 719.2500381469727,
- "y": 277.2500057220459,
- "wires": [
- [
- "1475889c.7b4807"
- ]
- ]
- },
- {
- "id": "276d4541.d03a6a",
- "type": "change",
- "z": "617f0f21.4c48d",
- "name": "Set flow variable for momentum",
- "rules": [
- {
- "t": "set",
- "p": "currentmomentumvalue",
- "pt": "flow",
- "to": "\"Momentum : \" & msg.payload.values.momentum",
- "tot": "jsonata"
- }
- ],
- "action": "",
- "property": "",
- "from": "",
- "to": "",
- "reg": false,
- "x": 1156.2500305175781,
- "y": 225.25,
- "wires": [
- []
- ]
- },
- {
- "id": "1475889c.7b4807",
- "type": "change",
- "z": "617f0f21.4c48d",
- "name": "Set flow variable for mfi",
- "rules": [
- {
- "t": "set",
- "p": "currentmfivalue",
- "pt": "flow",
- "to": "\"MFI : \" & msg.payload.values.mfi",
- "tot": "jsonata"
- }
- ],
- "action": "",
- "property": "",
- "from": "",
- "to": "",
- "reg": false,
- "x": 1138.2500305175781,
- "y": 276.25,
- "wires": [
- []
- ]
- },
- {
- "id": "5894bcd7.c03c44",
- "type": "comment",
- "z": "617f0f21.4c48d",
- "name": "Flow for Crypto Signals",
- "info": "Signals received from Crypto-Signals webhook",
- "x": 170.25003051757812,
- "y": 46.25,
- "wires": []
- },
- {
- "id": "f4f1b970.2c64f8",
- "type": "change",
- "z": "617f0f21.4c48d",
- "name": "Convert Bollinger values to Numbers",
- "rules": [
- {
- "t": "set",
- "p": "payload.values.close_0",
- "pt": "msg",
- "to": "$number(payload.values.close_0)",
- "tot": "jsonata"
- },
- {
- "t": "set",
- "p": "payload.values.upperband_1",
- "pt": "msg",
- "to": "$number(payload.values.upperband_1)",
- "tot": "jsonata"
- }
- ],
- "action": "",
- "property": "",
- "from": "",
- "to": "",
- "reg": false,
- "x": 770.2500305175781,
- "y": 332.91668701171875,
- "wires": [
- [
- "15300d73.958da3"
- ]
- ]
- },
- {
- "id": "15300d73.958da3",
- "type": "switch",
- "z": "617f0f21.4c48d",
- "name": "Eval Close Price vs Bollinger Upperband",
- "property": "payload.values.close_0",
- "propertyType": "msg",
- "rules": [
- {
- "t": "lte",
- "v": "payload.values.upperband_1",
- "vt": "msg"
- },
- {
- "t": "gt",
- "v": "payload.values.upperband_1",
- "vt": "msg"
- }
- ],
- "checkall": "true",
- "repair": false,
- "outputs": 2,
- "x": 232.25003051757812,
- "y": 491.91668701171875,
- "wires": [
- [
- "d8935e63.0ecbb"
- ],
- [
- "61c48900.a8d738"
- ]
- ]
- },
- {
- "id": "61c48900.a8d738",
- "type": "function",
- "z": "617f0f21.4c48d",
- "name": "Create alert for Bollinger Breakout",
- "func": "msg.payload = {chatId : -chatidref, type : 'message', content: \"Bollinger breakout, Check the charts! - Close Price: \" + msg.payload.values.close_0 + \" vs Bollinger Upperband: \" + msg.payload.values.upperband_1};\nreturn msg;",
- "outputs": 1,
- "noerr": 0,
- "x": 640.2500305175781,
- "y": 524.9166870117188,
- "wires": [
- [
- "8a06fd10.be136",
- "9655b6d0.edd8f8"
- ]
- ]
- },
- {
- "id": "63e6782e.c1a5f8",
- "type": "comment",
- "z": "617f0f21.4c48d",
- "name": "Check for Bollinger breakout",
- "info": "",
- "x": 194.25003051757812,
- "y": 431.91668701171875,
- "wires": []
- },
- {
- "id": "8a06fd10.be136",
- "type": "debug",
- "z": "617f0f21.4c48d",
- "name": "",
- "active": true,
- "tosidebar": true,
- "console": false,
- "tostatus": false,
- "complete": "false",
- "x": 924.2500305175781,
- "y": 600.9166870117188,
- "wires": []
- },
- {
- "id": "d8935e63.0ecbb",
- "type": "function",
- "z": "617f0f21.4c48d",
- "name": "Create message for do nothing",
- "func": "msg.payload = \"Do nothing! - Close Price: \" + msg.payload.values.close_0 + \" vs Bollinger Upperband: \" + msg.payload.values.upperband_1;\nreturn msg;",
- "outputs": 1,
- "noerr": 0,
- "x": 628.2500305175781,
- "y": 469.91668701171875,
- "wires": [
- [
- "268480e8.fb914"
- ]
- ]
- },
- {
- "id": "268480e8.fb914",
- "type": "debug",
- "z": "617f0f21.4c48d",
- "name": "",
- "active": true,
- "tosidebar": true,
- "console": false,
- "tostatus": false,
- "complete": "false",
- "x": 919.2500305175781,
- "y": 469.91668701171875,
- "wires": []
- },
- {
- "id": "9655b6d0.edd8f8",
- "type": "telegram sender",
- "z": "617f0f21.4c48d",
- "name": "Send bollinger breakout alert to Telegram",
- "bot": "",
- "x": 1008.2500305175781,
- "y": 524.9166870117188,
- "wires": [
- []
- ]
- }
- ]
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement