docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Method GenerateSignInCodeAsync

    GenerateSignInCodeAsync(string)

    Asynchronously generates a sign-in code that can be used to sign in. This method should be called before attempting to sign in using the sign-in code.

    Declaration
    Task<SignInCodeInfo> GenerateSignInCodeAsync(string identifier = null)
    Parameters
    Type Name Description
    string identifier

    An optional identifier. If provided, it may influence the generated sign-in code or be used for additional checks.

    Returns
    Type Description
    Task<SignInCodeInfo>

    A Task representing the asynchronous generation operation. The task result contains the generated SignInCodeInfo details:

    • SignInCodeThe unique code generated for signing in. This code should be used in subsequent sign-in attempts.
    • ExpirationThe date and time when the generated sign-in code will expire and become invalid for sign-in attempts.
    Exceptions
    Type Condition
    AuthenticationException

    Thrown when the current authentication state is invalid for this operation.

    In This Article
    Back to top
    Copyright © 2023 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookie Policy
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)