n8n
Version:
n8n Workflow Automation Tool
7 lines (6 loc) • 499 B
TypeScript
import type { AgentPersistedMessageDto } from '@n8n/api-types';
import type { AgentExecution } from '../entities/agent-execution.entity';
type ExecutionTranscript = Pick<AgentExecution, 'id' | 'userMessage' | 'assistantResponse' | 'toolCalls' | 'timeline' | 'error'>;
export declare function executionToMessagesDto(execution: ExecutionTranscript): AgentPersistedMessageDto[];
export declare function executionsToMessagesDto(executions: ExecutionTranscript[]): AgentPersistedMessageDto[];
export {};