feat(CF-524): Add project_archive MCP method
Implements complete project archival workflow: - Migration 024: Add archival fields to projects table - New project-archive.ts tool coordinating: * Tarball creation via shell * S3 upload with vault credentials * Database metadata tracking * Optional local deletion * Cleanup of temp files - Registered in tool definitions and handlers Replaces manual archival process used for Fireberries/CyprusPulse. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
This commit is contained in:
11
src/index.ts
11
src/index.ts
@@ -83,6 +83,7 @@ import {
|
||||
sessionPatternDetection,
|
||||
} from './tools/session-docs.js';
|
||||
import { archiveAdd, archiveSearch, archiveList, archiveGet } from './tools/archives.js';
|
||||
import { projectArchive } from './tools/project-archive.js';
|
||||
|
||||
// Create MCP server
|
||||
const server = new Server(
|
||||
@@ -667,6 +668,16 @@ server.setRequestHandler(CallToolRequestSchema, async (request) => {
|
||||
});
|
||||
break;
|
||||
|
||||
// Project archival
|
||||
case 'project_archive':
|
||||
result = await projectArchive({
|
||||
project_key: a.project_key,
|
||||
project_path: a.project_path,
|
||||
delete_local: a.delete_local,
|
||||
session_id: a.session_id,
|
||||
});
|
||||
break;
|
||||
|
||||
default:
|
||||
throw new Error(`Unknown tool: ${name}`);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user