Class RestInvite
Inherited Members
Namespace: Discord.Rest
Assembly: Discord.Net.Rest.dll
Syntax
public class RestInvite : RestEntity<string>, IInvite, IEntity<string>, IDeletable, IUpdateable
Properties
| Improve this Doc View SourceChannelId
Gets the ID of the channel this invite is linked to.
Declaration
public ulong ChannelId { get; }
Property Value
| Type | Description |
|---|---|
| System.UInt64 | An System.UInt64 representing the channel snowflake identifier that the invite points to. |
ChannelName
Gets the name of the channel this invite is linked to.
Declaration
public string ChannelName { get; }
Property Value
| Type | Description |
|---|---|
| System.String | A string containing the name of the channel that the invite points to. |
ChannelType
Declaration
public ChannelType ChannelType { get; }
Property Value
| Type | Description |
|---|---|
| ChannelType |
Code
Gets the unique identifier for this invite.
Declaration
public string Code { get; }
Property Value
| Type | Description |
|---|---|
| System.String | A string containing the invite code (e.g. |
GuildId
Gets the ID of the guild this invite is linked to.
Declaration
public ulong? GuildId { get; }
Property Value
| Type | Description |
|---|---|
| System.Nullable<System.UInt64> | An System.UInt64 representing the guild snowflake identifier that the invite points to. |
GuildName
Gets the name of the guild this invite is linked to.
Declaration
public string GuildName { get; }
Property Value
| Type | Description |
|---|---|
| System.String | A string containing the name of the guild that the invite points to. |
MemberCount
Gets the approximated count of total members in the guild.
Declaration
public int? MemberCount { get; }
Property Value
| Type | Description |
|---|---|
| System.Nullable<System.Int32> | An System.Int32 representing the approximated total member count of the guild that the
invite points to; |
PresenceCount
Gets the approximated count of online members in the guild.
Declaration
public int? PresenceCount { get; }
Property Value
| Type | Description |
|---|---|
| System.Nullable<System.Int32> | An System.Int32 representing the approximated online member count of the guild that the
invite points to; |
Url
Gets the URL used to accept this invite using Code.
Declaration
public string Url { get; }
Property Value
| Type | Description |
|---|---|
| System.String | A string containing the full invite URL (e.g. |
Methods
| Improve this Doc View SourceDeleteAsync(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 |
ToString()
Gets the URL of the invite.
Declaration
public override string ToString()
Returns
| Type | Description |
|---|---|
| System.String | A string that resolves to the Url of the invite. |
Overrides
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 SourceIInvite.Channel
Gets the channel this invite is linked to.
Declaration
IChannel IInvite.Channel { get; }
Returns
| Type | Description |
|---|---|
| IChannel | A generic channel that the invite points to. |
IInvite.Guild
Gets the guild this invite is linked to.
Declaration
IGuild IInvite.Guild { get; }
Returns
| Type | Description |
|---|---|
| IGuild | A guild object representing the guild that the invite points to. |