2019-06-23 03:35:23 -07:00
|
|
|
|
|
|
|
import {
|
|
|
|
IConnections,
|
|
|
|
ICredentialsDecrypted,
|
|
|
|
ICredentialsEncrypted,
|
|
|
|
ICredentialType,
|
|
|
|
IDataObject,
|
|
|
|
GenericValue,
|
|
|
|
IWorkflowSettings as IWorkflowSettingsWorkflow,
|
|
|
|
INode,
|
|
|
|
INodeCredentials,
|
|
|
|
INodeIssues,
|
2019-12-16 18:27:56 -08:00
|
|
|
INodeParameters,
|
2019-06-23 03:35:23 -07:00
|
|
|
INodePropertyOptions,
|
|
|
|
INodeTypeDescription,
|
|
|
|
IRunExecutionData,
|
|
|
|
IRun,
|
|
|
|
IRunData,
|
|
|
|
ITaskData,
|
|
|
|
WorkflowExecuteMode,
|
|
|
|
} from 'n8n-workflow';
|
|
|
|
|
|
|
|
import {
|
|
|
|
PaintStyle,
|
|
|
|
} from 'jsplumb';
|
|
|
|
|
|
|
|
declare module 'jsplumb' {
|
|
|
|
interface Anchor {
|
|
|
|
lastReturnValue: number[];
|
|
|
|
}
|
|
|
|
|
|
|
|
interface Connection {
|
|
|
|
// bind(event: string, (connection: Connection): void;): void; // tslint:disable-line:no-any
|
|
|
|
bind(event: string, callback: Function): void; // tslint:disable-line:no-any
|
|
|
|
removeOverlay(name: string): void;
|
2019-06-27 02:27:02 -07:00
|
|
|
removeOverlays(): void;
|
2019-06-23 03:35:23 -07:00
|
|
|
setParameter(name: string, value: any): void; // tslint:disable-line:no-any
|
|
|
|
setPaintStyle(arg0: PaintStyle): void;
|
|
|
|
addOverlay(arg0: any[]): void; // tslint:disable-line:no-any
|
|
|
|
setConnector(arg0: any[]): void; // tslint:disable-line:no-any
|
|
|
|
}
|
|
|
|
|
2019-06-27 02:27:02 -07:00
|
|
|
interface Endpoint {
|
|
|
|
getOverlay(name: string): any; // tslint:disable-line:no-any
|
|
|
|
}
|
|
|
|
|
2019-06-23 03:35:23 -07:00
|
|
|
interface Overlay {
|
|
|
|
setVisible(visible: boolean): void;
|
|
|
|
}
|
2019-08-02 08:06:06 -07:00
|
|
|
|
|
|
|
interface OnConnectionBindInfo {
|
|
|
|
originalSourceEndpoint: Endpoint;
|
|
|
|
originalTargetEndpoint: Endpoint;
|
2019-12-10 11:31:11 -08:00
|
|
|
getParameters(): { index: number };
|
2019-08-02 08:06:06 -07:00
|
|
|
}
|
2019-06-23 03:35:23 -07:00
|
|
|
}
|
|
|
|
|
|
|
|
// EndpointOptions from jsplumb seems incomplete and wrong so we define an own one
|
|
|
|
export interface IEndpointOptions {
|
|
|
|
anchor?: any; // tslint:disable-line:no-any
|
|
|
|
createEndpoint?: boolean;
|
|
|
|
dragAllowedWhenFull?: boolean;
|
|
|
|
dropOptions?: any; // tslint:disable-line:no-any
|
|
|
|
dragProxy?: any; // tslint:disable-line:no-any
|
|
|
|
endpoint?: string;
|
|
|
|
endpointStyle?: object;
|
|
|
|
isSource?: boolean;
|
|
|
|
isTarget?: boolean;
|
|
|
|
maxConnections?: number;
|
|
|
|
overlays?: any; // tslint:disable-line:no-any
|
|
|
|
parameters?: any; // tslint:disable-line:no-any
|
|
|
|
uuid?: string;
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface IConnectionsUi {
|
|
|
|
[key: string]: {
|
|
|
|
[key: string]: IEndpointOptions;
|
|
|
|
};
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface IUpdateInformation {
|
|
|
|
name: string;
|
|
|
|
key: string;
|
|
|
|
value: string | number; // with null makes problems in NodeSettings.vue
|
|
|
|
node?: string;
|
|
|
|
oldValue?: string | number;
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface INodeUpdatePropertiesInformation {
|
|
|
|
name: string; // Node-Name
|
|
|
|
properties: {
|
|
|
|
[key: string]: IDataObject;
|
|
|
|
};
|
|
|
|
}
|
|
|
|
|
|
|
|
export type XYPositon = [number, number];
|
|
|
|
|
|
|
|
export type MessageType = 'success' | 'warning' | 'info' | 'error';
|
|
|
|
|
|
|
|
export interface INodeUi extends INode {
|
|
|
|
position: XYPositon;
|
|
|
|
color?: string;
|
|
|
|
notes?: string;
|
|
|
|
issues?: INodeIssues;
|
|
|
|
_jsPlumb?: {
|
|
|
|
endpoints?: {
|
|
|
|
[key: string]: IEndpointOptions[];
|
|
|
|
};
|
|
|
|
};
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface INodeTypesMaxCount {
|
|
|
|
[key: string]: {
|
|
|
|
exist: number;
|
|
|
|
max: number;
|
|
|
|
nodeNames: string[];
|
|
|
|
};
|
|
|
|
}
|
|
|
|
|
2021-01-19 14:48:30 -08:00
|
|
|
export interface IExternalHooks {
|
|
|
|
run(eventName: string, metadata?: IDataObject): Promise<void>;
|
|
|
|
}
|
|
|
|
|
2019-06-23 03:35:23 -07:00
|
|
|
export interface IRestApi {
|
|
|
|
getActiveWorkflows(): Promise<string[]>;
|
|
|
|
getActivationError(id: string): Promise<IActivationError | undefined >;
|
|
|
|
getCurrentExecutions(filter: object): Promise<IExecutionsCurrentSummaryExtended[]>;
|
2021-02-09 14:32:40 -08:00
|
|
|
getPastExecutions(filter: object, limit: number, lastId?: string | number, firstId?: string | number): Promise<IExecutionsListResponse>;
|
2019-06-23 03:35:23 -07:00
|
|
|
stopCurrentExecution(executionId: string): Promise<IExecutionsStopData>;
|
|
|
|
makeRestApiRequest(method: string, endpoint: string, data?: any): Promise<any>; // tslint:disable-line:no-any
|
|
|
|
getSettings(): Promise<IN8nUISettings>;
|
|
|
|
getNodeTypes(): Promise<INodeTypeDescription[]>;
|
2020-10-22 08:24:35 -07:00
|
|
|
getNodesInformation(nodeList: string[]): Promise<INodeTypeDescription[]>;
|
2021-05-16 16:16:24 -07:00
|
|
|
getNodeParameterOptions(nodeType: string, path: string, methodName: string, currentNodeParameters: INodeParameters, credentials?: INodeCredentials): Promise<INodePropertyOptions[]>;
|
2019-06-23 03:35:23 -07:00
|
|
|
removeTestWebhook(workflowId: string): Promise<boolean>;
|
|
|
|
runWorkflow(runData: IStartRunData): Promise<IExecutionPushResponse>;
|
2021-05-29 11:31:21 -07:00
|
|
|
createNewWorkflow(sendData: IWorkflowDataUpdate): Promise<IWorkflowDb>;
|
2019-06-23 03:35:23 -07:00
|
|
|
updateWorkflow(id: string, data: IWorkflowDataUpdate): Promise<IWorkflowDb>;
|
|
|
|
deleteWorkflow(name: string): Promise<void>;
|
|
|
|
getWorkflow(id: string): Promise<IWorkflowDb>;
|
|
|
|
getWorkflows(filter?: object): Promise<IWorkflowShortResponse[]>;
|
|
|
|
getWorkflowFromUrl(url: string): Promise<IWorkflowDb>;
|
|
|
|
createNewCredentials(sendData: ICredentialsDecrypted): Promise<ICredentialsResponse>;
|
|
|
|
deleteCredentials(id: string): Promise<void>;
|
|
|
|
updateCredentials(id: string, data: ICredentialsDecrypted): Promise<ICredentialsResponse>;
|
|
|
|
getAllCredentials(filter?: object): Promise<ICredentialsResponse[]>;
|
|
|
|
getCredentials(id: string, includeData?: boolean): Promise<ICredentialsDecryptedResponse | ICredentialsResponse | undefined>;
|
|
|
|
getCredentialTypes(): Promise<ICredentialType[]>;
|
|
|
|
getExecution(id: string): Promise<IExecutionResponse>;
|
|
|
|
deleteExecutions(sendData: IExecutionDeleteFilter): Promise<void>;
|
2019-12-12 16:12:38 -08:00
|
|
|
retryExecution(id: string, loadWorkflow?: boolean): Promise<boolean>;
|
2019-06-23 03:35:23 -07:00
|
|
|
getTimezones(): Promise<IDataObject>;
|
2020-06-01 17:42:38 -07:00
|
|
|
oAuth1CredentialAuthorize(sendData: ICredentialsResponse): Promise<string>;
|
2020-01-07 16:29:11 -08:00
|
|
|
oAuth2CredentialAuthorize(sendData: ICredentialsResponse): Promise<string>;
|
|
|
|
oAuth2Callback(code: string, state: string): Promise<string>;
|
2019-06-23 03:35:23 -07:00
|
|
|
}
|
|
|
|
|
|
|
|
export interface IBinaryDisplayData {
|
|
|
|
index: number;
|
|
|
|
key: string;
|
|
|
|
node: string;
|
|
|
|
outputIndex: number;
|
|
|
|
runIndex: number;
|
|
|
|
}
|
|
|
|
|
2020-02-08 16:14:28 -08:00
|
|
|
export interface ICredentialsCreatedEvent {
|
|
|
|
data: ICredentialsDecryptedResponse;
|
|
|
|
options: {
|
|
|
|
closeDialog: boolean,
|
|
|
|
};
|
|
|
|
}
|
|
|
|
|
2019-06-23 03:35:23 -07:00
|
|
|
export interface IStartRunData {
|
|
|
|
workflowData: IWorkflowData;
|
|
|
|
startNodes?: string[];
|
|
|
|
destinationNode?: string;
|
|
|
|
runData?: IRunData;
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface IRunDataUi {
|
|
|
|
node?: string;
|
|
|
|
workflowData: IWorkflowData;
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface ITableData {
|
|
|
|
columns: string[];
|
|
|
|
data: GenericValue[][];
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface IVariableItemSelected {
|
|
|
|
variable: string;
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface IVariableSelectorOption {
|
|
|
|
name: string;
|
|
|
|
key?: string;
|
|
|
|
value?: string;
|
|
|
|
options?: IVariableSelectorOption[] | null;
|
|
|
|
allowParentSelect?: boolean;
|
|
|
|
dataType?: string;
|
|
|
|
}
|
|
|
|
|
|
|
|
// Simple version of n8n-workflow.Workflow
|
|
|
|
export interface IWorkflowData {
|
|
|
|
id?: string;
|
|
|
|
name?: string;
|
|
|
|
active?: boolean;
|
|
|
|
nodes: INode[];
|
|
|
|
connections: IConnections;
|
|
|
|
settings?: IWorkflowSettings;
|
2021-05-29 11:31:21 -07:00
|
|
|
tags?: string[];
|
2019-06-23 03:35:23 -07:00
|
|
|
}
|
|
|
|
|
|
|
|
export interface IWorkflowDataUpdate {
|
2021-05-29 11:31:21 -07:00
|
|
|
id?: string;
|
2019-06-23 03:35:23 -07:00
|
|
|
name?: string;
|
|
|
|
nodes?: INode[];
|
|
|
|
connections?: IConnections;
|
|
|
|
settings?: IWorkflowSettings;
|
|
|
|
active?: boolean;
|
2021-05-29 11:31:21 -07:00
|
|
|
tags?: ITag[] | string[]; // string[] when store or requested, ITag[] from API response
|
2019-06-23 03:35:23 -07:00
|
|
|
}
|
|
|
|
|
|
|
|
// Almost identical to cli.Interfaces.ts
|
|
|
|
export interface IWorkflowDb {
|
|
|
|
id: string;
|
|
|
|
name: string;
|
|
|
|
active: boolean;
|
|
|
|
createdAt: number | string;
|
|
|
|
updatedAt: number | string;
|
|
|
|
nodes: INodeUi[];
|
|
|
|
connections: IConnections;
|
|
|
|
settings?: IWorkflowSettings;
|
2021-05-29 11:31:21 -07:00
|
|
|
tags?: ITag[] | string[]; // string[] when store or requested, ITag[] from API response
|
2019-06-23 03:35:23 -07:00
|
|
|
}
|
|
|
|
|
|
|
|
// Identical to cli.Interfaces.ts
|
|
|
|
export interface IWorkflowShortResponse {
|
|
|
|
id: string;
|
|
|
|
name: string;
|
|
|
|
active: boolean;
|
|
|
|
createdAt: number | string;
|
|
|
|
updatedAt: number | string;
|
2021-05-29 11:31:21 -07:00
|
|
|
tags: ITag[];
|
2019-06-23 03:35:23 -07:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// Identical or almost identical to cli.Interfaces.ts
|
|
|
|
|
|
|
|
export interface IActivationError {
|
|
|
|
time: number;
|
|
|
|
error: {
|
|
|
|
message: string;
|
|
|
|
};
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface ICredentialsResponse extends ICredentialsEncrypted {
|
|
|
|
id?: string;
|
|
|
|
createdAt: number | string;
|
|
|
|
updatedAt: number | string;
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface ICredentialsBase {
|
|
|
|
createdAt: number | string;
|
|
|
|
updatedAt: number | string;
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface ICredentialsDecryptedResponse extends ICredentialsBase, ICredentialsDecrypted{
|
|
|
|
id: string;
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface IExecutionBase {
|
|
|
|
id?: number | string;
|
|
|
|
finished: boolean;
|
|
|
|
mode: WorkflowExecuteMode;
|
|
|
|
retryOf?: string;
|
|
|
|
retrySuccessId?: string;
|
2019-07-22 11:29:06 -07:00
|
|
|
startedAt: Date;
|
|
|
|
stoppedAt?: Date;
|
2019-06-23 03:35:23 -07:00
|
|
|
workflowId?: string; // To be able to filter executions easily //
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface IExecutionFlatted extends IExecutionBase {
|
|
|
|
data: string;
|
|
|
|
workflowData: IWorkflowDb;
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface IExecutionFlattedResponse extends IExecutionFlatted {
|
|
|
|
id: string;
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface IExecutionPushResponse {
|
|
|
|
executionId?: string;
|
|
|
|
waitingForWebhook?: boolean;
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface IExecutionResponse extends IExecutionBase {
|
|
|
|
id: string;
|
|
|
|
data: IRunExecutionData;
|
|
|
|
workflowData: IWorkflowDb;
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface IExecutionShortResponse {
|
|
|
|
id: string;
|
|
|
|
workflowData: {
|
|
|
|
id: string;
|
|
|
|
name: string;
|
|
|
|
};
|
|
|
|
mode: WorkflowExecuteMode;
|
|
|
|
finished: boolean;
|
2019-07-22 11:29:06 -07:00
|
|
|
startedAt: Date;
|
|
|
|
stoppedAt: Date;
|
2019-06-23 03:35:23 -07:00
|
|
|
executionTime?: number;
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface IExecutionsListResponse {
|
|
|
|
count: number;
|
|
|
|
results: IExecutionsSummary[];
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface IExecutionsCurrentSummaryExtended {
|
2021-02-13 11:40:27 -08:00
|
|
|
id: string;
|
2019-06-23 03:35:23 -07:00
|
|
|
finished?: boolean;
|
|
|
|
mode: WorkflowExecuteMode;
|
2019-08-08 22:37:10 -07:00
|
|
|
retryOf?: string;
|
|
|
|
retrySuccessId?: string;
|
2019-07-22 11:29:06 -07:00
|
|
|
startedAt: Date;
|
|
|
|
stoppedAt?: Date;
|
2019-06-23 03:35:23 -07:00
|
|
|
workflowId: string;
|
|
|
|
workflowName?: string;
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface IExecutionsStopData {
|
|
|
|
finished?: boolean;
|
|
|
|
mode: WorkflowExecuteMode;
|
2019-07-22 11:29:06 -07:00
|
|
|
startedAt: Date;
|
|
|
|
stoppedAt: Date;
|
2019-06-23 03:35:23 -07:00
|
|
|
}
|
|
|
|
|
|
|
|
export interface IExecutionsSummary {
|
2021-02-13 11:40:27 -08:00
|
|
|
id: string;
|
2019-06-23 03:35:23 -07:00
|
|
|
mode: WorkflowExecuteMode;
|
|
|
|
finished?: boolean;
|
|
|
|
retryOf?: string;
|
|
|
|
retrySuccessId?: string;
|
2019-07-22 11:29:06 -07:00
|
|
|
startedAt: Date;
|
|
|
|
stoppedAt?: Date;
|
2019-06-23 03:35:23 -07:00
|
|
|
workflowId: string;
|
|
|
|
workflowName?: string;
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface IExecutionDeleteFilter {
|
2019-07-22 11:29:06 -07:00
|
|
|
deleteBefore?: Date;
|
2019-06-23 03:35:23 -07:00
|
|
|
filters?: IDataObject;
|
|
|
|
ids?: string[];
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface IPushData {
|
2021-05-29 11:41:25 -07:00
|
|
|
data: IPushDataExecutionFinished | IPushDataNodeExecuteAfter | IPushDataNodeExecuteBefore | IPushDataTestWebhook | IPushDataConsoleMessage;
|
2019-06-23 03:35:23 -07:00
|
|
|
type: IPushDataType;
|
|
|
|
}
|
|
|
|
|
2021-05-29 11:41:25 -07:00
|
|
|
export type IPushDataType = 'executionFinished' | 'executionStarted' | 'nodeExecuteAfter' | 'nodeExecuteBefore' | 'sendConsoleMessage' | 'testWebhookDeleted' | 'testWebhookReceived';
|
2019-07-24 05:25:30 -07:00
|
|
|
|
|
|
|
export interface IPushDataExecutionStarted {
|
|
|
|
executionId: string;
|
|
|
|
mode: WorkflowExecuteMode;
|
|
|
|
startedAt: Date;
|
|
|
|
retryOf?: string;
|
|
|
|
workflowId: string;
|
|
|
|
workflowName?: string;
|
|
|
|
}
|
|
|
|
|
2019-06-23 03:35:23 -07:00
|
|
|
export interface IPushDataExecutionFinished {
|
|
|
|
data: IRun;
|
2021-02-13 11:40:27 -08:00
|
|
|
executionId: string;
|
2019-08-08 22:37:10 -07:00
|
|
|
retryOf?: string;
|
2019-07-24 05:25:30 -07:00
|
|
|
}
|
|
|
|
|
|
|
|
export interface IPushDataExecutionStarted {
|
2019-06-23 03:35:23 -07:00
|
|
|
executionId: string;
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface IPushDataNodeExecuteAfter {
|
|
|
|
data: ITaskData;
|
|
|
|
executionId: string;
|
|
|
|
nodeName: string;
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface IPushDataNodeExecuteBefore {
|
|
|
|
executionId: string;
|
|
|
|
nodeName: string;
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface IPushDataTestWebhook {
|
2019-07-26 05:17:00 -07:00
|
|
|
executionId: string;
|
2019-06-23 03:35:23 -07:00
|
|
|
workflowId: string;
|
|
|
|
}
|
|
|
|
|
2021-05-29 11:41:25 -07:00
|
|
|
export interface IPushDataConsoleMessage {
|
|
|
|
source: string;
|
|
|
|
message: string;
|
|
|
|
}
|
|
|
|
|
2019-06-23 03:35:23 -07:00
|
|
|
export interface IN8nUISettings {
|
|
|
|
endpointWebhook: string;
|
|
|
|
endpointWebhookTest: string;
|
2019-07-10 11:53:13 -07:00
|
|
|
saveDataErrorExecution: string;
|
|
|
|
saveDataSuccessExecution: string;
|
2019-07-10 09:06:26 -07:00
|
|
|
saveManualExecutions: boolean;
|
2019-06-23 03:35:23 -07:00
|
|
|
timezone: string;
|
2020-07-29 05:12:54 -07:00
|
|
|
executionTimeout: number;
|
|
|
|
maxExecutionTimeout: number;
|
2020-09-30 06:50:43 -07:00
|
|
|
oauthCallbackUrls: {
|
|
|
|
oauth1: string;
|
|
|
|
oauth2: string;
|
|
|
|
};
|
2019-06-23 03:35:23 -07:00
|
|
|
urlBaseWebhook: string;
|
2019-09-11 09:40:22 -07:00
|
|
|
versionCli: string;
|
2021-01-19 14:48:30 -08:00
|
|
|
n8nMetadata?: {
|
|
|
|
[key: string]: string | number | undefined;
|
|
|
|
};
|
2019-06-23 03:35:23 -07:00
|
|
|
}
|
|
|
|
|
|
|
|
export interface IWorkflowSettings extends IWorkflowSettingsWorkflow {
|
|
|
|
errorWorkflow?: string;
|
2019-07-10 11:53:13 -07:00
|
|
|
saveDataErrorExecution?: string;
|
|
|
|
saveDataSuccessExecution?: string;
|
2019-07-10 09:06:26 -07:00
|
|
|
saveManualExecutions?: boolean;
|
2019-06-23 03:35:23 -07:00
|
|
|
timezone?: string;
|
2020-07-29 05:12:54 -07:00
|
|
|
executionTimeout?: number;
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface ITimeoutHMS {
|
|
|
|
hours: number;
|
|
|
|
minutes: number;
|
|
|
|
seconds: number;
|
2019-06-23 03:35:23 -07:00
|
|
|
}
|
2020-08-25 11:38:09 -07:00
|
|
|
|
|
|
|
export type WorkflowTitleStatus = 'EXECUTING' | 'IDLE' | 'ERROR';
|
2021-04-09 13:44:53 -07:00
|
|
|
|
|
|
|
export type MenuItemType = 'link';
|
|
|
|
export type MenuItemPosition = 'top' | 'bottom';
|
|
|
|
|
|
|
|
export interface IMenuItem {
|
|
|
|
id: string;
|
|
|
|
type: MenuItemType;
|
2021-05-04 08:55:39 -07:00
|
|
|
position?: MenuItemPosition;
|
2021-04-09 13:44:53 -07:00
|
|
|
properties: ILinkMenuItemProperties;
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface ILinkMenuItemProperties {
|
|
|
|
title: string;
|
|
|
|
icon: string;
|
|
|
|
href: string;
|
|
|
|
newWindow?: boolean;
|
2021-05-16 16:16:24 -07:00
|
|
|
}
|
2021-05-29 11:31:21 -07:00
|
|
|
|
|
|
|
export interface ITag {
|
|
|
|
id: string;
|
|
|
|
name: string;
|
|
|
|
usageCount?: number;
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface ITagRow {
|
|
|
|
tag?: ITag;
|
|
|
|
usage?: string;
|
|
|
|
create?: boolean;
|
|
|
|
disable?: boolean;
|
|
|
|
update?: boolean;
|
|
|
|
delete?: boolean;
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface IRootState {
|
|
|
|
activeExecutions: IExecutionsCurrentSummaryExtended[];
|
|
|
|
activeWorkflows: string[];
|
|
|
|
activeActions: string[];
|
|
|
|
activeNode: string | null;
|
|
|
|
baseUrl: string;
|
|
|
|
credentials: ICredentialsResponse[] | null;
|
|
|
|
credentialTypes: ICredentialType[] | null;
|
|
|
|
endpointWebhook: string;
|
|
|
|
endpointWebhookTest: string;
|
|
|
|
executionId: string | null;
|
|
|
|
executingNode: string | null;
|
|
|
|
executionWaitingForWebhook: boolean;
|
|
|
|
pushConnectionActive: boolean;
|
|
|
|
saveDataErrorExecution: string;
|
|
|
|
saveDataSuccessExecution: string;
|
|
|
|
saveManualExecutions: boolean;
|
|
|
|
timezone: string;
|
|
|
|
stateIsDirty: boolean;
|
|
|
|
executionTimeout: number;
|
|
|
|
maxExecutionTimeout: number;
|
|
|
|
versionCli: string;
|
|
|
|
oauthCallbackUrls: object;
|
|
|
|
n8nMetadata: object;
|
|
|
|
workflowExecutionData: IExecutionResponse | null;
|
|
|
|
lastSelectedNode: string | null;
|
|
|
|
lastSelectedNodeOutputIndex: number | null;
|
|
|
|
nodeIndex: Array<string | null>;
|
|
|
|
nodeTypes: INodeTypeDescription[];
|
|
|
|
nodeViewOffsetPosition: XYPositon;
|
|
|
|
nodeViewMoveInProgress: boolean;
|
|
|
|
selectedNodes: INodeUi[];
|
|
|
|
sessionId: string;
|
|
|
|
urlBaseWebhook: string;
|
|
|
|
workflow: IWorkflowDb;
|
|
|
|
sidebarMenuItems: IMenuItem[];
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface ITagsState {
|
|
|
|
tags: { [id: string]: ITag };
|
|
|
|
isLoading: boolean;
|
|
|
|
fetchedAll: boolean;
|
|
|
|
fetchedUsageCount: boolean;
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface IModalState {
|
|
|
|
open: boolean;
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface IUiState {
|
|
|
|
sidebarMenuCollapsed: boolean;
|
|
|
|
modalStack: string[];
|
|
|
|
modals: {
|
|
|
|
[key: string]: IModalState;
|
|
|
|
};
|
|
|
|
isPageLoading: boolean;
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface IWorkflowsState {
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface IRestApiContext {
|
|
|
|
baseUrl: string;
|
|
|
|
sessionId: string;
|
|
|
|
}
|