Logs

Search logs with structured filters and full text search

Changed on
post/logs/search

Request

  • Base URL: /api (relative, and the document was published on a file host, not at the API’s origin)
  • URL: /api/logs/search
  • Auth: HTTP bearer

Request body

container_idsstring[]

Filter to specific containers (Docker container IDs). Empty = all containers. Drives "filter by container / show all" in a project's history, which spans multiple deployments and containers.

context_linesinteger nullable

grep -C: number of raw context lines to include before and after each match (0 = none, default). Clamped to 50 server-side. The surrounding lines ignore the level/text filters — they are the actual adjacent log lines, merged across overlapping matches.

cursorstring nullable

Pagination cursor

deploy_idinteger nullable

Filter by deployment ID (deployments.id)

end_timestring nullable

End of time range (ISO 8601). Defaults to now.

envsstring[]

Filter by environments

external_service_idinteger nullable

When set, search an imported/managed external service's logs instead of a project's. project_id is ignored in this mode.

levelsstring[]

Filter by log levels

node_idsinteger[]

Filter to specific worker nodes (node_id). Empty = all nodes, including control-plane-local logs.

page_sizeinteger nullable

Page size (default: 100, max: 500)

project_idinteger required

Project ID (integer, as used by the rest of the platform)

servicesstring[]

Filter by services

start_timestring nullable

Start of time range (ISO 8601). Defaults to 1 hour ago.

textstring nullable

Full text search query

Response

Search results

next_cursorstring nullable

Opaque keyset cursor for the next (older) page. Stays populated on a partial page — that's the whole point: the user can press Next to keep searching.

partialboolean

true when the store's time/byte budget ran out before this page could be proven complete.

scanned_back_tostring nullable

Set when partial is true: every chunk ending after this timestamp has been searched, nothing older has yet.

Changes

    • breaking

      removed the required property // from the response with the status

    • breaking

      removed the required property ///////// from the response with the status

    • breaking

      removed the required property ///////// from the response with the status

    • breaking

      removed the required property // from the response with the status

    • breaking

      removed the required property from the response with the status

    • breaking

      removed the required property from the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the required property ///////// to the response with the status

    • info

      added the required property ///////// to the response with the status

    • info

      added the required property // to the response with the status

    • info

      added the required property // to the response with the status

    • breaking

      removed the required property ///////// from the response with the status

    • breaking

      removed the required property ///////// from the response with the status

    • breaking

      removed the required property // from the response with the status

    • breaking

      removed the required property // from the response with the status

    • warning

      removed the optional property from the response with the status

    • warning

      removed the optional property from the response with the status

    • warning

      removed the optional property from the response with the status

    • warning

      removed the optional property from the response with the status

    • warning

      removed the optional property from the response with the status

    • info

      added the required property // to the response with the status

    • info

      added the required property ///////// to the response with the status

    • info

      added the required property ///////// to the response with the status

    • info

      added the required property // to the response with the status

    • info

      added the required property to the response with the status

    • info

      added the required property to the response with the status