We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/kunwarVivek/mcp-github-project-manager'
If you have feedback or need assistance with the MCP directory API, please join our Discord server
---
phase: 08-project-lifecycle-advanced
plan: 01
type: execute
wave: 1
depends_on: []
files_modified:
- src/infrastructure/tools/schemas/project-lifecycle-schemas.ts
- src/infrastructure/github/repositories/types.ts
autonomous: true
must_haves:
truths:
- "All 6 Phase 8 tool schemas are defined and exported"
- "Input schemas validate required parameters per RESEARCH.md"
- "Output schemas match GraphQL response structures"
artifacts:
- path: "src/infrastructure/tools/schemas/project-lifecycle-schemas.ts"
provides: "Zod schemas for all 6 lifecycle/advanced tools"
exports: ["CloseProjectInputSchema", "ReopenProjectInputSchema", "ConvertDraftIssueInputSchema", "UpdateItemPositionInputSchema", "SearchIssuesAdvancedInputSchema", "FilterProjectItemsInputSchema"]
- path: "src/infrastructure/github/repositories/types.ts"
provides: "TypeScript interfaces for repository layer"
contains: "ProjectLifecycleOutput"
key_links:
- from: "project-lifecycle-schemas.ts"
to: "Zod validation"
via: "z.object() definitions"
pattern: "z\\.object\\("
---
<objective>
Create Zod schemas for all 6 Phase 8 MCP tools covering project lifecycle management and advanced operations.
Purpose: Define strongly-typed input/output schemas that enable type-safe tool execution and MCP protocol compliance.
Output: One schema file with 12 Zod schemas (6 input + 6 output) and updated repository types.
</objective>
<execution_context>
@/Users/vivek/.claude/get-shit-done/workflows/execute-plan.md
@/Users/vivek/.claude/get-shit-done/templates/summary.md
</execution_context>
<context>
@.planning/PROJECT.md
@.planning/ROADMAP.md
@.planning/STATE.md
@.planning/phases/08-project-lifecycle-advanced/08-RESEARCH.md
Reference existing schema patterns:
@src/infrastructure/tools/schemas/project-template-linking-schemas.ts
</context>
<tasks>
<task type="auto">
<name>Task 1: Create project lifecycle schemas file</name>
<files>src/infrastructure/tools/schemas/project-lifecycle-schemas.ts</files>
<action>
Create `src/infrastructure/tools/schemas/project-lifecycle-schemas.ts` with Zod schemas for all 6 Phase 8 tools.
**Input Schemas (6):**
1. `CloseProjectInputSchema` - GHAPI-19
- projectId: z.string() - Required, ProjectV2 node ID
2. `ReopenProjectInputSchema` - GHAPI-20
- projectId: z.string() - Required, ProjectV2 node ID
3. `ConvertDraftIssueInputSchema` - GHAPI-21
- itemId: z.string() - Required, ProjectV2Item ID (PVTI_...)
- owner: z.string() - Required, target repository owner
- repo: z.string() - Required, target repository name
4. `UpdateItemPositionInputSchema` - GHAPI-22
- projectId: z.string() - Required, ProjectV2 node ID
- itemId: z.string() - Required, ProjectV2Item ID to move
- afterId: z.string().optional() - Item to place after (omit for first position)
5. `SearchIssuesAdvancedInputSchema` - GHAPI-23
- query: z.string() - Required, GitHub search query with AND/OR support
- first: z.number().min(1).max(100).optional().default(20)
- after: z.string().optional() - Pagination cursor
6. `FilterProjectItemsInputSchema` - GHAPI-24
- projectId: z.string() - Required, ProjectV2 node ID
- filter: z.object() with optional fields:
- status: z.string().optional() - Single select field value
- labels: z.array(z.string()).optional() - Label names to match
- assignee: z.string().optional() - Assignee login
- type: z.enum(['Issue', 'PullRequest', 'DraftIssue']).optional()
- first: z.number().min(1).max(100).optional().default(50)
- after: z.string().optional()
**Output Schemas (6):**
1. `ProjectLifecycleOutputSchema` - For close/reopen (shared)
- id: z.string()
- title: z.string()
- closed: z.boolean()
- url: z.string()
2. `ConvertedIssueOutputSchema`
- itemId: z.string() - Updated ProjectV2Item ID
- issueId: z.string() - Created issue node ID
- issueNumber: z.number()
- title: z.string()
- url: z.string()
- repository: z.string() - owner/repo format
3. `ItemPositionOutputSchema`
- success: z.boolean()
- itemId: z.string()
- position: z.string() - 'first' or 'after {id}'
4. `SearchIssuesOutputSchema`
- totalCount: z.number()
- issues: z.array(SearchIssueItemSchema)
- pageInfo: PageInfoSchema
5. `SearchIssueItemSchema` (helper)
- id: z.string()
- number: z.number()
- title: z.string()
- state: z.enum(['OPEN', 'CLOSED'])
- url: z.string()
- labels: z.array(z.string())
- assignees: z.array(z.string())
- repository: z.string()
6. `FilterProjectItemsOutputSchema`
- totalCount: z.number()
- filteredCount: z.number()
- items: z.array(ProjectItemSchema)
- pageInfo: PageInfoSchema
7. `ProjectItemSchema` (helper)
- id: z.string()
- type: z.enum(['Issue', 'PullRequest', 'DraftIssue'])
- contentId: z.string().nullable()
- title: z.string()
- state: z.string().nullable()
- labels: z.array(z.string())
- fieldValues: z.record(z.string(), z.string().nullable())
8. `PageInfoSchema` (reuse pattern from project-template-linking-schemas)
- hasNextPage: z.boolean()
- endCursor: z.string().nullable()
Export all schemas and inferred TypeScript types using `z.infer<typeof Schema>`.
Follow the pattern from project-template-linking-schemas.ts exactly.
</action>
<verify>
```bash
npx tsc --noEmit src/infrastructure/tools/schemas/project-lifecycle-schemas.ts
```
TypeScript compilation succeeds with no errors.
</verify>
<done>
All 6 input schemas and 6+ output schemas are defined, properly typed, and exported.
</done>
</task>
<task type="auto">
<name>Task 2: Add TypeScript interfaces to repository types</name>
<files>src/infrastructure/github/repositories/types.ts</files>
<action>
Add TypeScript interfaces to `src/infrastructure/github/repositories/types.ts` for the repository layer.
**Add these interfaces:**
```typescript
// Project Lifecycle Operations (Phase 8)
export interface ProjectLifecycleResult {
id: string;
title: string;
closed: boolean;
url: string;
}
export interface ConvertedDraftIssueResult {
itemId: string;
issueId: string;
issueNumber: number;
title: string;
url: string;
repository: string;
}
export interface ItemPositionResult {
success: boolean;
itemId: string;
position: string;
}
export interface SearchIssueResult {
id: string;
number: number;
title: string;
state: 'OPEN' | 'CLOSED';
url: string;
labels: string[];
assignees: string[];
repository: string;
}
export interface FilteredProjectItem {
id: string;
type: 'Issue' | 'PullRequest' | 'DraftIssue';
contentId: string | null;
title: string;
state: string | null;
labels: string[];
fieldValues: Record<string, string | null>;
}
```
Place after the existing Phase 7 interfaces (Template/Linking section).
</action>
<verify>
```bash
npx tsc --noEmit src/infrastructure/github/repositories/types.ts
```
TypeScript compilation succeeds.
</verify>
<done>
5 new TypeScript interfaces are added and exported from types.ts.
</done>
</task>
<task type="auto">
<name>Task 3: Verify schemas are importable</name>
<files>src/infrastructure/tools/schemas/project-lifecycle-schemas.ts</files>
<action>
Verify that the schemas can be imported from the new file.
Note: ToolSchemas.ts re-exports tools (not raw schemas) from tool files. The schema file is imported directly by the tool files (project-lifecycle-tools.ts and project-advanced-tools.ts in subsequent plans).
The pattern is:
- schemas/project-lifecycle-schemas.ts exports raw Zod schemas
- project-lifecycle-tools.ts imports schemas and creates tool definitions
- ToolSchemas.ts re-exports tools from project-lifecycle-tools.ts
Verify the file compiles and exports are accessible:
```bash
npx tsc --noEmit src/infrastructure/tools/schemas/project-lifecycle-schemas.ts
```
</action>
<verify>
```bash
npx tsc --noEmit src/infrastructure/tools/schemas/project-lifecycle-schemas.ts
```
TypeScript compilation succeeds.
</verify>
<done>
All Phase 8 schemas are defined in the schema file and ready for import by tool files.
</done>
</task>
</tasks>
<verification>
After completing all tasks:
1. TypeScript compilation:
```bash
npx tsc --noEmit
```
No errors in the full build.
2. Schema exports:
```bash
grep -c "export.*Schema" src/infrastructure/tools/schemas/project-lifecycle-schemas.ts
```
Should return 12+ (6 input + 6 output schemas).
3. Types exported:
```bash
grep -c "export type" src/infrastructure/tools/schemas/project-lifecycle-schemas.ts
```
Should return 12+ inferred types.
</verification>
<success_criteria>
- All 6 input schemas validate correct parameters per RESEARCH.md
- All output schemas match expected GraphQL response structures
- TypeScript compiles with no errors
- Schemas are exported through ToolSchemas.ts
- Repository types are added for use in tool executors
</success_criteria>
<output>
After completion, create `.planning/phases/08-project-lifecycle-advanced/08-01-SUMMARY.md`
</output>