shayaantx / botdarr

Slack/Discord/Telegram/Matrix bot for accessing radarr, sonarr, and lidarr
GNU General Public License v3.0
157 stars 12 forks source link

Slack bot integration Error: not_allowed_token_type #123

Open ImagineerNL opened 4 months ago

ImagineerNL commented 4 months ago

Trying to install this as a slack bot.

Created the app, added the oauth permissions as per instruction. Copy/pasted the SLACK_BOT_TOKEN from the slack app settings "Bot User OAuth Token" , but get this error in my logs and it won't connect to slack.

exception in thread "main" java.lang.IllegalStateException: Failed to the RTM endpoint URL (error: not_allowed_token_type) at com.github.seratch.jslack.Slack.rtmConnect(Slack.java:157) at com.github.seratch.jslack.Slack.rtmConnect(Slack.java:132) at com.github.seratch.jslack.Slack.rtm(Slack.java:123) at com.botdarr.clients.slack.SlackBootstrap.init(SlackBootstrap.java:36) at com.botdarr.BotdarrApplication.main(BotdarrApplication.java:13)

I'm using the docker app from the Unraid appdir, and manually added the needed variables from the readme.

Total log seems error free besides a lidarr warning (i dont have lidarr):

May 27, 2024 9:28:20 PM org.flywaydb.core.internal.logging.slf4j.Slf4jLog info INFO: Flyway Community Edition 6.2.4 by Redgate May 27, 2024 9:28:20 PM org.flywaydb.core.internal.logging.slf4j.Slf4jLog info INFO: Database: jdbc:sqlite:database/botdarr.db (SQLite 3.30) May 27, 2024 9:28:20 PM org.flywaydb.core.internal.logging.slf4j.Slf4jLog info INFO: Successfully validated 3 migrations (execution time 00:00.010s) May 27, 2024 9:28:20 PM org.flywaydb.core.internal.logging.slf4j.Slf4jLog info INFO: Current version of schema "main": 3 May 27, 2024 9:28:20 PM org.flywaydb.core.internal.logging.slf4j.Slf4jLog info INFO: Schema "main" is up to date. No migration necessary. Exception in thread "main" java.lang.IllegalStateException: Failed to the RTM endpoint URL (error: not_allowed_token_type) at com.github.seratch.jslack.Slack.rtmConnect(Slack.java:157) at com.github.seratch.jslack.Slack.rtmConnect(Slack.java:132) at com.github.seratch.jslack.Slack.rtm(Slack.java:123) at com.botdarr.clients.slack.SlackBootstrap.init(SlackBootstrap.java:36) at com.botdarr.BotdarrApplication.main(BotdarrApplication.java:13) 2024-May-27 21:28:20 PM [main] WARN com.botdarr.Config - Lidarr commands are not enabled, make sure you set the lidarr url, path, token, default profile

Press ANY KEY to close this window

shayaantx commented 4 months ago

@ImagineerNL ill run thru steps 2moro night or next night and see if i can reproduce

shayaantx commented 4 months ago

@ImagineerNL I ran through https://github.com/shayaantx/botdarr/wiki/Install-Slack-Bot and didn't have an issue (well I was running an older jdk 8 and got certificate errors, but once I upgraded it was fine)

I did update slack api https://github.com/shayaantx/botdarr/pull/124, but I couldn't reproduce your error

Did you create a classic app? or a modern one? (looks like eventually classic apps are gonna die, so guess these instructions will need to change)

image

If you're on discord or matrix or slack, post your handle, and I can look at your issue live too

ImagineerNL commented 4 months ago

I'll dig a bit further in what it might be, thanks for looking. I assume it was a classic app, that might have been the issue

ACupOfAvgJoe commented 3 months ago

classic Slack apps are no longer supported, any chance there will be support for modern apps? getting the same not_allowed_token_type error.