# Legacy Sandbox Snapshot Template - Documentation

> For the complete documentation index, see [llms.txt](/llms.txt). Markdown is available with `Accept: text/markdown` and `.md` URL variants.

Source: /docs/guides/sandbox-legacy-commit

# Legacy Sandbox Snapshot Template

This legacy page is kept for users who still use the 1.x or beta SDK line. New SDK 2.x integrations should follow the current Sandbox documentation.

##

[​](#terminology)

Terminology

- Commit: A commit operation saves the current state of a sandbox as a template, resulting in a new template of type snapshot template.

- Origin Sandbox: The sandbox instance being committed.

- Snapshot Template: The template generated after a commit operation.

##

[​](#feature-description)

Feature Description

###

[​](#committing-a-running-sandbox)

Committing a Running Sandbox

During the commit process:

- The origin sandbox will be briefly suspended during committing;

- The sandbox instance is unavailable during suspension;

- The suspension duration is close to the time required for a single pause operation.

After committing is complete:
Origin Sandbox:

- The existing pause record will be refreshed to a new pause record, based on the current sandbox state;

- The origin sandbox continues to run;

- A new template record is generated.

###

[​](#committing-a-paused-sandbox)

Committing a Paused Sandbox

During the commit process:

- The commit process will not trigger the origin sandbox to start;

- The origin sandbox remains in paused state.

After committing is complete:
Origin Sandbox:

- The existing pause record is not cleared;

- A new template record is generated.

##

[​](#parameter-description)

Parameter Description

ParameterTypeRequiredDescription`sandbox_id``string`YesThe ID of the sandbox instance to commit`alias``string`NoSet an alias for the generated template

##

[​](#return-value)

Return Value

After a successful commit operation, a `Template` object is returned.

##

[​](#code-examples)

Code Examples

Python

TypeScript

```
from novita_sandbox.core import Sandbox

# Commit an existing sandbox by ID to create a template snapshot
# sandbox_id: str - Required. The ID of the sandbox to commit
# alias: Optional[str] - Optional alias name for the created template
# Note: Default timeout is 10 minutes for commit operation
template = Sandbox.commit(
sandbox_id="existing-sandbox-id",
alias="my-template-alias"
)
print(f"Template ID: {template.template_id}")
print(f"Build ID: {template.build_id}")
```

Additionally, you can also use the Novita Sandbox CLI to commit a specified sandbox instance:

Bash

```
# Basic commit - creates a template snapshot from a sandbox
novita-sandbox-cli sandbox commit

# Commit with alias - assign a friendly name to the template
novita-sandbox-cli sandbox commit --alias my-template-alias
```

Last modified on June 5, 2026
