# Event Sources

## Overview

**The demand is to track how many successful orders have been made in a month.**&#x20;

<table><thead><tr><th width="353">Analysis</th><th>Action in CDP 365</th></tr></thead><tbody><tr><td><p>To have a successful order, an audience needs to take the action of purchasing. </p><p>That action is an event in CDP 365.</p></td><td>Create an <a href="#events">event</a> representing the purchasing action</td></tr><tr><td><p>The number of successful orders isn't insightful enough if it is used in a Marketing campaign. </p><p>Therefore, the data related to audiences, products, etc. are also demanded to make a complete analysis. </p></td><td>Create <a href="#event-attributes">event attributes</a> indicating audiences, products, etc.</td></tr><tr><td>Besides, these orders occurred from which sources if there are multiple sources generating revenues.</td><td>Create a <a href="#sources">source </a>defining where these orders made</td></tr></tbody></table>

### Steps of creating a Source&#x20;

&#x20;

<figure><img src="https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FBpIlOVxN0MVfwNKOjvJc%2Fimage.png?alt=media&#x26;token=aa25e2a3-0646-4ae6-b230-8a951027eba6" alt=""><figcaption><p>Steps</p></figcaption></figure>

* When creating a Source, it is required to assign events to track the interactions of audiences in that domain.&#x20;
* After having events, it is required to assign event attributes for the event to make the event insightful.
* Therefore, when creating a Source should have event attributes and events beforehand.

### Type of creating a new one

There are two options for creating an event attribute, an event, or a source

* 'Create new attribute' is to create a new one
* 'Create from existing attribute' is to create a new one based on the settings of an existing attribute, event, or source in CDP 365. The name and the description are required to change.

## Event attributes

### Create an event attribute

* Click create button
* Select the type of creating
* Set the configuration of event attribute

<figure><img src="https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FAypFGqhIs6UIg9Ow7cgW%2Fimage.png?alt=media&#x26;token=d9318a12-eb7c-4d99-8a62-f4aeec2b47d1" alt=""><figcaption><p>Create a new event attribute</p></figcaption></figure>

#### The configuration

<figure><img src="https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FSmFKPYvsMLyIuI02zHaB%2Fimage.png?alt=media&#x26;token=6adc6f4a-1923-4de7-8ffa-edcd71291247" alt=""><figcaption><p>The configuration</p></figcaption></figure>

The settings of an event attribute include

* Attribute type includes&#x20;
  * Attribute is an event attribute&#x20;
  * Line-item attribute is an event attribute that allows calculating complex formulas
  * For example, quantity and price are event attributes, but the total price of an order is a line-item attribute due to the complexity to calculate the total price. It requires the total quantity multiply the price.
* Attribute name&#x20;
* Attribute internal code is the code generated from the attribute name
* Description&#x20;
* Data type is the data format of values, for example, number, string, text
  * Display as is the specific format of event attributes, for example, if 'data type' is number then 'display as' is percentage, number, or currency
  * Is required is to make the event attribute required field
  * Auto suggestion is to make values of the event attribute automatically suggested when applying it.

<figure><img src="https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FSy7HYqhYkk2FsVzNSo7y%2Fimage.png?alt=media&#x26;token=1ef3a934-89a6-4c0c-88dd-b5de91f35081" alt=""><figcaption><p>An example of auto suggestion</p></figcaption></figure>

## Events

### Create a new event

* Click create button&#x20;
* Select the type of creating
* The settings of a new event include 2 steps
  * Fill event info
  * Assign event attributes

<figure><img src="https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FJ980TjLZv0nwIZS9Z5no%2Fimage.png?alt=media&#x26;token=9ef75699-a7d1-40b3-b1c2-b28c0e98ee2b" alt=""><figcaption><p>Create a new event</p></figcaption></figure>

#### The configuration

***Step 1: Fill event info***

<figure><img src="https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FR7SxQ3xR45t8CJbwUsC4%2Fimage.png?alt=media&#x26;token=79898210-a9ae-4fdf-baa5-deb2ec1cfa6d" alt=""><figcaption><p>Step 1: Fill event info</p></figcaption></figure>

* Event name
* Description&#x20;
* Event internal name is the code generated by event name
* 'Event action' and 'Event category' define an event. The combination must be unique for each event.
* Icon is the image making management of the event easier

#### ***Step 2: Assign event attributes***

* Left-hand side propose event attributes and Business Objects having in CDP 365
* Right-hand side contains event attributes and objects are assigned for the event
* Event attributes
* Object reference is Business Objects&#x20;
* Main object is the main Business Object into which the event aims to push data. Each event has one main object. Main object also contains line-item attribute.&#x20;
* Foreign object is a Business Object to which the data of the event relates. An event could have multiple foreign objects.
* For example, the purchase event could have&#x20;
  * Event attributes: quantity, price, etc.&#x20;
  * Main object: Product, the total revenue.
  * Foreign objects: Customers, Promotion, etc.

<figure><img src="https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FWMr7D1nx2Tc9BcnkBTLp%2Fimage.png?alt=media&#x26;token=0f297fcd-ac0d-49a6-af47-620dd9cd8529" alt=""><figcaption><p>Step 2: Assign attributes</p></figcaption></figure>

## Sources

### Create a new source

* Click create button&#x20;
* Select the type of creating
* The settings of a new source include
  * Choose source type
  * Fill source info
  * Assign events

<figure><img src="https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FgtxWagsLLOZaI0kbZ21Z%2Fimage.png?alt=media&#x26;token=08ac7fbe-d20b-446b-b5bf-8c3e459d3bd8" alt=""><figcaption><p>Create a new source</p></figcaption></figure>

#### The configuration

#### ***Step 1: Choose source type***

* Choose the type of source aimed to create
* There are 4 types and the settings of each type are different
  * Websites
  * Mobile App&#x20;
  * Server&#x20;
  * Cloud Service

<figure><img src="https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FfPNz7Dt0rsaiIzdbnVao%2Fimage.png?alt=media&#x26;token=007d6368-7513-4828-a3c7-3b582171a08d" alt=""><figcaption><p>Step 1: Choose source type</p></figcaption></figure>

#### ***Step 2: Fill source info***

* Source name
* Description&#x20;
* Domain: starts with ***http\://*** or ***https\://*** if the source type is a website&#x20;
* Icon: an image represents the source
* Associate with UTM: If selected, it will automatically sync data from UTM to ATM

<figure><img src="https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FN1XsrYmdS1y7NvwapQVe%2Fimage.png?alt=media&#x26;token=16a69e41-f749-4ca6-af8d-81c04de50f4b" alt=""><figcaption><p>Step 2: Fill source info (website)</p></figcaption></figure>

#### ***Step 3: Assign event***

* Choose event template. The event templates proposed by CDP 365 are already assigned event attributes and objects.
* Assign events for source&#x20;
  * Click![](https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FHuJsWyMXUqWSSxWXc5Y3%2Fimage.png?alt=media\&token=3b70d8c0-4e98-4b5f-b445-055390690c62)to add new a event to the source&#x20;
  * Click ![](https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FJQZfpgMoTMIvg24CUQus%2Fimage.png?alt=media\&token=edc5eb6c-abe0-4b9b-8799-ab4bc9f3ce6e) to remove an event/event attribute/object reference&#x20;
* [Choose event attributes and objects](#step-2-assign-event-attributes)

<figure><img src="https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FoGfn0mpf0LhWKVHpCJD6%2Fimage.png?alt=media&#x26;token=e0e83cf4-c5d3-474c-8c69-960a90668ba5" alt=""><figcaption><p>Step 3: Assign event</p></figcaption></figure>

## Check the new created ones

### Basic functions

#### Remove&#x20;

* Select an event attribute or an event
* Go to EDIT
* Could take action of Remove or Make a copy

*Note: Source can't be removed*

![](https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FS7m3638vTd8BcYkQtbz6%2Fimage.png?alt=media\&token=495e0738-4a56-48d4-b3ae-7930fa53261f)

#### Duplicate&#x20;

If demanding to create a new event attribute, event, or source from an existing one

* Hover over the selected existing one
* Click Duplicate icon ![](https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2F5cSRdRsF2q6PDAEdxsZa%2Fimage.png?alt=media\&token=b018094a-e021-4098-ac78-f47165c81145)
* Go to the settings
* Fill the name and the description.

#### Go to the assign setting

Click ![](https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2F6B32VWvAkeZy8RhDpcKC%2Fimage.png?alt=media\&token=2677a609-1a7e-4adf-9e6a-df599da8e33a) to view the final settings (detailed settings of assign) of an event attribute, an event, or a source.

### Event attributes

Click the name of the event to view the settings of the event attribute, and could edit the name and the description.&#x20;

<figure><img src="https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FC2aHDwzGdIwK2dmX2Lz2%2Fimage.png?alt=media&#x26;token=e417afd1-1e7d-4c83-b368-3e6c907401b3" alt=""><figcaption><p>Event attributes</p></figcaption></figure>

### Events

After choosing a specific event to view, you could see 2 tabs:

* Attribute: Showing the list of Event Attributes assigned to it. You are able to adjust this list by clicking the Assign button <img src="https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FZVxwuLABfoz6g77rkF1b%2Fimage.png?alt=media&#x26;token=be9700ac-4dc3-4103-9d7a-745d5661decb" alt="" data-size="line">

<figure><img src="https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2Fous9odwnHfK8jv6F8Srx%2Fimage.png?alt=media&#x26;token=3276ae10-cee1-44ef-a1a9-99abc3246209" alt=""><figcaption><p>Attribute tab</p></figcaption></figure>

* Setting: Showing the configuration of the event

<figure><img src="https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2F3WPrgOdzQYwSV12i8xrS%2Fimage.png?alt=media&#x26;token=8fc79d90-a2bd-4c22-b6cc-2bdd68d7ec2f" alt=""><figcaption><p>Setting</p></figcaption></figure>

### Sources

The details of a source include two tabs

* Events tab shows the traffic and the list of events the source has
* Setting tab shows the configuration of the source

#### Events tab

The tab includes 2 parts

* The chart shows traffic of the source in a set Time range
  * **Number Of Rejected:** number of events rejected
  * **Number Of Received:** number of events received&#x20;
* The list of events assigned in the source

<figure><img src="https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FqFaswhkk5UCtbKW0JcZc%2F2023-06-06_14-40-26.png?alt=media&#x26;token=a0d7ec66-8ae4-473d-8e17-96f8f0907f28" alt=""><figcaption><p>Events tab</p></figcaption></figure>

#### *List of events*

#### *Status*&#x20;

The status shows the ability of tracking data of an event

![](https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FdYwrHh8UVvopC3P6FVkx%2Fimage.png?alt=media\&token=dc2969ab-c243-4d8e-ae98-2c9c6df88b84)means the event doesn't track data

![](https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FN9k4bf0mOwJat6pLkhtL%2Fimage.png?alt=media\&token=9f930b12-36bd-4cac-9708-b66850149867) means the event is tracking data

#### *Name*

Hover over the name of an event ![](https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FEIX9ixGe3DB65wHTrdTA%2F2023-06-06_14-41-06.png?alt=media\&token=bfec3282-83bd-4243-9289-a7292a5f9834)

* Click the name to view [detailed traffic and event attributes of an event](#details-of-an-event-in-a-source)
* Click ![](https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FfNxnruGsLYTpxyGM6Fuz%2Fimage.png?alt=media\&token=75e67216-cee6-4d63-8171-1d6250014baf) to get the tracking script of event. Tracking script is a technical term that must be added to the source code for an event to start tracking data from the source.

#### *Details of an event in a source*

The details include 3 tabs

* **Event log**: Shows the traffic the event received or rejected

<figure><img src="https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FWQw8NE5JATH91o2qCUn6%2Fimage.png?alt=media&#x26;token=93d02c00-66c0-4761-9ed2-136c10665fcb" alt=""><figcaption><p>Event Log</p></figcaption></figure>

* **Event Attributes**: To point out the list of event attributes assigned to it and make any adjustment you want. By using the status toggle, these attributes could be enabled or disabled to track data.&#x20;

<figure><img src="https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FBBHpXHJ90HlIc2PMKuMG%2Fimage.png?alt=media&#x26;token=9094a4d3-3a51-40df-b4d6-a5eb2b65bd1d" alt=""><figcaption><p>Event Attributes</p></figcaption></figure>

* **Event Settings:** To optimize the performance of CDP 365 and better manage the data from events in a specific Event Source

<figure><img src="https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FjOHONSImNeVwvu7nLftO%2Fimage.png?alt=media&#x26;token=06805fbc-6efd-4968-9765-b3038ed8e0d8" alt=""><figcaption><p>Event Settings</p></figcaption></figure>

* *Priority Streaming:* To choose which event is prior to be recorded the data. If it's on, the event will be recorded realtime. And if not, there will be a certain delay (not too long) to record the event.
* *Used for product recommendation:* It allow users to determine whether the event data is used in recommending product&#x20;
* *Streaming to Customer Journeys:* Users are able to choose which events will be used in Customer Journeys. This option is only displayed in events assigned in the Event Sources of [Server type](#step-1-choose-source-type). For the Website & Application type, the events are automatically added in the Customer Journeys.
* *Record event data in Visitors/ Customers profiles:* Only the events having this option turned on could be display in Visitors/ Customers profiles

#### Setting tab

In the setting tab, not only the configuration of the source but also the tracking script (if the source is a website).&#x20;

The tracking script is a technical term that must be added to the source code to start tracking data from the domain.

<figure><img src="https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FzvvBl502SDAmHQCsBVqL%2Fimage.png?alt=media&#x26;token=f02b85a4-b323-476f-935c-4464b4ca0a18" alt=""><figcaption><p>Setting tab</p></figcaption></figure>

Here are the articles in this section:

{% content-ref url="broken-reference" %}
[Broken link](https://docs.antsomi.com/cdp-365-user-guide-en/data-hub/broken-reference)
{% endcontent-ref %}


---

# 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.antsomi.com/cdp-365-user-guide-en/data-hub/event-sources.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.
