You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[On hold]: AuthExports has no sign-in/sign-out and auth denials cannot carry an app error envelope (fixed-contract adapters) #830
ai-firstReduces friction for AI agents authoring URLCode projectsenhancementNew feature or requestextensionInvolves an extension or companion package (store, ui, auth, admin)needs-decisionWaiting on a maintainer decision before work can proceed
Implementation on hold under #841. Do not expand the legacy export API for historical parity. Exercise the underlying application need through the embedded-auth proof #843. No backward compatibility is required. Re-scope or close this request after the replacement proves the need is covered.
Problem or use case
Found by the #828 compatibility audit; see the fixed-contract-adapter recipe README, "Compatibility audit". The recipe keeps auth in charge of sessions, but two mismatches with a fixed external JSON contract remain, and both sit on auth's side of the boundary.
No sign-in or sign-out in AuthExports. A contract with POST /api/login returning {email, role} and POST /api/logout can't be served by an adapter without re-implementing what auth's /login and /logout handlers do around AuthService.login:
the flow CSRF token and origin check (http.verify);
The recipe makes clients call /account/csrf, then /account/login, then /api/me, and /account/logout.
Auth's 401 and 403 can't carry an application's error envelope. They come from authorize() as {error: "<message>"}. [Request]: Keep fixed JSON APIs declarative when method denials need a JSON error envelope #821's site.errors deliberately never rewrites extension denials, and onDeny changes only the status. A fixed contract's {error: {code}} for signed-out or CSRF failures isn't possible, so clients must key on status.
Proposed behavior and alternatives
This may be deliberate; the owner should decide. Options:
(a) Additive AuthExports.signIn(request, credentials) and signOut(request), which run the same verify, backoff, device and cookie steps as the native handlers and return the session headers for the adapter to pass through.
changed the title [-][Request]: AuthExports has no sign-in/sign-out and auth denials cannot carry an app error envelope (fixed-contract adapters)[/-][+][On hold]: AuthExports has no sign-in/sign-out and auth denials cannot carry an app error envelope (fixed-contract adapters)[/+]on Sep 28, 2026
Obsolete after #854 and #841. The contracts this issue describes are deleted: AuthExports, the fixed-contract adapter recipe and the admin package. Auth is now a thin Better Auth adapter that provides only a request principal and the identity capability. Store deletion and replace go through its HTTP API and StoreExports.transaction (#862), so no adapter-contract expansion is planned.
ai-firstReduces friction for AI agents authoring URLCode projectsenhancementNew feature or requestextensionInvolves an extension or companion package (store, ui, auth, admin)needs-decisionWaiting on a maintainer decision before work can proceed
Activity
[-][Request]: AuthExports has no sign-in/sign-out and auth denials cannot carry an app error envelope (fixed-contract adapters)[/-][+][On hold]: AuthExports has no sign-in/sign-out and auth denials cannot carry an app error envelope (fixed-contract adapters)[/+]jimhoyd commentedon Sep 29, 2026
Obsolete after #854 and #841. The contracts this issue describes are deleted:
AuthExports, the fixed-contract adapter recipe and the admin package. Auth is now a thin Better Auth adapter that provides only a request principal and theidentitycapability. Store deletion and replace go through its HTTP API andStoreExports.transaction(#862), so no adapter-contract expansion is planned.