---
search:
  tags:
    - Observability
    - GET
seo:
  description: >-
    What the Logs tab shows: the app's last stored output grouped into…
    Reference for the GET /v1/apps/{project}/invocations endpoint in the
    Sproutboat Cloud API.
sidebar:
  label: Recent runs of a running app, one per request
  badge: GET
title: Recent runs of a running app, one per request
type: openapi-operation
---
What the Logs tab shows: the app's last stored output grouped into **invocations**, newest first. One invocation is one run of a handler:
a request (`handler: fetch`), a cron run (`scheduled`), a queue or alarm delivery or other background wake-up (`trigger`), or output no run claimed
(`system`: a line printed with no request after it, a worker that stopped). The Logs tab shows `scheduled` runs by default and hides `trigger` ones.
The control plane stores none of it: the lines come from the app's host (`retention` in the answer).

Field names follow OpenTelemetry's semantic conventions where they map: `attributes` carry `http.request.method`, `url.path`, `url.scheme`,
`server.address`, `http.response.status_code` and `faas.trigger` (`http`, `timer` or `other`; a cron run has no HTTP attributes), each exception
`exception.type`, `exception.message` and `exception.stacktrace`, each console line `severity_number` and `severity_text`. `trace_id`, `span_id`
and `faas.invocation_id` will appear when the runtime tags lines with a request id; they are absent today.

**Console lines are matched to a request by order** (`logs_matched_by: order`): the host records no request id on a line, so the lines seen since the
previous run are attached to the next one. When requests overlap, a line can land under the wrong one.

A host from logs step 2 on stamps every stored line with the time it read it and reports each request's **CPU time** (`cpu_ms`) and a cron run's
expression (`attributes["faas.cron"]`). A host before that records none: `time` is `null`, `cpu_ms` is `null` and a cron run has no `faas.cron`, and the
answer is otherwise the same. The host still records no **level** (`severity_number` is 0 on a console line; a stack trace has frames only if the
runtime printed them).

**Time range.** `from` and `to` keep the runs that finished in that range (epoch milliseconds or an ISO 8601 date-time with a zone; `to` is optional).
On a host with the time window the range is read from the host in full, newest first, up to 10,000 lines or about 10 MiB in all (`window.windowed` true; `window.truncated` says when the range holds more and older runs are left out). On a host from before it, the range is cut from the host's last `lines` stored lines (1000 at most), so a busy app's old runs may lie beyond it: `window.truncated` says so. A run with no
time (a line an older host stored) cannot be placed in a range and is left out of it (`window.untimed` counts them); on a host that records no times
(`window.times` false) a range therefore answers an empty list. `window` says what the answer covers.

Removed before an invocation is returned, exactly as in `GET /v1/apps/{project}/logs`: the query string, the `http://` scheme (shown `https://`),
and every secret value of 8 characters or more (also URL-encoded, JSON-escaped, base64 and hex), replaced by `[redacted]`. A message over 16 KiB is cut.

`GET /v1/apps/{project}/invocations`
