User Tools

Site Tools


sysadminery:matrix

This is an old revision of the document!


register new user

ssh in. normally you use register_new_matrix_user, but the digital ocean droplet comes with:

./new-user

curl as client

you're on port 8448, which is unusual.

pw='PASSWORD'
echo $pw
curl -XPOST -d '{"type":"m.login.password", "user":"USERNAME", "password":"$pw"}' "https://greyn.club:8448/_matrix/client/r0/login"

that'll give you back a json object, including an access token

curl -XPOST \
    -d "{\"msgtype\":\"m.text\", \"body\":\"TEXT\"}" \
    "https://greyn.club:8448/_matrix/client/r0/rooms/"'!'"pPZWsacCoTafJoyJXu:greyn.club/send/m.room.message?access_token=ACCESSTOKEN"
sysadminery/matrix.1712069616.txt.gz · Last modified: 2024/04/02 14:53 by adam