Plugin Info • Rust AI Agent SDK
PluginInfo: Information about a plugin.
PluginInfo
Defined in the plugins module.
Rust AI Agent SDK
Information about a plugin.
Fields
| Name | Type | Description |
|---|---|---|
name | String | Plugin name |
version | String | Plugin version |
description | String | Plugin description |
plugin_type | PluginType | Plugin type |
hooks | Vec<PluginHook> | Hooks this plugin listens to |
enabled | bool | Whether the plugin is enabled |
Methods
new
fn new(name: impl Into<String>) -> SelfCreate new plugin info
Parameters:
| Name | Type |
|---|---|
name | impl Into<String> |
version
fn version(mut self, version: impl Into<String>) -> SelfSet version
Parameters:
| Name | Type |
|---|---|
version | impl Into<String> |
description
fn description(mut self, description: impl Into<String>) -> SelfSet description
Parameters:
| Name | Type |
|---|---|
description | impl Into<String> |
plugin_type
fn plugin_type(mut self, plugin_type: PluginType) -> SelfSet plugin type
Parameters:
| Name | Type |
|---|---|
plugin_type | PluginType |
hook
fn hook(mut self, hook: PluginHook) -> SelfAdd hook
Parameters:
| Name | Type |
|---|---|
hook | PluginHook |
hooks
fn hooks(mut self, hooks: Vec<PluginHook>) -> SelfAdd multiple hooks
Parameters:
| Name | Type |
|---|---|
hooks | Vec<PluginHook> |
Source
View on GitHubpraisonai/src/plugins/mod.rs at line 107