about summary refs log tree commit diff
path: root/MatrixRoomUtils.Core/Responses/StateEventResponse.cs
blob: 1af3e1f6153f686af39935958b9432adb44df227 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
using System.Text.Json.Serialization;

namespace MatrixRoomUtils.Core;

public class StateEventResponse
{
    [JsonPropertyName("content")]
    public dynamic Content { get; set; }
    [JsonPropertyName("origin_server_ts")]
    public long OriginServerTs { get; set; }
    [JsonPropertyName("room_id")]
    public string RoomId { get; set; }
    [JsonPropertyName("sender")]
    public string Sender { get; set; }
    [JsonPropertyName("state_key")]
    public string StateKey { get; set; }
    [JsonPropertyName("type")]
    public string Type { get; set; }
    [JsonPropertyName("unsigned")]
    public dynamic Unsigned { get; set; }
    [JsonPropertyName("event_id")]
    public string EventId { get; set; }
    [JsonPropertyName("user_id")]
    public string UserId { get; set; }
    [JsonPropertyName("replaces_state")]
    public string ReplacesState { get; set; }
    [JsonPropertyName("prev_content")]
    public dynamic PrevContent { get; set; }
}

public class StateEventResponse<T> : StateEventResponse where T : class
{
    
    [JsonPropertyName("content")]
    public T Content { get; set; }
}