Link Search Menu Expand Document

Constructor: messages.sponsoredMessages

Back to constructors index

A set of sponsored messages associated to a channel

Attributes:

NameTypeRequiredDescription
posts_betweenintOptionalIf set, specifies the minimum number of messages between shown sponsored messages; otherwise, only one sponsored message must be shown after all ordinary messages.
messagesArray of SponsoredMessageYesSponsored messages
chatsArray of ChatYesChats mentioned in the sponsored messages
usersArray of UserYesUsers mentioned in the sponsored messages

Type: messages.SponsoredMessages

Example:

$messages_sponsoredMessages = ['_' => 'messages.sponsoredMessages', 'posts_between' => int, 'messages' => [SponsoredMessage, SponsoredMessage], 'chats' => [Chat, Chat], 'users' => [User, User]];