S
S
Sergey Rogozhkin2016-08-11 16:59:46
PHP
Sergey Rogozhkin, 2016-08-11 16:59:46

Login through a telegram bot, who binds users how?

There is a website with a user base and a personal account. A small part indicated a phone number and confirmed it, but a large part did not. I want to add the ability to interact with the site through the bot.
How to understand who is who? Is it safe to ask for username and password in chat? Are there reliable scenarios?
In general, the login and phone in Telegram do not match the login / phone. in the site database. Some users access the site from mobile devices where the Telegram client is installed. Most use it from the desktop and only know the username/password. Some enter through social networks and do not even know their login. The bot will be found by a name that is remembered, written on a business card, advertised offline (deeplinking is not very suitable).
The user finds the bot, starts and says "I'm already your client." Further it is necessary to identify and remember.
How would you advise to arrange user binding? Thank you.

Answer the question

In order to leave comments, you need to log in

3 answer(s)
O
OnYourLips, 2016-08-11
@thecoder

Give a link to the site, which will link the account in the telegram to the account on the site.

M
mrgyf1, 2016-10-21
@mrgyf1

How did the author accomplish the task? Very interesting!

S
Sergey Rogozhkin, 2020-04-01
@thecoder

My everyday version, which covers only part of the scenarios: in my account there is a "connect bot" button that generates a connection code and displays the instruction "activate the bot and enter the code."
You can follow the link to the bot or find it manually on the phone by name. Entering the code in the bot itself can be a separate command or even the only command for notifier bots. Until they are connected, the status "code 123-456-789 issued, waiting for confirmation in the bot" hangs in the office.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question