@villedemontreal/workit
Version:
Worker for Node.js system with pluggable clients that works with both AWS Step function and Camunda platform powered by TypeScript
19 lines (18 loc) • 1.33 kB
TypeScript
import { ICreateWorkflowInstance, ICreateWorkflowInstanceResponse, IDeployWorkflowResponse, IPagination, IPaginationOptions, IPublishMessage, IUpdateWorkflowRetry, IUpdateWorkflowVariables, IWorkflow, IWorkflowClient, IWorkflowDefinition, IWorkflowDefinitionRequest, IWorkflowOptions } from '@villedemontreal/workit-types';
import 'reflect-metadata';
export declare abstract class ClientManager<TClient extends IWorkflowClient> implements IWorkflowClient {
protected readonly _client: TClient;
constructor(client: TClient);
deployWorkflow(bpmnPath: string, override?: any): Promise<IDeployWorkflowResponse>;
getWorkflows(options?: Partial<IWorkflowOptions & IPaginationOptions>): Promise<IPagination<IWorkflow>>;
getWorkflow(payload: IWorkflowDefinitionRequest): Promise<IWorkflowDefinition>;
/**
* Notice that you cannot pass "File" in variables for now.
*/
updateVariables(payload: IUpdateWorkflowVariables): Promise<void>;
updateJobRetries(payload: IUpdateWorkflowRetry): Promise<void>;
publishMessage<T, K>(payload: IPublishMessage<T, K>): Promise<void>;
createWorkflowInstance<T>(model: ICreateWorkflowInstance<T>): Promise<ICreateWorkflowInstanceResponse>;
resolveIncident(incidentKey: string): Promise<void>;
cancelWorkflowInstance(instanceId: string): Promise<void>;
}