raku-api-discord
raku-api-discord copied to clipboard
Raku module for interacting with the Discord API.
We don't want to supply the bot's own messages to the message supply because ignoring your own messages is tedious boilerplate. So we can add a Promise to the created...
Rakudo now already has a Apple Silicon formula on Homebrew, Zef also compiles without any problem, and running a simple Hello World Raku program also has no problem at all...
`API::Discord::Log` - can probably be very easily based on an existing log module in the ecosystem. Then remove all the `say`, `note`, `warn` etc
Currently, we hardcode the gateway URL like so; ```raku #| Host to which to connect. Can be overridden for testing e.g. has Str $.ws-host = 'gateway.discord.gg'; ``` According to the...
Currently if you want to do stuff with member permissions you must explicitly specify `use API::Discord::Permissions;` in your code which seems awfully inconvenient for a feature that the majority of...
When identifying to the gateway, you can specify an `intents` parameter which allows you to conditionally subscribe to pre-defined "intents", groups of events defined by Discord. If you do not...
This would hold middleware to collect information from Cro, plus procedures to access the collected data. Actual data collected TBC. Currently we are thinking of memory usage and throughput.
Here's a simple Discord bot. It prints out when somebody adds a reaction to the message. ``` #!raku use API::Discord; sub MAIN(Str $token) { my $discord = API::Discord.new(:$token); $discord.connect; await...
There are a few places where we currently just parse JSON and send the hash all the way to the user. We should make sure JSON responses are turned into...
I've been putting off behavioural tests - integration tests, I guess - because I don't know how to achieve it. What we really need to be able to test is...