How to try account linking in demo
You can implement the following features by linking a player’s account on different platforms to the main account:
- automatic player identification on different platforms
- manage a single cross-platform inventory on different platforms
Use demo scenes to check the linking of platform accounts to the main account for a preset Publisher Account project.
Note
You can link only one account of each platform to the main account.
To try account linking in a demo project:
- Go to your Unity project.
- Set up the demo scene to log in to the application via the platform account:
- In the main menu, go to
Window > Xsolla > Edit Settings . - Set the following parameters in the
Inspector panel:- Specify
Publishing platform . The selected value must be different fromXsolla andNone . - Change
Username from console .
- Specify
- In the main menu, go to

- Start the
Xsollus demo scene from theAssets > Xsolla > DemoCommon > Scene folder.
- Click
User account and thenAccount linking in the demo scene. The demo project will open in the default browser to simulate the start of the application on another platform.


- Click
Create an account .

- Specify email and password. Click
Accept and create .

- Select an item in the catalog and click
Buy on Xsolla . Purchase the item using one of the test bank cards. Close the receipt.

- Click on the email at the top of the screen to open the menu. Click
Inventory . Make sure that the purchased item is available in the inventory.

- Click
Get code . ClickRequest the code in the opened window. Write down the received account linking code.


- Go to the demo scene in Unity.
- Enter the received account linking code (see step 9) and click
Confirm .

- Now the platform account is linked to the main account. Make sure that the purchased item is available in the inventory in the Unity demo scene.

- Since this account is already linked to the main account, you can get the account linking code from it. Click
Get account link . Write down the received code.

- Set up the demo scene to log in to the application via another platform account (see step 2). The
Publishing platform should be different from the one selected in step 2. - Start the
Xsollus demo scene from theAssets > Xsolla > DemoCommon > Scene folder.
- Make sure the player’s inventory is empty.
- Click
Account linking . Stay in the Unity demo scene.
- Enter the received account linking code (see step 13) and click
Confirm .
- Now the account from the new platform is also linked to the main account. Make sure that the purchased item is available in the inventory of the Unity demo scene.
Follow the recipe to configure account linking for your project.
Was this article helpful?
Thank you for your feedback!
We’ll review your message and use it to help us improve your experience.Rate this page
Rate this page
Don’t want to answer
Thank you for your feedback!
Found a typo or other text error? Select the text and press Ctrl+Enter.