-1

i need to create a command in my userbot that if the user use it his username will be (normal username) + ONLINE. Im trying to use get_me() for getting the username but i get all the infos. I need only username... How i can do this?

Tibebes. M
  • 6,940
  • 5
  • 15
  • 36
null.user
  • 1
  • 1

1 Answers1

0

get_me() should return a dictionary like this:

{'first_name': 'Your Bot', 'username': 'YourBot', 'id': 123456789}

You can access the values of a dictionary with the corresponding key. If you want the username, it would look like this:

get_me()['username']
Chrissu
  • 382
  • 1
  • 13