get_workspace_context
Retrieve the complete workspace hierarchy and insights to understand project structure, task relationships, and overall team context.
Instructions
Get complete workspace hierarchy and insights
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/tools/initiatives.ts:517-523 (handler)The handler function for the get_workspace_context tool. It requires authentication, calls supabaseService.getWorkspaceContext(), and returns the context.
export const getWorkspaceContext = requireAuth(async (args: any) => { logger.info('Getting workspace context') const context = await supabaseService.getWorkspaceContext() return { context } }) - src/tools/initiatives.ts:508-515 (schema)The tool definition/schema for get_workspace_context. No input parameters required. Description: 'Get complete workspace hierarchy and insights'.
export const getWorkspaceContextTool: MCPTool = { name: 'get_workspace_context', description: 'Get complete workspace hierarchy and insights', inputSchema: { type: 'object', properties: {} } } - src/tools/initiatives.ts:616-628 (registration)Registration of getWorkspaceContextTool in the initiativeTools export object.
export const initiativeTools = { listInitiativesTool, getInitiativeTool, createInitiativeTool, updateInitiativeTool, getInitiativeContextTool, getInitiativeInsightsTool, searchWorkspaceTool, getEnhancedProjectContextTool, getWorkspaceContextTool, associateDocumentWithInitiativeTool, disassociateDocumentFromInitiativeTool } - src/tools/initiatives.ts:630-642 (registration)Registration of getWorkspaceContext handler in the initiativeHandlers map, mapping the tool name 'get_workspace_context' to the handler function.
export const initiativeHandlers = { list_initiatives: listInitiatives, get_initiative: getInitiative, create_initiative: createInitiative, update_initiative: updateInitiative, get_initiative_context: getInitiativeContext, get_initiative_insights: getInitiativeInsights, search_workspace: searchWorkspace, get_enhanced_project_context: getEnhancedProjectContext, get_workspace_context: getWorkspaceContext, associate_document_with_initiative: associateDocumentWithInitiative, disassociate_document_from_initiative: disassociateDocumentFromInitiative } - src/lib/api-client.ts:598-601 (helper)The API client method that makes the actual HTTP request to '/api/mcp/workspace/context' to fetch workspace context data from the backend.
async getWorkspaceContext(): Promise<any> { const response = await this.request<{ context: any }>('/api/mcp/workspace/context') return response.context }