A self-hosted service that monitors your Anytype tasks and sends notifications for items due today. It periodically syncs tasks from the Anytype API.
- Periodic sync of tasks from a self-hosted Anytype instance
- Notifications for tasks due today (sent once per task)
- Current notification providers: Telegram (more to come)
- REST API to view overdue and upcoming tasks
- Lightweight SQLite storage with no external database required
- Docker support for easy deployment
- A self-hosted Anytype instance with API access enabled
- For telegram notifications: A Telegram bot and the chat ID where notifications should be sent
- Docker (recommended) or JDK 17+ for running locally
-
Clone the repository:
git clone https://github.com/fixilein/anytype-notifications.git cd anytype-notifications -
Create a
.envfile from the example:cp .env.example .env
-
Fill in your
.envvalues (see Configuration below). -
Start the service:
docker compose up -d
The service will start syncing tasks and sending notifications. The REST API is available at http://localhost:8080.
If you don't already have an Anytype API endpoint, you can run the headless Anytype CLI alongside this service using anytype-cli-docker.
services:
anytype-cli:
build:
context: ./anytype-cli-docker
args:
ANYTYPE_CLI_VERSION: v0.1.9
ports:
- "31012:31012"
volumes:
- ./anytype-cli-docker/data:/data
- ./anytype-cli-docker/anytype-home:/root/.anytype
- ./client-config.yml:/root/.config/anytype/network.yml:ro
command: ["serve", "--listen-address", "0.0.0.0:31012"]
restart: unless-stopped
anytype-notifications:
build: ./anytype-notifications
ports:
- "8080:8080"
environment:
TZ: ${TZ}
ANYTYPE_BASE_URL: http://anytype-cli:31012
ANYTYPE_API_KEY: ${ANYTYPE_API_KEY}
SYNC_INTERVAL_MINUTES: "60"
TELEGRAM_BOT_TOKEN: ${TELEGRAM_BOT_TOKEN}
TELEGRAM_CHAT_ID: ${TELEGRAM_CHAT_ID}
volumes:
- ./anytype-notifications/data:/app/data
depends_on:
- anytype-cli
restart: unless-stoppedSee the anytype-cli-docker README for setup instructions (creating a bot account, joining a space, and generating an API key).
-
Make sure JDK 17+ is installed.
-
Set the required environment variables (see Configuration).
-
Build and run:
./gradlew run
All configuration is done through environment variables. Create a .env file in the project root (it is git-ignored by default).
| Variable | Required | Default | Description |
|---|---|---|---|
ANYTYPE_BASE_URL |
Yes | — | URL of your self-hosted Anytype instance. Should start with http or https |
ANYTYPE_API_KEY |
Yes | — | API key for Anytype authentication |
TELEGRAM_BOT_TOKEN |
Yes | — | Token from @BotFather |
TELEGRAM_CHAT_ID |
Yes | — | Chat ID where notifications are sent |
TZ |
Yes | — | Your timezone (e.g. Europe/Vienna, America/New_York) |
SYNC_INTERVAL_MINUTES |
No | 60 |
How often to sync tasks from Anytype (in minutes) |
ANYTYPE_OBJECT_TYPE_KEY |
No | task |
Anytype object type key to query |
ANYTYPE_DUE_DATE_PROPERTY_KEY |
No | due_date |
Anytype property key used for the due date |
Returns all synced tasks split into overdue and upcoming.
{
"overdue": [
{
"title": "Review PR",
"dueDate": "2026-02-15T10:00:00Z",
"objectId": "bafyreib..."
}
],
"upcoming": [
{
"title": "Write docs",
"dueDate": "2026-02-20T14:30:00Z",
"objectId": "bafyreic..."
}
]
}- Kotlin 2.2 on JVM 17
- Ktor — HTTP client (Anytype API) and server (REST API)
- Exposed — Database ORM for SQLite
- kotlinx-serialization — JSON handling
- kotlinx-coroutines — Async scheduling
- kotlinx-datetime — Timezone-aware date handling