Installation

Choose Telegram or MAX, install with your agent or terminal, then log in and check it works.

The Telegram and MAX CLIs are npm packages that run on Windows, macOS and Linux. Ask your local agent to check your computer, install the CLI and help connect your account, or install it yourself in a terminal. Once you have logged in, check your account and first chats, then give your agent a useful task.

1. Choose a messenger

Open Telegram or MAX below and copy the request into your local agent. It works with Codex, Cursor, Claude Code, Gemini CLI and Hermes. To install it yourself, open Install in a terminal inside the selected messenger.

Install Telegram

Copy this request into your agent. It will help you install and log in on your computer.

Prompt
Set up tg on my computer. First read the guide: https://wirecat.dev/llms.mdx/docs/installation/content.md

Check that Node.js 22.16+ (22.x) or 24+ and npm are installed.

Install with npm install -g @leemour/tg-cli (use npm.cmd in Windows PowerShell). Make sure tg runs by name in your current shell and in future terminals. On Windows, find the installation folder with npm.cmd prefix -g; add it to user PATH if missing, preserve existing entries, and refresh your own shell PATH. Do not assume npm updated your running shell. On macOS/Linux, check npm prefix -g and its bin folder when resolving the command; preserve existing shell configuration. If PowerShell blocks the generated script, use the .cmd launcher and follow the documented package repair without changing the permanent execution policy.

Before login, run tg skill install --for all. Read tg --help, tg commands --json and tg skill show, then load and verify the installed skill for your agent.

Use guided setup if the installed cli supports it; otherwise follow the login guide. Tell me setup takes about five minutes and chat history downloads are a separate step. Have me enter login codes and passwords locally or scan the QR code.

Verify tg --version, run tg doctor, check the logged-in account and show the first five chats.
Connect your agent →
Install in a terminal

Node.js 22.16+ (22.x) or 24+ with npm. After installing Node.js, open a new terminal.

Node.js ↗
Command
npm install -g @leemour/tg-cli
tg skill install --for all
tg --version
tg doctor

Windows: this single PowerShell installer installs the CLI and agent skill, saves user PATH, updates this terminal and verifies the command. No manual PATH edits:

Command
& ([scriptblock]::Create((Invoke-RestMethod 'https://wirecat.dev/install.ps1'))) -Tool tg -Agent all

Log in

Command
tg setup --agent all

Telegram setup checks your account and five chats and installs agent skills; history downloads are separate. The auto mode obtains your app ID and hash. Enter the code from Telegram in your terminal, then scan the QR in Settings → Devices → Link Desktop Device. If auto fails, use session start --app browser.

Command
tg account show
tg chats list --limit 5
tg inbox --limit 5
Documentation →

Allow about 5 minutes for setup. Downloading chat history is a separate step and may take longer.

The browser gives you the instructions; your agent or terminal runs the installation on your computer.

Install MAX

Copy this request into your agent. It will help you install and log in on your computer.

Prompt
Set up max on my computer. First read the guide: https://wirecat.dev/llms.mdx/docs/installation/content.md

Check that Node.js 22.16+ (22.x) or 24+ and npm are installed.

Install with npm install -g @leemour/max-cli (use npm.cmd in Windows PowerShell). Make sure max runs by name in your current shell and in future terminals. On Windows, find the installation folder with npm.cmd prefix -g; add it to user PATH if missing, preserve existing entries, and refresh your own shell PATH. Do not assume npm updated your running shell. On macOS/Linux, check npm prefix -g and its bin folder when resolving the command; preserve existing shell configuration. If PowerShell blocks the generated script, use the .cmd launcher and follow the documented package repair without changing the permanent execution policy.

Before login, run max skill install --for all. Read max --help, max commands --json and max skill show, then load and verify the installed skill for your agent.

Use guided setup if the installed cli supports it; otherwise follow the login guide. Tell me setup takes about five minutes and chat history downloads are a separate step. Have me enter login codes and passwords locally or scan the QR code.

Verify max --version, run max doctor, check the logged-in account and show the first five chats.
Connect your agent →
Install in a terminal

Node.js 22.16+ (22.x) or 24+ with npm. After installing Node.js, open a new terminal.

Node.js ↗
Command
npm install -g @leemour/max-cli
max skill install --for all
max --version
max doctor

Windows: this single PowerShell installer installs the CLI and agent skill, saves user PATH, updates this terminal and verifies the command. No manual PATH edits:

Command
& ([scriptblock]::Create((Invoke-RestMethod 'https://wirecat.dev/install.ps1'))) -Tool max -Agent all

Log in

Command
max setup --agent all

MAX setup guides QR login, checks your account and five chats, and installs agent skills. It reuses an existing session. It does not download all history or start the background service.

Command
max account show
max chats list --limit 5
max inbox --limit 5
Documentation →

Allow about 5 minutes for setup. Downloading chat history is a separate step and may take longer.

The browser gives you the instructions; your agent or terminal runs the installation on your computer.

Allow about five minutes for installation and login. Downloading chat history is a separate step; choose the chats and amount of history after setup.

2. Log in on your computer

Enter login codes and passwords in your local terminal when the CLI asks for them.

Telegram

  1. Run in your local terminal:

    tg setup --agent all
  2. On first login, the CLI obtains Telegram application credentials. Enter your phone number and the code sent in Telegram when requested.

  3. On your phone, choose the right Telegram account. Open Settings → Devices → Link Desktop Device and scan the computer’s QR code.

  4. Enter your two-step verification password if requested, then wait for setup to check your account and five chats and install agent skills. It reuses an existing session; history downloads remain a separate choice. For login alone, use tg session start --app auto.

If automatic registration fails, use:

tg session start --app browser

Telegram login instructions explain application credentials, QR and phone login.

Log in to MAX

  1. Run:

    max setup --agent all
  2. On your phone, open MAX → Settings → Devices. Scan the computer’s QR code and confirm the connection.

  3. Follow the terminal prompts. Guided setup checks your account and five chats and installs agent skills. It reuses an existing session; it does not download all history or start the background service. Use max session start qr if you only want to log in.

See MAX login instructions for alternatives, or the bot guide to connect a bot.

Check the connection

Run the command for your messenger:

tg account show
max account show

The response should show your account. Diagnostics may report a missing session before login; that is expected. Repeat the check after login, then list your chats.

3. Connect your agent

Connect your agent gives the steps for all five agents. For Claude Desktop or an MCP connection, continue to MCP and documentation.

Prompt
Summarise my unread messages by chat and tell me who needs an answer.

The CLI command is tg inbox --limit 5 or max inbox --limit 5.

Continue with first tasks: find a past decision, prepare for a meeting and draft a reply. Writing requests provides copyable examples and useful constraints.

Updates and file locations

These belong to each CLI's reference: Telegram installation, MAX installation. If a check fails, see Telegram troubleshooting or MAX troubleshooting.

Terminal commands

For manual installation, you need Node.js 22.16+ (22.x) or 24+ with npm. Download Node.js, open a new terminal and check the versions:

node --version
npm --version

Telegram

Install:

npm install -g @leemour/tg-cli

Version:

tg --version

Diagnostics:

tg doctor

Log in:

tg setup --agent all

Account:

tg account show

First five chats:

tg chats list --limit 5

MAX terminal commands

Install:

npm install -g @leemour/max-cli

Version:

max --version

Diagnostics:

max doctor

Log in:

max setup --agent all

Account:

max account show

First five chats:

max chats list --limit 5

Windows

The agent request above uses npm and asks the agent to install its skill, check PATH and verify the command. It does not download an installation script.

npm creates the command launcher in its global installation folder. On Windows, that folder must be on PATH. An already-running agent must also refresh its own shell environment; changing the saved user PATH does not update an open terminal.

For manual installation, the PowerShell installer below handles PATH and skill installation for you:

& ([scriptblock]::Create((Invoke-RestMethod 'https://wirecat.dev/install.ps1'))) -Tool tg -Agent all
& ([scriptblock]::Create((Invoke-RestMethod 'https://wirecat.dev/install.ps1'))) -Tool max -Agent all

It installs the npm package, preserves existing user PATH entries, updates this PowerShell, installs the agent skill and verifies bare tg or max. No manual PATH editing is needed. The installer completes these steps even when npm skips lifecycle scripts. It keeps the .cmd launcher and removes only npm's generated PowerShell shim for this package; execution policy is unchanged. -Agent codex|cursor|claude|gemini|all|none selects the skill; default is all. An already-running agent refreshes its shell environment itself before subsequent commands. Account login still needs your QR scan or code, entered locally.

On this page