Skip to main content

Nintendo

This article guides you through setting up Nintendo Switch as an identity provider, enabling your game to access Player Network authentication services.

caution

Curently, Nintendo Switch channel login is only available for Unreal Engine, while Unity support is planned for a future release.

Prerequisites

1. Register for an account and create the product

Apply for a Nintendo developer account and create your game product first, before proceeding with Player Network configurations.

Required fields:

FieldTypeDescription
application_idstringApplication ID provided by Nintendo
redirect_uristringRedirect URI
client_idstringClient ID provided by Nintendo
client_secretstringClient Secret provided by Nintendo
Create a Nintendo product
  1. Log in to the Nintendo Developer Portal, then select MY PRODUCTS.

  2. Under Products, click Create Product.

    Image: Nintendo Products

  3. Enter the app details. After selecting the Target Delivery Format, options for Target Sales Regions will be shown.

    note

    China should not be selected for the Target Sales Regions.

    Image: Nintendo Products

  4. Click Create to create your product.

2. Publish the game code and obtain an Application ID
  1. From the MY PRODUCTS page, select your product from under Products.

  2. In the top right corner, click Issue Game Code.

    Image: Issue Game Code

  3. Enter the details under Publishing Information.

    Image: Issue Game Code

  4. Click Issue. The Application ID and Game Code will be generated and displayed in the product page.

    Image: Issue Game Code

3. Configure socket and HTTP communication

When creating an online game, the follow information has to be configured to ensure that the game has access to the network.

  1. Log in to OMAS2 with your Nintendo Developer account, then select Products and Releases from the sidebar.

  2. Select your product from the Product List page.

    Image: Socket and HTTP communication usage

  3. Click Latest Release.

    Image: Socket and HTTP communication usage

  4. Under Use Socket or HTTP Communication, click Add Feature Request.

    Image: Socket and HTTP communication usage

  5. Enter the network details for the product, then click OK.

    Image: Socket and HTTP communication usage

4. Apply for a Client ID and Client Secret
caution

A separate set of client_id and client_secret should be applied for the development and release versions, for deployment to different server environments.

  1. Log in to OMAS2 Requests with your Nintendo Developer account.

  2. Enter the required information.

    Image: OMAS2 application and Nintendo linking

    note

    Do not enter China in the Country field.

    During the testing phase, you may enter any redirect URI in the Redirect URI field. However, games should update this field to the actual redirect URI before publishing the game. This field can be modified even after the application is complete.

  3. The client_id and client_secret for this product version will be provided once the application is approved.

  1. Create an account for Player Network Console.
  2. Create a project for your game, or join an existing project.
  3. Download the SDK.
  4. Integrate the SDK.
  5. Add Nintendo as an authentication method for your project on Player Network Console.

Step 1: Add Nintendo Login

note

There is no need to configure Nintendo account information in INTLConfig.ini.

  1. Add an observer to handle authentication callbacks.

    //configure callback
    FINTLAuthEvent authEvent;
    authEvent.AddUObject(this, &OnAuthResult_Implementation);
    UINTLSDKAPI::SetAuthResultObserver(authEvent);
    // Remove callbacks
    UINTLSDKAPI::GetAuthResultObserver().Clear();

    void OnAuthResult_Implementation(FINTLAuthResult ret)
    {
    UE_LOG(LogTemp, Warning, TEXT("MethodID: %d"), ret.MethodId);
    }

    void OnAuthResult_Implementation(FINTLAuthResult ret)
    {
    UE_LOG(LogTemp, Warning, TEXT("MethodID: %d"), ret.MethodId);
    }
  2. Call the AutoLogin method.

    UINTLSDKAPI::AutoLogin();
  3. Call the Login method to ask for user input if auto-login fails.

    UINTLSDKAPI::Login(EINTLLoginChannel::kChannelNintendo);
  4. Sync client authentication state with the game's backend and wait for the final authentication result.

Step 2: Package and configure URL allowlist

For Nintendo, an allowlist has to be configured to load URLs with the system browser. Player Network SDK has provided a list of URLs that are required in the LI PASS compliance process, the URLs should be added to the URL allowlist in the game project.

The AccessibleUrls.txt file can be found within the Switch folder under the INTLCore plugin:

Nintendo_AccessibleUrl_Txt_File

The corresponding allowlist URLs in AccessibleUrls.txt are:

^https://test\.account\.levelinfinite\.com/(.*)
^https://account\.levelinfinite\.com/(.*)
^https://www\.levelinfinite\.com/(.*)
^https://test\.account\.levelinfinite\.com/(.*)
^https://test-common-web\.intlgame\.com/(.*)
^https://common-web\.intlgame\.com/(.*)
^https://test\.intlgame\.com/(.*)
note

When building the package for Nintendo, the Application Id has to be configured in the project settings by entering the Application ID provided by Nintendo.

Nintendo_Package_Setting

Step 3: Test the login function

Search for the keyword "AuthResult" in the Player Network SDK logs to verify if the correct channel name and OpenID are returned. If they are, it indicates a successful configuration and the login function has been added successfully.