woltsu / oidc-telegram

Make a Telegram channel joinable via OIDC authentication!

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

oidc-telegram

Make a Telegram channel joinable using OIDC authentication!

When navigating to the root of the application, the app will first make sure that the user is authenticated as per the OIDC configuration. Then, it will generate a unique Telegram channel invite link (that is usable once and expires in 1 hour), to which it will automatically redirect the user.

Environment Configuration

The application expects the following environment variables:

  • SESSION_SECRET, some long random string for securing session token
  • BASE_URL, the base url where the app is running
  • OIDC_ISSUER_URL
  • OIDC_CLIENT_ID
  • TELEGRAM_BOT_TOKEN
  • TELEGRAM_CHAT_ID

See .env.example for an example.

Running in Docker

npm run build:docker

Development

Install dependencies:

pnpm install

Start keycloak:

docker compose up

Start dev mode:

npm start

About

Make a Telegram channel joinable via OIDC authentication!

License:MIT License


Languages

Language:TypeScript 92.2%Language:Dockerfile 7.8%