dadjokes-slack-bot posts a dad joke to a Slack channel named dadjokes every weekday. The whole bot is one function: it asks icanhazdadjoke.com for a joke in its Slack format and posts the text with Slack’s Bolt SDK. It runs on AWS Lambda on a weekday schedule, both set up by the Serverless Framework.
The repository has four commits: the first on December 10, 2021, and three small changes on January 2, 2022. It hasn’t changed since, and the README is still the Serverless Framework’s template for a scheduled cron job. The joke API still answers in the same format, so the handler still runs.
The handler
joke.js exports run, the Lambda handler. Each call creates a Bolt App with the bot token and signing secret from the environment, fetches https://icanhazdadjoke.com/slack with node-fetch, and posts the first attachment’s text with chat.postMessage. Errors are logged, not retried. One of the January commits added the await in front of postMessage, so the function waits for Slack’s reply before it returns.

The schedule
serverless.yml deploys one function, jokeHandler, to AWS on the Node.js 14 runtime. Its schedule event is cron(0 16 ? * MON-FRI *): 16:00 UTC, Monday to Friday, which the comment above it calls 10am. The Slack token and signing secret come from Serverless Framework dashboard parameters, and the serverless-bundle plugin bundles the code, with its esbuild option on.

The code is ES modules, with @slack/bolt 3.8 and node-fetch 3.1, deployed with Serverless Framework 2.70 and serverless-bundle 5.2.
The creation date shown here is the GitHub repository’s UTC creation date. The terminal capture comes from running the repository’s handler locally on Node 14, bundled with esbuild, with placeholder Slack credentials and a stub that blocks every connection to Slack and prints the calls instead, so nothing was posted. The jokes are real responses from icanhazdadjoke.com, and the code cards show real source files from the repository.