Node-telegram-bot-api: Get user ID by username?

Created on 18 Jul 2017  路  7Comments  路  Source: yagop/node-telegram-bot-api

is there a way to get the user id using the username?

question

Most helpful comment

You may want to look at https://github.com/kamikazechaser/tg-resolve or
https://github.com/GochoMugo/tgfancy (Addon to node-telegram-bot-api by @GochoMugo which has tg-resolve included)

All 7 comments

Using the official Telegram Bot API, there is no clear way to do that. However, if the bot has an open chat with the user, you may use the getChatMember method.

Also, you may want to take a look at https://github.com/kamikazechaser/tg-resolve.

You may want to look at https://github.com/kamikazechaser/tg-resolve or
https://github.com/GochoMugo/tgfancy (Addon to node-telegram-bot-api by @GochoMugo which has tg-resolve included)

thank you guys It works but its very slow
to resolve a username I need to wait 3 minutes

@mnb3000 @GochoMugo
guys tg-resolve is not working, do you have some alternatives to it? I need it in my bot

This is a long shot but you could run your own instance of PWRTelegram. Some time back, we had an issue with load on the primary server.

Closing this issue as the original question has been answered. Feel free to continue with the discussion.


CLOSE

ANS: https://github.com/yagop/node-telegram-bot-api/issues/383#issuecomment-316770512

@abbddo tg-resolve isnt working, did you find a solution?

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Panthro picture Panthro  路  3Comments

Dohoon-Kim picture Dohoon-Kim  路  3Comments

dimawebmaker picture dimawebmaker  路  3Comments

hems picture hems  路  3Comments

qunatumwhiskey picture qunatumwhiskey  路  4Comments