Skip to content

sud.getAppBaseInfo ​

Synchronously gets basic application information.

javascript
const appInfo = sud.getAppBaseInfo();

Parameters ​

None.

Return Value ​

Object.

PropertyTypeDescription
SDKVersionstringCurrent SUD SDK version; the property name is case-sensitive
enableDebugbooleanWhether debug mode is enabled
languagestringApplication language
themestringCurrent theme: light or dark
fontSizeScaleFactornumberFont scaling factor reported by the app
fontSizeSettingnumberFont size setting reported by the app
versionstringHost app version; optional, so check that it exists before using it

Usage Notes ​

This API returns synchronously and does not use callbacks or a Promise. Apps may provide different additional information. Only use optional fields when present, and do not require them to start the game.

Example ​

javascript
const appInfo = sud.getAppBaseInfo();

console.log('SDK version', appInfo.SDKVersion);
console.log('Application language', appInfo.language);
console.log('Dark theme', appInfo.theme === 'dark');

if (appInfo.version) {
  console.log('App version', appInfo.version);
}