SendInvoiceRequest

data class SendInvoiceRequest(chat_id: String, title: String, description: String, payload: String, provider_token: String, currency: String, prices: List<LabeledPrice>, max_tip_amount: Long?, suggested_tip_amounts: List<Long>?, start_parameter: String?, provider_data: String?, photo_url: String?, photo_size: Long?, photo_width: Long?, photo_height: Long?, need_name: Boolean?, need_phone_number: Boolean?, need_email: Boolean?, need_shipping_address: Boolean?, send_phone_number_to_provider: Boolean?, send_email_to_provider: Boolean?, is_flexible: Boolean?, disable_notification: Boolean?, reply_to_message_id: Long?, allow_sending_without_reply: Boolean?, reply_markup: InlineKeyboardMarkup?) : TelegramRequest

Use this method to send invoices. On success, the sent Message is returned.

Constructors

SendInvoiceRequest
Link copied to clipboard
fun SendInvoiceRequest(chat_id: String, title: String, description: String, payload: String, provider_token: String, currency: String, prices: List<LabeledPrice>, max_tip_amount: Long? = null, suggested_tip_amounts: List<Long>? = null, start_parameter: String? = null, provider_data: String? = null, photo_url: String? = null, photo_size: Long? = null, photo_width: Long? = null, photo_height: Long? = null, need_name: Boolean? = null, need_phone_number: Boolean? = null, need_email: Boolean? = null, need_shipping_address: Boolean? = null, send_phone_number_to_provider: Boolean? = null, send_email_to_provider: Boolean? = null, is_flexible: Boolean? = null, disable_notification: Boolean? = null, reply_to_message_id: Long? = null, allow_sending_without_reply: Boolean? = null, reply_markup: InlineKeyboardMarkup? = null)

Properties

allow_sending_without_reply
Link copied to clipboard
val allow_sending_without_reply: Boolean? = null
Pass True, if the message should be sent even if the specified replied-to message is not found
chat_id
Link copied to clipboard
val chat_id: String
Unique identifier for the target chat or username of the target channel (in the format @channelusername)
currency
Link copied to clipboard
val currency: String
Three-letter ISO 4217 currency code, see more on currencies
description
Link copied to clipboard
val description: String
Product description, 1-255 characters
disable_notification
Link copied to clipboard
val disable_notification: Boolean? = null
Sends the message
is_flexible
Link copied to clipboard
val is_flexible: Boolean? = null
Pass True, if the final price depends on the shipping method
max_tip_amount
Link copied to clipboard
val max_tip_amount: Long? = null
The maximum accepted amount for tips in the smallest units of the currency (integer, not float/double).
need_email
Link copied to clipboard
val need_email: Boolean? = null
Pass True, if you require the user's email address to complete the order
need_name
Link copied to clipboard
val need_name: Boolean? = null
Pass True, if you require the user's full name to complete the order
need_phone_number
Link copied to clipboard
val need_phone_number: Boolean? = null
Pass True, if you require the user's phone number to complete the order
need_shipping_address
Link copied to clipboard
val need_shipping_address: Boolean? = null
Pass True, if you require the user's shipping address to complete the order
payload
Link copied to clipboard
val payload: String
Bot-defined invoice payload, 1-128 bytes.
photo_height
Link copied to clipboard
val photo_height: Long? = null
Photo height
photo_size
Link copied to clipboard
val photo_size: Long? = null
Photo size
photo_url
Link copied to clipboard
val photo_url: String? = null
URL of the product photo for the invoice.
photo_width
Link copied to clipboard
val photo_width: Long? = null
Photo width
prices
Link copied to clipboard
val prices: List<LabeledPrice>
Price breakdown, a JSON-serialized list of components (e.g.
provider_data
Link copied to clipboard
val provider_data: String? = null
A JSON-serialized data about the invoice, which will be shared with the payment provider.
provider_token
Link copied to clipboard
val provider_token: String
Payments provider token, obtained via
reply_markup
Link copied to clipboard
val reply_markup: InlineKeyboardMarkup? = null
A JSON-serialized object for an
reply_to_message_id
Link copied to clipboard
val reply_to_message_id: Long? = null
If the message is a reply, ID of the original message
send_email_to_provider
Link copied to clipboard
val send_email_to_provider: Boolean? = null
Pass True, if user's email address should be sent to provider
send_phone_number_to_provider
Link copied to clipboard
val send_phone_number_to_provider: Boolean? = null
Pass True, if user's phone number should be sent to provider
start_parameter
Link copied to clipboard
val start_parameter: String? = null
Unique deep-linking parameter.
suggested_tip_amounts
Link copied to clipboard
val suggested_tip_amounts: List<Long>? = null
A JSON-serialized array of suggested amounts of tips in the smallest units of the currency (integer, not float/double).
title
Link copied to clipboard
val title: String
Product name, 1-32 characters