Questions tagged [tlsharp]

From library's github page: Unofficial Telegram (http://telegram.org) client library implemented in C#. No longer maintained.

From library's github page:

Unofficial Telegram (http://telegram.org) client library implemented in C#.

No longer maintained.

15 questions
6
votes
0 answers

How to detect edited or deleted messages on telegram TLSharp

I am trying to detect which message is edited or deleted on a subscribed channel on telegram with TLSharp library in c#. 1- in a while(true) loop I am getting latest updates. 2- when I delete or edit a message for test, I receive…
MohaMad
  • 2,575
  • 2
  • 14
  • 26
3
votes
2 answers

TLSharp Fetch Group List Issue

I can't fetch the full list of groups, the response returns only new groups my code : var dialogs = (TLDialogsSlice)await client.GetUserDialogsAsync(); var chats = dialogs.Chats .Where(c => c.GetType() ==…
mzcatcher
  • 61
  • 7
2
votes
1 answer

How to fix UPDATE_APP_TO_LOGIN error in TLSharp C#

Hi i am using TLSharp latest version is 0.1.0.574 and when i call var hash = await client.SendCodeRequestAsync(""); i got error System.InvalidOperationException: 'UPDATE_APP_TO_LOGIN' anyone know how to fix it My code TelegramClient client…
OS Coder
  • 63
  • 9
2
votes
0 answers

TLSharp Not allways imports Telegram contacts

I'm using TLSharp to create a program that imports Telegram contacts. The first tests with 3-4 numbers worked well. But now I'm trying to import 1000 contacts that I know they have Telegram installed and it doesnt' work well. I do it in groups of…
Dalamar
  • 107
  • 1
  • 1
  • 7
1
vote
0 answers

TlSharp uses TlRequestGetParticipants to obtain the maximum number of channel members only 10K. Is there any way to break through this limit

while (offset < (res.FullChat as TLChannelFull).ParticipantsCount) { var pReq = new TLRequestGetParticipants() { Channel = new TLInputChannel() { AccessHash = chat.AccessHash.Value,…
jianwei923
  • 33
  • 5
1
vote
0 answers

TLSharp Telegram Submit Comment

Telegram allows commenting on a channel post or on a generic supergroup message, thanks to message threads. https://core.tlgr.org/api/threads I get the last messages in the channel private async Task GetLastMessage(TLChannel…
WyWyWy
  • 11
  • 1
1
vote
1 answer

TLSharp library able to send message with "bold", "italic"?

I able to send telegram message by using TLsharp library. My question is how to set my message to bold, italic?
1
vote
0 answers

Is TLUser Id/AccessHash never changes?

Can I save TLUser.Id and AccessHash to DB for sending messages later? Is it ever change? Or better to save @username and get Id/AccessHash everytime need to send message?
Igor Golodnitsky
  • 4,456
  • 7
  • 44
  • 67
0
votes
1 answer

How to get notified that new message is sent in specified telegram channel with TLSharp?

I need to handle new messages in specified channel of tg. I think that it is should be possible to do with TLSharp (or telethon on python), but I accept any other method or library. I guess there should be a solution using client for tg RPC Api, but…
0
votes
1 answer

How do I get a list of phone numbers of contacts in TLSharp?

Now I get a list of phone numbers of my contacts through reflection. Is there any other way to do this? var userContacts = await client.GetContactsAsync(); foreach (var user in userContacts.Users) { var props =…
nexus
  • 15
  • 4
0
votes
1 answer

FILEREF_UPGRADE_NEEDED using GetFile function of TLSharp

I'm trying to dowload a file from a conversation in telegram. I`m using TLSharp lib... Please check my code: var result = await client.GetContactsAsync(); var user = result.Users .OfType() …
unaKomika
  • 1
  • 1
0
votes
1 answer

Create a new Telegram channel and fix rights / permissions with TLSharp

I can create a new channel like this, where client is a TLSharp.Core.TelegramClient authenticated and conected: TeleSharp.TL.Channels.TLRequestCreateChannel newChannel = new TeleSharp.TL.Channels.TLRequestCreateChannel(); …
David Con
  • 422
  • 3
  • 5
  • 15
0
votes
1 answer

How to convert TData to TLSharp session?

How to convert TData to TLSharp session ? I got an hex authKey by python script from TData but i cant to create right session file for TLSharp. Can anybody share a code example ?
songof5ky
  • 11
  • 1
0
votes
1 answer

TLSharp: get file

Have error: LIMIT_INVALID Memory Exception? Anybody have worked examples? TLMessageMediaDocument mediaFile = _msg.Media as TLMessageMediaDocument; TLDocument doc = mediaFile.Document as TLDocument; client.GetFile(new TLInputDocumentFileLocation() { …
prishelets
  • 3
  • 1
  • 3
0
votes
1 answer

TLsharp add user to gorup / channel telegram

i could i add user to supergroup / channel using tlsharp i tried: var contacts = new TLVector(); contacts.Add(new TLInputPhoneContact { FirstName = "xxx", LastName = "xxx", Phone = "xxx" }); var req = new…