iOS SDK Preset Events and Properties

Last updated:2023-02-21
iOS SDK Preset Events and Properties

Based on common use scenarios and to help developers quickly integrate the SDK, Jiguang Analytics SDK predefines some basic events and properties. Developers do not need to manually add tracking points for them. The SDK automatically collects and reports them.
Preset events and preset properties all start with "jg_", making it easy to distinguish them from custom events and properties.

Preset Events

  • All preset events include basic preset properties. For details, see Preset Event Properties.
  • "-" means that the event has only basic preset properties.
Event Display Name Event Name Event Property Property Display Name Data Type Property Value Meaning or Example & Sample Format Event Trigger Timing
App launch jg_app_launch - Reported when the app starts
App first activation jg_app_active - Triggered only when the app is opened for the first time after installation. It is not triggered again on the second opening.
App switches to background jg_app_hide - The app switches from the foreground active state to the background
App switches to foreground jg_app_show - The app switches from the background to the foreground active state
Exit app jg_app_end - Triggered when exiting the app or when the app enters the background
New user registration jg_app_cuid jg_utm_source Campaign source string Depends on public properties set by the developer; otherwise there is no data Triggered when a new user registers successfully. The backend also triggers setting user properties: first visit time and the first_utm series
jg_utm_medium Campaign medium string Depends on public properties set by the developer; otherwise there is no data
jg_utm_term Campaign term string Depends on public properties set by the developer; otherwise there is no data
jg_utm_content Campaign content string Depends on public properties set by the developer; otherwise there is no data
jg_utm_campaign Campaign name string Depends on public properties set by the developer; otherwise there is no data
Click notification bar message jg_message_click jg_msg_id Push ID string msgid of the notification bar message Triggered when the user clicks a notification bar message
jg_task_id Task ID string Sending task ID generated by the operation plan
jg_plan_id Operation plan ID string Operation plan ID
jg_msg_title Message title string Title of the notification bar message
jg_msg_content Message content string Copy of the notification bar message
jg_msg_type Message type string Message type
jg_msg_url Redirect page string Target opening address on the Android platform
Notification bar message delivered jg_push_received jg_msg_id Push ID string msgid of the notification bar message Triggered when a notification bar message is delivered to the terminal
jg_task_id Task ID string Sending task ID generated by the operation plan
jg_plan_id Operation plan ID string Operation plan ID
jg_msg_title Message title string Title of the notification bar message
jg_msg_content Message content string Copy of the notification bar message
jg_msg_type Message type string Message type
jg_msg_url Redirect page string Target opening address on the Android platform
Enable notification permission jg_notification_state_on jg_date_time Notification disabled / enabled time string Most recent time when notifications were enabled or disabled <br /> Triggered when app notification permission is enabled
Disable notification permission jg_notification_state_off jg_date_time Notification disabled / enabled time string Most recent time when notifications were enabled or disabled Triggered when the user disables app notification permission
App page view jg_app_viewscreen - Triggered when opening an Activity / ViewController page. Depends on full tracking. iOS is not supported yet.
App page element click jg_app_click - Triggered when clicking a control. Depends on full tracking. iOS is not supported yet.

Preset Event Properties

Display Name Property Name Data Type Remarks
Data source type jg_data_source string Android, iOS, WebJS, WeChat Mini Program, WeChat Official Account, HTTP API
app_key jg_app_key string appkey registered on the platform - data source for Android, iOS, web, mini programs, etc.
App name jg_app_name string Android and iOS are handled by the SDK; webjs / mini program / official account are handled by the backend (updated on 08.22)
Data source ID jg_data_source_id number data source ID registered on the platform - data source for Android, iOS, web, mini programs, etc.
App channel jg_channel_source string 360, MyApp, Wandoujia, Huawei AppGallery.
First launch jg_launch_first bool First launch after app installation
First-day visit jg_is_first_day bool Whether the event is triggered on the first day. From the first launch day to 24:00 is considered the first day.
Platform type jg_platform_type string App side, web side, mini program side, WeChat Official Account
App version jg_app_version string app or mini program app version number
Jiguang Analytics SDK version jg_operate_sdk_ver string Jiguang Analytics SDK version number
Device ID jg_device_id string Android mainly uses Android ID; iOS first attempts to obtain IDFA
Mobile carrier jg_carrier string China Telecom, China Mobile, China Unicom
Whether using wifi jg_wifi bool Whether the network connection uses wifi
WiFi name jg_ssid string
Network type jg_network_type string wifi, 2g, 3g, 4g, 5g
IP address jg_ip string Needs to be obtained by the backend server
Country jg_country string Country parsed from the IP address
City jg_city string City parsed from the IP address
Province jg_province string Province parsed from the IP address
GPS latitude jg_latitude number WeChat Official Account Latitude
GPS longitude jg_longitude number WeChat Official Account Longitude
Device brand jg_brand string huawei, xiaomi, vivo, oppo, apple
Device manufacturer jg_manufacturer string huawei, xiaomi, vivo, oppo, apple
Device model jg_devices_model string Production model of the mobile terminal device
Device time zone jg_time_zone string Current time zone of the device terminal system
System language jg_os_language string Current language of the device terminal system
Operating system jg_os string ios, android, harmony, Windows, Linux
System version jg_os_version string android 7, ios 14.5
Screen height jg_screen_height number
Screen width jg_screen_width number
Screen size jg_screen_size string
Session duration jg_event_duration number Summed based on the duration when the device is in the foreground, in seconds. This property is absent or has a value of 0 in app_launch.
Was this document helpful?

Copyright 2011-2026, jiguang.cn, All Rights Reserved. 粤ICP备12056275号-13 Shenzhen Hexun Huagu Information Technology Co., Ltd.

Open in Docs Center