Skip to main content
Fetches logs for a deployed model. Use this command to debug issues or monitor model behavior in production.

Options

TEXT
Name of the remote in .trussrc.
TEXT
ID of the model.
TEXT
ID of the deployment.
Tail for ongoing logs. Streams new log entries as they arrive.
DATETIME
Start of the log time range (ISO 8601). No-timezone values are local. Defaults to a short look-back ending at —end. Window must be <= 7 days.
DATETIME
End of the log time range (ISO 8601). No-timezone values are local. Defaults to now. Window must be <= 7 days.
TEXT
Logs from a relative time ago until now, written as a number plus a unit of s, m, h, or d (for example 90s, 2h, or 3d). Max 7d. Cannot be combined with --start or --end.
debug | info | warning | error
Minimum log severity. Defaults to all lines. Any value returns lines at or above that severity and drops lines with no level.
TEXT
Case-sensitive substring that must appear in the message (repeatable).
TEXT
Case-sensitive substring that drops any line containing it (repeatable).
TEXT
RE2 regex matched against the message. Prefer —includes/—excludes.
TEXT
Only return logs emitted by this replica (5-char short ID).
TEXT
Only return logs tagged with this inference request ID.
humanfriendly | W | WARNING | I | INFO | D | DEBUG
default:"humanfriendly"
Logging verbosity. humanfriendly (default) is pretty-printed; INFO, DEBUG, WARNING produce structured logs.
Disable interactive prompts. Use in CI/automated contexts where stdin isn’t a TTY.
Example: Fetch logs for a specific deployment:
Stream logs in real-time:
Fetch logs from the last two hours:
Fetch logs for a specific time window:
Filter logs to errors only:

Rate limits

Baseten limits the deployment logs endpoint (POST /v1/models/{model_id}/deployments/{deployment_id}/logs) to 30 requests/second per API key. Interactive use, including --tail, stays well under that limit. Scripts that wrap truss model-logs in a tight poll loop can hit the limit and receive 429 Too Many Requests. Wait for the response’s retry_after value (in seconds) before retrying. For the full response shape and a retry example, see management API rate limits.