Enum twilight_http::routing::Path [−][src]
#[non_exhaustive]
pub enum Path {
Show 70 variants
ApplicationCommand(u64),
ApplicationCommandId(u64),
ApplicationGuildCommand(u64),
ApplicationGuildCommandId(u64),
ChannelsId(u64),
ChannelsIdInvites(u64),
ChannelsIdMessages(u64),
ChannelsIdMessagesBulkDelete(u64),
ChannelsIdMessagesId(Method, u64),
ChannelsIdMessagesIdCrosspost(u64),
ChannelsIdMessagesIdReactions(u64),
ChannelsIdMessagesIdReactionsUserIdType(u64),
ChannelsIdMessagesIdThreads(u64),
ChannelsIdPermissionsOverwriteId(u64),
ChannelsIdPins(u64),
ChannelsIdPinsMessageId(u64),
ChannelsIdRecipients(u64),
ChannelsIdThreadMembers(u64),
ChannelsIdThreads(u64),
ChannelsIdTyping(u64),
ChannelsIdWebhooks(u64),
ChannelsIdFollowers(u64),
Gateway,
GatewayBot,
Guilds,
GuildsId(u64),
GuildsIdBans(u64),
GuildsIdBansId(u64),
GuildsIdAuditLogs(u64),
GuildsIdBansUserId(u64),
GuildsIdChannels(u64),
GuildsIdWidget(u64),
GuildsIdEmojis(u64),
GuildsIdEmojisId(u64),
GuildsIdIntegrations(u64),
GuildsIdIntegrationsId(u64),
GuildsIdIntegrationsIdSync(u64),
GuildsIdInvites(u64),
GuildsIdMembers(u64),
GuildsIdMembersId(u64),
GuildsIdMembersIdRolesId(u64),
GuildsIdMembersMeNick(u64),
GuildsIdMembersSearch(u64),
GuildsIdPreview(u64),
GuildsIdPrune(u64),
GuildsIdRegions(u64),
GuildsIdRoles(u64),
GuildsIdRolesId(u64),
GuildsIdStickers(u64),
GuildsIdTemplates(u64),
GuildsIdTemplatesCode(u64),
GuildsIdThreads(u64),
GuildsIdVanityUrl(u64),
GuildsIdVoiceStates(u64),
GuildsIdWelcomeScreen(u64),
GuildsIdWebhooks(u64),
InvitesCode,
InteractionCallback(u64),
StageInstances,
StickerPacks,
Stickers,
UsersId,
OauthApplicationsMe,
UsersIdConnections,
UsersIdChannels,
UsersIdGuilds,
UsersIdGuildsId,
VoiceRegions,
WebhooksIdTokenMessagesId(u64),
WebhooksId(u64),
}Expand description
An enum representing a path, most useful for ratelimiting implementations.
Variants (Non-exhaustive)
This enum is marked as non-exhaustive
ApplicationCommand(u64)Operating on global commands.
Tuple Fields of ApplicationCommand
0: u64ApplicationCommandId(u64)Operating on a specific command.
Tuple Fields of ApplicationCommandId
0: u64ApplicationGuildCommand(u64)Operating on commands in a guild.
Tuple Fields of ApplicationGuildCommand
0: u64ApplicationGuildCommandId(u64)Operating on a specific command in a guild.
Tuple Fields of ApplicationGuildCommandId
0: u64ChannelsId(u64)Operating on a channel.
Tuple Fields of ChannelsId
0: u64ChannelsIdInvites(u64)Operating on a channel’s invites.
Tuple Fields of ChannelsIdInvites
0: u64ChannelsIdMessages(u64)Operating on a channel’s messages.
Tuple Fields of ChannelsIdMessages
0: u64ChannelsIdMessagesBulkDelete(u64)Operating on a channel’s messages by bulk deleting.
Tuple Fields of ChannelsIdMessagesBulkDelete
0: u64Operating on an individual channel’s message.
ChannelsIdMessagesIdCrosspost(u64)Crossposting an individual channel’s message.
Tuple Fields of ChannelsIdMessagesIdCrosspost
0: u64ChannelsIdMessagesIdReactions(u64)Operating on an individual channel’s message’s reactions.
Tuple Fields of ChannelsIdMessagesIdReactions
0: u64ChannelsIdMessagesIdReactionsUserIdType(u64)Operating on an individual channel’s message’s reactions while specifying the user ID and emoji type.
Tuple Fields of ChannelsIdMessagesIdReactionsUserIdType
0: u64ChannelsIdMessagesIdThreads(u64)Operating on an individual channel’s message’s threads.
Tuple Fields of ChannelsIdMessagesIdThreads
0: u64ChannelsIdPermissionsOverwriteId(u64)Operating on a channel’s permission overwrites by ID.
Tuple Fields of ChannelsIdPermissionsOverwriteId
0: u64ChannelsIdPins(u64)Operating on a channel’s pins.
Tuple Fields of ChannelsIdPins
0: u64ChannelsIdPinsMessageId(u64)Operating on a channel’s individual pinned message.
Tuple Fields of ChannelsIdPinsMessageId
0: u64ChannelsIdRecipients(u64)Operating on a group DM’s recipients.
Tuple Fields of ChannelsIdRecipients
0: u64ChannelsIdThreadMembers(u64)Operating on a thread’s members.
Tuple Fields of ChannelsIdThreadMembers
0: u64ChannelsIdThreads(u64)Operating on a channel’s threads.
Tuple Fields of ChannelsIdThreads
0: u64ChannelsIdTyping(u64)Operating on a channel’s typing indicator.
Tuple Fields of ChannelsIdTyping
0: u64ChannelsIdWebhooks(u64)Operating on a channel’s webhooks.
Tuple Fields of ChannelsIdWebhooks
0: u64ChannelsIdFollowers(u64)Operating on a channel’s followers.
Tuple Fields of ChannelsIdFollowers
0: u64Operating with the gateway information.
Operating with the gateway information tailored to the current user.
Operating on the guild resource.
GuildsId(u64)Operating on one of user’s guilds.
Tuple Fields of GuildsId
0: u64GuildsIdBans(u64)Tuple Fields of GuildsIdBans
0: u64GuildsIdBansId(u64)Tuple Fields of GuildsIdBansId
0: u64GuildsIdAuditLogs(u64)Tuple Fields of GuildsIdAuditLogs
0: u64GuildsIdBansUserId(u64)Tuple Fields of GuildsIdBansUserId
0: u64GuildsIdChannels(u64)Tuple Fields of GuildsIdChannels
0: u64GuildsIdWidget(u64)Tuple Fields of GuildsIdWidget
0: u64GuildsIdEmojis(u64)Tuple Fields of GuildsIdEmojis
0: u64GuildsIdEmojisId(u64)Tuple Fields of GuildsIdEmojisId
0: u64GuildsIdIntegrations(u64)Tuple Fields of GuildsIdIntegrations
0: u64GuildsIdIntegrationsId(u64)Tuple Fields of GuildsIdIntegrationsId
0: u64GuildsIdIntegrationsIdSync(u64)Tuple Fields of GuildsIdIntegrationsIdSync
0: u64GuildsIdInvites(u64)Tuple Fields of GuildsIdInvites
0: u64GuildsIdMembers(u64)Tuple Fields of GuildsIdMembers
0: u64GuildsIdMembersId(u64)Tuple Fields of GuildsIdMembersId
0: u64GuildsIdMembersIdRolesId(u64)Tuple Fields of GuildsIdMembersIdRolesId
0: u64GuildsIdMembersMeNick(u64)Tuple Fields of GuildsIdMembersMeNick
0: u64GuildsIdMembersSearch(u64)Tuple Fields of GuildsIdMembersSearch
0: u64GuildsIdPreview(u64)Tuple Fields of GuildsIdPreview
0: u64GuildsIdPrune(u64)Tuple Fields of GuildsIdPrune
0: u64GuildsIdRegions(u64)Tuple Fields of GuildsIdRegions
0: u64GuildsIdRoles(u64)Tuple Fields of GuildsIdRoles
0: u64GuildsIdRolesId(u64)Tuple Fields of GuildsIdRolesId
0: u64GuildsIdStickers(u64)Tuple Fields of GuildsIdStickers
0: u64GuildsIdTemplates(u64)Tuple Fields of GuildsIdTemplates
0: u64GuildsIdTemplatesCode(u64)Tuple Fields of GuildsIdTemplatesCode
0: u64GuildsIdThreads(u64)Tuple Fields of GuildsIdThreads
0: u64GuildsIdVanityUrl(u64)Tuple Fields of GuildsIdVanityUrl
0: u64GuildsIdVoiceStates(u64)Tuple Fields of GuildsIdVoiceStates
0: u64GuildsIdWelcomeScreen(u64)Tuple Fields of GuildsIdWelcomeScreen
0: u64GuildsIdWebhooks(u64)Tuple Fields of GuildsIdWebhooks
0: u64InteractionCallback(u64)Operating on an interaction’s callback.
Tuple Fields of InteractionCallback
0: u64Operating on the state of a guild that the user is in.
Operating on the state of a guild that the user is in.
Operating on the voice regions available to the current user.
WebhooksIdTokenMessagesId(u64)Operating on a message created by a webhook.
Tuple Fields of WebhooksIdTokenMessagesId
0: u64WebhooksId(u64)Operating on a webhook.
Tuple Fields of WebhooksId
0: u64Trait Implementations
Parses a string into a path.
The string may start with a slash (/), which will be ignored.
Examples
use twilight_http::routing::Path;
use std::str::FromStr;
assert_eq!(Path::VoiceRegions, Path::from_str("/voice/regions")?);
assert_eq!(
Path::ChannelsIdMessages(123),
Path::from_str("channels/123/messages")?,
);type Err = PathParseError
type Err = PathParseError
The associated error which can be returned from parsing.
Auto Trait Implementations
impl RefUnwindSafe for Path
impl UnwindSafe for Path
Blanket Implementations
Mutably borrows from an owned value. Read more
Compare self to key and return true if they are equal.
pub fn vzip(self) -> V
Attaches the provided Subscriber to this type, returning a
WithDispatch wrapper. Read more
Attaches the current default Subscriber to this type, returning a
WithDispatch wrapper. Read more