Install the Together CLI
Requires Python 3.10+.
The [cli] extra target includes additional dependencies used by the CLI exclusively. The extra target prevents the Python SDK from being bloated with dependencies it does not use.
Update the CLI
Authenticate
The CLI relies on theTOGETHER_API_KEY environment variable being set to your account’s API token to authenticate requests. You can find your API token in your account settings.
To create an environment variable in the current shell, run:
Shell
Use the CLI in a CI/CD Environment
uvx is a helper utility from uv that downloads and runs a Python binary without a separate install step. In a CI/CD environment, invoke the CLI directly with uvx:
Available Commands
models
View Together models and upload your own.
endpoints
Manage your models on your own custom endpoints for improved reliability at scale.
files
Upload and manage datasets for use in fine-tuning, evals, and batch inference.
fine-tuning
Fine tune custom models.
evals
Manage model evaluation jobs.
clusters (beta)
Reserve, manage, and interact with gpu clusters.
jig (beta)
Build, deploy and manage dedicated containers.
Global parameters
The following parameters are available on every command:| Flag | Description |
|---|---|
--help | Print help docs for the prefixed command. |
--json | Forces the command into returning json response. Useful for scripting. |
--non-interactive | Disables any prompting and manual input. In CI/Agent runners this is disabled by default. |
--api-key [string] | Your Together API key. Defaults to reading environment variable TOGETHER_API_KEY. |
--timeout [number] | Request timeout, defaults to 5 seconds. |
--max-retries [number] | Maximum number of HTTP retries. |
--version | Print CLI version. |
--debug | Turns on debug mode to log diagnostic information. |