feat: plugins v1.5
This commit is contained in:
@@ -9,7 +9,7 @@ function createOpenApiDocument(baseUrl: string) {
|
||||
info: {
|
||||
title: 'MetoYou Plugin Support API',
|
||||
version: '1.0.0',
|
||||
description: 'Official HTTP endpoints for plugin metadata, event definitions, and plugin data. '
|
||||
description: 'Official HTTP endpoints for plugin install metadata and event definitions. '
|
||||
+ 'Plugin code is never executed by the signal server.'
|
||||
},
|
||||
servers: [{ url: `${baseUrl}/api` }],
|
||||
@@ -43,18 +43,18 @@ function createOpenApiDocument(baseUrl: string) {
|
||||
},
|
||||
'/servers/{serverId}/plugins/{pluginId}/data': {
|
||||
get: {
|
||||
summary: 'List plugin data records',
|
||||
responses: { '200': { description: 'Plugin data records' }, '403': { description: 'Not a server member' } }
|
||||
summary: 'Plugin data persistence disabled',
|
||||
responses: { '410': { description: 'Plugin data persistence is disabled on the signal server' } }
|
||||
}
|
||||
},
|
||||
'/servers/{serverId}/plugins/{pluginId}/data/{key}': {
|
||||
put: {
|
||||
summary: 'Write plugin data',
|
||||
responses: { '200': { description: 'Plugin data saved' }, '403': { description: 'Not a server member' } }
|
||||
summary: 'Plugin data persistence disabled',
|
||||
responses: { '410': { description: 'Plugin data persistence is disabled on the signal server' } }
|
||||
},
|
||||
delete: {
|
||||
summary: 'Delete plugin data',
|
||||
responses: { '200': { description: 'Plugin data deleted' }, '403': { description: 'Not a server member' } }
|
||||
summary: 'Plugin data persistence disabled',
|
||||
responses: { '410': { description: 'Plugin data persistence is disabled on the signal server' } }
|
||||
}
|
||||
},
|
||||
'/openapi/settings': {
|
||||
@@ -98,7 +98,7 @@ router.get('/docs', (_req, res) => {
|
||||
<body style="font-family:system-ui;margin:2rem;line-height:1.5">
|
||||
<h1>MetoYou Plugin Support API</h1>
|
||||
<p>Plugin support endpoints are available at <a href="/api/openapi.json">/api/openapi.json</a>.</p>
|
||||
<p>The signal server stores metadata, data, and event definitions only. It never executes plugin code.</p>
|
||||
<p>The signal server stores plugin install metadata and event definitions only. It never executes plugin code or stores arbitrary plugin data.</p>
|
||||
</body>
|
||||
</html>`);
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user