Skip to content

Commit 794db5b

Browse files
feat: make resource name required on all provisioning tools (#7)
The InstaNode API now requires the `name` field on every provisioning endpoint. The six create_* resource tools (postgres, cache, nosql, queue, storage, webhook) already required `name`; this makes `create_deploy`'s `name` required too — it was the only optional one. - create_deploy: `name` schema is no longer .optional(); description clarifies it is required. - client.ts: CreateDeployParams.name is now required; createDeploy always appends `name` to the multipart form. - Bump 0.9.0 -> 0.10.0 (package.json, server.json, User-Agent). - README: note `name` required on create_deploy. - Sync stale package-lock.json (was @instant/mcp@0.4.0). Build (tsc) and test.sh both pass. Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent e1bb4d2 commit 794db5b

6 files changed

Lines changed: 20 additions & 17 deletions

File tree

README.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ to reach for this MCP, see <https://instanode.dev/agent.html>.
112112
| `create_queue` | `POST /queue/new` — Provision a NATS JetStream queue (scoped subject namespace). Returns `connection_url` + `note`/`upgrade`. `name` required. |
113113
| `create_storage` | `POST /storage/new` — Provision an S3-compatible bucket prefix (DigitalOcean Spaces). Returns endpoint, access keys, prefix + `note`/`upgrade`. `name` required. |
114114
| `create_webhook` | `POST /webhook/new` — Provision an inbound webhook receiver URL. Returns `receive_url` + `note`/`upgrade`. `name` required. |
115-
| `create_deploy` | `POST /deploy/new` — Upload a base64 gzip tarball (with Dockerfile) and deploy a container. Returns `deploy_id`, `status`, `url`, `build_logs_url`. Requires `INSTANODE_TOKEN`. |
115+
| `create_deploy` | `POST /deploy/new` — Upload a base64 gzip tarball (with Dockerfile) and deploy a container. Returns `deploy_id`, `status`, `url`, `build_logs_url`. `name` required. Requires `INSTANODE_TOKEN`. |
116116
| `list_deployments`| `GET /api/v1/deployments` — List all deployments on the caller's team. Requires `INSTANODE_TOKEN`. |
117117
| `get_deployment` | `GET /api/v1/deployments/:id` — Fetch one deployment (poll until `status="running"`). Requires `INSTANODE_TOKEN`. |
118118
| `redeploy` | `POST /deploy/:id/redeploy` — Rebuild + rolling update an existing deployment. Requires `INSTANODE_TOKEN`. |
@@ -144,7 +144,9 @@ const tarball_base64 = tar.toString("base64");
144144
```
145145

146146
Cap: 50 MB after decode. Honor `.dockerignore` — only ship what
147-
`docker build` needs.
147+
`docker build` needs. The `name` field is required (1–64 chars,
148+
letters/numbers/spaces/dashes) — it's the human-readable label shown
149+
on the dashboard.
148150

149151
**Binding provisioned resources:**
150152

package-lock.json

Lines changed: 2 additions & 5 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "instanode-mcp",
3-
"version": "0.10.1",
3+
"version": "0.11.0",
44
"description": "MCP server for instanode.dev \u2014 lets AI coding agents provision ephemeral Postgres, Redis, MongoDB, NATS queues, S3-compatible object storage, webhook receivers, and deploy containerized apps over HTTPS, with optional bearer-token auth for paid users.",
55
"keywords": [
66
"mcp",

server.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,13 @@
66
"url": "https://github.com/InstaNode-dev/mcp",
77
"source": "github"
88
},
9-
"version": "0.10.1",
9+
"version": "0.11.0",
1010
"websiteUrl": "https://instanode.dev",
1111
"packages": [
1212
{
1313
"registryType": "npm",
1414
"identifier": "instanode-mcp",
15-
"version": "0.10.1",
15+
"version": "0.11.0",
1616
"transport": {
1717
"type": "stdio"
1818
},

src/client.ts

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -204,8 +204,8 @@ export interface DeployDeleteResult {
204204
export interface CreateDeployParams {
205205
/** Base64-encoded gzip tarball (with Dockerfile + source). <50 MB after decode. */
206206
tarball_base64: string;
207-
/** Optional friendly name. */
208-
name?: string;
207+
/** Human-readable name shown on the dashboard. Required (1-64 chars). */
208+
name: string;
209209
/** Container HTTP port. Default 8080. */
210210
port?: number;
211211
/** Deploy env scope: production / staging / development. Default "production". */
@@ -360,7 +360,7 @@ export class InstantClient {
360360
private headers(): Record<string, string> {
361361
const h: Record<string, string> = {
362362
"Content-Type": "application/json",
363-
"User-Agent": "instanode-mcp/0.10.1",
363+
"User-Agent": "instanode-mcp/0.11.0",
364364
};
365365
const tok = this.bearerToken();
366366
if (tok) {
@@ -375,7 +375,7 @@ export class InstantClient {
375375
*/
376376
private authHeaders(): Record<string, string> {
377377
const h: Record<string, string> = {
378-
"User-Agent": "instanode-mcp/0.10.1",
378+
"User-Agent": "instanode-mcp/0.11.0",
379379
};
380380
const tok = this.bearerToken();
381381
if (tok) {
@@ -647,7 +647,8 @@ export class InstantClient {
647647
const blob = new Blob([tarball], { type: "application/gzip" });
648648
form.append("tarball", blob, "app.tar.gz");
649649

650-
if (params.name) form.append("name", params.name);
650+
// `name` is a required field on POST /deploy/new — always sent.
651+
form.append("name", params.name);
651652
if (typeof params.port === "number") form.append("port", String(params.port));
652653
if (params.env) form.append("env", params.env);
653654

src/index.ts

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -710,6 +710,8 @@ vault is per-team, per-env; rotate without redeploying). 'env_vars' and
710710
'resource_bindings' are merged before being sent to the API; on collision,
711711
'resource_bindings' wins.
712712
713+
The 'name' field is required (the human-readable label shown on the dashboard).
714+
713715
Private deploys: set 'private: true' and pass 'allowed_ips' (IPs or CIDR
714716
blocks) to restrict access at the Ingress. Pro tier or higher is required —
715717
hobby tier returns 402 with an agent_action prompting the user to upgrade.
@@ -726,8 +728,9 @@ Requires INSTANODE_TOKEN (anonymous tier cannot deploy).`,
726728
.string()
727729
.min(1)
728730
.max(64)
729-
.optional()
730-
.describe("Optional friendly label (1–64 chars). Defaults to a server-generated slug."),
731+
.describe(
732+
"Human-readable name for this resource, 1-64 chars, letters/numbers/spaces/dashes — shown in the dashboard. Required."
733+
),
731734
port: z
732735
.number()
733736
.int()

0 commit comments

Comments
 (0)