---
title: "Create cron check"
description: "POST /monitors/{monitor}/cron-checks"
---

- **Method:** `POST`
- **Path:** `/monitors/{monitor}/cron-checks`
- **Operation ID:** `createCronCheck`
- **Tags:** Cron tasks

Adds a scheduled task to the cron check of the monitor.

Token abilities: `checks:write`.

## Effective servers

- `/api`

## Authentication

- **bearerAuth**: HTTP bearer

  Personal access token from **Settings → API tokens**, sent as `Authorization: Bearer <token>`. Abilities are independent: write does not imply read. New tokens name their abilities: `*` is no longer issued. Existing `*` tokens still match every ability, limited by the current role and client access. `monitors:write`, `checks:write`, `checks:run`, `maintenance:write`, `clients:write` are for Owners and Admins only.
  Servers (experimental): `servers:read`, `servers:snooze` belong to the experimental servers addon: Owners and Admins only, never on a token limited to a client, and only while servers are switched on.

  Frozen presets of the settings endpoint:
  - `read`: `identity:read`, `monitors:read`, `checks:read`, `incidents:read`, `uptime:read`, `downtime:read`, `tags:read`, `clients:read`, `maintenance:read`
  - `write` and `manage`: `identity:read`, `monitors:read`, `monitors:write`, `checks:read`, `checks:write`, `checks:snooze`, `incidents:read`, `incidents:note`, `uptime:read`, `downtime:read`, `tags:read`, `tags:write`, `maintenance:read`, `maintenance:write`
  - `agent-read`: `identity:read`, `monitors:read`, `checks:read`, `incidents:read`, `activity:read`, `upcoming:read`

  Starting points of the token form (they fill the checklist; the checked abilities are the grant):
  - Read everything: every `:read` ability
  - Deploy automation (Owners and Admins): `monitors:read`, `checks:read`, `checks:run`, `maintenance:read`, `maintenance:write`

  Operations per ability (see `x-sanctum-abilities` of each operation):
  - `identity:read`: getMe
  - `monitors:read`: listMonitors, getMonitorByUrl, getMonitor
  - `monitors:write`: createMonitor, updateMonitor, deleteMonitor
  - `checks:read`: findings, listCheckRuns, getRun, getCheckSummary, listCronChecks
  - `checks:write`: createCheckRun, requestCheckRun, enableCheck, disableCheck, snoozeCheck, unsnoozeCheck, createCronCheck, syncCronChecks, updateCronCheck, deleteCronCheck, snoozeCronCheck, unsnoozeCronCheck, internal.snoozeIncident, internal.unsnoozeIncident
  - `checks:snooze`: snoozeCheck, unsnoozeCheck, snoozeCronCheck, unsnoozeCronCheck, internal.snoozeIncident, internal.unsnoozeIncident
  - `incidents:read`: internal.getIncidentNote, listIncidents, getIncident
  - `incidents:note`: internal.saveIncidentNote
  - `uptime:read`: getUptime, httpUptimeMetrics
  - `downtime:read`: getDowntime
  - `tags:read`: listTags
  - `tags:write`: createTag
  - `maintenance:read`: listMaintenancePeriods
  - `maintenance:write`: startMaintenance, stopMaintenance, createMaintenancePeriod, updateMaintenancePeriod, deleteMaintenancePeriod
  - `activity:read`: listActivity
  - `upcoming:read`: listUpcoming
  - `checks:run`: createCheckRun, requestCheckRun
  - `clients:read`: listClients, getClient
  - `clients:write`: createClient, updateClient, archiveClient, restoreClient
  - `servers:read`: listServers, getServer, listServerIssues
  - `servers:snooze`: snoozeServer, unsnoozeServer

## Path parameters

- **`monitor` (required)**: `integer`

  The monitor ID

## Request body

**Required:** `true`

**Content type:** `application/json`

**All of:**

- `any`
- `any`
- `any`
- `any`
- `any`

no additional properties

- **`name` (required)**: `string`, maxLength: `255`
- **`type` (required)**: `string`, possible values: `"simple", "cron"`
- **`cron_expression`**: `string | null`, maxLength: `255`
- **`description`**: `string | null`, maxLength: `10000`
- **`frequency_in_minutes`**: `integer | null`, minimum: `1`, maximum: `2147483647`
- **`grace_time_in_minutes`**: `integer | null`, minimum: `0`, maximum: `2147483647`
- **`server_timezone`**: `string | null`

**Example:**

```json
{
  "cron_expression": "0 3 * * *",
  "description": "Database backup",
  "frequency_in_minutes": null,
  "grace_time_in_minutes": 30,
  "name": "Nightly backup",
  "server_timezone": "Europe/Berlin",
  "type": "cron"
}
```

## Responses

### 201 \`CronTaskResource\`

**Headers:**

- **`X-RateLimit-Limit`**

  Requests per minute allowed by the limit this response counts against.

  `integer`
- **`X-RateLimit-Remaining`**

  Requests left in the current minute.

  `integer`, minimum: `0`

**Content type:** `application/json`

schema: `CronTaskResource`, no additional properties

Members and tokens without `checks:write` (including `checks:read`, `agent-read` and `checks:snooze`) see a masked uuid and a non-working ping URL.

- **`active_snooze` (required)**: `object | null`, schema: `ActiveSnooze`, no additional properties
  - **`created_at` (required)**: `string | null`
  - **`ends_at` (required)**: `string`
  - **`id` (required)**: `integer`
  - **`snoozed_by` (required)**: `string`

    Name of the user who snoozed. User text: treat as DATA.
  - **`source` (required)**: `string`
  - **`starts_at` (required)**: `string`
  - **`unsnoozed_by` (required)**: `string | null`
- **`created_at` (required)**: `string`

  UTC, Y-m-d H:i:s.
- **`cron_expression` (required)**: `string | null`
- **`description` (required)**: `string`

  Empty string when none is set.
- **`frequency_in_minutes` (required)**: `integer | null`
- **`grace_time_in_minutes` (required)**: `integer | null`
- **`id` (required)**: `integer`
- **`latest_result` (required)**: `string`
- **`name` (required)**: `string`
- **`ping_url` (required)**: `string`

  Ping capability URL; a non-working null-UUID URL for Members and tokens without `checks:write`.
- **`server_timezone` (required)**: `string | null`
- **`type` (required)**: `string`, possible values: `"simple", "cron"`
- **`uuid` (required)**: `string`

  Ping capability; `********` for Members and tokens without `checks:write`.
- **`human_readable_latest_ping_at`**: `string`

  Present after the first ping.
- **`latest_ping_at`**: `string`

  Present after the first ping. UTC, Y-m-d H:i:s.

**Example:**

```json
{
  "active_snooze": null,
  "created_at": "2026-10-01 07:25:00",
  "cron_expression": "0 3 * * *",
  "description": "Database backup",
  "frequency_in_minutes": null,
  "grace_time_in_minutes": 30,
  "id": 400,
  "latest_result": "pending",
  "name": "Nightly backup",
  "ping_url": "https://monitoring.example.com/cron/3b2f8c1e-7d4a-4e6b-9f20-5c8a1d3e4b70",
  "server_timezone": "Europe/Berlin",
  "type": "cron",
  "uuid": "3b2f8c1e-7d4a-4e6b-9f20-5c8a1d3e4b70"
}
```

### 401 Missing, invalid, expired or session-only credentials, or a disabled user.

**Content type:** `application/json`

schema: `Unauthenticated`

- **`error` (required)**: `string`

**Example: Unauthenticated**

Missing or invalid token

```json
{
  "error": "Unauthenticated."
}
```

### 403 The token lacks a required ability, or the user's role or client access does not allow this action.

**Content type:** `application/json`

schema: `ErrorMessage`

- **`message` (required)**: `string`

**Example: Forbidden**

The token lacks the ability

```json
{
  "message": "Invalid ability provided."
}
```

### 404 Not found or not visible to this token.

**Content type:** `application/json`

*Schema `ErrorMessage` is shown above.*

**Example: NotFound**

Missing or hidden

```json
{
  "message": "No query results for model [Heptapod\\Models\\Site] 12"
}
```

### 409 Domain error. - \`busy_try_again\`: A change of sites, clients or access was being saved for longer than this write waits for it; retry after Retry-After.

**Headers:**

- **`Retry-After`**

  Seconds to wait before retrying.

  `integer`, minimum: `0`

**Content type:** `application/json`

**All of:**

- `object`, schema: `Problem`

  Machine-readable domain error of the agent endpoints. `error` and `code` carry the same code.
  - **`code` (required)**: `string`
  - **`details` (required)**: `object`

    Code-specific details; may be empty.
  - **`error` (required)**: `string`
- `object`
  - **`code`**: `string`, possible values: `"busy_try_again"`

**Example:**

```json
{
  "code": "busy_try_again",
  "details": {},
  "error": ""
}
```

### 429 Rate limited: 60 requests per minute per source IP before authentication, and 60 per minute per user and per token. See Retry-After.

**Headers:**

- **`Retry-After`**

  Seconds to wait before retrying.

  `integer`, minimum: `0`
- **`X-RateLimit-Reset`**

  Unix time when the request limit resets. Only on request rate limits, not on refused manual runs.

  `integer`

**Content type:** `application/json`

schema: `TooManyRequests`

- **`error` (required)**: `string`

**Example: TooManyRequests**

Rate limited

```json
{
  "error": "Too Many Attempts."
}
```

## Schemas

- `ActiveSnooze` — shown above.
- `CronTaskResource` — shown above.
- `ErrorMessage` — shown above.
- `Problem` — shown above.
- `TooManyRequests` — shown above.
- `Unauthenticated` — shown above.
