Repository navigation
Source compatible with 10.4.0, except that a NULL handle now returns a different error code
(see below and MIGRATION.md).
API
telebot_call_method()calls any Bot API method by name from the simple API and returns the
reply'sresultas JSON text.telebot_core_call_method()replacestelebot_core_call(), which still works but is deprecated
and produces a compiler warning.TELEBOT_DEPRECATED()marks such functions.- Functions of the simple API return
TELEBOT_ERROR_INVALID_PARAMETERfor a NULL handle, as the
core API does, instead ofTELEBOT_ERROR_NOT_SUPPORTED. telebot_set_proxy()andtelebot_stop_message_live_location()(both layers) take their string
inputs asconst char *.telebot_core_get_proxy()reportsTELEBOT_ERROR_OUT_OF_MEMORYwhen it cannot copy the address.
Headers
- New
telebot-config.hholds library-wide runtime settings;telebot_set_json_allocator()
moved there fromtelebot-core.h.telebot.handtelebot-core.hinclude it. telebot-core.hno longer includes high-level headers: request parameters shared by both
layers (telebot_send_options_t,telebot_input_file_t,telebot_input_media_t,
telebot_param_t,telebot_invoice_params_t,telebot_chat_permissions_t,
telebot_chat_administrator_rights_t) moved totelebot-common.h, and<pthread.h>is gone.- Every public header compiles on its own, from C and C++; a build check enforces it.
- API reference groups: Simple API, Core API, Common Definitions and Library Configuration.