Search Unity

  1. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Official Authentication now supports Code Link!

Discussion in 'Authentication' started by chengg_unity, Aug 25, 2023.

  1. chengg_unity

    chengg_unity

    Unity Technologies

    Joined:
    May 15, 2022
    Posts:
    68
    Hello everyone,

    We are excited to announce that Code Link is now live with Authentication 3.0.0! This feature allows players to easily switch devices or platforms by using a generated code, all without the need to input their login credentials.

    Before Code Link, the support for cross-platform or cross-progression was limited. For example, there wasn't an easy way for a player on Steam to continue their progress on consoles. Now, with Code Link, an authenticated player can seamlessly sign in to any other platform or device.

    Demo
    You can see it in action here:
    upload_2023-8-25_11-54-29.gif


    Documentation
    You can refer to our documentation (API and SDK) on how to set up and configure Code Link.
     
  2. Christoffell

    Christoffell

    Joined:
    Jun 12, 2023
    Posts:
    4
    Very cool! Was just looking for something like this and found the announcement.

    I have updated the Authentication package but I'm having issues. The updated codebase doesn't recognise
    GenerateCodeAsync (and possibly some of the other new functions).

    Did I do the update wrong? Or is this a bug?
     
  3. MiTschMR

    MiTschMR

    Joined:
    Aug 28, 2018
    Posts:
    455
    Can you share more information, for example the version of your authentication package, the code that throws the error and the full error message?
     
  4. Christoffell

    Christoffell

    Joined:
    Jun 12, 2023
    Posts:
    4
    No error message, VS code just doesnt show the package has any of the new functions.

    The version of Authentication is 3.0.0, and Roslyn doesn't identify the method:
    https://imgur.com/a/K23k2Hh

     
  5. MiTschMR

    MiTschMR

    Joined:
    Aug 28, 2018
    Posts:
    455
    Does it also show the errors inside Unity? I don‘t see the second and third screenshot, they are unavailable. Have you tried it with a different IDE like VS or Rider?
     
  6. erickb_unity

    erickb_unity

    Unity Technologies

    Joined:
    Sep 1, 2021
    Posts:
    89
    I just verified and noticed a small error, it should be GenerateSignInCodeAsync.
    The documentation is showing GenerateCodeAsync, we will update it.
     
  7. Christoffell

    Christoffell

    Joined:
    Jun 12, 2023
    Posts:
    4
    Thanks this solved it. Couldn't see the standard procedures up until now. Just a note: the SDK page's code examples as well as the diagrams still show GenerateCodeAsync. I think blindly copying the examples is what led me to my error the first time.