Complete API reference for the Kubiya Tools service methods and exceptions
list(source_uuid: Optional[str] = None) -> List[Dict[str, Any]]
source_uuid
(Optional[str]
): Optional source UUID to list tools from specific source. If not provided, lists tools from all sourcesList[Dict[str, Any]]
: List of tool dictionariesToolExecutionError
: For general tool operation failuressearch(query: str) -> List[Dict[str, Any]]
query
(str
): Search query string to match against tool names and descriptionsList[Dict[str, Any]]
: List of search result dictionariesToolExecutionError
: For search operation failuresdescribe(tool_name: str, source_uuid: Optional[str] = None) -> Dict[str, Any]
tool_name
(str
): Name of the tool to describesource_uuid
(Optional[str]
): Optional source UUID to search in specific source. If not provided, searches all sourcesDict[str, Any]
: Tool details dictionaryToolNotFoundError
: When the specified tool cannot be foundToolExecutionError
: For general operation failuresgenerate_tool(description: str, session_id: Optional[str] = None, target_dir: Optional[str] = None) -> Dict[str, Any]
description
(str
): Tool description (required) - detailed description of what the tool should dosession_id
(Optional[str]
): Session ID for continuing previous generation. Auto-generated if not providedtarget_dir
(Optional[str]
): Target directory for generated files. Defaults to current working directoryDict[str, Any]
: Generation result with session information and created filesToolGenerationError
: When tool generation fails (empty description, directory issues, AI errors, etc.)_list_sources() -> List[Dict[str, Any]]
_get_source_metadata(source_uuid: str) -> Dict[str, Any]
_levenshtein_distance(s1: str, s2: str) -> int
_process_generation_events(events: List[Dict[str, Any]], session_dir: str) -> List[str]
_process_file_content(generated_content: List[Dict[str, Any]], file_buffers: Dict[str, Dict[str, Any]], session_dir: str) -> List[str]