Plugin API Reference
Most AuraBoot plugins are pure configuration (JSON DSL). When configuration is not enough, the Plugin API exposes two surfaces:
- SPIs — extension points you implement (annotate with
@Extension) to contribute behavior into the platform's pipelines. - Services — host-managed beans you inject (
@Autowired) to call platform capabilities.
Discovery is built on PF4J (classloader isolation, lifecycle, extension index) layered on Spring (DI, transactions). Plugins are discovered via plugin.json + META-INF/extensions.idx and managed through the Plugin Marketplace.
Lifecycle
Every plugin extends AuraPlugin. The base class exposes the lifecycle as final methods and dispatches to the protected do* hooks you override; the constructor and getNamespace() are required:
public class MyPlugin extends AuraPlugin {
public MyPlugin(PluginWrapper wrapper) { super(wrapper); }
@Override public String getNamespace() { return "my-plugin"; }
@Override protected void doInstall(PluginInstallContext context) { /* one-time setup */ }
@Override protected void doEnable(PluginEnableContext context) { /* register, start workers */ }
@Override protected void doDisable(PluginDisableContext context) { /* unregister, stop workers */ }
@Override protected void doUninstall(PluginUninstallContext context) { /* cleanup persistent state */ }
}Each lifecycle hook receives its own context type (PluginInstallContext / PluginEnableContext / PluginDisableContext / PluginUninstallContext), all of which extend PluginContext. PluginContext exposes getTenantId(), getPluginId(), getNamespace(), getVersion(), getSettings(), and getSetting(key) / getSetting(key, defaultValue). To call host services, inject them via Spring @Autowired (see below).
SPIs (extension points)
| SPI | Purpose |
|---|---|
| CommandHandlerExtension | Hook into the Command Pipeline at preExecute / postExecute / onError. |
| EventListenerExtension | Subscribe to outbox-published domain events (at-least-once). |
| DataProviderExtension | Supply dynamic data sources to Page Blocks, dashboards, reports. |
| ValidatorExtension | Field-level / cross-field validation beyond DSL constraints. |
| MenuProviderExtension | Contribute menu items dynamically from a plugin. |
RestEndpointExtension | Register custom REST routes served by the platform dispatcher at /api/ext/{namespace}/**. |
Services (host beans)
| Service | Purpose |
|---|---|
| MetaModelService | Read model / field / page / command metadata after overlay merge. |
| DataAccessor | Parameterized CRUD over mt_<modelCode> tables with tenant scope. |
| ConversationTurnService | The single chokepoint every chat / agent / ACP turn must traverse. |
| CommandExecutor | Programmatic entry to the Command Pipeline. |
Spring bean injection
All @Extension classes are Spring-managed; inject any host service via @Autowired. Use @Autowired(required = false) for optional accessors (such as FileAccessor, AiProviderAccessor, KnowledgeBaseAccessor) so the plugin runs against both OSS and enterprise platforms.
Publishing to the Marketplace
- Validate —
aura plugin validate plugins/my-plugin - Package — the CLI bundles JSON resources and compiled extensions
- Publish — upload to the Marketplace or distribute as a zip
- Install — other tenants install via the Marketplace UI or
aura plugin publish
Marketplace metadata lives under plugin.json → marketplace:
{
"marketplace": {
"category": "CRM",
"tags": ["sales", "lead-management"],
"screenshots": ["screenshot-1.png", "screenshot-2.png"],
"pricing": "free",
"supportUrl": "https://github.com/yourorg/my-plugin/issues"
}
}Next steps
- Plugin development walkthrough
- Commands pipeline — phases your SPIs hook into
- REST API — HTTP equivalent for testing your plugin