mirror of
https://github.com/penpot/penpot.git
synced 2026-09-24 12:56:15 +00:00
* ⬆️ Upgrade MCP SDK to v2 and remove HTTP sessions MCP's per-request protocol removes the need to retain HTTP sessions. Use the v2 handler to manage each request's transport and lifecycle, so requests can reach any server instance without session affinity or the workaround that adopts sessions through private SDK fields. Keep legacy SSE support and the shared plugin and Redis bridges. Remove the shared expiry checker, including legacy SSE idle expiry; SSE connections now remain until disconnection or server shutdown. Verify stateless requests, token isolation, and legacy compatibility. Resolves #11827 AI-assisted-by: gpt-6-astra * 🔥 Remove legacy MCP SSE support Use Streamable HTTP as the sole MCP client transport so the server no longer needs a separate SSE connection registry or lifecycle. Remove /sse and /messages, their nginx routes, and the server-legacy dependency. Legacy SSE clients must switch to /mcp; older Streamable HTTP clients remain supported. Document the migration and verify that the removed endpoints return 404. Resolves #11846 AI-assisted-by: gpt-6-astra
65 lines
2.3 KiB
JSON
65 lines
2.3 KiB
JSON
{
|
|
"name": "mcp-server",
|
|
"version": "1.0.0",
|
|
"description": "MCP server for Penpot integration",
|
|
"type": "module",
|
|
"main": "dist/index.js",
|
|
"scripts": {
|
|
"build:server": "esbuild src/index.ts --bundle --platform=node --target=node20 --format=esm --outfile=dist/index.js --external:@modelcontextprotocol/* --external:ws --external:express --external:class-transformer --external:class-validator --external:reflect-metadata --external:pino --external:pino-pretty --external:pino-loki --external:js-yaml --external:sharp --external:nrepl-client --external:ioredis",
|
|
"build": "pnpm run build:server && node scripts/copy-resources.js",
|
|
"build:types": "tsc --emitDeclarationOnly --outDir dist",
|
|
"start": "node dist/index.js",
|
|
"start:multi-user": "node dist/index.js --multi-user",
|
|
"start:dev": "node --import ts-node/register src/index.ts",
|
|
"start:dev:multi-user": "node --loader ts-node/esm src/index.ts --multi-user",
|
|
"test": "tsx --test src/*.test.ts",
|
|
"test:integration:export-sema": "tsx scripts/integration-test-export-image-semaphore.ts",
|
|
"types:check": "tsc --noEmit",
|
|
"clean": "rm -rf dist/"
|
|
},
|
|
"keywords": [
|
|
"mcp",
|
|
"penpot",
|
|
"server"
|
|
],
|
|
"author": "",
|
|
"license": "MIT",
|
|
"engines": {
|
|
"node": ">=20"
|
|
},
|
|
"packageManager": "pnpm@12.5.1+sha512.e3f305bc784a2bc89f5ad3b6138889470fae8d2af5f36b61216ec91c2c3d64089775f9de38aac331044ea40f245cb0d5666392dfdf65824e1907ef6a2c62de5f",
|
|
"dependencies": {
|
|
"@modelcontextprotocol/node": "^2.0.0",
|
|
"@modelcontextprotocol/server": "^2.0.0",
|
|
"class-transformer": "^0.5.1",
|
|
"class-validator": "^0.15.1",
|
|
"express": "^5.2.1",
|
|
"ioredis": "^6.0.0",
|
|
"js-yaml": "^5.2.3",
|
|
"nrepl-client": "^0.3.0",
|
|
"pino": "^10.3.1",
|
|
"pino-loki": "^3.0.0",
|
|
"pino-pretty": "^13.1.3",
|
|
"reflect-metadata": "^0.2.2",
|
|
"sharp": "^0.35.3",
|
|
"ws": "^8.21.1",
|
|
"zod": "^4.4.3"
|
|
},
|
|
"devDependencies": {
|
|
"@modelcontextprotocol/client": "^2.0.0",
|
|
"@penpot/mcp-common": "workspace:../common",
|
|
"@types/express": "^5.0.6",
|
|
"@types/js-yaml": "^4.0.9",
|
|
"@types/node": "^26.1.2",
|
|
"@types/ws": "^8.18.1",
|
|
"cross-env": "^10.1.0",
|
|
"esbuild": "^0.28.1",
|
|
"ts-node": "^10.9.2",
|
|
"tsx": "^4.23.5",
|
|
"typescript": "^6.0.3"
|
|
},
|
|
"ts-node": {
|
|
"esm": true
|
|
}
|
|
}
|