T
T
Text_ADI2020-08-25 12:02:49
Bots
Text_ADI, 2020-08-25 12:02:49

How to send a telegram user's nickname programmatically?

How can a bot send a user's nickname to the user himself? The nickname itself must be in the message that the telegram bot will send. And how else to send a bot nickname? I am using the aiogram library.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
E
Emil Timerbaev, 2020-08-27
@Text_ADI

First question:
name_user = message.from_user.first_name
bot.send_message(message.from_user.id, name_user)
only telebot (library) is needed and
that's it sent a message

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question