Struct teloxide_core::payloads::CreateForumTopic
source · pub struct CreateForumTopic {
pub chat_id: Recipient,
pub name: String,
pub icon_color: u32,
pub icon_custom_emoji_id: String,
}
Expand description
Use this method to create a topic in a forum supergroup chat. The bot must be an administrator in the chat for this to work and must have the can_manage_topics administrator rights. Returns information about the created topic as a ForumTopic
object.
Fields§
§chat_id: Recipient
Unique identifier for the target chat or username of the target channel (in the format @channelusername
)
name: String
Topic name, 1-128 characters
icon_color: u32
Color of the topic icon in RGB format. Currently, must be one of 7322096 (0x6FB9F0), 16766590 (0xFFD67E), 13338331 (0xCB86DB), 9367192 (0x8EEE98), 16749490 (0xFF93B2), or 16478047 (0xFB6F5F)
icon_custom_emoji_id: String
Unique identifier of the custom emoji shown as the topic icon. Use getForumTopicIconStickers
to get all allowed custom emoji identifiers.
Implementations§
Trait Implementations§
source§impl Clone for CreateForumTopic
impl Clone for CreateForumTopic
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 CreateForumTopic
impl Debug for CreateForumTopic
source§impl Hash for CreateForumTopic
impl Hash for CreateForumTopic
source§impl PartialEq for CreateForumTopic
impl PartialEq for CreateForumTopic
source§impl Payload for CreateForumTopic
impl Payload for CreateForumTopic
§type Output = ForumTopic
type Output = ForumTopic
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 CreateForumTopic
impl Serialize for CreateForumTopic
impl Eq for CreateForumTopic
impl StructuralPartialEq for CreateForumTopic
Auto Trait Implementations§
impl Freeze for CreateForumTopic
impl RefUnwindSafe for CreateForumTopic
impl Send for CreateForumTopic
impl Sync for CreateForumTopic
impl Unpin for CreateForumTopic
impl UnwindSafe for CreateForumTopic
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> CreateForumTopicSetters for Pwhere
P: HasPayload<Payload = CreateForumTopic>,
impl<P> CreateForumTopicSetters for Pwhere
P: HasPayload<Payload = CreateForumTopic>,
source§fn icon_color(self, value: u32) -> Self
fn icon_color(self, value: u32) -> Self
Setter for
icon_color
field.source§fn icon_custom_emoji_id<T>(self, value: T) -> Self
fn icon_custom_emoji_id<T>(self, value: T) -> Self
Setter for
icon_custom_emoji_id
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