Logs Block
Query workflow execution logs
The Logs block lets you search and inspect workflow execution logs from inside a workflow. Use it to query logs across the workspace, fetch a single log entry by id, or load the full execution details with the per-block state snapshot.
Overview
| Property | Value |
|---|---|
| Type | logs |
| Category | blocks |
| Color | #EAB308 |
When to Use
- Search recent workflow runs in the workspace, filtered by level (info, error, running, pending).
- Build alerting or reporting flows that react to failed or long-running executions.
- Fetch a single log entry by id to enrich a downstream notification.
- Load full execution details, including the per-block state snapshot, for debugging or auditing.
- Filter logs by trigger type (api, webhook, schedule, manual, chat) or by a date range.
- Paginate through large result sets using the returned
nextCursor.
Configuration
Operation
Selects what the block does. Defaults to query.
| Label | ID |
|---|---|
| Query Logs | query |
| Get Log by ID | get_log |
| Get Execution Details | get_execution |
Workflow IDs
Visible when operation is query.
Comma-separated workflow IDs to scope the query to specific workflows. Leave blank to search across all workflows in the workspace.
Execution ID
Visible when operation is query.
Restrict query results to a single execution ID. To load full per-block state for an execution, use the get_execution operation instead.
Level
Visible when operation is query. Defaults to all.
Filter query results by execution status.
| Label | ID |
|---|---|
| All | all |
| Info | info |
| Error | error |
| Running | running |
| Pending | pending |
Triggers
Visible when operation is query.
Comma-separated trigger type filter, e.g. api,webhook,schedule,manual,chat.
Limit
Visible when operation is query.
Maximum number of results to return. Default 100, max 200.
Start Date
Visible when operation is query. Advanced field.
ISO 8601 timestamp. Only logs at or after this time are returned.
End Date
Visible when operation is query. Advanced field.
ISO 8601 timestamp. Only logs at or before this time are returned.
Search
Visible when operation is query. Advanced field.
Free-text search across log fields.
Sort By
Visible when operation is query. Advanced field. Defaults to date.
| Label | ID |
|---|---|
| Date | date |
| Duration | duration |
| Cost | cost |
| Status | status |
Sort Order
Visible when operation is query. Advanced field. Defaults to desc.
| Label | ID |
|---|---|
| Descending | desc |
| Ascending | asc |
Cursor
Visible when operation is query. Advanced field.
Opaque pagination cursor returned by a previous query response (nextCursor). Pass this value to retrieve the next page of results.
Log ID
Visible when operation is get_log. Required.
The id of the single log entry to fetch.
Execution ID (lookup)
Visible when operation is get_execution. Required.
The execution id whose full details and per-block state snapshot to load.
Inputs & Outputs
-
Inputs:
operation(string) — Operation to perform (query,get_log, orget_execution)workflowIds(string) — Comma-separated workflow IDsexecutionId(string) — Filter by execution ID (query operation)level(string) — Log level filter (all,info,error,running,pending)triggers(string) — Trigger type filterlimit(number) — Max results (default 100, max 200)startDate(string) — Start date filter (ISO 8601)endDate(string) — End date filter (ISO 8601)search(string) — Free-text searchsortBy(string) — Sort field (date,duration,cost,status)sortOrder(string) — Sort direction (ascordesc)cursor(string) — Pagination cursor from a previous responselogId(string) — Log entry ID (get_log operation)executionIdLookup(string) — Execution ID to look up (get_execution operation)
-
Outputs:
logs(json) — Log entries returned by a querytotal(number) — Total matching logsnextCursor(string) — Next pagination cursor; null when no more resultslog(json) — Single log entry (get_log operation)execution(json) — Execution details (get_execution operation)
Tools
Query Logs (logs_query) — Queries workflow execution logs in the current workspace with filters. Accepts workflowIds, executionId, level, triggers, limit, cursor, sortBy, sortOrder, startDate, endDate, and search. Returns an array of log entries and an optional nextCursor for pagination.
Get Log by ID (logs_get) — Fetches a single workflow execution log entry by its log ID. Requires the id param (mapped from the logId sub-block). Returns the log object.
Get Execution Details (logs_get_execution) — Fetches full execution details for a workflow run, including the per-block state snapshot. Requires the executionId param (mapped from the executionIdLookup sub-block). Returns executionId, workflowId, workflowState (per-block state snapshot), and executionMetadata (trigger, timestamps, totalDurationMs, and cost).
YAML Example
logs_1:
type: logs
name: "Logs"
inputs:
operation: "query"
level: "error"
triggers: "api,schedule"
limit: 50
startDate: "{{trigger.startDate}}"
connections:
outgoing:
- target: next-block-id