MCPcopy Create free account
hub / github.com/astercloud/aster / create

Method create

client-sdks/client-js/src/resources/tool.ts:26–31  ·  view source on GitHub ↗

* 创建自定义工具 * @param tool 工具定义 * @returns 工具信息

(tool: { name: string; type: string; schema: Record<string, any>; description?: string })

Source from the content-addressed store, hash-verified

24 * @returns 工具信息
25 */
26 async create(tool: { name: string; type: string; schema: Record<string, any>; description?: string }): Promise<ToolInfo> {
27 return this.request<ToolInfo>("/v1/tools", {
28 method: "POST",
29 body: tool,
30 });
31 }
32
33 /**
34 * 列出所有工具

Callers 4

client.test.tsFile · 0.45
mainFunction · 0.45
mainFunction · 0.45

Calls 1

requestMethod · 0.80

Tested by

no test coverage detected