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

# Commit Template

> Commit a template from draft to live

Commit a template's current draft version, making it live immediately. All notifications triggered after the commit will use the new content across all channel variants.

This is the CLI equivalent of clicking **Commit** in the template editor on the dashboard.

The template slug is passed as a positional argument, not a flag.

## Syntax

```bash theme={"system"}
suprsend template commit <slug> [flags]
```

## Arguments

| Argument | Description                                     |
| -------- | ----------------------------------------------- |
| `<slug>` | The slug of the template to commit *(required)* |

## Flags

| Flag                          | Description                                   | Default |
| ----------------------------- | --------------------------------------------- | ------- |
| `-h, --help`                  | Show help for the command                     | –       |
| `-m, --commit-message string` | Message describing the changes in this commit | –       |
| `-f, --force`                 | Force commit by skipping variants with errors | –       |

## Example

```bash theme={"system"}
# Commit a template in the staging workspace
suprsend template commit order-shipped

# Commit with a message
suprsend template commit order-shipped --commit-message "Fix Hindi variant subject line"

# Commit in production
suprsend template commit order-shipped --workspace production

# Commit in production, skipping variants with errors
suprsend template commit order-shipped --workspace production --force
```

## End-to-End Example

```bash theme={"system"}
# 1. Pull the current live version to local files
suprsend template pull --slug order-shipped

# 2. Edit the local template file
#    (update variant content, conditions, mock data, etc.)

# 3. Push the edited file as a draft
suprsend template push --slug order-shipped

# 4. Commit the draft to make it live
suprsend template commit order-shipped --commit-message "Add Hindi variant"
```

Or collapse push and commit into one step:

```bash theme={"system"}
suprsend template push --slug order-shipped --commit --commit-message "Add Hindi variant"
```

<Warning>
  Using `--force` skips validation on variants that have errors and commits the rest. Variants with errors remain in draft. Use with caution in production environments.
</Warning>
