Files
cinny-desktop/PLUGINS.md
Max Litruv Boonzaayer a4429fe9c2 feat: Add comprehensive plugin API documentation and example plugin
- Introduced PLUGIN_API.md for detailed plugin development guidelines.
- Implemented PLUGIN_SYSTEM_IMPLEMENTATION.md summarizing all requested features.
- Created example-plugin showcasing all API features including commands, message interceptors, settings, and notifications.
- Added plugin-metadata.json for the example plugin with relevant metadata.
2026-04-18 02:55:38 +10:00

4.4 KiB

Paarrot Plugin System

The Paarrot desktop client includes a powerful plugin system that allows you to extend and customize your Matrix experience.

What are Plugins?

Plugins are small JavaScript modules that run inside Paarrot and can:

  • Add custom commands
  • Modify the UI
  • React to Matrix events
  • Add new settings sections
  • Enhance functionality

Installing Plugins

From the Plugin Marketplace

  1. Open SettingsPlugins
  2. Browse the Marketplace tab
  3. Click Install on any plugin you want to add
  4. The plugin will be downloaded and enabled automatically

Manual Installation

  1. Download a plugin ZIP file
  2. Extract it to your plugins directory:
    • Windows: %APPDATA%\paarrot\plugins\
    • Linux: ~/.config/Paarrot/plugins/
    • macOS: ~/Library/Application Support/Paarrot/plugins/
  3. Restart Paarrot
  4. Enable the plugin in SettingsPluginsInstalled

Managing Plugins

Viewing Installed Plugins

Go to SettingsPluginsInstalled to see all installed plugins.

Enabling/Disabling Plugins

Click the toggle switch next to any plugin to enable or disable it. Disabled plugins won't run or use resources.

Uninstalling Plugins

Click the Uninstall button next to any plugin to remove it completely.

Searching Plugins

Use the search bar to filter plugins by name, description, author, or tags.

Plugin Security

⚠️ Important Security Information

Plugins run with access to your Matrix client and can:

  • Read your messages
  • Send messages on your behalf
  • Access your room list
  • Modify app behavior

Only install plugins from trusted sources!

Safety Tips

  1. Check the author: Install plugins from known developers
  2. Read reviews: Look for community feedback
  3. Review permissions: Understand what the plugin can do
  4. Keep updated: Update plugins regularly for security fixes
  5. Report issues: If a plugin behaves suspiciously, report it immediately

Developing Plugins

Want to create your own plugin? Check out the Plugin Development Guide.

Quick Start

  1. Create a plugin directory with:

    • index.js - Your plugin code
    • plugin-metadata.json - Plugin information
  2. Implement the plugin interface:

module.exports = {
  onLoad: async (context) => {
    // Your plugin initialization
    console.log('Plugin loaded!');
  },
  onUnload: async () => {
    // Cleanup when disabled
  }
};
  1. Test locally by copying to your plugins directory

  2. Publish to the Plugin Directory

Plugin API

Plugins have access to:

  • Matrix Client: Full matrix-js-sdk client instance
  • React: For building UI components
  • Commands: Register custom slash commands
  • UI Hooks: Inject UI elements
  • Settings: Add custom settings sections
  • Utilities: Notifications and helpers

See the Plugin Development Guide for complete API documentation.

Example Plugins

Check out the example-plugin/ directory for a simple example demonstrating:

  • Matrix client access
  • Event listeners
  • Custom commands
  • Notifications

Troubleshooting

Plugin Won't Load

  1. Check the browser console for errors (F12 → Console)
  2. Look for [PluginLoader] messages
  3. Verify index.js exists in the plugin directory
  4. Ensure plugin-metadata.json is valid JSON

Plugin Crashes

  1. Disable the plugin in Settings → Plugins
  2. Check console for error stack traces
  3. Report the issue to the plugin author
  4. Try reinstalling the plugin

Performance Issues

If Paarrot becomes slow:

  1. Disable plugins one by one to identify the culprit
  2. Check for memory leaks in the console
  3. Contact the plugin author with details

Plugin Directory

The official Paarrot Plugin Directory is maintained at: https://github.com/Paarrot/Plugin-Directory

Submit your plugins there to make them available in the marketplace!

Support

License

Plugins are independent works and have their own licenses. Check each plugin's metadata for license information.