get_categories
Retrieve all categories from a Revit model to streamline data organization and enhance model analysis within the Revit MCP Server environment.
Instructions
获取 Revit 模型中的所有类别
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/index.ts:116-123 (registration)Registration of the 'get_categories' tool in the MCP server's ListToolsRequestSchema handler, including name, description, and empty input schema.tools: [{ name: "get_categories", description: "获取 Revit 模型中的所有类别", inputSchema: { type: "object", properties: {} } }, {
- src/index.ts:119-122 (schema)Input schema for the 'get_categories' tool: an empty object.inputSchema: { type: "object", properties: {} }
- src/revitService.ts:112-119 (handler)RevitService.getCategories(): the direct handler called by MCP tool dispatcher for 'get_categories', delegates to socket client.async getCategories(): Promise<any[]> { try { return await this.client.getCategories(); } catch (error) { console.error('[RevitService] 获取类别失败:', error); throw error; } }
- src/revitSocketClient.ts:195-198 (handler)Core handler implementation in RevitSocketClient.getCategories(): sends 'get_categories' command over socket and returns response.public async getCategories(): Promise<any[]> { const response = await this.sendRequest<any[]>('get_categories', {}); return response; }