Skip to content

[docs] Document Edge Function redeploy step in OpenRouter rotation FAQ#245

Open
Silverhawk-bit wants to merge 1 commit intoNateBJones-Projects:mainfrom
Silverhawk-bit:contrib/Silverhawk-bit/faq-rotation-redeploy
Open

[docs] Document Edge Function redeploy step in OpenRouter rotation FAQ#245
Silverhawk-bit wants to merge 1 commit intoNateBJones-Projects:mainfrom
Silverhawk-bit:contrib/Silverhawk-bit/faq-rotation-redeploy

Conversation

@Silverhawk-bit
Copy link
Copy Markdown

Contribution Type

  • Repo improvement (docs, CI, templates)

What does this do?

Closes a gap in the OpenRouter API key rotation FAQ (docs/03-faq.md). The checklist previously stopped at supabase secrets set, but Edge Functions read environment variables once at cold start and cache them — already-running ("warm") instances keep using the old key until they recycle, producing intermittent 401s for several minutes after a rotation.

This PR adds the paired supabase functions deploy open-brain-mcp --no-verify-jwt command and a short paragraph explaining the warm-instance caching behavior, plus a note for users running extension functions that also consume OPENROUTER_API_KEY.

The Step 6.5 callout in docs/01-getting-started.md already points readers to "the FAQ on key rotation for the full checklist," so it inherits this fix automatically — no second edit needed.

Requirements

None. Documentation-only change.

Checklist

  • I've read CONTRIBUTING.md
  • My contribution has a README.md with prerequisites, step-by-step instructions, and expected outcome — N/A, edits an existing doc
  • My metadata.json has all required fields — N/A, edits an existing doc
  • If my contribution depends on a skill or primitive, I declared it in metadata.json and linked it in the README — N/A
  • I tested this on my own Open Brain instance — verified the documented behavior on my own deployment: rotating OpenRouter and running secrets set alone produces intermittent 401s until the function redeploys; pairing with functions deploy resolves immediately
  • No credentials, API keys, or secrets are included

The rotation checklist in docs/03-faq.md previously stopped at
`supabase secrets set`, but Edge Functions cache env vars at cold start.
Warm instances keep using the old key until they recycle, producing
intermittent 401s for several minutes after rotation.

Adds the paired `supabase functions deploy` command and a paragraph
explaining the warm-instance caching behavior, plus a note for users
running extension functions that also consume OPENROUTER_API_KEY.
@github-actions
Copy link
Copy Markdown

Hey @Silverhawk-bit — welcome to Open Brain Source! 👋

Thanks for submitting your first PR. The automated review will run shortly and check things like metadata, folder structure, and README completeness. If anything needs fixing, the review comment will tell you exactly what.

Once the automated checks pass, a human admin will review for quality and clarity. Expect a response within a few days.

If you have questions, check out CONTRIBUTING.md or open an issue.

@github-actions github-actions Bot added the documentation Improvements or additions to documentation label Apr 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant