n8n/packages/nodes-base/nodes/Pipedrive/Pipedrive.node.ts
krisn0x de60c85581
Some checks failed
CI: Master (Build, Test, Lint) / Build for Github Cache (push) Waiting to run
CI: Master (Build, Test, Lint) / Unit tests (22.x) (push) Waiting to run
CI: Master (Build, Test, Lint) / Unit tests (24.14.1) (push) Waiting to run
CI: Master (Build, Test, Lint) / Unit tests (25.x) (push) Waiting to run
CI: Master (Build, Test, Lint) / Lint (push) Waiting to run
CI: Master (Build, Test, Lint) / Performance (push) Waiting to run
CI: Master (Build, Test, Lint) / Notify Slack on failure (push) Blocked by required conditions
Release: Create Minor Release PR / Create release PR (push) Has been cancelled
Release: Create Minor Release PR / Notify Slack (push) Has been cancelled
fix(Pipedrive Node): Add v2 node with API v2 migration (#27905)
2026-04-06 08:26:53 +00:00

27 lines
819 B
TypeScript

import type { INodeTypeBaseDescription, IVersionedNodeType } from 'n8n-workflow';
import { VersionedNodeType } from 'n8n-workflow';
import { PipedriveV1 } from './v1/PipedriveV1.node';
import { PipedriveV2 } from './v2/PipedriveV2.node';
export class Pipedrive extends VersionedNodeType {
constructor() {
const baseDescription: INodeTypeBaseDescription = {
displayName: 'Pipedrive',
name: 'pipedrive',
icon: 'file:pipedrive.svg',
group: ['transform'],
defaultVersion: 2,
subtitle: '={{$parameter["operation"] + ": " + $parameter["resource"]}}',
description: 'Create and edit data in Pipedrive',
};
const nodeVersions: IVersionedNodeType['nodeVersions'] = {
1: new PipedriveV1(baseDescription),
2: new PipedriveV2(baseDescription),
};
super(nodeVersions, baseDescription);
}
}