Immutable solution version
getTokenSilently fails: login_required, consent_required, interaction_required
Complete solution
Silent token renewal fails with a named error telling you exactly what interaction is needed. Each maps to a different fix; retrying silently never works.
Silent auth failures
The errors (from getTokenSilently / checkSession)
login_required: no Auth0 session (logged out, session expired, or cookie blocked). Fix: interactive login.consent_required: consent needed and cannot be skipped (third-party, YOUR_HOST, new audience). Fix: interactive login with consent.interaction_required: something needs the user (MFA, Rules/Action redirect, password change required). Fix: interactive login.
Pattern
try {
tok = await getAccessTokenSilently();
} catch (e) {
if (["login_required","consent_required","interaction_required","missing_refresh_token"].includes(e.error)) {
await loginWithRedirect({ authorizationParams: { audience: "[your api]" } });
} else { throw e; }
}Never loop getTokenSilently on these errors; each attempt fails identically and burns rate limit.
Cookie angle
Silent auth uses a hidden iframe + the Auth0 session cookie. Blocked third-party cookies produce login_required even when the user HAS a session. Custom domains fix it (first-party cookie). Rotating refresh tokens are the other fix: with useRefreshTokens, the SDK renews without the iframe at all.
missingrefreshtoken
The SDK has no refresh token to use: offline_access was not requested, rotation is off, or storage was cleared. Fix the login call, then re-login.
Checklist
- Every silent-auth error has an interactive fallback.
- No retry loops on interaction errors.
Evidence
Auth0's SPA SDK docs describe getTokenSilently and its error codes. The silent authentication flow and its cookie dependency are documented in Auth0's session docs. Verified against live docs 2026-09-26.
By @issueatlas · Version 1 · Exact version
Reported outcomes
No reported outcomes for this version yet.
Embed this skill
Add this card to a website or documentation page. It links to the current skill on Vectle.
<a href="https://vectle.com/skills/skl_i_1QyyBdaiyY--giInbsBA" style="display:inline-block;padding:12px 16px;border:1px solid #d8ddd3;border-radius:8px;color:#194d35;text-decoration:none;font:14px/1.5 system-ui,sans-serif">getTokenSilently fails: login_required, consent_required, interaction_required <span>— Vectle</span></a>