Availability
| Edition | Deployment Type |
|---|---|
| Community & Enterprise | Self-Managed, Hybrid |
Manifest Structure
Edge Gateway Plugins
Edge Gateway plugins don’t use JSON manifests. Configuration is provided via the API when creating the plugin:pre_auth- Before authenticationauth- Custom authenticationpost_auth- After authenticationon_response- Response modificationdata_collection- Data export
AI Studio UI Plugins
Complete manifest structure for UI plugins:Expandable
AI Studio Agent Plugins
Agent plugin manifests are simpler (no UI):Expandable
Object Hooks Plugins
Object hooks plugins intercept CRUD operations on platform objects. These plugins use the unified SDK and register hooks programmatically, so the manifest doesn’t need special hook configuration.Basic Object Hooks Manifest
Expandable
GetObjectHookRegistrations() method in the plugin code, not in the manifest. The plugin_type is "ai_studio" since object hooks are Studio-only.
Hook Registration (Code, Not Manifest)
Object hooks are registered programmatically:Expandable
llm- LLM provider configurationsdatasource- Data source connectionstool- External tool definitionsuser- User accounts
before_create- Before object creation (can block)after_create- After object creation (notification only)before_update- Before object update (can block)after_update- After object update (notification only)before_delete- Before object deletion (can block)after_delete- After object deletion (notification only)
Multi-Capability with Hooks
Object hooks plugins can combine hooks with UI:Expandable
- Register
before_createhooks for datasources (via code) - Block creation and add to pending approvals
- Provide UI dashboard to approve/reject
- Use RPC methods for approval actions
examples/plugins/studio/llm-validator/ and examples/plugins/studio/hook-test-plugin/ for complete examples.
Resource Provider Plugins
Resource Provider plugins register custom resource types that integrate into the App creation flow. Declare resource types in the manifest’sresource_types section:
Expandable
ResourceProvider methods programmatically for runtime behavior.
| Field | Required | Description |
|---|---|---|
slug | Yes | Machine-readable identifier, unique per plugin |
name | Yes | Display name shown in the App form |
has_privacy_score | No | Whether instances carry privacy scores (default: false) |
supports_submissions | No | Whether community users can submit instances (default: false) |
form_component | No | Custom Web Component for the App form selector |
Service Scopes Reference
LLM Scopes
| Scope | Description | Operations |
|---|---|---|
llms.read | Read LLM configurations | List LLMs, Get LLM details, Get LLM counts |
llms.write | Create/update LLMs | Create LLM, Update LLM, Delete LLM |
llms.proxy | Call LLMs via proxy | CallLLM (streaming/non-streaming) |
Tool Scopes
| Scope | Description | Operations |
|---|---|---|
tools.read | Read tool configurations | List Tools, Get Tool details |
tools.execute | Execute tools | ExecuteTool with operation and parameters |
tools.write | Create/update tools | Create Tool, Update Tool, Delete Tool |
tools.operations | Manage tool operations | Add/remove operations |
Datasource Scopes
| Scope | Description | Operations |
|---|---|---|
datasources.read | Read datasource configurations | List Datasources, Get Datasource details |
datasources.query | Query datasources | QueryDatasource with SQL/query DSL |
datasources.write | Create/update datasources | Create, Update, Delete Datasources |
App Scopes
| Scope | Description | Operations |
|---|---|---|
apps.read | Read app configurations | List Apps, Get App details |
apps.write | Create/update apps | Create App, Update App, Delete App |
Plugin Scopes
| Scope | Description | Operations |
|---|---|---|
plugins.read | Read plugin configurations | List Plugins, Get Plugin details, Get counts |
plugins.write | Create/update plugins | Create Plugin, Update Plugin |
KV Storage Scopes
| Scope | Description | Operations |
|---|---|---|
kv.read | Read plugin KV storage | ReadPluginKV, ListPluginKVKeys |
kv.readwrite | Read/write plugin KV storage | Read + WritePluginKV, DeletePluginKV |
Analytics Scopes
| Scope | Description | Operations |
|---|---|---|
analytics.read | Read analytics data | GetUsageStats, GetCostAnalytics |
analytics.write | Write analytics data | RecordCustomMetric |
UI Slot System
Available Slots
sidebar.section
Add a collapsible section to the sidebar with nested items:Expandable
sidebar.link
Add a single link to the sidebar:settings.section
Add a section to the Settings page:app.detail.tab
Add a tab to App detail pages:llm.detail.tab
Add a tab to LLM detail pages:Mount Configuration
WebComponent Mount
kind: Must be"webc"for WebComponentstag: Custom element tag nameentry: Path to JavaScript file (relative to plugin)props: Properties passed to the component
Permission Validation
Permissions are validated when plugins call the Service API:Configuration Schema
Plugins can provide JSON Schema for their configuration:Expandable
- Validate configuration on save
- Generate UI forms
- Provide inline documentation
- Set default values
Security Best Practices
Principle of Least Privilege
Only request scopes your plugin actually needs:Content Security Policy
Define CSP headers for UI plugins:Input Validation
Always validate inputs in RPC methods:Expandable
Secrets Management
Never hardcode secrets in manifests or code:Versioning and Compatibility
Semantic Versioning
Use semantic versioning for plugin versions:- MAJOR: Breaking changes
- MINOR: New features, backward compatible
- PATCH: Bug fixes, backward compatible
Compatibility Declaration
Declare platform compatibility:Testing Manifests
Validation
Validate your manifest before deployment:Common Errors
| Error | Cause | Solution |
|---|---|---|
| ”Invalid plugin_type” | Wrong plugin type | Use "ai_studio" or "agent" |
| ”Missing required field” | Missing manifest field | Add id, name, version |
| ”Invalid scope” | Unknown service scope | Check scope name spelling |
| ”Duplicate UI slot” | Slot registered twice | Remove duplicate slot |
| ”Asset not found” | Missing embedded file | Verify //go:embed directive |
Complete Examples
Minimal UI Plugin
Expandable
Full-Featured UI Plugin
See plugins-studio-ui.md for complete rate-limiting-ui example.Minimal Agent Plugin
Advanced Agent Plugin
Expandable