The Bitcoin Calendar Bot is a Go-based application that fetches historical Bitcoin event data from the Bitcoin Historical Events API and publishes these events to Nostr relays. This bot automates the posting of calendar events about Bitcoin history.
Key functionalities include:
- Fetching events from a configurable API endpoint.
- Publishing events as Nostr Kind 1 (text-based) notes.
- NEW: Publishing events as Nostr NIP-68 Kind 20 (picture-based) notes for events with associated images.
- Support for English, configurable at runtime.
- Metrics collection for monitoring event posting success and failures.
The project has recently undergone a significant refactoring to improve modularity and maintainability. Core functionalities such as configuration management, API interaction, logging, metrics collection, and Nostr event publishing have been moved into dedicated packages within an internal directory.
The recommended way to run the bot is with Docker and Docker Compose. For detailed setup instructions, please see the Installation Guide.
A typical workflow involves:
- Cloning the repository.
- Configuring your API and Nostr keys in a
.envfile. - Building the Docker image with
docker-compose build. - Running the test bot with
docker-compose run --rm nostr-bot-en-testto verify your setup. - Setting up a cron job to run the production bot (
nostr-bot-en) daily.
The main application logic is organized within the internal directory:
internal/config: Handles loading and validation of application configuration.internal/api: Contains the client for interacting with the Bitcoin Calendar events API.internal/logging: Manages logger setup and configuration.internal/metrics: Provides a collector for tracking application-specific metrics.internal/models: Defines shared data structures likeAPIEvent.internal/nostr: Handles all Nostr-related operations, including event creation and publishing.
The main.go file serves as the entry point, orchestrating these components.
- Installation Guide - Detailed installation and setup instructions
- Usage Guide - How to use the bot effectively and available configuration options
- Development Guide - Information for developers
- Roadmap - Future development plans
This project is licensed under the MIT License. See the LICENSE.txt file for details.
Contributions are welcome! Please see our Contributing Guide for details.
Support Bitcoin Calendar via Coinos
- Bitcoin Calendar EN ⚡️
bitcal@coinos.io🔗 Coinos page
Support Bitcoin Calendar on Geyser
...or 👇
