package tech.easyflow.ai.service;

import com.mybatisflex.core.service.IService;
import tech.easyflow.ai.entity.PluginItem;
import tech.easyflow.common.domain.Result;

import java.math.BigInteger;
import java.util.List;

/**
 *  服务层。
 *
 * @author WangGangqiang
 * @since 2025-04-27
 */
public interface PluginItemService extends IService<PluginItem> {

    boolean savePluginTool(PluginItem pluginItem);

    Result searchPlugin(BigInteger aiPluginToolId);

    boolean updatePlugin(PluginItem pluginItem);

    List<PluginItem> searchPluginToolByPluginId(BigInteger pluginId, BigInteger botId);

    List<PluginItem> getPluginToolList(BigInteger botId);

    Result pluginToolTest(String inputData, BigInteger pluginToolId);

    List<PluginItem> getByPluginId(String id);

    /**
     * 获取某个插件的系统维护工具。
     *
     * @param pluginId 插件 ID
     * @return 工具
     */
    PluginItem getSingleByPluginId(BigInteger pluginId);
}
