Skip to main content
There are many options to customize the SDK to your needs. Theymes provides flexible way of configuring the SDK either by passing a TheymesConfig object to functions or by setting configuration options directly in the TheymesSdk class, in which case they are persisted and passed to the help center when opened later. You can even use both methods together. When Theymes opens the help center it will merge the configuration options from both methods.
Prefer persisting configuration optionsPersisting the options such as fields and tags is preferred, as it ensures that the help center will always open with the correct configuration and allows other SDK features to use them.

Language

ISO 639-1 language code in which the help center should be displayed. If not set, we will prefer the language of the device the game is running on, and if that is not available, we will default to English. Note, some languages do not support two-letter ISO-639-1 code, so for those languages you need to give the three-letter ISO-639-2 code. You can specify any languages that are configured for your game in the Theymes application. Please check your game settings in the Theymes application to see available values.
Example

Player

There are two ways to set the player information. You can either set it using the TheymesSdk.SetPlayer() method, or by using our Player Verification feature. With the Player Verification feature you get a signed token from your backend which you can pass to the SDK with TheymesSdk.SetSignedMetadataToken() method.
Player VerificationThe Player Verification allows you to verify the identity of your players. For example if someone opens a support ticket, you can be sure that the player information and optionally other metadata is correct and not tampered with.
Example
If you use Player Verification with expiring tokens, subscribe to TheymesSdk.onSignedMetadataTokenExpirationUpdated. It is called once a minute with the remaining expiration time in seconds, and may be 0 or negative if the current token is already expired. Your game decides when to refresh the token based on this value. The value is calculated from the client’s clock, so if the clock is not in sync, the reported expiration time is skewed too. All player fields are optional, however it is highly recommended to set at least the id field, otherwise the player will be considered as an anonymous player. See our Player Metadata documentation for more information about the player fields.

Tags

Tags are used to categorize the support tickets. You can specify any tags that are configured for your game in the Theymes application. Please check your game settings in the Theymes application to see available values. Tags that are not configured for your game will be ignored.
Example
There are more functions to manage tags. See the API Reference for more information.

Fields

Fields are used to pass additional information about the player to the help center. You can specify any fields that are configured for your game in the Theymes application. Please check your game settings in the Theymes application to see available values. Fields that are not configured for your game will be ignored.
Example
There are more functions to manage fields. See the API Reference for more information. Breadcrumbs are short diagnostic messages you can add before opening support. They are useful for describing recent game events, such as the player opening a menu, starting a mission, or hitting an error.
Example
The SDK timestamps breadcrumbs automatically and includes them when you call TheymesSdk.OpenSupport(), TheymesSdk.OpenSupportAsync(), TheymesSdk.OpenResource(), or TheymesSdk.OpenResourceAsync(). Breadcrumbs are kept in memory only, bounded by SDK settings, and cleared when you call TheymesSdk.ClearBreadcrumbs() or TheymesSdk.Reset(). Do not include personal data, secrets, or other sensitive information in breadcrumbs.

WebGL options

When building for WebGL, you can pass InitializeOptions.web to TheymesSdk.Initialize() to customize WebGL-specific behavior.

Canvas selector

If your game has multiple canvases, the SDK needs to know which one to use. By default, the SDK looks for #unity-canvas, #unityCanvas, or the first canvas element. If your game uses a different canvas (for example #gameCanvas), pass a custom selector:
Example

Nonce (Content Security Policy)

If you use Content Security Policy (CSP) with a nonce for inline scripts and styles, pass the same nonce to the SDK so it can inject it into its inline content:
Example
Generate a random nonce when the page is rendered and use it in both your CSP header (e.g. 'nonce-{RANDOM}') and the SDK initialization. See the Web SDK Content Security Policy guide for more details.

Android options

When building for Android, you can pass InitializeOptions.android to TheymesSdk.Initialize() to customize Android-specific behavior. These options are ignored on iOS and WebGL.

Orientation

By default, the support view is locked to portrait on phones and uses the system default on large screens (tablets). You can override this by passing an Orientation constant:
Example
Available Orientation constants: If you want to use other orientations on Android, you can also pass the corresponding integer from the ActivityInfo class.