We use essential cookies for the website to function, as well as analytics cookies for analyzing and creating statistics of the website performance. To agree to the use of analytics cookies, click "Accept All". You can manage your preferences at any time by clicking "Cookie Settings" on the footer. More Information.

Only Essential Cookies
Accept All
Notice on Closing the Huawei Analytics Service Access Portal

Dear developer!

Due to business adjustments, we will close the entrance for Huawei Analytics services on June 30, 2024 and no longer support new user registration. Developers of projects that have already activated Huawei Analytics services are not affected and can still continue to use Huawei Analytics services. If there are any changes, we will notify them separately. Thank you for your support!

SamplesAnalytics KitiOS Sample Code

iOS Sample Code

The sample code provides a demo project that demonstrates how to call open APIs of Analytics Kit. Guided by the demo, you will learn how to:

  • Use Xcode to efficiently integrate Analytics Kit.
  • Correctly use APIs of Analytics Kit.
Expand

Sample Code

Find It on Gitee

Find It on GitHub

iOS sample code

Click here

Click here

NOTE

You can use the sample code only after completing the following operations:

  1. Open the CLI and run the following commands:
    • cd~Project path
    • pod install
  2. Sign in to AppGallery Connect, download the agconnect-services.plist file of your app, and copy the file to your app's root directory of the demo project. Change bundle id to that of your app.