API reference
Method GetUsernameAsync
- Namespace
- DisCatSharp.Experimental
- Assembly
- DisCatSharp.Experimental.dll
GetUsernameAsync(DiscordClient, ulong, CancellationToken)
This is a test method to test the functionality of DisCatSharp.Experimental and the DisCatSharp.Analyzer.
[Experimental("This function is being tested and might change at any time.")]
[RequiresFeature(Features.MonetizedApplication)]
public static Task<string> GetUsernameAsync(this DiscordClient client, ulong id, CancellationToken cancellationToken = default)
Parameters
clientDiscordClientThe discord client.
idulongThe id of the user to get the username of.
cancellationTokenCancellationTokenA token to cancel the request.