#How to fill the “telegram allowFrom (user name or user id)”?I just stuck here

1 messages · Page 1 of 1 (latest)

deft lance
#

How to fill the “telegram allowFrom (user name or user id)”?
I just stuck here

unique krakenBOT
#

To help others find answers, you can mark your question as solved via Right click solution message -> Apps -> ✅ Mark Solution

wanton acornBOT
# deft lance How to fill the “telegram allowFrom (user name or user id)”? I just stuck here

channels.telegram.allowFrom is your (the human sender’s) Telegram user ID (numeric, recommended) or your @usernamenot the bot’s username.

Examples:

channels: {
  telegram: {
    allowFrom: ["123456789"],      // your Telegram user id
    // or: allowFrom: ["@yourname"] // the wizard can often resolve this to an id
  }
}

How to find your Telegram user ID:

  • Safest: start the gateway, DM your bot, then run openclaw logs --follow and look for from.id
  • Also works: DM your bot, then call https://api.telegram.org/bot<BOT_TOKEN>/getUpdates and read message.from.id
deft lance
wanton acornBOT
# deft lance Is there any step should I do before? I just try still not pass

If you mean “I put something in allowFrom but the bot still ignores my DM”, usually one of these is missing:

1) Make sure you’re using your Telegram user ID, not your display name / phone number

  • allowFrom wants numeric from.id (best) or an actual Telegram @username.
  • If your Telegram account has no username set, @something won’t work — use the numeric ID.

2) If dmPolicy is the default (pairing), you must approve the pairing code

With Telegram the default is typically dmPolicy: "pairing" → you DM the bot, it replies with a short code, and you approve it:

openclaw pairing list telegram
openclaw pairing approve telegram <CODE>

Pairing doc: https://docs.openclaw.ai/start/pairing

3) Restart + check logs for the reason it’s blocked