release: @marketplaces/auth 0.1.0 (built from main)
This commit is contained in:
44
dist/telegram/admin-auth.service.d.ts
vendored
Normal file
44
dist/telegram/admin-auth.service.d.ts
vendored
Normal file
@@ -0,0 +1,44 @@
|
||||
import { Observable } from 'rxjs';
|
||||
import { AdminAuthStatus, AuthSession, WebSessionStart } from './models/session.model';
|
||||
export declare class AdminAuthService {
|
||||
private readonly api;
|
||||
private readonly sessionSignal;
|
||||
private readonly statusSignal;
|
||||
private readonly showLoginSignal;
|
||||
readonly session: import("@angular/core").Signal<AuthSession | null>;
|
||||
readonly status: import("@angular/core").Signal<AdminAuthStatus>;
|
||||
readonly isAuthenticated: import("@angular/core").Signal<boolean>;
|
||||
readonly showLoginDialog: import("@angular/core").Signal<boolean>;
|
||||
readonly displayName: import("@angular/core").Signal<string | null>;
|
||||
private sessionCheckTimer?;
|
||||
constructor();
|
||||
checkSession(): void;
|
||||
/** Check session without mutating internal state beyond activating on success (used for polling). */
|
||||
checkSessionOnce(webSessionID?: string | null): Observable<AuthSession | null>;
|
||||
/** Create a backend web session - identical call to the customer login (TelegramSessionApiService.createSession). */
|
||||
createWebSession(): Observable<WebSessionStart>;
|
||||
getAdminAppLoginUrl(webSessionID: string): string;
|
||||
onLoginComplete(): void;
|
||||
requestLogin(): void;
|
||||
/**
|
||||
* Dev-only shortcut for local testing without a reachable Telegram/session
|
||||
* backend: fabricates a local session and activates it directly, skipping
|
||||
* the QR flow entirely. No-ops in production builds (checked via Angular's
|
||||
* isDevMode() at runtime, not just build-time, so it is safe even if this
|
||||
* code ships). Never call this from anywhere reachable in a production build.
|
||||
*/
|
||||
devBypassLogin(): void;
|
||||
hideLogin(): void;
|
||||
logout(): void;
|
||||
/** JWT pair storage, reserved for once the backend issues admin access/refresh tokens. Unused until then. */
|
||||
getAdminToken(): string | null;
|
||||
setAdminTokens(token: string, refreshToken: string): void;
|
||||
clearAdminTokens(): void;
|
||||
private activateSession;
|
||||
private clearAuthState;
|
||||
private scheduleSessionRefresh;
|
||||
private clearSessionRefresh;
|
||||
private getStoredAdminSessionID;
|
||||
private setStoredAdminSessionID;
|
||||
private clearStoredAdminSessionID;
|
||||
}
|
||||
Reference in New Issue
Block a user