2020-03-01 22:46:37 +04:00
|
|
|
using System;
|
|
|
|
|
using Newtonsoft.Json;
|
|
|
|
|
|
2023-07-28 19:34:28 +03:00
|
|
|
namespace Kruzya.TelegramBot.CombotAntiSpam.Combot;
|
|
|
|
|
|
|
|
|
|
internal class CombotApiResponse
|
2020-03-01 22:46:37 +04:00
|
|
|
{
|
2023-07-28 19:34:28 +03:00
|
|
|
public class ApiResult
|
2020-03-01 22:46:37 +04:00
|
|
|
{
|
2023-07-28 19:34:28 +03:00
|
|
|
[JsonProperty("messages")]
|
|
|
|
|
public string[] Messages { get; set; }
|
2020-03-01 22:46:37 +04:00
|
|
|
|
2023-07-28 19:34:28 +03:00
|
|
|
[JsonProperty("time_added")]
|
|
|
|
|
public int TimeAdded { get; set; }
|
2020-03-01 22:46:37 +04:00
|
|
|
|
2023-07-28 19:34:28 +03:00
|
|
|
[JsonProperty("offenses")]
|
|
|
|
|
public int Offenses { get; set; }
|
2020-03-01 22:46:37 +04:00
|
|
|
|
2023-07-28 19:34:28 +03:00
|
|
|
public DateTime AddedAt => DateTimeOffset.FromUnixTimeSeconds(TimeAdded).DateTime;
|
|
|
|
|
}
|
2020-03-01 22:46:37 +04:00
|
|
|
|
2023-07-28 19:34:28 +03:00
|
|
|
[JsonProperty("ok")]
|
|
|
|
|
public bool IsSpammer { get; set; }
|
2020-03-01 22:46:37 +04:00
|
|
|
|
2023-07-28 19:34:28 +03:00
|
|
|
[JsonProperty("description")]
|
|
|
|
|
public string Description { get; set; }
|
2020-03-01 22:46:37 +04:00
|
|
|
|
2023-07-28 19:34:28 +03:00
|
|
|
[JsonProperty("result")]
|
|
|
|
|
public ApiResult Result { get; set; }
|
2020-03-01 22:46:37 +04:00
|
|
|
}
|