send_paid_media()

Client.send_paid_media()

Use this method to send paid media.

Usable by Users Bots
Parameters:
  • chat_id (int | str) – Unique identifier for the target chat or username of the target channel (in the format @channelusername).

  • star_count (int) – The number of Telegram Stars that must be paid to buy access to the media.

  • media (List of InputPaidMedia) – A list describing the media to be sent; up to 10 items.

  • caption (str, optional) – Media caption, 0-1024 characters after entities parsing.

  • 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.

  • show_caption_above_media (bool, optional) – Pass True, if the caption must be shown above the message media.

  • disable_notification (bool, optional) – Sends the message silently. Users will receive a notification with no sound.

  • protect_content (bool, optional) – Pass True if the content of the message must be protected from forwarding and saving; for bots only.

  • business_connection_id (str, optional) – Unique identifier of the business connection on behalf of which the message will be sent.

  • schedule_date (datetime, optional) – Date when the message will be automatically sent. Pass a datetime object.

Returns:

Message – On success, the sent message is returned.