A minimal oh-my-pi extension that demonstrates the two most common authoring patterns: subscribing to session_start to notify on load, and registering a /hello slash command that sends a greeting into the conversation. It is intentionally small β use it as a copy-paste starting point for your own extension.
Install
Option A β drop into user extensions directory:
cp -r . ~/.omp/agent/extensions/hello-extension
Restart omp. You will see the startup notification immediately.
Option B β point the settings extensions array at it:
# ~/.omp/agent/config.yml
extensions:
- /path/to/hello-extensionOption C β load once via CLI flag:
omp --extension ./hello-extension
Usage
After loading, type /hello or /hello Ada in the omp prompt. The command sends a visible greeting custom message into the conversation and shows a βMessage sent!β notification.
What it demonstrates
- Default export factory receiving
ExtensionAPI pi.on("session_start", ...)β session lifecycle hookpi.registerCommand(...)β slash command registrationctx.ui.notify(...)β user-facing notificationpackage.jsonwithomp.extensionsmanifest field