feat(web): send CSA Vercel protection bypass on GDPR scrub - #5455
Merged
eshurakov merged 1 commit intoAug 24, 2026
Conversation
Add support for the `CSA_VERCEL_PROTECTION_BYPASS` environment variable to allow the Cloud deletion worker to authenticate with CSA when Vercel Deployment Protection is enabled. - Add `CSA_VERCEL_PROTECTION_BYPASS` to `.env.local.example` and `ENVIRONMENT.md`. - Update `handleCsaSupportDb` to include the `x-vercel-protection-bypass` header in requests to CSA. - Update `deletionAttentionHint` to provide more descriptive instructions when a `csa_unauthorized` error occurs. - Add unit tests to verify the bypass header is correctly sent or omitted based on the environment configuration.
Contributor
Author
Code Review SummaryStatus: No Issues Found | Recommendation: Merge Files Reviewed (6 files)
Reviewed by grok-4.6 · Input: 58.6K · Output: 9.9K · Cached: 514.2K Review guidance: REVIEW.md from base branch |
pandemicsyn
approved these changes
Aug 24, 2026
eshurakov
deleted the
session/agent_52810711-b7dc-488e-9dda-5605b7ef35f7
branch
August 24, 2026 20:24
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Cloud → CSA
POST /api/internal/cloud/users/gdpr-scrubwas gettingcsa_unauthorizedbecause Vercel Deployment Protection runs before CSA'sKILO_SUPPORT_API_SECRETcheck. CSA → Cloud working does not cover this path.x-vercel-protection-bypassfromCSA_VERCEL_PROTECTION_BYPASS(header only, never a query param).Authorization: Bearer $SUPPORT_API_SECRETfor CSA route auth.csa_unauthorizedoperator hint to mention both secrets.After merge, set the secret with
pnpm web:env set CSA_VERCEL_PROTECTION_BYPASS(CSA project's Vercel automation bypass).Verification
git diff --checkcsa-support-db/deletion-hintsnot run here (no local Postgres)Visual Changes
None. Operator hint text for
csa_unauthorizednow mentionsCSA_VERCEL_PROTECTION_BYPASS.