@discord-types/builders/message/allowedMention
API reference for @discord-types/builders/message/allowedMention
@discord-types/builders/message/allowedMention
Types
AllowedMention
Raw Type
type AllowedMention = AllowedMention.Prototype, & {
parse: {apiTypes.AllowedMentionTypes},
roles: {apiTypes.Snowflake},
users: {apiTypes.Snowflake},
repliedUser: boolean?
}
Intersection with variants:
Variant 2
JSON
Raw Type
type JSON = AllowedMention.Prototype.build(nil :: any),
Functions
AllowedMention.Prototype.addUserMention
[[ Add a user mention to the allowed mentions for this message. ]]
Function Signature
--[[
Add a user mention to the allowed mentions for this message.
]]
function AllowedMention.Prototype.addUserMention(self: AllowedMention, userId: string) -> AllowedMention end
Arguments
userId
Returns
ret1
AllowedMention.Prototype.addRoleMention
[[ Add a role mention to the allowed mentions for this message. ]]
Function Signature
--[[
Add a role mention to the allowed mentions for this message.
]]
function AllowedMention.Prototype.addRoleMention(self: AllowedMention, roleId: string) -> AllowedMention end
Arguments
roleId
Returns
ret1
AllowedMention.Prototype.setRepliedUser
[[ For replies, whether to mention the author of the message being replied to (default false) ]]
Function Signature
--[[
For replies, whether to mention the author of the message being replied to (default false)
]]
function AllowedMention.Prototype.setRepliedUser(self: AllowedMention, repliedUser: boolean) -> AllowedMention end
Arguments
repliedUser
Returns
ret1
AllowedMention.Prototype.setMentionsEveryone
[[ Controls @everyone and @here mentions ]]
Function Signature
--[[
Controls @everyone and @here mentions
]]
function AllowedMention.Prototype.setMentionsEveryone(self: AllowedMention, mentionsEveryone: boolean) -> AllowedMention end
Arguments
mentionsEveryone
Returns
ret1
AllowedMention.Prototype.build
[[ Responsible for building the AllowedMention JSON that can be parsed by the Discord API. ]]
Function Signature
--[[
Responsible for building the AllowedMention JSON that can be parsed by the Discord API.
]]
function AllowedMention.Prototype.build(self: AllowedMention) -> JSON end
Returns
ret1
AllowedMention.Interface.new
[[ Responsible for creating a new AllowedMention.
```lua
``` ]]
Function Signature
--[[
Responsible for creating a new AllowedMention.
\`\`\`lua
\`\`\`
]]
function AllowedMention.Interface.new(resource: {
roles: {apiTypes.Snowflake},
users: {apiTypes.Snowflake},
repliedUser: boolean?,
mentionsEveryone: boolean?
}?) -> AllowedMention end
Arguments
resource
This field is optional and may not be specified
{roles: {apiTypes.Snowflake}, users: {apiTypes.Snowflake}, repliedUser: boolean?, mentionsEveryone: boolean?}?
Returns
ret1
Last updated on