Create, list, and push Baseten models. Authentication is via ‘baseten auth login’ or the BASETEN_API_KEY environment variable.Documentation Index
Fetch the complete documentation index at: https://docs.baseten.co/llms.txt
Use this file to discover all available pages before exploring further.
push
model_name field in config.yaml. Use —override-name to override that for this push only.
Options
Deployment timeout as a Go duration (e.g. 30m, 1h); allowed range 10m to 24h.
Human-readable name for the new deployment.
Model directory to push. Defaults to the current directory.
Disable archive download for the new model. Only valid for new models.
Validate the push and request upload credentials without uploading or creating anything.
Stable environment to push to. Mutually exclusive with —promote.
Filter JSON output with a jq expression; implies —output json (or jsonl for streamed commands)
User-provided labels for the deployment as a JSON object, e.g. ’{“team”:“ml”,“priority”:1}’.
Force a full rebuild without using cached layers.
Output formatOne of:
text, json, jsonl, noneUse this deployment’s instance type instead of preserving the target environment’s. Only meaningful when an environment is targeted.
Override the model_name from config.yaml for this push only. The on-disk config.yaml is not modified.
Promote the new deployment to the production environment.
Baseten remote URL, overrides BASETEN_REMOTE_URL (default https://app.baseten.co)
Stream build and runtime logs to stderr after pushing. Logs are always text-formatted; use ‘baseten model deployment logs —tail’ for structured log streaming.
Team the model belongs to. Only valid for new models.
Block until the deployment is active. Exits non-zero on a terminal-failure status.
Watch the model directory and push on change. (not yet implemented)
Hot-reload the running container on watched changes. (not yet implemented)
Keep the watcher alive after the deployment exits. (not yet implemented)
Enable verbose logging
Examples
Push the current directory as a new deploymentFilter output with --jq
Print the new deployment’s predict URL
Output
Text mode (--output text): Narrative summary on stdout: success banner, deployment status, log/predict URLs and example next-step commands. Under —output json the narrative is redirected to stderr so stdout stays a clean JSON document.
JSON mode (--output json): payload type cmd.ModelPushResult.
Under —dry-run no upload or deployment happens; the push is validated, upload credentials are requested, and stdout is the empty JSON object \{\}. Otherwise stdout is the full model+deployment result.
list
Options
Filter JSON output with a jq expression; implies —output json (or jsonl for streamed commands)
Output formatOne of:
text, json, jsonl, noneBaseten remote URL, overrides BASETEN_REMOTE_URL (default https://app.baseten.co)
Team name or ID to scope the listing to. Defaults to all teams the caller can see.
Enable verbose logging
Examples
List all models accessible to the callerFilter output with --jq
Print just the model IDs
Output
Text mode (--output text): Table with columns: ID, NAME, TEAM, DEPLOYMENTS, CREATED. When no models exist, prints “No models found.” to stderr.
JSON mode (--output json): payload type managementapi.Models.
fetch
Options
Filter JSON output with a jq expression; implies —output json (or jsonl for streamed commands)
ID of the model.Mutually exclusive with other flags in group
model-ref.Name of the model. Use —team to disambiguate when the same name exists in multiple teams.Mutually exclusive with other flags in group
model-ref.Output formatOne of:
text, json, jsonl, noneBaseten remote URL, overrides BASETEN_REMOTE_URL (default https://app.baseten.co)
Team name or ID. Only valid with —model-name.
Enable verbose logging
Examples
Fetch a model by IDFilter output with --jq
Print the production deployment ID
Output
Text mode (--output text): Field-per-line summary: ID, Name, Team, Deployments, Instance, Production, Development, Created. Optional fields are omitted when unset.
JSON mode (--output json): payload type managementapi.Model.
predict
Options
Inline JSON request body.Mutually exclusive with other flags in group
predict-input.Specific deployment to target. Mutually exclusive with —environment and —regional.
Environment to target (e.g. production, development). Defaults to production. Mutually exclusive with —deployment-id and —regional.
Path to a JSON file containing the request body. Use ’-’ for stdin.Mutually exclusive with other flags in group
predict-input.Filter JSON output with a jq expression; implies —output json (or jsonl for streamed commands)
ID of the model.Mutually exclusive with other flags in group
model-ref.Name of the model. Use —team to disambiguate when the same name exists in multiple teams.Mutually exclusive with other flags in group
model-ref.Output formatOne of:
text, json, jsonl, noneRegional environment name; routes via the regional hostname. Mutually exclusive with —environment and —deployment-id.
Baseten remote URL, overrides BASETEN_REMOTE_URL (default https://app.baseten.co)
Team name or ID. Only valid with —model-name.
Use the WebSocket predict endpoint. Sends the body as one frame, reads one frame back, then closes. Not for multi-message or back-and-forth sessions.
Enable verbose logging
Examples
Send an inline JSON bodyFilter output with --jq
Extract a field when the model returns JSON
Output
Text mode (--output text): The model’s response body, passed through verbatim. May be JSON, plain text, or binary, and may stream when the model uses chunked transfer encoding or SSE.
JSON mode (--output json): payload type cmd.JSONUndefined.
Under —output json, binary frames are base64-encoded under a ‘body’ key. Under —output jsonl, each SSE or binary chunk is emitted as its own record, one per line.
delete
Options
Filter JSON output with a jq expression; implies —output json (or jsonl for streamed commands)
ID of the model.Mutually exclusive with other flags in group
model-ref.Name of the model. Use —team to disambiguate when the same name exists in multiple teams.Mutually exclusive with other flags in group
model-ref.Output formatOne of:
text, json, jsonl, noneBaseten remote URL, overrides BASETEN_REMOTE_URL (default https://app.baseten.co)
Team name or ID. Only valid with —model-name.
Skip the interactive confirmation prompt. Required when stdin is not a terminal.
Enable verbose logging
Examples
Delete by ID without confirmationFilter output with --jq
Print the deleted model’s ID
Output
Text mode (--output text): On success, prints “Deleted model name (id)” to stderr; no stdout output.
JSON mode (--output json): payload type managementapi.ModelTombstone.