Skip to main content

Integration Guide

Supported Channels

Quick Start Guide

Step 1: Install the JavaScript SDK

Install the JavaScript SDK from npm or CDN.

$ npm install @intlsdk/account-api

Step 2: Instantiate SDK

caution

Set env to the test environment https://test.intlgame.com during the integration testing; set env to the corresponding production environment when launching the game.

The parameters for instantiating different functions differ.

Custom account

const accountApi = new IntlgameAccountApi({
env: "test", // SDK environment
langType: "en", //Language
appID: "", //Custom account App ID
accountPlatType: 52, //Custom account channel ID
gameID: 11,
});
ParameterTypeDescriptionRemark
envstringSDK environment
For more information, see Retrieve cluster information
Required
langTypestringLanguage type
For more information, see Language Type Definition - Custom Account
Required
appIDstringApp ID
ACCOUNT_APP_ID assigned by Player Network Console
Required
accountPlatTypenumberThe platform type for custom account
ACCOUNT_PLAT_TYPE assigned by Player Network Console
Required
gameIDnumberPlayer Network unique game IDRequired

Third-party channels

const accountApi = new IntlgameAccountApi({
env: "test", // SDK environment
gameID: 11,
});
ParameterTypeDescriptionRemark
envstringSDK environment
For more information, see Retrieve cluster information
Required
gameIDnumberPlayer Network unique game IDRequired

API

For more information on the friend APIs, see:

APIFunction
shareShare