public static Task <IReadOnlyList <IInvite> > FetchInvitesAsync(this IGuildChannel channel, IRestRequestOptions options = null, CancellationToken cancellationToken = default) { var client = channel.GetRestClient(); return(client.FetchChannelInvitesAsync(channel.Id, options, cancellationToken)); }
public static Task <IInvite> CreateInviteAsync(this IGuildChannel channel, TimeSpan maxAge = default, int maxUses = 0, bool isTemporaryMembership = false, bool isUnique = false, IRestRequestOptions options = null, CancellationToken cancellationToken = default) { var client = channel.GetRestClient(); return(client.CreateInviteAsync(channel.Id, maxAge, maxUses, isTemporaryMembership, isUnique, options, cancellationToken)); }
public static Task DeleteOverwriteAsync(this IGuildChannel channel, Snowflake targetId, IRestRequestOptions options = null, CancellationToken cancellationToken = default) { var client = channel.GetRestClient(); return(client.DeleteOverwriteAsync(channel.Id, targetId, options, cancellationToken)); }
public static Task SetOverwriteAsync(this IGuildChannel channel, LocalOverwrite overwrite, IRestRequestOptions options = null, CancellationToken cancellationToken = default) { var client = channel.GetRestClient(); return(client.SetOverwriteAsync(channel.Id, overwrite, options, cancellationToken)); }
public static Task <IReadOnlyList <IInvite> > FetchInvitesAsync(this IGuildChannel channel, IRestRequestOptions options = null) { var client = channel.GetRestClient(); return(client.FetchChannelInvitesAsync(channel.Id, options)); }
public static Task DeleteOverwriteAsync(this IGuildChannel channel, Snowflake targetId, IRestRequestOptions options = null) { var client = channel.GetRestClient(); return(client.DeleteOverwriteAsync(channel.Id, targetId, options)); }
public static Task SetOverwriteAsync(this IGuildChannel channel, LocalOverwrite overwrite, IRestRequestOptions options = null) { var client = channel.GetRestClient(); return(client.SetOverwriteAsync(channel.Id, overwrite, options)); }