{e.Message}" + $"", Format = "org.matrix.custom.html" }; } public static RoomMessageEventData FormatSuccess(string text) { return new RoomMessageEventData(body: text, messageType: "m.text") { FormattedBody = $"{text}", Format = "org.matrix.custom.html" }; } public static RoomMessageEventData FormatSuccessJson(string text, object data) { return new RoomMessageEventData(body: text, messageType: "m.text") { FormattedBody = $"{text}:
{data.ToJson(ignoreNull: true)}", Format = "org.matrix.custom.html" }; } public static string HtmlFormatMention(string id, string? displayName = null) { return $"{displayName ?? id}"; } }