From b77b399902f37309a23eb6a7321bf2d6a32336db Mon Sep 17 00:00:00 2001 From: Cursor Agent Date: Thu, 9 Jul 2026 02:48:05 +0000 Subject: [PATCH 1/3] chore(deps): bump @photon-ai/dashboard-api to 1.6.1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sync CLI with dashboard@v1.6.2 (8ba0b69). The v1.6.2 dashboard tag is a security-only release (unauthenticated phone OTP rate-limiting) with no API surface changes, so the api-public package stayed at 1.6.1 on npm — that's the version we consume. Co-authored-by: citron --- bun.lock | 5 +++-- package.json | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/bun.lock b/bun.lock index 748dba3..fdc61ff 100644 --- a/bun.lock +++ b/bun.lock @@ -1,5 +1,6 @@ { "lockfileVersion": 1, + "configVersion": 0, "workspaces": { "": { "name": "dashboard-cli", @@ -15,7 +16,7 @@ "update-notifier": "^7.3.1", }, "devDependencies": { - "@photon-ai/dashboard-api": "1.2.0", + "@photon-ai/dashboard-api": "1.6.1", "@types/bun": "latest", "@types/node": "^25.6.2", "@types/update-notifier": "^6.0.8", @@ -49,7 +50,7 @@ "@noble/hashes": ["@noble/hashes@2.2.0", "", {}, "sha512-IYqDGiTXab6FniAgnSdZwgWbomxpy9FtYvLKs7wCUs2a8RkITG+DFGO1DM9cr+E3/RgADRpFjrKVaJ1z6sjtEg=="], - "@photon-ai/dashboard-api": ["@photon-ai/dashboard-api@1.2.0", "", { "peerDependencies": { "@elysiajs/eden": "^1.4.9", "elysia": "^1.4.28" } }, "sha512-ZQ4OVaGQMFVMa2/bL2OfRxMaQDABwi+tHUFQHmQOH39N7pCXC6vQ8m32+Its2FxQ5VwU+dyvqmyv0ccxCmK8hw=="], + "@photon-ai/dashboard-api": ["@photon-ai/dashboard-api@1.6.1", "", { "peerDependencies": { "@elysiajs/eden": "^1.4.9", "elysia": "^1.4.28" } }, "sha512-6wgtxR3/6PXxckhkkCWKSGaRBZviaxLrhtCid5WlD3NimPj4V8S0ODvgeF4kH5vDgmOvvr6QIDLY/dGZKl2fQg=="], "@pnpm/config.env-replace": ["@pnpm/config.env-replace@1.1.0", "", {}, "sha512-htyl8TWnKL7K/ESFa1oW2UB5lVDxuF5DpM7tBi6Hu2LNL3mWkIzNLG6N4zoCUP1lCKNxWy/3iu8mS8MvToGd6w=="], diff --git a/package.json b/package.json index afb9a76..8ffd9db 100644 --- a/package.json +++ b/package.json @@ -49,7 +49,7 @@ "prepublishOnly": "bun run typecheck && bun run build" }, "devDependencies": { - "@photon-ai/dashboard-api": "1.2.0", + "@photon-ai/dashboard-api": "1.6.1", "@types/bun": "latest", "@types/node": "^25.6.2", "@types/update-notifier": "^6.0.8", From 0e004c2b6661a24e7e5b5a0e0449315797a7f73a Mon Sep 17 00:00:00 2001 From: Cursor Agent Date: Thu, 9 Jul 2026 02:48:10 +0000 Subject: [PATCH 2/3] refactor(projects,spectrum-users): cast list responses at the API boundary MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit @photon-ai/dashboard-api 1.6.1 continues to emit list response payloads as { [x: string]: any } rather than typed arrays, so calling .map on the raw Eden `data` picks up an implicit `any` parameter under strict TS. Recover the field-level shape with a boundary cast — same pattern spectrum/lines.ts already uses for SpectrumLine. Co-authored-by: citron --- src/commands/projects.ts | 16 +++++++++++++++- src/commands/spectrum/users.ts | 2 +- 2 files changed, 16 insertions(+), 2 deletions(-) diff --git a/src/commands/projects.ts b/src/commands/projects.ts index 0722690..1bc599b 100644 --- a/src/commands/projects.ts +++ b/src/commands/projects.ts @@ -25,6 +25,20 @@ import { isInteractive } from "~/lib/tty.ts"; const PLATFORMS = ["imessage", "whatsapp_business", "voice"] as const; type Platform = (typeof PLATFORMS)[number]; +/** + * Local DTO for projects list/show. The published `@photon-ai/dashboard-api` + * contract erases response payloads to `any`, so we cast at the API boundary + * to recover field-level types for the fields this CLI actually reads. + */ +interface Project { + id: string; + name: string; + status: string; + location: string; + platforms: string[]; + updatedAt: string; +} + export function registerProjectsCommand(program: Command): void { const projects = program .command("projects") @@ -65,7 +79,7 @@ function registerListCommand(projects: Command): void { die(`Failed to list projects: ${formatApiError(error)}`); } - const list = data ?? []; + const list = (data ?? []) as Project[]; if (opts.json) { printJson(list); return; diff --git a/src/commands/spectrum/users.ts b/src/commands/spectrum/users.ts index 8fc8ad1..e34fd78 100644 --- a/src/commands/spectrum/users.ts +++ b/src/commands/spectrum/users.ts @@ -37,7 +37,7 @@ export function registerSpectrumUsers(spectrum: Command): void { if (status === 401) throw new SessionExpiredError(resolved.name); if (error) die(`Failed to list users: ${formatApiError(error)}`); - const list = data?.users ?? []; + const list = ((data?.users ?? []) as SpectrumUser[]); if (opts.json) return printJson(list); if (list.length === 0) { console.log(c.dim("No Spectrum users yet.")); From 8bb072bcf98d82371a8e309a84fd497351ad6fe1 Mon Sep 17 00:00:00 2001 From: Cursor Agent Date: Thu, 9 Jul 2026 02:48:15 +0000 Subject: [PATCH 3/3] docs: refresh UPSTREAM_DIFF.md for dashboard@v1.6.2 Regenerated against @photon-ai/dashboard-api 1.6.1 (the api version shipping with dashboard@v1.6.2). Adds 7 new routes: call-registry profile/registrations under a project and the new promotional-emails / promotional-status routes on the user profile. No removals or breaking changes. Co-authored-by: citron --- UPSTREAM_DIFF.md | 42 ++++++++++++------------------------------ 1 file changed, 12 insertions(+), 30 deletions(-) diff --git a/UPSTREAM_DIFF.md b/UPSTREAM_DIFF.md index 7e7d390..93e6657 100644 --- a/UPSTREAM_DIFF.md +++ b/UPSTREAM_DIFF.md @@ -1,44 +1,26 @@ # Upstream API Diff -> Old routes: 36 · New routes: 58 +> Old routes: 80 · New routes: 87 ## Added Routes | Route | Method | |-------|--------| -| `api.profile.spectrum-updates` | `PATCH` | -| `api.projects.:id.members` | `GET` | -| `api.projects.:id.members` | `POST` | -| `api.projects.:id.members.:memberUserId` | `DELETE` | -| `api.projects.:id.slack` | `DELETE` | -| `api.projects.:id.slack` | `GET` | -| `api.projects.:id.slack` | `PUT` | -| `api.projects.:id.slack.installations` | `GET` | -| `api.projects.:id.slack.installations.:teamId` | `DELETE` | -| `api.projects.:id.spectrum.avatar` | `DELETE` | -| `api.projects.:id.spectrum.avatar.commit` | `POST` | -| `api.projects.:id.spectrum.avatar.upload` | `POST` | -| `api.projects.:id.voice.imessage-enabled` | `PATCH` | -| `api.projects.:id.voice.settings` | `GET` | -| `api.projects.:id.voice.sip-inbound` | `DELETE` | -| `api.projects.:id.voice.sip-inbound` | `PATCH` | -| `api.projects.:id.webhooks` | `GET` | -| `api.projects.:id.webhooks` | `POST` | -| `api.projects.:id.webhooks.:webhookId` | `DELETE` | -| `api.projects.:id.whatsapp.templates` | `GET` | -| `api.projects.:id.whatsapp.templates` | `POST` | -| `api.projects.:id.whatsapp.templates.:templateId` | `DELETE` | -| `api.projects.:id.whatsapp.templates.:templateId` | `PATCH` | +| `api.profile.promotional-emails` | `PATCH` | +| `api.profile.promotional-status` | `GET` | +| `api.projects.:id.call-registry.profile` | `GET` | +| `api.projects.:id.call-registry.profile` | `PATCH` | +| `api.projects.:id.call-registry.profile` | `PUT` | +| `api.projects.:id.call-registry.registrations` | `GET` | +| `api.projects.:id.call-registry.registrations` | `POST` | ## Removed Routes -| Route | Method | -|-------|--------| -| `api.projects.:id.spectrum.avatar-upload-url` | `GET` | +_(none)_ ## Summary -- **23** added -- **1** removed +- **7** added +- **0** removed - **0** changed -- **35** unchanged +- **80** unchanged