• 0 Posts
  • 4 Comments
Joined 6 months ago
cake
Cake day: August 10th, 2025

help-circle



  • If you don’t shy away from python, I just use the requests library most of the time:

    homeserver_url = “XXX”

    access_token = “XXX”

    room_id = “!XXX”

    url = f{homeserver_url}/_matrix/client/r0/rooms/{room_id}/send/m.room.message"

    headers = {“Authorization”: f"Bearer {access_token}",“Content-Type”: “application/json”,}

    data = “msgtype”: “m.text”,“body”: “Question of the day!”,}

    response = requests.post(url, headers=headers, data=json.dumps(data))

    Alternatively I also have a bot I use in NodeRed connected to Home Assistant.

    Double Alternatively, I’ve used AppRise successfully within various tools like ChangeDetection to notify me via matrix.