n8n/packages/nodes-base/nodes/Microsoft/Outlook/MicrosoftOutlook.node.ts
Michael Kret 556a6132ba
feat(Microsoft Outlook Node): Node overhaul (#4449)
[N8N-4995](https://linear.app/n8n/issue/N8N-4995)

---------

Co-authored-by: Giulio Andreini <g.andreini@gmail.com>
2023-09-15 12:52:18 +03:00

27 lines
877 B
TypeScript

import type { INodeTypeBaseDescription, IVersionedNodeType } from 'n8n-workflow';
import { VersionedNodeType } from 'n8n-workflow';
import { MicrosoftOutlookV1 } from './v1/MicrosoftOutlookV1.node';
import { MicrosoftOutlookV2 } from './v2/MicrosoftOutlookV2.node';
export class MicrosoftOutlook extends VersionedNodeType {
constructor() {
const baseDescription: INodeTypeBaseDescription = {
displayName: 'Microsoft Outlook',
name: 'microsoftOutlook',
group: ['transform'],
icon: 'file:outlook.svg',
subtitle: '={{$parameter["operation"] + ": " + $parameter["resource"]}}',
description: 'Consume Microsoft Outlook API',
defaultVersion: 2,
};
const nodeVersions: IVersionedNodeType['nodeVersions'] = {
1: new MicrosoftOutlookV1(baseDescription),
2: new MicrosoftOutlookV2(baseDescription),
};
super(nodeVersions, baseDescription);
}
}