Add MSC4144 per message profile types (#256)

This commit is contained in:
Toni Spets 2024-07-17 13:29:13 +03:00 committed by GitHub
commit 9e8d3050b0
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 15 additions and 4 deletions

View file

@ -131,10 +131,11 @@ type MessageEventContent struct {
replyFallbackRemoved bool
MessageSendRetry *BeeperRetryMetadata `json:"com.beeper.message_send_retry,omitempty"`
BeeperGalleryImages []*MessageEventContent `json:"com.beeper.gallery.images,omitempty"`
BeeperGalleryCaption string `json:"com.beeper.gallery.caption,omitempty"`
BeeperGalleryCaptionHTML string `json:"com.beeper.gallery.caption_html,omitempty"`
MessageSendRetry *BeeperRetryMetadata `json:"com.beeper.message_send_retry,omitempty"`
BeeperGalleryImages []*MessageEventContent `json:"com.beeper.gallery.images,omitempty"`
BeeperGalleryCaption string `json:"com.beeper.gallery.caption,omitempty"`
BeeperGalleryCaptionHTML string `json:"com.beeper.gallery.caption_html,omitempty"`
BeeperPerMessageProfile *BeeperPerMessageProfile `json:"com.beeper.per_message_profile,omitempty"`
BeeperLinkPreviews []*BeeperLinkPreview `json:"com.beeper.linkpreviews,omitempty"`

10
event/profile.go Normal file
View file

@ -0,0 +1,10 @@
package event
import "maunium.net/go/mautrix/id"
type BeeperPerMessageProfile struct {
ID string `json:"id"`
Displayname string `json:"displayname,omitempty"`
AvatarURL *id.ContentURIString `json:"avatar_url,omitempty"`
AvatarFile *EncryptedFileInfo `json:"avatar_file,omitempty"`
}