2021-08-19 04:19:20 +08:00
|
|
|
[
|
|
|
|
{
|
2022-02-10 03:13:27 +08:00
|
|
|
"id": "49e4b3a1ee3e9e1e",
|
|
|
|
"type": "matrix-synapse-users",
|
2021-08-19 04:19:20 +08:00
|
|
|
"z": "f025a8b9fbd1b054",
|
|
|
|
"name": "",
|
2022-02-10 03:13:27 +08:00
|
|
|
"server": null,
|
|
|
|
"x": 610,
|
|
|
|
"y": 2240,
|
|
|
|
"wires": [
|
|
|
|
[
|
|
|
|
"d4978f7c2dad7ecf"
|
|
|
|
],
|
|
|
|
[
|
|
|
|
"da9d25c324cb727e"
|
|
|
|
]
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"id": "e199d3db1ea6757c",
|
|
|
|
"type": "matrix-send-message",
|
|
|
|
"z": "f025a8b9fbd1b054",
|
|
|
|
"name": "Send HTML Notice",
|
|
|
|
"server": null,
|
2021-08-19 04:19:20 +08:00
|
|
|
"roomId": "",
|
2022-02-10 03:13:27 +08:00
|
|
|
"messageType": "m.notice",
|
|
|
|
"messageFormat": "html",
|
|
|
|
"x": 970,
|
|
|
|
"y": 2240,
|
|
|
|
"wires": [
|
|
|
|
[
|
|
|
|
"e248881d6749ba70"
|
|
|
|
],
|
|
|
|
[
|
|
|
|
"da9d25c324cb727e"
|
|
|
|
]
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"id": "d4978f7c2dad7ecf",
|
|
|
|
"type": "function",
|
|
|
|
"z": "f025a8b9fbd1b054",
|
|
|
|
"name": "",
|
|
|
|
"func": "msg.next_token = msg.payload.next_token || false;\nlet new_payload = '<ul>';\nmsg.payload.users.forEach(function(user, index){\n if(msg.guests == 'false' && user.is_guest) {\n return;\n }\n new_payload += '<li>'+ JSON.stringify(user, null, 2).replace(/(?:\\r\\n|\\r|\\n)/g, \"\\n<br>\"); + '</li>'\n});\nmsg.payload = new_payload + '</ul>';\n\nreturn msg;",
|
|
|
|
"outputs": 1,
|
|
|
|
"noerr": 0,
|
|
|
|
"initialize": "",
|
|
|
|
"finalize": "",
|
|
|
|
"libs": [],
|
|
|
|
"x": 800,
|
|
|
|
"y": 2240,
|
|
|
|
"wires": [
|
|
|
|
[
|
|
|
|
"e199d3db1ea6757c"
|
|
|
|
]
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"id": "880cac7307d9a786",
|
|
|
|
"type": "comment",
|
|
|
|
"z": "f025a8b9fbd1b054",
|
|
|
|
"name": "Response to \"users\" with full server user list (excluding guests)",
|
|
|
|
"info": "",
|
|
|
|
"x": 620,
|
|
|
|
"y": 2160,
|
|
|
|
"wires": []
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"id": "469d2ebd9995747a",
|
|
|
|
"type": "matrix-send-message",
|
|
|
|
"z": "f025a8b9fbd1b054",
|
|
|
|
"name": "",
|
|
|
|
"server": null,
|
|
|
|
"roomId": "",
|
|
|
|
"messageType": "m.notice",
|
|
|
|
"messageFormat": "",
|
|
|
|
"x": 600,
|
|
|
|
"y": 2300,
|
|
|
|
"wires": [
|
|
|
|
[],
|
|
|
|
[]
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"id": "da9d25c324cb727e",
|
|
|
|
"type": "change",
|
|
|
|
"z": "f025a8b9fbd1b054",
|
|
|
|
"name": "",
|
|
|
|
"rules": [
|
|
|
|
{
|
|
|
|
"t": "set",
|
|
|
|
"p": "payload",
|
|
|
|
"pt": "msg",
|
|
|
|
"to": "error",
|
|
|
|
"tot": "msg"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"action": "",
|
|
|
|
"property": "",
|
|
|
|
"from": "",
|
|
|
|
"to": "",
|
|
|
|
"reg": false,
|
|
|
|
"x": 420,
|
|
|
|
"y": 2300,
|
|
|
|
"wires": [
|
|
|
|
[
|
|
|
|
"469d2ebd9995747a"
|
|
|
|
]
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"id": "86577e484ca26aca",
|
|
|
|
"type": "change",
|
|
|
|
"z": "f025a8b9fbd1b054",
|
|
|
|
"name": "",
|
|
|
|
"rules": [
|
|
|
|
{
|
|
|
|
"t": "set",
|
|
|
|
"p": "guests",
|
|
|
|
"pt": "msg",
|
|
|
|
"to": "false",
|
|
|
|
"tot": "str"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"t": "set",
|
|
|
|
"p": "limit",
|
|
|
|
"pt": "msg",
|
|
|
|
"to": "25",
|
|
|
|
"tot": "num"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"t": "set",
|
|
|
|
"p": "order_by",
|
|
|
|
"pt": "msg",
|
|
|
|
"to": "creation_ts",
|
|
|
|
"tot": "str"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"action": "",
|
|
|
|
"property": "",
|
|
|
|
"from": "",
|
|
|
|
"to": "",
|
|
|
|
"reg": false,
|
|
|
|
"x": 420,
|
|
|
|
"y": 2240,
|
2021-08-19 04:19:20 +08:00
|
|
|
"wires": [
|
|
|
|
[
|
2022-02-10 03:13:27 +08:00
|
|
|
"49e4b3a1ee3e9e1e"
|
2021-08-19 04:19:20 +08:00
|
|
|
]
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
2022-02-10 03:13:27 +08:00
|
|
|
"id": "e248881d6749ba70",
|
2021-08-19 04:19:20 +08:00
|
|
|
"type": "switch",
|
|
|
|
"z": "f025a8b9fbd1b054",
|
2022-02-10 03:13:27 +08:00
|
|
|
"name": "More to paginate?",
|
|
|
|
"property": "next_token",
|
2021-08-19 04:19:20 +08:00
|
|
|
"propertyType": "msg",
|
|
|
|
"rules": [
|
|
|
|
{
|
2022-02-10 03:13:27 +08:00
|
|
|
"t": "istype",
|
|
|
|
"v": "string",
|
|
|
|
"vt": "string"
|
2021-08-19 04:19:20 +08:00
|
|
|
}
|
|
|
|
],
|
|
|
|
"checkall": "true",
|
|
|
|
"repair": false,
|
|
|
|
"outputs": 1,
|
2022-02-10 03:13:27 +08:00
|
|
|
"x": 1190,
|
|
|
|
"y": 2240,
|
2021-08-19 04:19:20 +08:00
|
|
|
"wires": [
|
|
|
|
[
|
2022-02-10 03:13:27 +08:00
|
|
|
"11d7fcf6335bc75b"
|
2021-08-19 04:19:20 +08:00
|
|
|
]
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
2022-02-10 03:13:27 +08:00
|
|
|
"id": "11d7fcf6335bc75b",
|
|
|
|
"type": "change",
|
2021-08-19 04:19:20 +08:00
|
|
|
"z": "f025a8b9fbd1b054",
|
|
|
|
"name": "",
|
2022-02-10 03:13:27 +08:00
|
|
|
"rules": [
|
|
|
|
{
|
|
|
|
"t": "set",
|
|
|
|
"p": "from",
|
|
|
|
"pt": "msg",
|
|
|
|
"to": "next_token",
|
|
|
|
"tot": "msg"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"action": "",
|
|
|
|
"property": "",
|
|
|
|
"from": "",
|
|
|
|
"to": "",
|
|
|
|
"reg": false,
|
|
|
|
"x": 1370,
|
|
|
|
"y": 2240,
|
2021-08-19 04:19:20 +08:00
|
|
|
"wires": [
|
|
|
|
[
|
2022-02-10 03:13:27 +08:00
|
|
|
"49e4b3a1ee3e9e1e"
|
|
|
|
]
|
2021-08-19 04:19:20 +08:00
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
2022-02-10 03:13:27 +08:00
|
|
|
"id": "8b48e27a118999ec",
|
|
|
|
"type": "switch",
|
2021-08-19 04:19:20 +08:00
|
|
|
"z": "f025a8b9fbd1b054",
|
2022-02-10 03:13:27 +08:00
|
|
|
"name": "is from me",
|
|
|
|
"property": "userId",
|
|
|
|
"propertyType": "msg",
|
|
|
|
"rules": [
|
|
|
|
{
|
|
|
|
"t": "eq",
|
|
|
|
"v": "@skylord123:skylar.tech",
|
|
|
|
"vt": "str"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"checkall": "true",
|
|
|
|
"repair": false,
|
|
|
|
"outputs": 1,
|
|
|
|
"x": 590,
|
|
|
|
"y": 2200,
|
2021-08-19 04:19:20 +08:00
|
|
|
"wires": [
|
2022-02-10 03:13:27 +08:00
|
|
|
[
|
|
|
|
"7a64319e26e8b689"
|
|
|
|
]
|
2021-08-19 04:19:20 +08:00
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
2022-02-10 03:13:27 +08:00
|
|
|
"id": "553da6dd77e5e03b",
|
|
|
|
"type": "matrix-receive",
|
2021-08-19 04:19:20 +08:00
|
|
|
"z": "f025a8b9fbd1b054",
|
|
|
|
"name": "",
|
2022-02-10 03:13:27 +08:00
|
|
|
"server": null,
|
|
|
|
"roomId": "",
|
|
|
|
"acceptText": true,
|
|
|
|
"acceptEmotes": true,
|
|
|
|
"acceptStickers": true,
|
|
|
|
"acceptReactions": true,
|
|
|
|
"acceptFiles": true,
|
|
|
|
"acceptImages": true,
|
|
|
|
"x": 420,
|
|
|
|
"y": 2200,
|
2021-08-19 04:19:20 +08:00
|
|
|
"wires": [
|
|
|
|
[
|
2022-02-10 03:13:27 +08:00
|
|
|
"8b48e27a118999ec"
|
2021-08-19 04:19:20 +08:00
|
|
|
]
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
2022-02-10 03:13:27 +08:00
|
|
|
"id": "7a64319e26e8b689",
|
|
|
|
"type": "switch",
|
2021-08-19 04:19:20 +08:00
|
|
|
"z": "f025a8b9fbd1b054",
|
2022-02-10 03:13:27 +08:00
|
|
|
"name": "msg.payload filter",
|
|
|
|
"property": "payload",
|
|
|
|
"propertyType": "msg",
|
|
|
|
"rules": [
|
|
|
|
{
|
|
|
|
"t": "eq",
|
|
|
|
"v": "users",
|
|
|
|
"vt": "str"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"checkall": "true",
|
|
|
|
"repair": false,
|
|
|
|
"outputs": 1,
|
|
|
|
"x": 770,
|
|
|
|
"y": 2200,
|
|
|
|
"wires": [
|
|
|
|
[
|
|
|
|
"86577e484ca26aca"
|
|
|
|
]
|
|
|
|
]
|
2021-08-19 04:19:20 +08:00
|
|
|
}
|
|
|
|
]
|