Skip to content

Commit 9b00689

Browse files
authored
Merging pull request #16827
1 parent afe83f2 commit 9b00689

File tree

2 files changed

+16
-2
lines changed

2 files changed

+16
-2
lines changed

components/pipedrive/actions/add-lead/add-lead.mjs

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ export default {
66
key: "pipedrive-add-lead",
77
name: "Add Lead",
88
description: "Create a new lead in Pipedrive. [See the documentation](https://developers.pipedrive.com/docs/api/v1/Leads#addLead)",
9-
version: "0.0.1",
9+
version: "0.0.2",
1010
type: "action",
1111
props: {
1212
pipedrive,
@@ -84,6 +84,12 @@ export default {
8484
description: "A flag indicating whether the lead was seen by someone in the Pipedrive UI",
8585
optional: true,
8686
},
87+
note: {
88+
type: "string",
89+
label: "Note",
90+
description: "A note to add to the lead",
91+
optional: true,
92+
},
8793
},
8894
async run({ $ }) {
8995
if (!this.organizationId && !this.personId) {
@@ -101,6 +107,14 @@ export default {
101107
visible_to: this.visibleTo,
102108
was_seen: this.wasSeen,
103109
});
110+
111+
if (this.note) {
112+
await this.pipedrive.addNote({
113+
content: this.note,
114+
lead_id: response.data?.id,
115+
});
116+
}
117+
104118
$.export("$summary", `Successfully created lead: ${response.data?.title || response.data?.id}`);
105119
return response;
106120
},

components/pipedrive/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@pipedream/pipedrive",
3-
"version": "0.4.0",
3+
"version": "0.4.1",
44
"description": "Pipedream Pipedrive Components",
55
"main": "pipedrive.app.mjs",
66
"keywords": [

0 commit comments

Comments
 (0)