A chatbot with configurable plugins to use in Telegram channels
  • Go 86.2%
  • HTML 13.1%
  • Makefile 0.5%
  • Dockerfile 0.2%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Felipe M. 8b1eb05813
All checks were successful
CI / goreleaser-lint (push) Successful in 14s
CI / format (push) Successful in 1m27s
CI / test (push) Successful in 3m44s
CI / build (push) Successful in 6m23s
CI / lint (push) Successful in 7m52s
Authenticate the setup actions against the GitHub API
setup-go, setup-node and setup-bun resolve versions through
api.github.com. Anonymously that is sixty requests an hour for the
whole runner host, and the jobs started failing on it. GH_API_TOKEN is
a read-only GitHub token held as a Forgejo secret.

Where the secret is absent the input is empty and the action falls back
to an anonymous request, exactly as before.
2026-09-22 12:54:19 +02:00
.github/workflows Authenticate the setup actions against the GitHub API 2026-09-22 12:54:19 +02:00
assets What is my purpose? 2020-04-23 11:00:19 +02:00
cmd/butterrobot feat: add Sentry observability support 2026-09-21 14:10:15 +02:00
docs feat: add Sentry observability support 2026-09-21 14:10:15 +02:00
internal fix: skip unknown plugins enabled on a channel without erroring 2026-09-21 20:08:30 +02:00
.env-example chore: remove Slack platform support 2026-07-06 07:52:31 +02:00
.gitignore chore: ignore all test db files 2025-06-13 12:04:22 +02:00
.goreleaser.yml ci: migrate from Woodpecker to Forgejo Actions and modernize build setup (#1) 2026-04-08 10:50:27 +02:00
CLAUDE.md chore: try to ensure that code is checked after each session 2025-06-23 11:35:30 +02:00
Containerfile feat: add !gallerydl command to download media from links 2026-07-05 20:05:57 +02:00
go.mod feat: add Sentry observability support 2026-09-21 14:10:15 +02:00
go.sum feat: add Sentry observability support 2026-09-21 14:10:15 +02:00
Makefile Give golangci-lint five minutes 2026-09-22 12:47:19 +02:00
README.md feat: add Sentry observability support 2026-09-21 14:10:15 +02:00

Butter Robot

Status badge

Go framework to create bots for several platforms.

Butter Robot

What is my purpose?

Features

  • Support for chat platforms (Telegram)
  • Plugin system for easy extension
  • Admin interface for managing channels and plugins
  • Message queue for asynchronous processing
  • Optional Sentry error reporting and tracing

Documentation

Go to documentation

Database Management

ButterRobot includes an automatic database migration system. Migrations are applied automatically when the application starts, ensuring your database schema is always up to date.

Learn more about migrations

Installation

From Source

# Clone the repository
git clone https://git.nakama.town/fmartingr/butterrobot.git
cd butterrobot

# Build the application
go build -o butterrobot ./cmd/butterrobot

Containers

The fmartingr/butterrobot/butterrobot container image is published on Github packages:

docker pull docker.pkg.git.nakama.town/fmartingr/butterrobot/butterrobot:latest
docker run -d --name butterrobot -p 8080:8080 docker.pkg.git.nakama.town/fmartingr/butterrobot/butterrobot:latest

Configuration

Configuration is done through environment variables:

  • DEBUG: Set to "y" to enable debug mode
  • BUTTERROBOT_HOSTNAME: Hostname for webhook URLs
  • LOG_LEVEL: Logging level (DEBUG, INFO, WARN, ERROR)
  • SECRET_KEY: Secret key for sessions and password hashing
  • DATABASE_PATH: Path to SQLite database file

Observability

Sentry error reporting is optional and off until a DSN is provided:

  • SENTRY_DSN: Sentry DSN (empty disables reporting)
  • SENTRY_ENVIRONMENT: Environment name (default production)
  • SENTRY_RELEASE: Release identifier (defaults to the build version)
  • SENTRY_TRACES_SAMPLE_RATE: Fraction of HTTP requests traced, 0.0-1.0 (default 0)
  • SENTRY_ENABLE_LOGS: Set to y to forward non-error logs to Sentry

Learn more about observability

Platform-specific configuration

Telegram

  • TELEGRAM_TOKEN: Telegram bot token

Contributing

git clone git@github.com:fmartingr/butterrobot.git
cd butterrobot
go mod download

Create a .env-local file with the required environment variables:

TELEGRAM_TOKEN=xxx
...

And then you can run it directly:

go run ./cmd/butterrobot/main.go

License

GPL-2.0