1 | export type { Logger } from "pino";
|
2 | export { Context } from "./context.js";
|
3 | export { Probot } from "./probot.js";
|
4 | export { Server } from "./server/server.js";
|
5 | export { ProbotOctokit } from "./octokit/probot-octokit.js";
|
6 | export { run } from "./run.js";
|
7 | export { createNodeMiddleware } from "./create-node-middleware.js";
|
8 | export { createProbot } from "./create-probot.js";
|
9 | /** NOTE: exported types might change at any point in time */
|
10 | export type { Options, ApplicationFunction, ApplicationFunctionOptions, } from "./types.js";
|
11 | declare global {
|
12 | namespace NodeJS {
|
13 | interface ProcessEnv {
|
14 | /**
|
15 | * The App ID assigned to your GitHub App.
|
16 | * @example '1234'
|
17 | */
|
18 | APP_ID?: string;
|
19 | /**
|
20 | * By default, logs are formatted for readability in development. You can
|
21 | * set this to `json` in order to disable the formatting.
|
22 | */
|
23 | LOG_FORMAT?: "json" | "pretty";
|
24 | /**
|
25 | * The verbosity of logs to show when running your app, which can be
|
26 | * `fatal`, `error`, `warn`, `info`, `debug`, `trace` or `silent`.
|
27 | * @default 'info'
|
28 | */
|
29 | LOG_LEVEL?: "trace" | "debug" | "info" | "warn" | "error" | "fatal" | "silent";
|
30 | /**
|
31 | * By default, when using the `json` format, the level printed in the log
|
32 | * records is an int (`10`, `20`, ..). This option tells the logger to
|
33 | * print level as a string: `{"level": "info"}`. Default `false`
|
34 | */
|
35 | LOG_LEVEL_IN_STRING?: "true" | "false";
|
36 | /**
|
37 | * Only relevant when `LOG_FORMAT` is set to `json`. Sets the json key for the log message.
|
38 | * @default 'msg'
|
39 | */
|
40 | LOG_MESSAGE_KEY?: string;
|
41 | /**
|
42 | * The organization where you want to register the app in the app
|
43 | * creation manifest flow. If set, the app is registered for an
|
44 | * organization
|
45 | * (https://github.com/organizations/ORGANIZATION/settings/apps/new), if
|
46 | * not set, the GitHub app would be registered for the user account
|
47 | * (https://github.com/settings/apps/new).
|
48 | */
|
49 | GH_ORG?: string;
|
50 | /**
|
51 | * The hostname of your GitHub Enterprise instance.
|
52 | * @example github.mycompany.com
|
53 | */
|
54 | GHE_HOST?: string;
|
55 | /**
|
56 | * The protocol of your GitHub Enterprise instance. Defaults to HTTPS.
|
57 | * Do not change unless you are certain.
|
58 | * @default 'https'
|
59 | */
|
60 | GHE_PROTOCOL?: string;
|
61 | /**
|
62 | * The contents of the private key for your GitHub App. If you're unable
|
63 | * to use multiline environment variables, use base64 encoding to
|
64 | * convert the key to a single line string. See the Deployment docs for
|
65 | * provider specific usage.
|
66 | */
|
67 | PRIVATE_KEY?: string;
|
68 | /**
|
69 | * When using the `PRIVATE_KEY_PATH` environment variable, set it to the
|
70 | * path of the `.pem` file that you downloaded from your GitHub App registration.
|
71 | * @example 'path/to/key.pem'
|
72 | */
|
73 | PRIVATE_KEY_PATH?: string;
|
74 | /**
|
75 | * The port to start the local server on.
|
76 | * @default '3000'
|
77 | */
|
78 | PORT?: string;
|
79 | /**
|
80 | * The host to start the local server on.
|
81 | */
|
82 | HOST?: string;
|
83 | /**
|
84 | * Set to a `redis://` url as connection option for
|
85 | * [ioredis](https://github.com/luin/ioredis#connect-to-redis) in order
|
86 | * to enable
|
87 | * [cluster support for request throttling](https://github.com/octokit/plugin-throttling.js#clustering).
|
88 | * @example 'redis://:secret@redis-123.redislabs.com:12345/0'
|
89 | */
|
90 | REDIS_URL?: string;
|
91 | /**
|
92 | * Set to a [Sentry](https://sentry.io/) DSN to report all errors thrown
|
93 | * by your app.
|
94 | * @example 'https://1234abcd@sentry.io/12345'
|
95 | */
|
96 | SENTRY_DSN?: string;
|
97 | /**
|
98 | * The URL path which will receive webhooks.
|
99 | * @default '/api/github/webhooks'
|
100 | */
|
101 | WEBHOOK_PATH?: string;
|
102 | /**
|
103 | * Allows your local development environment to receive GitHub webhook
|
104 | * events. Go to https://smee.io/new to get started.
|
105 | * @example 'https://smee.io/your-custom-url'
|
106 | */
|
107 | WEBHOOK_PROXY_URL?: string;
|
108 | /**
|
109 | * **Required**
|
110 | * The webhook secret used when creating a GitHub App. 'development' is
|
111 | * used as a default, but the value in `.env` needs to match the value
|
112 | * configured in your App settings on GitHub. Note: GitHub marks this
|
113 | * value as optional, but for optimal security it's required for Probot
|
114 | * apps.
|
115 | *
|
116 | * @example 'development'
|
117 | * @default 'development'
|
118 | */
|
119 | WEBHOOK_SECRET?: string;
|
120 | NODE_ENV?: string;
|
121 | }
|
122 | }
|
123 | }
|