Webhook class Null safety

Webhooks are a low-effort way to post messages to channels in Discord. They do not require a bot user or authentication to use.

Implemented types


avatarHash String?
Webhooks avatar hash
late, final
bot bool
True if bot or webhook
read-only, override
channel CacheableTextChannel<TextGuildChannel>?
The webhook's channel, if this is accessed using a normal client and the client has that channel in it's cache.
late, final
client INyxx
Reference to Nyxx object
createdAt DateTime
Gets creation timestamp included in Snowflake
read-only, inherited
defaultAvatarId int
Default webhook avatar id
discriminator int
User Discriminator. -1 if webhook
read-only, override
guild Cacheable<Snowflake, Guild>?
The webhook's guild, if this is accessed using a normal client and the client has that guild in it's cache.
late, final
hashCode int
The hash code for this object. [...]
read-only, inherited
id Snowflake
ID of entity as Snowflake
final, inherited
name String?
The webhook's name.
late, final
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited
tag String
User tag: l7ssha#6712
read-only, override
token String
The webhook's token. Defaults to empty string
late, final
type WebhookType?
Webhook type
late, final
user User?
The user, if this is accessed using a normal client.
late, final
username String
User name
read-only, override


avatarURL({String format = "webp", int size = 128}) String
Url to user avatar
delete({String? auditReason}) Future<void>
Deletes the webhook.
edit({String? name, SnowflakeEntity? channel, AttachmentBuilder? avatarAttachment, String? auditReason}) Future<Webhook>
Edits the webhook.
execute(MessageBuilder builder, {bool? wait, Snowflake? threadId, String? avatarUrl, String? username}) Future<Message?>
Executes webhook. [...]
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
toString() String
Returns a string representation of this object.


operator ==(dynamic other) bool
The equality operator. [...]