StarTransaction

@Serializable
data class StarTransaction(val id: String, val amount: Int, val nanostarAmount: Int? = null, val date: Instant, val source: TransactionPartner? = null, val receiver: TransactionPartner? = null)

Describes a Telegram Star transaction.

Api reference

Constructors

Link copied to clipboard
constructor(id: String, amount: Int, nanostarAmount: Int? = null, date: Instant, source: TransactionPartner? = null, receiver: TransactionPartner? = null)

Properties

Link copied to clipboard
val amount: Int

Integer amount of Telegram Stars transferred by the transaction

Link copied to clipboard
@Serializable(with = InstantSerializer::class)
val date: Instant

Date the transaction was created in Unix time

Link copied to clipboard
val id: String

Unique identifier of the transaction. Coincides with the identifier of the original transaction for refund transactions. Coincides with SuccessfulPayment.telegram_payment_charge_id for successful incoming payments from users.

Link copied to clipboard
val nanostarAmount: Int? = null

Optional. The number of 1/1000000000 shares of Telegram Stars transferred by the transaction; from 0 to 999999999

Link copied to clipboard

Optional. Receiver of an outgoing transaction (e.g., a user for a purchase refund, Fragment for a withdrawal). Only for outgoing transactions

Link copied to clipboard

Optional. Source of an incoming transaction (e.g., a user purchasing goods or services, Fragment refunding a failed withdrawal). Only for incoming transactions