Storyden

Plugin Model

The architecture and lifecycle model for Storyden plugins.

Plugins in Storyden are installed resources with a manifest contract, a runtime mode, and an authenticated RPC session.

Manifest is source of truth

A plugin manifest defines:

  • Identity (id, name, author, version)
  • Event subscriptions (events_consumed)
  • Optional API identity requirements (access)
  • Optional configuration contract (configuration_schema)
  • If the plugin is supervised:
    • Runtime entrypoint (command, and optional args)

Storyden uses this as the primary contract for install and runtime behaviour for both supervised and external plugins. See Manifest -> top-level fields for the generated schema reference.

Two plugin modes

Supervised

Supervised plugins are packaged and run by Storyden itself.

  • Installed from an archive (.sdx / .zip payload)
  • Process lifecycle managed by Storyden itself, supervised plugins cannot reconnect on their own
  • Runtime provider is configurable:
  • Storyden can enable and disable
  • Logs are collected and viewable in the Plugins section of Settings

External

External plugins run outside Storyden and connect in over authenticated WebSocket RPC.

  • Installed/updated via pasting a manifest YAML/JSON
  • No process management by Storyden
  • No host-managed log stream
  • Connection authenticated with an external RPC token
  • Token lifecycle and security model are documented in Security -> RPC authentication model

External mode is the easiest way to iterate during plugin development because the plugin process and debugger are fully under your control.

2026-02-19-19-39-09.png

Session lifecycle

At runtime, plugins attach as sessions.

High-level flow:

  1. Plugin installed
  2. (If supervised) Plugin is activated and started on the configured runtime provider
  3. Plugin connects and authenticates over RPC
  4. Host marks session as connected/active
  5. RPC requests and events flow in both directions
  6. Disconnect, unload, token cycle, or state change tears session down

For protocol-level details, see API Overview -> How the two layers fit and RPC Reference.

Event delivery model

Event subscriptions are explicit.

A plugin receives only what it declares in events_consumed, and event delivery is done via typed host-to-plugin RPC methods. See Manifest -> events_consumed and RPC -> Host to Plugin -> event.

Configuration model

Plugin configuration has two layers:

  • configuration_schema in the manifest (shape contract for UI + validation)
  • Stored config values (runtime data)

When config changes, Storyden validates and sends configure RPC to the plugin.

Plugins can also call get_config RPC when needed. See Manifest -> configuration_schema, RPC -> configure, and RPC -> get_config.

On this page