@cfxlabsinc/b2b-services
    Preparing search index...

    Type Alias StoredSessionResolution<TStaff>

    StoredSessionResolution:
        | {
            kind: "signed-in";
            opened: OpenedSession;
            session: StoredSession;
            staff: TStaff
            | null;
        }
        | { kind: "signed-out" }
        | { kind: "ended" }

    Type Parameters

    • TStaff = never

    Type Declaration

    • {
          kind: "signed-in";
          opened: OpenedSession;
          session: StoredSession;
          staff: TStaff | null;
      }

      opened reads the row as it now stands, a refresh's new tokens included. staff is the admitted staff principal for a cfx-admin session, else null.

    • { kind: "signed-out" }

      No id cookie, or no live row for it.

    • { kind: "ended" }

      The tokens stopped verifying or the refresh was refused: the row is ended.