> For the complete documentation index, see [llms.txt](https://help.openloyalty.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.openloyalty.io/campaigns/campaigns/automation-campaigns/creating-automations.md).

# Creating Automations

In this article, you will learn how to create automation campaigns.

Automation campaigns in Open Loyalty allow you to automatically reward members based on scheduled triggers - daily, weekly, monthly, birthdays, or membership anniversaries.

## 🛠️ Step-by-Step Setup

Go to **Campaigns › Automation** and click **Add automation campaign** (or use the ▼ to **Import** an existing automation configuration). The form has six sections:

{% stepper %}
{% step %}

### Trigger

Select when the automation campaign runs:

* **Daily** – runs every day
* **Weekly** – runs every week, on the days you select
* **Monthly** – runs every month, on the schedule you set
* **Member's birthday** – runs once a year, on each member's birthday
* **Membership anniversary** – runs once a year, on each member's registration date

<figure><img src="https://2658975168-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FcNVX03KZzmrGwJihLiEx%2Fuploads%2Fgit-blob-fc0df752e8a962d0ce0dc5ab587e6f536e12cfde%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure>

{% hint style="danger" %}
Automation campaigns run just after 00:00, according to the configured tenant timezone.
{% endhint %}
{% endstep %}

{% step %}

### Basic settings

* **Name and description** – choose a distinctive campaign name and optionally add a description. If you added another language in the settings, use **Add translation**.
* **Start and end date** – the start date is required; the end date is optional but must be after the start date.

<figure><img src="https://2658975168-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FcNVX03KZzmrGwJihLiEx%2Fuploads%2Fgit-blob-975cc0cb083ca185c6e6e4ef053fb101ad96933a%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure>

* **Target** – who the campaign applies to: **Everyone**, a **Segment** or a **Tier**. Who actually qualifies depends on the conditions in **Rules**.
* **Visibility** – who sees the campaign.
* **Display order** (optional) – where the campaign appears in the list; lower numbers show first.

<figure><img src="https://2658975168-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FcNVX03KZzmrGwJihLiEx%2Fuploads%2Fgit-blob-e525132f359475f57b68533172f43ee931ba9349%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure>

{% hint style="warning" %}
**Campaign visibility** only determines to whom the campaign is presented. If you want to target a given audience, the condition must be specified in the rules.

* **Visibility** - displaying the campaign, e.g. for a given segment or tier
* **Conditions** - being able to earn points, e.g. for a given segment or tier
  {% endhint %}
  {% endstep %}

{% step %}

### Rules

Rules decide who qualifies for the campaign and what they get. You can add more than one.

* Click **Create rule** (or **Add new rule** for the next ones).

<figure><img src="https://2658975168-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FcNVX03KZzmrGwJihLiEx%2Fuploads%2Fgit-blob-27bc402cd7be49105b616302ab17d08fa2cb0024%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure>

* **Conditions** – click **Add condition** and pick one from **Popular conditions** or **Member details** — for example membership tier, custom attributes, or **Days since registration** (see [below](#rewarding-members-for-time-in-the-program)).
* **Effects** – click **Add effect**, e.g. add units (10 points), issue a coupon, or deduct units.

<figure><img src="https://2658975168-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FcNVX03KZzmrGwJihLiEx%2Fuploads%2Fgit-blob-84bee451ce1d0abb97d6e49fd54c821330d3c0c4%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}

### Custom attributes

Optionally define **custom attributes** (key:value pairs) to store extra campaign details that the standard fields don't cover, e.g. to tag or filter the automation campaign in the API and the UI. Click **Create attribute**.

<figure><img src="https://2658975168-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FcNVX03KZzmrGwJihLiEx%2Fuploads%2Fgit-blob-7adc43d80c4411681f09700a605664d54811dddd%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}

### Limits and budget

Control how often a member can receive the automation campaign's reward:

* **Campaign limit** – **Completions per member**: how many times each member can complete this campaign (in total or per period).
* **Campaign budget** – total units issued, and a per-member units cap.

<figure><img src="https://2658975168-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FcNVX03KZzmrGwJihLiEx%2Fuploads%2Fgit-blob-0e7b6a0abb36d6a87b92b0c9cb1cd1d38ade0a17%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}

### Campaign status

The campaign only runs while its status is **Active**. Switch it on, then click **Create campaign**.

<figure><img src="https://2658975168-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FcNVX03KZzmrGwJihLiEx%2Fuploads%2Fgit-blob-e9f4a5493031056700428a0a4fe7d2474ed39141%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
Only **active** automation campaigns count towards your tenant's limit of automation campaigns, and the limit is checked when you activate one. Inactive automation campaigns don't count.
{% endhint %}
{% endstep %}
{% endstepper %}

***

## 🎂 Rewarding members for time in the program

The **Days since registration** condition rewards members when their time in the program reaches a specific number of days — for example onboarding milestones (30, 60 or 90 days) or membership anniversaries (365 or 730 days).

{% stepper %}
{% step %}

### Choose the Daily trigger

The condition is available only for automation campaigns with the **Daily** trigger.
{% endstep %}

{% step %}

### Add the condition

In a rule, click **Add condition**, open **Member details** and choose **Days since registration**. Type a whole number of days between **0** and **7305** (20 years). The only operator is *equals*.
{% endstep %}

{% step %}

### Choose the effect

Choose the reward, e.g. add points. To reward each tier differently, add a separate rule per tier with the tier condition.
{% endstep %}

{% step %}

### Limit it to once per member

Set **Completions per member** to 1, so a member can't receive the milestone twice.
{% endstep %}
{% endstepper %}

**How it works**

* Tenure is counted in full calendar days between the member's registration date and the day of the run, in the tenant's timezone; the hour of registration doesn't matter. `0` is the day of registration.
* A member qualifies **only on the day** their tenure equals the number you set.
* **Forward-only:** members who passed the milestone before the campaign was activated are not rewarded retroactively.
* Running the same day again doesn't create a second reward.
* There is no months/years selector: one year is 365 days, two years 730. Because of leap years, 365 days can be one day off the calendar anniversary for some registration dates.

{% hint style="warning" %}

* The condition isn't available for Weekly, Monthly, Member's birthday or Membership anniversary triggers, nor for other campaign types. If you change a campaign's trigger away from **Daily**, the condition is removed from its rules.
* Avoid editing a tenure campaign while its nightly run is in progress — part of the audience could be processed with the old configuration and part with the new one.
* [Campaign simulation](/campaigns/campaigns/campaign-simulation.md) doesn't support automation campaigns, so the condition can't be previewed there.
  {% endhint %}

***

## ✅ Best Practices

* Prefer longer-term triggers for special events (birthday, anniversary)
* Use **Target** for the audience and rule conditions for eligibility
* Scale gradually - fine-tune limits and budgets as you assess performance

***

## 🔍 Troubleshooting Tips

* **No effect?**\
  Check campaign status, scheduling, and rule conditions
* **Zero units issued?**\
  Review your per-member limits and global budget caps
* **Birthday/anniversary misfires?**\
  Validate member data - missing or future dates won’t trigger at 00:00
* **Tenure reward missing for a member?**\
  The member qualifies only on the exact day; members who passed the milestone before activation aren't rewarded


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

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

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://help.openloyalty.io/campaigns/campaigns/automation-campaigns/creating-automations.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
