vercel 54.8.0 → 54.9.1

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 (51) hide show
  1. package/dist/chunks/{add-7PN3D2CB.js → add-DLK472F2.js} +5 -5
  2. package/dist/chunks/{chunk-TKYXKHYP.js → chunk-2WIR65ZA.js} +64 -5
  3. package/dist/chunks/{chunk-6MRFETFX.js → chunk-5DEFO6LE.js} +3 -3
  4. package/dist/chunks/{chunk-MZXIRI4R.js → chunk-5MNBLHCW.js} +1 -1
  5. package/dist/chunks/{chunk-BGOG7M2L.js → chunk-6TKGW3ER.js} +1 -1
  6. package/dist/chunks/{chunk-UVSQEC2H.js → chunk-7BNN27HP.js} +1 -1
  7. package/dist/chunks/{chunk-3UG4R5C6.js → chunk-BR7Z2MXT.js} +4 -4
  8. package/dist/chunks/{chunk-6GCPDK6C.js → chunk-BTHBAHZ7.js} +1 -1
  9. package/dist/chunks/{chunk-C2JLV23W.js → chunk-CSYB45VZ.js} +14 -4
  10. package/dist/chunks/{chunk-KFVMKDQD.js → chunk-H3M6DIPE.js} +307 -6
  11. package/dist/chunks/{chunk-QSUXC4XD.js → chunk-J5JWEUV2.js} +2 -2
  12. package/dist/chunks/{chunk-SX3T5LJW.js → chunk-KXIQF76V.js} +1 -1
  13. package/dist/chunks/{chunk-L6Q2EQPI.js → chunk-LJ5WXXG6.js} +2 -0
  14. package/dist/chunks/{chunk-MZ6WX76F.js → chunk-LZQB35VT.js} +2 -2
  15. package/dist/chunks/{chunk-ZBFZHPN5.js → chunk-NHT3AQHJ.js} +4 -4
  16. package/dist/chunks/{chunk-2VNVOF6Y.js → chunk-OZLTZQ6G.js} +2 -2
  17. package/dist/chunks/{chunk-A4NNTF2R.js → chunk-SZB6YXTE.js} +2 -2
  18. package/dist/chunks/{chunk-T5UBTKLR.js → chunk-TS7YAK5A.js} +1 -1
  19. package/dist/chunks/{chunk-BLBP6PJV.js → chunk-WA3URLW4.js} +1 -1
  20. package/dist/chunks/{chunk-I6N27CZY.js → chunk-WBGELPB3.js} +4 -4
  21. package/dist/chunks/{chunk-5MRKNVDF.js → chunk-ZOEYFRYV.js} +9 -6
  22. package/dist/chunks/{compile-vercel-config-ZRGV2HQF.js → compile-vercel-config-6DRMFWMC.js} +1 -1
  23. package/dist/chunks/{delete-62D6RPHR.js → delete-IJ6VXN3J.js} +3 -3
  24. package/dist/chunks/{disable-EUFCTMHU.js → disable-YD3NZSGK.js} +3 -3
  25. package/dist/chunks/{discard-UXWAYS5Y.js → discard-VFWKNLCW.js} +3 -3
  26. package/dist/chunks/{edit-K7S5CQEI.js → edit-3UMHPT2N.js} +4 -4
  27. package/dist/chunks/{enable-4C5ME3GT.js → enable-OM55GDFZ.js} +3 -3
  28. package/dist/chunks/{export-NPUHUUHH.js → export-LSEMLHHU.js} +3 -3
  29. package/dist/chunks/{inspect-ASCZ6G5V.js → inspect-ZMNYUC4I.js} +4 -4
  30. package/dist/chunks/{list-MY22OIPS.js → list-GIAM3YSQ.js} +2 -2
  31. package/dist/chunks/{list-G7DVTQFM.js → list-ZBRTOAFQ.js} +4 -4
  32. package/dist/chunks/{ls-C5IRWH53.js → ls-NDRKV5AX.js} +5 -5
  33. package/dist/chunks/{publish-645OGLRF.js → publish-T3LIYYM2.js} +3 -3
  34. package/dist/chunks/{query-T5BWXYMO.js → query-ZPH4RM2S.js} +2 -2
  35. package/dist/chunks/{reorder-OHRSG6FC.js → reorder-E53AAA3P.js} +3 -3
  36. package/dist/chunks/{restore-GZNFRZV5.js → restore-4HJU6B2V.js} +3 -3
  37. package/dist/chunks/{rm-4IHGJQWN.js → rm-ZOVPEOPT.js} +5 -5
  38. package/dist/chunks/{rule-inspect-E5WP4XX3.js → rule-inspect-UMFXT335.js} +5 -5
  39. package/dist/chunks/{rules-KFYHGFV7.js → rules-LUJB7CCT.js} +7 -7
  40. package/dist/chunks/{schema-DUVEFNFM.js → schema-VKBUX74S.js} +2 -2
  41. package/dist/chunks/{update-W4JIJ732.js → update-G6D7GNBJ.js} +5 -5
  42. package/dist/commands/build/index.js +22 -19
  43. package/dist/commands/deploy/index.js +11 -11
  44. package/dist/commands/dev/index.js +18 -11
  45. package/dist/commands/env/index.js +4 -4
  46. package/dist/commands/link/index.js +8 -8
  47. package/dist/commands/list/index.js +3 -3
  48. package/dist/commands-bulk.js +1270 -744
  49. package/dist/index.js +8 -8
  50. package/dist/version.mjs +1 -1
  51. package/package.json +21 -21
@@ -9,8 +9,8 @@ import {
9
9
  handleRulesApiError,
10
10
  parseRulesFlagsAndScope,
11
11
  rulesCollectionPath
12
- } from "./chunk-MZ6WX76F.js";
13
- import "./chunk-6MRFETFX.js";
12
+ } from "./chunk-LZQB35VT.js";
13
+ import "./chunk-5DEFO6LE.js";
14
14
  import "./chunk-5SYDEK2N.js";
15
15
  import {
16
16
  validateJsonOutput
@@ -20,9 +20,9 @@ import {
20
20
  } from "./chunk-NGRSQRSN.js";
21
21
  import {
22
22
  AGENT_REASON
23
- } from "./chunk-L6Q2EQPI.js";
24
- import "./chunk-BLBP6PJV.js";
25
- import "./chunk-KFVMKDQD.js";
23
+ } from "./chunk-LJ5WXXG6.js";
24
+ import "./chunk-WA3URLW4.js";
25
+ import "./chunk-H3M6DIPE.js";
26
26
  import "./chunk-DPXUXH7G.js";
27
27
  import {
28
28
  buildCommandWithGlobalFlags,
@@ -25,10 +25,10 @@ import {
25
25
  import {
26
26
  buildCommand,
27
27
  pullCommand
28
- } from "./chunk-UVSQEC2H.js";
28
+ } from "./chunk-7BNN27HP.js";
29
29
  import {
30
30
  envCommand
31
- } from "./chunk-KFVMKDQD.js";
31
+ } from "./chunk-H3M6DIPE.js";
32
32
  import {
33
33
  confirmOption,
34
34
  forceOption,
@@ -4742,6 +4742,48 @@ var createThresholdSubcommand = {
4742
4742
  }
4743
4743
  ]
4744
4744
  };
4745
+ var claimSubcommand = {
4746
+ name: "claim",
4747
+ aliases: [],
4748
+ description: "Claim a sandbox marketplace resource (e.g. Stripe, Shopify) by opening the provider claim URL in your browser",
4749
+ arguments: [
4750
+ {
4751
+ name: "resource",
4752
+ required: false
4753
+ }
4754
+ ],
4755
+ options: [
4756
+ {
4757
+ ...yesOption,
4758
+ description: "Skip the confirmation prompt when claiming a single sandbox resource"
4759
+ },
4760
+ {
4761
+ name: "no-wait",
4762
+ description: "Print the claim URL and exit without polling for completion",
4763
+ shorthand: null,
4764
+ type: Boolean,
4765
+ deprecated: false
4766
+ },
4767
+ formatOption
4768
+ ],
4769
+ examples: [
4770
+ {
4771
+ name: "Claim a sandbox resource by name",
4772
+ value: [
4773
+ `${packageName} integration-resource claim <resource>`,
4774
+ `${packageName} integration-resource claim my-stripe`
4775
+ ]
4776
+ },
4777
+ {
4778
+ name: "Pick a sandbox resource interactively (current team)",
4779
+ value: `${packageName} integration-resource claim`
4780
+ },
4781
+ {
4782
+ name: "Print the claim URL as JSON without waiting",
4783
+ value: `${packageName} integration-resource claim my-stripe --format=json --no-wait`
4784
+ }
4785
+ ]
4786
+ };
4745
4787
  var integrationResourceCommand = {
4746
4788
  name: "integration-resource",
4747
4789
  aliases: ["ir"],
@@ -4752,7 +4794,8 @@ var integrationResourceCommand = {
4752
4794
  connectSubcommand2,
4753
4795
  createThresholdSubcommand,
4754
4796
  disconnectSubcommand2,
4755
- removeSubcommand9
4797
+ removeSubcommand9,
4798
+ claimSubcommand
4756
4799
  ],
4757
4800
  examples: []
4758
4801
  };
@@ -4831,6 +4874,20 @@ var addSubcommand7 = {
4831
4874
  argument: "ID",
4832
4875
  description: "Installation ID to use when multiple installations exist for the integration"
4833
4876
  },
4877
+ {
4878
+ name: "claim",
4879
+ shorthand: null,
4880
+ type: Boolean,
4881
+ deprecated: false,
4882
+ description: "If the new resource is a sandbox (e.g. Stripe, Shopify), claim it immediately without prompting"
4883
+ },
4884
+ {
4885
+ name: "no-claim",
4886
+ shorthand: null,
4887
+ type: Boolean,
4888
+ deprecated: false,
4889
+ description: "If the new resource is a sandbox, skip the offer to claim it (only print a hint)"
4890
+ },
4834
4891
  formatOption
4835
4892
  ],
4836
4893
  examples: [
@@ -5272,14 +5329,15 @@ var guideSubcommand = {
5272
5329
  var resourceSubcommand = {
5273
5330
  name: "resource",
5274
5331
  aliases: [],
5275
- description: "Manage marketplace integration resources (connect, disconnect, remove, create-threshold)",
5332
+ description: "Manage marketplace integration resources (connect, disconnect, remove, create-threshold, claim)",
5276
5333
  options: [],
5277
5334
  arguments: [],
5278
5335
  subcommands: [
5279
5336
  connectSubcommand2,
5280
5337
  createThresholdSubcommand,
5281
5338
  disconnectSubcommand2,
5282
- removeSubcommand9
5339
+ removeSubcommand9,
5340
+ claimSubcommand
5283
5341
  ],
5284
5342
  examples: [
5285
5343
  {
@@ -8651,6 +8709,7 @@ export {
8651
8709
  disconnectSubcommand2,
8652
8710
  connectSubcommand2,
8653
8711
  createThresholdSubcommand,
8712
+ claimSubcommand,
8654
8713
  integrationResourceCommand,
8655
8714
  addSubcommand7 as addSubcommand6,
8656
8715
  acceptTermsSubcommand,
@@ -9,14 +9,14 @@ import {
9
9
  } from "./chunk-5SYDEK2N.js";
10
10
  import {
11
11
  AGENT_REASON
12
- } from "./chunk-L6Q2EQPI.js";
12
+ } from "./chunk-LJ5WXXG6.js";
13
13
  import {
14
14
  getScope
15
- } from "./chunk-BLBP6PJV.js";
15
+ } from "./chunk-WA3URLW4.js";
16
16
  import {
17
17
  getLinkedProject,
18
18
  getProjectByNameOrId
19
- } from "./chunk-KFVMKDQD.js";
19
+ } from "./chunk-H3M6DIPE.js";
20
20
  import {
21
21
  buildCommandWithGlobalFlags,
22
22
  outputAgentError
@@ -7,7 +7,7 @@ const __dirname = __dirname_(__filename);
7
7
  import {
8
8
  VERCEL_DIR,
9
9
  isVercelTomlEnabled
10
- } from "./chunk-KFVMKDQD.js";
10
+ } from "./chunk-H3M6DIPE.js";
11
11
  import {
12
12
  parseArguments
13
13
  } from "./chunk-6IQZVQV6.js";
@@ -6,7 +6,7 @@ const __filename = __fileURLToPath(import.meta.url);
6
6
  const __dirname = __dirname_(__filename);
7
7
  import {
8
8
  require_lib
9
- } from "./chunk-KFVMKDQD.js";
9
+ } from "./chunk-H3M6DIPE.js";
10
10
  import {
11
11
  packageName
12
12
  } from "./chunk-LN6B7ZI3.js";
@@ -6,7 +6,7 @@ const __filename = __fileURLToPath(import.meta.url);
6
6
  const __dirname = __dirname_(__filename);
7
7
  import {
8
8
  getEnvTargetPlaceholder
9
- } from "./chunk-KFVMKDQD.js";
9
+ } from "./chunk-H3M6DIPE.js";
10
10
  import {
11
11
  projectOption,
12
12
  yesOption
@@ -8,22 +8,22 @@ import {
8
8
  getUpdateCommand,
9
9
  isGlobal,
10
10
  isNativeBinaryInstall
11
- } from "./chunk-BGOG7M2L.js";
11
+ } from "./chunk-6TKGW3ER.js";
12
12
  import {
13
13
  getGlobalPathConfig,
14
14
  writeToConfigFile
15
- } from "./chunk-2VNVOF6Y.js";
15
+ } from "./chunk-OZLTZQ6G.js";
16
16
  import {
17
17
  apiCommand,
18
18
  listSubcommand2 as listSubcommand,
19
19
  loginCommand
20
- } from "./chunk-TKYXKHYP.js";
20
+ } from "./chunk-2WIR65ZA.js";
21
21
  import {
22
22
  help
23
23
  } from "./chunk-5ZJHY4AC.js";
24
24
  import {
25
25
  login
26
- } from "./chunk-KFVMKDQD.js";
26
+ } from "./chunk-H3M6DIPE.js";
27
27
  import {
28
28
  TelemetryClient
29
29
  } from "./chunk-DPXUXH7G.js";
@@ -7,7 +7,7 @@ const __dirname = __dirname_(__filename);
7
7
  import {
8
8
  formatCondition,
9
9
  formatTransform
10
- } from "./chunk-QSUXC4XD.js";
10
+ } from "./chunk-J5JWEUV2.js";
11
11
  import {
12
12
  output_manager_default
13
13
  } from "./chunk-Z5SBJH6L.js";
@@ -18,7 +18,7 @@ import {
18
18
  require_lib,
19
19
  require_minimatch,
20
20
  require_pluralize
21
- } from "./chunk-KFVMKDQD.js";
21
+ } from "./chunk-H3M6DIPE.js";
22
22
  import {
23
23
  CantParseJSONFile,
24
24
  cmd,
@@ -11897,6 +11897,15 @@ async function* findDirs(name, dir, root = dir) {
11897
11897
  }
11898
11898
  }
11899
11899
  }
11900
+ function stripParentSegments(path2) {
11901
+ const normalized = normalizePath(path2);
11902
+ const segments = normalized.split("/");
11903
+ let i = 0;
11904
+ while (i < segments.length && segments[i] === "..") {
11905
+ i++;
11906
+ }
11907
+ return segments.slice(i).join("/");
11908
+ }
11900
11909
  function filesWithoutFsRefs(files, repoRootPath, sharedDest, standalone) {
11901
11910
  let filePathMap;
11902
11911
  const out = {};
@@ -11909,9 +11918,10 @@ function filesWithoutFsRefs(files, repoRootPath, sharedDest, standalone) {
11909
11918
  if (isExternalSymlink(file)) {
11910
11919
  continue;
11911
11920
  }
11912
- shared[path2] = file;
11913
- filePathMap[normalizePath(path2)] = normalizePath(
11914
- relative2(repoRootPath, join4(sharedDest, path2))
11921
+ const funcPath = stripParentSegments(path2);
11922
+ shared[funcPath] = file;
11923
+ filePathMap[funcPath] = normalizePath(
11924
+ relative2(repoRootPath, join4(sharedDest, funcPath))
11915
11925
  );
11916
11926
  } else {
11917
11927
  filePathMap[normalizePath(path2)] = normalizePath(
@@ -23125,8 +23125,13 @@ var require_resolve2 = __commonJS({
23125
23125
  var __toCommonJS2 = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
23126
23126
  var resolve_exports = {};
23127
23127
  __export2(resolve_exports, {
23128
+ detectFrameworkFromWorkspace: () => detectFrameworkFromWorkspace,
23129
+ getServiceFs: () => getServiceFs,
23130
+ inferWorkspaceFromNearestManifest: () => inferWorkspaceFromNearestManifest,
23131
+ parsePyModuleAttrEntrypoint: () => parsePyModuleAttrEntrypoint,
23128
23132
  resolveAllConfiguredServices: () => resolveAllConfiguredServices,
23129
23133
  resolveConfiguredService: () => resolveConfiguredService,
23134
+ resolveEntrypointPath: () => resolveEntrypointPath,
23130
23135
  validateServiceConfig: () => validateServiceConfig,
23131
23136
  validateServiceEntrypoint: () => validateServiceEntrypoint
23132
23137
  });
@@ -23773,6 +23778,7 @@ var require_resolve2 = __commonJS({
23773
23778
  builderConfig.handlerFunction = moduleAttrParsed.attrName;
23774
23779
  }
23775
23780
  return {
23781
+ schema: "experimentalServices",
23776
23782
  name,
23777
23783
  type,
23778
23784
  trigger,
@@ -23978,6 +23984,270 @@ var require_resolve2 = __commonJS({
23978
23984
  }
23979
23985
  });
23980
23986
 
23987
+ // ../fs-detectors/dist/services/resolve-v2.js
23988
+ var require_resolve_v2 = __commonJS({
23989
+ "../fs-detectors/dist/services/resolve-v2.js"(exports, module) {
23990
+ "use strict";
23991
+ var __defProp = Object.defineProperty;
23992
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
23993
+ var __getOwnPropNames = Object.getOwnPropertyNames;
23994
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
23995
+ var __export2 = (target, all) => {
23996
+ for (var name in all)
23997
+ __defProp(target, name, { get: all[name], enumerable: true });
23998
+ };
23999
+ var __copyProps = (to, from, except, desc) => {
24000
+ if (from && typeof from === "object" || typeof from === "function") {
24001
+ for (let key of __getOwnPropNames(from))
24002
+ if (!__hasOwnProp.call(to, key) && key !== except)
24003
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
24004
+ }
24005
+ return to;
24006
+ };
24007
+ var __toCommonJS2 = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
24008
+ var resolve_v2_exports = {};
24009
+ __export2(resolve_v2_exports, {
24010
+ resolveAllConfiguredServicesV2: () => resolveAllConfiguredServicesV22,
24011
+ resolveConfiguredServiceV2: () => resolveConfiguredServiceV22,
24012
+ validateServiceConfigV2: () => validateServiceConfigV22
24013
+ });
24014
+ module.exports = __toCommonJS2(resolve_v2_exports);
24015
+ var import_path12 = __require("path");
24016
+ var import_build_utils6 = __require("@vercel/build-utils");
24017
+ var import_frameworks2 = require_frameworks();
24018
+ var import_types = require_types3();
24019
+ var import_resolve = require_resolve2();
24020
+ var import_utils4 = require_utils3();
24021
+ var frameworksBySlug = new Map(import_frameworks2.frameworkList.map((f) => [f.slug, f]));
24022
+ var SERVICE_NAME_REGEX = /^[a-zA-Z]([a-zA-Z0-9_-]*[a-zA-Z0-9])?$/;
24023
+ function validateServiceConfigV22(name, config) {
24024
+ if (!SERVICE_NAME_REGEX.test(name)) {
24025
+ return {
24026
+ code: "INVALID_SERVICE_NAME",
24027
+ message: `Service name "${name}" is invalid. Names must start with a letter, end with an alphanumeric character, and contain only alphanumeric characters, hyphens, and underscores.`,
24028
+ serviceName: name
24029
+ };
24030
+ }
24031
+ if (!config || typeof config !== "object") {
24032
+ return {
24033
+ code: "INVALID_SERVICE_CONFIG",
24034
+ message: `Service "${name}" has an invalid configuration. Expected an object.`,
24035
+ serviceName: name
24036
+ };
24037
+ }
24038
+ if (typeof config.root !== "string" || config.root.length === 0) {
24039
+ return {
24040
+ code: "MISSING_ROOT",
24041
+ message: `Service "${name}" must specify a "root".`,
24042
+ serviceName: name
24043
+ };
24044
+ }
24045
+ const normalizedRoot = import_path12.posix.normalize(config.root);
24046
+ if (normalizedRoot.startsWith("/")) {
24047
+ return {
24048
+ code: "INVALID_ROOT",
24049
+ message: `Service "${name}" has invalid "root" "${config.root}". Must be a relative path.`,
24050
+ serviceName: name
24051
+ };
24052
+ }
24053
+ if (normalizedRoot === ".." || normalizedRoot.startsWith("../")) {
24054
+ return {
24055
+ code: "INVALID_ROOT",
24056
+ message: `Service "${name}" has invalid "root" "${config.root}". Must not escape the project root.`,
24057
+ serviceName: name
24058
+ };
24059
+ }
24060
+ if (config.runtime && !(config.runtime in import_types.RUNTIME_BUILDERS)) {
24061
+ return {
24062
+ code: "INVALID_RUNTIME",
24063
+ message: `Service "${name}" has invalid runtime "${config.runtime}".`,
24064
+ serviceName: name
24065
+ };
24066
+ }
24067
+ if (config.framework && !frameworksBySlug.has(config.framework)) {
24068
+ return {
24069
+ code: "INVALID_FRAMEWORK",
24070
+ message: `Service "${name}" has invalid framework "${config.framework}".`,
24071
+ serviceName: name
24072
+ };
24073
+ }
24074
+ if (config.runtime && config.framework) {
24075
+ const frameworkRuntime = (0, import_utils4.inferRuntimeFromFramework)(config.framework);
24076
+ if (frameworkRuntime && frameworkRuntime !== config.runtime) {
24077
+ return {
24078
+ code: "RUNTIME_FRAMEWORK_MISMATCH",
24079
+ message: `Service "${name}" has conflicting runtime/framework: runtime "${config.runtime}" is incompatible with framework "${config.framework}" (runtime "${frameworkRuntime}").`,
24080
+ serviceName: name
24081
+ };
24082
+ }
24083
+ }
24084
+ if (!config.framework && !config.entrypoint) {
24085
+ return {
24086
+ code: "MISSING_SERVICE_CONFIG",
24087
+ message: `Service "${name}" must specify "framework" or "entrypoint".`,
24088
+ serviceName: name
24089
+ };
24090
+ }
24091
+ return null;
24092
+ }
24093
+ async function resolveConfiguredServiceV22(name, config, fs5) {
24094
+ const root = config.root;
24095
+ const normalizedRoot = import_path12.posix.normalize(root);
24096
+ const serviceFsResult = normalizedRoot === "." ? { fs: fs5 } : await (0, import_resolve.getServiceFs)(fs5, name, root);
24097
+ if (serviceFsResult.error) {
24098
+ return { error: serviceFsResult.error };
24099
+ }
24100
+ const serviceFs = serviceFsResult.fs;
24101
+ const rawEntrypoint = config.entrypoint;
24102
+ const moduleAttr = typeof rawEntrypoint === "string" ? (0, import_resolve.parsePyModuleAttrEntrypoint)(rawEntrypoint) : null;
24103
+ let normalizedEntrypoint;
24104
+ let entrypointIsDirectory = false;
24105
+ if (typeof rawEntrypoint === "string") {
24106
+ const entrypointToResolve = moduleAttr ? moduleAttr.filePath : rawEntrypoint;
24107
+ const resolved = await (0, import_resolve.resolveEntrypointPath)({
24108
+ fs: serviceFs,
24109
+ serviceName: name,
24110
+ entrypoint: entrypointToResolve
24111
+ });
24112
+ if (resolved.error) {
24113
+ return { error: resolved.error };
24114
+ }
24115
+ normalizedEntrypoint = resolved.entrypoint?.normalized;
24116
+ entrypointIsDirectory = Boolean(resolved.entrypoint?.isDirectory);
24117
+ }
24118
+ const entrypointFile = entrypointIsDirectory || !normalizedEntrypoint ? void 0 : normalizedEntrypoint;
24119
+ const inferredRuntime = (0, import_utils4.inferServiceRuntime)({
24120
+ runtime: config.runtime,
24121
+ framework: config.framework,
24122
+ entrypoint: entrypointFile
24123
+ });
24124
+ let framework = config.framework;
24125
+ if (!framework && normalizedEntrypoint) {
24126
+ const workspace = entrypointIsDirectory ? normalizedEntrypoint : import_path12.posix.dirname(normalizedEntrypoint) || ".";
24127
+ const detection = await (0, import_resolve.detectFrameworkFromWorkspace)({
24128
+ fs: serviceFs,
24129
+ workspace,
24130
+ serviceName: name,
24131
+ runtime: inferredRuntime
24132
+ });
24133
+ if (detection.error) {
24134
+ return { error: detection.error };
24135
+ }
24136
+ framework = detection.framework;
24137
+ }
24138
+ if (entrypointIsDirectory && !framework) {
24139
+ return {
24140
+ error: {
24141
+ code: "MISSING_SERVICE_FRAMEWORK",
24142
+ message: `Service "${name}" uses directory entrypoint "${config.entrypoint}" but no framework could be detected. Specify "framework" explicitly or use a file entrypoint.`,
24143
+ serviceName: name
24144
+ }
24145
+ };
24146
+ }
24147
+ const frameworkDefinition = framework ? frameworksBySlug.get(framework) : void 0;
24148
+ let builderUse;
24149
+ let builderSrc;
24150
+ if (framework) {
24151
+ builderUse = (0, import_build_utils6.isNodeBackendFramework)(framework) ? "@vercel/backends" : frameworkDefinition?.useRuntime?.use || "@vercel/static-build";
24152
+ builderSrc = entrypointFile || frameworkDefinition?.useRuntime?.src || "package.json";
24153
+ } else {
24154
+ if (!inferredRuntime) {
24155
+ return {
24156
+ error: {
24157
+ code: "MISSING_SERVICE_CONFIG",
24158
+ message: `Service "${name}" must specify "framework" or a runtime-resolvable "entrypoint".`,
24159
+ serviceName: name
24160
+ }
24161
+ };
24162
+ }
24163
+ builderUse = inferredRuntime === "node" ? "@vercel/backends" : (0, import_utils4.getBuilderForRuntime)(inferredRuntime);
24164
+ builderSrc = entrypointFile;
24165
+ }
24166
+ const isRoot = normalizedRoot === ".";
24167
+ const projectRelativeSrc = isRoot ? builderSrc : import_path12.posix.join(normalizedRoot, builderSrc);
24168
+ const builderConfig = { zeroConfig: true };
24169
+ if (builderUse === "@vercel/backends") {
24170
+ builderConfig.serviceName = name;
24171
+ }
24172
+ if (framework) {
24173
+ builderConfig.framework = framework;
24174
+ }
24175
+ if (!isRoot) {
24176
+ builderConfig.workspace = normalizedRoot;
24177
+ }
24178
+ if (moduleAttr) {
24179
+ builderConfig.handlerFunction = moduleAttr.attrName;
24180
+ }
24181
+ const runtime = import_types.STATIC_BUILDERS.has(builderUse) ? void 0 : inferredRuntime;
24182
+ return {
24183
+ service: {
24184
+ schema: "experimentalServicesV2",
24185
+ name,
24186
+ root,
24187
+ framework,
24188
+ runtime,
24189
+ entrypoint: entrypointFile,
24190
+ builder: {
24191
+ src: projectRelativeSrc,
24192
+ use: builderUse,
24193
+ config: builderConfig
24194
+ },
24195
+ installCommand: config.installCommand,
24196
+ buildCommand: config.buildCommand,
24197
+ devCommand: config.devCommand,
24198
+ ignoreCommand: config.ignoreCommand,
24199
+ outputDirectory: config.outputDirectory,
24200
+ bindings: config.bindings,
24201
+ functions: config.functions,
24202
+ headers: config.headers,
24203
+ redirects: config.redirects,
24204
+ rewrites: config.rewrites,
24205
+ routes: config.routes,
24206
+ cleanUrls: config.cleanUrls,
24207
+ trailingSlash: config.trailingSlash
24208
+ }
24209
+ };
24210
+ }
24211
+ async function resolveAllConfiguredServicesV22(services, fs5) {
24212
+ const resolved = [];
24213
+ const errors = [];
24214
+ for (const name of Object.keys(services)) {
24215
+ const config = services[name];
24216
+ const validationError = validateServiceConfigV22(name, config);
24217
+ if (validationError) {
24218
+ errors.push(validationError);
24219
+ continue;
24220
+ }
24221
+ const { service, error } = await resolveConfiguredServiceV22(
24222
+ name,
24223
+ config,
24224
+ fs5
24225
+ );
24226
+ if (error) {
24227
+ errors.push(error);
24228
+ continue;
24229
+ }
24230
+ if (service) {
24231
+ resolved.push(service);
24232
+ }
24233
+ }
24234
+ const serviceNames = new Set(Object.keys(services));
24235
+ for (const service of resolved) {
24236
+ for (const binding of service.bindings ?? []) {
24237
+ if (!serviceNames.has(binding.service)) {
24238
+ errors.push({
24239
+ code: "UNKNOWN_SERVICE_BINDING",
24240
+ message: `Service "${service.name}" declares a binding to unknown service "${binding.service}".`,
24241
+ serviceName: service.name
24242
+ });
24243
+ }
24244
+ }
24245
+ }
24246
+ return { services: resolved, errors };
24247
+ }
24248
+ }
24249
+ });
24250
+
23981
24251
  // ../fs-detectors/dist/services/auto-detect.js
23982
24252
  var require_auto_detect = __commonJS({
23983
24253
  "../fs-detectors/dist/services/auto-detect.js"(exports, module) {
@@ -27869,6 +28139,7 @@ var require_detect_services = __commonJS({
27869
28139
  var import_routing_utils2 = require_dist5();
27870
28140
  var import_utils4 = require_utils3();
27871
28141
  var import_resolve = require_resolve2();
28142
+ var import_resolve_v2 = require_resolve_v2();
27872
28143
  var import_auto_detect = require_auto_detect();
27873
28144
  var import_detect_railway = require_detect_railway();
27874
28145
  var import_detect_render = require_detect_render();
@@ -27933,7 +28204,8 @@ var require_detect_services = __commonJS({
27933
28204
  fs: fs5,
27934
28205
  workPath,
27935
28206
  detectEntrypoint,
27936
- configuredServices: providedConfiguredServices
28207
+ configuredServices: providedConfiguredServices,
28208
+ configuredServicesType
27937
28209
  } = options;
27938
28210
  const scopedFs = workPath ? fs5.chdir(workPath) : fs5;
27939
28211
  const { config: vercelConfig, error: configError } = await (0, import_utils4.readVercelConfig)(scopedFs);
@@ -27948,6 +28220,23 @@ var require_detect_services = __commonJS({
27948
28220
  });
27949
28221
  }
27950
28222
  const hasProvidedConfiguredServices = providedConfiguredServices && Object.keys(providedConfiguredServices).length > 0;
28223
+ const experimentalServicesV2 = hasProvidedConfiguredServices && configuredServicesType === "experimentalServicesV2" ? providedConfiguredServices : hasProvidedConfiguredServices ? void 0 : vercelConfig?.experimentalServicesV2;
28224
+ if (experimentalServicesV2 && Object.keys(experimentalServicesV2).length > 0) {
28225
+ const result2 = await (0, import_resolve_v2.resolveAllConfiguredServicesV2)(
28226
+ experimentalServicesV2,
28227
+ scopedFs
28228
+ );
28229
+ return withResolvedResult({
28230
+ services: result2.services,
28231
+ source: "configured",
28232
+ // V2 uses explicit `bindings`, so no implicit `{NAME}_URL` injection.
28233
+ useImplicitEnvInjection: false,
28234
+ // V2 routes are explicitly carried per-service to output them separately.
28235
+ routes: emptyRoutes(),
28236
+ errors: result2.errors,
28237
+ warnings: []
28238
+ });
28239
+ }
27951
28240
  const configuredServices = hasProvidedConfiguredServices ? providedConfiguredServices : vercelConfig?.experimentalServices;
27952
28241
  const hasConfiguredServices = configuredServices && Object.keys(configuredServices).length > 0;
27953
28242
  if (!hasConfiguredServices) {
@@ -28053,7 +28342,8 @@ var require_detect_services = __commonJS({
28053
28342
  inferred
28054
28343
  );
28055
28344
  }
28056
- function generateServicesRoutes2(services) {
28345
+ function generateServicesRoutes2(allServices) {
28346
+ const services = allServices.filter(import_build_utils6.isExperimentalService);
28057
28347
  const hostRewrites = [];
28058
28348
  const rewrites = [];
28059
28349
  const defaults = [];
@@ -28610,10 +28900,14 @@ var require_detect_builders = __commonJS({
28610
28900
  return publicBuilder ? publicBuilder.src.replace("/**/*", "") : null;
28611
28901
  }
28612
28902
  async function detectBuilders2(files, pkg, options = {}) {
28613
- const { experimentalServices, projectSettings = {} } = options;
28903
+ const {
28904
+ experimentalServices,
28905
+ experimentalServicesV2,
28906
+ projectSettings = {}
28907
+ } = options;
28614
28908
  const { framework } = projectSettings;
28615
- const configuredServices = experimentalServices;
28616
- const configuredServicesType = "experimentalServices";
28909
+ const configuredServices = experimentalServices ?? experimentalServicesV2;
28910
+ const configuredServicesType = experimentalServices ? "experimentalServices" : "experimentalServicesV2";
28617
28911
  const hasServicesConfig = configuredServices != null && typeof configuredServices === "object";
28618
28912
  if (hasServicesConfig || framework === "services") {
28619
28913
  return (0, import_get_services_builders.getServicesBuilders)({
@@ -33865,17 +34159,24 @@ var require_dist6 = __commonJS({
33865
34159
  getServicesBuilders: () => import_get_services_builders.getServicesBuilders,
33866
34160
  getWorkspacePackagePaths: () => import_get_workspace_package_paths.getWorkspacePackagePaths,
33867
34161
  getWorkspaces: () => import_get_workspaces.getWorkspaces,
34162
+ isExperimentalService: () => import_build_utils6.isExperimentalService,
34163
+ isExperimentalServiceV2: () => import_build_utils6.isExperimentalServiceV2,
33868
34164
  isOfficialRuntime: () => import_is_official_runtime.isOfficialRuntime,
33869
34165
  isRouteOwningBuilder: () => import_utils4.isRouteOwningBuilder,
33870
34166
  isStaticBuild: () => import_utils4.isStaticBuild,
33871
34167
  isStaticRuntime: () => import_is_official_runtime.isStaticRuntime,
33872
34168
  monorepoManagers: () => import_monorepo_managers.monorepoManagers,
33873
34169
  packageManagers: () => import_package_managers.packageManagers,
34170
+ resolveAllConfiguredServicesV2: () => import_resolve_v2.resolveAllConfiguredServicesV2,
34171
+ resolveConfiguredServiceV2: () => import_resolve_v2.resolveConfiguredServiceV2,
34172
+ validateServiceConfigV2: () => import_resolve_v2.validateServiceConfigV2,
33874
34173
  workspaceManagers: () => import_workspace_managers.workspaceManagers
33875
34174
  });
33876
34175
  module.exports = __toCommonJS2(src_exports);
33877
34176
  var import_detect_builders = require_detect_builders();
33878
34177
  var import_detect_services2 = require_detect_services();
34178
+ var import_resolve_v2 = require_resolve_v2();
34179
+ var import_build_utils6 = __require("@vercel/build-utils");
33879
34180
  var import_auto_detect = require_auto_detect();
33880
34181
  var import_utils4 = require_utils3();
33881
34182
  var import_get_services_builders = require_get_services_builders();
@@ -36920,7 +37221,7 @@ var require_package = __commonJS({
36920
37221
  "../client/package.json"(exports, module) {
36921
37222
  module.exports = {
36922
37223
  name: "@vercel/client",
36923
- version: "17.5.8",
37224
+ version: "17.5.10",
36924
37225
  main: "dist/index.js",
36925
37226
  typings: "dist/index.d.ts",
36926
37227
  homepage: "https://vercel.com",
@@ -7,10 +7,10 @@ const __dirname = __dirname_(__filename);
7
7
  import {
8
8
  AGENT_REASON,
9
9
  AGENT_STATUS
10
- } from "./chunk-L6Q2EQPI.js";
10
+ } from "./chunk-LJ5WXXG6.js";
11
11
  import {
12
12
  getLinkedProject
13
- } from "./chunk-KFVMKDQD.js";
13
+ } from "./chunk-H3M6DIPE.js";
14
14
  import {
15
15
  buildCommandWithYes,
16
16
  outputAgentError