feat(cli): add inkreach-teable plugin commands
plugin list: list registered plugins (id/name/status/runtimeType) plugin register: register by URL (--name --url --positions) plugin config list: list base configs (pluginId/tableId/enabled/form/write) plugin config enable/disable: enable/disable per table or base-wide Added 5 client methods: getPlugins, registerPlugin, listPluginConfigs, upsertPluginConfig for CRUD.
This commit is contained in:
Vendored
+13
@@ -207,5 +207,18 @@ class Client {
|
||||
sql(baseId, sql) {
|
||||
return this.call('POST', `/api/base/${baseId}/sql`, { sql });
|
||||
}
|
||||
// ---- plugin ----
|
||||
getPlugins() {
|
||||
return this.call('GET', '/api/plugin');
|
||||
}
|
||||
registerPlugin(body) {
|
||||
return this.call('POST', '/api/plugin', body);
|
||||
}
|
||||
listPluginConfigs(baseId) {
|
||||
return this.call('GET', `/api/base/${baseId}/plugin-config`);
|
||||
}
|
||||
upsertPluginConfig(baseId, pluginId, body) {
|
||||
return this.call('PUT', `/api/base/${baseId}/plugin-config/${pluginId}`, body);
|
||||
}
|
||||
}
|
||||
exports.Client = Client;
|
||||
|
||||
Reference in New Issue
Block a user