34 #define WEBHOOK_URL "https://your-domain/cgi-bin/bot.cgi"
35 #define BOT_TOKEN "your secret token"
38 int main(
int argc,
char** argv) {
41 std::string user_id =
"";
42 std::string filename =
"";
52 while ((c = getopt(argc, argv,
"wu:p:")) != -1) {
55 user_id = (std::string)optarg;
62 filename = (std::string)optarg;
65 std::cerr << optopt <<
" without argument" << std::endl;
71 std::cerr <<
"No user ID given!" << std::endl;
85 if (tcgetattr(STDIN_FILENO, &t) < 0) {
89 std::getline(std::cin, line);
void setWebhook(std::string)
Telegram::Message * sendPhoto(std::string, Json::Int64)
int main(int argc, char **argv)
Telegram::Message * sendMessage(std::string, Json::Int64)