59 nl::json json = nl::json::object();
#define OBJECT_SERIALIZE_FIELD(json, json_field, field)
Available objects: https://core.telegram.org/bots/api#available-types.
#define OBJECT_DESERIALIZE_FIELD(json, json_field, field, default_value, optional)
Deserialize.
Describes actions that a non-administrator user is allowed to take in a chat. https://core....
nl::json toJson() const
Serializes this object to JSON.
bool canSendVideos
Optional. True, if the user is allowed to send videos.
bool canManageTopics
Optional. True, if the user is allowed to create forum topics. If omitted defaults to the value of ca...
bool canAddWebPagePreviews
Optional. True, if the user is allowed to add web page previews to their messages.
bool canChangeInfo
Optional. True, if the user is allowed to change the chat title, photo and other settings....
void fromJson(const nl::json &json)
Deserializes this object from JSON.
bool canPinMessages
Optional. True, if the user is allowed to pin messages. Ignored in public supergroups.
bool canInviteUsers
Optional. True, if the user is allowed to invite new users to the chat.
ChatPermissions()=default
bool canSendMessages
Optional. True, if the user is allowed to send text messages, contacts, invoices, locations and venue...
bool canSendAudios
Optional. True, if the user is allowed to send audios.
bool canSendVoiceNotes
Optional. True, if the user is allowed to send voice notes.
bool canSendPhotos
Optional. True, if the user is allowed to send photos.
bool canSendVideoNotes
Optional. True, if the user is allowed to send video notes.
bool canSendOtherMessages
Optional. True, if the user is allowed to send animations, games, stickers and use inline bots.
ChatPermissions(const nl::json &json)
bool canSendPolls
Optional. True, if the user is allowed to send polls.
bool canSendDocuments
Optional. True, if the user is allowed to send documents.