Agent-Logs-Url: https://github.com/J3vb/OwnCord/sessions/2d415fd9-6138-495b-ac29-c54d08ae4ce4 Co-authored-by: J3vb <192430104+J3vb@users.noreply.github.com>
hello plugin
Phase C Step 9 — proof-of-life plugin used by Server/plugin/plugin_test.go.
Manifest
plugin.json declares the commands, events, and storage capabilities.
The manifest is the only file the default (no--tags wazero) build needs —
the registry persists it into the plugins table without executing the .wasm.
Building the WASM
The .wasm binary is intentionally NOT checked in. Build it locally with TinyGo
or any other WASM toolchain that emits a module exporting command_dispatch,
on_event, and _start:
# TinyGo example (writes hello.wasm into this directory)
tinygo build -o hello.wasm -target wasi ./main.go
A trivial main.go that satisfies the host API is sketched in
Server/plugin/sandbox_wazero.go's docstring.
Tests
Server/plugin/plugin_test.go exercises the manifest parser and the loader
against this directory. It does not require the .wasm to be present —
manifest-only validation is the default-build coverage path.