# Codespace scheduling

> Codespace scheduling - Learn about the options available for codespace scheduling.

This Markdown file sits beside the HTML page at the same path (with a `.md` suffix). It summarizes the topic and lists links for tools and LLM context.

Companion generated at `2026-10-09T14:05:25.085613+00:00` (UTC).

## Primary page

- [Codespace scheduling](https://docs.datarobot.com/en/docs/workbench/notebook/codespaces/schedule-cs.html.md): Full documentation for this topic (Markdown sidecar).

## Sections on this page

- [Create a notebook job](https://docs.datarobot.com/en/docs/workbench/notebook/codespaces/schedule-cs.html.md#create-a-notebook-job): In-page section heading.
- [Notebook parameterization](https://docs.datarobot.com/en/docs/workbench/notebook/codespaces/schedule-cs.html.md#notebook-parameterization): In-page section heading.
- [Manage notebook job definitions](https://docs.datarobot.com/en/docs/workbench/notebook/codespaces/schedule-cs.html.md#manage-notebook-job-definitions): In-page section heading.
- [Single Use Case jobs](https://docs.datarobot.com/en/docs/workbench/notebook/codespaces/schedule-cs.html.md#single-use-case-jobs): In-page section heading.
- [All Use Case jobs](https://docs.datarobot.com/en/docs/workbench/notebook/codespaces/schedule-cs.html.md#all-use-case-jobs): In-page section heading.
- [Monitor run history](https://docs.datarobot.com/en/docs/workbench/notebook/codespaces/schedule-cs.html.md#monitor-run-history): In-page section heading.
- [Notifications](https://docs.datarobot.com/en/docs/workbench/notebook/codespaces/schedule-cs.html.md#notifications): In-page section heading.
- [Notebook scheduling considerations](https://docs.datarobot.com/en/docs/workbench/notebook/codespaces/schedule-cs.html.md#notebook-scheduling-considerations): In-page section heading.
- [Next steps](https://docs.datarobot.com/en/docs/workbench/notebook/codespaces/schedule-cs.html.md#next-steps): In-page section heading.

## Related documentation

- [NextGen UI documentation](https://docs.datarobot.com/en/docs/workbench/index.html.md): Linked from this page.
- [DataRobot Notebooks](https://docs.datarobot.com/en/docs/workbench/notebook/index.html.md): Linked from this page.
- [Codespaces](https://docs.datarobot.com/en/docs/workbench/notebook/codespaces/index.html.md): Linked from this page.
- [environment variables](https://docs.datarobot.com/en/docs/workbench/notebook/codespaces/session-cs.html.md#codespace-environment-variables): Linked from this page.
- [DataRobot’s notification system](https://docs.datarobot.com/en/docs/platform/admin/webhooks/index.html.md): Linked from this page.
- [Convert notebooks to codespaces](https://docs.datarobot.com/en/docs/workbench/notebook/codespaces/convert-cs.html.md): Linked from this page.

## Documentation content

With the codespace scheduling capability, you can automate your code-based workflows by scheduling notebooks to run on a schedule in non-interactive mode.

See the associated [considerations](https://docs.datarobot.com/en/docs/workbench/notebook/codespaces/schedule-cs.html.md#notebook-scheduling-considerations) for important additional information.

## Create a notebook job

Notebook scheduling is managed by notebook jobs. To create a notebook job:

1. Open the notebook that you want to configure for scheduling.
2. Choose theNotebook jobstile in the left sidebar and clickCreate notebook job.

1. Complete the fields in the Create job modal.

| Field name | Description |
| --- | --- |
| Job name | Enter the name of the notebook job that you are creating. |
| Run mode | Set the run schedule for the notebook. Run on a schedule: Creates a time-based schedule in an enabled state. Disabled schedule: Allows you to create a time-based schedule for the notebook but not enable it. Run now: Runs the notebook immediately. This setting is useful for performing a test run of the notebook before automating the notebook scheduled run, or if you want to run the notebook asynchronously and track the run history. |
| Schedule type | Choose between a simple schedule or a cron schedule. Simple schedule: Set the frequency and a time to run the notebook.Cron schedule: Configures the exact time and date for the notebook to run, specifying the minute, hour, date, month, and day of the week. |
| Frequency | Set the rate at which you want to notebook to run (hour, day, week, month, quarter, year). |
| Time | Specify the time at which the notebook will run on the schedule. Select Cron schedule for more precise scheduling options. |
| Parameters | Define parameters in the notebook to automatically provide their values at the time of the scheduled run instead of manually changing each value. Choose to add parameters as single entries or import them in bulk. |

When you have fully configured the notebook job, click Create. Once you’ve created the scheduled notebook job, DataRobot shuts down the codespace session (unless you’ve created the job in a disabled state). A codespace cannot be started in an interactive session while it has an enabled schedule on it in order to prevent unexpected behavior and filesystem conflicts. The newly created notebook job can be viewed from the Notebook jobs tab. When a notebook job runs, the results (cell outputs) are displayed in the notebook.

### Notebook parameterization

You can parameterize a notebook to enhance the automation experience enabled by notebook scheduling. Defining certain values in a codespace as parameters provides inputs for those parameters when a notebook job runs. This replaces the need to continuously modify the notebook itself to change the values for each run. DataRobot supports parameterization for both scheduled notebook jobs and manual “Run now” notebook jobs in a codespace.

To parameterize values in a notebook, you must define the parameters as codespace [environment variables](https://docs.datarobot.com/en/docs/workbench/notebook/codespaces/session-cs.html.md#codespace-environment-variables). The value of the environment variable will serve as the default value of the parameter.

Once defined, you can use this parameter in code by retrieving the corresponding environment variable, as shown below.

When a notebook job is executed, the session's environment variables will first be set according to codespace's environment variables; any parameters defined for the job will be set at the notebook kernel level and override the corresponding codespace environment variable's default value. Note that these runtime parameter values do not replace the codespace environment variables' stored values.

When adding parameters, you can add each one-by-one by adding key-value pairs, or define them in bulk. For bulk import, specify a new-line delimited key value pairs in the text field. Use the following format on each line in the field:

`KEY=VALUE # DESCRIPTION`

## Manage notebook job definitions

Job definitions can be accessed for a specific Use Case, a notebook or codespace within a Use Case, or across all Use Cases. Access to jobs is dependent on which you want to view.

### Single Use Case jobs

Scheduled notebook job definitions for a selected Use Case are available for management from either a:

**Use Case:**
Open a Use Case, choose the Notebooks & codespaces tile (1), select the Job definitions tab (2), and click the Actions menu next to a job (3).

[https://docs.datarobot.com/en/docs/images/nb-sched-uc.png](https://docs.datarobot.com/en/docs/images/nb-sched-uc.png)

**Notebook or codespace:**
Open a Use Case and choose the Notebooks & codespaces tile.

Select the
Notebooks & codespaces
* tab.
Select a notebook or codespace.
Select the
Notebook jobs
or
Codespace jobs
tile.
Click the
Actions menu
:fontawesome-solid-ellipsis-vertical.

[https://docs.datarobot.com/en/docs/images/nb-sched-3.png](https://docs.datarobot.com/en/docs/images/nb-sched-3.png)


### All Use Case jobs

To view notebook jobs configured across all Use Cases, from Workbench select the Notebooks & codespaces tile and then the Job definitions tab:

### Monitor run history

DataRobot tracks the history and metadata (start time, end time, duration, and status) of each automated run of a scheduled notebook and each manual run of a notebook triggered by the Run now action. To view the run history, navigate to the Run history tab from either:

- Workbench > Notebooks & codespaces > Run history .
- From within a Use Case, Notebooks & codespaces > Run history .
- From within a notebooks or codespace, Notebook jobs > action menu > View run history .

In the notebook listing, from the Actions menu you can download run results or open the notebook.

Each notebook run has a corresponding notebook revision, which is a snapshot of the notebook (and cell outputs) that DataRobot automatically collects at the end of each notebook job run. This allows you to go back and view the run results of previous notebook runs, even if the current version of the notebook has changed. The notebook revision is displayed in the Run results column in the Run history table. Click on a run in the table to open the notebook revision for that corresponding run.

### Notifications

You can configure notifications for scheduled jobs to receive alerts on specific events. Notifications for scheduled notebook jobs are off by default. To set up notifications, leverage [DataRobot’s notification system](https://docs.datarobot.com/en/docs/platform/admin/webhooks/index.html.md) to first create a notification channel for delivering notifications. DataRobot supports webhook, email, Slack, and Microsoft Teams channels. Then, create a notification channel for your alert conditions. You can either create a policy for the event group, “Notebook-Schedule-related-events”, or for a single event. Events for notebook jobs include “Notebook Schedule Completed”, “Notebook Schedule Created”, and “Notebook Schedule Failure”.

An administrator is required to configure notification channels and policies, but notifications can be received by all subscribers. For more information on configuring notifications for scheduled jobs, see the [Notification service](https://docs.datarobot.com/en/docs/platform/admin/webhooks/index.html.md) documentation.

### Notebook scheduling considerations

Review the following considerations before working with notebook scheduling:

- Codespaces are limited to five active schedules. Additionally, each notebook can only have one active schedule at a time. Therefore, you can have up to five active schedules for five notebooks at a time in one codespace. If you do want to create another scheduled notebook job, you will need to disable an existing schedule from another notebook.
- You cannot start a codespace in an interactive session if the codespace has an enabled scheduled job. In order to edit or execute your codespace in an interactive session, you will need to disable any enabled scheduled notebook job.
- The smallest frequency you can specify for a schedule is hourly.
- The max number of notebook jobs that can be executed in parallel is set at the organization level and defaults to two. This is a separate limit from the max number of interactive notebook sessions you can have running in parallel.
- The max run time for a notebook job to execute is currently 24 hours. After that notebook execution limit is reached, the job will be terminated.
- Getting input from the user fromstdin(such as when debuggers are used or other input prompts) is disabled when a codespace is in a scheduled job (or is non-interactively executed). This prevents the codespace from blocking indefinitely while waiting for interactive user input and allows the codespace job to execute to completion.

## Next steps

After scheduling a codespace job, review how sessions behave when not running on a schedule or explore converting other notebooks to take advantage of scheduling.

- Codespace sessions : Start and manage an interactive codespace session, including file management and Git integration.
- Convert notebooks to codespaces : Convert a standalone notebook into a codespace to unlock scheduling and other codespace-only capabilities.
- Add a codespace : Create a new codespace or upload files and Git repositories to establish one.
