stop_message_live_location()

async Client.stop_message_live_location()

Stop updating a live location message before its live_period expires.

Either chat_id + message_id or inline_message_id must be provided.

Usable by Users Bots
Parameters:
  • chat_id (int | str, optional) – Unique identifier (int) or username (str) of the target chat.

  • message_id (int, optional) – Identifier of the live location message to stop.

  • inline_message_id (str, optional) – Identifier of the inline live location message to stop.

  • reply_markup (InlineKeyboardMarkup, optional) – A new inline keyboard to replace the current one. Pass None to remove the existing reply markup.

  • business_connection_id (str, optional) – Unique identifier of the business connection.

Returns:

Message | bool – On success, the edited Message is returned. For inline messages, True is returned.

Example

# Stop a live location
await app.stop_message_live_location(chat_id, message_id)