Add start of Media Moderator PoC bot
2 files changed, 24 insertions, 0 deletions
diff --git a/LibMatrix/StateEventTypes/Spec/JoinRulesEventData.cs b/LibMatrix/StateEventTypes/Spec/JoinRulesEventData.cs
index d3da559..08e8f22 100644
--- a/LibMatrix/StateEventTypes/Spec/JoinRulesEventData.cs
+++ b/LibMatrix/StateEventTypes/Spec/JoinRulesEventData.cs
@@ -12,6 +12,10 @@ public class JoinRulesEventData : IStateEventType {
private static string Invite = "invite";
private static string Knock = "knock";
+ /// <summary>
+ /// one of ["public", "invite", "knock", "restricted", "knock_restricted"]
+ /// "private" is reserved without implementation!
+ /// </summary>
[JsonPropertyName("join_rule")]
public string JoinRule { get; set; }
diff --git a/LibMatrix/StateEventTypes/Spec/RoomMessageEventData.cs b/LibMatrix/StateEventTypes/Spec/RoomMessageEventData.cs
index 5d65237..11a0e82 100644
--- a/LibMatrix/StateEventTypes/Spec/RoomMessageEventData.cs
+++ b/LibMatrix/StateEventTypes/Spec/RoomMessageEventData.cs
@@ -17,4 +17,24 @@ public class RoomMessageEventData : IStateEventType {
[JsonPropertyName("format")]
public string Format { get; set; }
+
+ [JsonPropertyName("m.relates_to")]
+ public MessageRelatesTo? RelatesTo { get; set; }
+
+ /// <summary>
+ /// Media URI for this message, if any
+ /// </summary>
+ [JsonPropertyName("url")]
+ public string? Url { get; set; }
+
+ public class MessageRelatesTo {
+
+ [JsonPropertyName("m.in_reply_to")]
+ public MessageInReplyTo? InReplyTo { get; set; }
+
+ public class MessageInReplyTo {
+ [JsonPropertyName("event_id")]
+ public string EventId { get; set; }
+ }
+ }
}
|