Story.edit()

Story.edit()

Bound method edit of Story.

Use as a shortcut for:

await client.edit_story(
    story_id=story.id,
    caption="hello"
)

Example

await story.edit_caption("hello")
Parameters:
  • story_id (int) – Unique identifier (int) of the target story.

  • animation (str | BinaryIO, optional) – New story Animation. Pass a file_id as string to send a animation that exists on the Telegram servers, pass an HTTP URL as a string for Telegram to get a animation from the Internet, pass a file path as string to upload a new animation that exists on your local machine, or pass a binary file-like object with its attribute “.name” set for in-memory uploads.

  • photo (str | BinaryIO, optional) – New story photo. Pass a file_id as string to send a photo that exists on the Telegram servers, pass an HTTP URL as a string for Telegram to get a photo from the Internet, pass a file path as string to upload a new photo that exists on your local machine, or pass a binary file-like object with its attribute “.name” set for in-memory uploads.

  • video (str | BinaryIO, optional) – New story video. Pass a file_id as string to send a video that exists on the Telegram servers, pass an HTTP URL as a string for Telegram to get a video from the Internet, pass a file path as string to upload a new video that exists on your local machine, or pass a binary file-like object with its attribute “.name” set for in-memory uploads.

  • privacy (StoriesPrivacyRules, optional) – Story privacy.

  • allowed_users (List of int, optional) – List of user_id whos allowed to view the story.

  • denied_users (List of int, optional) – List of user_id whos denied to view the story.

  • caption (str, optional) – Story caption, 0-1024 characters.

  • parse_mode (ParseMode, optional) – By default, texts are parsed using both Markdown and HTML styles. You can combine both syntaxes together.

  • caption_entities (List of MessageEntity) – List of special entities that appear in the caption, which can be specified instead of parse_mode.

  • media_areas (List of InputMediaArea) – List of media area object to be included in story.

Returns:

On success, the edited Story is returned.

Raises:

RPCError – In case of a Telegram RPC error.