Link Search Menu Expand Document

Constructor: messageActionGiftTon

Back to constructors index

You were gifted some toncoins.

This service message should be displayed below the appropriate sticker from the inputStickerSetTonGifts » stickerset »:

  • If crypto_amount <= 10_000_000_000, choose the sticker with emoji equal to “2️⃣”
  • If crypto_amount <= 50_000_000_000, choose the sticker with emoji equal to “1️⃣”
  • Otherwise, choose the sticker with emoji equal to “3️⃣”

Attributes:

NameTypeRequiredDescription
currencystringYesName of a localized FIAT currency.
amountlongYesFIAT currency equivalent (in the currency specified in currency) of the amount specified in crypto_amount.
crypto_currencystringYesName of the cryptocurrency.
crypto_amountlongYesAmount in the smallest unit of the cryptocurrency (for TONs, one billionth of a ton, AKA a nanoton).
transaction_idstringOptionalTransaction ID.

Type: MessageAction

Example:

$messageActionGiftTon = ['_' => 'messageActionGiftTon', 'currency' => 'string', 'amount' => long, 'crypto_currency' => 'string', 'crypto_amount' => long, 'transaction_id' => 'string'];