diff --git a/BeezleBot/BeezleBot.cpp b/BeezleBot/BeezleBot.cpp index aa1ea07..482d8dd 100644 --- a/BeezleBot/BeezleBot.cpp +++ b/BeezleBot/BeezleBot.cpp @@ -11,7 +11,8 @@ int main(int argc, char **argv) { Settings settings(argc, argv); - DokuWiki wiki(settings.wikiUrl, settings.wikiUser, settings.wikiPassword); + DokuWiki wiki(settings.wikiUrl + "/lib/exe/xmlrpc.php", + settings.wikiUser, settings.wikiPassword); tgbot::LongPollBot bot(settings.telegramToken); bot.callback([&wiki, &settings](const tgbot::types::Message message, @@ -46,7 +47,10 @@ int main(int argc, char **argv) api.sendMessage(std::to_string(message.chat.id), reply.str()); } - api.sendMessage(std::to_string(message.chat.id), "Stored to wiki"); + std::ostringstream pageUrl; + pageUrl << settings.wikiUrl << "/doku.php?id=" << "beezletest"; + api.sendMessage(std::to_string(message.chat.id), + "Stored to wiki at " + pageUrl.str()); } } }); diff --git a/beezle.conf b/beezle.conf index 5ec7fbe..66a628c 100644 --- a/beezle.conf +++ b/beezle.conf @@ -3,7 +3,7 @@ token = 123456789:ABCDEFG1234567HIJKLMN8901234abcdefg users = my_telegram_user [DokuWiki] -url = https://my.webserver.url/dokuwiki/lib/exe/xmlrpc.php +url = https://my.webserver.url/dokuwiki username = wiki_username password = wiki_password