pub struct UpdateCurrentUserApplication<'a> { /* private fields */ }
Expand description
Update the current user’s application.
Returns the newly updated application.
Refer to Discord Docs/Update Current User Application.
§Examples
use std::env;
use twilight_http::Client;
let bearer_token = env::var("BEARER_TOKEN")?;
let client = Client::new(bearer_token);
let response = client
.update_current_user_application()
.description("My cool application")
.await?;
let application = response.model().await?;
println!("Application: {}", application.description);
Implementations§
source§impl<'a> UpdateCurrentUserApplication<'a>
impl<'a> UpdateCurrentUserApplication<'a>
sourcepub const fn cover_image(self, cover_image: Option<&'a str>) -> Self
pub const fn cover_image(self, cover_image: Option<&'a str>) -> Self
Sets the cover image of the application.
sourcepub const fn custom_install_url(self, custom_install_url: &'a str) -> Self
pub const fn custom_install_url(self, custom_install_url: &'a str) -> Self
Sets the custom install URL of the application.
sourcepub const fn description(self, description: &'a str) -> Self
pub const fn description(self, description: &'a str) -> Self
Sets the description of the application.
sourcepub const fn flags(self, flags: ApplicationFlags) -> Self
pub const fn flags(self, flags: ApplicationFlags) -> Self
Sets the flags of the application.
Only limited intent flags (GATEWAY_PRESENCE_LIMITED
, GATEWAY_GUILD_MEMBERS_LIMITED
,
and GATEWAY_MESSAGE_CONTENT_LIMITED
) can be updated via the API.
sourcepub fn install_params(self, install_params: InstallParams) -> Self
pub fn install_params(self, install_params: InstallParams) -> Self
Sets the install params of the application.
pub fn integrations_types_config( self, guild: Option<InstallParams>, user: Option<InstallParams>, ) -> Self
sourcepub const fn interactions_endpoint_url(
self,
interactions_endpoint_url: &'a str,
) -> Self
pub const fn interactions_endpoint_url( self, interactions_endpoint_url: &'a str, ) -> Self
Sets the interactions endpoint URL of the application.
sourcepub const fn role_connections_verification_url(
self,
role_connections_verification_url: &'a str,
) -> Self
pub const fn role_connections_verification_url( self, role_connections_verification_url: &'a str, ) -> Self
Sets the role connections verification URL of the application.
Sets the tags of the application.
Trait Implementations§
source§impl IntoFuture for UpdateCurrentUserApplication<'_>
impl IntoFuture for UpdateCurrentUserApplication<'_>
source§type Output = Result<Response<Application>, Error>
type Output = Result<Response<Application>, Error>
The output that the future will produce on completion.
source§type IntoFuture = ResponseFuture<Application>
type IntoFuture = ResponseFuture<Application>
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 UpdateCurrentUserApplication<'_>
impl TryIntoRequest for UpdateCurrentUserApplication<'_>
Auto Trait Implementations§
impl<'a> Freeze for UpdateCurrentUserApplication<'a>
impl<'a> !RefUnwindSafe for UpdateCurrentUserApplication<'a>
impl<'a> Send for UpdateCurrentUserApplication<'a>
impl<'a> Sync for UpdateCurrentUserApplication<'a>
impl<'a> Unpin for UpdateCurrentUserApplication<'a>
impl<'a> !UnwindSafe for UpdateCurrentUserApplication<'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