Skip to content

1grzyb1/aoc-slack

Repository files navigation

AOC-SLACK

Slack bot for Advent of Code.

Features

Posting messages about solved puzzles to Slack channels in real time.

img.png

Posting a message with leaderboard at the end of the day.

img_2.png

Installation

To install slack bot you need to add slack app to your workspace and host aoc-slack bot somewhere.

Add app to your slack workspace

  1. Go to https://api.slack.com/apps and create a new app.
  2. Select "From scratch" and give it a name and workspace.
  3. Select incoming webhooks and activate it.
  4. Click "Add new webhook to your workspace" and select a channel to which you want to receive messages.

Host aoc-slack bot

To run aoc-slack in docker you need to run the following command:

docker run -e AOC_SLACK_LEADERBOARD_ID=<leaderboard_id> \
           -e AOC_SLACK_SESSION=<aoc_session> \
           -e AOC_SLACK_WEBHOOK_URL=<slack_app_webhook_url> \
           -d \
           1grzyb1/aoc-slack:latest

Properties description

Property Description
AOC_SLACK_LEADERBOARD_ID (required) ID of your private leaderboard in advent of code
AOC_SLACK_SESSION (required) Session header from aoc website
AOC_SLACK_WEBHOOK_URL (required) URL to slack app webhook
AOC_SLACK_YEAR Year for which bot should work (default current year)
AOC_SLACK_STARS_CRON Cron how often new stars should be refreshed (default every 15min. Minimum approved by aoc API)
AOC_SLACK_LEADERBOARD_CRON Cron how when leaderboard should be sent (default midnight EST (UTC-5))
AOC_SLACK_ONLY_ACTIVE_USERS Shows only users with any points on leaderboard (default False)

About

Advent of code slack bot

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published