morpheus

A Matrix client written in Go-QT
git clone git://archive.git.mtrnord.blog/Nordgedanken/morpheus.git
Log | Files | Refs | README | LICENSE

types.go (1736B)


      1 package matrix
      2 
      3 // HTMLMessage is the contents of a Matrix formated message event.
      4 type HTMLMessage struct {
      5 	MsgType       string `json:"msgtype,omitempty"`
      6 	Body          string `json:"body,omitempty"`
      7 	FormattedBody string `json:"formatted_body,omitempty"`
      8 	Format        string `json:"format,omitempty"`
      9 }
     10 
     11 // RoomAliases is the json response when getting the room aliases
     12 type RoomAliases struct {
     13 	Age     int `json:"age,omitempty"`
     14 	Content struct {
     15 		Aliases []string `json:"aliases,omitempty"`
     16 	} `json:"content,omitempty"`
     17 	EventID        string `json:"event_id,omitempty"`
     18 	OriginServerTs int64  `json:"origin_server_ts,omitempty"`
     19 	RoomID         string `json:"room_id,omitempty"`
     20 	Sender         string `json:"sender,omitempty"`
     21 	StateKey       string `json:"state_key,omitempty"`
     22 	Type           string `json:"type,omitempty"`
     23 }
     24 
     25 // JoinedRooms is the json response when getting the joined rooms list
     26 type JoinedRooms struct {
     27 	JoinedRooms []string `json:"joined_rooms,omitempty"`
     28 }
     29 
     30 // RoomAvatar is the json response when getting the room avatar list
     31 type RoomAvatar struct {
     32 	Age     int `json:"age,omitempty"`
     33 	Content struct {
     34 		Info struct {
     35 			H        int    `json:"h,omitempty"`
     36 			Mimetype string `json:"mimetype,omitempty"`
     37 			Size     int    `json:"size,omitempty"`
     38 			W        int    `json:"w,omitempty"`
     39 		} `json:"info,omitempty"`
     40 		URL string `json:"url,omitempty"`
     41 	} `json:"content,omitempty"`
     42 	EventID        string `json:"event_id,omitempty"`
     43 	OriginServerTs int64  `json:"origin_server_ts,omitempty"`
     44 	RoomID         string `json:"room_id,omitempty"`
     45 	Sender         string `json:"sender,omitempty"`
     46 	StateKey       string `json:"state_key,omitempty"`
     47 	Type           string `json:"type,omitempty"`
     48 }