public TelegramApiResponse GetUpdates(int offset) { string url = $"{this.botSettings.GetBotApiEndpoint()}/getUpdates?offset={offset}"; var dataAsString = webRequestor.GetJson(url); var data = JsonSerializer.Deserialize <TelegramApiResponse>(dataAsString); return(data); }
public void SendMessage(string messageText, int chatId) { webRequestor.GetJson($"{this.botSettings.GetBotApiEndpoint()}/sendMessage?chat_id={chatId}&text={messageText}"); }