@lumerahq/cli 0.30.14 → 0.30.16
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.
- package/dist/{chunk-ASPEK3I6.js → chunk-2K4ZYGCE.js} +1 -1
- package/dist/{chunk-KZEOP5YF.js → chunk-E7YZ6QS6.js} +5 -0
- package/dist/{chunk-2K2LYH5O.js → chunk-ODANFLL7.js} +1 -1
- package/dist/{deps-22CUIP2M.js → deps-ZDRNDMUF.js} +2 -2
- package/dist/{dev-XBOHUDPR.js → dev-S5JVAXDD.js} +3 -3
- package/dist/index.js +12 -12
- package/dist/{init-L6D5OHMY.js → init-QVR42DUW.js} +1 -1
- package/dist/{register-SBXONOFY.js → register-G3YK77HE.js} +1 -1
- package/dist/{resources-TZD6KV4M.js → resources-LEDTATIA.js} +29 -5
- package/dist/{run-EBTA3FKD.js → run-MSAMUYQH.js} +1 -1
- package/package.json +1 -1
- package/templates/default/package.json +1 -1
- package/templates/default/pnpm-lock.yaml +5 -5
|
@@ -275,6 +275,11 @@ var ApiClient = class {
|
|
|
275
275
|
body: JSON.stringify(def)
|
|
276
276
|
});
|
|
277
277
|
}
|
|
278
|
+
async deleteMailbox(id) {
|
|
279
|
+
await this.request(`/api/mailboxes/${encodeURIComponent(id)}`, {
|
|
280
|
+
method: "DELETE"
|
|
281
|
+
});
|
|
282
|
+
}
|
|
278
283
|
// Agents
|
|
279
284
|
async listAgents(opts) {
|
|
280
285
|
const params = new URLSearchParams({ limit: "100" });
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import {
|
|
2
2
|
deps,
|
|
3
3
|
syncDeps
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-ODANFLL7.js";
|
|
5
5
|
import "./chunk-2CR762KB.js";
|
|
6
|
-
import "./chunk-
|
|
6
|
+
import "./chunk-E7YZ6QS6.js";
|
|
7
7
|
import "./chunk-JLVVHTBY.js";
|
|
8
8
|
import "./chunk-FJFIWC7G.js";
|
|
9
9
|
import "./chunk-PNKVD2UK.js";
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import {
|
|
2
2
|
dev
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-2K4ZYGCE.js";
|
|
4
4
|
import {
|
|
5
5
|
syncDeps
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-ODANFLL7.js";
|
|
7
7
|
import {
|
|
8
8
|
loadEnv
|
|
9
9
|
} from "./chunk-2CR762KB.js";
|
|
10
10
|
import {
|
|
11
11
|
createApiClient
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-E7YZ6QS6.js";
|
|
13
13
|
import {
|
|
14
14
|
findProjectRoot,
|
|
15
15
|
getApiUrl,
|
package/dist/index.js
CHANGED
|
@@ -240,32 +240,32 @@ async function main() {
|
|
|
240
240
|
switch (command) {
|
|
241
241
|
// Resource commands
|
|
242
242
|
case "plan":
|
|
243
|
-
await import("./resources-
|
|
243
|
+
await import("./resources-LEDTATIA.js").then((m) => m.plan(args.slice(1)));
|
|
244
244
|
break;
|
|
245
245
|
case "apply":
|
|
246
|
-
await import("./resources-
|
|
246
|
+
await import("./resources-LEDTATIA.js").then((m) => m.apply(args.slice(1)));
|
|
247
247
|
break;
|
|
248
248
|
case "pull":
|
|
249
|
-
await import("./resources-
|
|
249
|
+
await import("./resources-LEDTATIA.js").then((m) => m.pull(args.slice(1)));
|
|
250
250
|
break;
|
|
251
251
|
case "destroy":
|
|
252
|
-
await import("./resources-
|
|
252
|
+
await import("./resources-LEDTATIA.js").then((m) => m.destroy(args.slice(1)));
|
|
253
253
|
break;
|
|
254
254
|
case "list":
|
|
255
|
-
await import("./resources-
|
|
255
|
+
await import("./resources-LEDTATIA.js").then((m) => m.list(args.slice(1)));
|
|
256
256
|
break;
|
|
257
257
|
case "show":
|
|
258
|
-
await import("./resources-
|
|
258
|
+
await import("./resources-LEDTATIA.js").then((m) => m.show(args.slice(1)));
|
|
259
259
|
break;
|
|
260
260
|
case "diff":
|
|
261
|
-
await import("./resources-
|
|
261
|
+
await import("./resources-LEDTATIA.js").then((m) => m.diff(args.slice(1)));
|
|
262
262
|
break;
|
|
263
263
|
// Development
|
|
264
264
|
case "dev":
|
|
265
|
-
await import("./dev-
|
|
265
|
+
await import("./dev-S5JVAXDD.js").then((m) => m.dev(args.slice(1)));
|
|
266
266
|
break;
|
|
267
267
|
case "run":
|
|
268
|
-
await import("./run-
|
|
268
|
+
await import("./run-MSAMUYQH.js").then((m) => m.run(args.slice(1)));
|
|
269
269
|
break;
|
|
270
270
|
case "functions":
|
|
271
271
|
await import("./functions-DZCNHDRJ.js").then(
|
|
@@ -279,10 +279,10 @@ async function main() {
|
|
|
279
279
|
break;
|
|
280
280
|
// Project
|
|
281
281
|
case "init":
|
|
282
|
-
await import("./init-
|
|
282
|
+
await import("./init-QVR42DUW.js").then((m) => m.init(args.slice(1)));
|
|
283
283
|
break;
|
|
284
284
|
case "register":
|
|
285
|
-
await import("./register-
|
|
285
|
+
await import("./register-G3YK77HE.js").then((m) => m.register(args.slice(1)));
|
|
286
286
|
break;
|
|
287
287
|
case "templates":
|
|
288
288
|
await import("./templates-LNUOTNLN.js").then((m) => m.templates(subcommand, args.slice(2)));
|
|
@@ -299,7 +299,7 @@ async function main() {
|
|
|
299
299
|
break;
|
|
300
300
|
// Dependencies
|
|
301
301
|
case "deps":
|
|
302
|
-
await import("./deps-
|
|
302
|
+
await import("./deps-ZDRNDMUF.js").then((m) => m.deps(args.slice(1)));
|
|
303
303
|
break;
|
|
304
304
|
// Feature flags (read the in-sandbox snapshot)
|
|
305
305
|
case "flags":
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import {
|
|
2
2
|
deploy
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-2K4ZYGCE.js";
|
|
4
4
|
import {
|
|
5
5
|
syncDeps
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-ODANFLL7.js";
|
|
7
7
|
import {
|
|
8
8
|
loadEnv
|
|
9
9
|
} from "./chunk-2CR762KB.js";
|
|
@@ -12,7 +12,7 @@ import {
|
|
|
12
12
|
createApiClient,
|
|
13
13
|
isApiErrorStatus,
|
|
14
14
|
validateCollectionNameLength
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-E7YZ6QS6.js";
|
|
16
16
|
import {
|
|
17
17
|
findProjectRoot,
|
|
18
18
|
getApiUrl,
|
|
@@ -1529,6 +1529,8 @@ ${pc2.dim("Resources:")}
|
|
|
1529
1529
|
agents/<name> Destroy single agent
|
|
1530
1530
|
skills Destroy only project skills
|
|
1531
1531
|
skills/<slug> Destroy single project skill
|
|
1532
|
+
mailboxes Destroy only mailboxes
|
|
1533
|
+
mailboxes/<slug> Destroy single mailbox
|
|
1532
1534
|
app Delete app registration
|
|
1533
1535
|
|
|
1534
1536
|
${pc2.dim("Options:")}
|
|
@@ -1538,6 +1540,7 @@ ${pc2.dim("Options:")}
|
|
|
1538
1540
|
${pc2.dim("Examples:")}
|
|
1539
1541
|
lumera destroy # Destroy everything
|
|
1540
1542
|
lumera destroy collections/users # Destroy single collection
|
|
1543
|
+
lumera destroy mailboxes/support # Destroy single mailbox
|
|
1541
1544
|
lumera destroy app # Delete app registration
|
|
1542
1545
|
`);
|
|
1543
1546
|
}
|
|
@@ -2161,7 +2164,7 @@ async function planMailboxes(api, localMailboxes) {
|
|
|
2161
2164
|
resource: "mailbox",
|
|
2162
2165
|
id: existing.id,
|
|
2163
2166
|
name: mb.slug,
|
|
2164
|
-
details: "description differs (
|
|
2167
|
+
details: "description differs (no update endpoint)"
|
|
2165
2168
|
});
|
|
2166
2169
|
}
|
|
2167
2170
|
}
|
|
@@ -2178,7 +2181,7 @@ async function applyMailboxes(api, localMailboxes) {
|
|
|
2178
2181
|
const localDesc = (mb.description ?? "").trim();
|
|
2179
2182
|
const remoteDesc = (existing.description ?? "").trim();
|
|
2180
2183
|
if (localDesc !== remoteDesc) {
|
|
2181
|
-
console.log(pc2.yellow(" \u26A0"), `mailbox ${mb.slug}: description drift not reconcilable by CLI (no PATCH endpoint yet)
|
|
2184
|
+
console.log(pc2.yellow(" \u26A0"), `mailbox ${mb.slug}: description drift not reconcilable by CLI (no PATCH endpoint yet)`);
|
|
2182
2185
|
} else {
|
|
2183
2186
|
console.log(pc2.green(" \u2713"), pc2.dim(`mailbox ${mb.slug} already exists (${existing.email})`));
|
|
2184
2187
|
}
|
|
@@ -3471,6 +3474,17 @@ async function destroyResources(api, platformDir, resourceType, resourceName, sk
|
|
|
3471
3474
|
}
|
|
3472
3475
|
}
|
|
3473
3476
|
}
|
|
3477
|
+
if (!resourceType || resourceType === "mailboxes") {
|
|
3478
|
+
const localMailboxes = loadLocalMailboxes(platformDir, resourceName || void 0);
|
|
3479
|
+
const remoteMailboxes = await api.listMailboxes();
|
|
3480
|
+
const remoteBySlug = new Map(remoteMailboxes.map((mailbox) => [mailbox.slug, mailbox]));
|
|
3481
|
+
for (const local of localMailboxes) {
|
|
3482
|
+
const remote = remoteBySlug.get(local.slug);
|
|
3483
|
+
if (remote) {
|
|
3484
|
+
toDelete.push({ type: "mailbox", id: local.slug, name: local.slug, remoteId: remote.id });
|
|
3485
|
+
}
|
|
3486
|
+
}
|
|
3487
|
+
}
|
|
3474
3488
|
if (toDelete.length === 0) {
|
|
3475
3489
|
console.log(pc2.green(" \u2713 No resources found to delete"));
|
|
3476
3490
|
return;
|
|
@@ -3497,6 +3511,7 @@ async function destroyResources(api, platformDir, resourceType, resourceName, sk
|
|
|
3497
3511
|
const skills = toDelete.filter((r) => r.type === "skill");
|
|
3498
3512
|
const hooks = toDelete.filter((r) => r.type === "hook");
|
|
3499
3513
|
const automations = toDelete.filter((r) => r.type === "automation");
|
|
3514
|
+
const mailboxes = toDelete.filter((r) => r.type === "mailbox");
|
|
3500
3515
|
const collections = toDelete.filter((r) => r.type === "collection");
|
|
3501
3516
|
let errors = 0;
|
|
3502
3517
|
for (const resource of agents) {
|
|
@@ -3535,6 +3550,15 @@ async function destroyResources(api, platformDir, resourceType, resourceName, sk
|
|
|
3535
3550
|
errors++;
|
|
3536
3551
|
}
|
|
3537
3552
|
}
|
|
3553
|
+
for (const resource of mailboxes) {
|
|
3554
|
+
try {
|
|
3555
|
+
await api.deleteMailbox(resource.remoteId);
|
|
3556
|
+
console.log(pc2.green(" \u2713"), `Deleted mailbox: ${resource.name}`);
|
|
3557
|
+
} catch (e) {
|
|
3558
|
+
console.log(pc2.red(" \u2717"), `Failed to delete mailbox ${resource.name}: ${e}`);
|
|
3559
|
+
errors++;
|
|
3560
|
+
}
|
|
3561
|
+
}
|
|
3538
3562
|
const deletePlan = planCollectionDelete(collections, platformDir);
|
|
3539
3563
|
if (deletePlan.cycleNames.length > 0 && !forceCycles) {
|
|
3540
3564
|
console.log();
|
package/package.json
CHANGED
|
@@ -12,8 +12,8 @@ importers:
|
|
|
12
12
|
.:
|
|
13
13
|
dependencies:
|
|
14
14
|
'@lumerahq/ui':
|
|
15
|
-
specifier: ^0.19.
|
|
16
|
-
version: 0.19.
|
|
15
|
+
specifier: ^0.19.5
|
|
16
|
+
version: 0.19.5(@types/react@19.2.16)(react-dom@19.2.7(react@19.2.7))(react@19.2.7)
|
|
17
17
|
'@tanstack/react-query':
|
|
18
18
|
specifier: ^5.90.11
|
|
19
19
|
version: 5.101.0(react@19.2.7)
|
|
@@ -457,8 +457,8 @@ packages:
|
|
|
457
457
|
'@jridgewell/trace-mapping@0.3.31':
|
|
458
458
|
resolution: {integrity: sha512-zzNR+SdQSDJzc8joaeP8QQoCQr8NuYx2dIIytl1QeBEZHJ9uW6hebsrYgbz8hJwUQao3TWCMtmfV8Nu1twOLAw==}
|
|
459
459
|
|
|
460
|
-
'@lumerahq/ui@0.19.
|
|
461
|
-
resolution: {integrity: sha512-
|
|
460
|
+
'@lumerahq/ui@0.19.5':
|
|
461
|
+
resolution: {integrity: sha512-AkX13UMMEkkHLRktms6Gh6vrygcQbMWxq1Du07qNbiVcVCcAPMWr68chkLdUOM0/00Bgb7JfLu1jrodhtFlrGA==}
|
|
462
462
|
peerDependencies:
|
|
463
463
|
react: ^18.0.0 || ^19.0.0
|
|
464
464
|
react-dom: ^18.0.0 || ^19.0.0
|
|
@@ -2311,7 +2311,7 @@ snapshots:
|
|
|
2311
2311
|
'@jridgewell/resolve-uri': 3.1.2
|
|
2312
2312
|
'@jridgewell/sourcemap-codec': 1.5.5
|
|
2313
2313
|
|
|
2314
|
-
'@lumerahq/ui@0.19.
|
|
2314
|
+
'@lumerahq/ui@0.19.5(@types/react@19.2.16)(react-dom@19.2.7(react@19.2.7))(react@19.2.7)':
|
|
2315
2315
|
dependencies:
|
|
2316
2316
|
'@base-ui/react': 1.5.0(@types/react@19.2.16)(react-dom@19.2.7(react@19.2.7))(react@19.2.7)
|
|
2317
2317
|
'@tanstack/react-query': 5.101.0(react@19.2.7)
|