[][src]Struct tbot::methods::SendInvoice

#[must_use = "methods do nothing unless turned into a future"]pub struct SendInvoice<'a> { /* fields omitted */ }

Sends an invoice.

Reflects the sendInvoice method.

Implementations

impl<'a> SendInvoice<'a>[src]

pub fn provider_data(self, provider_data: &'a str) -> Self[src]

Configures data for your payment provider. Reflects the provider_data parameter.

pub fn photo(self, photo: Photo<'a>) -> Self[src]

Configures a photo for the invoice. Reflects the photo_url, photo_width and photo_height parameters.

pub fn is_name_needed(self, is_needed: bool) -> Self[src]

Configures if the user must specify their name. Reflects the need_name parameters.

pub fn is_phone_number_needed(self, is_needed: bool) -> Self[src]

Configures if the user must specify their phone number. Reflects the need_phone_number parameter.

pub fn is_email_needed(self, is_needed: bool) -> Self[src]

Configures if the user must specify their email. Reflects the need_email parameter.

pub fn is_shipping_address_needed(self, is_needed: bool) -> Self[src]

Configures if the user must specify their shipping address. Reflects the need_shipping_address parameter.

pub fn should_send_phone_number_to_provider(self, should_send: bool) -> Self[src]

Configures if the user's phone must be sent to your payment provider. Reflects the send_phone_number_to_provider parameter.

pub fn should_send_email_to_provider(self, must_send: bool) -> Self[src]

Configures if the user's email must be sent to your payment provider. Reflects the send_email_to_provider parameter.

pub fn is_flexible(self, is_flexible: bool) -> Self[src]

Configures if the final price depends on the shipping method. Reflects the is_flexible parameter.

pub fn is_notification_disabled(self, is_disabled: bool) -> Self[src]

Configures if the message will be sent silently. Reflects the disable_notification parameter.

pub fn in_reply_to(self, id: Id) -> Self[src]

Configures which message this invoice is sent in reply to. Reflects the reply_to_message_id parameter.

pub fn reply_markup(self, markup: Keyboard<'a>) -> Self[src]

Configures a keyboard for the message. Reflects the reply_markup parameter.

impl<'_> SendInvoice<'_>[src]

pub async fn call(self) -> Result<Message, MethodCall>[src]

Calls the method.

Trait Implementations

impl<'a> Clone for SendInvoice<'a>[src]

impl<'a> Debug for SendInvoice<'a>[src]

impl<'a> Serialize for SendInvoice<'a>[src]

Auto Trait Implementations

impl<'a> !RefUnwindSafe for SendInvoice<'a>

impl<'a> Send for SendInvoice<'a>

impl<'a> Sync for SendInvoice<'a>

impl<'a> Unpin for SendInvoice<'a>

impl<'a> !UnwindSafe for SendInvoice<'a>

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T> Instrument for T[src]

impl<T> Instrument for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> WithSubscriber for T[src]