Struct teloxide_core::payloads::CreateChatInviteLink
source · pub struct CreateChatInviteLink {
pub chat_id: Recipient,
pub name: Option<String>,
pub expire_date: Option<DateTime<Utc>>,
pub member_limit: Option<u32>,
pub creates_join_request: Option<bool>,
}
Expand description
Use this method to create an additional invite link for a chat. The bot must be an administrator in the chat for this to work and must have the appropriate admin rights. The link can be revoked using the method RevokeChatInviteLink
. Returns the new invite link as ChatInviteLink
object.
Fields§
§chat_id: Recipient
Unique identifier for the target chat or username of the target channel (in the format @channelusername
)
name: Option<String>
Invite link name; 0-32 characters
expire_date: Option<DateTime<Utc>>
Point in time (Unix timestamp) when the link will expire
member_limit: Option<u32>
Maximum number of users that can be members of the chat simultaneously after joining the chat via this invite link; 1-99999
creates_join_request: Option<bool>
True, if users joining the chat via the link need to be approved by chat administrators. If True, member_limit can’t be specified
Implementations§
Trait Implementations§
source§impl Clone for CreateChatInviteLink
impl Clone for CreateChatInviteLink
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for CreateChatInviteLink
impl Debug for CreateChatInviteLink
source§impl Hash for CreateChatInviteLink
impl Hash for CreateChatInviteLink
source§impl PartialEq for CreateChatInviteLink
impl PartialEq for CreateChatInviteLink
source§impl Payload for CreateChatInviteLink
impl Payload for CreateChatInviteLink
§type Output = ChatInviteLink
type Output = ChatInviteLink
The return type of a Telegram method. Read more
source§fn timeout_hint(&self) -> Option<Duration>
fn timeout_hint(&self) -> Option<Duration>
If this payload may take long time to execute (e.g.
GetUpdates
with
big timeout
), the minimum timeout that should be used.source§impl Serialize for CreateChatInviteLink
impl Serialize for CreateChatInviteLink
impl Eq for CreateChatInviteLink
impl StructuralPartialEq for CreateChatInviteLink
Auto Trait Implementations§
impl Freeze for CreateChatInviteLink
impl RefUnwindSafe for CreateChatInviteLink
impl Send for CreateChatInviteLink
impl Sync for CreateChatInviteLink
impl Unpin for CreateChatInviteLink
impl UnwindSafe for CreateChatInviteLink
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)source§impl<P> CreateChatInviteLinkSetters for Pwhere
P: HasPayload<Payload = CreateChatInviteLink>,
impl<P> CreateChatInviteLinkSetters for Pwhere
P: HasPayload<Payload = CreateChatInviteLink>,
source§fn expire_date<T>(self, value: T) -> Self
fn expire_date<T>(self, value: T) -> Self
Setter for
expire_date
field.source§fn member_limit(self, value: u32) -> Self
fn member_limit(self, value: u32) -> Self
Setter for
member_limit
field.source§fn creates_join_request(self, value: bool) -> Self
fn creates_join_request(self, value: bool) -> Self
Setter for
creates_join_request
field.source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.source§impl<T> Erasable for T
impl<T> Erasable for T
source§impl<P> HasPayload for Pwhere
P: Payload,
impl<P> HasPayload for Pwhere
P: Payload,
source§fn payload_mut(&mut self) -> &mut <P as HasPayload>::Payload
fn payload_mut(&mut self) -> &mut <P as HasPayload>::Payload
Gain mutable access to the underlying payload.
source§fn payload_ref(&self) -> &<P as HasPayload>::Payload
fn payload_ref(&self) -> &<P as HasPayload>::Payload
Gain immutable access to the underlying payload.
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more