# Segment-1: Based on who performed an event

## Segment Definition

{% hint style="info" %}
Customers who purchased twice or more in the last 7 days
{% endhint %}

Let's breakdown this into the different filters:

1. Filter-1: Who performed the event: Order Created
2. Filter-2: Number of times the event was performed: Twice or more
3. Filter-3: When the event was performed: In the last 7 days

***

{% stepper %}
{% step %}
**Step-1: Choose the event**

Here we will choose `Order Created` to create our segment.

<figure><img src="/files/c3dQI7We9hZDnTHZPqam" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}
**Step-2: Choose the number of times the event was performed**

Here we will choose `total`  `greater than equal to`  `2` , since we want people who purchased twice or more.

<figure><img src="/files/sIdCWQbOLxm0bQfsuMxP" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}
**Step-3: Choose the time range**

Here we will choose `since 7 days` since we want people who made their purchases in the last week.

<figure><img src="/files/gt6erOrNEMqgABIUyVrg" alt=""><figcaption></figcaption></figure>
{% endstep %}
{% endstepper %}

**At the end, give a name to your segment & then click on `Save` to save it.**

<figure><img src="/files/050bEzEzXxJQ0Q788DFq" alt=""><figcaption></figcaption></figure>


---

# 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://limechatai.gitbook.io/limechat-product-guide/whatsapp-marketing/segments/creating-a-segment/segment-1-based-on-who-performed-an-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.
