vercel 54.14.0 → 54.14.2

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 (74) hide show
  1. package/dist/chunks/{add-PVEKZBHH.js → add-PKT6ULVJ.js} +9 -9
  2. package/dist/chunks/{chunk-Y76J3TGD.js → chunk-2HN6DLIY.js} +1 -1
  3. package/dist/chunks/{chunk-FPRA7U2P.js → chunk-2XEEOHHH.js} +1 -1
  4. package/dist/chunks/{chunk-TH555JND.js → chunk-2ZSXQQXI.js} +15 -42
  5. package/dist/chunks/{chunk-6D6CSOSK.js → chunk-372SHB43.js} +86 -62
  6. package/dist/chunks/{chunk-4KAFHBYE.js → chunk-3BR246Y6.js} +1 -1
  7. package/dist/chunks/{chunk-V2WFM23D.js → chunk-4BFK3C7V.js} +2 -2
  8. package/dist/chunks/{chunk-FMN3NXRC.js → chunk-56AJHIQC.js} +1 -1
  9. package/dist/chunks/chunk-64IF634X.js +18 -0
  10. package/dist/chunks/{chunk-VNUNCNPE.js → chunk-AWD3IGXU.js} +3 -3
  11. package/dist/chunks/{chunk-5SYDEK2N.js → chunk-D7MGZH35.js} +1 -1
  12. package/dist/chunks/{chunk-IQQJHYW4.js → chunk-DPS62LHL.js} +2 -2
  13. package/dist/chunks/{chunk-RWJORLQP.js → chunk-FEYVO2US.js} +59 -17
  14. package/dist/chunks/{chunk-ABOX5TXU.js → chunk-FLW73SZ3.js} +3 -3
  15. package/dist/chunks/{chunk-Z7KOKD2G.js → chunk-G3NXHUFT.js} +1 -1
  16. package/dist/chunks/{chunk-CO5D46AG.js → chunk-GGP5R3FU.js} +18 -38
  17. package/dist/chunks/{chunk-J5273CSE.js → chunk-HIYWSGI7.js} +19 -10
  18. package/dist/chunks/{chunk-WFRHKZFI.js → chunk-IB56QKCM.js} +1 -1
  19. package/dist/chunks/{chunk-ZTPOJE63.js → chunk-IJJOI63T.js} +1 -1
  20. package/dist/chunks/{chunk-DAASB6YQ.js → chunk-ILJH44MK.js} +23 -3
  21. package/dist/chunks/{chunk-V4GROAUJ.js → chunk-IPWWE7PB.js} +4 -7
  22. package/dist/chunks/{chunk-G7QWUIGS.js → chunk-J7BMPRCU.js} +3 -3
  23. package/dist/chunks/{chunk-7OZWGXPA.js → chunk-JISJDGJF.js} +2 -2
  24. package/dist/chunks/{chunk-5UCWXYNH.js → chunk-LQR3CHMH.js} +88 -46
  25. package/dist/chunks/{chunk-4NDOMD3E.js → chunk-LYCSVJIX.js} +1 -1
  26. package/dist/chunks/{chunk-6IQZVQV6.js → chunk-MYWLF3BZ.js} +18 -0
  27. package/dist/chunks/{chunk-6K3WJDFA.js → chunk-O4V7CMVO.js} +10 -10
  28. package/dist/chunks/{chunk-KJ5O7JQQ.js → chunk-O7RJHL34.js} +81 -86
  29. package/dist/chunks/{chunk-C3VH3X5Y.js → chunk-OHIZ4SVU.js} +4 -4
  30. package/dist/chunks/{chunk-JFWE5ORG.js → chunk-P4KQ3FJ4.js} +1 -0
  31. package/dist/chunks/{chunk-PV533MBH.js → chunk-PMUUPCDL.js} +1 -1
  32. package/dist/chunks/{chunk-OEM7RB3X.js → chunk-SDZ5ICZL.js} +2 -2
  33. package/dist/chunks/{chunk-NGRSQRSN.js → chunk-SGPBULVT.js} +1 -1
  34. package/dist/chunks/{chunk-RM4XGGZO.js → chunk-TSENBD7C.js} +2 -2
  35. package/dist/chunks/{chunk-O4C4A7HM.js → chunk-VKRW77HH.js} +1 -1
  36. package/dist/chunks/chunk-VXYGCOKL.js +28 -0
  37. package/dist/chunks/{chunk-7CJZCFLW.js → chunk-YLGMXYFG.js} +2 -2
  38. package/dist/chunks/{chunk-B6C7NMT3.js → chunk-Z2MBXYZZ.js} +1 -1
  39. package/dist/chunks/{chunk-S4VHXL2Y.js → chunk-Z3X747P6.js} +1 -1
  40. package/dist/chunks/{compile-vercel-config-MD37D2F7.js → compile-vercel-config-3LV7J3IZ.js} +4 -4
  41. package/dist/chunks/{delete-6EMDCXSA.js → delete-GFW6Y6TZ.js} +10 -8
  42. package/dist/chunks/{disable-FLJ27NHG.js → disable-PGRAS2ZL.js} +10 -8
  43. package/dist/chunks/{discard-KEIII6RM.js → discard-S6N5Q4G5.js} +10 -8
  44. package/dist/chunks/{edit-DOL2ZJPG.js → edit-TICKX4ZV.js} +12 -10
  45. package/dist/chunks/{enable-PZWZIETT.js → enable-L3BYWN6S.js} +10 -8
  46. package/dist/chunks/{export-2PFHAELC.js → export-NXS33U5T.js} +6 -6
  47. package/dist/chunks/{inspect-WPWOZJ2K.js → inspect-OOI5JN3Y.js} +9 -9
  48. package/dist/chunks/{list-4R5DCLTB.js → list-6EHRL2D4.js} +7 -7
  49. package/dist/chunks/{list-ZT7QK2H7.js → list-77WL6463.js} +11 -11
  50. package/dist/chunks/{ls-4JTXQXMQ.js → ls-PBSOEXFG.js} +9 -9
  51. package/dist/chunks/{publish-JV4J3SOA.js → publish-CU2THVYW.js} +10 -8
  52. package/dist/chunks/{query-N22EYSZZ.js → query-HEATRYAK.js} +99 -43
  53. package/dist/chunks/{reorder-TG53BKW4.js → reorder-IQVKSM3H.js} +10 -8
  54. package/dist/chunks/{restore-U7O4VESA.js → restore-RDEOBGAS.js} +10 -8
  55. package/dist/chunks/{rm-XA4LYZXI.js → rm-MCSGTU4J.js} +9 -9
  56. package/dist/chunks/{routes-EAMQVFU2.js → routes-YEU33SON.js} +2 -2
  57. package/dist/chunks/{rule-inspect-HC745CYT.js → rule-inspect-3YK2XSL3.js} +9 -9
  58. package/dist/chunks/{rules-RMN72YHN.js → rules-F4MRDDHM.js} +6 -6
  59. package/dist/chunks/{schema-CZVKUXM6.js → schema-65C5EBJ7.js} +9 -9
  60. package/dist/chunks/{stamp-ENIXDCRO.js → stamp-AA7R3MZS.js} +3 -1
  61. package/dist/chunks/{types-P6JKZFEY.js → types-3R7HKP57.js} +3 -3
  62. package/dist/chunks/{update-PU3WLIA7.js → update-XB4WSRGY.js} +9 -9
  63. package/dist/commands/build/index.js +18 -16
  64. package/dist/commands/deploy/index.js +30 -171
  65. package/dist/commands/dev/index.js +187 -133
  66. package/dist/commands/dev/next-dev-websocket-shim-preload.cjs +190 -0
  67. package/dist/commands/env/index.js +162 -101
  68. package/dist/commands/link/index.js +19 -19
  69. package/dist/commands/list/index.js +13 -11
  70. package/dist/commands-bulk.js +258 -104
  71. package/dist/help.js +1 -1
  72. package/dist/index.js +27 -27
  73. package/dist/version.mjs +1 -1
  74. package/package.json +11 -11
@@ -10,7 +10,7 @@ import {
10
10
  import {
11
11
  RoutesAddTelemetryClient,
12
12
  RoutesTelemetryClient
13
- } from "./chunks/chunk-PV533MBH.js";
13
+ } from "./chunks/chunk-PMUUPCDL.js";
14
14
  import {
15
15
  ALL_ACTION_CHOICES,
16
16
  MAX_CONDITIONS,
@@ -31,7 +31,7 @@ import {
31
31
  runInteractiveEditLoop,
32
32
  stripQuotes,
33
33
  validateActionFlags
34
- } from "./chunks/chunk-S4VHXL2Y.js";
34
+ } from "./chunks/chunk-Z3X747P6.js";
35
35
  import {
36
36
  getRouteVersions
37
37
  } from "./chunks/chunk-AHU7WNL2.js";
@@ -48,10 +48,10 @@ import {
48
48
  parsePosition,
49
49
  parseSubcommandArgs,
50
50
  withGlobalFlags
51
- } from "./chunks/chunk-G7QWUIGS.js";
51
+ } from "./chunks/chunk-J7BMPRCU.js";
52
52
  import {
53
53
  normalizeRepeatableStringFilters
54
- } from "./chunks/chunk-5SYDEK2N.js";
54
+ } from "./chunks/chunk-D7MGZH35.js";
55
55
  import {
56
56
  OpenApiCache,
57
57
  api,
@@ -64,11 +64,11 @@ import {
64
64
  resolveOpenApiTagForTeamsCli,
65
65
  setAutoUpdate,
66
66
  tryOpenApiFallback
67
- } from "./chunks/chunk-RWJORLQP.js";
67
+ } from "./chunks/chunk-FEYVO2US.js";
68
68
  import {
69
69
  getUpdateCommand,
70
70
  isGlobal
71
- } from "./chunks/chunk-V4GROAUJ.js";
71
+ } from "./chunks/chunk-IPWWE7PB.js";
72
72
  import {
73
73
  Now,
74
74
  collectContactInformation,
@@ -89,14 +89,14 @@ import {
89
89
  require_format,
90
90
  require_jsonlines,
91
91
  setupDomain
92
- } from "./chunks/chunk-TH555JND.js";
92
+ } from "./chunks/chunk-2ZSXQQXI.js";
93
93
  import {
94
94
  getGlobalPathConfig,
95
95
  persistAuthConfig,
96
96
  readLocalConfig,
97
97
  sleep,
98
98
  writeToConfigFile
99
- } from "./chunks/chunk-C3VH3X5Y.js";
99
+ } from "./chunks/chunk-OHIZ4SVU.js";
100
100
  import "./chunks/chunk-V5P25P7F.js";
101
101
  import {
102
102
  ellipsis,
@@ -108,7 +108,7 @@ import {
108
108
  } from "./chunks/chunk-WEVQWSBT.js";
109
109
  import {
110
110
  formatTable
111
- } from "./chunks/chunk-RM4XGGZO.js";
111
+ } from "./chunks/chunk-TSENBD7C.js";
112
112
  import "./chunks/chunk-LKBI43XK.js";
113
113
  import {
114
114
  isValidName
@@ -124,7 +124,7 @@ import {
124
124
  import {
125
125
  formatEnvironment,
126
126
  validateLsArgs
127
- } from "./chunks/chunk-Y76J3TGD.js";
127
+ } from "./chunks/chunk-2HN6DLIY.js";
128
128
  import {
129
129
  validateJsonOutput
130
130
  } from "./chunks/chunk-XPKWKPWA.js";
@@ -189,6 +189,7 @@ import {
189
189
  createSubcommand3,
190
190
  createSubcommand4,
191
191
  createSubcommand5,
192
+ createSubcommand6,
192
193
  createThresholdSubcommand,
193
194
  creditsSubcommand,
194
195
  cronsCommand,
@@ -382,11 +383,11 @@ import {
382
383
  webAnalyticsSubcommand,
383
384
  webhooksCommand,
384
385
  whoamiCommand
385
- } from "./chunks/chunk-KJ5O7JQQ.js";
386
+ } from "./chunks/chunk-O7RJHL34.js";
386
387
  import {
387
388
  metricsCommand,
388
389
  schemaSubcommand
389
- } from "./chunks/chunk-DAASB6YQ.js";
390
+ } from "./chunks/chunk-ILJH44MK.js";
390
391
  import {
391
392
  addSubcommand as addSubcommand9,
392
393
  deleteSubcommand,
@@ -402,12 +403,12 @@ import {
402
403
  reorderSubcommand,
403
404
  restoreSubcommand as restoreSubcommand2,
404
405
  routesCommand
405
- } from "./chunks/chunk-WFRHKZFI.js";
406
+ } from "./chunks/chunk-IB56QKCM.js";
406
407
  import {
407
408
  alertsCommand,
408
409
  inspectSubcommand,
409
410
  listSubcommand
410
- } from "./chunks/chunk-IQQJHYW4.js";
411
+ } from "./chunks/chunk-DPS62LHL.js";
411
412
  import {
412
413
  rulesAddSubcommand as rulesAddSubcommand2,
413
414
  rulesAggregateCommand,
@@ -415,38 +416,44 @@ import {
415
416
  rulesLsSubcommand,
416
417
  rulesRmSubcommand,
417
418
  rulesUpdateSubcommand
418
- } from "./chunks/chunk-NGRSQRSN.js";
419
- import "./chunks/chunk-O4C4A7HM.js";
419
+ } from "./chunks/chunk-SGPBULVT.js";
420
+ import "./chunks/chunk-VKRW77HH.js";
420
421
  import {
421
422
  activityCommand,
422
423
  typesSubcommand
423
- } from "./chunks/chunk-FMN3NXRC.js";
424
- import "./chunks/chunk-ZTPOJE63.js";
424
+ } from "./chunks/chunk-56AJHIQC.js";
425
+ import "./chunks/chunk-IJJOI63T.js";
425
426
  import {
426
427
  main
427
- } from "./chunks/chunk-6K3WJDFA.js";
428
- import "./chunks/chunk-FPRA7U2P.js";
428
+ } from "./chunks/chunk-O4V7CMVO.js";
429
+ import "./chunks/chunk-2XEEOHHH.js";
429
430
  import {
430
431
  require_execa
431
432
  } from "./chunks/chunk-YI3JV6GM.js";
433
+ import {
434
+ stamp_default
435
+ } from "./chunks/chunk-64IF634X.js";
436
+ import {
437
+ elapsed
438
+ } from "./chunks/chunk-VXYGCOKL.js";
432
439
  import {
433
440
  ensureLink
434
- } from "./chunks/chunk-7CJZCFLW.js";
435
- import "./chunks/chunk-6D6CSOSK.js";
441
+ } from "./chunks/chunk-YLGMXYFG.js";
442
+ import "./chunks/chunk-372SHB43.js";
436
443
  import {
437
444
  AGENT_ACTION,
438
445
  AGENT_REASON,
439
446
  AGENT_STATUS
440
447
  } from "./chunks/chunk-LJ5WXXG6.js";
441
- import "./chunks/chunk-V2WFM23D.js";
442
- import "./chunks/chunk-OEM7RB3X.js";
448
+ import "./chunks/chunk-4BFK3C7V.js";
449
+ import "./chunks/chunk-SDZ5ICZL.js";
443
450
  import {
444
451
  detectExplicitScope,
445
452
  getScope
446
- } from "./chunks/chunk-Z7KOKD2G.js";
453
+ } from "./chunks/chunk-G3NXHUFT.js";
447
454
  import {
448
455
  help
449
- } from "./chunks/chunk-VNUNCNPE.js";
456
+ } from "./chunks/chunk-AWD3IGXU.js";
450
457
  import {
451
458
  STANDARD_ENVIRONMENTS,
452
459
  VERCEL_CONFIG_EXTENSIONS,
@@ -493,10 +500,10 @@ import {
493
500
  selectAndParseRemoteUrl,
494
501
  selectOrg,
495
502
  ua_default
496
- } from "./chunks/chunk-5UCWXYNH.js";
503
+ } from "./chunks/chunk-LQR3CHMH.js";
497
504
  import {
498
505
  TelemetryClient
499
- } from "./chunks/chunk-J5273CSE.js";
506
+ } from "./chunks/chunk-HIYWSGI7.js";
500
507
  import {
501
508
  argvHasNonInteractive,
502
509
  buildCommandWithGlobalFlags,
@@ -509,17 +516,15 @@ import {
509
516
  outputAgentError,
510
517
  shouldEmitNonInteractiveCommandError
511
518
  } from "./chunks/chunk-NHGCQRK5.js";
512
- import {
513
- elapsed,
514
- require_ms,
515
- stamp_default
516
- } from "./chunks/chunk-CO5D46AG.js";
517
519
  import {
518
520
  require_lib as require_lib3
519
521
  } from "./chunks/chunk-N2T234LO.js";
522
+ import {
523
+ require_ms
524
+ } from "./chunks/chunk-GGP5R3FU.js";
520
525
  import {
521
526
  table
522
- } from "./chunks/chunk-4NDOMD3E.js";
527
+ } from "./chunks/chunk-LYCSVJIX.js";
523
528
  import {
524
529
  GLOBAL_CLI_FLAG_NAMES,
525
530
  getCommandNameWithGlobalFlags,
@@ -530,7 +535,7 @@ import {
530
535
  parseArguments,
531
536
  printError,
532
537
  require_strip_ansi
533
- } from "./chunks/chunk-6IQZVQV6.js";
538
+ } from "./chunks/chunk-MYWLF3BZ.js";
534
539
  import {
535
540
  APIError,
536
541
  AliasInUse,
@@ -866,7 +871,7 @@ async function activity(client) {
866
871
  return 0;
867
872
  }
868
873
  telemetry2.trackCliSubcommandTypes(subcommandOriginal);
869
- const typesFn = (await import("./chunks/types-P6JKZFEY.js")).default;
874
+ const typesFn = (await import("./chunks/types-3R7HKP57.js")).default;
870
875
  return typesFn(client, telemetry2);
871
876
  }
872
877
  default: {
@@ -876,7 +881,7 @@ async function activity(client) {
876
881
  return 0;
877
882
  }
878
883
  telemetry2.trackCliSubcommandLs(subcommandOriginal);
879
- const listFn = (await import("./chunks/list-4R5DCLTB.js")).default;
884
+ const listFn = (await import("./chunks/list-6EHRL2D4.js")).default;
880
885
  return listFn(client, telemetry2);
881
886
  }
882
887
  }
@@ -1979,17 +1984,17 @@ async function alerts(client) {
1979
1984
  switch (subcommand) {
1980
1985
  case "inspect": {
1981
1986
  telemetry2.trackCliSubcommandInspect(subcommandOriginal);
1982
- const inspectFn = (await import("./chunks/inspect-WPWOZJ2K.js")).default;
1987
+ const inspectFn = (await import("./chunks/inspect-OOI5JN3Y.js")).default;
1983
1988
  return inspectFn(client, args);
1984
1989
  }
1985
1990
  case "rules": {
1986
1991
  telemetry2.trackCliSubcommandRules(args[0] ?? "ls");
1987
- const rulesFn = (await import("./chunks/rules-RMN72YHN.js")).default;
1992
+ const rulesFn = (await import("./chunks/rules-F4MRDDHM.js")).default;
1988
1993
  return rulesFn(client, args);
1989
1994
  }
1990
1995
  default: {
1991
1996
  telemetry2.trackCliSubcommandLs(subcommandOriginal);
1992
- const listFn = (await import("./chunks/list-ZT7QK2H7.js")).default;
1997
+ const listFn = (await import("./chunks/list-77WL6463.js")).default;
1993
1998
  return listFn(client, telemetry2);
1994
1999
  }
1995
2000
  }
@@ -4334,19 +4339,24 @@ async function addStore(client, argv) {
4334
4339
  args: [nameArg],
4335
4340
  flags
4336
4341
  } = parsedArgs;
4342
+ const interactive = client.stdin.isTTY && !client.nonInteractive;
4337
4343
  const yes = flags["--yes"] ?? false;
4338
4344
  const environmentFlags = flags["--environment"];
4339
4345
  if (environmentFlags?.length) {
4340
4346
  const envValidation = validateEnvironments(environmentFlags);
4341
4347
  if (!envValidation.valid) {
4342
- output_manager_default.error(
4343
- `Invalid environment value: ${envValidation.invalid.map((e2) => `"${e2}"`).join(", ")}. Must be one of: ${VALID_ENVIRONMENTS.join(", ")}`
4344
- );
4348
+ const message = `Invalid environment value: ${envValidation.invalid.map((e2) => `"${e2}"`).join(", ")}. Must be one of: ${VALID_ENVIRONMENTS.join(", ")}`;
4349
+ outputAgentError(client, {
4350
+ status: "error",
4351
+ reason: "invalid_arguments",
4352
+ message
4353
+ });
4354
+ output_manager_default.error(message);
4345
4355
  return 1;
4346
4356
  }
4347
4357
  }
4348
4358
  let accessFlag = flags["--access"];
4349
- if (!accessFlag && client.stdin.isTTY) {
4359
+ if (!accessFlag && interactive) {
4350
4360
  accessFlag = await client.input.select({
4351
4361
  message: "Choose the access type for the blob store",
4352
4362
  choices: [
@@ -4363,30 +4373,75 @@ async function addStore(client, argv) {
4363
4373
  ]
4364
4374
  });
4365
4375
  }
4376
+ if (!accessFlag) {
4377
+ outputAgentError(client, {
4378
+ status: "error",
4379
+ reason: "missing_arguments",
4380
+ message: "Missing required --access flag. Must be 'public' or 'private'.",
4381
+ next: [
4382
+ {
4383
+ command: buildCommandWithGlobalFlags(
4384
+ client.argv,
4385
+ "blob create-store <name> --access private --yes"
4386
+ ),
4387
+ when: "create a private blob store and link it to the project"
4388
+ }
4389
+ ]
4390
+ });
4391
+ }
4366
4392
  const access3 = parseAccessFlag(accessFlag);
4367
4393
  if (!access3)
4368
4394
  return 1;
4369
4395
  const region = flags["--region"] || "iad1";
4370
4396
  let name = nameArg;
4371
4397
  if (!name) {
4372
- if (!client.stdin.isTTY) {
4398
+ if (interactive) {
4399
+ name = await client.input.text({
4400
+ message: "Enter a name for your blob store",
4401
+ validate: (value) => {
4402
+ if (value.length < 5) {
4403
+ return "Name must be at least 5 characters long";
4404
+ }
4405
+ return true;
4406
+ }
4407
+ });
4408
+ } else {
4409
+ outputAgentError(client, {
4410
+ status: "error",
4411
+ reason: "missing_arguments",
4412
+ message: "Missing required argument: name.",
4413
+ next: [
4414
+ {
4415
+ command: buildCommandWithGlobalFlags(
4416
+ client.argv,
4417
+ `blob create-store <name> --access ${access3} --yes`
4418
+ ),
4419
+ when: "create the blob store and link it to the project"
4420
+ }
4421
+ ]
4422
+ });
4373
4423
  output_manager_default.error("Missing required argument: name");
4374
4424
  return 1;
4375
4425
  }
4376
- name = await client.input.text({
4377
- message: "Enter a name for your blob store",
4378
- validate: (value) => {
4379
- if (value.length < 5) {
4380
- return "Name must be at least 5 characters long";
4381
- }
4382
- return true;
4383
- }
4384
- });
4385
4426
  }
4386
4427
  telemetryClient.trackCliArgumentName(name);
4387
4428
  telemetryClient.trackCliOptionAccess(accessFlag);
4388
4429
  telemetryClient.trackCliOptionRegion(flags["--region"]);
4389
4430
  const link = await getLinkedProject(client);
4431
+ if (link.status === "linked" && client.nonInteractive && !yes && !environmentFlags?.length) {
4432
+ outputAgentError(client, {
4433
+ status: "error",
4434
+ reason: "confirmation_required",
4435
+ message: `Creating a blob store and linking it to ${link.project.name} requires confirmation. Re-run with --yes to create the store and link it to all environments, or pass --environment to choose which ones.`,
4436
+ next: [
4437
+ {
4438
+ command: buildCommandWithYes(client.argv),
4439
+ when: "create the store and link it to all environments"
4440
+ }
4441
+ ]
4442
+ });
4443
+ return 1;
4444
+ }
4390
4445
  let storeId;
4391
4446
  let storeRegion;
4392
4447
  try {
@@ -4413,20 +4468,23 @@ async function addStore(client, argv) {
4413
4468
  const docsUrl = access3 === "public" ? "https://vercel.com/docs/vercel-blob/public-storage" : "https://vercel.com/docs/vercel-blob/private-storage";
4414
4469
  output_manager_default.log(`Access: ${access3}. Learn more: ${output_manager_default.link(docsUrl, docsUrl)}`);
4415
4470
  if (link.status === "linked") {
4416
- let shouldLink = yes;
4417
- if (!shouldLink) {
4471
+ let shouldLink = yes || Boolean(environmentFlags?.length);
4472
+ if (!shouldLink && interactive) {
4418
4473
  shouldLink = await client.input.confirm(
4419
4474
  `Would you like to link this blob store to ${link.project.name}?`,
4420
4475
  true
4421
4476
  );
4422
4477
  }
4478
+ if (!shouldLink && !interactive) {
4479
+ output_manager_default.log(
4480
+ `Not linked to ${import_chalk19.default.bold(link.project.name)}. Pass --yes when creating to link the store to your project automatically.`
4481
+ );
4482
+ }
4423
4483
  if (shouldLink) {
4424
4484
  let environments;
4425
4485
  if (environmentFlags?.length) {
4426
4486
  environments = environmentFlags;
4427
- } else if (yes) {
4428
- environments = [...VALID_ENVIRONMENTS];
4429
- } else {
4487
+ } else if (interactive && !yes) {
4430
4488
  environments = await client.input.checkbox({
4431
4489
  message: "Select environments",
4432
4490
  choices: [
@@ -4435,6 +4493,8 @@ async function addStore(client, argv) {
4435
4493
  { name: "Development", value: "development", checked: true }
4436
4494
  ]
4437
4495
  });
4496
+ } else {
4497
+ environments = [...VALID_ENVIRONMENTS];
4438
4498
  }
4439
4499
  output_manager_default.spinner(
4440
4500
  `Connecting ${import_chalk19.default.bold(name)} to ${import_chalk19.default.bold(link.project.name)}...`
@@ -4500,24 +4560,40 @@ async function removeStore(client, argv, rwToken) {
4500
4560
  args: [storeIdArg],
4501
4561
  flags: { "--yes": yes }
4502
4562
  } = parsedArgs;
4563
+ const interactive = client.stdin.isTTY && !client.nonInteractive;
4503
4564
  let storeId = storeIdArg;
4504
4565
  if (!storeId) {
4505
4566
  storeId = getStoreIdFromAuth(rwToken) ?? void 0;
4506
4567
  }
4507
4568
  if (!storeId) {
4508
- if (!client.stdin.isTTY) {
4569
+ if (interactive) {
4570
+ storeId = await client.input.text({
4571
+ message: "Enter the ID of the blob store you want to remove",
4572
+ validate: (value) => {
4573
+ if (value.length !== 22) {
4574
+ return "ID must be 22 characters long";
4575
+ }
4576
+ return true;
4577
+ }
4578
+ });
4579
+ } else {
4580
+ outputAgentError(client, {
4581
+ status: "error",
4582
+ reason: "missing_arguments",
4583
+ message: "Missing required argument: storeId.",
4584
+ next: [
4585
+ {
4586
+ command: buildCommandWithGlobalFlags(
4587
+ client.argv,
4588
+ "blob delete-store <storeId> --yes"
4589
+ ),
4590
+ when: "delete the blob store"
4591
+ }
4592
+ ]
4593
+ });
4509
4594
  output_manager_default.error("Missing required argument: storeId");
4510
4595
  return 1;
4511
4596
  }
4512
- storeId = await client.input.text({
4513
- message: "Enter the ID of the blob store you want to remove",
4514
- validate: (value) => {
4515
- if (value.length !== 22) {
4516
- return "ID must be 22 characters long";
4517
- }
4518
- return true;
4519
- }
4520
- });
4521
4597
  }
4522
4598
  const link = await getLinkedProject(client);
4523
4599
  const accountId = link.status === "linked" ? link.org.id : void 0;
@@ -4540,7 +4616,18 @@ async function removeStore(client, argv, rwToken) {
4540
4616
  connectionsResponse.connections
4541
4617
  );
4542
4618
  if (!yes) {
4543
- if (!client.stdin.isTTY) {
4619
+ if (!interactive) {
4620
+ outputAgentError(client, {
4621
+ status: "error",
4622
+ reason: "confirmation_required",
4623
+ message: `Removing ${label} cannot be undone and requires confirmation. Re-run with --yes.`,
4624
+ next: [
4625
+ {
4626
+ command: buildCommandWithYes(client.argv),
4627
+ when: "remove the blob store without prompting"
4628
+ }
4629
+ ]
4630
+ });
4544
4631
  output_manager_default.error(
4545
4632
  "Confirmation required. Use --yes to skip confirmation in non-interactive environments."
4546
4633
  );
@@ -4661,24 +4748,40 @@ async function getStore(client, argv, rwToken) {
4661
4748
  const {
4662
4749
  args: [storeIdArg]
4663
4750
  } = parsedArgs;
4751
+ const interactive = client.stdin.isTTY && !client.nonInteractive;
4664
4752
  let storeId = storeIdArg;
4665
4753
  if (!storeId) {
4666
4754
  storeId = getStoreIdFromAuth(rwToken) ?? void 0;
4667
4755
  }
4668
4756
  if (!storeId) {
4669
- if (!client.stdin.isTTY) {
4757
+ if (interactive) {
4758
+ storeId = await client.input.text({
4759
+ message: "Enter the ID of the blob store you want to get info about",
4760
+ validate: (value) => {
4761
+ if (value.length !== 22) {
4762
+ return "ID must be 22 characters long";
4763
+ }
4764
+ return true;
4765
+ }
4766
+ });
4767
+ } else {
4768
+ outputAgentError(client, {
4769
+ status: "error",
4770
+ reason: "missing_arguments",
4771
+ message: "Missing required argument: storeId.",
4772
+ next: [
4773
+ {
4774
+ command: buildCommandWithGlobalFlags(
4775
+ client.argv,
4776
+ "blob get-store <storeId>"
4777
+ ),
4778
+ when: "get the blob store details"
4779
+ }
4780
+ ]
4781
+ });
4670
4782
  output_manager_default.error("Missing required argument: storeId");
4671
4783
  return 1;
4672
4784
  }
4673
- storeId = await client.input.text({
4674
- message: "Enter the ID of the blob store you want to get info about",
4675
- validate: (value) => {
4676
- if (value.length !== 22) {
4677
- return "ID must be 22 characters long";
4678
- }
4679
- return true;
4680
- }
4681
- });
4682
4785
  }
4683
4786
  telemetryClient.trackCliArgumentStoreId(storeId);
4684
4787
  try {
@@ -4747,6 +4850,7 @@ async function listStores(client, argv) {
4747
4850
  const showAll = parsedArgs.flags["--all"] ?? false;
4748
4851
  const jsonOutput = parsedArgs.flags["--json"] ?? false;
4749
4852
  const noProjects = parsedArgs.flags["--no-projects"] ?? false;
4853
+ const interactive = client.stdin.isTTY && client.stdout.isTTY && !client.nonInteractive;
4750
4854
  const telemetryClient = new BlobListStoresTelemetryClient({
4751
4855
  opts: {
4752
4856
  store: client.telemetryEventStore
@@ -4819,7 +4923,7 @@ async function listStores(client, argv) {
4819
4923
  }
4820
4924
  const header = linkedProject ? `Blob stores for project ${import_chalk21.default.bold(linkedProject.name)}:` : `Blob stores:`;
4821
4925
  output_manager_default.log(header);
4822
- if (!client.stdin.isTTY || !client.stdout.isTTY) {
4926
+ if (!interactive) {
4823
4927
  output_manager_default.print(
4824
4928
  table(buildTableRows(stores, noProjects), { hsep: 3 }).replace(
4825
4929
  /^/gm,
@@ -4965,6 +5069,7 @@ async function emptyStore(client, argv, auth) {
4965
5069
  const {
4966
5070
  flags: { "--yes": yes }
4967
5071
  } = parsedArgs;
5072
+ const interactive = client.stdin.isTTY && !client.nonInteractive;
4968
5073
  telemetryClient.trackCliFlagYes(yes);
4969
5074
  const storeId = getStoreIdFromAuth(auth);
4970
5075
  if (!storeId) {
@@ -4999,7 +5104,18 @@ async function emptyStore(client, argv, auth) {
4999
5104
  const projectsInfo = formatConnectedProjects(connections);
5000
5105
  const message = `Are you sure you want to delete all files in ${label}?${projectsInfo} This action cannot be undone.`;
5001
5106
  if (!yes) {
5002
- if (!client.stdin.isTTY) {
5107
+ if (!interactive) {
5108
+ outputAgentError(client, {
5109
+ status: "error",
5110
+ reason: "confirmation_required",
5111
+ message: `Deleting all files in ${label} cannot be undone and requires confirmation. Re-run with --yes.`,
5112
+ next: [
5113
+ {
5114
+ command: buildCommandWithYes(client.argv),
5115
+ when: "empty the blob store without prompting"
5116
+ }
5117
+ ]
5118
+ });
5003
5119
  output_manager_default.error(
5004
5120
  "Missing --yes flag. This is a destructive operation, use --yes to confirm."
5005
5121
  );
@@ -10771,7 +10887,10 @@ function parseCurlLikeArgs(rawArgs, commandName) {
10771
10887
  function setupCurlLikeCommand(client, command, telemetryClient, options = {}) {
10772
10888
  const { print } = output_manager_default;
10773
10889
  if (options.allowFullUrl) {
10774
- const parsed = parseCurlLikeArgs(client.argv.slice(2), command.name);
10890
+ const parsed = parseCurlLikeArgs(
10891
+ options.args ?? client.argv.slice(2),
10892
+ command.name
10893
+ );
10775
10894
  if (parsed.help) {
10776
10895
  print(help(command, { columns: client.stderr.columns }));
10777
10896
  return 2;
@@ -11401,13 +11520,17 @@ async function runCurlWithCookie(token2, userId, curlFlags, json) {
11401
11520
 
11402
11521
  // src/commands/curl/index.ts
11403
11522
  async function curl(client) {
11523
+ return runCurl(client, {});
11524
+ }
11525
+ async function runCurl(client, { forceTrace = false, args }) {
11404
11526
  const telemetryClient = new CurlTelemetryClient({
11405
11527
  opts: {
11406
11528
  store: client.telemetryEventStore
11407
11529
  }
11408
11530
  });
11409
11531
  const setup = setupCurlLikeCommand(client, curlCommand, telemetryClient, {
11410
- allowFullUrl: true
11532
+ allowFullUrl: true,
11533
+ args
11411
11534
  });
11412
11535
  if (typeof setup === "number") {
11413
11536
  return setup;
@@ -11418,9 +11541,9 @@ async function curl(client) {
11418
11541
  deploymentFlag,
11419
11542
  protectionBypassFlag,
11420
11543
  toolFlags,
11421
- trace: traceFlag,
11422
11544
  json: jsonFlag
11423
11545
  } = setup;
11546
+ const traceFlag = forceTrace || setup.trace;
11424
11547
  const result = isFullUrl ? await getFullUrlAndToken(client, path3, protectionBypassFlag) : await getDeploymentUrlAndToken(client, "curl", path3, {
11425
11548
  deploymentFlag,
11426
11549
  protectionBypassFlag,
@@ -36955,7 +37078,7 @@ var MetricsTelemetryClient = class extends TelemetryClient {
36955
37078
  }
36956
37079
  }
36957
37080
  trackCliOptionFilter(v) {
36958
- if (v) {
37081
+ if (v && v.length > 0) {
36959
37082
  this.trackCliOption({
36960
37083
  option: "filter",
36961
37084
  value: this.redactedValue
@@ -36986,6 +37109,22 @@ var MetricsTelemetryClient = class extends TelemetryClient {
36986
37109
  });
36987
37110
  }
36988
37111
  }
37112
+ trackCliOptionBucketTimezone(v) {
37113
+ if (v) {
37114
+ this.trackCliOption({
37115
+ option: "bucket-timezone",
37116
+ value: v
37117
+ });
37118
+ }
37119
+ }
37120
+ trackCliOptionProject(v) {
37121
+ if (v) {
37122
+ this.trackCliOption({
37123
+ option: "project",
37124
+ value: this.redactedValue
37125
+ });
37126
+ }
37127
+ }
36989
37128
  trackCliFlagAll(v) {
36990
37129
  if (v) {
36991
37130
  this.trackCliFlag("all");
@@ -37041,7 +37180,7 @@ async function metrics(client) {
37041
37180
  return 0;
37042
37181
  }
37043
37182
  telemetry2.trackCliSubcommandSchema(subcommandOriginal);
37044
- const schemaFn = (await import("./chunks/schema-CZVKUXM6.js")).default;
37183
+ const schemaFn = (await import("./chunks/schema-65C5EBJ7.js")).default;
37045
37184
  return schemaFn(client, telemetry2);
37046
37185
  }
37047
37186
  default: {
@@ -37054,7 +37193,7 @@ async function metrics(client) {
37054
37193
  output_manager_default.print(help(metricsCommand, { columns: client.stderr.columns }));
37055
37194
  return 2;
37056
37195
  }
37057
- const queryFn = (await import("./chunks/query-N22EYSZZ.js")).default;
37196
+ const queryFn = (await import("./chunks/query-HEATRYAK.js")).default;
37058
37197
  return queryFn(client, telemetry2);
37059
37198
  }
37060
37199
  }
@@ -42343,7 +42482,7 @@ async function redeploy(client) {
42343
42482
  printAlignedLabel(
42344
42483
  isProdDeployment ? "Production" : "Preview",
42345
42484
  import_chalk172.default.cyan(previewUrl),
42346
- isProdDeployment ? { gutter: "\u25B2" } : {}
42485
+ isProdDeployment && noWait ? { gutter: "\u25B2" } : {}
42347
42486
  );
42348
42487
  if (!client.stdout.isTTY) {
42349
42488
  client.stdout.write(`https://${deployment.url}`);
@@ -42361,6 +42500,12 @@ async function redeploy(client) {
42361
42500
  }
42362
42501
  if (deployment.readyState === "READY" && deployment.aliasAssigned && !rollingRelease2) {
42363
42502
  output_manager_default.spinner("Completing\u2026", 0);
42503
+ if (deployment.target === "production" && deployment.alias && deployment.alias.length > 0) {
42504
+ output_manager_default.stopSpinner();
42505
+ const primaryDomain = deployment.alias[0];
42506
+ const prodUrl = `https://${primaryDomain}`;
42507
+ printAlignedLabel("Aliased", import_chalk172.default.cyan(prodUrl), { gutter: "\u25B2" });
42508
+ }
42364
42509
  } else {
42365
42510
  try {
42366
42511
  const clientOptions = {
@@ -47949,7 +48094,7 @@ async function main27(client) {
47949
48094
  return 2;
47950
48095
  }
47951
48096
  telemetry2.trackCliSubcommandEdit(subcommandOriginal);
47952
- return (await import("./chunks/edit-DOL2ZJPG.js")).default(client, args);
48097
+ return (await import("./chunks/edit-TICKX4ZV.js")).default(client, args);
47953
48098
  case "delete":
47954
48099
  if (needHelp) {
47955
48100
  telemetry2.trackCliFlagHelp("routes", subcommandOriginal);
@@ -47957,7 +48102,7 @@ async function main27(client) {
47957
48102
  return 2;
47958
48103
  }
47959
48104
  telemetry2.trackCliSubcommandDelete(subcommandOriginal);
47960
- return (await import("./chunks/delete-6EMDCXSA.js")).default(client, args);
48105
+ return (await import("./chunks/delete-GFW6Y6TZ.js")).default(client, args);
47961
48106
  case "enable":
47962
48107
  if (needHelp) {
47963
48108
  telemetry2.trackCliFlagHelp("routes", subcommandOriginal);
@@ -47965,7 +48110,7 @@ async function main27(client) {
47965
48110
  return 2;
47966
48111
  }
47967
48112
  telemetry2.trackCliSubcommandEnable(subcommandOriginal);
47968
- return (await import("./chunks/enable-PZWZIETT.js")).default(client, args);
48113
+ return (await import("./chunks/enable-L3BYWN6S.js")).default(client, args);
47969
48114
  case "disable":
47970
48115
  if (needHelp) {
47971
48116
  telemetry2.trackCliFlagHelp("routes", subcommandOriginal);
@@ -47973,7 +48118,7 @@ async function main27(client) {
47973
48118
  return 2;
47974
48119
  }
47975
48120
  telemetry2.trackCliSubcommandDisable(subcommandOriginal);
47976
- return (await import("./chunks/disable-FLJ27NHG.js")).default(client, args);
48121
+ return (await import("./chunks/disable-PGRAS2ZL.js")).default(client, args);
47977
48122
  case "reorder":
47978
48123
  if (needHelp) {
47979
48124
  telemetry2.trackCliFlagHelp("routes", subcommandOriginal);
@@ -47981,7 +48126,7 @@ async function main27(client) {
47981
48126
  return 2;
47982
48127
  }
47983
48128
  telemetry2.trackCliSubcommandReorder(subcommandOriginal);
47984
- return (await import("./chunks/reorder-TG53BKW4.js")).default(client, args);
48129
+ return (await import("./chunks/reorder-IQVKSM3H.js")).default(client, args);
47985
48130
  case "export":
47986
48131
  if (needHelp) {
47987
48132
  telemetry2.trackCliFlagHelp("routes", subcommandOriginal);
@@ -47989,7 +48134,7 @@ async function main27(client) {
47989
48134
  return 2;
47990
48135
  }
47991
48136
  telemetry2.trackCliSubcommandExport(subcommandOriginal);
47992
- return (await import("./chunks/export-2PFHAELC.js")).default(client, args);
48137
+ return (await import("./chunks/export-NXS33U5T.js")).default(client, args);
47993
48138
  case "publish":
47994
48139
  if (needHelp) {
47995
48140
  telemetry2.trackCliFlagHelp("routes", subcommandOriginal);
@@ -47997,7 +48142,7 @@ async function main27(client) {
47997
48142
  return 2;
47998
48143
  }
47999
48144
  telemetry2.trackCliSubcommandPublish(subcommandOriginal);
48000
- return (await import("./chunks/publish-JV4J3SOA.js")).default(client, args);
48145
+ return (await import("./chunks/publish-CU2THVYW.js")).default(client, args);
48001
48146
  case "restore":
48002
48147
  if (needHelp) {
48003
48148
  telemetry2.trackCliFlagHelp("routes", subcommandOriginal);
@@ -48005,7 +48150,7 @@ async function main27(client) {
48005
48150
  return 2;
48006
48151
  }
48007
48152
  telemetry2.trackCliSubcommandRestore(subcommandOriginal);
48008
- return (await import("./chunks/restore-U7O4VESA.js")).default(client, args);
48153
+ return (await import("./chunks/restore-RDEOBGAS.js")).default(client, args);
48009
48154
  case "discard-staging":
48010
48155
  if (needHelp) {
48011
48156
  telemetry2.trackCliFlagHelp("routes", subcommandOriginal);
@@ -48013,7 +48158,7 @@ async function main27(client) {
48013
48158
  return 2;
48014
48159
  }
48015
48160
  telemetry2.trackCliSubcommandDiscardStaging(subcommandOriginal);
48016
- return (await import("./chunks/discard-KEIII6RM.js")).default(client, args);
48161
+ return (await import("./chunks/discard-S6N5Q4G5.js")).default(client, args);
48017
48162
  default:
48018
48163
  output_manager_default.error(getInvalidSubcommand(COMMAND_CONFIG36));
48019
48164
  output_manager_default.print(help(routesCommand, { columns: client.stderr.columns }));
@@ -51563,7 +51708,12 @@ async function get3(client, telemetry2) {
51563
51708
 
51564
51709
  // src/commands/traces/index.ts
51565
51710
  var COMMAND_CONFIG41 = {
51566
- get: getCommandAliases(getSubcommand2)
51711
+ get: getCommandAliases(getSubcommand2),
51712
+ create: getCommandAliases(createSubcommand5)
51713
+ };
51714
+ var SUBCOMMAND_METADATA = {
51715
+ [getSubcommand2.name]: getSubcommand2,
51716
+ [createSubcommand5.name]: createSubcommand5
51567
51717
  };
51568
51718
  async function traces(client) {
51569
51719
  const telemetry2 = new TracesTelemetryClient({
@@ -51587,15 +51737,19 @@ async function traces(client) {
51587
51737
  );
51588
51738
  if (parsedArgs.flags["--help"]) {
51589
51739
  telemetry2.trackCliFlagHelp("traces", subcommandOriginal);
51590
- const isGet = subcommand === getSubcommand2.name;
51740
+ const subMetadata = typeof subcommand === "string" ? SUBCOMMAND_METADATA[subcommand] : void 0;
51591
51741
  output_manager_default.print(
51592
- help(isGet ? getSubcommand2 : tracesCommand, {
51593
- parent: isGet ? tracesCommand : void 0,
51742
+ help(subMetadata ?? tracesCommand, {
51743
+ parent: subMetadata ? tracesCommand : void 0,
51594
51744
  columns: client.stderr.columns
51595
51745
  })
51596
51746
  );
51597
51747
  return 2;
51598
51748
  }
51749
+ if (subcommand === createSubcommand5.name) {
51750
+ const args = client.argv.slice(4);
51751
+ return runCurl(client, { forceTrace: true, args });
51752
+ }
51599
51753
  return get3(client, telemetry2);
51600
51754
  }
51601
51755
 
@@ -52786,7 +52940,7 @@ async function create5(client, argv) {
52786
52940
  }
52787
52941
  });
52788
52942
  let parsedArgs;
52789
- const flagsSpecification = getFlagsSpecification(createSubcommand5.options);
52943
+ const flagsSpecification = getFlagsSpecification(createSubcommand6.options);
52790
52944
  try {
52791
52945
  parsedArgs = parseArguments(argv, flagsSpecification);
52792
52946
  } catch (error) {
@@ -53298,7 +53452,7 @@ async function main30(client) {
53298
53452
  case "create":
53299
53453
  if (needHelp) {
53300
53454
  telemetry2.trackCliFlagHelp("webhooks", subcommandOriginal);
53301
- return printHelp(createSubcommand5);
53455
+ return printHelp(createSubcommand6);
53302
53456
  }
53303
53457
  telemetry2.trackCliSubcommandCreate(subcommandOriginal);
53304
53458
  return create5(client, args);