Currently it only accepts user tokens, but it would be great if you can make it work with bot tokens as well.
Im not experienced enough with .NET at all to provide a complete solution for this, but I was able to get it working with a bot token by adding the following line to the very start of DataService#GetStringAsync:
_httpClient.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue("Bot", "BOT TOKEN HERE");
(Obviously replace BOT TOKEN HERE with the actual token)
Currently using this app puts your discord account at risk, as it's use goes against discord TOS. Making the same exact functionality except remove the ability to use a user token, and instead replace it with a bot token would greatly benefit the end users.
This is scheduled for next release
um where is DataService#GetStringAsync? I can not find it @yonilerner
@thisisjvgrace It looks like that method was removed in https://github.com/Tyrrrz/DiscordChatExporter/pull/63 The best equivalent now is probably DataService#GetApiResponseAsync, but I have not tested it, and do not have time to.
EDIT: Though, note that the Owner has said in this thread that this feature is planned for the next release anyway, so you may want to just hold tight for that
Hello, I'm using v2.20.0, and trying to use a bot token returns
Authentication token is invalid.
Thanks
@KaKi87
consult with the wiki: https://github.com/Tyrrrz/DiscordChatExporter/wiki/Obtaining-Token-and-Channel-IDs#how-to-get-a-bot-token
Most helpful comment
This is scheduled for next release