using Newtonsoft.Json; using xCommons.Extensions; using xBotService.Constants; using System.Collections.Generic; namespace xBotService.Models { // public class XBotMessageRequest // { // public long ChatId { get; set; } // public string Text { get; set; } // public XBotReplyMarkup ReplyMarkup { get; set; } = null; // public string ParseMode { get; set; } = XBotMessageParseMode.Html.GetStringValue(); // } // public class XBotReplyMarkup // { // public List> InlineKeyboard { get; set; } // } // public class XBotInlineButton // { // public string Text { get; set; } // public string Url { get; set; } // public string CallbackData { get; set; } // } // public class XBotMessageResponse // { // public bool Ok { get; set; } // public string Description { get; set; } // public XBotResMessage Result { get; set; } // } // public class XBotResMessage // { // public long Date { get; set; } // public string Text { get; set; } // public long MessageId { get; set; } // public XBotResUser From { get; set; } // public XBotResChat Chat { get; set; } // } public class XBotResUser { [JsonProperty("id")] public long Id { get; set; } [JsonProperty("is_bot")] public bool IsBot { get; set; } [JsonProperty("last_name")] public string LastName { get; set; } [JsonProperty("username")] public string Username { get; set; } [JsonProperty("first_name")] public string FirstName { get; set; } [JsonProperty("language_code")] public string LanguageCode { get; set; } [JsonProperty("has_main_web_app")] public string HasMainWebApp { get; set; } [JsonProperty("has_topics_enabled")] public bool HasTopicsEnabled { get; set; } [JsonProperty("allows_users_to_create_topics")] public bool AllowsUsersToCreateTopics { get; set; } } // public class XBotResChat // { // public long Id { get; set; } // public string Type { get; set; } // public string Title { get; set; } // public string Username { get; set; } // public string FirstName { get; set; } // } // public class XBotUpdate // { // public long UpdateId { get; set; } // public XBotResMessage Message { get; set; } // public XBotCallbackQuery CallbackQuery { get; set; } // } /// /// Base Bot Response ... /// public class XBotResponse : XBotResponse { } /// /// Base Bot Response ... /// /// public class XBotResponse { public bool Ok { get; set; } public T Result { get; set; } } /// /// Bot Message Send Request ... /// public class XBotSendMessageRequest { [JsonProperty("chat_id")] public long ChatId { get; set; } [JsonProperty("text")] public string Text { get; set; } [JsonProperty("reply_markup")] public object ReplyMarkup { get; set; } [JsonProperty("message_thread_id")] public long MessageThreadId { get; set; } [JsonProperty("reply_to_message_id")] public long ReplyToMessageId { get; set; } } // public class XBotCallbackQuery // { // public string Id { get; set; } // public string Data { get; set; } // public XBotResUser From { get; set; } // public XBotResMessage Message { get; set; } // } }