+18
-6
@@ -4,17 +4,29 @@ package tgapi
|
||||
// Since: Bot API 7.5
|
||||
// See https://core.telegram.org/bots/api#startransaction
|
||||
type StarTransaction struct {
|
||||
ID string `json:"id"`
|
||||
Amount int `json:"amount"`
|
||||
NanostarAmount int `json:"nanostar_amount,omitempty"`
|
||||
Date int `json:"date"`
|
||||
Source map[string]any `json:"source,omitempty"`
|
||||
Receiver map[string]any `json:"receiver,omitempty"`
|
||||
// ID 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.
|
||||
ID string `json:"id"`
|
||||
// Amount Integer amount of Telegram Stars transferred by the transaction
|
||||
Amount int `json:"amount"`
|
||||
// NanostarAmount Optional. The number of 1/1000000000 shares of Telegram Stars transferred by the
|
||||
// transaction; from 0 to 999999999
|
||||
NanostarAmount int `json:"nanostar_amount,omitempty"`
|
||||
// Date Date the transaction was created in Unix time
|
||||
Date int `json:"date"`
|
||||
// Source Optional. Source of an incoming transaction (e.g., a user purchasing goods or services, Fragment
|
||||
// refunding a failed withdrawal). Only for incoming transactions.
|
||||
Source map[string]any `json:"source,omitempty"`
|
||||
// Receiver Optional. Receiver of an outgoing transaction (e.g., a user for a purchase refund, Fragment for
|
||||
// a withdrawal). Only for outgoing transactions.
|
||||
Receiver map[string]any `json:"receiver,omitempty"`
|
||||
}
|
||||
|
||||
// StarTransactions contains a list of Telegram Star transactions.
|
||||
// Since: Bot API 7.5
|
||||
// See https://core.telegram.org/bots/api#startransactions
|
||||
type StarTransactions struct {
|
||||
// Transactions The list of transactions
|
||||
Transactions []StarTransaction `json:"transactions"`
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user