@wasserstoff/mangi-tg-bot
Version:
A powerful Telegram Bot SDK with built-in authentication, session management, and database integration
15 lines • 610 B
TypeScript
export type SessionData = {
jwtToken?: string;
custom?: {};
};
export declare const initial: () => SessionData & {
setCustom: (key: string, value: any) => void;
getCustom: (key: string) => any;
updateCustom: (updates: Record<string, any>) => void;
deleteCustom: (key: string) => void;
};
export default function sessionMiddleware(ctx: any, next: () => Promise<void>): Promise<void>;
import { Middleware } from "grammy";
import { CustomContext } from "../context/CustomContext";
export declare const requireSessionAndChat: Middleware<CustomContext>;
//# sourceMappingURL=session.d.ts.map