Read app logs
tzcloud_read_logsRead your application's logs for one environment.
container is stdout/stderr. app is logging-package output. router keeps 5xx responses whole within its cap. tzcloud_read_status has failed paths in server_errors. all or no source merges stored sources and console by time. Recognized level, or field, filter, contains or until, excludes console from that read.
container gives invalid_request for local or serverless applications. Read pool for functions' console lines and failures, or omit source. On a server's container read, a recognized level or nonempty field gives invalid_request. It ignores until. It gives lines without entries. Waits need since. Without compute, kept failed-check lines can answer. An in-flight version, or an upload to a deploy target with no history, gives deploy_in_flight. Otherwise no compute gives never_deployed. Store reads with no version and nothing serving give never_deployed. local needs no deploy.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"application": "<application>"
},
"name": "tzcloud_read_logs"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| field | No | Structured field matched with `value`. Without `value`, any entry with the field. For a response's `x-request-id`, use `request_id` here, its header as `value`, and no `source`. This finds stored records, not console lines. | |
| level | No | Store minimum: `debug`, `info`, `warn` or `error`. A recognized level gives `invalid_request` for `container` and excludes console lines from an all-source read. Other values are ignored. | |
| limit | No | Newest entries retained, from 1 to 1000; default 100. | |
| since | No | Inclusive timestamp with a time zone: `YYYY-MM-DDTHH:mm[:ss[.fraction]]`, then `Z` or `±HH:mm`. Fraction has 1–9 digits, T/Z ignore case. Malformed gives `invalid_request`. Default open, except 24 hours back for a container environment's console. | |
| until | No | Inclusive end, with `since` syntax and validation. Default open. | |
| value | No | JSON-typed equality with `field`, including null. Omitted matches any entry with the field. | |
| filter | No | Connections to hosts declared or undeclared in the manifest's `egress` at the read. Naming `source` selects its page: `egress` reads the proxy's records, `harness` connections made without the proxy. With no source, the returned page may hold neither. | |
| source | No | `container`: server stdout/stderr; serverless: `pool`. `app`: logging package. `egress`: outbound proxy. `harness`: runtime harness. `pool`: functions. `platform`, `router`. `all`/absent merges by time; `level` when recognized, or `field`, `filter`, `contains` or `until`, excludes console lines. | |
| contains | No | Message text. On `container`, case-insensitive over the newest 1000 lines, with indented continuation lines, before `limit`. | |
| application | Yes | Your account's application `id` from `tzcloud_list_applications`, not its name or label. | |
| environment | No | Default production. `local` needs no deploy. Store reads with no version and nothing serving give `never_deployed`. Without compute, `container` may return kept failed-check lines or refuse `deploy_in_flight` or `never_deployed`; read the detail. `container` with `local` gives `invalid_request`. | |
| wait_seconds | No | Wait for an entry, with `since`. For `container`, the console is followed for at most 40 seconds. Out of range gives `invalid_request`. |