> For the complete documentation index, see [llms.txt](https://docs.octoxlabs.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.octoxlabs.com/documentation/use-octoxlabs/reports/schedule-a-report.md).

# Schedule a Report

Run a report automatically every week, every few weeks or once a month, and email the file to recipients.

A scheduled report is a normal report that OctoXLabs generates again at a set time. Each run builds a new file from the latest finished discovery and, if you set recipients, emails it.

### Before you begin

* You need permission to add reports and report schedules. Editing a schedule needs the change report schedule permission and deleting one needs the delete report schedule permission.
* Configure SMTP first. Scheduled reports are delivered by email, and OctoXLabs sends the mail through the SMTP server saved in settings.
* Create the saved queries the report uses. See Create and Save Queries.

### Create a schedule

{% stepper %}
{% step %}

#### Switch on the schedule

Open **Reports** > **Report Builder**. In the **Define** step, enter the **Report Name**, **Export Type** and **Report Template**, then turn on **Schedule**. The schedule fields appear below the switch.
{% endstep %}

{% step %}

#### Choose when it runs

Select a **Frequency**:

| Frequency                       | Fields                                                                    | Result                                                                                        |
| ------------------------------- | ------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------- |
| **Weekly**                      | **Days** (one or more days), **Start Time**                               | Runs on each selected day at the start time.                                                  |
| **Every X weeks**               | **Every X Week(s)** (1 to 52, default 2), **Day of Week**, **Start Time** | Runs every N weeks on one weekday. The first run is the next occurrence of that day and time. |
| **First weekday of each month** | **Day of Week**, **Start Time**                                           | Runs on the first selected weekday of each month, for example the first Monday.               |

A preview line under the fields confirms the choice, for example "Every Monday and Thursday at 08:00". Days are Sunday to Saturday.
{% endstep %}

{% step %}

#### Pick the data and recipients

Select **Next** and choose the inventory and saved queries in the **Builder** step. The **Discovery Date** field is not shown for scheduled reports: every run uses the latest discovery at that time. Select **Next**, set **Subject**, **Recipients** and **CC** in the **Configure** step, then select **Create**.

You see the confirmations **Report created** and **Report schedule created**. The schedule starts enabled.
{% endstep %}
{% endstepper %}

{% hint style="info" %}
The first file is built when you create the report, like any other report. The schedule then produces later files.
{% endhint %}

### Manage schedules

Open **Reports** > **Schedules**. The list has a **Search** box and these columns:

| Column                          | Meaning                                                                  |
| ------------------------------- | ------------------------------------------------------------------------ |
| **Report Name**                 | The report that runs.                                                    |
| **Template**                    | The report template.                                                     |
| **Query Names**, **Dashboards** | The sources of the report.                                               |
| **Type**                        | **Weekly**, "Every N week(s)" or **First weekday of each month**.        |
| **Schedule**                    | The readable schedule, for example "Every 2 week(s) on Monday at 08:00". |
| **Enabled**                     | A switch that pauses or resumes the schedule.                            |

Use the row actions to edit or delete a schedule. In the editor ("Edit Schedule") you can change the report name, description, queries, dashboards (PDF), columns (**OctoXLabs** template), the schedule, and the **Subject**, **Recipients** and **CC** of the mail. You cannot change the export type, template or inventory; create a new report for that. The **Reports** list also gives you the edit icon on scheduled rows, and the duplicate icon copies the report together with its schedule.

Deleting a report deletes its schedule. To remove only the schedule, delete it from **Schedules**.

### How the email is sent

After a run finishes, OctoXLabs emails the file to **Recipients** and **CC** with the subject " is Ready" and the report description as the body. If the queries return no rows and the report has no dashboards, no file is attached and the subject ends with "(Skipped)". A mail failure is logged and does not mark the report as failed.

### Verify the result

The schedule appears in **Schedules** with the **Enabled** switch on, and at the next run a new entry appears in **Reports** > **Reports** and the recipients receive the mail.

### What's next?

<table data-view="cards"><thead><tr><th></th><th></th><th data-hidden data-card-target data-type="content-ref"></th></tr></thead><tbody><tr><td><strong>SMTP</strong></td><td>Configure the mail server used for report delivery.</td><td></td></tr><tr><td><strong>Generate a Report</strong></td><td>The full Report Builder walkthrough.</td><td></td></tr><tr><td><strong>Report Types</strong></td><td>Choose the right template.</td><td></td></tr></tbody></table>
