@tupaas/mcp 1.1.0 → 1.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/index.js +22 -3
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -6,9 +6,10 @@ import fs from "fs";
6
6
  import path from "path";
7
7
  import os from "os";
8
8
  import { execSync } from "child_process";
9
+ const VERSION = "1.2.0";
9
10
  const API_URL = process.env.TUPAAS_API_URL ?? "https://tupaas.dev/api";
10
11
  const API_KEY = process.env.TUPAAS_API_KEY ?? "";
11
- const server = new Server({ name: "tupaas-mcp", version: "1.1.0" }, { capabilities: { tools: {} } });
12
+ const server = new Server({ name: "tupaas-mcp", version: VERSION }, { capabilities: { tools: {} } });
12
13
  function authHeaders() {
13
14
  return { "x-api-key": API_KEY };
14
15
  }
@@ -16,7 +17,7 @@ server.setRequestHandler(ListToolsRequestSchema, async () => ({
16
17
  tools: [
17
18
  {
18
19
  name: "deploy",
19
- description: "Deploy a project folder to TuPaaS. Compresses the folder, uploads it, and returns the live URL. Supports redeploy (same name = update existing project).",
20
+ description: "Deploy a project folder to TuPaaS. Compresses the folder, uploads it, and returns the live URL. Supports redeploy (same name = update existing project). IMPORTANT: If the project requires a database (e.g. has prisma, pg, DATABASE_URL in .env), call list_databases first and ask the user which database to use or whether to create a new one. Do not decide on your own.",
20
21
  inputSchema: {
21
22
  type: "object",
22
23
  properties: {
@@ -53,7 +54,7 @@ server.setRequestHandler(ListToolsRequestSchema, async () => ({
53
54
  },
54
55
  {
55
56
  name: "list_databases",
56
- description: "List all databases owned by the authenticated user. Returns id, name, type, status, and connection URL for each database.",
57
+ description: "List all databases owned by the authenticated user. Returns id, name, type, status, and connection URL for each database. IMPORTANT: If this is called as part of a deploy process and the project needs a database, you MUST present the list to the user and ask whether they want to use one of these existing databases or create a new one. Never choose automatically.",
57
58
  inputSchema: {
58
59
  type: "object",
59
60
  properties: {},
@@ -87,6 +88,14 @@ server.setRequestHandler(ListToolsRequestSchema, async () => ({
87
88
  required: ["database_id"],
88
89
  },
89
90
  },
91
+ {
92
+ name: "version",
93
+ description: "Returns the current version of the TuPaaS MCP server and the API URL it is configured to use.",
94
+ inputSchema: {
95
+ type: "object",
96
+ properties: {},
97
+ },
98
+ },
90
99
  ],
91
100
  }));
92
101
  server.setRequestHandler(CallToolRequestSchema, async (request) => {
@@ -325,6 +334,16 @@ server.setRequestHandler(CallToolRequestSchema, async (request) => {
325
334
  ],
326
335
  };
327
336
  }
337
+ case "version": {
338
+ return {
339
+ content: [
340
+ {
341
+ type: "text",
342
+ text: `TuPaaS MCP v${VERSION}\nAPI URL: ${API_URL}\nAPI Key: ${API_KEY ? `${API_KEY.slice(0, 12)}...` : "NOT SET"}`,
343
+ },
344
+ ],
345
+ };
346
+ }
328
347
  default:
329
348
  return {
330
349
  content: [
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tupaas/mcp",
3
- "version": "1.1.0",
3
+ "version": "1.2.0",
4
4
  "description": "MCP server for deploying to TuPaaS from Claude Code",
5
5
  "type": "module",
6
6
  "bin": {