import type { BuiltAgent, BuiltTool, CredentialProvider } from '@n8n/agents'; import { Logger } from '@n8n/backend-common'; import type { JSONSchema7 } from 'json-schema'; import { type ExecuteAgentData, type ExecuteAgentWorkflowContext, type InlineAgentPayload } from 'n8n-workflow'; import { CredentialsService } from '../../credentials/credentials.service'; import type { AgentRunTelemetryType } from '../../interfaces'; import { Telemetry } from '../../telemetry'; import { AgentExecutionService } from './agent-execution.service'; import { AgentRunTracingService } from './agent-run-tracing.service'; import { AgentRuntimeReconstructionService } from './agent-runtime-reconstruction.service'; import type { Agent } from './entities/agent.entity'; import { AgentRepository } from './repositories/agent.repository'; export declare class AgentWorkflowExecutionService { private readonly logger; private readonly agentRepository; private readonly agentExecutionService; private readonly telemetry; private readonly credentialsService; private readonly agentRuntimeReconstructionService; private readonly agentRunTracingService; constructor(logger: Logger, agentRepository: AgentRepository, agentExecutionService: AgentExecutionService, telemetry: Telemetry, credentialsService: CredentialsService, agentRuntimeReconstructionService: AgentRuntimeReconstructionService, agentRunTracingService: AgentRunTracingService); private normalizeWorkflowStreamError; private applyPerCallAgentExtras; compileIsolated(agentEntity: Agent, credentialProvider: CredentialProvider, outputSchema?: JSONSchema7, extraTools?: BuiltTool[]): Promise<{ ok: boolean; agent?: BuiltAgent; error?: string; }>; private compileIsolatedFromSource; private buildWorkflowExtraTools; private streamWorkflowAgent; private buildWorkflowResult; executeForWorkflow(agentId: string, message: string, executionId: string, threadId: string, projectId: string, telemetryUserId?: string, useDraftVersion?: boolean, outputSchema?: JSONSchema7, workflowContext?: ExecuteAgentWorkflowContext): Promise; executeInlineForWorkflow(inlineAgent: InlineAgentPayload, message: string, executionId: string, threadId: string, projectId: string, telemetryUserId?: string, runType?: AgentRunTelemetryType, outputSchema?: JSONSchema7, workflowContext?: ExecuteAgentWorkflowContext): Promise; private validateInlineAgentConfig; }