Skip to content

Commit d35afa0

Browse files
committed
Docstrings fix: parameters optionality and text
1 parent d058e1a commit d35afa0

3 files changed

Lines changed: 77 additions & 77 deletions

File tree

‎telebot/__init__.py‎

Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1876,7 +1876,7 @@ def send_message(
18761876
:param callback_query_id: Deprecated. Use ephemeral_message_parameters instead.
18771877
:type callback_query_id: :obj:`str`
18781878

1879-
:param ephemeral_message_parameters: Parameters of the ephemeral message to send.
1879+
:param ephemeral_message_parameters: Optional. A JSON-serialized object containing the parameters of the ephemeral message to send
18801880
:type ephemeral_message_parameters: :class:`telebot.types.EphemeralMessageParameters`
18811881

18821882
:param suggested_post_parameters: A JSON-serialized object containing the parameters of the suggested post to send;
@@ -2669,7 +2669,7 @@ def send_photo(
26692669
:param callback_query_id: Deprecated. Use ephemeral_message_parameters instead.
26702670
:type callback_query_id: :obj:`str`
26712671

2672-
:param ephemeral_message_parameters: Parameters of the ephemeral message to send.
2672+
:param ephemeral_message_parameters: Optional. A JSON-serialized object containing the parameters of the ephemeral message to send
26732673
:type ephemeral_message_parameters: :class:`telebot.types.EphemeralMessageParameters`
26742674

26752675
:return: On success, the sent Message is returned.
@@ -2732,7 +2732,7 @@ def send_live_photo(
27322732
:param message_thread_id: Identifier of a message thread, in which the message will be sent
27332733
:type message_thread_id: :obj:`int`
27342734

2735-
:param direct_messages_topic_id: Identifier of the direct messages topic to which the message will be sent; required if the message is sent to a direct messages chat
2735+
:param direct_messages_topic_id: Optional. Identifier of the direct messages topic to which the message will be sent; required if the message is sent to a direct messages chat
27362736
:type direct_messages_topic_id: :obj:`int`
27372737

27382738
:param business_connection_id: Unique identifier of the business connection on behalf of which the message will be sent
@@ -2790,7 +2790,7 @@ def send_live_photo(
27902790
:type reply_markup: :class:`telebot.types.InlineKeyboardMarkup` or :class:`telebot.types.ReplyKeyboardMarkup` or :class:`telebot.types.ReplyKeyboardRemove`
27912791
or :class:`telebot.types.ForceReply`
27922792

2793-
:param ephemeral_message_parameters: Parameters of the ephemeral message to send
2793+
:param ephemeral_message_parameters: Optional. A JSON-serialized object containing the parameters of the ephemeral message to send
27942794
:type ephemeral_message_parameters: :class:`telebot.types.EphemeralMessageParameters`
27952795

27962796
:return: On success, the sent Message is returned.
@@ -2932,7 +2932,7 @@ def send_audio(
29322932
:param callback_query_id: Deprecated. Use ephemeral_message_parameters instead.
29332933
:type callback_query_id: :obj:`str`
29342934

2935-
:param ephemeral_message_parameters: Parameters of the ephemeral message to send.
2935+
:param ephemeral_message_parameters: Optional. A JSON-serialized object containing the parameters of the ephemeral message to send
29362936
:type ephemeral_message_parameters: :class:`telebot.types.EphemeralMessageParameters`
29372937

29382938
:return: On success, the sent Message is returned.
@@ -3075,7 +3075,7 @@ def send_voice(
30753075
:param callback_query_id: Deprecated. Use ephemeral_message_parameters instead.
30763076
:type callback_query_id: :obj:`str`
30773077

3078-
:param ephemeral_message_parameters: Parameters of the ephemeral message to send.
3078+
:param ephemeral_message_parameters: Optional. A JSON-serialized object containing the parameters of the ephemeral message to send
30793079
:type ephemeral_message_parameters: :class:`telebot.types.EphemeralMessageParameters`
30803080

30813081
:return: On success, the sent Message is returned.
@@ -3229,7 +3229,7 @@ def send_document(
32293229
:param callback_query_id: Deprecated. Use ephemeral_message_parameters instead.
32303230
:type callback_query_id: :obj:`str`
32313231

3232-
:param ephemeral_message_parameters: Parameters of the ephemeral message to send.
3232+
:param ephemeral_message_parameters: Optional. A JSON-serialized object containing the parameters of the ephemeral message to send
32333233
:type ephemeral_message_parameters: :class:`telebot.types.EphemeralMessageParameters`
32343234

32353235
:return: On success, the sent Message is returned.
@@ -3376,7 +3376,7 @@ def send_sticker(
33763376
:param callback_query_id: Deprecated. Use ephemeral_message_parameters instead.
33773377
:type callback_query_id: :obj:`str`
33783378

3379-
:param ephemeral_message_parameters: Parameters of the ephemeral message to send.
3379+
:param ephemeral_message_parameters: Optional. A JSON-serialized object containing the parameters of the ephemeral message to send
33803380
:type ephemeral_message_parameters: :class:`telebot.types.EphemeralMessageParameters`
33813381

33823382
:return: On success, the sent Message is returned.
@@ -3563,7 +3563,7 @@ def send_video(
35633563
:param callback_query_id: Deprecated. Use ephemeral_message_parameters instead.
35643564
:type callback_query_id: :obj:`str`
35653565

3566-
:param ephemeral_message_parameters: Parameters of the ephemeral message to send.
3566+
:param ephemeral_message_parameters: Optional. A JSON-serialized object containing the parameters of the ephemeral message to send
35673567
:type ephemeral_message_parameters: :class:`telebot.types.EphemeralMessageParameters`
35683568

35693569
:return: On success, the sent Message is returned.
@@ -3741,7 +3741,7 @@ def send_animation(
37413741
:param callback_query_id: Deprecated. Use ephemeral_message_parameters instead.
37423742
:type callback_query_id: :obj:`str`
37433743

3744-
:param ephemeral_message_parameters: Parameters of the ephemeral message to send.
3744+
:param ephemeral_message_parameters: Optional. A JSON-serialized object containing the parameters of the ephemeral message to send
37453745
:type ephemeral_message_parameters: :class:`telebot.types.EphemeralMessageParameters`
37463746

37473747
:return: On success, the sent Message is returned.
@@ -3890,7 +3890,7 @@ def send_video_note(
38903890
:param callback_query_id: Deprecated. Use ephemeral_message_parameters instead.
38913891
:type callback_query_id: :obj:`str`
38923892

3893-
:param ephemeral_message_parameters: Parameters of the ephemeral message to send.
3893+
:param ephemeral_message_parameters: Optional. A JSON-serialized object containing the parameters of the ephemeral message to send
38943894
:type ephemeral_message_parameters: :class:`telebot.types.EphemeralMessageParameters`
38953895

38963896
:return: On success, the sent Message is returned.
@@ -4217,7 +4217,7 @@ def send_location(
42174217
:param callback_query_id: Deprecated. Use ephemeral_message_parameters instead.
42184218
:type callback_query_id: :obj:`str`
42194219

4220-
:param ephemeral_message_parameters: Parameters of the ephemeral message to send.
4220+
:param ephemeral_message_parameters: Optional. A JSON-serialized object containing the parameters of the ephemeral message to send
42214221
:type ephemeral_message_parameters: :class:`telebot.types.EphemeralMessageParameters`
42224222

42234223
:return: On success, the sent Message is returned.
@@ -4476,7 +4476,7 @@ def send_venue(
44764476
:param callback_query_id: Deprecated. Use ephemeral_message_parameters instead.
44774477
:type callback_query_id: :obj:`str`
44784478

4479-
:param ephemeral_message_parameters: Parameters of the ephemeral message to send.
4479+
:param ephemeral_message_parameters: Optional. A JSON-serialized object containing the parameters of the ephemeral message to send
44804480
:type ephemeral_message_parameters: :class:`telebot.types.EphemeralMessageParameters`
44814481

44824482
:return: On success, the sent Message is returned.
@@ -4607,7 +4607,7 @@ def send_contact(
46074607
:param callback_query_id: Deprecated. Use ephemeral_message_parameters instead.
46084608
:type callback_query_id: :obj:`str`
46094609

4610-
:param ephemeral_message_parameters: Parameters of the ephemeral message to send.
4610+
:param ephemeral_message_parameters: Optional. A JSON-serialized object containing the parameters of the ephemeral message to send
46114611
:type ephemeral_message_parameters: :class:`telebot.types.EphemeralMessageParameters`
46124612

46134613
:return: On success, the sent Message is returned.
@@ -4679,10 +4679,10 @@ def send_message_draft(
46794679
:param entities: A JSON-serialized list of special entities that appear in message text, which can be specified instead of parse_mode
46804680
:type entities: :obj:`list` of :class:`telebot.types.MessageEntity
46814681

4682-
:param can_stop: Optional. Pass True if the user can stop message generation
4682+
:param can_stop: Optional. Pass True to show the user a button to stop further drafts. The bot will receive an Update “stopped_message_generation” if the user presses the button.
46834683
:type can_stop: :obj:`bool`
46844684

4685-
:param keep_on_stop: Optional. Pass True if the generated message must be kept after the user stops generation
4685+
:param keep_on_stop: Optional. Pass True to keep the draft in the chat when the button is pressed. The draft will still disappear after a short time or if the bot sends a message. To fully preserve the partial draft, the bot should send it as a new message.
46864686
:type keep_on_stop: :obj:`bool`
46874687

46884688
:return: Returns True on success.
@@ -4750,7 +4750,7 @@ def send_rich_message(
47504750
:param direct_messages_topic_id: Identifier of the direct messages topic to which the message will be sent; required if the message is sent to a direct messages chat
47514751
:type direct_messages_topic_id: :obj:`int`
47524752

4753-
:param ephemeral_message_parameters: Parameters of the ephemeral message to send
4753+
:param ephemeral_message_parameters: Optional. A JSON-serialized object containing the parameters of the ephemeral message to send
47544754
:type ephemeral_message_parameters: :class:`telebot.types.EphemeralMessageParameters`
47554755

47564756
:return: On success, the sent Message is returned.
@@ -4793,10 +4793,10 @@ def send_rich_message_draft(
47934793
:param message_thread_id: Unique identifier for the target message thread
47944794
:type message_thread_id: :obj:`int`
47954795

4796-
:param can_stop: Optional. Pass True if the user can stop message generation
4796+
:param can_stop: Optional. Pass True to show the user a button to stop further drafts. The bot will receive an Update “stopped_message_generation” if the user presses the button.
47974797
:type can_stop: :obj:`bool`
47984798

4799-
:param keep_on_stop: Optional. Pass True if the generated message must be kept after the user stops generation
4799+
:param keep_on_stop: Optional. Pass True to keep the draft in the chat when the button is pressed. The draft will still disappear after a short time or if the bot sends a message. To fully preserve the partial draft, the bot should send it as a new message.
48004800
:type keep_on_stop: :obj:`bool`
48014801

48024802
:return: Returns True on success.
@@ -5099,7 +5099,7 @@ def promote_chat_member(
50995099
:param can_delete_stories: Pass True if the administrator can delete the channel's stories
51005100
:type can_delete_stories: :obj:`bool`
51015101

5102-
:param can_send_welcome_messages: Pass True if the administrator can manage or send chat welcome messages
5102+
:param can_send_welcome_messages: Optional. Pass True if the administrator can manage chat welcome messages or directly send them in the case of bots
51035103
:type can_send_welcome_messages: :obj:`bool`
51045104

51055105
:param can_manage_direct_messages: Pass True if the administrator can manage direct messages
@@ -7020,7 +7020,7 @@ def edit_ephemeral_message_text(
70207020
:param entities: A JSON-serialized list of special entities that appear in message text, which can be specified instead of parse_mode
70217021
:type entities: :obj:`list` of :obj:`MessageEntity`
70227022

7023-
:param rich_message: New rich content of the message; required if text isn't specified
7023+
:param rich_message: Optional. New rich content of the message; required if text isn't specified
70247024
:type rich_message: :obj:`InputRichMessage`
70257025

70267026
:param link_preview_options: Link preview generation options for the message
@@ -7101,7 +7101,7 @@ def edit_ephemeral_message_caption(
71017101
:param caption_entities: A JSON-serialized list of special entities that appear in the caption, which can be specified instead of parse_mode
71027102
:type caption_entities: :obj:`list` of :obj:`MessageEntity`
71037103

7104-
:param show_caption_above_media: Pass True if the caption must be shown above the message media. Supported only for animation, photo and video messages.
7104+
:param show_caption_above_media: Optional. Pass True if the caption must be shown above the message media. Supported only for animation, photo and video messages.
71057105
:type show_caption_above_media: :obj:`bool`
71067106

71077107
:param reply_markup: A JSON-serialized object for an inline keyboard

0 commit comments

Comments
 (0)