# Create Event

{% hint style="info" %}
Auto Event Registration

If you have already completed Hackle platform integration, sending a new event directly from the SDK automatically registers the event key on the Dashboard.\
For more details, refer to the [Auto Event Registration](/en/event-management/event-auto-regist.md) document.
{% endhint %}

You can create an event by clicking the **`+ Create New Event`** button located in the upper right area of the **`Event menu`**.

![](/files/xvDpND3vp5I0cU38k5fY)

## 1. Enter Event Key

The Event Key value is the value that defines a user's action in code. For example, if you defined the click of a purchase button in code as `purchase`, enter `purchase` as the Event Key.

The Event Key value can only contain **`alphabets`**, **`numbers`**, **`_`**, **`-`**, and **`.`**, with a length limit of 1 to 128 characters. If an event key with the same name has already been created, you cannot create another event with that duplicate key value.

{% hint style="warning" %}
The event key value cannot be modified once created.

Before clicking the Create button, make sure there are no typos in the entered event key value and that it follows the Naming Convention agreed upon within your organization.
{% endhint %}

## 2. Write Event Description

If there is a risk that the event key value alone may not clearly convey what the event is, adding a description can be very helpful to team members who share this event. Including in this area the exact point in time when the event data is collected can be useful during subsequent development or QA processes. The event description can be modified at any time, so please add more whenever you think additional description is needed.

## 3. Event Type

{% hint style="info" %}
Auto-collect URL event supported

You can easily collect events by simply entering a URL address without any development work. Properties included in the URL are automatically saved and can be used as filters or targeting in A/B Tests and Data Analytics.
{% endhint %}

1. **Standard Event**: An event sent via SDK. You can pre-create event names before sending them via SDK. No separate configuration is required when selecting a standard event. After creating the event, send the event to Hackle via SDK using that event key.
2. **Auto-collect URL Event**: The JavaScript and React SDKs for Web provide a feature to auto-collect URLs. You can group auto-collected URLs with the conditions you want and use them as a single standard event. To use the Auto-collect URL event type, you need to configure conditions specifying which URLs to select.

### 3-2. Auto-collect URL event configuration

![](/files/K4tOnaopgZalIe7CCrp4)

1. Enter the URL you want to configure in the input field and click **`Add AND condition`**.
2. In the **Configured URL conditions** below, the URL you entered is automatically split into individual items.
   1. Query parameters contained in the URL address—such as product ID, category ID, acquisition path type—are automatically collected as properties of that event. Multiple types of information mixed together, or a single type of information in list format, are all collected without omission.
   2. Examples
      1. abc.com/detail/?itemId=1,2,3
      2. abc.com/detail/?itemId=1\&itemId=2\&itemId=3
      3. abc.com/detail/?itemId\[]=1\&itemId\[]=2\&itemId\[]=3\
         \=> Saved as a list "{1,2,3}" under the property "itemId"
3. If you want to add more URLs or pagePath/host conditions later, use **`Add AND condition`** in the **Configured URL conditions** section to enter them directly. Note that only one host condition can be configured. If two or more are configured, the AND condition may prevent normal operation.

## 4. Upload Event Image

If the event name and description are insufficient, you can upload an image to share more detailed information with team members. Uploading a screenshot showing where and when the event occurs will be useful. The event image can be modified or deleted at any time after creation. However, only one image file (jpg, jpeg, png) of 10 MB or less can be uploaded.

## 5. Create Event

Clicking the **`Create`** button in the lower right completes the event creation.

## 6. Code Work Related to the Event

After creation, Hackle SDK integration and code work are required to track the event. Inform the developer of the event key and the conditions under which the event occurs. The event must be sent to Hackle at the time the event triggers.

For example, suppose you created a **purchase** event, and it triggers when the user clicks the purchase button. Then the developer must call Hackle SDK's **track** method in the code when the user clicks the purchase button to send the event key. For the **track** method, refer to the SDK guide for the language you are using.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.hackle.io/en/event-management/create-event.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
