For the complete documentation index, see llms.txt. This page is also available as Markdown.

Event Tracking

The Hackle SDK provides the ability to send user events to Hackle. By using this feature at every point where a user action occurs, you can collect meaningful data about user behavior and use it for user behavior analysis.

track

You can send user events by passing the Event Key to the track() method.

Parameter
Type
Required
Constraints

Event name (key)

string

Required

Character limit is 128 characters.

Example

Assume an event key called purchase is defined to collect an event when the user clicks the "Buy" button.

/* 예시 1: 이벤트 키만 전송 */
hackleClient.track({key: "purchase"});

Property

The Hackle SDK supports adding properties to Event objects.

  • Properties must be sent as key-value pairs (Property Key and Property Value).

  • The maximum number of properties that can be added to an event object is 64.

Category
Type
Constraints

Property Key

string

  • Character limit is 128 characters.

  • Case-insensitive.

  • For example, AGE and age are recognized as the same Property Key.

Property Value

boolean, string, number, array

  • For string type, the character limit is 1024 characters.

  • String type is case-sensitive.

  • For example, APPLE and apple are recognized as different Property Values.

  • For number type, up to 15 integer digits and up to 6 decimal places are supported.

Example

In the example below, three properties (pay_method, discount_amount, is_discount) are added.

Last updated