util library

It contains useful functions that make it easier to work with VK API.

Classes

HttpClient
Http client.
VkDartKeyboard
Model Keyboard. Create a button:

Enums

MessageSource
Message Source
VkDartKeyboardColor
The enum of colors supported by the VK keyboard.

Constants

peerChatIdOffset → const int
Offset Chat ID.

Functions

checkBoolUtil(Object? value) bool?
Checks the value for an integer, then checks for one. If the value is not an integer, null is returned,
getPeerType(int id) MessageSource
Returns the dialog type. Accepts the id parameter as input, if id is less than peerChatIdOffset, MessageSource.chat is returned, if id is less than zero, returned MessageSource.group, in all other cases MessageSource.user
transformAttachments(List<Map<String, dynamic>> attachments) List<AttachmentModel>
Transforms a list of attachment objects in the format:

Exceptions / Errors

VkDartKeyboardException