[Parity] Edge Config CLI (vercel edge-config)#15822
Conversation
- Add edge-config list, add, get, update, remove, items, tokens subcommands - Wire /v1/edge-config APIs with team scope and slug-or-id resolution - Extend exitWithNonInteractiveError with edge-config variant (404 -> not_found) - Add unit tests and changeset Made-with: Cursor
🦋 Changeset detectedLatest commit: 34a2182 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
|
Low Risk — New CLI command feature with CRUD operations, telemetry, and tests — no auth/schema/billing changes.
Assessed at 34a2182. |
Resolve agent-output: keep edge-config next steps and hints; extend ExitWithNonInteractiveErrorVariant with access-summary and web-analytics. Made-with: Cursor
🧪 Unit Test StrategyComparing: Strategy: Affected packages only ✅ Only testing packages that have been modified or depend on modified packages. Affected packages - 1 (3%)
Unaffected packages - 39 (98%)
Results
This comment is automatically generated based on the affected testing strategy |
- Extract parse-patch-body and normalize \r\n, \n, \t before JSON.parse - Document required operation field in --patch help text Made-with: Cursor
Resolve agent-output: keep edge-config + ProjectExitWithNonInteractiveVariant; add speed-insights to ExitWithNonInteractiveErrorVariant (main). Made-with: Cursor
Made-with: Cursor
…--help snapshot - Add edge-config to expected commands map in index.test.ts - Use stderr getFullOutput() instead of read() for dev --help snapshot so the captured output matches across platforms (read() can differ on Linux CI) Made-with: Cursor
📦 CLI Tarball ReadyThe Vercel CLI tarball for this PR is now available! Quick TestYou can test this PR's CLI directly by running: npx https://vercel-d8ms2jue4.vercel.sh/tarballs/vercel.tgz --helpUse in vercel.jsonTo use this CLI version in your project builds, add to your {
"build": {
"env": {
"VERCEL_CLI_VERSION": "vercel@https://vercel-d8ms2jue4.vercel.sh/tarballs/vercel.tgz"
}
}
}Python Runtime WheelA Python Workers WheelA |
parsePatchBody now runs before any API calls so invalid --patch cannot leave the store renamed after a failed validation. Adds a unit test that asserts PUT is not called when patch validation fails. Made-with: Cursor
## Summary
Adds `vercel edge-config` with dashboard API parity for Edge Config
stores (team scope):
- **list** (`ls`) — `GET /v1/edge-config`
- **add** (`create`) — `POST /v1/edge-config` (optional `--items` JSON
object)
- **get** (`inspect`) — `GET /v1/edge-config/:id` (accepts `ecfg_…` id
or slug)
- **update** — `PUT` slug rename and/or `PATCH` items via `--patch`
(JSON array or `{ "items": [...] }`)
- **remove** (`rm`, `delete`) — `DELETE /v1/edge-config/:id`
(confirmation / `--yes`)
- **items** — `GET` all items or one via `--key`
- **tokens** — list `GET`, create `POST` (`--add <label>`), revoke
`DELETE` (`--remove`, repeatable; `--yes` in non-interactive)
## Non-interactive / agents
- `exitWithNonInteractiveError` supports variant `edge-config`: API
**404** maps to `not_found` (not `project_not_found`), with `next[]`
pointing at `edge-config list`, `teams switch`, `whoami`.
## Testing
- `pnpm exec vitest run
test/unit/commands/edge-config/edge-config.test.ts` (from
`packages/cli`)
## Changeset
- Minor bump for `vercel` CLI package (`.changeset/cli-edge-config.md`).
Closes / tracks parity issue: **Edge Config CLI** (attach to your
internal parity issue as needed).
Made with [Cursor](https://cursor.com)
This PR was opened by the [Changesets release](https://github.com/changesets/action) GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated. # Releases ## @vercel/build-utils@13.13.0 ### Minor Changes - Extend `finalizeLambda` with pluggable ZIP strategy (`createZip`), pre-digest validation hook (`validateZip`), and optional trace tags. Widen `getLambdaEnvironment` buffer param to `{ byteLength: number }`. ([#15856](#15856)) ## vercel@50.41.0 ### Minor Changes - Add `vercel edge-config` with `list`, `add`, `get`, `update`, `remove`, `items`, and `tokens` subcommands for Edge Config dashboard API parity. ([#15822](#15822)) - Add `vercel project checks` to list a project's deployment checks configuration (parity with dashboard), including `--format json` and non-interactive error payloads. ([#15816](#15816)) ### Patch Changes - Improve `vercel teams request` in non-interactive mode: validation, missing team scope, and API errors emit structured JSON on stdout with stable `reason` values and `next[]` commands that preserve global flags (for example `--cwd` and `--non-interactive`). ([#15815](#15815)) - Hide `--search` flag from `vc logs --help` output while continuing to accept it, and update the `--query` flag description to indicate advanced querying with filter syntax support. ([#15854](#15854)) - Updated dependencies \[[`a80217a9ed60d7b7f3e98537b0468cc5488078c1`](a80217a)]: - @vercel/build-utils@13.13.0 - @vercel/backends@0.0.56 - @vercel/elysia@0.1.59 - @vercel/express@0.1.69 - @vercel/fastify@0.1.62 - @vercel/go@3.4.7 - @vercel/h3@0.1.68 - @vercel/hono@0.2.62 - @vercel/hydrogen@1.3.6 - @vercel/koa@0.1.42 - @vercel/nestjs@0.2.63 - @vercel/next@4.16.5 - @vercel/node@5.7.1 - @vercel/python@6.29.0 - @vercel/redwood@2.4.12 - @vercel/remix-builder@5.7.2 - @vercel/ruby@2.3.2 - @vercel/rust@1.0.6 - @vercel/static-build@2.9.9 ## @vercel/backends@0.0.56 ### Patch Changes - Updated dependencies \[[`a80217a9ed60d7b7f3e98537b0468cc5488078c1`](a80217a)]: - @vercel/build-utils@13.13.0 ## @vercel/cervel@0.0.43 ### Patch Changes - Updated dependencies \[]: - @vercel/backends@0.0.56 ## @vercel/client@17.2.68 ### Patch Changes - Updated dependencies \[[`a80217a9ed60d7b7f3e98537b0468cc5488078c1`](a80217a)]: - @vercel/build-utils@13.13.0 ## @vercel/elysia@0.1.59 ### Patch Changes - Updated dependencies \[]: - @vercel/node@5.7.1 ## @vercel/express@0.1.69 ### Patch Changes - Updated dependencies \[]: - @vercel/node@5.7.1 - @vercel/cervel@0.0.43 ## @vercel/fastify@0.1.62 ### Patch Changes - Updated dependencies \[]: - @vercel/node@5.7.1 ## @vercel/fs-detectors@5.14.3 ### Patch Changes - Updated dependencies \[[`a80217a9ed60d7b7f3e98537b0468cc5488078c1`](a80217a)]: - @vercel/build-utils@13.13.0 ## @vercel/gatsby-plugin-vercel-builder@2.1.9 ### Patch Changes - Updated dependencies \[[`a80217a9ed60d7b7f3e98537b0468cc5488078c1`](a80217a)]: - @vercel/build-utils@13.13.0 ## @vercel/h3@0.1.68 ### Patch Changes - Updated dependencies \[]: - @vercel/node@5.7.1 ## @vercel/hono@0.2.62 ### Patch Changes - Updated dependencies \[]: - @vercel/node@5.7.1 ## @vercel/koa@0.1.42 ### Patch Changes - Updated dependencies \[]: - @vercel/node@5.7.1 ## @vercel/nestjs@0.2.63 ### Patch Changes - Updated dependencies \[]: - @vercel/node@5.7.1 ## @vercel/node@5.7.1 ### Patch Changes - Updated dependencies \[[`a80217a9ed60d7b7f3e98537b0468cc5488078c1`](a80217a)]: - @vercel/build-utils@13.13.0 ## @vercel/static-build@2.9.9 ### Patch Changes - Updated dependencies \[]: - @vercel/gatsby-plugin-vercel-builder@2.1.9 Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
This PR was opened by the [Changesets release](https://github.com/changesets/action) GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated. # Releases ## @vercel/build-utils@13.13.0 ### Minor Changes - Extend `finalizeLambda` with pluggable ZIP strategy (`createZip`), pre-digest validation hook (`validateZip`), and optional trace tags. Widen `getLambdaEnvironment` buffer param to `{ byteLength: number }`. ([#15856](#15856)) ## vercel@50.41.0 ### Minor Changes - Add `vercel edge-config` with `list`, `add`, `get`, `update`, `remove`, `items`, and `tokens` subcommands for Edge Config dashboard API parity. ([#15822](#15822)) - Add `vercel project checks` to list a project's deployment checks configuration (parity with dashboard), including `--format json` and non-interactive error payloads. ([#15816](#15816)) ### Patch Changes - Improve `vercel teams request` in non-interactive mode: validation, missing team scope, and API errors emit structured JSON on stdout with stable `reason` values and `next[]` commands that preserve global flags (for example `--cwd` and `--non-interactive`). ([#15815](#15815)) - Hide `--search` flag from `vc logs --help` output while continuing to accept it, and update the `--query` flag description to indicate advanced querying with filter syntax support. ([#15854](#15854)) - Updated dependencies \[[`a80217a9ed60d7b7f3e98537b0468cc5488078c1`](a80217a)]: - @vercel/build-utils@13.13.0 - @vercel/backends@0.0.56 - @vercel/elysia@0.1.59 - @vercel/express@0.1.69 - @vercel/fastify@0.1.62 - @vercel/go@3.4.7 - @vercel/h3@0.1.68 - @vercel/hono@0.2.62 - @vercel/hydrogen@1.3.6 - @vercel/koa@0.1.42 - @vercel/nestjs@0.2.63 - @vercel/next@4.16.5 - @vercel/node@5.7.1 - @vercel/python@6.29.0 - @vercel/redwood@2.4.12 - @vercel/remix-builder@5.7.2 - @vercel/ruby@2.3.2 - @vercel/rust@1.0.6 - @vercel/static-build@2.9.9 ## @vercel/backends@0.0.56 ### Patch Changes - Updated dependencies \[[`a80217a9ed60d7b7f3e98537b0468cc5488078c1`](a80217a)]: - @vercel/build-utils@13.13.0 ## @vercel/cervel@0.0.43 ### Patch Changes - Updated dependencies \[]: - @vercel/backends@0.0.56 ## @vercel/client@17.2.68 ### Patch Changes - Updated dependencies \[[`a80217a9ed60d7b7f3e98537b0468cc5488078c1`](a80217a)]: - @vercel/build-utils@13.13.0 ## @vercel/elysia@0.1.59 ### Patch Changes - Updated dependencies \[]: - @vercel/node@5.7.1 ## @vercel/express@0.1.69 ### Patch Changes - Updated dependencies \[]: - @vercel/node@5.7.1 - @vercel/cervel@0.0.43 ## @vercel/fastify@0.1.62 ### Patch Changes - Updated dependencies \[]: - @vercel/node@5.7.1 ## @vercel/fs-detectors@5.14.3 ### Patch Changes - Updated dependencies \[[`a80217a9ed60d7b7f3e98537b0468cc5488078c1`](a80217a)]: - @vercel/build-utils@13.13.0 ## @vercel/gatsby-plugin-vercel-builder@2.1.9 ### Patch Changes - Updated dependencies \[[`a80217a9ed60d7b7f3e98537b0468cc5488078c1`](a80217a)]: - @vercel/build-utils@13.13.0 ## @vercel/h3@0.1.68 ### Patch Changes - Updated dependencies \[]: - @vercel/node@5.7.1 ## @vercel/hono@0.2.62 ### Patch Changes - Updated dependencies \[]: - @vercel/node@5.7.1 ## @vercel/koa@0.1.42 ### Patch Changes - Updated dependencies \[]: - @vercel/node@5.7.1 ## @vercel/nestjs@0.2.63 ### Patch Changes - Updated dependencies \[]: - @vercel/node@5.7.1 ## @vercel/node@5.7.1 ### Patch Changes - Updated dependencies \[[`a80217a9ed60d7b7f3e98537b0468cc5488078c1`](a80217a)]: - @vercel/build-utils@13.13.0 ## @vercel/static-build@2.9.9 ### Patch Changes - Updated dependencies \[]: - @vercel/gatsby-plugin-vercel-builder@2.1.9 Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Summary
Adds
vercel edge-configwith dashboard API parity for Edge Config stores (team scope):ls) —GET /v1/edge-configcreate) —POST /v1/edge-config(optional--itemsJSON object)inspect) —GET /v1/edge-config/:id(acceptsecfg_…id or slug)PUTslug rename and/orPATCHitems via--patch(JSON array or{ "items": [...] })rm,delete) —DELETE /v1/edge-config/:id(confirmation /--yes)GETall items or one via--keyGET, createPOST(--add <label>), revokeDELETE(--remove, repeatable;--yesin non-interactive)Non-interactive / agents
exitWithNonInteractiveErrorsupports variantedge-config: API 404 maps tonot_found(notproject_not_found), withnext[]pointing atedge-config list,teams switch,whoami.Testing
pnpm exec vitest run test/unit/commands/edge-config/edge-config.test.ts(frompackages/cli)Changeset
vercelCLI package (.changeset/cli-edge-config.md).Closes / tracks parity issue: Edge Config CLI (attach to your internal parity issue as needed).
Made with Cursor