> ## 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.

# Push Category

> Use the suprsend category push CLI command to upload local preference categories and translation files to your workspace, with optional commit control.

Upload local preference categories and translations to a workspace. Reads `categories.json` and `translations/<locale>.json` files from the input directory. By default, categories are staged as drafts; translation files are applied immediately, whether or not `--commit` is set.

Pass `--commit` to also promote the changes to live after pushing, or commit later using the [`category commit`](https://docs.suprsend.com/reference/cli-category-commit) command to make them live.

## Syntax

```bash theme={"system"}
suprsend category push [flags]
```

## Flags

| Flag | Description | Default |
| - | - | - |
| `-h, --help` | Show help for the command | – |
| `-c, --commit` | Promote changes from draft to live after pushing | `false` |
| `--commit-message string` | Message describing the changes being committed | – |
| `-d, --dir string` | Directory containing category files | `./suprsend/preference_categories/` |
| `-j, --json string` | Categories (and optional translations) as a JSON object | – |
| `-n, --dry-run` | Print what would be pushed without making any changes | – |
| `-F, --force` | Skip confirmation prompt when `--commit` is set | – |

## Example

```bash theme={"system"}
# Push categories from default directory
suprsend category push

# Push categories from custom directory
suprsend category push --dir categories

# Push categories to production workspace
suprsend category push --workspace production

# Push categories and commit them with a message
suprsend category push --commit --commit-message "Update notification preferences"

# Push categories inline via JSON
suprsend category push --json '{"categories":{"root_categories":[...]}}'

# Push categories with translations inline
suprsend category push --json '{"categories":{"root_categories":[...]},"translations":{"es":{"sections":{},"categories":{}}}}'
```

***

### Frequently Asked Questions

> [accordion] I have pushed my categories but don’t see the updated categories in live mode.
>
> You can view detailed logs by enabling debug mode `export DEBUG=true` in your terminal.
> In most cases, this happens when an existing preference category is being overridden by the latest push and that category is already linked to a workflow. When this occurs, the changes cannot be committed to **live mode**.
>
> The updated categories will still appear in **draft** mode, but you’ll need to update or unlink the workflows before committing the changes live.


## Related topics

- [User Preferences](https://docs.suprsend.com/docs/user-preferences.md)
- [CI/CD with the SuprSend CLI](https://docs.suprsend.com/reference/cli-ci-cd.md)
- [Commit Category](https://docs.suprsend.com/reference/cli-category-commit.md)
- [Push Preference Translation](https://docs.suprsend.com/reference/cli-category-translation-push.md)
- [Android Push](https://docs.suprsend.com/docs/android-push-template.md)


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