recover_gaps()

async Client.recover_gaps()

Restores updates for the time while the client was offline.

Note

To use this method, you must set the Client.skip_updates and Client.in_memory parameter to False, otherwise updates state saving and recovery will not work.

Usable by Users Bots
Parameters:

ids (int | Iterable of int, optional) – Identifiers of the chats to recover, 0 for private chats and other updates. By default, every known chat is recovered.

Returns:

tuple – The number of messages and updates recovered is returned.