UNPKG

@complycube/api

Version:

ComplyCube's Node.js library for the AML/KYC API

43 lines (42 loc) 1.42 kB
import { AxiosInstance } from "axios"; import { Resource } from "../Resource"; export type WorkflowSessionStatus = "started" | "processing" | "complete" | "abandoned" | "cancelled"; export type WorkflowSessionRequest = { clientId?: string | null; workflowTemplateId?: string | null; lastActionBy?: string | null; }; export type WorkflowSessionRelatedCheck = { checkId: string; type: string; taskId: string; }; export type WorkflowSession = { id: string; clientId: string; entityName: string; status: string; workflowTemplateId?: string; workflowTemplateName?: string; workflowTemplateDescription?: string; workflowId?: string; workflowVersion?: number; workflowDescription?: string; compliancePolicies?: object[]; policyAssurance?: object[]; tasks?: object[]; lastCompletedTaskId?: string; allRelatedChecks?: WorkflowSessionRelatedCheck[]; outcome?: string; }; export declare class WorkflowSessions extends Resource<WorkflowSessionRequest> { constructor(axiosInstance: AxiosInstance); get(id: string): Promise<WorkflowSession>; complete(id: string): Promise<{ status: WorkflowSessionStatus; }>; list(clientId: string, workflowTemplateId: string, { page, pageSize }?: { page?: number; pageSize?: number; }): Promise<WorkflowSession[]>; }