Parameter setScriptUrl
Description
The setScriptUrl method in TeleportConfiguration.Builder allows you to define the URL from which the Teleport SDK will load its main JavaScript script (teleport.js).
Purpose
This parameter is used to specify the source for loading the Teleport script, which can be useful for using custom SDK versions or bypassing network restrictions.
Recommendations
It is recommended to add query parameters (in any format) to the script URL to enrich Teleport statistics. This allows for collecting more detailed information about clients and platforms using the SDK.
Example Usage
kotlin
TeleportConfiguration.Builder("YOUR_API_KEY")
.setScriptUrl("https://cdn.teleport.media/stable/teleport.for.android.js?client=123&appId=234&platform=android")
.build()In this example, parameters client, appId, and platform are added to the base script URL to collect additional statistics.