Method GetCharacterByName
- Namespace
- GuildWars2.Hero.Accounts
- Assembly
- GuildWars2.dll
GetCharacterByName(string, string?, MissingMemberBehavior, CancellationToken)
Retrieves the details of a character that belongs to the account associated with the access token. This endpoint is only accessible with a valid access token.
public Task<(Character Value, MessageContext Context)> GetCharacterByName(string characterName, string? accessToken, MissingMemberBehavior missingMemberBehavior = MissingMemberBehavior.Error, CancellationToken cancellationToken = default)
Parameters
characterNamestringA character name that belongs to the account associated with the access token.
accessTokenstringAn API key or subtoken.
missingMemberBehaviorMissingMemberBehaviorThe desired behavior when JSON contains unexpected members.
cancellationTokenCancellationTokenA token to cancel the request.
Returns
- Task<(Character Value, MessageContext Context)>
A task that represents the API request.