0

Is it possible to get the chat_id directly without using the telegram client ?

We have a mobile contact list and we would like to get the chat_id of each one.

Regards

Fran Rod
  • 586
  • 4
  • 14
  • 26

1 Answers1

0

ok, deeping insside the api doc, I have found a way to get it. It's sharing the contact with the bot, so you get a response from the api. The url method is like this:

 https://api.telegram.org/botTOKEN/sendContact?chat_id=CHATID&phone_number=PHONENUMBER&first_name=NAME
Fran Rod
  • 586
  • 4
  • 14
  • 26