# Scheduled tasks

Scheduled tasks let you tell Olly to run a saved prompt automatically on a schedule. Each run produces its own chat and lands in the task's run history. Use scheduled tasks for recurring observability work — a daily error summary, a weekly capacity check, a one-off run timed to a release — without having to remember to open Olly and type the prompt yourself.

## What you need

- Olly turned on for your team. See [Enable Olly](https://coralogix.com/docs/user-guides/olly/enable/index.md).
- Each scheduled task belongs to the user who created it. Other team members don't see your tasks and can't manage them.

## Open scheduled tasks

In Coralogix, navigate to **Settings**, then under **Olly AI** select **Scheduled tasks**.

The page lists every scheduled task you've created as a card. Each card shows the task name, a badge marking it as **One-off** or **Recurring**, and an **Active** toggle. Use the search bar to filter by name, or select **New scheduled task** to create one.

## Create a scheduled task

1. On the Scheduled tasks page, select **New scheduled task**.
1. In the **Details** section, fill in:
   - **Name**: short identifier shown on the card and in run history (for example, `Daily error summary`).
   - **Prompt**: the instruction Olly runs on each execution. Write it the same way you phrase it in chat — for example, *Summarize the top error categories in the payment service over the last 24 hours and graph them*.
   - **Model**: the Olly model used for each run. The list matches the models available in Olly chat — see [Model selection](https://coralogix.com/docs/user-guides/olly/model-selection/index.md).
1. In the **Schedule** section, set:
   - **Recurrence**: pick one of the four options — **One-off** (runs once), **Hourly**, **Daily**, or **Weekly**.
   - **Run at** (One-off) or **Start time** (recurring): when the run fires. The time must be in the future and **no later than 1 week from now**.
   - **Active**: leave on to start the task immediately, or turn off to save it paused.
1. Select **Create**.

The new task appears on the Scheduled tasks page. If it's active and the start time has passed, Olly runs it at the next scheduled time.

## Manage a scheduled task

Open a task to see its details, run it on demand, or change it. From the Scheduled tasks page, select a card to open the task detail page. From the kebab menu on a card you can also select **Open**, **Edit**, **Run now**, or **Delete** without opening the detail page.

### Pause or activate a task

The badge next to the task name shows the current state — **Active** (green) or **Paused** (grey). To switch states:

- On the Scheduled tasks page, use the **Active** toggle on the card.
- On the detail page, select **Edit** and switch the **Active** toggle.

A paused task stays in the list but doesn't run on its schedule. Activating it again resumes runs at the next scheduled time.

### Run a task now

Select **Run now** on the detail page, or pick **Run now** from the card's kebab menu. The run starts immediately and appears in the task's run history. Running on demand doesn't change the task's next scheduled run.

### Edit a task

Select **Edit** to open the task in the same dialog used to create it. You can change the name, prompt, model, recurrence, interval, start time, and active state. Changes apply to subsequent runs. Chats from past runs stay unchanged.

### Delete a task

Select **Delete** from the detail page or the card's kebab menu, then confirm in the dialog. Olly stops the task and removes it from your list. **Chats from past runs of the task stay** in your chat history — only the task itself goes away. Deletion can't be undone.

## See run history

The detail page's **Run history** section lists every run of the task, most recent first. Each entry shows:

- A status badge — **Pending**, **Running**, **Succeeded**, or **Failed**.
- The time the run started.
- A **View chat** link to open the chat Olly produced for that run.

If a run is in progress, the entry stays in **Pending** or **Running** until it completes. A **Failed** entry means the run didn't complete — hover the badge to see why. Common reasons are that the team's **AI units quota** was exceeded, that **AI-Powered Capabilities** was turned off for the account before the run fired, or that the run timed out. Some failures happen before the agent produces a chat, so a Failed entry might have no **View chat** link.

## Limits

- **Scheduled tasks per user**: up to 20. If you reach the limit, delete a task you no longer need before creating a new one.
- **Start time**: must be in the future and no later than 1 week from when you save the task.
- **Visibility**: a scheduled task is private to the user who created it. Team API keys aren't supported.

## Next steps

Browse the tabular outputs Olly returns from your scheduled runs in [Dynamic tables](https://coralogix.com/docs/user-guides/olly/dynamic-tables/index.md).
