2024-08-29 06:55:53 -07:00
|
|
|
|
import {
|
|
|
|
|
NodeConnectionType,
|
|
|
|
|
type IExecuteFunctions,
|
|
|
|
|
type INodeExecutionData,
|
|
|
|
|
type INodeType,
|
|
|
|
|
type INodeTypeDescription,
|
2023-03-09 09:13:15 -08:00
|
|
|
|
} from 'n8n-workflow';
|
2019-06-23 03:35:23 -07:00
|
|
|
|
|
|
|
|
|
export class Start implements INodeType {
|
|
|
|
|
description: INodeTypeDescription = {
|
|
|
|
|
displayName: 'Start',
|
|
|
|
|
name: 'start',
|
2019-07-26 02:27:46 -07:00
|
|
|
|
icon: 'fa:play',
|
2019-06-23 03:35:23 -07:00
|
|
|
|
group: ['input'],
|
|
|
|
|
version: 1,
|
|
|
|
|
description: 'Starts the workflow execution from this node',
|
|
|
|
|
maxNodes: 1,
|
2022-09-15 01:52:24 -07:00
|
|
|
|
hidden: true,
|
2019-06-23 03:35:23 -07:00
|
|
|
|
defaults: {
|
|
|
|
|
name: 'Start',
|
2019-07-26 02:41:08 -07:00
|
|
|
|
color: '#00e000',
|
2019-06-23 03:35:23 -07:00
|
|
|
|
},
|
2022-04-22 09:29:51 -07:00
|
|
|
|
// eslint-disable-next-line n8n-nodes-base/node-class-description-inputs-wrong-regular-node
|
2019-06-23 03:35:23 -07:00
|
|
|
|
inputs: [],
|
2024-08-29 06:55:53 -07:00
|
|
|
|
outputs: [NodeConnectionType.Main],
|
2019-06-23 03:35:23 -07:00
|
|
|
|
properties: [
|
2022-06-20 12:39:24 -07:00
|
|
|
|
{
|
2022-08-17 08:50:24 -07:00
|
|
|
|
displayName:
|
|
|
|
|
'This node is where a manual workflow execution starts. To make one, go back to the canvas and click ‘execute workflow’',
|
2022-06-20 12:39:24 -07:00
|
|
|
|
name: 'notice',
|
|
|
|
|
type: 'notice',
|
|
|
|
|
default: '',
|
|
|
|
|
},
|
2019-06-23 03:35:23 -07:00
|
|
|
|
],
|
|
|
|
|
};
|
|
|
|
|
|
2022-12-02 12:54:28 -08:00
|
|
|
|
async execute(this: IExecuteFunctions): Promise<INodeExecutionData[][]> {
|
2019-06-23 03:35:23 -07:00
|
|
|
|
const items = this.getInputData();
|
|
|
|
|
|
2023-09-05 03:59:02 -07:00
|
|
|
|
return [items];
|
2019-06-23 03:35:23 -07:00
|
|
|
|
}
|
|
|
|
|
}
|