public static class TdApi.SendGift extends TdApi.Function<TdApi.Ok>
Returns Ok
| Modifier and Type | Field and Description |
|---|---|
static int |
CONSTRUCTOR
Identifier uniquely determining type of the object.
|
long |
giftId
Identifier of the gift to send.
|
boolean |
isPrivate
Pass true to show the current user as sender and gift text only to the gift receiver; otherwise, everyone will be able to see them.
|
TdApi.FormattedText |
text
Text to show along with the gift; 0-getOption("gift_text_length_max") characters.
|
long |
userId
Identifier of the user that will receive the gift.
|
| Constructor and Description |
|---|
SendGift()
Default constructor for a function, which sends a gift to another user.
|
SendGift(long giftId,
long userId,
TdApi.FormattedText text,
boolean isPrivate)
Creates a function, which sends a gift to another user.
|
| Modifier and Type | Method and Description |
|---|---|
int |
getConstructor()
Returns an identifier uniquely determining type of the object.
|
toStringpublic long giftId
public long userId
public TdApi.FormattedText text
public boolean isPrivate
public static final int CONSTRUCTOR
public SendGift()
Returns Ok
public SendGift(long giftId,
long userId,
TdApi.FormattedText text,
boolean isPrivate)
Returns Ok
giftId - Identifier of the gift to send.userId - Identifier of the user that will receive the gift.text - Text to show along with the gift; 0-getOption("gift_text_length_max") characters. Only Bold, Italic, Underline, Strikethrough, Spoiler, and CustomEmoji entities are allowed.isPrivate - Pass true to show the current user as sender and gift text only to the gift receiver; otherwise, everyone will be able to see them.public int getConstructor()
TdApi.ObjectgetConstructor in class TdApi.Object