[−][src]Struct tbot::event_loop::webhook::Webhook
Configures webhook and starts a server.
To construct a Webhook
, use Bot::webhook
.
Methods
impl<'a, C> Webhook<'a, C>
[src]
pub const fn ip(self, ip: IpAddr) -> Self
[src]
Configures the IP tbot
will bind to.
pub fn certificate(self, certificate: &'a str) -> Self
[src]
Configures certificate
.
pub fn max_connections(self, max: u8) -> Self
[src]
Configures max_connections
.
pub fn allowed_updates(self, updates: &'a [UpdateKind]) -> Self
[src]
Configures allowed_updates
.
pub const fn request_timeout(self, timeout: Duration) -> Self
[src]
Configures for how long tbot
should wait for setWebhook
. If you
don't configure this value, it is set to 60s
.
pub const fn http(self) -> Http<'a, C>
[src]
Configures a webhook server over HTTP. For HTTPS, see the https
method.
pub const fn https(self, identity: Identity) -> Https<'a, C>
[src]
Configures a webhook server over HTTPS. For HTTP, see the http
method.
Auto Trait Implementations
impl<'a, C> !RefUnwindSafe for Webhook<'a, C>
impl<'a, C> Send for Webhook<'a, C> where
C: Send + Sync,
C: Send + Sync,
impl<'a, C> Sync for Webhook<'a, C> where
C: Send + Sync,
C: Send + Sync,
impl<'a, C> Unpin for Webhook<'a, C>
impl<'a, C> !UnwindSafe for Webhook<'a, C>
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,