Repository navigation
fix(shop): PAYMENT_PROVIDER_NOT_CONFIGURED names the credential that's wrong (#216) - #226
Merged
Merged
Conversation
…s wrong (#216) The 503 listed all three Beam keys and told the merchant to edit wrangler.toml and redeploy, whatever was actually wrong. On bactrack the cause was a stored BEAM_API_KEY that no longer decrypted (and a legacy BEAM_SECRET_KEY the code never reads) — indistinguishable from "never set", because getSecrets returns null for both. - secrets/service: diagnoseSecrets() → env | stored | undecryptable | missing per key; unreadLookalikes() finds set env vars with the same prefix that Khao Pad doesn't read (BEAM_SECRET_KEY). - The 503 now says which keys are not set, which are saved but can't be decrypted (with the BETTER_AUTH_SECRET hint), which lookalikes are ignored, and points at /admin/settings/secrets instead of a redeploy. It also returns `missing` / `undecryptable` arrays and logs the same line. Key names only, never values. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
They are read (API host overrides). Caught by the admin payment-health card on a local worker pointed at a fake Beam. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Merged
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.
Closes #216.
Before
Payment provider beam is not configured … Set BEAM_MERCHANT_ID + BEAM_API_KEY + BEAM_WEBHOOK_SECRET in wrangler.toml [vars] and redeploy.: the same text whether a key was never set, saved but undecryptable after aBETTER_AUTH_SECRETrotation, or set under the wrong name. bactrack had the last two at once.After
diagnoseSecrets()(secrets service): per keyenv | stored | undecryptable | missing.unreadLookalikes(): set env vars with the provider's prefix that Khao Pad doesn't read, e.g.BEAM_SECRET_KEY.missing/undecryptablearrays and logs the line server-side. Key names only, never values (pinned by a test).Live on a local worker configured like bactrack was:
Tests
3 integration tests (env/stored/undecryptable/missing; the exact bactrack case incl. no values leaked; only-missing listed).
Gate: lint 0 errors · check 0 · 1170/1170 · build · contract-guard.
🤖 Generated with Claude Code