Skip to main content

Plugin API Reference

All plugin endpoints require JWT authentication. The base path is /api/.

Plugin Listing

List All Plugins

Get all available plugins with the current user's installation status.

Endpoint: GET /api/plugins

Query Parameters:

ParameterTypeDescription
categorystringFilter by category (e.g., ai-provider, search)

Response:

{
"plugins": [
{
"id": "openai",
"name": "OpenAI",
"version": "1.0.0",
"description": "Use OpenAI models like GPT-4o for content generation",
"category": "ai-provider",
"capabilities": ["ai-provider"],
"icon": { "type": "svg", "value": "<svg>...</svg>" },
"enabled": true,
"configured": true,
"autoEnable": false,
"systemPlugin": false,
"builtIn": true
}
]
}

Get Settings Menu

Get plugins grouped by category for the settings navigation UI. Only returns plugins that the user has enabled and that have user-configurable settings.

Endpoint: GET /api/plugins/settings-menu

Response:

{
"categories": [
{
"id": "ai-provider",
"label": "AI Providers",
"plugins": [
{
"id": "openai",
"name": "OpenAI",
"icon": { "type": "svg", "value": "..." },
"configured": true
}
]
}
]
}

Get Plugin Details

Get detailed information about a specific plugin, including its settings schema and current user settings.

Endpoint: GET /api/plugins/:pluginId

Response:

{
"id": "tavily",
"name": "Tavily",
"version": "1.0.0",
"description": "Web search and content extraction using Tavily API",
"category": "search",
"capabilities": ["search", "content-extractor"],
"settingsSchema": {
"type": "object",
"properties": {
"apiKey": {
"type": "string",
"title": "API Key",
"x-secret": true,
"x-envVar": "PLUGIN_TAVILY_API_KEY"
}
}
},
"settings": {
"searchDepth": "basic",
"maxResults": 10
},
"enabled": true,
"configured": true,
"readme": "## What does Tavily do?\n\n..."
}
info

Secret fields (x-secret: true) are never returned in settings responses. They appear as masked values or are omitted entirely.

List Plugin Models

For AI provider plugins, fetch the list of available models. The plugin must be enabled and have valid credentials configured.

Endpoint: GET /api/plugins/:pluginId/models

Response:

[
{
"id": "gpt-4o",
"name": "GPT-4o",
"contextLength": 128000,
"capabilities": {
"supportsStreaming": true,
"supportsToolCalling": true,
"supportsVision": true
}
},
{
"id": "gpt-4o-mini",
"name": "GPT-4o Mini",
"contextLength": 128000
}
]

User Plugin Management

Enable Plugin

Enable a plugin for the current user. Optionally provide initial settings.

Endpoint: POST /api/plugins/:pluginId/enable

Body:

{
"settings": {
"maxResults": 20
},
"secretSettings": {
"apiKey": "sk-..."
},
"autoEnableForWorks": true
}
FieldTypeDescription
settingsobjectNon-secret settings to apply
secretSettingsobjectSecret settings (API keys, tokens)
autoEnableForWorksbooleanAuto-enable this plugin for all works

Disable Plugin

Disable a plugin for the current user. This cascades — the plugin will be disabled for all the user's works.

Endpoint: POST /api/plugins/:pluginId/disable

Update Plugin Settings

Update user-specific settings for an enabled plugin.

Endpoint: PATCH /api/plugins/:pluginId/settings

Body:

{
"settings": {
"searchDepth": "advanced",
"maxResults": 20
},
"secretSettings": {
"apiKey": "new-key-..."
},
"metadata": {
"lastConfigured": "2025-01-15"
}
}
FieldTypeDescription
settingsobjectNon-secret settings to update (merged with existing)
secretSettingsobjectSecret settings to update
metadataobjectArbitrary metadata to store with the plugin

Errors:

StatusDescription
400Plugin not enabled for this user
404Plugin not found

Work Plugin Management

Work endpoints manage plugin configuration at the work level. All work endpoints require the user to have edit permissions on the work.

List Work Plugins

Get all plugins with their work-specific configuration.

Endpoint: GET /api/works/:workId/plugins

Response:

{
"plugins": [
{
"id": "openai",
"name": "OpenAI",
"category": "ai-provider",
"enabled": true,
"activeCapability": "ai-provider",
"priority": 1,
"settings": {
"defaultModel": "gpt-4o"
}
}
]
}

Enable Plugin for Work

Enable a plugin for a specific work. The plugin must already be enabled at the user level.

Endpoint: POST /api/works/:workId/plugins/:pluginId/enable

Body:

{
"settings": {
"defaultModel": "gpt-4o-mini"
},
"activeCapability": "ai-provider",
"priority": 1
}
FieldTypeDescription
settingsobjectWork-specific settings overrides
activeCapabilitystringSet this plugin as the active provider for this capability
prioritynumberPriority when multiple plugins provide the same capability

Errors:

StatusDescription
400Plugin not enabled at user level
404Plugin or work not found

Disable Plugin for Work

Disable a plugin for a specific work. The user-level setting is not affected.

Endpoint: POST /api/works/:workId/plugins/:pluginId/disable

Update Work Plugin Settings

Update work-specific settings for a plugin. These settings take highest priority in the settings hierarchy.

Endpoint: PATCH /api/works/:workId/plugins/:pluginId/settings

Body:

{
"settings": {
"defaultModel": "gpt-4o-mini",
"temperature": 0.5
},
"secretSettings": {
"apiKey": "work-specific-key"
}
}

Errors:

StatusDescription
400Plugin not enabled for this work

Set Active Capability

Designate a plugin as the active provider for a specific capability in this work. For example, set OpenAI as the active ai-provider for this work.

Endpoint: POST /api/works/:workId/plugins/:pluginId/capability

Body:

{
"capability": "ai-provider"
}

Only one plugin can be active per capability per work. Setting a new active plugin for a capability automatically deactivates the previous one.

Errors:

StatusDescription
400Plugin does not have the specified capability

Endpoint Summary

MethodEndpointDescription
GET/api/pluginsList all plugins
GET/api/plugins/settings-menuPlugins for settings navigation
GET/api/plugins/:pluginIdPlugin details
GET/api/plugins/:pluginId/modelsAI models for plugin
POST/api/plugins/:pluginId/enableEnable for user
POST/api/plugins/:pluginId/disableDisable for user
PATCH/api/plugins/:pluginId/settingsUpdate user settings
GET/api/works/:workId/pluginsWork plugins
POST/api/works/:workId/plugins/:pluginId/enableEnable for work
POST/api/works/:workId/plugins/:pluginId/disableDisable for work
PATCH/api/works/:workId/plugins/:pluginId/settingsUpdate work settings
POST/api/works/:workId/plugins/:pluginId/capabilitySet active capability