mirror of
https://github.com/wiz0u/WTelegramClient.git
synced 2026-01-03 15:19:57 +01:00
FAQ update
This commit is contained in:
parent
0351ad027f
commit
d0c783ec23
20
FAQ.md
20
FAQ.md
|
|
@ -1,5 +1,6 @@
|
|||
## FAQ
|
||||
|
||||
<a name="remove-logs"></a>
|
||||
#### 1. How to remove the Console logs?
|
||||
|
||||
Writing the library logs to the Console is the default behavior of the `WTelegram.Helpers.Log` delegate.
|
||||
|
|
@ -8,6 +9,7 @@ In any case, it is not recommended to totally ignore those logs because you woul
|
|||
|
||||
Read the [example about logging settings](EXAMPLES.md#change-logging-settings) for how to write logs to a file.
|
||||
|
||||
<a name="multiple-users"></a>
|
||||
#### 2. How to handle multiple user accounts
|
||||
|
||||
The WTelegram.session file contains the authentication keys negociated for the current user.
|
||||
|
|
@ -22,6 +24,7 @@ If you need to manage these user accounts in parallel, you can create multiple i
|
|||
Also please note that the session files are encrypted with your api_hash, so if you change it, the existing session files can't be read anymore.
|
||||
Your api_id/api_hash represents your application, and shouldn't change with each user account the application will manage.
|
||||
|
||||
<a name="GUI"></a>
|
||||
#### 3. How to use the library in a WinForms or WPF application
|
||||
|
||||
The library should work without a problem in a GUI application.
|
||||
|
|
@ -30,6 +33,10 @@ The difficulty might be in your Config callback when the user must enter the ver
|
|||
An easy solution is to call `Interaction.InputBox("Enter verification code")` instead.
|
||||
This might require adding a reference *(and `using`)* to the Microsoft.VisualBasic assembly.
|
||||
|
||||
A more complex solution requires the use of a `ManualResetEventSlim` that you will wait for in Config callback,
|
||||
and when the user has provided the verification_code through your GUI, you "set" the event to release your Config callback so it can return the code.
|
||||
|
||||
<a name="access-hash"></a>
|
||||
#### 4. Where to get the access_hash? Why the error `CHANNEL_INVALID` or `USER_ID_INVALID`?
|
||||
|
||||
An `access_hash` is required by Telegram when dealing with a channel, user, photo, document, etc...
|
||||
|
|
@ -50,6 +57,7 @@ So you can just pass that structure you already have, in place of the `Input...`
|
|||
* If you have enabled the [CollectAccessHash system](EXAMPLES.md#collect-access-hash-and-save-them-for-later-use) at the start of your session, it will have collected the `access_hash`.
|
||||
You can then retrieve it with `client.GetAccessHashFor<User/Channel/Photo/Document>(id)`
|
||||
|
||||
<a name="dev-versions"></a>
|
||||
#### 5. I need to test a feature that has been developed but not yet released in WTelegramClient nuget
|
||||
|
||||
The developmental versions of the library are available through Azure DevOps as part of the Continuous Integration builds after each Github commit.
|
||||
|
|
@ -57,6 +65,7 @@ The developmental versions of the library are available through Azure DevOps as
|
|||
You can access these versions for testing in your program by going to our [private nuget feed](https://dev.azure.com/wiz0u/WTelegramClient/_packaging?_a=package&feed=WTelegramClient&view=overview&package=WTelegramClient&protocolType=NuGet), then click on "Connect to feed" and follow the steps.
|
||||
After that, you should be able to see/install the pre-release versions in your Nuget package manager and install them in your application. *(make sure you enable the **pre-release** checkbox)*
|
||||
|
||||
<a name="test-servers"></a>
|
||||
#### 6. Telegram can't find any chats and asks me to signup (firstname, lastname) even for an existing account
|
||||
This happens when you connect to Telegram Test servers instead of Production servers.
|
||||
On these separate test servers, all created accounts and chats are periodically deleted, so you shouldn't use them under normal circumstances.
|
||||
|
|
@ -70,6 +79,7 @@ If you use the Github source project in an old .NET Framework 4.x or .NET Core x
|
|||
|
||||
To fix this, you should also switch to using the [WTelegramClient Nuget package](https://www.nuget.org/packages/WTelegramClient) as it will install the required dependencies for it to work.
|
||||
|
||||
<a name="prevent-ban"></a>
|
||||
#### 7. How to not get banned from Telegram?
|
||||
|
||||
**Do not share publicly your app's ID and hash!** They cannot be regenerated and are bound to your Telegram account.
|
||||
|
|
@ -97,17 +107,21 @@ Here are some key points:
|
|||
|
||||
If your client displays Telegram channels to the user, you have to support and display [official sponsored messages](https://core.telegram.org/api/sponsored-messages).
|
||||
|
||||
#### 8. I can't import phone numbers. I get error PHONE_NUMBER_BANNED or FLOOD_WAIT_8xxxx
|
||||
<a name="abuse"></a>
|
||||
#### 8. I can't import phone numbers. I get error PHONE_NUMBER_BANNED, FLOOD_WAIT_8xxxx or PEER_FLOOD
|
||||
|
||||
You can get these kind of problems if you abuse Telegram [Terms of Service](https://telegram.org/tos) or https://core.telegram.org/api/terms or make excessive requests.
|
||||
You can get these kind of problems if you abuse Telegram [Terms of Service](https://telegram.org/tos), or the [API Terms of Service](https://core.telegram.org/api/terms), or make excessive requests.
|
||||
|
||||
You can try to wait more between the requests, wait for a day or two to see if the requests become possible again.
|
||||
|
||||
If you think your phone number was banned for a wrong reason, you may try to contact [recover@telegram.org](mailto:recover@telegram.org), explaining what you were doing.
|
||||
An account that was limited due to reported spam might receive PEER_FLOOD errors. Read [Telegram Spam FAQ](https://telegram.org/faq_spam) to learn more.
|
||||
|
||||
If you think your phone number was banned from Telegram for a wrong reason, you may try to contact [recover@telegram.org](mailto:recover@telegram.org), explaining what you were doing.
|
||||
|
||||
In any case, WTelegramClient is not responsible for the bad usage of the library and we are not affiliated to Telegram teams, so there is nothing we can do.
|
||||
|
||||
|
||||
<a name="troubleshoot"></a>
|
||||
## Troubleshooting guide
|
||||
|
||||
Here is a list of common issues and how to fix them so that your program work correctly:
|
||||
|
|
|
|||
Loading…
Reference in a new issue