UNPKG

743 BPlain TextView Raw
1import { Pool } from "pg";
2import { Authorization } from "./model";
3import { Explanation } from "./util/explanations";
4import { ReadonlyDataLoaderExecutor } from "./loader";
5
6export interface Context {
7 readonly realm: string;
8 readonly base: string;
9 readonly privateKey: string;
10 readonly publicKeys: ReadonlyArray<string>;
11 readonly codeValidityDuration: number;
12 readonly jwtValidityDuration: number;
13 readonly sendMail: (options: {
14 readonly to: string;
15 readonly subject: string;
16 readonly text: string;
17 readonly html: string;
18 readonly from?: string;
19 }) => Promise<any>;
20 readonly explanations: ReadonlyArray<Explanation>;
21 executor: ReadonlyDataLoaderExecutor<Pool>;
22 authorization: null | Authorization;
23}