UNPKG

@openinc/parse-server-opendash

Version:
15 lines (14 loc) 695 B
import { Core_Token } from "../types"; interface TokenPayload { type: "verify-email" | "password-reset"; userId: string; } export declare function createToken(type: TokenPayload["type"], userId: string, url: string): Promise<{ token: string; url: string; }>; export declare function createUrl(url: string, token: string): string; export declare function consumeToken(type: TokenPayload["type"], key: string, doNotConsume?: boolean): Promise<TokenPayload>; export declare function isExpired(token: Core_Token): boolean; export declare function createSessionToken(user: Parse.User, installationId: string | undefined, createdWith: Record<string, any>): Promise<string>; export {};