Add plugin methods to plugin API (#9744)

Этот коммит содержится в:
Hanzei
2018-11-08 19:17:07 +01:00
коммит произвёл Christopher Speller
родитель 93e581d642
Коммит e67d89b9a8
7 изменённых файлов: 390 добавлений и 4 удалений

Просмотреть файл

@@ -314,6 +314,35 @@ type API interface {
// Minimum server version: 5.6
UploadFile(data []byte, channelId string, filename string) (*model.FileInfo, *model.AppError)
// Plugin Section
// GetPlugins will return a list of plugin manifests for currently active plugins.
//
// Minimum server version: 5.6
GetPlugins() ([]*model.Manifest, *model.AppError)
// EnablePlugin will enable an plugin installed.
//
// Minimum server version: 5.6
EnablePlugin(id string) *model.AppError
// DisablePlugin will disable an enabled plugin.
//
// Minimum server version: 5.6
DisablePlugin(id string) *model.AppError
// RemovePlugin will disable and delete a plugin.
//
// Minimum server version: 5.6
RemovePlugin(id string) *model.AppError
// GetPluginStatus will return the status of a plugin.
//
// Minimum server version: 5.6
GetPluginStatus(id string) (*model.PluginStatus, *model.AppError)
// KV Store Section
// KVSet will store a key-value pair, unique per plugin.
KVSet(key string, value []byte) *model.AppError