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

Hi and welcome to the group. Before asking any questions, please read the rules from the group's description, and don't forget to read the docs. Make sure you are using the latest version with pip3 install -U telethon, since most problems have already been fixed in newer versions.

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

Telethon Chat

The problem is on the migrate part

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

Telethon Chat

Man this is the code and my purpose is creating a group and making it visible

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

Telethon Chat

download module files from GitHub and feel free to edit

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

Telethon Chat

Do you know what things do I need to change in the code or the module?

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

Telethon Chat

Using int but not worked

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

Telethon Chat

don't pass it as string

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

Telethon Chat

this issue is not related to telethon and it's issue in module or in code (as long your code don't violate tos)

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

Telethon Chat

MigrateChatRequest

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

Telethon Chat

How to change a group to super group using migrateChatRequest and also making a group history visible ? With that one id, chat_id = u.participants.chat_id

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

Telethon Chat

I hope you are trying

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

Telethon Chat

Printing result shows me this

InvitedUsers(
updates=Updates(
updates=[
.
.
.],
users=[User(id....
),User(id...
)],
chats=[Chats(id = ***,.....))],
...

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

Telethon Chat

^exec async
async def CreateChannel(client, title='Aayco', about=None, group=False):
if about is None:
about = str(datetime.now())
try:
result = await client(functions.channels.CreateChannelRequest(
title=title,
about=about,
megagroup=group
))
return True, result.chats[0].id
except:
return False, None

result,chat_id = await CreateChannel(client)

print(chat_id if result else 'Error')

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

Telethon Chat

Same thing i did and try to get the id, through print .it shows me the full thing of the group including users but i am unable to call the group id

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

Telethon Chat

Toggle group to True in order to make groups?

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

Telethon Chat

How to show and purchase this one?

And can i sort them by price or something like that ?

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

Telethon Chat

But that code isn't working, the one i sent

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

Telethon Chat

await client.start()
    result = await client(functions.messages.CreateChatRequest(
        users=['maths_war_bot'],
        title='my awesome title'
    ))
   
    for u in result.updates.updates:
        if isinstance(u,UpdateChatParticipants):
            chat_id2 = u.participants.chat_id
   
    group = client.get_entity(chat_id)
    migrated = client(functions.messages.MigrateChatRequest(
        chat_id=chat_id2
    ))

  
    result2 = client(functions.channels.TogglePreHistoryHiddenRequest(
        channel="-100"+str(chat_id2),
        enabled=False
    ))

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

Telethon Chat

module convert it to int automatically but it should be passed as int

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

Telethon Chat

If it worked it would have shown me like this

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

Telethon Chat

remove this or change to int

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

Telethon Chat

Migrate = client(MigrateChatRequest(
chat_id = str(chat_id))

?

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

Telethon Chat

TogglePreHistoryHiddenRequest

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

Telethon Chat

Hello, has anyone met a problem with freezing acc after starting? If so please react

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

Telethon Chat

Executed Code 👑

from telethon.tl.functions.messages import CreateChatRequest
from telethon.tl.types import UpdateChatParticipants

async def CreateChat(client, title='Aayco', user_ids=None):
    if user_ids is None:
        user_ids = ['unlowly', 'ikilwa']
    try:
        result = await client(CreateChatRequest(users=user_ids, title=title))
        for u in result.updates.updates:
            if isinstance(u, UpdateChatParticipants):
                return True, u.participants.chat_id
        return True, None
    except:
        return False, None

result, chat_id = await CreateChat(client)
print(chat_id if result and chat_id else 'Error')

💙Output:
4713863998

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

Telethon Chat

Yes i appreciate it, but the account is reported and i can't able to create a supergroup or use CreateChannelRequest and also you are creating a group using CreateChannelRequest but i am creating a group using CreateChatRequest

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

Telethon Chat

Executed Code 👑

async def CreateChannel(client, title='Aayco', about=None, group=False):
if about is None:
about = str(datetime.now())
try:
result = await client(functions.channels.CreateChannelRequest(
title=title,
about=about,
megagroup=group
))
return True, result.chats[0].id
except:
return False, None

result,chat_id = await CreateChannel(client)

print(chat_id if result else 'Error')

💙Output:
2891488289

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

Telethon Chat

wait lemme remove one of my chats

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

Telethon Chat

Print result and get id according to the object

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

Telethon Chat

With createchatrequest result.chats[0].id wasn't working

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