bookclerk_plugin_sdk::protocol

Development These docs follow the development version and change with every merge.

Last updated View as Markdown

Shared role method names and typed method payloads.

Audience: guest authors who need the Cap'n Proto method parameter / result structs (generated from schema/plugin.capnp) without depending on host crates. Wire types live in bookclerk_plugin_abi; this module re-exports them for a stable SDK import path.

Trust boundary

External plugins are untrusted relative to the host. The host must never hand them library.db, master.key, or the Bookclerk files-dir root. Plugins receive only a scoped plugin_data_dir / cache_dir, and credentials are host-mediated (login returns a blob the host seals; scan and fetch receive that blob from the host). Scan returns book DTOs for the host to upsert.

Prefer product docs under docs/plugins/README.md for jail / capability rules.

Item Kind Summary
PROTOCOL_NAME constant Logical ABI identifier for diagnostics (not a plugin.toml field).
MAX_RPC_LINE_BYTES constant Maximum length of one framed bridge line in bytes (including newline).

Re-exports

Constants

PROTOCOL_NAME

pub const PROTOCOL_NAME: &str = "workers-rpc";

Logical ABI identifier for diagnostics (not a plugin.toml field).

Manifests advertise compatibility via api_version only.

MAX_RPC_LINE_BYTES

pub const MAX_RPC_LINE_BYTES: usize = _;

Maximum length of one framed bridge line in bytes (including newline).

Used by the workerd bridge framing. Currently 16 MiB.

Generated from crates/bookclerk-plugin-sdk at main · View as Markdown