TikTok AppLog
Do not integrate on your own.The TikTok channel requires formal cooperation with TikTok before you can register an application and obtain the configuration required for integration.If you need to integrate, please consult your business contact first.
Player Network supports two independent TikTok reporting channels, which use different SDKs and report to different TikTok backends. Please choose the appropriate channel based on your business needs.
| AppLog (TTGP) | Business SDK Analytics | |
|---|---|---|
| SDK | TTGP 内置的 TikTok SDK | Standalone TikTok Business SDK |
| Dashboard | TikTok AppLog / TTGP Partner Dashboard | TikTok For Business Advertising Management Platform |
| Supported platforms | iOS and Android | Android only |
| API style | Dedicated TikTokTTGPAppLog* interface | Universal AnalyticsInit + ReportEvent (spChannels=TikTok) |
| Identity mapping | Automatically map Player Network openid ↔ TTGP openid | Automatically map via TikTokBusinessSdk.identify() (requires ANALYTICS_AUTH_REPORT_ENABLE = 1) |
| Applicable scenarios | Recommended for new integrations | Use only when requested by a TikTok business representative |
For Business SDK Analytics documentation, see Configure TikTok Reporting (Business SDK).
AppLog channel
Player Network surfaces TikTok AppLog as a fire-and-forget event-reporting channel.The channel can report predefined lifecycle events (install, launch, register, login) and custom events directly to TikTok through the bundled TikTok SDK.
Supported platforms
AppLog is supported on:
- iOS
- Android
Enable switch
The feature is controlled by the following key in INTLConfig.ini:
[TikTok]
TIKTOK_TTGP_APP_LOG_ENABLE = true
| Property | Value |
|---|---|
| Default value | true |
| Supported platforms | Android, iOS |
| Required | No |
If the switch is set to false, calls to SetCommonParams and ReportEvent return immediately without reporting any data.
Event types
Use the numeric event type values when calling ReportEvent.
| Event | Value | Explanation |
|---|---|---|
| Install | 1 | First-time installation. |
| Launch | 2 | Application launch. |
| Register | 3 | User registration. |
| Login | 4 | User login. |
| Custom | 5 | A custom event with a name and JSON parameters. |
SetCommonParams
Call SetCommonParams after the Player Network login succeeds and after the player logs in or binds TikTok. The SDK uses this call to attach identity and device context to every subsequent event.
The SDK resolves the following values automatically:
- TTGP openid — read from the internal mapping that is persisted when TikTok login or bind succeeds.
- Advertising ID — GAID on Android, IDFA on iOS, obtained from the device-info module.
You only need to pass the in-game user profile:
| Parameter | Required | Explanation |
|---|---|---|
userId | No | In-game user ID. Pass an empty string if unavailable. |
userNickName | No | In-game user nickname.Pass an empty string if unavailable. |
userIcon | No | In-game user avatar URL. Pass an empty string if unavailable. |
- Unity
- Unreal Engine
INTLAPI.TikTokTTGPAppLogSetCommonParams(
userId: playerId,
userNickName: playerNickname,
userIcon: playerAvatarUrl
);
UINTLSDKAPI::TikTokTTGPAppLogSetCommonParams(
playerId,
playerNickname,
playerAvatarUrl
);
If no TikTok identity mapping exists when you call SetCommonParams, the TTGP openid defaults to "0".The event may still be accepted, but TikTok user attribution may be unavailable.
ReportEvent
ReportEvent is fire-and-forget. There is no result observer; reporting failures are logged internally.
For Custom events, provide eventName and an optional paramsJson string.
- Unity
- Unreal Engine
// Report a predefined login event
INTLAPI.TikTokTTGPAppLogReportEvent(4);
// Report a custom event
INTLAPI.TikTokTTGPAppLogReportEvent(
eventType: 5,
eventName: "CompleteTutorial",
paramsJson: "{ \"level\": \"1\" }"
);
// Report a predefined login event
UINTLSDKAPI::TikTokTTGPAppLogReportEvent(4, TEXT(""), TEXT("{}"));
// Report a custom event
UINTLSDKAPI::TikTokTTGPAppLogReportEvent(
5,
TEXT("CompleteTutorial"),
TEXT("{ \"level\": \"1\" }")
);
Call SetCommonParams before you start reporting events.If ReportEvent is called before SetCommonParams, the SDK automatically calls SetCommonParams("", "", "") and logs a warning.The reported event is still sent, but user attribution may be incomplete.
Identity attribution behavior
AppLog relies on a mapping between the Player Network openid and the TikTok TTGP openid.The SDK creates this mapping automatically when:
- TikTok login succeeds.
- TikTok account binding succeeds.
The mapping is removed automatically when TikTok is unbound.If the mapping is missing, the TTGP openid falls back to "0" and TikTok user attribution may be unavailable.
Testing and troubleshooting
- Confirm that
TIKTOK_TTGP_APP_LOG_ENABLEis set totrueinINTLConfig.ini. - Ensure the
INTLTikTokplugin is included in the Android or iOS build. - Make sure Player Network login and TikTok login or bind have both succeeded before calling
SetCommonParams. - Check the native device or editor logs for warnings from
TikTokTTGPAppLogif events are not appearing. - Custom event parameters must be valid JSON. Invalid JSON is ignored, and the event is reported without parameters.
Business SDK Analytics (standalone channel)
The TikTok Business SDK analytics path is an independent reporting channel from AppLog independent reporting channel. It uses a standalone TikTok Business SDK, reporting data to the TikTok For Business Ads Manager platform rather than the TTGP backend. This channel only supports Android, and is configured via TIKTOK_EVENT_APPID and TIKTOK_EVENT_TT_APPID. For details, refer to Configure TikTok Reporting (Business SDK).