Create events
Events are the basis for event analysis on the Mini Program platform. You must create events before you can perform event analysis.
This topic describes how to create events.
Procedure
To create an event, take the following steps:
- Log on to the Mini Program platform.
- In the left navigation panel, choose Analytics > Custom Analysis.
- On the displayed Custom Analysis page, find the desired mini program.
- Click Events in the Action column. The Manage Event tab is displayed.
- On the Manage Event tab, click New Event.

Figure 1. Create an event
- On the New Event page, configure the parameters:
Parameter | Description | Example value |
Event Name | The name of the event. Follow a clear and consistent naming convention so analysts and developers can recognize it. | event_example1 |
Data Reporting Method | Specify the method in which data is collected and reported. By default, By Self-Defined Actions is selected, which specifies that data are reported when the custom actions occur and conditions match. | By Self-Defined Actions |
Action 1 | Configure the action that triggers the event. An event can contain one or multiple actions. Each action is an independent rule that can trigger the event.
After configuring an action, you can click Action to add more actions to the event. | N/A |
- After the event is configured, you can click one of the following buttons based on your business requirements:
- Save: Stores your configuration as a draft.
- Save & Test: Saves and opens test mode so you can validate that triggers fire as expected, selectors match, fields populate correctly, and Report Type behaves as intended. Use this before publishing.
- Save & Publish: Publishes the event. Data collection starts immediately for users who meet the action conditions. You can also publish the event after the event is created. For more information, see Publish events.