n8n_get_execution
Retrieve detailed execution information including status, timestamps, workflow data, and node outputs using an execution ID.
Instructions
Get detailed information about a specific execution.
Args:
id (string): Execution ID
includeData (boolean): Include full execution data with node outputs (default: true)
Returns: Complete execution details including:
Status and mode
Timestamps (started, stopped)
Workflow data
Node execution results (if includeData is true)
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | Execution ID | |
| includeData | No | Include full execution data |
Implementation Reference
- src/tools/executions.ts:99-142 (handler)The tool 'n8n_get_execution' is registered and implemented here. It retrieves detailed execution information from the n8n API using the provided execution ID and includeData flag.
server.registerTool( 'n8n_get_execution', { title: 'Get n8n Execution', description: `Get detailed information about a specific execution. Args: - id (string): Execution ID - includeData (boolean): Include full execution data with node outputs (default: true) Returns: Complete execution details including: - Status and mode - Timestamps (started, stopped) - Workflow data - Node execution results (if includeData is true)`, inputSchema: GetExecutionSchema, annotations: { readOnlyHint: true, destructiveHint: false, idempotentHint: true, openWorldHint: false } }, async (params: z.infer<typeof GetExecutionSchema>) => { const execution = await get<N8nExecution>(`/executions/${params.id}`, { includeData: params.includeData }); let text = formatExecution(execution); if (execution.data?.resultData?.error) { text += `\n\n**Error:**\n\`\`\`\n${JSON.stringify(execution.data.resultData.error, null, 2)}\n\`\`\``; } if (execution.data?.resultData?.lastNodeExecuted) { text += `\n\n- Last Node: ${execution.data.resultData.lastNodeExecuted}`; } return { content: [{ type: 'text', text }], structuredContent: execution }; }