import { ExternalTaskState } from '../ExternalTask/ExternalTask'; import { FlowNodeInstance } from './FlowNodeInstance'; export type ServiceTaskInstance = FlowNodeInstance & { /** * If the Service Task is an External Service Task, this will contain information about the corresponding External Task. */ externalTaskData?: ExternalTaskData; /** * If the Service Task is an Http Service Task, this will contain information about the corresponding Http request. */ httpServiceTaskData?: HttpServiceTaskData; }; export type ExternalTaskData = { externalTaskId: string; topic: string; state: ExternalTaskState; isSingleTry: boolean; payload: any; workerId?: string; lockExpirationTime?: Date; result?: any; error?: any; finishedAt?: Date; }; export type HttpServiceTaskData = { url: string; method: string; body?: any; headers?: Array>; };