158 lines
5.1 KiB
YAML
158 lines
5.1 KiB
YAML
plugins:
|
|
get:
|
|
operationId: listPlugins
|
|
summary: List all plugins
|
|
description: |
|
|
Returns a list of all plugins with their configurations and status.
|
|
The `actualName` field contains the plugin name from `GetName()` (used as the map key),
|
|
while `name` contains the display name from the configuration.
|
|
The `types` array in the status shows which interfaces the plugin implements (llm, mcp, http).
|
|
tags:
|
|
- Plugins
|
|
responses:
|
|
'200':
|
|
description: Successful response
|
|
content:
|
|
application/json:
|
|
schema:
|
|
$ref: '../../schemas/management/plugins.yaml#/ListPluginsResponse'
|
|
'500':
|
|
$ref: '../../openapi.yaml#/components/responses/InternalError'
|
|
|
|
post:
|
|
operationId: createPlugin
|
|
summary: Create a new plugin
|
|
description: Creates a new plugin with the specified configuration.
|
|
tags:
|
|
- Plugins
|
|
requestBody:
|
|
required: true
|
|
content:
|
|
application/json:
|
|
schema:
|
|
$ref: '../../schemas/management/plugins.yaml#/CreatePluginRequest'
|
|
responses:
|
|
'201':
|
|
description: Plugin created successfully
|
|
content:
|
|
application/json:
|
|
schema:
|
|
$ref: '../../schemas/management/plugins.yaml#/PluginResponse'
|
|
'400':
|
|
$ref: '../../openapi.yaml#/components/responses/BadRequest'
|
|
'409':
|
|
description: Plugin already exists
|
|
content:
|
|
application/json:
|
|
schema:
|
|
$ref: '../../schemas/inference/common.yaml#/BifrostError'
|
|
'500':
|
|
$ref: '../../openapi.yaml#/components/responses/InternalError'
|
|
|
|
/plugins/{name}:
|
|
get:
|
|
operationId: getPlugin
|
|
summary: Get a specific plugin
|
|
description: |
|
|
Returns the configuration for a specific plugin.
|
|
The response includes the plugin status with types array showing which interfaces
|
|
the plugin implements (llm, mcp, http). The `actualName` field shows the plugin name
|
|
from GetName() (used as the map key), which may differ from the display name (`name`).
|
|
tags:
|
|
- Plugins
|
|
parameters:
|
|
- name: name
|
|
in: path
|
|
required: true
|
|
description: Plugin display name (the config field `name`, not the internal `actualName` from GetName())
|
|
schema:
|
|
type: string
|
|
responses:
|
|
'200':
|
|
description: Successful response
|
|
content:
|
|
application/json:
|
|
schema:
|
|
$ref: '../../schemas/management/plugins.yaml#/Plugin'
|
|
'400':
|
|
$ref: '../../openapi.yaml#/components/responses/BadRequest'
|
|
'404':
|
|
description: Plugin not found
|
|
content:
|
|
application/json:
|
|
schema:
|
|
$ref: '../../schemas/inference/common.yaml#/BifrostError'
|
|
'500':
|
|
$ref: '../../openapi.yaml#/components/responses/InternalError'
|
|
|
|
put:
|
|
operationId: updatePlugin
|
|
summary: Update a plugin
|
|
description: |
|
|
Updates a plugin's configuration. Will reload or stop the plugin based on enabled status.
|
|
The response `actualName` field shows the plugin name from GetName() (used as the map key),
|
|
which may differ from the display name (`name`).
|
|
tags:
|
|
- Plugins
|
|
parameters:
|
|
- name: name
|
|
in: path
|
|
required: true
|
|
description: Plugin display name (the config field `name`, not the internal `actualName` from GetName())
|
|
schema:
|
|
type: string
|
|
requestBody:
|
|
required: true
|
|
content:
|
|
application/json:
|
|
schema:
|
|
$ref: '../../schemas/management/plugins.yaml#/UpdatePluginRequest'
|
|
responses:
|
|
'200':
|
|
description: Plugin updated successfully
|
|
content:
|
|
application/json:
|
|
schema:
|
|
$ref: '../../schemas/management/plugins.yaml#/PluginResponse'
|
|
'400':
|
|
$ref: '../../openapi.yaml#/components/responses/BadRequest'
|
|
'404':
|
|
description: Plugin not found
|
|
content:
|
|
application/json:
|
|
schema:
|
|
$ref: '../../schemas/inference/common.yaml#/BifrostError'
|
|
'500':
|
|
$ref: '../../openapi.yaml#/components/responses/InternalError'
|
|
|
|
delete:
|
|
operationId: deletePlugin
|
|
summary: Delete a plugin
|
|
description: Removes a plugin from the configuration and stops it if running.
|
|
tags:
|
|
- Plugins
|
|
parameters:
|
|
- name: name
|
|
in: path
|
|
required: true
|
|
description: Plugin display name (the config field `name`, not the internal `actualName` from GetName())
|
|
schema:
|
|
type: string
|
|
responses:
|
|
'200':
|
|
description: Plugin deleted successfully
|
|
content:
|
|
application/json:
|
|
schema:
|
|
$ref: '../../schemas/management/common.yaml#/MessageResponse'
|
|
'400':
|
|
$ref: '../../openapi.yaml#/components/responses/BadRequest'
|
|
'404':
|
|
description: Plugin not found
|
|
content:
|
|
application/json:
|
|
schema:
|
|
$ref: '../../schemas/inference/common.yaml#/BifrostError'
|
|
'500':
|
|
$ref: '../../openapi.yaml#/components/responses/InternalError'
|