Table of Contents

LinkJwt

Methods
public PlayerAccountOperation LinkJwt(string token, bool force = false, CancellationToken cancellationToken = default)

Adds custom JSON Web Token (JWT) authentication to the current player account.

Parameters
Type Name Description
string token

JSON Web Token (JWT) to link.

Signed with an asymmetric algorithm (such as RS256 or ES256). Must contain a valid “sub” value which is the external unique player ID.

bool force

If the JWT is already linked to another player account, and a force value of false is passed, then an error will be returned.

If the JWT is already linked to another player account, and a force value of true is passed, then the JWT will be unlinked from the other player account, and linked to this one.

WARNING: If the JWT is unlinked from another player account, and that other player account has no other authentication methods set up, then access to that player account will be lost.

CancellationToken cancellationToken

Can be used to cancel the operation.

Returns
Type Description
PlayerAccountOperation

Result of the operation.