From a11be80cf0c13263791f3e4f82fda461acd77130 Mon Sep 17 00:00:00 2001 From: Alex Auvolat Date: Sun, 16 Feb 2020 22:57:30 +0100 Subject: Work --- mxlib/api.go | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) (limited to 'mxlib') diff --git a/mxlib/api.go b/mxlib/api.go index cb2d10c..84c125b 100644 --- a/mxlib/api.go +++ b/mxlib/api.go @@ -18,7 +18,7 @@ type Transaction struct { } type Event struct { - Content map[string]string `json:"content"` + Content map[string]interface{} `json:"content"` Type string `json:"type"` EventId string `json:"event_id"` RoomId string `json:"room_id"` @@ -47,6 +47,17 @@ type CreateRoomRequest struct { Topic string `json:"topic"` Invite []string `json:"invite"` CreationContent map[string]interface{} `json:"creation_content"` + PowerLevels map[string]interface{} `json:"power_level_content_override"` +} + +type CreateRoomNoAliasRequest struct { + Preset string `json:"preset"` + Name string `json:"name"` + Topic string `json:"topic"` + Invite []string `json:"invite"` + CreationContent map[string]interface{} `json:"creation_content"` + PowerLevels map[string]interface{} `json:"power_level_content_override"` + IsDirect bool `json:"is_direct"` } type CreateRoomResponse struct { @@ -70,10 +81,11 @@ type RoomJoinResponse struct { RoomId string `json:"room_id"` } -type RoomSendRequest struct { +type RoomSendMessageRequest struct { MsgType string `json:"msgtype"` Body string `json:"body"` } type RoomSendResponse struct { EventId string `json:"event_id"` } + -- cgit v1.2.3