#include "WiFi.h"
#include "WiFiClientSecure.h"
#include "UniversalTelegramBot.h"
const char* SSID = "SSID";
const char* PASSWORD = "PASSWORD";
#define bot_token = "BOT_TOKEN";
#define chat_id = "CHAT_ID";
WiFiClientSecure client;
UniversalTelegramBot teleBot(bot_token,client);
void setup() {
// put your setup code here, to run once:
Serial.begin(115200);
WiFi.mode(WIFI_STA);
WiFi.begin(SSID,PASSWORD);
client.setCAcert(TELEGRAM_CERTIFICATE_ROOT);
while(WiFi.status() != WL_CONNECTED){
Serial.print(".");
delay(1000);
}
Serial.println("Wifi Connected");
teleBot.sendMessage(chat_id,"Message");
}
void loop() {
// put your main code here, to run repeatedly:
delay(10); // this speeds up the simulation
}