import type { H3Event } from "h3"; /** * Every write to `active-org-id` goes through here, so no call site can move an * account between organizations silently. Vault credentials are scoped per * organization, so a repoint makes every key synced under the previous org * unreadable for that account, and the only symptom is a missing-credential * error naming the key. The UI notices (`org.createOrgVaultNotice`, * `org.acceptInvitationOrgSwitchNotice`) only reach a human looking at the * screen; roster and identity migrations run by an agent reach this setting with * no notice anywhere in their path, so the warnings below go to `warnAgent` and * surface in the conversation that ordered the repoint. * * Pass the request's `event` when the account is the caller's own: its next * requests then read the new selection on every instance instead of a cached * one (see `ORG_SELECTION_COOKIE`). * * Lives in its own module because `auto-join-domain` and `accept-pending` are * imported by `context`, so hosting this in `context` would make the cycle. */ export declare function setActiveOrgId(email: string, orgId: string | null, reason: string, event?: H3Event): Promise;