Method ModifyPositionAsync
- Namespace
- DSharpPlus.Entities
- Assembly
- DSharpPlus.dll
ModifyPositionAsync(int, string, bool?, ulong?)
Updates the channel position
public Task ModifyPositionAsync(int position, string reason = null, bool? lockPermissions = null, ulong? parentId = null)
Parameters
positionintPosition the channel should be moved to.
reasonstringReason for audit logs.
lockPermissionsbool?Whether to sync channel permissions with the parent, if moving to a new category.
parentIdulong?The new parent ID if the channel is to be moved to a new category.
Returns
Exceptions
- UnauthorizedException
Thrown when the client does not have the ManageChannels permission.
- NotFoundException
Thrown when the channel does not exist.
- BadRequestException
Thrown when an invalid parameter was provided.
- ServerErrorException
Thrown when Discord is unable to process the request.