telethonchat | Unsorted

Telegram-канал telethonchat - Telethon Chat

6095

Official Telethon's chat! Rules: • Speak English • Stay on topic (questions about Telethon) • Be respectful • Don't ask to ask • Spam-related uses lead to ban • Read https://docs.telethon.dev before asking things here Read more about us @TelethonUpdates

Subscribe to a channel

Telethon Chat

they don't have any groups to ask questions so I thought I take my chances here at least

Читать полностью…

Telethon Chat

this chat is for telethon-related questions only

Читать полностью…

Telethon Chat

anyone worked with aiogram before? Why is it so hard to work with?

Читать полностью…

Telethon Chat

Maybe making it objective shall fix?

Читать полностью…

Telethon Chat

telethon/crypto/rsa.py:52:5: F824 global _server_keys is unused: name is never assigned in scope
global _server_keys
^
telethon/crypto/rsa.py:68:5: F824 global _server_keys is unused: name is never assigned in scope
global _server_keys
^
2 F824 global _server_keys is unused: name is never assigned in scope
4

I saw this error either, but didn't know how to fix since everything looked fine.

Читать полностью…

Telethon Chat

Hey guys, i have started using Telethon2, it is great, works exactly how i want it to be for my usecases. I want to get groups and channels which arenot archived, but the getDialogs return all, can you please guide me in this regard because i am very stuck

Читать полностью…

Telethon Chat

/channel/TelethonChat/645846

Читать полностью…

Telethon Chat

Guys, maybe someone knows how to organize the purchase of gifts for telegram users? Is there any method in telethon? So that I specify a unique gift ID and it is sent to the user for my stars from the account balance

Читать полностью…

Telethon Chat

🤷‍♀️ IDK just ask sth

Читать полностью…

Telethon Chat

Check the ToS and API ToS of Telegram yourself, but who cares when even if you break them nothing happens?

Actually as far as I know , getChannelDifference doesn't break the law, so you're totally free to do such things.

Читать полностью…

Telethon Chat

Calling raw requests and getting output of them is so simple , the TelegramClient class defines the coroutine __call__ itself, and takes (request, ordered,flood_sleep_threshold) arguments that you do not need any other than the first one for usual.

So when you define your client ( that needs to be connected, and some requests require authorization ) you'll be able to call requests this way:

output = await client(Request())# for one request
outputs = await client([RequestOne(),RequestTwo()])
# you may pass requests in any list-like object, and now you can take advantage of the ordered parameter ( I guess, maybe not implemented )

Real examples for some webapp actions:

from telethon.tl.functions.messages import RequestWebViewRequest 
AuthorizedUrl = await client(RequestWebViewRequest(botpeer, botpeer, platform='android', url=url))

Pay attention to requests __init__ functions and that you need to "await".
Read telethon raw api page here.

Читать полностью…

Telethon Chat

maybe he will got kick automatically

Читать полностью…

Telethon Chat

i mean you will need to reply on his message if you meet him in group or something like that to cache his entity

Читать полностью…

Telethon Chat

you have to chat with this user even once

Читать полностью…

Telethon Chat

GetPinnedStories isn't for literally pinned stories.

Читать полностью…

Telethon Chat

but damn telethon is way easier to work with

Читать полностью…

Telethon Chat

I've forked a repo that has used aiogram and am now stuck with it

Читать полностью…

Telethon Chat

I'll try and make a pull request if worked

Читать полностью…

Telethon Chat

iter_dialogs(limit: float = None, *, offset_date: hints.DateLike = None, offset_id: int = 0, offset_peer: hints.EntityLike = <telethon.tl.types.InputPeerEmpty object>, ignore_pinned: bool = False, ignore_migrated: bool = False, folder: int = None, archived: bool = None)→ _DialogsIter

Читать полностью…

Telethon Chat

Wrong chat,
@TelethonV2

Telethon v2 is not ready yet as far as lonami acknowledged

Читать полностью…

Telethon Chat

@dakozoff

You better take a look at @Tonnel_Network_bot either

Читать полностью…

Telethon Chat

Send gift nft where the document is

Читать полностью…

Telethon Chat

Is it something new?

Читать полностью…

Telethon Chat

@Voiro dm

Читать полностью…

Telethon Chat

Be more specific for what you want, then you'll be responded with the requests you need.

Читать полностью…

Telethon Chat

hello everyone, guys, can I use telethon for commercial use so that the user-bot gets some statistics from public channels, as tgstat does, to the extent that it does not legally contradict tg?

Читать полностью…

Telethon Chat

does anyone know what happen there's no enough balance of stars with user for next month subscription after joining via subscription link

Читать полностью…

Telethon Chat

the the id is unknow I cannot do a send_message request, it returns same value error

Читать полностью…

Telethon Chat

Is there any way to get an user entity via the id?
https://docs.telethon.dev/en/stable/concepts/entities.html

on the doc it says to get the dialogs or get chat participants to cache the entities but the I only have the entity id and their not in any group or not in the chat list is it possible to get this user?

ValueError: Could not find the input entity for PeerUser(user_id=6648562231) (PeerUser). Please read https://docs.telethon.dev/en/stable/concepts/entities.html to find out more details.


I get value error when I try to find an unknown entity with just ID

Читать полностью…

Telethon Chat

I’m having trouble pulling all of the stories from a user

GetAllStoriesRequest - pulls your contact’s stories

GetPeerStoriesRequest - pulls active stories from a peer

GetPinnedStoriesRequest - pulls pinned stories from a peer

GetStoriesArchiveRequest - pulls old stories from you or your channel

How can I pull old non pinned stories from a peer? I feel like I’m missing something

Читать полностью…
Subscribe to a channel