Skip to content

[flags] FlagValues: projectIds in the protected header, flags-keys JWKS - #575

Merged
luismeyer merged 2 commits into
standardfrom
luismeyer/flag-values-align-api
Oct 26, 2026
Merged

luismeyer merged 2 commits into
standardfrom
luismeyer/flag-values-align-api

Conversation

@luismeyer

@luismeyer luismeyer commented Oct 26, 2026 •

Copy link
Copy Markdown
Member

Why

Aligns platform-encrypted FlagValues with the backend contract in vercel/api#99707. The SDK currently omits projectIds from the protected header, so the API would reject every platform-encrypted token before decryption.

What changed

  • Adds the authorized projectIds to the protected JWE header, defaulting to the current Vercel project ID.
  • Supports explicit project IDs for multiple projects and microfrontends, with the same validation limits as the API.
  • Removes the ignored payload scope claim and fails clearly when no project ID is known.
  • Uses https://keys.vercel-flags.com/.well-known/jwks.json as the default platform JWKS.
  • Updates the standard, implementation spec, README, tests, Next.js caller fixture, and changeset.

Docs host removal

Removes the temporary flags-sdk.dev JWKS route, its helper and tests, and its local key-generation script. A repository-wide reference check found no remaining consumers.

Open questions

  • Is projectIds in the protected header the final format?
  • Should environment and team also be bound to platform-encrypted FlagValues?

🤖 Generated with Claude Code

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@vercel

vercel Bot commented Oct 26, 2026 •

Copy link
Copy Markdown
Contributor

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
flags-playground Error Error v0 Oct 26, 2026 11:55am UTC
flags-sdk-dev Error Error v0 Oct 26, 2026 11:55am UTC
flags-sdk-flagsmith Error Error v0 Oct 26, 2026 11:55am UTC
flags-sdk-launchdarkly Error Error v0 Oct 26, 2026 11:55am UTC
flags-sdk-reflag Error Error v0 Oct 26, 2026 11:55am UTC
flags-sdk-snippets Error Error v0 Oct 26, 2026 11:55am UTC
flags-sdk-sveltekit-snippets Error Error v0 Oct 26, 2026 11:55am UTC
shirt-shop Error Error v0 Oct 26, 2026 11:55am UTC
shirt-shop-api Ready Ready Preview, v0 Oct 26, 2026 11:55am UTC
4 Skipped Deployments
Project Deployment Actions Updated
flags-sdk-growthbook Skipped Skipped v0 Oct 26, 2026 11:55am UTC
flags-sdk-openfeature Skipped Skipped v0 Oct 26, 2026 11:55am UTC
flags-sdk-posthog Skipped Skipped v0 Oct 26, 2026 11:55am UTC
flags-sdk-statsig Skipped Skipped v0 Oct 26, 2026 11:55am UTC

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@luismeyer
luismeyer marked this pull request as ready for review October 26, 2026 12:23
@luismeyer
luismeyer merged commit 2921a96 into standard Oct 26, 2026
11 of 20 checks passed
@luismeyer
luismeyer deleted the luismeyer/flag-values-align-api branch October 26, 2026 12:24

This branch had an error being deployed

8 failed, 1 active, and 5 inactive deployments
Preview – flags-sdk-dev — 972ed3f9 Deployed Oct 26, 2026 by vercel[bot]
Preview – flags-sdk-snippets — 972ed3f9 Deployed Oct 26, 2026 by vercel[bot]
Preview – flags-playground — 972ed3f9 Deployed Oct 26, 2026 by vercel[bot]
Preview – shirt-shop — 972ed3f9 Deployed Oct 26, 2026 by vercel[bot]
Preview – flags-sdk-flagsmith — 972ed3f9 Deployed Oct 26, 2026 by vercel[bot]
Preview – flags-sdk-sveltekit-snippets — 972ed3f9 Deployed Oct 26, 2026 by vercel[bot]
Preview – flags-sdk-reflag — 972ed3f9 Deployed Oct 26, 2026 by vercel[bot]
Preview – flags-sdk-launchdarkly — 972ed3f9 Deployed Oct 26, 2026 by vercel[bot]
Preview – shirt-shop-api — 972ed3f9 Deployed Oct 26, 2026 by vercel[bot]
Preview – flags-sdk-growthbook — 972ed3f9 Deployed Oct 26, 2026 by vercel[bot]
Preview – flags-sdk-statsig — 972ed3f9 Deployed Oct 26, 2026 by vercel[bot]
Preview – flags-sdk-openfeature — 972ed3f9 Deployed Oct 26, 2026 by vercel[bot]
Preview – flags-sdk-posthog — 972ed3f9 Deployed Oct 26, 2026 by vercel[bot]
Preview – flags-sdk-vercel — 972ed3f9 Deployed Oct 26, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant