Skip to content

[Bug]: /reset command confirmation sent to wrong Telegram account in multi-account setup #2038

@madmantim

Description

@madmantim

Summary

In a multi-account Telegram setup, running /reset from a non-default bot sends the "New session started" confirmation message to the default Telegram account instead of the account that received the command.

Steps to reproduce

  1. Configure multiple Telegram accounts:
"telegram": {
  "accounts": {
    "default": { "botToken": "...", "name": "Sugi" },
    "gsw": { "botToken": "...", "name": "Sugi GSW" }
  }
}
  1. Bind a separate agent to the non-default account:
"bindings": [
  { "agentId": "gsw", "match": { "channel": "telegram", "accountId": "gsw" } }
]
  1. Send /reset to the gsw Telegram bot (as an allowlisted user)

  2. Observe where the "New session started · model: X" confirmation appears

Expected behavior

The reset confirmation should be delivered through the gsw Telegram bot (the same bot that received the /reset command).

Actual behavior

The reset confirmation is delivered through the default Telegram bot, appearing in the wrong chat.

Note: The actual session reset works correctly (only the target agent's session is reset). The bug is specifically in the confirmation message delivery routing.

Environment

  • Clawdbot version: 2026.1.24-3
  • OS: macOS (Darwin 25.2.0 arm64)
  • Install method: npm global

Related Issues

This appears to be the same class of bug as #1058 — the accountId from the incoming command context is not being threaded through to the confirmation message delivery.

Notes

  • Inbound message routing works correctly (messages to gsw bot route to agent:gsw:* sessions)
  • The confirmation shows the correct agent's model (e.g., claude-sonnet-4-5 for gsw), but is delivered to wrong bot
  • Likely fix location: wherever /reset command confirmation is sent, it needs to respect the incoming accountId

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions