telegram-console
v0.4.1
Published
A terminal-based Telegram client
Downloads
1,273
Maintainers
Readme
telegram-console
A terminal-based Telegram client for technical users. Seamlessly and discretely keep track of your group chats while you watch Claude do your job.
Installation
npm install -g telegram-consoleSetup
Step 1: Get Telegram API Credentials
Telegram allows third-party clients to access their platform through an official API. Unlike some services that require centralized API keys, Telegram's model lets each user generate their own credentials. This means:
- You control your credentials — your API ID and Hash are generated by you and stored only on your machine
- No middleman — this client connects directly to Telegram's servers using your credentials
- Full transparency — the code is open source, so you can verify exactly what data is sent
To get your credentials:
- Go to my.telegram.org and log in with your phone number
- You'll receive a confirmation code in Telegram — enter it
- Click on "API development tools"
- Fill in the form:
- App title: Any name (e.g., "My Console Client")
- Short name: A short identifier (e.g., "console")
- Platform, description, and other fields can be left as default
- Click "Create application"
- You'll see your API ID (a number) and API Hash (a string) — save these
Important: Never share your API credentials. They are unique to your account and should be treated like a password.
By using the Telegram API, you agree to Telegram's API Terms of Service.
Step 2: Run the Client
- Run
telegram-console - Enter your API ID and API Hash when prompted
- Authenticate using one of these methods:
- QR Code (default): Scan the QR code with Telegram mobile app (Settings → Devices → Link Desktop Device)
- Phone Code: Enter your phone number and the code sent to your Telegram
Usage
telegram-consoleKeyboard Shortcuts
| Key | Action | | ------ | -------------------------------- | | ↑/↓ | Navigate chats / scroll messages | | ←/→ | Switch panels | | Enter | Select chat / send message | | Tab | Focus input | | Esc | Go back | | Ctrl+C | Exit |
Features
- View chat list (private chats + groups)
- Read messages
- Send text messages
- Unread indicators
- Connection status display
- Session persistence
- QR code + phone code authentication
Configuration
Config file location: ~/.config/telegram-console/config.json
Environment Variables
| Variable | Description |
| ----------------- | --------------------------- |
| TG_API_ID | Telegram API ID |
| TG_API_HASH | Telegram API Hash |
| TG_SESSION_MODE | persistent or ephemeral |
| TG_AUTH_METHOD | qr or phone |
Contributing
Contributions are welcome! Feel free to open issues and pull requests.
License
MIT
