get_peer_stories()

Client.get_peer_stories()

Get all active stories from an user/channel by using user identifiers.

Usable by Users Bots
Parameters:

chat_id (int | str) – Unique identifier (int) or username (str) of the target user/channel. For your personal story you can simply use “me” or “self”. For a contact that exists in your Telegram address book you can use his phone number (str). You can also use user profile/channel public link in form of t.me/<username> (str).

Returns:

Generator – On success, a generator yielding Story objects is returned.

Example

# Get all active story from spesific user/channel
async for story in app.get_peer_stories(chat_id):
    print(story)
Raises:

ValueError – In case of invalid arguments.