42 lines
710 B
Python
42 lines
710 B
Python
import os
|
|
|
|
name = "Synapse Assign Space"
|
|
|
|
kind = "action"
|
|
|
|
showstatus = True
|
|
|
|
resolve = {
|
|
"sender": ["messages", 0, "senderId"],
|
|
"space_id": ["space_id"],
|
|
"username": ["profile", "username"],
|
|
"room_id": ["dmroom_id"],
|
|
}
|
|
keys = [
|
|
{
|
|
"keytitle": "via",
|
|
"keyvalue": [
|
|
"loxthelion.com",
|
|
],
|
|
}
|
|
]
|
|
|
|
method = "PUT"
|
|
|
|
path = [
|
|
"https://loxthelion.com/_matrix/client/v3/rooms/",
|
|
{"resolved": "space_id"},
|
|
"/state/m.space.child/",
|
|
{"resolved": "room_id"},
|
|
"?user_id=@rmass_bridge_test:loxthelion.com"
|
|
]
|
|
|
|
headers = {
|
|
"Authorization": {
|
|
"os": "AS_TOKEN",
|
|
"prefix": "Bearer ",
|
|
},
|
|
"Content-Type": "application/json",
|
|
}
|
|
|