pub struct UpdateWebhookWithToken<'a> { /* private fields */ }
Expand description
Update a webhook, with a token, by ID.
Implementations§
source§impl<'a> UpdateWebhookWithToken<'a>
impl<'a> UpdateWebhookWithToken<'a>
sourcepub fn avatar(self, avatar: Option<&'a str>) -> Self
pub fn avatar(self, avatar: Option<&'a str>) -> Self
Set the avatar of the webhook.
This must be a Data URI, in the form of
data:image/{type};base64,{data}
where {type}
is the image MIME type
and {data}
is the base64-encoded image. See Discord Docs/Image Data.
sourcepub fn name(self, name: &'a str) -> Self
pub fn name(self, name: &'a str) -> Self
Change the name of the webhook.
§Errors
Returns an error of type WebhookUsername
if the webhook’s name is
invalid.
Trait Implementations§
source§impl IntoFuture for UpdateWebhookWithToken<'_>
impl IntoFuture for UpdateWebhookWithToken<'_>
source§type Output = Result<Response<Webhook>, Error>
type Output = Result<Response<Webhook>, Error>
The output that the future will produce on completion.
source§type IntoFuture = ResponseFuture<Webhook>
type IntoFuture = ResponseFuture<Webhook>
Which kind of future are we turning this into?
source§fn into_future(self) -> Self::IntoFuture
fn into_future(self) -> Self::IntoFuture
Creates a future from a value. Read more
source§impl TryIntoRequest for UpdateWebhookWithToken<'_>
impl TryIntoRequest for UpdateWebhookWithToken<'_>
Auto Trait Implementations§
impl<'a> Freeze for UpdateWebhookWithToken<'a>
impl<'a> !RefUnwindSafe for UpdateWebhookWithToken<'a>
impl<'a> Send for UpdateWebhookWithToken<'a>
impl<'a> Sync for UpdateWebhookWithToken<'a>
impl<'a> Unpin for UpdateWebhookWithToken<'a>
impl<'a> !UnwindSafe for UpdateWebhookWithToken<'a>
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