Telebot 9.4
Library for Telegram bot API
Loading...
Searching...
No Matches
telebot-methods.h
Go to the documentation of this file.
1/*
2 * telebot
3 *
4 * Copyright (c) 2015 Elmurod Talipov.
5 *
6 * Licensed under the Apache License, Version 2.0 (the License);
7 * you may not use this file except in compliance with the License.
8 * You may obtain a copy of the License at
9 *
10 * http://www.apache.org/licenses/LICENSE-2.0
11 *
12 * Unless required by applicable law or agreed to in writing, software
13 * distributed under the License is distributed on an "AS IS" BASIS,
14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15 * See the License for the specific language governing permissions and
16 * limitations under the License.
17 */
18
19#ifndef __TELEBOT_METHODS_H__
20#define __TELEBOT_METHODS_H__
21
22#include <stdbool.h>
23#include "telebot-common.h"
24#include "telebot-types.h"
25#include "telebot-core.h"
26
27#ifdef __cplusplus
28extern "C" {
29#endif
30
57
69
79telebot_error_e telebot_set_proxy(telebot_handler_t handle, char *addr, char *auth);
80
91
114 int limit, int timeout, telebot_update_type_e allowed_updates[],
115 int allowed_updates_count, telebot_update_t **updates, int *count);
116
126
127
150 char *certificate, int max_connections,telebot_update_type_e allowed_updates[],
151 int allowed_updates_count);
152
162
163
175
185
196
205
213
232 const char *text, const char *parse_mode, bool disable_web_page_preview,
233 bool disable_notification, int reply_to_message_id, const char *reply_markup);
234
249 long long int from_chat_id, bool disable_notification, int message_id);
250
272 const char *photo, bool is_file, const char *caption, const char *parse_mode,
273 bool disable_notification, int reply_to_message_id, const char *reply_markup);
274
275
309 const char *audio, bool is_file, const char *caption, const char *parse_mode,
310 int duration, const char *performer, const char *title, const char *thumb,
311 bool disable_notification, int reply_to_message_id, const char *reply_markup);
312
337 const char *document, bool is_file, const char *thumb, const char *caption,
338 const char *parse_mode, bool disable_notification, int reply_to_message_id,
339 const char *reply_markup);
340
370 const char *video, bool is_file, int duration, int width, int height,
371 const char *thumb, const char *caption, const char *parse_mode,
372 bool supports_streaming, bool disable_notification, int reply_to_message_id,
373 const char *reply_markup);
374
401 const char *animation, bool is_file, int duration, int width, int height,
402 const char *thumb, const char *caption, const char *parse_mode,
403 bool disable_notification, int reply_to_message_id, const char *reply_markup);
404
405
428 const char *voice, bool is_file, const char *caption, const char *parse_mode,
429 int duration, bool disable_notification, int reply_to_message_id,
430 const char *reply_markup);
431
457 char *video_note, bool is_file, int duration, int length, const char *thumb,
458 bool disable_notification, int reply_to_message_id, const char *reply_markup);
459
472 telebot_handler_t handle,
473 long long int chat_id,
474 char *media_paths[],
475 int count,
476 bool disable_notification,
477 int reply_to_message_id);
478
497 float latitude, float longitude, int live_period, bool disable_notification,
498 int reply_to_message_id, const char *reply_markup);
499
518 long long int chat_id, int message_id, const char *inline_message_id,
519 float latitude, float longitude, const char *reply_markup);
520
536 long long int chat_id, int message_id, char *inline_message_id,
537 const char *reply_markup);
538
560 float latitude, float longitude, const char *title, const char *address,
561 const char *foursquare_id, const char *foursquare_type, bool disable_notification,
562 int reply_to_message_id, const char *reply_markup);
563
583 const char *phone_number, const char *first_name, const char *last_name,
584 const char *vcard, bool disable_notification, int reply_to_message_id,
585 const char *reply_markup);
586
613 const char *question, const char **options, int count_options, bool is_anonymous,
614 const char *type, bool allows_multiple_answers, int correct_option_id, bool is_closed,
615 bool disable_notification, int reply_to_message_id, const char *reply_markup);
616
632 bool disable_notification, int reply_to_message_id, const char *reply_markup);
633
655 char *action);
656
672 int user_id, int offset, int limit, telebot_user_profile_photos_t *photos);
673
683
688 long long int user_id, int offset, int limit, telebot_user_profile_audios_t *audios);
689
694
699 const char *photo);
700
705 const char *photo_id);
706
711 const char *business_connection_id, telebot_business_connection_t *connection);
712
717
722 long long int chat_id, long long int user_id, telebot_user_chat_boosts_t *boosts);
723
728
737 const char *path);
738
756 int user_id, long until_date);
757
770 int user_id);
771
804 long long int chat_id, int user_id, long until_date, bool can_send_messages,
805 bool can_send_media_messages, bool can_send_polls, bool can_send_other_messages,
806 bool can_add_web_page_previews, bool can_change_info, bool can_invite_users,
807 bool can_pin_messages);
808
839 long long int chat_id, int user_id, bool can_change_info, bool can_post_messages,
840 bool can_edit_messages, bool can_delete_messages, bool can_invite_users,
841 bool can_restrict_members, bool can_pin_messages, bool can_promote_members);
842
857 long long int chat_id, int user_id, const char *custom_title);
858
887 long long int chat_id, bool can_send_messages, bool can_send_media_messages,
888 bool can_send_polls, bool can_send_other_messages, bool can_add_web_page_previews,
889 bool can_change_info, bool can_invite_users, bool can_pin_messages);
890
903 long long int chat_id, char **invite_link);
904
917 const char *photo);
918
930
943 const char *title);
944
957 long long int chat_id, const char *description);
958
974 int message_id, bool disable_notification);
975
987
997
1009 telebot_chat_t *chat);
1010
1011
1019
1035 telebot_chat_member_t **admin, int *count);
1036
1045
1056 long long int chat_id, int *count);
1057
1070 int user_id, telebot_chat_member_t *member);
1071
1079
1094 long long int chat_id, const char *sticker_set_name);
1095
1108 long long int chat_id);
1109
1131 const char *callback_query_id, const char *text, bool show_alert,
1132 const char *url, int cache_time);
1133
1142 telebot_bot_command_t commands[], int count);
1143
1153 telebot_bot_command_t **commands, int *count);
1154
1162
1181 long long int chat_id, int message_id, const char *inline_message_id,
1182 const char *text, const char *parse_mode, bool disable_web_page_preview,
1183 const char *reply_markup);
1184
1200 long long int chat_id, int message_id, const char *inline_message_id,
1201 const char *caption, const char *parse_mode, const char *reply_markup);
1202
1219 long long int chat_id, int message_id, const char *inline_message_id,
1220 const char *reply_markup);
1221
1237 int message_id, const char *reply_markup);
1238
1256 int message_id);
1257
1266
1275
1285 const char *name, const char *language_code);
1286
1296 const char *language_code, char **name);
1297
1307 const char *description, const char *language_code);
1308
1318 const char *language_code, char **description);
1319
1329 const char *short_description, const char *language_code);
1330
1340 const char *language_code, char **short_description);
1341
1351 long long int chat_id, const char *menu_button);
1352
1362 long long int chat_id, char **menu_button);
1363
1373 const char *rights, bool for_channels);
1374
1384 bool for_channels, char **rights);
1385
1395 const char *scope, const char *language_code);
1396
1416 long long int chat_id, long long int from_chat_id, int message_id,
1417 const char *caption, const char *parse_mode, const char *caption_entities,
1418 bool disable_notification, bool protect_content, int reply_to_message_id,
1419 bool allow_sending_without_reply, const char *reply_markup, int *message_id_out);
1420
1436 long long int chat_id, long long int from_chat_id, const char *message_ids,
1437 bool disable_notification, bool protect_content, bool remove_caption,
1438 int **message_ids_out, int *count);
1439
1454 long long int chat_id, long long int from_chat_id, const char *message_ids,
1455 bool disable_notification, bool protect_content, int **message_ids_out, int *count);
1456
1466 long long int chat_id, const char *message_ids);
1467
1479 long long int chat_id, int user_id, long until_date, bool revoke_messages);
1480
1490 long long int chat_id, long long int sender_chat_id);
1491
1501 long long int chat_id, long long int sender_chat_id);
1502
1516 long long int chat_id, const char *name, long expire_date, int member_limit,
1517 bool creates_join_request, telebot_chat_invite_link_t *invite_link);
1518
1533 long long int chat_id, const char *invite_link_str, const char *name,
1534 long expire_date, int member_limit, bool creates_join_request,
1535 telebot_chat_invite_link_t *invite_link);
1536
1547 long long int chat_id, const char *invite_link_str, telebot_chat_invite_link_t *invite_link);
1548
1555
1565 long long int chat_id, int user_id);
1566
1576 long long int chat_id, int user_id);
1577
1589 long long int chat_id, int message_id, const char *reaction, bool is_big);
1590
1603 long long int chat_id, int message_id, const char *inline_message_id,
1604 const char *media, const char *reply_markup);
1605
1610#ifdef __cplusplus
1611}
1612#endif
1613
1614#endif /* __TELEBOT_METHODS_H__ */
telebot_error_e telebot_delete_my_commands(telebot_handler_t handle, const char *scope, const char *language_code)
Use this method to delete the list of the bot's commands for the given scope and user language.
telebot_error_e telebot_get_my_description(telebot_handler_t handle, const char *language_code, char **description)
Use this method to get the current bot description for the given user language.
telebot_error_e telebot_get_proxy(telebot_handler_t handle, char **addr)
Get proxy address currently used.
telebot_error_e telebot_close(telebot_handler_t handle)
Use this method to close the bot instance before moving it from one local server to another.
telebot_error_e telebot_answer_callback_query(telebot_handler_t handle, const char *callback_query_id, const char *text, bool show_alert, const char *url, int cache_time)
Send answers to callback queries sent from inline keyboards. The answer will be displayed to the user...
telebot_error_e telebot_send_dice(telebot_handler_t handle, long long int chat_id, bool disable_notification, int reply_to_message_id, const char *reply_markup)
Send a dice, which will have a random value from 1 to 6.
telebot_error_e telebot_download_file(telebot_handler_t handle, const char *file_id, const char *path)
This function is used to download file.
telebot_error_e telebot_unban_chat_member(telebot_handler_t handle, long long int chat_id, int user_id)
Unban a previously kicked user in a supergroup or channel. The user will not return to the group or c...
telebot_error_e telebot_send_venue(telebot_handler_t handle, long long int chat_id, float latitude, float longitude, const char *title, const char *address, const char *foursquare_id, const char *foursquare_type, bool disable_notification, int reply_to_message_id, const char *reply_markup)
Send information about a venue.
telebot_error_e telebot_get_business_connection(telebot_handler_t handle, const char *business_connection_id, telebot_business_connection_t *connection)
Use this method to get information about the business connection.
telebot_error_e telebot_put_user_profile_photos(telebot_user_profile_photos_t *photos)
This function is used to free memory allocated for user profile pictures object.
telebot_error_e telebot_get_chat_admins(telebot_handler_t handle, long long int chat_id, telebot_chat_member_t **admin, int *count)
Get a list of administrators in a chat. Response contains an array of objects that contains informati...
telebot_error_e telebot_approve_chat_join_request(telebot_handler_t handle, long long int chat_id, int user_id)
Use this method to approve a chat join request.
telebot_error_e telebot_put_user_chat_boosts(telebot_user_chat_boosts_t *boosts)
Release user chat boosts obtained with telebot_get_user_chat_boosts.
telebot_error_e telebot_get_my_default_administrator_rights(telebot_handler_t handle, bool for_channels, char **rights)
Use this method to get the current default administrator rights of the bot.
telebot_error_e telebot_send_media_group(telebot_handler_t handle, long long int chat_id, char *media_paths[], int count, bool disable_notification, int reply_to_message_id)
Send a group of photos as an album.
telebot_error_e telebot_edit_message_media(telebot_handler_t handle, long long int chat_id, int message_id, const char *inline_message_id, const char *media, const char *reply_markup)
Use this method to edit animation, audio, document, photo, or video messages.
telebot_error_e telebot_destroy(telebot_handler_t handle)
Final function to use telebo APIs.
telebot_error_e telebot_set_my_name(telebot_handler_t handle, const char *name, const char *language_code)
Use this method to change the bot's name.
telebot_error_e telebot_get_my_name(telebot_handler_t handle, const char *language_code, char **name)
Use this method to get the current bot name for the given user language.
telebot_error_e telebot_set_webhook(telebot_handler_t handle, char *url, char *certificate, int max_connections, telebot_update_type_e allowed_updates[], int allowed_updates_count)
This function is used to specify a url and receive incoming updates via an outgoing webhook....
telebot_error_e telebot_get_webhook_info(telebot_handler_t handle, telebot_webhook_info_t *info)
This function is used to get information about telegram bot itself.
telebot_error_e telebot_set_chat_description(telebot_handler_t handle, long long int chat_id, const char *description)
Change the description of a supergroup or a channel. The bot must be an administrator in the chat for...
telebot_error_e telebot_send_contact(telebot_handler_t handle, long long int chat_id, const char *phone_number, const char *first_name, const char *last_name, const char *vcard, bool disable_notification, int reply_to_message_id, const char *reply_markup)
Send phone contacts.
telebot_error_e telebot_edit_chat_invite_link(telebot_handler_t handle, long long int chat_id, const char *invite_link_str, const char *name, long expire_date, int member_limit, bool creates_join_request, telebot_chat_invite_link_t *invite_link)
Use this method to edit a non-primary invite link created by the bot.
telebot_error_e telebot_put_chat(telebot_chat_t *chat)
Release chat obtained with telebot_get_chat().
telebot_error_e telebot_get_chat(telebot_handler_t handle, long long int chat_id, telebot_chat_t *chat)
Get up to date information about the chat (current name of the user for one-on-one conversations,...
enum telebot_update_type telebot_update_type_e
Enumerations of telegram update types.
telebot_error_e telebot_edit_message_caption(telebot_handler_t handle, long long int chat_id, int message_id, const char *inline_message_id, const char *caption, const char *parse_mode, const char *reply_markup)
Edit captions of messages sent by the bot or via the bot (for inline bots).
telebot_error_e telebot_forward_messages(telebot_handler_t handle, long long int chat_id, long long int from_chat_id, const char *message_ids, bool disable_notification, bool protect_content, int **message_ids_out, int *count)
Use this method to forward multiple messages of any kind.
telebot_error_e telebot_send_audio(telebot_handler_t handle, long long int chat_id, const char *audio, bool is_file, const char *caption, const char *parse_mode, int duration, const char *performer, const char *title, const char *thumb, bool disable_notification, int reply_to_message_id, const char *reply_markup)
Send audio files. if you want Telegram clients to display them in the music player....
telebot_error_e telebot_put_my_commands(telebot_bot_command_t *commands, int count)
Release bot commands obtained with telebot_get_my_commands().
telebot_error_e telebot_set_chat_photo(telebot_handler_t handle, long long int chat_id, const char *photo)
Set a new profile photo for the chat. Photos can't be changed for private chats. The bot must be an a...
telebot_error_e telebot_decline_chat_join_request(telebot_handler_t handle, long long int chat_id, int user_id)
Use this method to decline a chat join request.
telebot_error_e telebot_put_user(telebot_user_t *user)
This function is used to release memory used for user object.
telebot_error_e telebot_unpin_chat_message(telebot_handler_t handle, long long int chat_id)
Unpin a message in a supergroup or a channel. The bot must be an administrator in the chat for this t...
telebot_error_e telebot_get_updates(telebot_handler_t handle, int offset, int limit, int timeout, telebot_update_type_e allowed_updates[], int allowed_updates_count, telebot_update_t **updates, int *count)
This function is used to get latest updates.
telebot_error_e telebot_create_chat_invite_link(telebot_handler_t handle, long long int chat_id, const char *name, long expire_date, int member_limit, bool creates_join_request, telebot_chat_invite_link_t *invite_link)
Use this method to create an additional invite link for a chat.
telebot_error_e telebot_unban_chat_sender_chat(telebot_handler_t handle, long long int chat_id, long long int sender_chat_id)
Use this method to unban a previously banned channel chat in a supergroup or a channel.
telebot_error_e telebot_edit_message_live_location(telebot_handler_t handle, long long int chat_id, int message_id, const char *inline_message_id, float latitude, float longitude, const char *reply_markup)
Edit live location messages sent by the bot or via the bot (for inline bots). A location can be edite...
telebot_error_e telebot_send_location(telebot_handler_t handle, long long int chat_id, float latitude, float longitude, int live_period, bool disable_notification, int reply_to_message_id, const char *reply_markup)
Send point on the map.
telebot_error_e telebot_edit_message_text(telebot_handler_t handle, long long int chat_id, int message_id, const char *inline_message_id, const char *text, const char *parse_mode, bool disable_web_page_preview, const char *reply_markup)
Edit text and game messages sent by the bot or via the bot (for inline bots).
telebot_error_e telebot_get_my_short_description(telebot_handler_t handle, const char *language_code, char **short_description)
Use this method to get the current bot short description for the given user language.
telebot_error_e telebot_get_chat_menu_button(telebot_handler_t handle, long long int chat_id, char **menu_button)
Use this method to get the current value of the bot's menu button in a private chat,...
telebot_error_e telebot_delete_messages(telebot_handler_t handle, long long int chat_id, const char *message_ids)
Use this method to delete multiple messages in a chat.
telebot_error_e telebot_put_chat_admins(telebot_chat_member_t *admins, int count)
Release chat admins obtained with telebot_get_chat_admins().
telebot_error_e telebot_get_me(telebot_handler_t handle, telebot_user_t *me)
This function is used to get information about telegram bot itself.
telebot_error_e telebot_remove_my_profile_photo(telebot_handler_t handle, const char *photo_id)
Use this method to remove the bot's profile photo.
telebot_error_e telebot_set_my_commands(telebot_handler_t handle, telebot_bot_command_t commands[], int count)
Change the list of the bot's commands.
telebot_error_e telebot_send_voice(telebot_handler_t handle, long long int chat_id, const char *voice, bool is_file, const char *caption, const char *parse_mode, int duration, bool disable_notification, int reply_to_message_id, const char *reply_markup)
Send audio files, if you want Telegram clients to display the file as a playable voice message....
telebot_error_e telebot_pin_chat_message(telebot_handler_t handle, long long int chat_id, int message_id, bool disable_notification)
Pin a message in a supergroup or a channel. The bot must be an administrator in the chat for this to ...
telebot_error_e telebot_put_business_connection(telebot_business_connection_t *connection)
Release business connection obtained with telebot_get_business_connection.
telebot_error_e telebot_put_chat_member(telebot_chat_member_t *member)
Release chat member otained with telebot_get_chat_member().
telebot_error_e telebot_put_user_profile_audios(telebot_user_profile_audios_t *audios)
Release user profile audios obtained with telebot_get_user_profile_audios.
telebot_error_e telebot_revoke_chat_invite_link(telebot_handler_t handle, long long int chat_id, const char *invite_link_str, telebot_chat_invite_link_t *invite_link)
Use this method to revoke an invite link created by the bot.
telebot_error_e telebot_ban_chat_sender_chat(telebot_handler_t handle, long long int chat_id, long long int sender_chat_id)
Use this method to ban a channel chat in a supergroup or a channel.
telebot_error_e telebot_forward_message(telebot_handler_t handle, long long int chat_id, long long int from_chat_id, bool disable_notification, int message_id)
Forward messages of any kind.
telebot_error_e telebot_delete_chat_sticker_set(telebot_handler_t handle, long long int chat_id)
Delete a group sticker set from a supergroup. The bot must be an administrator in the chat for this t...
telebot_error_e telebot_put_me(telebot_user_t *me)
This function is used to release memory used for obtained information about telegram bot itself.
telebot_error_e telebot_send_video_note(telebot_handler_t handle, long long int chat_id, char *video_note, bool is_file, int duration, int length, const char *thumb, bool disable_notification, int reply_to_message_id, const char *reply_markup)
Send video messages. As of v.4.0, Telegram clients support rounded square mp4 videos of up to 1 minut...
telebot_error_e telebot_put_updates(telebot_update_t *updates, int count)
This function is used to release memory used for obtained updates.
telebot_error_e telebot_send_photo(telebot_handler_t handle, long long int chat_id, const char *photo, bool is_file, const char *caption, const char *parse_mode, bool disable_notification, int reply_to_message_id, const char *reply_markup)
Send photos.
struct telebot_handler * telebot_handler_t
This is opaque object to represent a telebot handler.
Definition telebot-types.h:3489
telebot_error_e telebot_get_user_chat_boosts(telebot_handler_t handle, long long int chat_id, long long int user_id, telebot_user_chat_boosts_t *boosts)
Use this method to get user chat boosts.
telebot_error_e telebot_set_chat_admin_custom_title(telebot_handler_t handle, long long int chat_id, int user_id, const char *custom_title)
Export an invite link to a supergroup or a channel. The bot must be an administrator in the chat for ...
telebot_error_e telebot_set_my_profile_photo(telebot_handler_t handle, const char *photo)
Use this method to set the bot's profile photo.
telebot_error_e telebot_send_video(telebot_handler_t handle, long long int chat_id, const char *video, bool is_file, int duration, int width, int height, const char *thumb, const char *caption, const char *parse_mode, bool supports_streaming, bool disable_notification, int reply_to_message_id, const char *reply_markup)
Send video files, Telegram clients support mp4 videos (other formats may be sent as Document).
telebot_error_e telebot_send_animation(telebot_handler_t handle, long long int chat_id, const char *animation, bool is_file, int duration, int width, int height, const char *thumb, const char *caption, const char *parse_mode, bool disable_notification, int reply_to_message_id, const char *reply_markup)
Send animation files (GIF or H.264/MPEG-4 AVC without sound).
telebot_error_e telebot_set_chat_menu_button(telebot_handler_t handle, long long int chat_id, const char *menu_button)
Use this method to change the bot's menu button in a private chat, or the default menu button.
telebot_error_e telebot_delete_message(telebot_handler_t handle, long long int chat_id, int message_id)
Delete a message, including service messages, with the following limitations:
telebot_error_e telebot_edit_message_reply_markup(telebot_handler_t handle, long long int chat_id, int message_id, const char *inline_message_id, const char *reply_markup)
Edit only the reply markup of messages sent by the bot or via the bot (for inline bots).
telebot_error_e telebot_set_message_reaction(telebot_handler_t handle, long long int chat_id, int message_id, const char *reaction, bool is_big)
Use this method to set a new message reaction.
telebot_error_e telebot_send_chat_action(telebot_handler_t handle, long long int chat_id, char *action)
Tell the user that something is happening on the bot's side. The status is set for 5 seconds or less ...
telebot_error_e telebot_set_my_short_description(telebot_handler_t handle, const char *short_description, const char *language_code)
Use this method to change the bot's short description.
telebot_error_e telebot_stop_message_live_location(telebot_handler_t handle, long long int chat_id, int message_id, char *inline_message_id, const char *reply_markup)
Stop updating a live location message sent by the bot or via the bot (for inline bots) before live_pe...
telebot_error_e telebot_restrict_chat_member(telebot_handler_t handle, long long int chat_id, int user_id, long until_date, bool can_send_messages, bool can_send_media_messages, bool can_send_polls, bool can_send_other_messages, bool can_add_web_page_previews, bool can_change_info, bool can_invite_users, bool can_pin_messages)
Restrict a user in a supergroup. The bot must be an administrator in the supergroup for this to work ...
telebot_error_e telebot_send_message(telebot_handler_t handle, long long int chat_id, const char *text, const char *parse_mode, bool disable_web_page_preview, bool disable_notification, int reply_to_message_id, const char *reply_markup)
Send text messages.
telebot_error_e telebot_put_chat_invite_link(telebot_chat_invite_link_t *invite_link)
Release chat invite link obtained with telebot_create_chat_invite_link etc.
telebot_error_e telebot_set_chat_sticker_set(telebot_handler_t handle, long long int chat_id, const char *sticker_set_name)
Set a new group sticker set for a supergroup. The bot must be an administrator in the chat for this t...
telebot_error_e telebot_copy_messages(telebot_handler_t handle, long long int chat_id, long long int from_chat_id, const char *message_ids, bool disable_notification, bool protect_content, bool remove_caption, int **message_ids_out, int *count)
Use this method to copy multiple messages of any kind.
telebot_error_e telebot_delete_chat_photo(telebot_handler_t handle, long long int chat_id)
Delete a chat photo. Photos can't be changed for private chats. The bot must be an administrator in t...
telebot_error_e telebot_send_poll(telebot_handler_t handle, long long int chat_id, const char *question, const char **options, int count_options, bool is_anonymous, const char *type, bool allows_multiple_answers, int correct_option_id, bool is_closed, bool disable_notification, int reply_to_message_id, const char *reply_markup)
Send a native poll.
telebot_error_e telebot_kick_chat_member(telebot_handler_t handle, long long int chat_id, int user_id, long until_date)
Kick a user from a group, a supergroup or a channel. In the case of supergroups and channels,...
telebot_error_e telebot_set_chat_permissions(telebot_handler_t handle, long long int chat_id, bool can_send_messages, bool can_send_media_messages, bool can_send_polls, bool can_send_other_messages, bool can_add_web_page_previews, bool can_change_info, bool can_invite_users, bool can_pin_messages)
Set default chat permissions for all members. The bot must be an administrator in the group or a supe...
telebot_error_e telebot_set_proxy(telebot_handler_t handle, char *addr, char *auth)
Set proxy address to use telebot behind proxy.
telebot_error_e
Enumerations of error code for telebot programming interface.
Definition telebot-common.h:45
telebot_error_e telebot_get_chat_members_count(telebot_handler_t handle, long long int chat_id, int *count)
Get the number of members in a chat.
telebot_error_e telebot_get_user_profile_photos(telebot_handler_t handle, int user_id, int offset, int limit, telebot_user_profile_photos_t *photos)
This function is used to get user profile pictures object.
telebot_error_e telebot_set_my_default_administrator_rights(telebot_handler_t handle, const char *rights, bool for_channels)
Use this method to change the default administrator rights requested by the bot when it's added as an...
telebot_error_e telebot_get_chat_member(telebot_handler_t handle, long long int chat_id, int user_id, telebot_chat_member_t *member)
Get information about a member of a chat.
telebot_error_e telebot_log_out(telebot_handler_t handle)
Use this method to log out from the cloud Bot API server before launching the bot locally.
telebot_error_e telebot_put_webhook_info(telebot_webhook_info_t *info)
This function is used to release memory used for obtained information about telegram bot itself.
telebot_error_e telebot_set_chat_title(telebot_handler_t handle, long long int chat_id, const char *title)
Change the title of a chat. Titles can't be changed for private chats. The bot must be an administrat...
telebot_error_e telebot_export_chat_invite_link(telebot_handler_t handle, long long int chat_id, char **invite_link)
Generate a new invite link for a chat; any previously generated link is revoked. The bot must be an a...
telebot_error_e telebot_send_document(telebot_handler_t handle, long long int chat_id, const char *document, bool is_file, const char *thumb, const char *caption, const char *parse_mode, bool disable_notification, int reply_to_message_id, const char *reply_markup)
Send general files.
telebot_error_e telebot_delete_webhook(telebot_handler_t handle)
This function is used to remove webhook integration if you decide to switch back to getUpdates.
telebot_error_e telebot_set_my_description(telebot_handler_t handle, const char *description, const char *language_code)
Use this method to change the bot's description.
telebot_error_e telebot_leave_chat(telebot_handler_t handle, long long int chat_id)
Leave a group, supergroup or channel.
telebot_error_e telebot_create(telebot_handler_t *handle, char *token)
Initial function to use telebot APIs.
telebot_error_e telebot_ban_chat_member(telebot_handler_t handle, long long int chat_id, int user_id, long until_date, bool revoke_messages)
Use this method to ban a user in a group, a supergroup or a channel.
telebot_error_e telebot_get_my_commands(telebot_handler_t handle, telebot_bot_command_t **commands, int *count)
Get the current list of the bot's commands.
telebot_error_e telebot_get_user_profile_audios(telebot_handler_t handle, long long int user_id, int offset, int limit, telebot_user_profile_audios_t *audios)
Use this method to get user profile audios.
telebot_error_e telebot_stop_poll(telebot_handler_t handle, long long int chat_id, int message_id, const char *reply_markup)
Stop a poll which was sent by the bot.
telebot_error_e telebot_copy_message(telebot_handler_t handle, long long int chat_id, long long int from_chat_id, int message_id, const char *caption, const char *parse_mode, const char *caption_entities, bool disable_notification, bool protect_content, int reply_to_message_id, bool allow_sending_without_reply, const char *reply_markup, int *message_id_out)
Use this method to copy messages of any kind.
telebot_error_e telebot_promote_chat_member(telebot_handler_t handle, long long int chat_id, int user_id, bool can_change_info, bool can_post_messages, bool can_edit_messages, bool can_delete_messages, bool can_invite_users, bool can_restrict_members, bool can_pin_messages, bool can_promote_members)
Promote or demote a user in a supergroup or a channel. The bot must be an administrator in the chat f...
This object represents a bot command.
Definition telebot-types.h:3096
Describes the connection of the bot with a business account.
Definition telebot-types.h:156
This object contains information about one member of a chat.
Definition telebot-types.h:2936
This object represents a chat.
Definition telebot-types.h:229
This object represents an incoming update.
Definition telebot-types.h:3328
This object represents a list of user chat boosts.
Definition telebot-types.h:2290
This object represents a list of user profile audios.
Definition telebot-types.h:2232
This object represent a user's profile pictures.
Definition telebot-types.h:2582
This object represents a Telegram user or bot.
Definition telebot-types.h:178
Thi object represetns information about the current status of a webhook.
Definition telebot-types.h:3425
This file contains telegram bot common defintions.
This file contains core API for the telegram bot interface.
This file contains types used to create telegram bot.