Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create a middleware feature that gives direct access to plugins #26

Open
kyrivanderpoel opened this issue Oct 29, 2017 · 0 comments
Open
Assignees

Comments

@kyrivanderpoel
Copy link
Collaborator

Plugins currently do not have access to other plugins. It would be useful to write plugins that can run or modify multiple plugins at runtime. Potential use cases would be a logging, wrapping plugins with authentication so Discord users could have access to some plugins restricted or turned off, or listing all features available to the user, as defined by its plugins.

Middleware will be a logical extension of plugins. They may have a chat interface, but they might not. I believe that will one of the defining features: most if not all plugins should define a command, but some middleware may not define a command.

Summing up, middleware:

  • Will be given a similar interface to plugins in that they may have a command interface
  • May act without a discord command interface
  • Will have access to the plugins variable from the discord client, allowing middleware to operate on plugins

The choice between developing a plugin or middleware will be fairly simple: if one needs to develop a command interface or backend operation that needs access to plugins, one will use middleware. Otherwise, one will likely make a plugin.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant