Get started

Integrating with Xsolla servers is suitable for partners who want a ready-made server solution for monetization and in-game items management.

After integration of Xsolla SDKs, you can use:

With this integration, all operations are processed on the Xsolla side and you do not have to configure your own server side for these tasks.

Choose and install one of the following assets depending on your needs:

  • Store Unity SDK — contains all the necessary methods to integrate all Xsolla products listed above.
  • Login Unity SDK — designed to implement only the functions of the Xsolla Login.
  • Inventory Unity SDK — designed to implement functions of the Xsolla Login and the Player Inventory. Use this asset if your application is published on a platform that cannot use the Xsolla Pay Station and In-Game Store for some reason.

Notice
All assets are not compatible with each other. Choose and integrate only one asset that best suits your needs.

Requirements

System requirements

  • 64-bit OS
  • Windows 7 SP1 and higher
  • macOS 10.12 and higher
  • A compatible version of Unity:
    • 2018.4.30f1
    • 2019.3.4f1

Target OS

  • iOS
  • Android
  • macOS
  • Windows 64-bit
Additionally, the SDK supports creating WebGL build to run your application in a browser.
Note
We recommend you use the Mono compiler for desktop platforms as it's compatible with the provided in-game browser. If you use other browser solutions, you can use the IL2CPP compiler instead. To create game builds for Android, you can use either Mono or IL2CPP compilers.

Features

Login Unity SDK features

The Login Unity SDK is used to integrate applications based on Unity with Xsolla Login. Main features:
  • authentication via username and password
  • authentication via social networks
  • authentication via Facebook and Google apps on Android devices
  • authentication via Steam session_ticket
  • signup
  • email confirmation
  • password reset
  • user attributes management
  • cross-platform account linking
  • token invalidation
  • OAuth 2.0 support
  • friend system
  • user account

Inventory Unity SDK features

The Inventory Unity SDK is used to integrate applications based on Unity with the Xsolla Login and Player Inventory. The Inventory Unity SDK supports all Login Unity SDK features and additionally the following features:
  • managing user inventory
  • managing virtual currency balance
  • working with coupons
  • managing cross-platform inventory

Store Unity SDK features

The Store Unity SDK is used to integrate applications based on Unity with the following Xsolla products:Store Unity SDK supports all Login Unity SDK features and additionally the following features:
  • selling virtual items
  • selling virtual currency
  • managing in-game store
  • working with promotional campaigns (discounts, coupons, promo codes)

Note
To enable cross-platform account linking, email the Xsolla integration team (integration@xsolla.com). Follow the account linking how-to to try this function in the demo.

Privacy policy

If you use the SDK, add the Xsolla Privacy Policy Agreement link to your application. You can see the example of this link in the demo project on the sign up page.

Note
Note that the Xsolla Privacy Policy Agreement doesn’t mean user data will be used. If you plan to collect and process this kind of data, make sure that your actions comply with the law. You should ask users for their permission to collect and process their data or inform them about the Privacy Policy Agreement.

Charge policy

Xsolla offers the necessary tools to help you build and grow your gaming business, including personalized support at every stage. The terms of payment are determined by the contract that can be signed via Publisher Account.

The cost of using all Xsolla products is 5% of the amount you receive for the sale of the game and in-game goods via the Xsolla Pay Station. If you do not use the Xsolla Pay Station in your application, but use other products, contact your Account Manager to clarify the terms and conditions.

Prerequisites

Before integrating Unity SDKs, follow these steps:

  1. Install the asset.
  2. Set up the project in your Publisher Account.

Install the asset

  1. Download Unity.
  2. Pick a personal or professional Unity license based on your preferences.
  3. Create a new Unity project.
  4. Download one of the assets:

  1. Add a Xsollus demo scene in build settings:
    1. Go to Assets > Xsolla > DemoCommon > Scene and launch the Xsollus scene.
    2. Open File > Build settings and click Add Open Scenes.

  1. Make sure that the Mono compiler is used for creating a game build (optional):
    1. Click Edit > Project Settings in the main menu.
    2. Go to Other Settings > Configuration block.
    3. Make sure that Mono is chosen in the Scripting Backend field.

After installing the asset, launch the Store demo scene that shows how SDKs features work.

Set up the project in your Publisher Account

  1. Register an Xsolla Publisher Account.
  2. Configure a Publisher Account project that is automatically created after the previous step:
    1. Click My game in the Projects block and go to Project settings.
    2. In setup mode, specify a Project name and click Save.

    1. Go to Integration settings and check that the Integrate Commerce API toggle is set to On.

During the integration process, you will need the following parameters:

  • Project ID found in Project settings > Project ID.

  • Login ID found in Login settings > Login ID. It has the UUID format.

Demo

To demonstrate the functionality of integration with Xsolla servers, we provide the Xsollus demo scene. It is available in the Assets > Xsolla > DemoCommon > Scene > Xsollus folder. Use it as an example.

For the demo scene, a project in Publisher Account is preset and an in-game store is fully configured. When you launch the Xsollus demo scene, the sign-up/login page is displayed. If the authorization is successful, the main menu opens.

Default values for the Xsollus demo scene:

KeyValue
Login ID026201e3-7e40-11ea-a85b-42010aa80004
Project ID77640
Was this article helpful?
Thank you!
Is there anything we can improve? Message
We're sorry to hear that
Please explain why this article wasn't helpful to you. Message
Thank you for your feedback!
We'll review your message and use it to help us improve your experience.

Continue reading