Commit graph

9 commits

Author SHA1 Message Date
Nick Misasi
9b43bb3542 docs(13-04): create example plugin CLAUDE.md
Add AI development guidance for plugin developers using the hello_python
example as a template. Includes setup commands, architecture overview,
hook patterns, API usage, and best practices.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-20 10:41:03 -05:00
Nick Misasi
feec91ade1 feat(13-03): create example plugin Makefile with all targets
Add Makefile for hello_python example with development workflow targets:
- venv: Create virtual environment with SDK and dependencies
- install: Install/update dependencies in existing venv
- dist: Package plugin as tar.gz with vendored SDK
- dist-minimal: Package plugin without SDK (server must have SDK)
- clean: Remove build artifacts
- run: Run plugin locally for testing
- lint: Run type checking on plugin code
- help: Show available targets and development workflow

This Makefile serves as a template for Python plugin developers.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-20 10:37:08 -05:00
Nick Misasi
ddbcc2d164 feat(python-sdk): export Command class and register command in example
- Export Command wrapper class from main package
- Update hello_python example to register /hello command in OnActivate
- Slash commands must be registered via api.register_command() to work

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-19 23:13:13 -05:00
Nick Misasi
da0bda1d10 docs(hello_python): add critical venv bundling notes
- Use --copies flag when creating venv for distribution
- Symlinks point to build machine paths and won't work after extraction
- Avoid -e (editable) installs which reference local paths

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-19 23:03:59 -05:00
Nick Misasi
3425ad1d0e docs(hello_python): add packaging and deployment instructions
Add comprehensive documentation for:
- Two packaging options (system Python vs bundled venv)
- Three deployment methods (UI, mmctl, API)
- Installation verification steps
- Troubleshooting guide for common issues

Also fixes the manifest example to use server.executable
instead of non-existent python.entry_point field.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-19 22:57:47 -05:00
Nick Misasi
4d73a9e4cc fix(example): use server.executable instead of python.entry_point
The ManifestPython struct doesn't have an entry_point field.
Python plugins should specify their script in server.executable.
2026-01-19 22:45:44 -05:00
Nick Misasi
777ed118c3 docs(10-01): add README for example Python plugin
Document the hello_python example plugin including:
- Plugin structure and file explanations
- Development and production installation steps
- Hook descriptions (OnActivate, OnDeactivate, MessageWillBePosted, ExecuteCommand)
- Usage patterns and next steps

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-19 15:28:25 -05:00
Nick Misasi
dcf2d8ba4b feat(10-01): implement example plugin with multiple hooks
Add plugin.py demonstrating SDK capabilities:
- OnActivate: Log activation, get server version via API
- OnDeactivate: Log deactivation
- MessageWillBePosted: Simple word filter example
- ExecuteCommand: /hello command with subcommand support

Also add requirements.txt specifying SDK dependency.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-19 15:27:55 -05:00
Nick Misasi
174e967a12 feat(10-01): create example plugin manifest with Python runtime fields
Add plugin.json for hello_python example plugin demonstrating:
- server.runtime: "python" field for Python plugin detection
- server.python_version: ">=3.9" minimum requirement
- server.python.entry_point: "plugin.py" entry point

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-19 15:27:06 -05:00