import { BpmnType, EventType } from '../../ProcessModel/index'; /** * @swagger * components: * schemas: * FlowNodeInstanceList: * description: A list of FlowNodeInstances. * type: object * required: * - flowNodeInstances * - totalCount * properties: * flowNodeInstances: * description: The FlowNodeInstances. * type: array * items: * $ref: '#/components/schemas/FlowNodeInstance' * totalCount: * description: The total number of FlowNodeInstances. * type: number */ export type FlowNodeInstanceList = { flowNodeInstances: Array; totalCount: number; }; /** * @swagger * components: * schemas: * FlowNodeInstance: * description: A FlowNodeInstance. * type: object * required: * - flowNodeInstanceId * - flowNodeId * - flowNodeType * - state * - processDefinitionId * - processModelId * - processInstanceId * - correlationId * - startToken * - ownerId * properties: * flowNodeInstanceId: * description: The ID of the FlowNodeInstance * type: string * flowNodeId: * description: The ID of the FlowNode * type: string * flowNodeName: * description: The name of the FlowNode * type: string * flowNodeLane: * description: The name of the FlowNode's lane that contains this FlowNodeInstance * type: string * flowNodeType: * description: The BPMN type of the FlowNode * $ref: '#/components/schemas/BpmnType' * eventType: * description: The type of the Event, if this FlowNodeInstance is an Event * $ref: '#/components/schemas/EventType' * previousFlowNodeInstanceId: * description: The ID of the FlowNodeInstance that was executed before this one * type: string * parentProcessInstanceId: * description: The ID of the parent ProcessInstance, if this FlowNodeInstance within is a sub process * type: string * state: * description: The state of the FlowNodeInstance * $ref: '#/components/schemas/FlowNodeInstanceState' * processDefinitionId: * description: The ID of the ProcessDefinition that contains this FlowNodeInstance * type: string * processModelId: * description: The ID of the ProcessModel that contains this FlowNodeInstance * type: string * embeddedProcessModelId: * description: The ID of the SubProcess that contains this FlowNodeInstance * type: string * processModelName: * description: The Name of the ProcessModel that contains this FlowNodeInstance * type: string * processInstanceId: * description: The ID of the ProcessInstance that contains this FlowNodeInstance * type: string * correlationId: * description: The ID of the Correlation that contains this FlowNodeInstance * type: string * startToken: * description: The token with which the Flow Node Instance started * type: Record * endToken: * description: The token with which the Flow Node Instance finished * type: Record * ownerId: * description: The ID of the user that owns this FlowNodeInstance * type: string * error: * description: The error that occured during execution of the FlowNodeInstance (if any) * type: object * startedAt: * description: The date when the FlowNodeInstance was started * type: string * finishedAt: * description: The date when the FlowNodeInstance was finished * type: string * triggeredByFlowNodeInstance: * description: The FlowNodeInstance that triggered this FlowNodeInstance (if any) * $ref: '#/components/schemas/FlowNodeInstance' */ export type FlowNodeInstance = { /** * The instance ID of this FlowNodeInstance. */ flowNodeInstanceId: string; /** * The unique ID of the FlowNode, as it is modelled in the diagram. */ flowNodeId: string; /** * Optional: The name of the FlowNode, as it is modelled in the diagram. */ flowNodeName?: string; /** * Optional: The lane that this FlowNodeInstance belongs to. * The lane also serves as the IAM claim the user needs to have, in order to access this FlowNodeInstance. */ flowNodeLane?: string; /** * Describes the BPMN type of the FlowNode that this instance is executing. */ flowNodeType: BpmnType; /** * Optional: If the FlowNodeInstance is an Event, this will contain the type of Event (Message, Signal, Timer, etc). * * If the FlowNodeInstance is a regular Event, this will be undefined. */ eventType?: EventType; /** * Optional: Contains the InstanceId of the FlowNodeInstance that was executed before this one. * * StartEvents never have a predecessor. */ previousFlowNodeInstanceId?: string; parentProcessInstanceId?: string; state: FlowNodeInstanceState; processDefinitionId: string; processModelId: string; embeddedProcessModelId?: string; processModelName?: string; processInstanceId: string; correlationId: string; /** * The token with which the Flow Node Instance was started. */ startToken: Record; /** * The token with which the Flow Node Instance was finished. * Only available for Flow Node Instances with a "finished", "error" or "terminated" state. */ endToken?: Record; ownerId: string; error?: Error; startedAt?: Date; finishedAt?: Date; triggeredByFlowNodeInstance?: FlowNodeInstance; multiInstanceMetadataId?: string; multiInstanceStartToken?: Record | Array>; multiInstanceEndToken?: Record | Array>; }; /** * @swagger * components: * schemas: * FlowNodeInstanceState: * description: The state of a FlowNodeInstance. * type: string * enum: * - running * - suspended * - finished * - terminated * - error * - canceled */ export declare enum FlowNodeInstanceState { running = "running", suspended = "suspended", finished = "finished", terminated = "terminated", error = "error", canceled = "canceled" } export type FlowNodeInstanceMetaInfo = { key: string; value: any; }; export declare enum FlowNodeInstanceSortableColumns { flowNodeInstanceId = "flowNodeInstanceId", flowNodeId = "flowNodeId", flowNodeName = "flowNodeName", flowNodeLane = "flowNodeLane", flowNodeType = "flowNodeType", eventType = "eventType", state = "state", previousFlowNodeInstanceId = "previousFlowNodeInstanceId", parentProcessInstanceId = "parentProcessInstanceId", processDefinitionId = "processDefinitionId", processModelId = "processModelId", embeddedProcessModelId = "embeddedProcessModelId", processModelName = "processModelName", processInstanceId = "processInstanceId", correlationId = "correlationId", ownerId = "ownerId", createdAt = "createdAt", finishedAt = "finishedAt", triggeredByFlowNodeInstance = "triggeredByFlowNodeInstance" } export type FlowNodeInstanceSortSettings = { sortBy: FlowNodeInstanceSortableColumns; sortDir?: 'ASC' | 'DESC'; };