Part of the Discord ecosystem · 7 projects
This module integrates with the DiscordPHP library to provide Drush commands and dispatch Symfony events for Discord interactions. It allows you to automate actions like logging messages when the Discord loop is ready or sending replies to specific Discord messages.
Features
Using the team-reflex/discord-php-package, this module offers a drush-command to start the included ReactPHP-loop and dispatches Symfony-events for certain things that happen inside it.
Use-cases/examples for ECA (see attachment)
- Log a watchdog-message when the DiscordPHP-loop is ready
- Send a reply when a certain message is posted in a channel
Make sure that you enable the ECA-submodule if you want to import that example-model.
A typed-data definition and a normalizer for the DiscordPHP Message-class is also present, this allows you to see which tokens are available when those Symfony-events are fired.
Post-Installation
- Generate a bot and write down its token
- Change the installed key-configuration by pasting your Discord-bot token
Additional Requirements
- For the
discrd_php_eca-submodule, the ECA-module is required
Recommended modules/libraries
Community Documentation
Ask your assistant about DiscordPHP
Check compatibility with your Drupal and PHP version, maintenance and security coverage, from current release data. How it works
Depends on
Dependencies of the latest stable release
Required by
Tracked projects that depend on this one
No tracked projects depend on this one yet.
More in the Discord ecosystem
Most installed first
Activity
Release Timeline
Releases
| Version | Type | Core | PHP | Release date | |
|---|---|---|---|---|---|
| 2.0.0 | Stable | 10–11 | PHP >=8.1 | Jun 24, 2024 | |
| 1.0.0 | Stable | 9–10 | PHP >=8.1 | Jun 24, 2024 | |
| 1.0.0-rc2 | Pre-release | 9–10 | PHP >=8.1 | Jun 5, 2024 | |
| 2.0.x-dev | Dev | 10–11 | PHP >=8.1 | May 1, 2024 | |
| 1.0.0-rc1 | Pre-release | 9–10 | PHP ^7.4 || ^8.0 | May 1, 2024 | |
| 1.0.x-dev | Dev | 9–10 | PHP >=8.1 | Feb 12, 2024 |