func (c *Sys) ListPlugins(i *ListPluginsInput) (*ListPluginsResponse, error) {
	path := "/v1/sys/plugins/catalog"
	req := c.c.NewRequest("LIST", path)
	ctx, cancelFunc := context.WithCancel(context.Background())
	defer cancelFunc()
	resp, err := c.c.RawRequestWithContext(ctx, req)
	if err != nil {
		return nil, err
	}
	defer resp.Body.Close()
	var result struct {
		Data struct {
			Keys []string `json:"keys"`
		} `json:"data"`
	}
	if err := resp.DecodeJSON(&result); err != nil {
		return nil, err
	}
	return &ListPluginsResponse{Names: result.Data.Keys}, nil
}
ListPlugins lists all plugins in the catalog and returns their names as a
list of strings.
package api
import (
	"context"
	"fmt"
	"net/http"
)
type ListPluginsInput struct{}
type ListPluginsResponse struct {
	Names []string
}