Ask Beste anything about your codebase. Get back a structured response with code, citations, and the ability to apply changes — without leaving the editor.
Beste Copilot
claude-opus-4-7 · streaming
You
How do I rotate refresh tokens on every use without breaking concurrent requests?
Beste
Token rotation needs three pieces working together: a rotating store, a short grace window, and per-user locking on refresh.
Issue a new refresh token alongside each access token. Mark the previous one stale but keep it valid for a short overlap.
session.rotate({
staleAfter: "5s",
invalidate: "previous",
});Most rotation bugs come from skipping the grace window. Five seconds is enough to land any concurrent refresh.
From your codebase
src/auth/session.ts · L42
docs/security/tokens.md · §3.2
Browser-chrome card rendering an AI prompt and a structured response — markdown blocks (headings, paragraphs, lists, quotes, code), citation list, copy/regenerate/apply footer. Every label is editable; no media props required.
showcase28
Browser-chrome card rendering a markdown source editor on the left and the rendered HTML on the right — minimal monochrome syntax markers, structured preview blocks (headings, paragraphs, lists, fenced code). Every label is editable; no media props required.
showcase18
Browser-chrome card pairing a syntax-highlighted code editor with a live log stream — filter pills, color-coded levels, and a tail-mode footer. Every label is editable; no media props required.
showcase17
Browser-chrome card pairing a syntax-highlighted code editor with a live test-results panel — pass/fail rows, expandable failures, and a coverage footer. Every label is editable; no media props required.
showcase16
Browser-chrome card pairing a syntax-highlighted code editor with an AI chat panel — assistant suggestions arrive as inline snippets you can apply with one click. Every label is editable; no media props required.