tgbotxx 1.1.9.2
Telegram Bot C++ Library
Loading...
Searching...
No Matches
tgbotxx::RefundedPayment Struct Reference

This object contains basic information about a refunded payment. https://core.telegram.org/bots/api#refundedpayment. More...

#include <RefundedPayment.hpp>

Public Member Functions

 RefundedPayment ()=default
 
 RefundedPayment (const nl::json &json)
 
nl::json toJson () const
 Serializes this object to JSON.
 
void fromJson (const nl::json &json)
 Deserializes this object from JSON.
 

Public Attributes

std::string currency
 Three-letter ISO 4217 currency code, or “XTR” for payments in Telegram Stars. Currently, always “XTR” https://t.me/BotNews/90 https://core.telegram.org/bots/payments#supported-currencies.
 
std::int64_t totalAmount {}
 Total refunded price in the smallest units of the currency (integer, not float/double). For example, for a price of US$ 1.45, total_amount = 145. See the exp parameter in currencies.json, it shows the number of digits past the decimal point for each currency (2 for the majority of currencies). https://core.telegram.org/bots/payments/currencies.json.
 
std::string invoicePayload
 Bot-specified invoice payload.
 
std::string telegramPaymentChargeId
 Telegram payment identifier.
 
std::string providerPaymentChargeId
 Optional. Provider payment identifier.
 

Detailed Description

This object contains basic information about a refunded payment. https://core.telegram.org/bots/api#refundedpayment.

Definition at line 7 of file RefundedPayment.hpp.

Constructor & Destructor Documentation

◆ RefundedPayment() [1/2]

tgbotxx::RefundedPayment::RefundedPayment ( )
default

◆ RefundedPayment() [2/2]

tgbotxx::RefundedPayment::RefundedPayment ( const nl::json &  json)
inlineexplicit

Definition at line 9 of file RefundedPayment.hpp.

Member Function Documentation

◆ fromJson()

void tgbotxx::RefundedPayment::fromJson ( const nl::json &  json)
inline

Deserializes this object from JSON.

Definition at line 47 of file RefundedPayment.hpp.

◆ toJson()

nl::json tgbotxx::RefundedPayment::toJson ( ) const
inline

Serializes this object to JSON.

Returns
JSON representation of this object

Definition at line 36 of file RefundedPayment.hpp.

Member Data Documentation

◆ currency

std::string tgbotxx::RefundedPayment::currency

Three-letter ISO 4217 currency code, or “XTR” for payments in Telegram Stars. Currently, always “XTR” https://t.me/BotNews/90 https://core.telegram.org/bots/payments#supported-currencies.

Definition at line 16 of file RefundedPayment.hpp.

◆ invoicePayload

std::string tgbotxx::RefundedPayment::invoicePayload

Bot-specified invoice payload.

Definition at line 26 of file RefundedPayment.hpp.

◆ providerPaymentChargeId

std::string tgbotxx::RefundedPayment::providerPaymentChargeId

Optional. Provider payment identifier.

Definition at line 32 of file RefundedPayment.hpp.

◆ telegramPaymentChargeId

std::string tgbotxx::RefundedPayment::telegramPaymentChargeId

Telegram payment identifier.

Definition at line 29 of file RefundedPayment.hpp.

◆ totalAmount

std::int64_t tgbotxx::RefundedPayment::totalAmount {}

Total refunded price in the smallest units of the currency (integer, not float/double). For example, for a price of US$ 1.45, total_amount = 145. See the exp parameter in currencies.json, it shows the number of digits past the decimal point for each currency (2 for the majority of currencies). https://core.telegram.org/bots/payments/currencies.json.

Definition at line 23 of file RefundedPayment.hpp.


The documentation for this struct was generated from the following file: