> ## Documentation Index
> Fetch the complete documentation index at: https://docs.wisdom.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Schedule Eval Set

The `scheduleEvalSet` mutation sets a recurring cron schedule for an evaluation set. It requires the `evaluation:schedule` permission, and the `evaluation:lock` permission if the set is locked.

## Signature

```graphql theme={null}
scheduleEvalSet(
  domainId: ID!
  evalSetId: ID!
  cronExpression: String
  cronTimezone: String
  chatMode: ChatMode
): EvalSet!
```

| Argument | Type | Description |
| :- | :- | :- |
| `domainId` | `ID!` | The domain that contains the evaluation set. |
| `evalSetId` | `ID!` | The evaluation set to schedule. |
| `cronExpression` | `String` | The cron expression of the schedule. You must pass it. Pass `null` to clear the schedule. |
| `cronTimezone` | `String` | The time zone of the cron expression. |
| `chatMode` | `ChatMode` | The chat mode that scheduled runs use. Defaults to `FAST`. |

Returns the updated [EvalSet](https://docs.wisdom.ai/integrations/graphql-api/objects/evaluation-data-types.md#evalset), including `cronExpression`, `cronTimezone`, and `scheduledRunChatMode`.

## Example

This example runs an evaluation set every Monday at 06:00.

```graphql theme={null}
mutation ScheduleEvalSet($domainId: ID!, $evalSetId: ID!, $cronExpression: String, $cronTimezone: String) {
  scheduleEvalSet(
    domainId: $domainId
    evalSetId: $evalSetId
    cronExpression: $cronExpression
    cronTimezone: $cronTimezone
  ) {
    id
    cronExpression
    cronTimezone
    scheduledRunChatMode
  }
}
```

```json Variables theme={null}
{
  "domainId": "domain_987654321",
  "evalSetId": "eval_set_123",
  "cronExpression": "0 6 * * 1",
  "cronTimezone": "America/New_York"
}
```

```json Response theme={null}
{
  "data": {
    "scheduleEvalSet": {
      "id": "eval_set_123",
      "cronExpression": "0 6 * * 1",
      "cronTimezone": "America/New_York",
      "scheduledRunChatMode": "FAST"
    }
  }
}
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.