class Hamilton::Types::InputInvoiceMessageContent

Overview

Represents the content of an invoice message to be sent as the result of an inline query.

Included Modules

Defined in:

types/input_message_content.cr

Constructors

Instance Method Summary

Instance methods inherited from class Reference

==(other : Hamilton::Any) ==

Instance methods inherited from class Object

===(other : Hamilton::Any) ===

Constructor Detail

def self.new(pull : JSON::PullParser) #

def self.new(params) #

def self.new(*, __pull_for_json_serializable pull : JSON::PullParser) #

def self.new(**params) #

Instance Method Detail

def currency : String #

Three-letter ISO 4217 currency code, see more on currencies. Pass “XTR” for payments in Telegram Stars.


def currency=(currency : String) #

Three-letter ISO 4217 currency code, see more on currencies. Pass “XTR” for payments in Telegram Stars.


def description : String #

Product description, 1-255 characters.


def description=(description : String) #

Product description, 1-255 characters.


def is_flexible : Bool | Nil #

Pass True if the final price depends on the shipping method. Ignored for payments in Telegram Stars.


def is_flexible=(is_flexible : Bool | Nil) #

Pass True if the final price depends on the shipping method. Ignored for payments in Telegram Stars.


def max_tip_amount : Int32 | Nil #

The maximum accepted amount for tips in the smallest units of the currency (integer, not float/double). For example, for a maximum tip of US$ 1.45 pass max_tip_amount = 145.


def max_tip_amount=(max_tip_amount : Int32 | Nil) #

The maximum accepted amount for tips in the smallest units of the currency (integer, not float/double). For example, for a maximum tip of US$ 1.45 pass max_tip_amount = 145.


def need_email : Bool | Nil #

Pass True if you require the user's email address to complete the order. Ignored for payments in Telegram Stars.


def need_email=(need_email : Bool | Nil) #

Pass True if you require the user's email address to complete the order. Ignored for payments in Telegram Stars.


def need_name : Bool | Nil #

Pass True if you require the user's full name to complete the order. Ignored for payments in Telegram Stars.


def need_name=(need_name : Bool | Nil) #

Pass True if you require the user's full name to complete the order. Ignored for payments in Telegram Stars.


def need_phone_number : Bool | Nil #

Pass True if you require the user's phone number to complete the order. Ignored for payments in Telegram Stars.


def need_phone_number=(need_phone_number : Bool | Nil) #

Pass True if you require the user's phone number to complete the order. Ignored for payments in Telegram Stars.


def need_shipping_address : Bool | Nil #

Pass True if you require the user's shipping address to complete the order. Ignored for payments in Telegram Stars.


def need_shipping_address=(need_shipping_address : Bool | Nil) #

Pass True if you require the user's shipping address to complete the order. Ignored for payments in Telegram Stars.


def non_nil_fields : Array(String) #

List of available non-nil fields.


def non_nil_fields=(non_nil_fields : Array(String)) #

List of available non-nil fields.


def payload : String #

Bot-defined invoice payload, 1-128 bytes. This will not be displayed to the user, use it for your internal processes.


def payload=(payload : String) #

Bot-defined invoice payload, 1-128 bytes. This will not be displayed to the user, use it for your internal processes.


def photo_height : Int32 | Nil #

Photo height.


def photo_height=(photo_height : Int32 | Nil) #

Photo height.


def photo_size : Int32 | Nil #

Photo size in bytes.


def photo_size=(photo_size : Int32 | Nil) #

Photo size in bytes.


def photo_url : String | Nil #

URL of the product photo for the invoice. Can be a photo of the goods or a marketing image for a service.


def photo_url=(photo_url : String | Nil) #

URL of the product photo for the invoice. Can be a photo of the goods or a marketing image for a service.


def photo_width : Int32 | Nil #

Photo width.


def photo_width=(photo_width : Int32 | Nil) #

Photo width.


def prices : Array(Hamilton::Types::LabeledPrice) #

Price breakdown, a JSON-serialized list of components (e.g. product price, tax, discount, delivery cost, delivery tax, bonus, etc.). Must contain exactly one item for payments in Telegram Stars.


def prices=(prices : Array(Hamilton::Types::LabeledPrice)) #

Price breakdown, a JSON-serialized list of components (e.g. product price, tax, discount, delivery cost, delivery tax, bonus, etc.). Must contain exactly one item for payments in Telegram Stars.


def provider_data : String | Nil #

A JSON-serialized object for data about the invoice, which will be shared with the payment provider. A detailed description of the required fields should be provided by the payment provider.


def provider_data=(provider_data : String | Nil) #

A JSON-serialized object for data about the invoice, which will be shared with the payment provider. A detailed description of the required fields should be provided by the payment provider.


def provider_token : String | Nil #

Payment provider token, obtained via @BotFather. Pass an empty string for payments in Telegram Stars.


def provider_token=(provider_token : String | Nil) #

Payment provider token, obtained via @BotFather. Pass an empty string for payments in Telegram Stars.


def send_email_to_provider : Bool | Nil #

Pass True if the user's email address should be sent to the provider. Ignored for payments in Telegram Stars.


def send_email_to_provider=(send_email_to_provider : Bool | Nil) #

Pass True if the user's email address should be sent to the provider. Ignored for payments in Telegram Stars.


def send_phone_number_to_provider : Bool | Nil #

Pass True if the user's phone number should be sent to the provider. Ignored for payments in Telegram Stars.


def send_phone_number_to_provider=(send_phone_number_to_provider : Bool | Nil) #

Pass True if the user's phone number should be sent to the provider. Ignored for payments in Telegram Stars.


def suggested_tip_amounts : Array(Int32) | Nil #

A JSON-serialized array of suggested amounts of tip in the smallest units of the currency (integer, not float/double). At most 4 suggested tip amounts can be specified. The suggested tip amounts must be positive, passed in a strictly increased order and must not exceed max_tip_amount.


def suggested_tip_amounts=(suggested_tip_amounts : Array(Int32) | Nil) #

A JSON-serialized array of suggested amounts of tip in the smallest units of the currency (integer, not float/double). At most 4 suggested tip amounts can be specified. The suggested tip amounts must be positive, passed in a strictly increased order and must not exceed max_tip_amount.


def title : String #

Product name, 1-32 characters.


def title=(title : String) #

Product name, 1-32 characters.