Skip to content

miniproto.auth.service.AuthService.handle_dc_migration

miniproto.auth.service.AuthService.handle_dc_migration

Section titled “miniproto.auth.service.AuthService.handle_dc_migration”
handle_dc_migration(error: DatacenterMigration) -> types.AuthExportedAuthorization | None

Persist Telegram’s requested DC migration and export user authorization when needed.

An unauthenticated session only changes its target DC. An authenticated session also obtains an exported authorization, which the caller must import through a sender for the target DC.

Parameters:

  • error (DatacenterMigration) – Classified Telegram migration response with the target dc_id.

Returns:

Raises: