Interface ISteamSignInTokenStore
The Steam sign-in refresh token and the account it belongs to, held for the current session of whatever hosts it — what lets a fresh partner-site cookie be minted without scanning the QR code again.
Namespace: Serenity.Steam.Application.SignIn
Assembly: Serenity.Steam.Application.dll
Syntax
public interface ISteamSignInTokenStore
Remarks
Never log an instance raw: describe it through the implementation's redacting ToString.
Properties
HasToken
Declaration
bool HasToken { get; }
Property Value
| Type | Description |
|---|---|
| bool | Whether a sign-in token is available, in memory or in the session's backing state. |
Methods
Clear()
Forgets the stored sign-in, in memory and in the session's backing state.
Declaration
void Clear()
Store(string, string)
Stores the sign-in, in memory and mirrored to the session's backing state.
Declaration
void Store(string refreshToken, string accountName)
Parameters
| Type | Name | Description |
|---|---|---|
| string | refreshToken | The refresh token the QR sign-in yielded. |
| string | accountName | The Steam account the token belongs to. |
Exceptions
| Type | Condition |
|---|---|
| ArgumentException | When |
| ArgumentNullException | When |
TryGet(out string, out string)
Reads back the stored sign-in.
Declaration
bool TryGet(out string refreshToken, out string accountName)
Parameters
| Type | Name | Description |
|---|---|---|
| string | refreshToken | The refresh token found, or empty when none is stored. |
| string | accountName | The account the token belongs to, or empty when none is stored. |
Returns
| Type | Description |
|---|---|
| bool | Whether a sign-in token is available. |