tgcf icon indicating copy to clipboard operation
tgcf copied to clipboard

error Invalid object ID for a chat when trying to use chat IDs

Open Rinarikato opened this issue 1 year ago • 1 comments

Describe the bug I'm trying to forward messages from a channel to a group using chat IDs on command line tgcf and I got the following error

ChatIdInvalidError: Invalid object ID for a chat. Make sure to pass the right types, for instance making sure that the request is designed for chats (not channels/megagroups) or otherwise look for a different one more suited\nAn example working with a megagroup and AddChatUserRequest, it will fail because megagroups are channels. Use InviteToChannelRequest instead (caused by GetHistoryRequest)

I'm running on Conda environment using Python 3.11.8 on Windows 11 2H11

when I use usernames like @channelexample everything is fine, just the ID's is not working.

I'm using the parameters -l past

Rinarikato avatar Jun 26 '24 12:06 Rinarikato

add -100 before each channel id

cleanerspam avatar Aug 27 '24 06:08 cleanerspam