Introduction

When running agents with DeepSeek Harness (DSH), events such as task completion, agent questions, tool approval requests, and long-term goal status changes can occur asynchronously. If a person is not present at the terminal, it is easy to miss nodes requiring manual input.

Below is introduced emiliagarfield6-bot/dsh-telegram-notify. It is a Telegram notification plugin for DSH, used to send reminders to Telegram when events occur.

What is it

dsh-telegram-notify is maintained by emiliagarfield6-bot and is licensed under MIT.

Its positioning is: to forward key events during DSH agent execution as Telegram messages, including:

  • Task completion
  • Agent questions
  • Request tool approval
  • Long-term goal completion or blocked

Core Features

Below are the verified functional points.

Trigger Timing

The plugin sends Telegram notifications when the following events occur:

  1. The agent returns from running to idle, i.e., task completion.
  2. The agent calls ask_user_question, requiring user input.
  3. The agent requests tool approval.
  4. Long-term goal completion or blocked.

Notification Noise Reduction

To avoid unnecessary interruptions, the plugin has two types of restrictions:

  1. Only the root session triggers notifications; child agent endings do not trigger notifications.
  2. No notification if the run duration is less than minRunSeconds; there is a debounce after returning to idle.

Notification Modes

The plugin supports concise mode and complex mode.

  1. Concise mode: Only notifies task results.
  2. Complex mode: In addition to the result, includes task duration, token consumption, and cache hit rate.
  3. sendTaskContent: Default is off. When enabled, in complex mode, it can include the final output content of this round.

Installation and Enablement

First, obtain the plugin source code. The installation command below is provided by verified information.

Execute in the plugin source code directory:

dsh plugin --profile web add .

Execute from any directory; you need to provide the package path:

dsh plugin --profile web add file:/absolute/path/dsh-telegram-notify

The file: dependency is packaged and copied during installation. After modifying source code, you need to re-run dsh plugin add for changes to take effect.

If you want to modify and use directly in the source code directory, you can use the symbolic link method:

dsh plugin --profile web add link:<path>

Uninstall can be executed:

dsh plugin --profile web remove dsh-telegram-notify

Configuration

There are two entry points for configuration: the DSH Settings page, or the profile’s cordis.patch.yml.

Getting Telegram Configuration

  1. Find @BotFather in Telegram to create a bot and obtain the token.
  2. Send a message to the bot to get the chat ID via @userinfobot.
  3. You can also get the chat ID by accessing the following interface:
https://api.telegram.org/bot<token>/getUpdates

Configuring in Settings Page

Navigate to:

Settings > Plugins > Plugin Config > telegram-notify

Fill in token and chatId. For domestic networks, you can fill in proxy together, or use apiBase as a reverse proxy address.

You can also configure:

  • sendTaskContent
  • minRunSeconds
  • Notification modes
  • Various notification toggles

The token field is declared as secret. The settings page only writes and does not read, so it will not be returned in plaintext.

Configuring in Profile

You can also configure in the profile’s cordis.patch.yml:

- id: telegram-notify
  config:
    token: "123456:ABC..."
    chatId: "123456789"
    proxy: "http://127.0.0.1:7890"

Note: DSH’s patch config performs a full replacement, not a deep merge. When overwriting configuration, you must include all fields to be set; fields not listed will use the plugin’s default values.

Configuration Priority

Configuration priority from high to low is:

  1. The telegram-notify namespace in the settings page
  2. The config in profile cordis.patch.yml
  3. Environment variables TELEGRAM_BOT_TOKEN / TELEGRAM_CHAT_ID
  4. Schema default values

Restart After First Configuration

After the first configuration, close DSH and restart:

dsh web

After successful startup, you will receive a reminder “DSH Telegram Notification Online”. If no notification is sent, check the failure records in the DSH logs.

Typical Usage

After the above steps, the common usage is as follows.

  1. Receive notification when task completes.
    Applicable to scenarios where the agent returns from running to idle.

  2. Receive notification when agent asks question.
    Applicable to scenarios where the agent calls ask_user_question and waits for an answer.

  3. Receive notification when requesting tool approval.
    Applicable to scenarios where the agent requests tool approval and waits for manual processing.

  4. Receive notification when long-term goal status changes.
    Includes long-term goal completion or blocked.

  5. When more information is needed, use complex mode.
    Complex mode includes task duration, token consumption, and cache hit rate.

  6. When you need to view the final output of this round, turn on sendTaskContent.
    This configuration is disabled by default and only takes effect in complex mode.

Suitable Scenarios and Notes

Who is it suitable for

This plugin is suitable for the following situations:

  1. DSH tasks run for a long time, and it is inconvenient for people to stay by the terminal.
  2. Hope to receive reminders immediately when agent asks questions, requests approval, or long-term goal status changes.
  3. Using the Telegram API in a domestic network environment, requiring configuration of proxy or apiBase.
  4. Hope that notification failure does not affect the agent’s main process.

Notes

  1. The plugin runs with the current dsh process permissions; you should check the source code and license before installation.
  2. Notification is fire-and-forget; failure only logs, and does not affect the agent’s main process.
  3. Under a domestic network, api.telegram.org cannot be connected directly; you need to set proxy or use apiBase as a reverse proxy address.
  4. file: installation involves packaging and copying at installation time; modifying source code requires re-running add to take effect.
  5. Runtime environment requirements:
Node.js ^22.19.0 || >=24.0.0
@deepseek-ai/schemastery >=3.18.0

Conclusion

If your DSH tasks often need to leave the terminal, dsh-telegram-notify provides a minimal closed loop: sending task completion, questions, approvals, and long-term goal status to Telegram.

Related Links:

  • GitHub: https://github.com/emiliagarfield6-bot/dsh-telegram-notify
  • Community directory: Can be searched for dsh-telegram-notify in the independent community directory.