XF2 [8WR] Discord Integration

XF2 [8WR] Discord Integration [Paid] 2.1.1.9

No permission to buy ($30.00)
Is there any way to completely mirror threads with text channels? (including embedded images)

Reply in Discord -> Reply also gets made on forum with you username
Reply in Xenforo -> Reply also gets made on Discord with your username

I'd enable slow-chat to avoid spam.

---

EDIT: If the above is not possible I'd just wish that the bot for notifying about posts/thread would also display (embed) images.
Thanks!
 
Last edited:
Jaxel updated XF2 [8WR] Discord Integration with a new update entry:

2.1.1.7 - CHANGELOG

  • When posting messages to Discord, their rate limits only allow 5 posts per second. So if XenRio tried to post new streams, and there were more than 5 streams, many streams would get lost. I've added a small delay per post, so that all streams get posted.
  • Over time, the cached data for connected accounts gets lost. This is EXPECTED BEHAVIOR, as outlined by XenForo staff here...

Read the rest of this update entry...
 
Is there any way to completely mirror threads with text channels? (including embedded images)

Reply in Discord -> Reply also gets made on forum with you username
Reply in Xenforo -> Reply also gets made on Discord with your username

I'd enable slow-chat to avoid spam.

---

EDIT: If the above is not possible I'd just wish that the bot for notifying about posts/thread would also display (embed) images.
Thanks!
Hey @Jaxel could you let me know if you have any plans in supporting these things in the future?
  • Sync threads: create a channel and connect it with a forum topic. Replying on forums or discords works in two ways. You reply on the forum and your reply also gets posted in the channel, and vice versa
  • Let the "bot" display images, now image replies are just empty:
    PHqQjaX.png
 
Using the latest version, our XF error log is getting flooded with errors at the rate of roughly one a second:

ErrorException: [E_NOTICE] Trying to access array offset on value of type null
src/addons/EWR/Discord/Listener/Navigation.php:13
Generated by: Unknown account

Stack trace​

#0 src/addons/EWR/Discord/Listener/Navigation.php(13): XF::handlePhpError()
#1 [internal function]: EWR\Discord\Listener\Navigation::navigationSetup()
#2 src/XF/Extension.php(67): call_user_func_array()
#3 src/XF/App.php(2654): XF\Extension->fire()
#4 src/XF/Pub/App.php(572): XF\App->fire()
#5 src/XF/Pub/App.php(513): XF\Pub\App->getNavigation()
#6 src/XF/App.php(1995): XF\Pub\App->renderPageHtml()
#7 src/XF/Mvc/Dispatcher.php(402): XF\App->renderPage()
#8 src/XF/Mvc/Dispatcher.php(58): XF\Mvc\Dispatcher->render()
#9 src/XF/App.php(2184): XF\Mvc\Dispatcher->run()
#10 src/XF.php(391): XF\App->run()
#11 index.php(20): XF::runApp()
#12 {main}

Request state​

array(4) {
["url"] => string(68) "/forum/threads/thread-name.11232/"
["referrer"] => string(23) "https://www.google.com/"
["_GET"] => array(0) {
}
["_POST"] => array(0) {
}
}

@Jaxel We moved to a newer version of PHP (7.4.3) which I suspect may play a part in this. I am not observing any functional issues/bugs, but these errors are killing the utility of the XF error log since any meaningful errors are buried under so many of these.
 
Hello, I've read the F.A.Q I got everything set up. When I link discord it auto adds the ranks normally.

However, when I remove the rank from myself inside discord, it will not auto-update and remove the rank on the forums. @Jaxel
 
I've been able to scope down the issue to the option to display the online count alongside the navigation element for Discord. I didn't realize this initially because I didn't think we had this enabled, as this hasn't displayed for a long time. However, if I disable the option to display this count, the errors go away. Per my first post, I suspect that we simply didn't notice that this count was no longer working, until we updated PHP and the underlying error started surfacing in the error log.

Searching this thread, the only mention of issues with the online count is an API change that Discord made almost a year ago, but the add-on was updated since to accommodate this change. So I'm unsure how to get this online count working again, though the more immediate problem of the error deluge is (thankfully) resolved.
 
I have it fixed for the next version. I have several updates to a bunch of my addons due to PHP changes; but I'm in the process of moving into a new place, so I haven't released the updates yet.
 
@Jaxel Sounds good - we would like to use the online count, but it's a minor feature so there's no urgency there. Thanks much for the update and best of luck with the move (y)
 
I've been able to scope down the issue to the option to display the online count alongside the navigation element for Discord. I didn't realize this initially because I didn't think we had this enabled, as this hasn't displayed for a long time. However, if I disable the option to display this count, the errors go away. Per my first post, I suspect that we simply didn't notice that this count was no longer working, until we updated PHP and the underlying error started surfacing in the error log.

Searching this thread, the only mention of issues with the online count is an API change that Discord made almost a year ago, but the add-on was updated since to accommodate this change. So I'm unsure how to get this online count working again, though the more immediate problem of the error deluge is (thankfully) resolved.
Do you have your Discord Server's widget enabled? The addon can't get your server's information, including the online count, if the widget is disabled.
 
Do you have your Discord Server's widget enabled? The addon can't get your server's information, including the online count, if the widget is disabled.

Aha! We did, but I disabled/re-enabled it on Discord, and disabled/re-enabled the online count on XenForo, and now it appears to be working perfectly. Not sure why it broke, but happy to have it functioning again.
 
Did you revoke your bot permissions? Did you disable your server's widget?
No didn't change any perms it seemed to have fixed itself the next day. I had about 50+ members signing up and joining the forums at once doing so somehow rate limited the discord bot and prevented the SYNC settings and prevented users from using the discord bot to sign up. So something with rate-limiting when mass members signing up at once.
 
@Jaxel It also appears that role syncing is not working for our integration - we have not changed anything with the integration and it was working earlier. Is this related to PHP version 7.4.10? or the latest Discord updates? We have not changed anything on the Xenforo side.

I noticed the latest with the widget bot and just set it default. - I am taking it this feature is optional and being disabled is fine - does this have to be set for role syncing to work?

1607996636959.png
 
@Jaxel It also appears that role syncing is not working for our integration - we have not changed anything with the integration and it was working earlier. Is this related to PHP version 7.4.10? or the latest Discord updates? We have not changed anything on the Xenforo side.

I noticed the latest with the widget bot and just set it default. - I am taking it this feature is optional and being disabled is fine - does this have to be set for role syncing to work?

WidgetBot.io is just the web-based Discord client you can optionally use, it shouldn't impact role syncing.

Have you gotten it to work before but find it fails now, or are you setting it up for the first time?

-

On an unrelated note, I have a feature suggestion! May be out of scope for this add-on, but it would be great if we had the ability to send notifications to a specified Discord channel when reports are submitted/resolved/rejected.

I've actually set up this behavior via TH's Notifier add-on to much success, as it gets moderator eyes on reports much more quickly. But it would be preferable to not need an entire separate add-on for that.
 
WidgetBot.io is just the web-based Discord client you can optionally use, it shouldn't impact role syncing.

Have you gotten it to work before but find it fails now, or are you setting it up for the first time?
We have had it running and successfully syncing for about 1 year or more, it seems to have stopped working over the last month or so - at least for a few users in the last month. No settings in the addon have been changed in a very long time.
 
Did you change the roles list order on your server? You can try re-installing the bot by deleting your server ID.
 
Top Bottom