Show / Hide Table of Contents

Class RestWebhook

Inheritance
System.Object
RestEntity<System.UInt64>
RestWebhook
Implements
IWebhook
IDeletable
ISnowflakeEntity
IEntity<System.UInt64>
IUpdateable
Inherited Members
RestEntity<UInt64>.Id
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: Discord.Rest
Assembly: Discord.Net.Rest.dll
Syntax
public class RestWebhook : RestEntity<ulong>, IWebhook, IDeletable, ISnowflakeEntity, IEntity<ulong>, IUpdateable

Properties

| Improve this Doc View Source

AvatarId

Gets the ID of this webhook's default avatar.

Declaration
public string AvatarId { get; }
Property Value
Type Description
System.String
| Improve this Doc View Source

ChannelId

Gets the ID of the channel for this webhook.

Declaration
public ulong ChannelId { get; }
Property Value
Type Description
System.UInt64
| Improve this Doc View Source

CreatedAt

Gets when the snowflake was created.

Declaration
public DateTimeOffset CreatedAt { get; }
Property Value
Type Description
System.DateTimeOffset

A System.DateTimeOffset representing when the entity was first created.

| Improve this Doc View Source

Creator

Gets the user that created this webhook.

Declaration
public IUser Creator { get; }
Property Value
Type Description
IUser
| Improve this Doc View Source

GuildId

Gets the ID of the guild owning this webhook.

Declaration
public ulong? GuildId { get; }
Property Value
Type Description
System.Nullable<System.UInt64>
| Improve this Doc View Source

Name

Gets the default name of this webhook.

Declaration
public string Name { get; }
Property Value
Type Description
System.String
| Improve this Doc View Source

Token

Gets the token of this webhook.

Declaration
public string Token { get; }
Property Value
Type Description
System.String

Methods

| Improve this Doc View Source

DeleteAsync(RequestOptions)

Deletes this object and all its children.

Declaration
public Task DeleteAsync(RequestOptions options = null)
Parameters
Type Name Description
RequestOptions options

The options to be used when sending the request.

Returns
Type Description
System.Threading.Tasks.Task
| Improve this Doc View Source

GetAvatarUrl(ImageFormat, UInt16)

Gets the URL to this webhook's default avatar.

Declaration
public string GetAvatarUrl(ImageFormat format = ImageFormat.Auto, ushort size = 128)
Parameters
Type Name Description
ImageFormat format
System.UInt16 size
Returns
Type Description
System.String
| Improve this Doc View Source

ModifyAsync(Action<WebhookProperties>, RequestOptions)

Declaration
public Task ModifyAsync(Action<WebhookProperties> func, RequestOptions options = null)
Parameters
Type Name Description
System.Action<WebhookProperties> func
RequestOptions options
Returns
Type Description
System.Threading.Tasks.Task
| Improve this Doc View Source

ToString()

Declaration
public override string ToString()
Returns
Type Description
System.String
Overrides
System.Object.ToString()
| Improve this Doc View Source

UpdateAsync(RequestOptions)

Updates this object's properties with its current state.

Declaration
public Task UpdateAsync(RequestOptions options = null)
Parameters
Type Name Description
RequestOptions options
Returns
Type Description
System.Threading.Tasks.Task

Explicit Interface Implementations

| Improve this Doc View Source

IWebhook.Channel

Gets the channel for this webhook.

Declaration
ITextChannel IWebhook.Channel { get; }
Returns
Type Description
ITextChannel
| Improve this Doc View Source

IWebhook.Guild

Gets the guild owning this webhook.

Declaration
IGuild IWebhook.Guild { get; }
Returns
Type Description
IGuild
| Improve this Doc View Source

IWebhook.ModifyAsync(Action<WebhookProperties>, RequestOptions)

Modifies this webhook.

Declaration
Task IWebhook.ModifyAsync(Action<WebhookProperties> func, RequestOptions options)
Parameters
Type Name Description
System.Action<WebhookProperties> func
RequestOptions options
Returns
Type Description
System.Threading.Tasks.Task

Implements

IWebhook
IDeletable
ISnowflakeEntity
IEntity<TId>
IUpdateable
  • Improve this Doc
  • View Source
Back to top Generated by DocFX