> For the complete documentation index, see [llms.txt](https://docs.cekat.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.cekat.ai/en/analytics/segmentation.md).

# Segmentation

Segmentation shows you who the customers behind your Analytics numbers are. Analytics answers “how many people started a chat on WhatsApp”. Segmentation answers “who are those people”. You pick the events customers have done, narrow them down by event details if needed, and Cekat.AI lists the matching customers.

Segments use the same event catalog as Analytics, so the numbers match your dashboards. Each customer is counted once, even if they match several events.

## Open Segmentation

Segmentation is available to businesses on the Analytics plan. Every user in your business can view, create, edit, duplicate, and delete segments.

1. In the top navigation, click Analytics.
2. In the left sidebar, click the Segmentation icon (two-person icon).

The Segmentation page lists every segment your business has saved.

<figure><img src="https://content.gitbook.com/content/zFvvakHJ5OVubOo4WKlR/blobs/OmypYkWDF6aeSNYEtWOL/Unknown%20image" alt="Figure 1. Click Analytics (1), then the Segmentation icon in the left sidebar (2)."><figcaption></figcaption></figure>

## Manage saved segments

### Switch views

At the top right of the list, choose card or table view.

* Cards show the segment name, the number of matching customers (users matched), and when it was created.
* Table shows the Title, Condition, User Match, Created, and Action columns. At the bottom, choose the rows per page in Showing, then click Prev or Next to move between pages.

<figure><img src="https://content.gitbook.com/content/zFvvakHJ5OVubOo4WKlR/blobs/VowVD0iKLsjrZ2MZqihF/Unknown%20image" alt="Figure 2. Switch between card and table view (1), set the rows per page (2), and move between pages (3)."><figcaption></figcaption></figure>

### Search and sort segments

* To find a segment, type its name in Search segments by name.
* To sort, click Most Recent, then choose Most Recent, Name A–Z, Name Z–A, Most Users, or Fewest Users.

<figure><img src="https://content.gitbook.com/content/zFvvakHJ5OVubOo4WKlR/blobs/RXE741XIALVC26pJQ5Cx/Unknown%20image" alt="Figure 3. Choose how segments are sorted from the Most Recent menu."><figcaption></figcaption></figure>

### Duplicate and delete segments

1. On a segment card, click the ⋯ icon. In table view, use the icons in the Action column.
2. Choose Duplicate to copy the segment as a starting point, or Delete to remove it.
3. If you chose Delete, click Delete Segment to confirm.

<figure><img src="https://content.gitbook.com/content/zFvvakHJ5OVubOo4WKlR/blobs/M8AF1HDaemiP9p4PGHKA/Unknown%20image" alt="Figure 4. Click the ⋯ icon (1), then choose Duplicate or Delete (2)."><figcaption></figcaption></figure>

A deleted segment can't be restored.

<figure><img src="https://content.gitbook.com/content/zFvvakHJ5OVubOo4WKlR/blobs/zYs8oehLYSBde1fv6bOJ/Unknown%20image" alt="Figure 5. Click Delete Segment to confirm. A deleted segment can&#x27;t be restored."><figcaption></figcaption></figure>

## Create a segment

1. On the Segmentation page, click New Segment.
2. The builder opens as Untitled Segment. To rename it, click the name, type a new one, then click the ✓ icon.

<figure><img src="https://content.gitbook.com/content/zFvvakHJ5OVubOo4WKlR/blobs/FTp9kJo8FsWEfGMzJgtH/Unknown%20image" alt="Figure 6. Click New Segment to open the builder."><figcaption></figcaption></figure>

<figure><img src="https://content.gitbook.com/content/zFvvakHJ5OVubOo4WKlR/blobs/ePVRQmWIpW5MLoPxb1tQ/Unknown%20image" alt="Figure 7. Click the segment name and type a new one (1), then click ✓ (2)."><figcaption></figcaption></figure>

The builder has two sides: Segment definition on the left, where you set the conditions, and the search results on the right.

### Choose events

1. In Segment definition, click Add Event.
2. In Choose an event, search by what the customer did, such as “whatsapp” or “order”. The search covers every category at once.
3. Click an event to see its details. The panel on the right shows the event's properties with sample values, such as Channel, Inbox, and Device Type.
4. Click Add Event.

<figure><img src="https://content.gitbook.com/content/zFvvakHJ5OVubOo4WKlR/blobs/LSFlMyEeOI5nAm3WOcAc/Unknown%20image" alt="Figure 8. A new builder starts empty. Click Add Event to choose your first event."><figcaption></figcaption></figure>

<figure><img src="https://content.gitbook.com/content/zFvvakHJ5OVubOo4WKlR/blobs/zVPpofBWr20SCToyEp0X/Unknown%20image" alt="Figure 9. Search for an event (1), or browse by category (2)."><figcaption></figcaption></figure>

<figure><img src="https://content.gitbook.com/content/zFvvakHJ5OVubOo4WKlR/blobs/smvwLKZCTK97Aq9D6aV1/Unknown%20image" alt="Figure 10. Click an event (1) to see its properties and sample values (2)."><figcaption></figcaption></figure>

<figure><img src="https://content.gitbook.com/content/zFvvakHJ5OVubOo4WKlR/blobs/erlQtDafjg5anwTvtHaD/Unknown%20image" alt="Figure 11. Click Add Event to add the event to the segment."><figcaption></figcaption></figure>

Events are grouped into the categories below. Your business's own custom events appear in the same list as the built-in events.

| Category  | Example events                                                                                                    |
| --------- | ----------------------------------------------------------------------------------------------------------------- |
| Chat      | Chat Started, Chat Resolved, Chat Rated, AI Agent Replied, Label Added, Ticket Created                            |
| Order     | Order Paid, Order Paid via Stripe                                                                                 |
| Website   | Page Viewed, Button Clicked, Form Submitted, WhatsApp Link Clicked, Visitor Matched to Contact                    |
| Marketing | Chat from Meta Ad, Chat from TikTok Ad, Website Visit from Ad, Conversion Sent to Meta, Conversion Sent to TikTok |
| Calls     | Call Booked, Call Rescheduled, Call Canceled, Call No-Show, Call Attended, Call Qualified                         |

A segment can have up to 10 events. The number in use appears in Events Used, for example “2/10 Events Used”.

To swap an event, click the ⇄ icon. To remove it, click the ✕ icon.

### Set the time range

Each event has its own time range, so you can build conditions like “paid in the last 90 days and chatted in the last 7 days”.

On the event card, click the time range picker, then choose one:

* in the last: a number of recent days, such as 30 days.
* all time: any time, covering all of your business's event history.
* between: between two dates. Fill in Start date and End date.

<figure><img src="https://content.gitbook.com/content/zFvvakHJ5OVubOo4WKlR/blobs/XPam8lZCc5rVE9gQ4zGB/Unknown%20image" alt="Figure 12. Choose in the last, all time, or between."><figcaption></figcaption></figure>

### Filter by event details (optional)

Use conditions to narrow an event down, for example only chats that came in through WhatsApp.

1. On the event card, click Add Condition.
2. In the first field, choose a property, such as Channel, Inbox, Device Type, or UTM Source.
3. In the second field, choose an operator:
   * Equals / Does not equal: matches / doesn't match one value.
   * Is any of / Is not any of: is / isn't one of several values.
   * Is empty / Is not empty: the property is blank / filled in.
4. In the third field, choose a value, such as whatsapp.

<figure><img src="https://content.gitbook.com/content/zFvvakHJ5OVubOo4WKlR/blobs/XiPsLq7EbhpKWw2q3HAK/Unknown%20image" alt="Figure 13. Click Add Condition to filter the event (1). The number of events used appears in Events Used (2)."><figcaption></figcaption></figure>

<figure><img src="https://content.gitbook.com/content/zFvvakHJ5OVubOo4WKlR/blobs/p4snZPAqjotHPYLuF7eg/Unknown%20image" alt="Figure 14. Choose a property (1), an operator (2), and a value (3). The red message (!) appears when a condition is incomplete."><figcaption></figcaption></figure>

<figure><img src="https://content.gitbook.com/content/zFvvakHJ5OVubOo4WKlR/blobs/0zsbZ9wUQznXOmHdESJ0/Unknown%20image" alt="Figure 15. The list of condition operators."><figcaption></figcaption></figure>

To add another condition to the same event, click Add Condition again, then choose AND or OR between the conditions. To remove a condition, click the trash icon.

If a condition is incomplete, you see “Event 1: Enter a valid value for the condition.” and Search stays disabled.

### Combine events with AND / OR

When a segment has two or more events, choose AND or OR between each event:

* AND: the customer did both events.
* OR: the customer did either event.

AND doesn't care about order. A customer matches as long as both events happened within their own time ranges. To look at the order of steps, use a Funnel in Analytics.

<figure><img src="https://content.gitbook.com/content/zFvvakHJ5OVubOo4WKlR/blobs/gs5PLXZNMCKmA2wCodmY/Unknown%20image" alt="Figure 16. Choose AND/OR between conditions (1) and between events (2)."><figcaption></figcaption></figure>

## Run the search and save the segment

1. Once your events and conditions are set, click Search.
2. Check the number of matching customers in Total Users Matching.
3. When the result looks right, click Save Segment.

<figure><img src="https://content.gitbook.com/content/zFvvakHJ5OVubOo4WKlR/blobs/f3y8keMAIct4SktQGv8y/Unknown%20image" alt="Figure 17. Click Search (1), check Total Users Matching (2), and open View all users (3)."><figcaption></figcaption></figure>

<figure><img src="https://content.gitbook.com/content/zFvvakHJ5OVubOo4WKlR/blobs/V84c1hYBBwUFhP3GBu1z/Unknown%20image" alt="Figure 18. When the result looks right, click Save Segment."><figcaption></figcaption></figure>

Keep in mind:

* The search only runs when you click Search.
* If you close the builder before saving, Unsaved Changes appears. Click Keep Editing to go back, or Discard & Leave to leave without saving.

<figure><img src="https://content.gitbook.com/content/zFvvakHJ5OVubOo4WKlR/blobs/hlKxbe4MWLU542N6xCYr/Unknown%20image" alt="Figure 19. Click Keep Editing to go back (1), or Discard &#x26; Leave to leave without saving (2)."><figcaption></figcaption></figure>

## View matching customers

### Matching users preview

After a search, Matching users preview shows the first 10 customers. Each row has Name, Phone, Email, Last Active, and Status. Scroll the table sideways to see the other columns.

### All matching users

1. Click View all users.
2. All matching users lists every customer in the segment, 25 per page.
3. To find a customer, type their name, email, or phone number in the search field. This search only covers the page you're on.
4. Click Prev or Next to move between pages.

To go back to the builder, click the ← icon at the top left.

<figure><img src="https://content.gitbook.com/content/zFvvakHJ5OVubOo4WKlR/blobs/h7GZNmXKMjFXQO2zdBEV/Unknown%20image" alt="Figure 20. Go back to the builder (1), search customers on this page (2), and move between pages (3)."><figcaption></figcaption></figure>

## Open a saved segment

Click a segment's card or title to open it. A saved segment is a frozen audience: its customer list is saved as a snapshot when you click Save Segment, and it isn't updated automatically.

<figure><img src="https://content.gitbook.com/content/zFvvakHJ5OVubOo4WKlR/blobs/IAgJSnJwHkP572zv4X55/Unknown%20image" alt="Figure 21. A saved segment is a frozen audience: its customer list was saved as a snapshot."><figcaption></figcaption></figure>

## Examples

* Customers who chatted on WhatsApp or Telegram: Chat Started in the last 30 days, with the condition Channel Equals whatsapp OR Channel Equals telegram.
* Customers who chatted and paid: Chat Started AND Order Paid via Stripe, both in the last 30 days.
* Customers who left a rating: Chat Rated in the last 7 days, for your support team to follow up.
* Customers from Meta ads: Chat from Meta Ad in the last 30 days.
