TLSharp | Telegram client library implemented in C | REST library
kandi X-RAY | TLSharp Summary
kandi X-RAY | TLSharp Summary
Unofficial Telegram (client library implemented in C#. Check out TeleJS - a pure JavaScript implementation of Telegram MTP protocol. It's a perfect fit for any developer who would like to send data directly to Telegram users or write own custom Telegram client.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of TLSharp
TLSharp Key Features
TLSharp Examples and Code Snippets
Community Discussions
Trending Discussions on TLSharp
QUESTION
I'm new to the WTelegramClient C# Library and was used to TLSharp (not working anymore)
I'm trying to understand how I get User info after update is received, I have the example code that listen to updates and write them in console but I can't understand how I can respond to the user that sent the message (new update)
I think I need the user id/access_hash to send message to the sender but I can't understand how
Here is how I get the new messages but it can get only username or name/id
...ANSWER
Answered 2022-Feb-10 at 02:03Below is a quick example on how to modify DisplayMessage
to react to a message sent in private from a user, get the details about this user, verify who it is and which text was sent to us, and then send him a message back.
Notes:
- For this example to work, you will need the latest version of Program_ListenUpdates.cs with static variables
DisplayMessage
is nowasync void
, in order to useawait
- You can pass
user
to send a message because classUser
is implicitly converted toInputPeerUser
(with the user id/access_hash). - You can do similarly for messages coming from chats, using
PeerChat
/PeerChannel
classes and the _chats dictionary to get chat details
QUESTION
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
...ANSWER
Answered 2022-Jan-31 at 21:43The error "UPDATE_APP_TO_LOGIN" happens because your Telegram Client/Library uses an obsolete API layer.
As stated on its project page, TLSharp is no longer maintained and will not be updated to fix this.
You should switch to WTelegramClient which is:
- offering up-to-date API (latest layer)
- safer (latest MTProto v2 implementation and many security checks)
- feature-complete (covers all API methods, handling of updates, multiple-DC connections)
- easy-to-use (API calls are direct methods with fully documented parameters in VS)
- designed for .NET 5.0+, but also available for .NET Standard 2.0 (.NET Framework 4.6.1+ & .NET Core 2.0+)
QUESTION
I found many examples using the bot api, however I need a simple client that implements an event when a message from a contact or group is received, as a user and not a bot (so the Telegram api, and not Bot api). TLSharp library doesn't implement this method. What is the best way to achieve it?
...ANSWER
Answered 2021-Aug-31 at 07:19The provided link is old but it was a good starting point. Here is the updated working code:
QUESTION
I want to reuse existing session file (the phonenumber.session) file,
But I want to change it default path (working directory) to another directory, like '/data/se.session'
There is any option to do that in telethon?
...ANSWER
Answered 2021-May-19 at 15:18After looking at telethon source code, I found this,
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install TLSharp
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page