Plugin development
HarborClient plugins extend the app with installable packages: custom settings panels, sidebar views, request tabs, appearance themes, File → Import handlers, HTTP hooks, and persistent storage. Each plugin ships as a HarborClient plugin file (.hcp) containing a manifest.json and bundled JavaScript. A .hcp file is a normal ZIP archive — the extension is a naming convention only, not a separate container format. Plugins use the same hc namespace as request scripts, but with a broader API suited to long-lived extensions.
Themes are plugins too: declare contributes.themes, register with hc.themes.register, and include "categories": ["themes"] when the package should appear under File → Themes rather than File → Plugins.
To install or manage plugins in the app, see Plugins (File → Plugins) or browse the plugin marketplace. For theme packages, see Themes (File → Themes). This guide covers package layout, the manifest, APIs, examples, and the development workflow.
Guide
- Install — add
@harborclient/sdkto your plugin project - Quick start — minimal renderer and main entry examples
- Package layout — directory structure for a
.hcppackage - Manifest —
manifest.jsonfields, metadata, and contribution types - Permissions — capability model and install-time grants
- Architecture — renderer vs main runtimes and plugin lifecycle
- Building — bundling and packaging as
.hcp - Dev workflow — unpacked loading, hot reload, and startup options
- Renderer API —
PluginContext, React/JSX, and host integration - UI contributions — settings panels, tabs, menus, Action menu actions, and toolbar actions
- Themes and storage — themes, commands, storage, and filesystem
- Main API — HTTP hooks and IPC in the SES utilityProcess
- Snippets — types and import syntax for request script snippet files
- Components — interactive component explorer (Storybook)
- Examples — request logger, audit tab, Solarized theme, and import handler
- Marketplace — publish to the HarborClient plugin catalog
- Performance — IPC and rendering best practices
- Plugins vs scripts — how plugins differ from request scripts