@thinkingai/ae-cli 1.0.30 → 6.0.16-1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{auth-U25QJU5D.js → auth-DYC2BGLM.js} +2 -3
- package/dist/{auth-H3GJD55A.js → auth-GHBMJ5ZR.js} +33 -17
- package/dist/{chunk-CLJF7MQA.js → chunk-2DUEAXV3.js} +1 -1
- package/dist/{chunk-SF3KTPIC.js → chunk-5OC7CYCG.js} +2 -2
- package/dist/{chunk-SRJIAOBN.js → chunk-6W4QOZAL.js} +10 -0
- package/dist/{chunk-I42JGQ2J.js → chunk-BJX3GXWC.js} +3 -5
- package/dist/{chunk-GLNZSDKO.js → chunk-DMMEPCST.js} +4 -6
- package/dist/{chunk-VJFUB3H3.js → chunk-I5CRVM2S.js} +3 -3
- package/dist/{chunk-GSJGPNKK.js → chunk-PN3OS34E.js} +1 -1
- package/dist/{chunk-JM34JPCO.js → chunk-RSHMZ3LG.js} +178 -4
- package/dist/{client-IN42F223.js → client-2UJ63MVQ.js} +3 -4
- package/dist/{config-64G36TJL.js → config-NCUGK6NS.js} +3 -3
- package/dist/index.js +2530 -28
- package/dist/{model-VZCYNIOG.js → model-SJSOZTRS.js} +2 -2
- package/dist/{raw-WJIWC6YP.js → raw-7NVWSVJP.js} +5 -7
- package/dist/{sync-NVASAISS.js → sync-GRVO4K3U.js} +3 -3
- package/dist/{te-agent-YV4DXEXK.js → te-agent-KZRIEN4N.js} +468 -46
- package/dist/{te-analysis-CB3DA5I5.js → te-analysis-VAR4KUOK.js} +144 -29
- package/dist/{te-audience-W7SCQFC7.js → te-audience-KMKYI2YJ.js} +22 -15
- package/dist/{te-common-FBXVWBSI.js → te-common-WNCZB7R7.js} +4 -5
- package/dist/{te-community-LNVDZSGW.js → te-community-JEEFXPB3.js} +10 -11
- package/dist/{te-dataops-IPCSSWYH.js → te-dataops-GD3XBYCS.js} +11 -12
- package/dist/{te-engage-KARARMIR.js → te-engage-4XHCTS6I.js} +4 -5
- package/dist/{te-kb-2Z2CARN3.js → te-kb-B62KFP2A.js} +96 -8
- package/dist/{te-meta-PDKLMWXN.js → te-meta-EPZGQN56.js} +9 -10
- package/dist/{te-team-SW5B7DHO.js → te-team-YY24VORI.js} +6 -7
- package/dist/tracking/i18n/resources/cli/en.json +153 -0
- package/dist/tracking/i18n/resources/cli/ja.json +153 -0
- package/dist/tracking/i18n/resources/cli/ko.json +153 -0
- package/dist/tracking/i18n/resources/cli/zh.json +153 -0
- package/package.json +9 -3
- package/skills/ae-agent/SKILL.md +65 -25
- package/skills/ae-analysis/SKILL.md +108 -8
- package/skills/ae-analysis/references/cancel_query.md +39 -0
- package/skills/ae-analysis/references/drilldown_user_events.md +4 -2
- package/skills/ae-analysis/references/drilldown_users.md +4 -2
- package/skills/ae-analysis/references/get_bi_panel_detail.md +35 -0
- package/skills/ae-analysis/references/list_alerts.md +1 -1
- package/skills/ae-analysis/references/list_bi_panels.md +35 -0
- package/skills/ae-analysis/references/list_cluster_members.md +4 -1
- package/skills/ae-analysis/references/list_dashboards.md +1 -1
- package/skills/ae-analysis/references/list_entities.md +1 -1
- package/skills/ae-analysis/references/list_events.md +1 -1
- package/skills/ae-analysis/references/list_metrics.md +1 -1
- package/skills/ae-analysis/references/list_project_mark_times.md +1 -1
- package/skills/ae-analysis/references/list_properties.md +1 -1
- package/skills/ae-analysis/references/list_public_access_links.md +1 -1
- package/skills/ae-analysis/references/list_reports.md +1 -1
- package/skills/ae-analysis/references/list_tag_members.md +4 -1
- package/skills/ae-analysis/references/query_adhoc.md +6 -5
- package/skills/ae-analysis/references/query_bi_panel_data.md +58 -0
- package/skills/ae-analysis/references/query_dashboard_report_data.md +4 -1
- package/skills/ae-analysis/references/query_entity_details.md +5 -2
- package/skills/ae-analysis/references/query_event_details.md +4 -1
- package/skills/ae-analysis/references/query_report_data.md +2 -2
- package/skills/ae-analysis-global/SKILL.md +3 -1
- package/skills/ae-analysis-intent/SKILL.md +132 -0
- package/skills/ae-data-integration-helper/SKILL.md +242 -0
- package/skills/ae-data-integration-helper/references/android_sdk_faq.md +179 -0
- package/skills/ae-data-integration-helper/references/c_sdk_compilation.md +83 -0
- package/skills/ae-data-integration-helper/references/c_sdk_faq.md +416 -0
- package/skills/ae-data-integration-helper/references/cocoscreator_sdk_faq.md +123 -0
- package/skills/ae-data-integration-helper/references/cpp_server_sdk_faq.md +365 -0
- package/skills/ae-data-integration-helper/references/index.md +56 -0
- package/skills/ae-data-integration-helper/references/ios_sdk_faq.md +118 -0
- package/skills/ae-data-integration-helper/references/java_sdk_faq.md +406 -0
- package/skills/ae-data-integration-helper/references/javascript_sdk_faq.md +129 -0
- package/skills/ae-data-integration-helper/references/logbus2_guide.md +309 -0
- package/skills/ae-data-integration-helper/references/logbus2_parser_plugin.md +348 -0
- package/skills/ae-data-integration-helper/references/minigame_sdk_faq.md +115 -0
- package/skills/ae-data-integration-helper/references/miniprogram_sdk_faq.md +118 -0
- package/skills/ae-data-integration-helper/references/python_sdk_faq.md +232 -0
- package/skills/ae-data-integration-helper/references/restful_api_notes.md +74 -0
- package/skills/ae-data-integration-helper/references/sdk_log_guide.md +316 -0
- package/skills/ae-data-integration-helper/references/sdk_usage_notes.md +107 -0
- package/skills/ae-data-integration-helper/references/unity_sdk_faq.md +115 -0
- package/skills/ae-generate-tracking-code/SKILL.md +629 -0
- package/skills/ae-generate-tracking-code/references/autotrack-enum.md +183 -0
- package/skills/ae-generate-tracking-code/references/client-sdk-insert.md +202 -0
- package/skills/ae-generate-tracking-code/references/datax-config.md +43 -0
- package/skills/ae-generate-tracking-code/references/debug-script.md +102 -0
- package/skills/ae-generate-tracking-code/references/logbus-config.md +200 -0
- package/skills/ae-generate-tracking-code/references/modes.md +83 -0
- package/skills/ae-generate-tracking-code/references/restful-call.md +36 -0
- package/skills/ae-generate-tracking-code/references/sdk-index.md +128 -0
- package/skills/ae-generate-tracking-code/references/server-sdk-insert.md +206 -0
- package/skills/ae-generate-tracking-code/references/snippet-delivery.md +394 -0
- package/skills/ae-generate-tracking-code/references/te-api.md +181 -0
- package/skills/ae-generate-tracking-plan/SKILL.md +1083 -0
- package/skills/ae-generate-tracking-plan/references/autotrack-events.md +273 -0
- package/skills/ae-generate-tracking-plan/references/business-dimension-mapping.md +425 -0
- package/skills/ae-generate-tracking-plan/references/te-api.md +100 -0
- package/skills/ae-generate-tracking-plan/references/xlsx-schema.md +152 -0
- package/skills/ae-kb/SKILL.md +38 -5
- package/tracking-plan-template/MMO/346/211/213/346/270/270/345/237/213/347/202/271/346/250/241/346/235/277_v1.md +104 -0
- package/tracking-plan-template/MMO/346/211/213/346/270/270/345/237/213/347/202/271/346/250/241/346/235/277_v1.xlsx +0 -0
- package/tracking-plan-template/MMO/351/241/265/346/270/270/345/237/213/347/202/271/346/250/241/346/235/277_v2.md +117 -0
- package/tracking-plan-template/MMO/351/241/265/346/270/270/345/237/213/347/202/271/346/250/241/346/235/277_v2.xlsx +0 -0
- package/tracking-plan-template/RPG/347/261/273/345/237/213/347/202/271/346/250/241/346/235/277_v1.md +72 -0
- package/tracking-plan-template/RPG/347/261/273/345/237/213/347/202/271/346/250/241/346/235/277_v1.xlsx +0 -0
- package/tracking-plan-template/SLG/346/270/270/346/210/217/345/237/213/347/202/271/346/250/241/346/235/277_v1.md +86 -0
- package/tracking-plan-template/SLG/346/270/270/346/210/217/345/237/213/347/202/271/346/250/241/346/235/277_v1.xlsx +0 -0
- package/tracking-plan-template/Slots/345/237/213/347/202/271/346/250/241/346/235/277_v1.md +80 -0
- package/tracking-plan-template/Slots/345/237/213/347/202/271/346/250/241/346/235/277_v1.xlsx +0 -0
- package/tracking-plan-template/TE /345/237/213/347/202/271/347/244/272/344/276/213/346/250/241/346/235/277.md" +40 -0
- package/tracking-plan-template/TE /345/237/213/347/202/271/347/244/272/344/276/213/346/250/241/346/235/277.xlsx +0 -0
- package/tracking-plan-template/TE/345/256/230/346/226/271/346/250/241/346/235/277_dataTrackSample.md +40 -0
- package/tracking-plan-template/TE/345/256/230/346/226/271/346/250/241/346/235/277_dataTrackSample.xlsx +0 -0
- package/tracking-plan-template//344/274/221/351/227/262/345/205/273/346/210/220/347/261/273/345/237/213/347/202/271/346/250/241/346/235/277_v2.md +92 -0
- package/tracking-plan-template//344/274/221/351/227/262/345/205/273/346/210/220/347/261/273/345/237/213/347/202/271/346/250/241/346/235/277_v2.xlsx +0 -0
- package/tracking-plan-template//345/215/241/347/211/214/346/270/270/346/210/217/345/237/213/347/202/271/346/250/241/346/235/277_v1.md +119 -0
- package/tracking-plan-template//345/215/241/347/211/214/346/270/270/346/210/217/345/237/213/347/202/271/346/250/241/346/235/277_v1.xlsx +0 -0
- package/tracking-plan-template//345/241/224/351/230/262/345/205/273/346/210/220/347/261/273/345/237/213/347/202/271/346/250/241/346/235/277_V1.md +130 -0
- package/tracking-plan-template//345/241/224/351/230/262/345/205/273/346/210/220/347/261/273/345/237/213/347/202/271/346/250/241/346/235/277_V1.xlsx +0 -0
- package/tracking-plan-template//345/276/256/344/277/241/345/260/217/346/270/270/346/210/217/345/237/213/347/202/271/346/250/241/346/235/277_v1.md +52 -0
- package/tracking-plan-template//345/276/256/344/277/241/345/260/217/346/270/270/346/210/217/345/237/213/347/202/271/346/250/241/346/235/277_v1.xlsx +0 -0
- package/tracking-plan-template//346/215/225/351/261/274/347/261/273/345/237/213/347/202/271/346/250/241/346/235/277_v1.md +68 -0
- package/tracking-plan-template//346/215/225/351/261/274/347/261/273/345/237/213/347/202/271/346/250/241/346/235/277_v1.xlsx +0 -0
- package/tracking-plan-template//346/224/276/347/275/256/347/261/273/345/215/241/347/211/214/346/270/270/346/210/217_/345/237/213/347/202/271/346/250/241/347/211/210v1.md +108 -0
- package/tracking-plan-template//346/224/276/347/275/256/347/261/273/345/215/241/347/211/214/346/270/270/346/210/217_/345/237/213/347/202/271/346/250/241/347/211/210v1.xlsx +0 -0
- package/tracking-plan-template//346/224/276/347/275/256/347/261/273/345/237/213/347/202/271/346/250/241/346/235/277_v1.md +119 -0
- package/tracking-plan-template//346/224/276/347/275/256/347/261/273/345/237/213/347/202/271/346/250/241/346/235/277_v1.xlsx +0 -0
- package/tracking-plan-template//346/243/213/347/211/214/347/261/273/357/274/210/346/226/227/345/234/260/344/270/273/357/274/211/345/237/213/347/202/271/346/250/241/346/235/277_v1.md +63 -0
- package/tracking-plan-template//346/243/213/347/211/214/347/261/273/357/274/210/346/226/227/345/234/260/344/270/273/357/274/211/345/237/213/347/202/271/346/250/241/346/235/277_v1.xlsx +0 -0
- package/tracking-plan-template//346/243/213/347/211/214/347/261/273/357/274/210/351/272/273/345/260/206/357/274/211/345/237/213/347/202/271/346/250/241/346/235/277_v2.md +101 -0
- package/tracking-plan-template//346/243/213/347/211/214/347/261/273/357/274/210/351/272/273/345/260/206/357/274/211/345/237/213/347/202/271/346/250/241/346/235/277_v2.xlsx +0 -0
- package/tracking-plan-template//347/224/265/345/225/206/345/237/213/347/202/271/346/226/271/346/241/210/346/250/241/346/235/277_v1.md +84 -0
- package/tracking-plan-template//347/224/265/345/225/206/345/237/213/347/202/271/346/226/271/346/241/210/346/250/241/346/235/277_v1.xlsx +0 -0
- package/tracking-plan-template//347/237/255/345/211/247/344/272/247/345/223/201/345/237/213/347/202/271/346/226/271/346/241/210/346/250/241/346/235/277_v1.md +79 -0
- package/tracking-plan-template//347/237/255/345/211/247/344/272/247/345/223/201/345/237/213/347/202/271/346/226/271/346/241/210/346/250/241/346/235/277_v1.xlsx +0 -0
- package/tracking-plan-template//347/244/276/344/272/244/350/201/212/345/244/251/347/261/273/345/237/213/347/202/271/346/250/241/346/235/277_v1.md +105 -0
- package/tracking-plan-template//347/244/276/344/272/244/350/201/212/345/244/251/347/261/273/345/237/213/347/202/271/346/250/241/346/235/277_v1.xlsx +0 -0
- package/tracking-plan-template//351/230/205/350/257/273/347/261/273APP/345/237/213/347/202/271/346/250/241/346/235/277_v1.md +83 -0
- package/tracking-plan-template//351/230/205/350/257/273/347/261/273APP/345/237/213/347/202/271/346/250/241/346/235/277_v1.xlsx +0 -0
- package/wiki/te-docs/index.md +225 -0
- package/wiki/te-docs/raw/advanced-data-type/first-event-check.md +66 -0
- package/wiki/te-docs/raw/advanced-data-type/updated-event.md +87 -0
- package/wiki/te-docs/raw/advanced-data-type.md +16 -0
- package/wiki/te-docs/raw/data-ingestion-guide/about-gdpr.md +55 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/android/android-advanced/automatic-event-tracking.md +431 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/android/android-advanced/debugging-and-logging.md +49 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/android/android-advanced/multi-instance.md +66 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/android/android-advanced/preset-properties.md +466 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/android/android-advanced/third-party-integration.md +127 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/android/android-advanced.md +513 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/android/compliance.md +24 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/android/release-notes.md +177 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/android.md +228 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/c/c-advanced.md +419 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/c/release-notes.md +45 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/c.md +110 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/client-side-sdk-faq.md +52 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/cpp/cpp-advanced.md +366 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/cpp/release-notes.md +103 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/cpp.md +201 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/cross-platform/flutter/compliance.md +26 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/cross-platform/flutter/flutter-advanced/automatically-track-events.md +117 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/cross-platform/flutter/flutter-advanced/debugging-and-logging.md +47 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/cross-platform/flutter/flutter-advanced/preset-properties.md +52 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/cross-platform/flutter/flutter-advanced.md +267 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/cross-platform/flutter/release-notes.md +82 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/cross-platform/flutter.md +139 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/cross-platform/react-native/compliance.md +26 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/cross-platform/react-native/reactnative-advanced/automatically-track-events.md +121 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/cross-platform/react-native/reactnative-advanced/debugging-and-logging.md +54 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/cross-platform/react-native/reactnative-advanced/preset-properties.md +18 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/cross-platform/react-native/reactnative-advanced.md +305 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/cross-platform/react-native/release-notes.md +79 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/cross-platform/react-native.md +137 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/cross-platform/uni-app/release-notes.md +24 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/cross-platform/uni-app/uniapp-advanced/automatically-track-events.md +54 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/cross-platform/uni-app/uniapp-advanced/debugging-and-logging.md +53 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/cross-platform/uni-app/uniapp-advanced/multi-instance.md +42 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/cross-platform/uni-app/uniapp-advanced/preset-properties.md +119 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/cross-platform/uni-app/uniapp-advanced/support-native.md +81 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/cross-platform/uni-app/uniapp-advanced.md +331 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/cross-platform/uni-app.md +156 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/cross-platform.md +12 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/cocos2d-x/cocos2d-x-advanced/automatic-event-tracking.md +29 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/cocos2d-x/cocos2d-x-advanced/debugging-and-logging.md +47 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/cocos2d-x/cocos2d-x-advanced/multi-instance.md +21 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/cocos2d-x/cocos2d-x-advanced/preset-properties.md +249 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/cocos2d-x/cocos2d-x-advanced.md +301 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/cocos2d-x/compliance.md +24 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/cocos2d-x/release-notes.md +51 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/cocos2d-x.md +281 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/cocoscreator/cocoscreator-advance/automatic-event-tracking.md +70 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/cocoscreator/cocoscreator-advance/debugging-and-logging.md +57 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/cocoscreator/cocoscreator-advance/native-support.md +104 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/cocoscreator/cocoscreator-advance/preset-properties.md +91 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/cocoscreator/cocoscreator-advance.md +374 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/cocoscreator/compliance.md +35 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/cocoscreator/release-notes.md +109 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/cocoscreator.md +170 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/corona/compliance.md +28 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/corona/corona-advanced/automatic-event-tracking.md +29 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/corona/corona-advanced/debugging-and-logging.md +58 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/corona/corona-advanced/preset-properties.md +43 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/corona/corona-advanced.md +204 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/corona/release-notes.md +29 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/corona.md +269 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/unity/compliance.md +24 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/unity/release-notes.md +177 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/unity/unity-advanced/automatic-event-tracking.md +119 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/unity/unity-advanced/debugging-and-logging.md +47 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/unity/unity-advanced/multi-instance.md +50 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/unity/unity-advanced/native-pluggable.md +43 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/unity/unity-advanced/preset-properties.md +212 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/unity/unity-advanced/third-party-integration.md +77 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/unity/unity-advanced.md +396 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/unity.md +176 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/unreal/compliance.md +24 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/unreal/release-notes.md +81 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/unreal/unreal-advanced/automatic-event-tracking.md +79 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/unreal/unreal-advanced/debugging-and-logging.md +31 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/unreal/unreal-advanced/preset-properties.md +25 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/unreal/unreal-advanced/third-party-integrations.md +141 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/unreal/unreal-advanced.md +278 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine/unreal.md +190 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/game-engine.md +14 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/h5-and-app-sdk-connection.md +147 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/instant-app-and-game.md +24 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/ios/compliance.md +24 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/ios/ios-advanced/automatic-event-tracking.md +272 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/ios/ios-advanced/debugging-and-logging.md +77 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/ios/ios-advanced/multi-instance.md +142 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/ios/ios-advanced/preset-properties.md +484 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/ios/ios-advanced/third-party-integrations.md +132 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/ios/ios-advanced.md +682 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/ios/release-notes.md +163 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/ios.md +304 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/javascript/compliance.md +29 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/javascript/javascript-advanced/automatic-event-tracking.md +136 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/javascript/javascript-advanced/debugging-and-logging.md +48 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/javascript/javascript-advanced/multi-instance.md +50 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/javascript/javascript-advanced/preset-properties.md +132 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/javascript/javascript-advanced.md +462 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/javascript/release-notes.md +107 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/javascript.md +208 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/macos/macos-advanced/debugging-and-logging.md +62 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/macos/macos-advanced/preset-properties.md +118 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/macos/macos-advanced.md +556 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk/macos.md +231 -0
- package/wiki/te-docs/raw/data-ingestion-guide/client-sdk.md +25 -0
- package/wiki/te-docs/raw/data-ingestion-guide/data-import-tools/filebeat-logstash-user-guide.md +610 -0
- package/wiki/te-docs/raw/data-ingestion-guide/data-import-tools/logbus2-user-guide.md +1215 -0
- package/wiki/te-docs/raw/data-ingestion-guide/data-import-tools/ta-datax-writer-plugin-user-guide.md +278 -0
- package/wiki/te-docs/raw/data-ingestion-guide/data-import-tools.md +15 -0
- package/wiki/te-docs/raw/data-ingestion-guide/privacy-policy.md +38 -0
- package/wiki/te-docs/raw/data-ingestion-guide/restful-api-user-guide.md +155 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/c/c-advanced/debugging-and-logging-FM9Cwz.md +37 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/c/c-advanced/debugging-and-logging-RSyfw7.md +41 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/c/c-advanced/debugging-and-logging.md +89 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/c/c-advanced/preset-properties-OxzWw.md +126 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/c/c-advanced/preset-properties-VuE3wr.md +126 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/c/c-advanced/preset-properties.md +126 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/c/c-advanced-IauKwI.md +175 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/c/c-advanced-YAilwk.md +210 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/c/c-advanced.md +211 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/c/release-notes-PVazwa.md +62 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/c/release-notes-TADbwY.md +50 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/c/release-notes.md +69 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/c-V2W3wv.md +131 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/c-Zf9Jwl.md +179 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/c.md +189 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/erlang/erlang-advanced/debugging-and-logging.md +38 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/erlang/erlang-advanced/preset-properties.md +126 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/erlang/erlang-advanced.md +113 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/erlang/release-notes.md +34 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/erlang.md +155 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/golang/golang-advanced/debugging-and-logging.md +42 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/golang/golang-advanced/preset-properties.md +126 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/golang/golang-advanced.md +157 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/golang/release-notes.md +72 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/golang.md +148 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/java/java-advanced/debugging-and-logging.md +49 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/java/java-advanced/preset-properties.md +126 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/java/java-advanced.md +223 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/java/release-notes.md +88 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/java.md +174 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/lua/lua-advanced/debugging-and-logging.md +46 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/lua/lua-advanced/preset-properties.md +126 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/lua/lua-advanced.md +182 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/lua/release-notes.md +61 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/lua.md +121 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/nodejs/nodejs-advanced/debugging-and-logging.md +55 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/nodejs/nodejs-advanced/preset-properties.md +126 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/nodejs/nodejs-advanced.md +225 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/nodejs/release-notes.md +45 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/nodejs.md +141 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/php/php-advanced/debugging-and-logging.md +41 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/php/php-advanced/preset-properties.md +126 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/php/php-advanced.md +216 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/php/release-notes.md +45 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/php.md +173 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/python/python-advanced/debugging-and-logging.md +40 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/python/python-advanced/preset-properties.md +126 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/python/python-advanced.md +206 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/python/release-notes.md +51 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/python.md +116 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/ruby/release-notes.md +44 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/ruby/ruby-advanced/debugging-and-logging.md +47 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/ruby/ruby-advanced/preset-properties.md +126 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/ruby/ruby-advanced.md +189 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/ruby.md +142 -0
- package/wiki/te-docs/raw/data-ingestion-guide/server-sdk.md +22 -0
- package/wiki/te-docs/raw/data-ingestion-guide/thinkingdata-privacy-policy.md +37 -0
- package/wiki/te-docs/raw/data-ingestion-guide.md +48 -0
- package/wiki/te-docs/raw/preparations-before-data-ingestion/data-rules.md +396 -0
- package/wiki/te-docs/raw/preparations-before-data-ingestion/preset-properties-and-system-fields.md +957 -0
- package/wiki/te-docs/raw/preparations-before-data-ingestion/user-identification-rules.md +723 -0
- package/wiki/te-docs/raw/preparations-before-data-ingestion.md +203 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk/openharmony//345/220/210/350/247/204/346/214/207/345/215/227.md +96 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk/openharmony//346/233/264/346/226/260/346/227/245/345/277/227.md +97 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk/openharmony//350/277/233/351/230/266/346/214/207/345/215/227//345/244/232/345/256/236/344/276/213.md +52 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk/openharmony//350/277/233/351/230/266/346/214/207/345/215/227//345/256/236/346/227/266/350/260/203/350/257/225.md +48 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk/openharmony//350/277/233/351/230/266/346/214/207/345/215/227//351/242/204/347/275/256/345/261/236/346/200/247.md +447 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk/openharmony//350/277/233/351/230/266/346/214/207/345/215/227.md +370 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk/openharmony.md +172 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk//345/260/217/347/250/213/345/272/217/345/260/217/346/270/270/346/210/217//345/220/210/350/247/204/346/214/207/345/215/227.md +37 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk//345/260/217/347/250/213/345/272/217/345/260/217/346/270/270/346/210/217//346/233/264/346/226/260/346/227/245/345/277/227.md +209 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk//345/260/217/347/250/213/345/272/217/345/260/217/346/270/270/346/210/217//350/277/233/351/230/266/346/214/207/345/215/227//345/244/232/345/256/236/344/276/213.md +71 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk//345/260/217/347/250/213/345/272/217/345/260/217/346/270/270/346/210/217//350/277/233/351/230/266/346/214/207/345/215/227//345/256/236/346/227/266/350/260/203/350/257/225.md +49 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk//345/260/217/347/250/213/345/272/217/345/260/217/346/270/270/346/210/217//350/277/233/351/230/266/346/214/207/345/215/227//350/207/252/345/212/250/351/207/207/351/233/206.md +125 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk//345/260/217/347/250/213/345/272/217/345/260/217/346/270/270/346/210/217//350/277/233/351/230/266/346/214/207/345/215/227//351/242/204/347/275/256/345/261/236/346/200/247.md +498 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk//345/260/217/347/250/213/345/272/217/345/260/217/346/270/270/346/210/217//350/277/233/351/230/266/346/214/207/345/215/227.md +612 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk//345/260/217/347/250/213/345/272/217/345/260/217/346/270/270/346/210/217.md +373 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk//346/270/270/346/210/217/345/274/225/346/223/216/cocos2d-lua//345/220/210/350/247/204/346/214/207/345/215/227.md +26 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk//346/270/270/346/210/217/345/274/225/346/223/216/cocos2d-lua//346/233/264/346/226/260/346/227/245/345/277/227.md +32 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk//346/270/270/346/210/217/345/274/225/346/223/216/cocos2d-lua//350/277/233/351/230/266/346/214/207/345/215/227//345/256/236/346/227/266/350/260/203/350/257/225.md +48 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk//346/270/270/346/210/217/345/274/225/346/223/216/cocos2d-lua//350/277/233/351/230/266/346/214/207/345/215/227//350/207/252/345/212/250/351/207/207/351/233/206.md +30 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk//346/270/270/346/210/217/345/274/225/346/223/216/cocos2d-lua//350/277/233/351/230/266/346/214/207/345/215/227//351/242/204/347/275/256/345/261/236/346/200/247.md +61 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk//346/270/270/346/210/217/345/274/225/346/223/216/cocos2d-lua//350/277/233/351/230/266/346/214/207/345/215/227.md +236 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk//346/270/270/346/210/217/345/274/225/346/223/216/cocos2d-lua.md +200 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk//346/270/270/346/210/217/345/274/225/346/223/216/egret//346/233/264/346/226/260/346/227/245/345/277/227.md +83 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk//346/270/270/346/210/217/345/274/225/346/223/216/egret//350/277/233/351/230/266/346/214/207/345/215/227/native/346/224/257/346/214/201.md +66 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk//346/270/270/346/210/217/345/274/225/346/223/216/egret//350/277/233/351/230/266/346/214/207/345/215/227//345/256/236/346/227/266/350/260/203/350/257/225.md +54 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk//346/270/270/346/210/217/345/274/225/346/223/216/egret//350/277/233/351/230/266/346/214/207/345/215/227//350/207/252/345/212/250/351/207/207/351/233/206.md +62 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk//346/270/270/346/210/217/345/274/225/346/223/216/egret//350/277/233/351/230/266/346/214/207/345/215/227//351/242/204/347/275/256/345/261/236/346/200/247.md +358 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk//346/270/270/346/210/217/345/274/225/346/223/216/egret//350/277/233/351/230/266/346/214/207/345/215/227.md +615 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk//346/270/270/346/210/217/345/274/225/346/223/216/egret.md +166 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk//346/270/270/346/210/217/345/274/225/346/223/216/layaair//346/233/264/346/226/260/346/227/245/345/277/227.md +87 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk//346/270/270/346/210/217/345/274/225/346/223/216/layaair//350/277/233/351/230/266/346/214/207/345/215/227/native/346/224/257/346/214/201.md +71 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk//346/270/270/346/210/217/345/274/225/346/223/216/layaair//350/277/233/351/230/266/346/214/207/345/215/227//345/256/236/346/227/266/350/260/203/350/257/225.md +54 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk//346/270/270/346/210/217/345/274/225/346/223/216/layaair//350/277/233/351/230/266/346/214/207/345/215/227//350/207/252/345/212/250/351/207/207/351/233/206.md +61 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk//346/270/270/346/210/217/345/274/225/346/223/216/layaair//350/277/233/351/230/266/346/214/207/345/215/227//351/242/204/347/275/256/345/261/236/346/200/247.md +406 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk//346/270/270/346/210/217/345/274/225/346/223/216/layaair//350/277/233/351/230/266/346/214/207/345/215/227.md +597 -0
- package/wiki/te-docs/raw//345/256/242/346/210/267/347/253/257-sdk//346/270/270/346/210/217/345/274/225/346/223/216/layaair.md +179 -0
- package/wiki/te-docs/schema.md +16 -0
- package/wiki/te-docs/synthesis/batch-ingest-comparison.md +324 -0
- package/wiki/te-docs/synthesis/js-sdk-cheatsheet.md +538 -0
- package/wiki/te-docs/synthesis/restful-api-reference.md +363 -0
- package/wiki/te-docs/synthesis/sdk-selection.md +372 -0
- package/wiki/te-docs/synthesis/server-sdk-overview.md +449 -0
- package/dist/chunk-U6TKB3IV.js +0 -171
|
@@ -0,0 +1,131 @@
|
|
|
1
|
+
---
|
|
2
|
+
code: csharp_sdk_installation
|
|
3
|
+
name: "C#"
|
|
4
|
+
wikiToken: V2W3wvcfkiGW3lk9rrDcnosAnqi
|
|
5
|
+
parentWikiToken: IKVPwn4NfiIhijk5EcAcMf6pn7e
|
|
6
|
+
updateTime: 1774252015000
|
|
7
|
+
sourceUrl: https://docs-v2.thinkingdata.cn/?version=v6.0&lan=en-US&code=csharp_sdk_installation
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
::: tip
|
|
11
|
+
Before you begin, please read [<text color="purple" underline="true">Preparation before Data Ingestion</text>](https://thinkingdata.feishu.cn/wiki/OhD8we9iai6Xk5kM1QNc8ITRnQe).
|
|
12
|
+
:::
|
|
13
|
+
**Latest version**: v2.0.3
|
|
14
|
+
**Update time**: 2025-09-03
|
|
15
|
+
**Resource download: **[source code](https%3A%2F%2Fgithub.com%2FThinkingDataAnalytics%2Fcsharp-sdk)
|
|
16
|
+
::: warning Notice
|
|
17
|
+
Current documentation applies to v2.0.0 and later. For historical versions, see [Data Ingestion Guide - C# (V1)](https%3A%2F%2Fdocs.thinkingdata.cn%2Fta-manual%2Fv4.1%2Fen%2Finstallation%2Finstallation_menu%2Fserver_sdk%2Fcsharp_sdk_installation%2Fcsharp_sdk_installation.html)
|
|
18
|
+
:::
|
|
19
|
+
## **SDK**** Integration**
|
|
20
|
+
### Method 1: NuGet Integration
|
|
21
|
+
1. Search for the ThinkingDataAnalytics library in NuGet and install it into your project.
|
|
22
|
+
1. When you install the ThinkingDataAnalytics library, the Newtonsoft.Json library will be automatically installed as well.
|
|
23
|
+
### Method 2: Integrate the DLL file
|
|
24
|
+
1. Download the SDK source code.
|
|
25
|
+
1. Open the solution in the source code and manually compile the DLL file of the SDK.
|
|
26
|
+
1. Import the DLL file of the ThinkingDataAnalytics SDK into your project.
|
|
27
|
+
1. The SDK depends on the Newtonsoft.Json framework for JSON parsing. Please manually add the Newtonsoft.Json library to your project.
|
|
28
|
+
### Logbus Integration
|
|
29
|
+
We recommend using SDK+LogBus to track and report data on server. You can refer to the following documents to complete the installation of Logbus:[ LogBus User Guide](https://thinkingdata.feishu.cn/wiki/SlE6wOEK3isQvukzEbnc5V0inNa)
|
|
30
|
+
## **Initialization**
|
|
31
|
+
The following is the sample code for SDK initialization:
|
|
32
|
+
```csharp
|
|
33
|
+
using ThinkingData.Analytics
|
|
34
|
+
|
|
35
|
+
TDAnalytics te = new TDAnalytics(new TDLoggerConsumer("LOG_DIRECTORY"));
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
`LOG_DIRECTORY` is the local folder path.
|
|
39
|
+
## **Common Features**
|
|
40
|
+
In order to ensure that the distinct ID and account ID can be bound smoothly, if your game uses the distinct ID and account ID, we strongly recommend that you upload these two IDs at the same time, otherwise the account will not match, causing users to double count. For specific ID binding rules, please refer to the chapter on [User Identification Rules](https://thinkingdata.feishu.cn/wiki/Pov9wECdsi2QQsk4NN9cEPsvnyc).
|
|
41
|
+
### 3.1 **Sending Events**
|
|
42
|
+
You can call `Track` to upload events. It is suggested that you set event properties based on the data tracking plan drafted previously. Here is an example of a user buying an item:
|
|
43
|
+
```csharp
|
|
44
|
+
Dictionary<string, object> properties = new Dictionary<string, object>();
|
|
45
|
+
properties.Add("#ip", "123.123.123.123");
|
|
46
|
+
properties.Add("channel", "TE");
|
|
47
|
+
properties.Add("age", 1);
|
|
48
|
+
properties.Add("is_success", true);
|
|
49
|
+
|
|
50
|
+
List<string> list = new List<string>();
|
|
51
|
+
list.Add("value");
|
|
52
|
+
properties.Add("array", list);
|
|
53
|
+
|
|
54
|
+
Dictionary<string, Object> objectTest = new Dictionary<string, object>();
|
|
55
|
+
objectTest.Add("key", "vale");
|
|
56
|
+
properties.Add("object", objectTest);
|
|
57
|
+
|
|
58
|
+
List<Object> object_arr = new List<Object>();
|
|
59
|
+
object_arr.Add(objectTest);
|
|
60
|
+
properties.Add("object_arr", object_arr);
|
|
61
|
+
|
|
62
|
+
te.Track("accountId", "distinctId", "Payment", properties);
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
- Key is the name of the property and refers to the string type. It must start with a character, and contain numbers, characters (insensitive to case, and upper cases would be transformed into lower cases by TE) and underscores "_", with a maximum length of 50 characters.
|
|
66
|
+
- Value, the value of the property, supports string, numbers, Boolean, time, object, array object, and array
|
|
67
|
+
<quote-container>
|
|
68
|
+
**The requirements for event properties and user properties are the same as that for super properties**
|
|
69
|
+
</quote-container>
|
|
70
|
+
|
|
71
|
+
### 3.2 **User Properties**
|
|
72
|
+
You can set general user properties by calling `UserSet` API. The original properties would be replaced by the properties uploaded via this API. If no user properties are set before, user properties will be newly created. The type of newly-created user properties must conform to that of the uploaded properties. User name setting is taken as the example here:
|
|
73
|
+
```csharp
|
|
74
|
+
Dictionary<string, object> properties= new Dictionary<string, object>();
|
|
75
|
+
properties.Add("user_name","TA");
|
|
76
|
+
te.UserSet("accountId","distinctId", properties);
|
|
77
|
+
|
|
78
|
+
Dictionary<string, object> newProperties= new Dictionary<string, object>();
|
|
79
|
+
newProperties.Add("user_name","TE");
|
|
80
|
+
te.UserSet("accountId","distinctId", newProperties);
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
### 3.3 Reported data
|
|
84
|
+
With `TDLoggerConsumer`, the captured events are encoded as json strings and then added to the cache. Data is written to disk only when the string length in the cache exceeds the set length. The default maximum length is 8192.
|
|
85
|
+
You can call the `flush()` api to report data to the TE immediately under certain service scenarios. However, frequent calls to `flush()` can result in degraded service performance.
|
|
86
|
+
```csharp
|
|
87
|
+
te.Flush();
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
### 3.4 Close SDK
|
|
91
|
+
```csharp
|
|
92
|
+
te.Close();
|
|
93
|
+
```
|
|
94
|
+
|
|
95
|
+
<quote-container>
|
|
96
|
+
Close and exit the SDK. Please call this api before closing the server to avoid data loss in the cache
|
|
97
|
+
</quote-container>
|
|
98
|
+
|
|
99
|
+
## **Best Practice**
|
|
100
|
+
The following sample code covers all the above-mentioned operations. It is recommended that the codes be used in the following steps:
|
|
101
|
+
```csharp
|
|
102
|
+
using ThinkingData.Analytics
|
|
103
|
+
|
|
104
|
+
TDAnalytics te = new TDAnalytics(new TDLoggerConsumer("LOG_DIRECTORY"));
|
|
105
|
+
|
|
106
|
+
Dictionary<string, object> properties = new Dictionary<string, object>();
|
|
107
|
+
properties.Add("#ip", "123.123.123.123");
|
|
108
|
+
properties.Add("channel", "TE");
|
|
109
|
+
properties.Add("age", 1);
|
|
110
|
+
properties.Add("is_success", true);
|
|
111
|
+
|
|
112
|
+
List<string> list = new List<string>();
|
|
113
|
+
list.Add("value");
|
|
114
|
+
properties.Add("array", list);
|
|
115
|
+
|
|
116
|
+
Dictionary<string, Object> objectTest = new Dictionary<string, object>();
|
|
117
|
+
objectTest.Add("key", "vale");
|
|
118
|
+
properties.Add("object", objectTest);
|
|
119
|
+
|
|
120
|
+
List<Object> object_arr = new List<Object>();
|
|
121
|
+
object_arr.Add(objectTest);
|
|
122
|
+
properties.Add("object_arr", object_arr);
|
|
123
|
+
|
|
124
|
+
te.Track("accountId", "distinctId", "Payment", properties);
|
|
125
|
+
|
|
126
|
+
Dictionary<string, object> userProperties = new Dictionary<string, object>();
|
|
127
|
+
userProperties.Add("user_name", "TA");
|
|
128
|
+
te.UserSet("accountId", "distinctId", userProperties);
|
|
129
|
+
|
|
130
|
+
te.Flush();
|
|
131
|
+
```
|
|
@@ -0,0 +1,179 @@
|
|
|
1
|
+
---
|
|
2
|
+
code: cpp_server_sdk_installation
|
|
3
|
+
name: "C++"
|
|
4
|
+
wikiToken: Zf9Jwl81biGtrbkmBhackD1Fn3c
|
|
5
|
+
parentWikiToken: IKVPwn4NfiIhijk5EcAcMf6pn7e
|
|
6
|
+
updateTime: 1774252019000
|
|
7
|
+
sourceUrl: https://docs-v2.thinkingdata.cn/?version=v6.0&lan=en-US&code=cpp_server_sdk_installation
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
::: tip
|
|
11
|
+
Before you begin, please read [<text color="purple" underline="true">Preparation before Data Ingestion</text>](https://thinkingdata.feishu.cn/wiki/OhD8we9iai6Xk5kM1QNc8ITRnQe).
|
|
12
|
+
C++ 11 is required. The g++ version needs to be greater than 5.1.0
|
|
13
|
+
:::
|
|
14
|
+
**Latest version**: v2.0.0
|
|
15
|
+
**Update time**: 2023-11-30
|
|
16
|
+
**Resource download: **[**Source Code**](https%3A%2F%2Fgithub.com%2FThinkingDataAnalytics%2Fcpp-server-sdk)
|
|
17
|
+
::: warning Notice
|
|
18
|
+
Current documentation applies to v2.0.0 and later. For historical versions, see [Data Ingestion Guide - C++ (V1)](https%3A%2F%2Fdocs.thinkingdata.cn%2Fta-manual%2Fv4.1%2Fen%2Finstallation%2Finstallation_menu%2Fserver_sdk%2Fcpp_server_sdk_installation%2Fcpp_server_sdk_installation.html)
|
|
19
|
+
:::
|
|
20
|
+
## **SDK**** Integration**
|
|
21
|
+
**1.1**** Build **`**libthinkingdata.a**`** file**
|
|
22
|
+
1. TE SDK relies on [rapidjson ](https%3A%2F%2Fgithub.com%2FTencent%2Frapidjson)parsing library, you need to download `rapidjson` library.
|
|
23
|
+
2. Download the SDK source code, modify the `CMakeLists.txt` file in the SDK, and select the data consumers you need for packaging (details can refer to the `CMakeLists.txt` file in the SDK source code). Here is an example of the most common `logconsumer`:
|
|
24
|
+
```bash
|
|
25
|
+
cmake_minimum_required(VERSION 3.12)
|
|
26
|
+
project(ThinkingData)
|
|
27
|
+
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
|
28
|
+
set(CMAKE_CXX_STANDARD 11)
|
|
29
|
+
|
|
30
|
+
message(STATUS "[${PROJECT_NAME}] current cmake version: ${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION}.${CMAKE_PATCH_VERSION}")
|
|
31
|
+
message(STATUS "[${PROJECT_NAME}] CMAKE_HOST_SYSTEM: ${CMAKE_HOST_SYSTEM} ")
|
|
32
|
+
|
|
33
|
+
if(NOT CMAKE_BUILD_TYPE)
|
|
34
|
+
set(CMAKE_BUILD_TYPE release CACHE STRING "Build Type" FORCE)
|
|
35
|
+
endif()
|
|
36
|
+
|
|
37
|
+
message(STATUS "[${PROJECT_NAME}] Build type:${CMAKE_BUILD_TYPE}")
|
|
38
|
+
|
|
39
|
+
message(STATUS "[${PROJECT_NAME}] Debug configuration:${CMAKE_CXX_FLAGS_DEBUG}")
|
|
40
|
+
|
|
41
|
+
message(STATUS "[${PROJECT_NAME}] release configuration:${CMAKE_CXX_FLAGS_RELEASE}")
|
|
42
|
+
|
|
43
|
+
message(STATUS "[${PROJECT_NAME}] release configuration with debug info:${CMAKE_CXX_FLAGS_RELWITHDEBINFO}")
|
|
44
|
+
|
|
45
|
+
message(STATUS "[${PROJECT_NAME}] minimal release configuration:${CMAKE_CXX_FLAGS_MINSIZEREL}")
|
|
46
|
+
|
|
47
|
+
include_directories(include)
|
|
48
|
+
|
|
49
|
+
#
|
|
50
|
+
# log consumer. Recommended for production environments
|
|
51
|
+
#
|
|
52
|
+
set(TE_LIB_NAME thinkingdata)
|
|
53
|
+
add_library(${TE_LIB_NAME} src/TDAnalytics.cpp src/TDUtils.cpp src/TDLoggerConsumer.cpp src/TDConsumer.cpp)
|
|
54
|
+
if(UNIX)
|
|
55
|
+
find_package(Threads REQUIRED)
|
|
56
|
+
target_link_libraries(${TE_LIB_NAME} Threads::Threads)
|
|
57
|
+
endif()
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
3. The `rapidjson` library contains only header files.
|
|
61
|
+
1. Put the `rapidjson` in the following path if your project has not included the `rapidjson` library before:
|
|
62
|
+
|
|
63
|
+
<image token="A0uybVQmOoqIRfxshGNcdvObnig" width="222" height="201" align="center"/>
|
|
64
|
+
|
|
65
|
+
2. The contents of the `TDJsonParse.h` file need to be modified if your project has previously included the `rapidjson` library. You don't need to import `rapidjson` again:
|
|
66
|
+
|
|
67
|
+
<image token="J9LLbZLR0oI26KxgcUfcHyFWndc" width="294" height="149" align="center"/>
|
|
68
|
+
|
|
69
|
+
|
|
70
|
+
**1.2 ****Logbus**** Integration**
|
|
71
|
+
We recommend using SDK+LogBus to track and report data on server. You can refer to the following documents to complete the installation of Logbus:[ LogBus User Guide](https://thinkingdata.feishu.cn/wiki/SlE6wOEK3isQvukzEbnc5V0inNa)
|
|
72
|
+
## **Initialization**
|
|
73
|
+
The following is the sample code for SDK initialization:
|
|
74
|
+
```cpp
|
|
75
|
+
#include "../include/TDAnalytics.h"
|
|
76
|
+
#include "../include/TDLoggerConsumer.h"
|
|
77
|
+
#include "../include/TDDebugConsumer.h"
|
|
78
|
+
#include "../include/TDBatchConsumer.h"
|
|
79
|
+
|
|
80
|
+
using namespace thinkingDataAnalytics;
|
|
81
|
+
|
|
82
|
+
int main(int argc, char *argv[]) {
|
|
83
|
+
TDLoggerConsumer::Config config = TDLoggerConsumer::Config("LOG_DIRECTORY", 20, 500, TDLoggerConsumer::HOURLY);
|
|
84
|
+
config.fileNamePrefix = "te";
|
|
85
|
+
config.rotateMode = TDLoggerConsumer::HOURLY;
|
|
86
|
+
|
|
87
|
+
TDConsumer *consumer = new TDLoggerConsumer(config);
|
|
88
|
+
TDAnalytics te(*consumer, false);
|
|
89
|
+
}
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
`LOG_DIRECTORY` is the local folder path.
|
|
93
|
+
## **Common Features**
|
|
94
|
+
In order to ensure that the distinct ID and account ID can be bound smoothly, if your game uses the distinct ID and account ID, we strongly recommend that you upload these two IDs at the same time, otherwise the account will not match, causing users to double count. For specific ID binding rules, please refer to the chapter on [User Identification Rules](https://thinkingdata.feishu.cn/wiki/Pov9wECdsi2QQsk4NN9cEPsvnyc).
|
|
95
|
+
### 3.1 **Sending Events**
|
|
96
|
+
You can call `track` to upload events. It is suggested that you set event properties based on the data tracking plan drafted previously. Here is an example of a user buying an item:
|
|
97
|
+
```cpp
|
|
98
|
+
TDPropertiesNode event_properties;
|
|
99
|
+
event_properties.SetString("name1", "XZ_debug");
|
|
100
|
+
event_properties.SetString("name2", "logbugs");
|
|
101
|
+
event_properties.SetString("name3", "name3");
|
|
102
|
+
event_properties.SetString("#uuid", "1234567890");
|
|
103
|
+
event_properties.SetNumber("test_number_int", 3);
|
|
104
|
+
event_properties.SetNumber("test_number_double", 3.14);
|
|
105
|
+
event_properties.SetBool("test_bool", true);
|
|
106
|
+
std::string test_string = "test_string";
|
|
107
|
+
event_properties.SetString("test_stl_string1", test_string);
|
|
108
|
+
event_properties.SetDateTime("test_time1", time(nullptr), 0);
|
|
109
|
+
timeb t = {};
|
|
110
|
+
ftime(&t);
|
|
111
|
+
event_properties.SetDateTime("#time", t.time, t.millitm);
|
|
112
|
+
std::vector<std::string> test_list;
|
|
113
|
+
test_list.emplace_back("item11");
|
|
114
|
+
test_list.emplace_back("item21");
|
|
115
|
+
event_properties.SetList("test_list1", test_list);
|
|
116
|
+
|
|
117
|
+
// track event
|
|
118
|
+
te.track("accountId", "distinctId", "eventName", event_properties);
|
|
119
|
+
```
|
|
120
|
+
|
|
121
|
+
- Key is the name of the property and refers to the string type. It must start with a character, and contain numbers, characters (insensitive to case, and upper cases would be transformed into lower cases by TE) and underscores "_", with a maximum length of 50 characters.
|
|
122
|
+
- Value, the value of the property, supports string, numbers, Boolean, time, object, array object, and array
|
|
123
|
+
<quote-container>
|
|
124
|
+
**The requirements for event properties and user properties are the same as that for super properties**
|
|
125
|
+
</quote-container>
|
|
126
|
+
|
|
127
|
+
### 3.2** User Properties**
|
|
128
|
+
You can set general user properties by calling `user_set` API. The original properties would be replaced by the properties uploaded via this API. If no user properties are set before, user properties will be newly created. The type of newly-created user properties must conform to that of the uploaded properties. User name setting is taken as the example here:
|
|
129
|
+
```cpp
|
|
130
|
+
// user_set
|
|
131
|
+
TDPropertiesNode userSet_properties;
|
|
132
|
+
userSet_properties.SetString("userName", "test");
|
|
133
|
+
te.user_set("accountId", "distinctId", userSet_properties);
|
|
134
|
+
```
|
|
135
|
+
|
|
136
|
+
### 3.3 Reported data
|
|
137
|
+
When using `TDLoggerConsumer`, the captured events are converted to json strings and then added to the cache array. Data is written to disk only when the number of array elements exceeds the set capacity. The default capacity is 20.
|
|
138
|
+
You can call the `flush()` api to report data to the TE immediately under certain service scenarios. However, frequent calls to `flush()` can result in degraded service performance.
|
|
139
|
+
```cpp
|
|
140
|
+
te.flush();
|
|
141
|
+
```
|
|
142
|
+
|
|
143
|
+
### 3.4 Close SDK
|
|
144
|
+
```cpp
|
|
145
|
+
te.close();
|
|
146
|
+
```
|
|
147
|
+
|
|
148
|
+
<quote-container>
|
|
149
|
+
Close and exit the SDK. Please call this api before closing the server to avoid data loss in the cache
|
|
150
|
+
</quote-container>
|
|
151
|
+
|
|
152
|
+
## **Best Practice**
|
|
153
|
+
The following sample code covers all the above-mentioned operations. It is recommended that the codes be used in the following steps:
|
|
154
|
+
```cpp
|
|
155
|
+
// Import header file (adjust the path yourself)
|
|
156
|
+
#include "../include/TDAnalytics.h"
|
|
157
|
+
#include "../include/TDLoggerConsumer.h"
|
|
158
|
+
|
|
159
|
+
using namespace thinkingDataAnalytics;
|
|
160
|
+
|
|
161
|
+
TDLoggerConsumer::Config config = TDLoggerConsumer::Config("LOG_DIRECTORY", 20, 500, TDLoggerConsumer::HOURLY);
|
|
162
|
+
config.fileNamePrefix = "te";
|
|
163
|
+
config.rotateMode = TDLoggerConsumer::HOURLY;
|
|
164
|
+
|
|
165
|
+
TDConsumer *consumer = new TDLoggerConsumer(config);
|
|
166
|
+
TDAnalytics te(*consumer, false);
|
|
167
|
+
|
|
168
|
+
TDPropertiesNode event_properties;
|
|
169
|
+
event_properties.SetString("name1", "XZ_debug");;
|
|
170
|
+
event_properties.SetNumber("test_number_int", 3);
|
|
171
|
+
event_properties.SetBool("test_bool", true);
|
|
172
|
+
te.track("accountId", "distinctId", "eventName", event_properties);
|
|
173
|
+
|
|
174
|
+
TDPropertiesNode userSet_properties;
|
|
175
|
+
userSet_properties.SetString("userName", "test");
|
|
176
|
+
te.user_set("accountId", "distinctId", userSet_properties);
|
|
177
|
+
|
|
178
|
+
te.flush();
|
|
179
|
+
```
|
|
@@ -0,0 +1,189 @@
|
|
|
1
|
+
---
|
|
2
|
+
code: c_sdk_installation
|
|
3
|
+
name: "C "
|
|
4
|
+
wikiToken: Er3owqC0UiRR21kCDgZcY4qJn3e
|
|
5
|
+
parentWikiToken: IKVPwn4NfiIhijk5EcAcMf6pn7e
|
|
6
|
+
updateTime: 1774252007000
|
|
7
|
+
sourceUrl: https://docs-v2.thinkingdata.cn/?version=v6.0&lan=en-US&code=c_sdk_installation
|
|
8
|
+
---
|
|
9
|
+
::: tip
|
|
10
|
+
Before you begin, please read [<text color="purple" underline="true">Preparation before Data Ingestion</text>](https://thinkingdata.feishu.cn/wiki/OhD8we9iai6Xk5kM1QNc8ITRnQe).
|
|
11
|
+
:::
|
|
12
|
+
**Latest version: **v2.0.0
|
|
13
|
+
**Update time: **2023-11-30
|
|
14
|
+
**Resource download: **[Source Code](https%3A%2F%2Fgithub.com%2FThinkingDataAnalytics%2Fc-sdk)
|
|
15
|
+
::: warning Notice
|
|
16
|
+
Current documentation applies to v2.0.0 and later. For historical versions, see [Data Ingestion Guide - C (V1)](https%3A%2F%2Fdocs.thinkingdata.cn%2Fta-manual%2Fv4.1%2Fen%2Finstallation%2Finstallation_menu%2Fserver_sdk%2Fc_sdk_installation%2Fc_sdk_installation.html)
|
|
17
|
+
:::
|
|
18
|
+
## **SDK Integration**
|
|
19
|
+
1.1 Download the source code, modify the `CMakeLists.txt` file.
|
|
20
|
+
e.g. Use logconsumer mode:
|
|
21
|
+
```bash
|
|
22
|
+
cmake_minimum_required(VERSION 3.12)
|
|
23
|
+
project(thinking_data_c)
|
|
24
|
+
message(STATUS "[ThinkingData] CMAKE_HOST_SYSTEM: ${CMAKE_HOST_SYSTEM} ")
|
|
25
|
+
|
|
26
|
+
include_directories(include)
|
|
27
|
+
|
|
28
|
+
#################################################################
|
|
29
|
+
|
|
30
|
+
# Product Library: logging consumer
|
|
31
|
+
if(WIN32)
|
|
32
|
+
add_compile_definitions(USE_WIN)
|
|
33
|
+
set(CMAKE_C_FLAGS "-std=c89 -pedantic-errors -m64")
|
|
34
|
+
else()
|
|
35
|
+
add_compile_definitions(USE_POSIX)
|
|
36
|
+
set(CMAKE_C_FLAGS "-std=c89")
|
|
37
|
+
endif()
|
|
38
|
+
SET(TE_LIB_NAME thinkingdata)
|
|
39
|
+
add_library(${TE_LIB_NAME} src/thinkingdata.c src/td_json.c src/td_list.c src/td_util.c src/td_logger_consumer.c)
|
|
40
|
+
if(WIN32)
|
|
41
|
+
include_directories(thirdparty/pcre/include)
|
|
42
|
+
link_directories(thirdparty/pcre/lib)
|
|
43
|
+
target_link_libraries(${TE_LIB_NAME} pcre_x64)
|
|
44
|
+
endif()
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
1.2 Logbus Integration
|
|
48
|
+
We recommend using SDK+LogBus to track and report data on server. You can refer to the following documents to complete the installation of Logbus:[ LogBus User Guide](https://thinkingdata.feishu.cn/wiki/SlE6wOEK3isQvukzEbnc5V0inNa)
|
|
49
|
+
## **Initialization**
|
|
50
|
+
The following is the sample code for SDK initialization:
|
|
51
|
+
```c
|
|
52
|
+
struct TDAnalytics* ta = NULL;
|
|
53
|
+
struct TDConsumer* consumer = NULL;
|
|
54
|
+
|
|
55
|
+
TDConfig* config = td_init_config();
|
|
56
|
+
char* logPath = "LOG_DIRECTORY";
|
|
57
|
+
TD_ASSERT(TD_OK == td_add_string("file_path", logPath, strlen(logPath), config));
|
|
58
|
+
|
|
59
|
+
if (TD_OK != td_init_consumer(&consumer, config)) {
|
|
60
|
+
fprintf(stderr, "Failed to initialize the consumer.");
|
|
61
|
+
}
|
|
62
|
+
td_free_properties(config);
|
|
63
|
+
|
|
64
|
+
if (TD_OK != td_init(consumer, &ta)) {
|
|
65
|
+
fprintf(stderr, "Failed to initialize the SDK.");
|
|
66
|
+
return 1;
|
|
67
|
+
}
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
`LOG_DIRECTORY` is the local folder path.
|
|
71
|
+
## **Common Features**
|
|
72
|
+
In order to ensure that the distinct ID and account ID can be bound smoothly, if your game uses the distinct ID and account ID, we strongly recommend that you upload these two IDs at the same time, otherwise the account will not match, causing users to double count. For specific ID binding rules, please refer to the chapter on [User Identification Rules](https://thinkingdata.feishu.cn/wiki/Pov9wECdsi2QQsk4NN9cEPsvnyc).
|
|
73
|
+
### **3.1 Sending Events**
|
|
74
|
+
You can call `td_track` to upload events. It is suggested that you set event properties based on the data tracking plan drafted previously. Here is an example of a user buying an item:
|
|
75
|
+
```c
|
|
76
|
+
TDProperties *properties = td_init_properties();
|
|
77
|
+
|
|
78
|
+
TD_ASSERT(TD_OK == td_add_string("#ip", "192.168.1.1", strlen("192.168.1.1"), properties));
|
|
79
|
+
|
|
80
|
+
TD_ASSERT(TD_OK == td_add_string("channel", "ta", strlen("ta"), properties));
|
|
81
|
+
TD_ASSERT(TD_OK == td_add_int("age", 1, properties));
|
|
82
|
+
TD_ASSERT(TD_OK == td_add_bool("is_success", TD_TRUE, properties));
|
|
83
|
+
TD_ASSERT(TD_OK == td_add_date("birthday", time(NULL), 0, properties));
|
|
84
|
+
|
|
85
|
+
TD_ASSERT(TD_OK == td_append_array("arr", "value", strlen("value"), properties));
|
|
86
|
+
TD_ASSERT(TD_OK == td_append_array("arr", "value1", strlen("value1"), properties));
|
|
87
|
+
|
|
88
|
+
TDProperties *object = td_init_custom_properties("object");
|
|
89
|
+
TD_ASSERT(TD_OK == td_add_string("key", "value", strlen("value"), object));
|
|
90
|
+
TD_ASSERT(TD_OK == td_add_property(object, properties));
|
|
91
|
+
|
|
92
|
+
TDProperties *object1 = td_init_custom_properties("object1");
|
|
93
|
+
TD_ASSERT(TD_OK == td_add_string("key", "value", strlen("value"), object1));
|
|
94
|
+
TD_ASSERT(TD_OK == td_append_properties("object_arr", object1, properties));
|
|
95
|
+
|
|
96
|
+
TD_ASSERT(TD_OK == td_track("account_id", "distinct_id", "payment", properties, ta));
|
|
97
|
+
td_free_properties(properties);
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
- Key is the name of the property and refers to the string type. It must start with a character, and contain numbers, characters (insensitive to case, and upper cases would be transformed into lower cases by TE) and underscores "_", with a maximum length of 50 characters.
|
|
101
|
+
- Value, the value of the property, supports string, numbers, Boolean, time, object, array object, and array
|
|
102
|
+
<quote-container>
|
|
103
|
+
**The requirements for event properties and user properties are the same as that for super properties**
|
|
104
|
+
</quote-container>
|
|
105
|
+
|
|
106
|
+
### 3.2** **User Properties**
|
|
107
|
+
You can set general user properties by calling `td_user_set` API. The original properties would be replaced by the properties uploaded via this API. If no user properties are set before, user properties will be newly created. The type of newly-created user properties must conform to that of the uploaded properties. User name setting is taken as the example here:
|
|
108
|
+
```c
|
|
109
|
+
TDProperties *user_properties = td_init_properties();
|
|
110
|
+
TD_ASSERT(TD_OK == td_add_string("user_name", "TA", strlen("TA"), user_properties));
|
|
111
|
+
TD_ASSERT(TD_OK == td_user_set(account_id, distinct_id, user_properties,ta));
|
|
112
|
+
td_free_properties(user_properties);
|
|
113
|
+
|
|
114
|
+
TDProperties *user_properties2 = td_init_properties();
|
|
115
|
+
TD_ASSERT(TD_OK == td_add_string("user_name", "TE", strlen("TE"), user_properties2));
|
|
116
|
+
TD_ASSERT(TD_OK == td_user_set(account_id, distinct_id, user_properties2,ta));
|
|
117
|
+
td_free_properties(user_properties2);
|
|
118
|
+
```
|
|
119
|
+
|
|
120
|
+
### 3.3 Reported data
|
|
121
|
+
Use `td_init_consumer()` to initialize the SDK. The SDK will write the collected data to the disk in real time.
|
|
122
|
+
Internally, the `td_flush()` function synchronizes the default memory cache in the file system to disk in real time. No manual call is usually required.
|
|
123
|
+
```c
|
|
124
|
+
td_flush(ta);
|
|
125
|
+
```
|
|
126
|
+
|
|
127
|
+
### 3.4 Close SDK
|
|
128
|
+
```c
|
|
129
|
+
td_free(ta);
|
|
130
|
+
td_consumer_free(consumer);
|
|
131
|
+
```
|
|
132
|
+
|
|
133
|
+
<quote-container>
|
|
134
|
+
Close and exit the SDK. Please call this API before closing the server to avoid data loss in the cache
|
|
135
|
+
</quote-container>
|
|
136
|
+
|
|
137
|
+
## **Best Practice**
|
|
138
|
+
The following sample code covers all the above-mentioned operations. It is recommended that the codes be used in the following steps:
|
|
139
|
+
```c
|
|
140
|
+
struct TDAnalytics* ta = NULL;
|
|
141
|
+
struct TDConsumer* consumer = NULL;
|
|
142
|
+
|
|
143
|
+
TDConfig* config = td_init_config();
|
|
144
|
+
char* logPath = "LOG_DIRECTORY";
|
|
145
|
+
TD_ASSERT(TD_OK == td_add_string("file_path", logPath, strlen(logPath), config));
|
|
146
|
+
|
|
147
|
+
if (TD_OK != td_init_consumer(&consumer, config)) {
|
|
148
|
+
fprintf(stderr, "Failed to initialize the consumer.");
|
|
149
|
+
}
|
|
150
|
+
td_free_properties(config);
|
|
151
|
+
|
|
152
|
+
if (TD_OK != td_init(consumer, &ta)) {
|
|
153
|
+
fprintf(stderr, "Failed to initialize the SDK.");
|
|
154
|
+
return 1;
|
|
155
|
+
}
|
|
156
|
+
|
|
157
|
+
TDProperties *properties = td_init_properties();
|
|
158
|
+
|
|
159
|
+
TD_ASSERT(TD_OK == td_add_string("#ip", "192.168.1.1", strlen("192.168.1.1"), properties));
|
|
160
|
+
|
|
161
|
+
TD_ASSERT(TD_OK == td_add_string("channel", "ta", strlen("ta"), properties));
|
|
162
|
+
TD_ASSERT(TD_OK == td_add_int("age", 1, properties));
|
|
163
|
+
TD_ASSERT(TD_OK == td_add_bool("is_success", TD_TRUE, properties));
|
|
164
|
+
TD_ASSERT(TD_OK == td_add_date("birthday", time(NULL), 0, properties));
|
|
165
|
+
|
|
166
|
+
TD_ASSERT(TD_OK == td_append_array("arr", "value", strlen("value"), properties));
|
|
167
|
+
TD_ASSERT(TD_OK == td_append_array("arr", "value1", strlen("value1"), properties));
|
|
168
|
+
|
|
169
|
+
TDProperties *object = td_init_custom_properties("object");
|
|
170
|
+
TD_ASSERT(TD_OK == td_add_string("key", "value", strlen("value"), object));
|
|
171
|
+
TD_ASSERT(TD_OK == td_add_property(object, properties));
|
|
172
|
+
|
|
173
|
+
TDProperties *object1 = td_init_custom_properties("object1");
|
|
174
|
+
TD_ASSERT(TD_OK == td_add_string("key", "value", strlen("value"), object1));
|
|
175
|
+
TD_ASSERT(TD_OK == td_append_properties("object_arr", object1, properties));
|
|
176
|
+
|
|
177
|
+
TD_ASSERT(TD_OK == td_track("account_id", "distinct_id", "payment", properties, ta));
|
|
178
|
+
td_free_properties(properties);
|
|
179
|
+
|
|
180
|
+
TDProperties *user_properties = td_init_properties();
|
|
181
|
+
TD_ASSERT(TD_OK == td_add_string("user_name", "TA", strlen("TA"), user_properties));
|
|
182
|
+
TD_ASSERT(TD_OK == td_user_set("account_id", "distinct_id", user_properties,ta));
|
|
183
|
+
td_free_properties(user_properties);
|
|
184
|
+
|
|
185
|
+
TDProperties *user_properties2 = td_init_properties();
|
|
186
|
+
TD_ASSERT(TD_OK == td_add_string("user_name", "TE", strlen("TE"), user_properties2));
|
|
187
|
+
TD_ASSERT(TD_OK == td_user_set("account_id", "distinct_id", user_properties2,ta));
|
|
188
|
+
td_free_properties(user_properties2);
|
|
189
|
+
```
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
---
|
|
2
|
+
code: erlang_sdk_debug
|
|
3
|
+
name: "Debugging and Logging"
|
|
4
|
+
wikiToken: In61wT9A5iEn0fky0DacwxDAnIf
|
|
5
|
+
parentWikiToken: PnlawuZLdi5AtakVJFEcXnohnGc
|
|
6
|
+
updateTime: 1774249338000
|
|
7
|
+
sourceUrl: https://docs-v2.thinkingdata.cn/?version=v6.0&lan=en-US&code=erlang_sdk_debug
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
::: warning Notice
|
|
11
|
+
The SDK Debug mode is used only for access debugging. Do not apply it to the production environment.
|
|
12
|
+
:::
|
|
13
|
+
During the process of SDK Integration, you can perform real-time debugging by checking SDK logs in the IDE console or using the Debug function of TE.
|
|
14
|
+
## Debugging
|
|
15
|
+
You need to follow the following two steps to enable the Debug mode:
|
|
16
|
+
#### 2.1 Use DebugConsumer
|
|
17
|
+
The sample code for enabling the Debug mode on the client side is as follows:
|
|
18
|
+
```erlang
|
|
19
|
+
ServerUrl = "server_url",
|
|
20
|
+
AppID = "app_id",
|
|
21
|
+
IsWrite = true,
|
|
22
|
+
DeviceId = "123456789",
|
|
23
|
+
|
|
24
|
+
Consumer = td_debug_consumer:init_with_config(ServerUrl, AppID, IsWrite, DeviceId),
|
|
25
|
+
TE_SDK = td_analytics:init_with_consumer(Consumer),
|
|
26
|
+
|
|
27
|
+
AccountId0 = "account_id_Erlang_0",
|
|
28
|
+
td_analytics:track_instance(TE_SDK, AccountId0, "distinct_logbus", "ViewProduct", #{"#key_1" => "🚓🦽🦼🚲🚜🚜🦽", "key_2" => 2.2, "key_array" => ["🚌", "🏍", "😚😊"]}),
|
|
29
|
+
td_analytics:close_instance(TE_SDK).
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
#### 2.2 Add Device
|
|
33
|
+
To avoid launching the Debug mode in the production environment, it is required that only specified device can enable Debug mode. The Debug mode can only be enabled for devices whose ID has been configured in the "Debug data" sector on the "tracking management" page of the TE.
|
|
34
|
+
<image token="S4GEbaN7fosQCKxozN9cvFnhnSg" width="1280" height="590" align="center"/>
|
|
35
|
+
|
|
36
|
+
<quote-container>
|
|
37
|
+
It can only be used for data verification at the integration stage, and should not be used in the online environment.
|
|
38
|
+
</quote-container>
|
package/wiki/te-docs/raw/data-ingestion-guide/server-sdk/erlang/erlang-advanced/preset-properties.md
ADDED
|
@@ -0,0 +1,126 @@
|
|
|
1
|
+
---
|
|
2
|
+
code: erlang_sdk_preset_properties
|
|
3
|
+
name: "Preset Properties"
|
|
4
|
+
wikiToken: LFkbwNEG8idFlikyL1mcfeIRnIc
|
|
5
|
+
parentWikiToken: PnlawuZLdi5AtakVJFEcXnohnGc
|
|
6
|
+
updateTime: 1774249340000
|
|
7
|
+
sourceUrl: https://docs-v2.thinkingdata.cn/?version=v6.0&lan=en-US&code=erlang_sdk_preset_properties
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
The following present properties are properties that all events in SDK would have.
|
|
11
|
+
|
|
12
|
+
<lark-table rows="8" cols="4" column-widths="169,152,140,259">
|
|
13
|
+
|
|
14
|
+
<lark-tr>
|
|
15
|
+
<lark-td>
|
|
16
|
+
Property name
|
|
17
|
+
</lark-td>
|
|
18
|
+
<lark-td>
|
|
19
|
+
Display name
|
|
20
|
+
</lark-td>
|
|
21
|
+
<lark-td>
|
|
22
|
+
Property type
|
|
23
|
+
</lark-td>
|
|
24
|
+
<lark-td>
|
|
25
|
+
Instruction
|
|
26
|
+
</lark-td>
|
|
27
|
+
</lark-tr>
|
|
28
|
+
<lark-tr>
|
|
29
|
+
<lark-td>
|
|
30
|
+
#ip
|
|
31
|
+
</lark-td>
|
|
32
|
+
<lark-td>
|
|
33
|
+
IP address
|
|
34
|
+
</lark-td>
|
|
35
|
+
<lark-td>
|
|
36
|
+
Text
|
|
37
|
+
</lark-td>
|
|
38
|
+
<lark-td>
|
|
39
|
+
IP address of the user, based on which TE would get the geographical location of the user
|
|
40
|
+
</lark-td>
|
|
41
|
+
</lark-tr>
|
|
42
|
+
<lark-tr>
|
|
43
|
+
<lark-td>
|
|
44
|
+
#country
|
|
45
|
+
</lark-td>
|
|
46
|
+
<lark-td>
|
|
47
|
+
Country
|
|
48
|
+
</lark-td>
|
|
49
|
+
<lark-td>
|
|
50
|
+
Text
|
|
51
|
+
</lark-td>
|
|
52
|
+
<lark-td>
|
|
53
|
+
The country where the user is located; generated based on the IP address
|
|
54
|
+
</lark-td>
|
|
55
|
+
</lark-tr>
|
|
56
|
+
<lark-tr>
|
|
57
|
+
<lark-td>
|
|
58
|
+
#country_code
|
|
59
|
+
</lark-td>
|
|
60
|
+
<lark-td>
|
|
61
|
+
Country code
|
|
62
|
+
</lark-td>
|
|
63
|
+
<lark-td>
|
|
64
|
+
Text
|
|
65
|
+
</lark-td>
|
|
66
|
+
<lark-td>
|
|
67
|
+
The code of the country where the user is located (ISO 3166-1 alpha-2, two English characters in upper case); generated based on the IP address
|
|
68
|
+
</lark-td>
|
|
69
|
+
</lark-tr>
|
|
70
|
+
<lark-tr>
|
|
71
|
+
<lark-td>
|
|
72
|
+
#province
|
|
73
|
+
</lark-td>
|
|
74
|
+
<lark-td>
|
|
75
|
+
Province
|
|
76
|
+
</lark-td>
|
|
77
|
+
<lark-td>
|
|
78
|
+
Text
|
|
79
|
+
</lark-td>
|
|
80
|
+
<lark-td>
|
|
81
|
+
The province where the user is located; generated based on the IP address
|
|
82
|
+
</lark-td>
|
|
83
|
+
</lark-tr>
|
|
84
|
+
<lark-tr>
|
|
85
|
+
<lark-td>
|
|
86
|
+
#city
|
|
87
|
+
</lark-td>
|
|
88
|
+
<lark-td>
|
|
89
|
+
City
|
|
90
|
+
</lark-td>
|
|
91
|
+
<lark-td>
|
|
92
|
+
Text
|
|
93
|
+
</lark-td>
|
|
94
|
+
<lark-td>
|
|
95
|
+
The city where the user is located; generated based on the IP address
|
|
96
|
+
</lark-td>
|
|
97
|
+
</lark-tr>
|
|
98
|
+
<lark-tr>
|
|
99
|
+
<lark-td>
|
|
100
|
+
#lib
|
|
101
|
+
</lark-td>
|
|
102
|
+
<lark-td>
|
|
103
|
+
SDK type
|
|
104
|
+
</lark-td>
|
|
105
|
+
<lark-td>
|
|
106
|
+
Text
|
|
107
|
+
</lark-td>
|
|
108
|
+
<lark-td>
|
|
109
|
+
The type of SDK which you integrate, e.g., Golang, etc.
|
|
110
|
+
</lark-td>
|
|
111
|
+
</lark-tr>
|
|
112
|
+
<lark-tr>
|
|
113
|
+
<lark-td>
|
|
114
|
+
#lib_version
|
|
115
|
+
</lark-td>
|
|
116
|
+
<lark-td>
|
|
117
|
+
SDK version
|
|
118
|
+
</lark-td>
|
|
119
|
+
<lark-td>
|
|
120
|
+
Text
|
|
121
|
+
</lark-td>
|
|
122
|
+
<lark-td>
|
|
123
|
+
The version of the SDK which you integrate
|
|
124
|
+
</lark-td>
|
|
125
|
+
</lark-tr>
|
|
126
|
+
</lark-table>
|