import express from "express"; import { WebhookEvent, Webhooks } from "@octokit/webhooks"; import LRUCache from "lru-cache"; import Redis from "ioredis"; import { Probot } from "./index"; import { Context } from "./context"; import { ProbotOctokit } from "./octokit/probot-octokit"; import type { Logger, LogFn } from "pino"; export interface Options { privateKey?: string; githubToken?: string; appId?: number | string; Octokit?: typeof ProbotOctokit; log?: Logger; redisConfig?: Redis.RedisOptions | string; secret?: string; webhookPath?: string; logLevel?: "trace" | "debug" | "info" | "warn" | "error" | "fatal"; port?: number; host?: string; baseUrl?: string; } export declare type State = { appId?: number; privateKey?: string; githubToken?: string; log: Logger; Octokit: typeof ProbotOctokit; octokit: InstanceType; cache?: LRUCache; webhooks: { path?: string; secret?: string; }; port?: number; host?: string; baseUrl?: string; }; export declare type ProbotWebhooks = Webhooks>; export declare type DeprecatedLogger = LogFn & Logger; export declare type ApplicationFunctionOptions = { getRouter?: (path?: string) => express.Router; [key: string]: unknown; }; export declare type ApplicationFunction = (app: Probot, options: ApplicationFunctionOptions) => void; export declare type ServerOptions = { log?: Logger; port?: number; host?: string; webhookPath?: string; webhookProxy?: string; Probot: typeof Probot; }; export declare type MiddlewareOptions = { probot: Probot; [key: string]: unknown; };