probot.log()
, app.log()
and context.log()
are aliasing .log.info()
.
We will probably remove the aliasing in future.
Returns an Octokit instance with default settings for authentication. If
a githubToken
is passed explicitly, the Octokit instance will be
pre-authenticated with that token when instantiated. Otherwise Octokit's
app authentication strategy is used, and options.auth
options are merged
deeply when instantiated.
Besides the authentication, the Octokit's baseUrl is set as well when run against a GitHub Enterprise Server with a custom domain.
Detects if Probot is likely running in a test environment.
Note: This method only detects Jest environments or when NODE_ENV starts
with test
.
Returns true
if Probot is in a test environment.
The base event name refers to the part before
the first period mark (e.g. the issues
part in issues.opened
).
Returns false
when the application is not subscribed to a webhook
event. Otherwise, returns true
. Returns undefined
if Probot failed to
retrieve GitHub App metadata.
Note: Probot will only check against a list of events known to be in the
GET /app
response. Therefore, only the false
value should be considered
truthy.
Check if an application is subscribed to an event.
Returns false
if the app is not subscribed to an event. Otherwise,
returns true
. Returns undefined
if the webhook-event-check feature is
disabled or if Probot failed to retrieve the GitHub App's metadata.
Generated using TypeDoc
cert
options is deprecated. UseprivateKey
instead