Files
clubber/openspec/changes/update-mcp-server-for-organization-members/proposal.md
T

31 lines
1.8 KiB
Markdown
Raw Normal View History

# Proposal: Update MCP Server for Organization Members
## Summary
Update the TypeScript MCP server to support the new organization member functionality that was implemented in the GraphQL backend. The MCP server currently only exposes tools for individual members and needs to be updated to handle both INDIVIDUAL and ORGANIZATION member types.
## Background
The GraphQL API was recently updated to support both individual and organization members through the `support-organization-members` change. This added:
- `memberType` field (enum: INDIVIDUAL, ORGANIZATION)
- `companyName` field for organizations
- Made `firstName` nullable (required for individuals, optional for organizations)
- Conditional validation based on member type
However, the TypeScript MCP server (`src/mcp_server.ts`) still assumes all members are individuals with a required `firstName` field. The MCP tools don't expose the new fields, and the formatting logic doesn't distinguish between member types.
## Goals
- Update MCP tool definitions to include `memberType` and `companyName` fields
- Update tool descriptions to explain conditional requirements (INDIVIDUAL requires firstName, ORGANIZATION requires companyName)
- Update all GraphQL queries/mutations in the MCP server to include new fields
- Update member formatting logic to distinguish between individuals and organizations
- Maintain backward compatibility (memberType defaults to INDIVIDUAL)
## Non-Goals
- Changing the GraphQL schema (already complete)
- Adding new MCP tools (only updating existing tools)
- Modifying validation logic (handled by GraphQL backend)
## Technical Note
- The MCP server is written in TypeScript and uses the Model Context Protocol SDK
- Field names use camelCase in MCP tools (matching GraphQL conventions)
- The GraphQL backend already validates conditional requirements server-side