You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
.describe("Name of the API-based tool to load, for example get_resource."),
});
exportasyncfunctioncreateFetchToolSchemaTool(
apiBasedTools: Record<string,ApiBasedTool>,
){
returntool(
async({ toolName })=>{
consttoolDefinition=apiBasedTools[toolName];
if(!toolDefinition){
returnJSON.stringify(
{
status: 404,
error: "TOOL_NOT_FOUND",
message: `Tool "${toolName}" not found.`,
},
null,
2,
);
}
returnJSON.stringify(
{
status: 200,
name: toolName,
loaded: true,
},
null,
2,
);
},
{
name: "fetch_tool_schema",
description:
"Fetch the schema for an API-based AdminForth tool by name and load it for later use. Use this right after fetch_skill when the skill mentions non-base tools.",