Skip to main content

Module plugin

Module plugin 

Source

Re-exports§

pub use bridge::ChatWriter;
pub use bridge::HistoryReader;
pub use bridge::TeamChecker;
pub use schema::all_known_commands;
pub use schema::builtin_command_infos;
pub use room_plugin_taskboard as taskboard;

Modules§

bridge
Bridge between the abstract plugin framework (room-protocol) and the concrete broker internals (room-cli). This module provides the concrete ChatWriter and HistoryReader types that implement the MessageWriter and HistoryAccess traits respectively.
loader
Dynamic plugin loader using libloading.
queue
schema
stats

Structs§

CommandContext
Context passed to a plugin’s handle method.
CommandInfo
Describes a single command for /help and autocomplete.
ParamSchema
Schema for a single command parameter — drives validation, /help output, and TUI argument autocomplete.
PluginRegistry
Central registry of plugins. The broker uses this to dispatch / commands.
RoomMetadata
Frozen snapshot of room state for plugin consumption.
UserInfo
A user’s online presence.

Enums§

ParamType
The kind of value a parameter accepts.
PluginResult
What the broker should do after a plugin handles a command.

Constants§

PLUGIN_API_VERSION
Current Plugin API version. Increment when the Plugin trait changes in a way that requires plugin authors to update their code (new required methods, changed signatures, removed defaults).
PROTOCOL_VERSION
The room-protocol crate version, derived from Cargo.toml at compile time. Used by the broker to reject plugins that require a newer protocol than the one currently running.

Traits§

HistoryAccess
Async read-only access to a room’s chat history.
MessageWriter
Async message dispatch for plugins. Abstracts over the broker’s broadcast and persistence machinery so plugins never touch broker internals.
Plugin
A plugin that handles one or more / commands and/or reacts to room lifecycle events.
TeamAccess
Read-only access to daemon-level team membership.

Type Aliases§

BoxFuture
Boxed future type used by Plugin::handle for dyn compatibility.