@activepieces/piece-drip 0.3.10 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +9 -15
- package/src/i18n/zh.json +33 -33
- package/src/index.js +1 -1
- package/src/index.js.map +1 -1
- package/src/lib/actions/add-subscriber-to-campaign.action.d.ts +2 -2
- package/src/lib/actions/add-subscriber-to-campaign.action.js +2 -1
- package/src/lib/actions/add-subscriber-to-campaign.action.js.map +1 -1
- package/src/lib/actions/apply-tag-to-subscriber.action.d.ts +1 -1
- package/src/lib/actions/upsert-subscriber.action.d.ts +1 -1
- package/src/lib/common/index.d.ts +4 -2
- package/src/lib/common/index.js +4 -2
- package/src/lib/common/index.js.map +1 -1
- package/src/lib/trigger/new-subscriber.trigger.d.ts +3 -3
- package/src/lib/trigger/new-tag.trigger.d.ts +3 -3
package/package.json
CHANGED
|
@@ -1,27 +1,21 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@activepieces/piece-drip",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.4.0",
|
|
4
4
|
"dependencies": {
|
|
5
5
|
"@sinclair/typebox": "0.34.11",
|
|
6
|
-
"axios": "1.
|
|
6
|
+
"axios": "1.13.1",
|
|
7
7
|
"axios-retry": "4.4.1",
|
|
8
8
|
"deepmerge-ts": "7.1.0",
|
|
9
|
+
"form-data": "4.0.4",
|
|
9
10
|
"mime-types": "2.1.35",
|
|
10
11
|
"nanoid": "3.3.8",
|
|
11
12
|
"semver": "7.6.0",
|
|
12
|
-
"
|
|
13
|
-
"
|
|
14
|
-
"@activepieces/pieces-
|
|
15
|
-
"@activepieces/
|
|
16
|
-
"
|
|
17
|
-
|
|
18
|
-
"overrides": {
|
|
19
|
-
"@tryfabric/martian": {
|
|
20
|
-
"@notionhq/client": "$@notionhq/client"
|
|
21
|
-
},
|
|
22
|
-
"vite": {
|
|
23
|
-
"rollup": "npm:@rollup/wasm-node"
|
|
24
|
-
}
|
|
13
|
+
"socket.io-client": "4.8.1",
|
|
14
|
+
"zod": "4.1.13",
|
|
15
|
+
"@activepieces/pieces-common": "0.11.0",
|
|
16
|
+
"@activepieces/pieces-framework": "0.23.0",
|
|
17
|
+
"@activepieces/shared": "0.30.4",
|
|
18
|
+
"tslib": "2.6.2"
|
|
25
19
|
},
|
|
26
20
|
"resolutions": {
|
|
27
21
|
"rollup": "npm:@rollup/wasm-node"
|
package/src/i18n/zh.json
CHANGED
|
@@ -1,54 +1,54 @@
|
|
|
1
1
|
{
|
|
2
|
-
"E-commerce CRM for B2B marketers": "B2B
|
|
3
|
-
"Get it from https://www.getdrip.com/user/edit": "
|
|
4
|
-
"Apply a tag to subscriber": "
|
|
5
|
-
"Add a subscriber to a campaign": "
|
|
6
|
-
"Create or Update Subscriber": "
|
|
2
|
+
"E-commerce CRM for B2B marketers": "E-commerce CRM for B2B marketers",
|
|
3
|
+
"Get it from https://www.getdrip.com/user/edit": "Get it from https://www.getdrip.com/user/edit",
|
|
4
|
+
"Apply a tag to subscriber": "Apply a tag to subscriber",
|
|
5
|
+
"Add a subscriber to a campaign": "Add a subscriber to a campaign",
|
|
6
|
+
"Create or Update Subscriber": "Create or Update Subscriber",
|
|
7
7
|
"Custom API Call": "自定义 API 呼叫",
|
|
8
|
-
"Apply a tag to a subscriber": "
|
|
9
|
-
"Add a subscriber to a campaign (Email series)": "
|
|
8
|
+
"Apply a tag to a subscriber": "Apply a tag to a subscriber",
|
|
9
|
+
"Add a subscriber to a campaign (Email series)": "Add a subscriber to a campaign (Email series)",
|
|
10
10
|
"Make a custom API call to a specific endpoint": "将一个自定义 API 调用到一个特定的终点",
|
|
11
|
-
"Account": "
|
|
12
|
-
"Subscriber Email": "
|
|
11
|
+
"Account": "Account",
|
|
12
|
+
"Subscriber Email": "Subscriber Email",
|
|
13
13
|
"Tag": "标签",
|
|
14
|
-
"Email Series Campaign": "
|
|
14
|
+
"Email Series Campaign": "Email Series Campaign",
|
|
15
15
|
"tags": "标签",
|
|
16
|
-
"Custom Fields": "
|
|
16
|
+
"Custom Fields": "Custom Fields",
|
|
17
17
|
"First Name": "名字",
|
|
18
18
|
"Last Name": "名字",
|
|
19
|
-
"Zip Code": "
|
|
20
|
-
"Country": "
|
|
21
|
-
"State": "
|
|
22
|
-
"City": "
|
|
23
|
-
"Phone": "
|
|
24
|
-
"Address": "
|
|
19
|
+
"Zip Code": "Zip Code",
|
|
20
|
+
"Country": "Country",
|
|
21
|
+
"State": "State",
|
|
22
|
+
"City": "City",
|
|
23
|
+
"Phone": "Phone",
|
|
24
|
+
"Address": "Address",
|
|
25
25
|
"Method": "方法",
|
|
26
26
|
"Headers": "信头",
|
|
27
27
|
"Query Parameters": "查询参数",
|
|
28
28
|
"Body": "正文内容",
|
|
29
|
-
"Response is Binary ?": "
|
|
29
|
+
"Response is Binary ?": "Response is Binary ?",
|
|
30
30
|
"No Error on Failure": "失败时没有错误",
|
|
31
31
|
"Timeout (in seconds)": "超时(秒)",
|
|
32
|
-
"Email of the subscriber": "
|
|
33
|
-
"Tag to apply": "
|
|
34
|
-
"Tags to apply to subscriber": "
|
|
35
|
-
"Custom field data about the subscriber": "
|
|
36
|
-
"Postal code in which the subscriber resides": "
|
|
37
|
-
"The country in which the subscriber resides": "
|
|
38
|
-
"The region in which the subscriber resides": "
|
|
39
|
-
"The city in which the subscriber resides": "
|
|
40
|
-
"The subscriber's primary phone number": "
|
|
41
|
-
"The subscriber's mailing address": "
|
|
32
|
+
"Email of the subscriber": "Email of the subscriber",
|
|
33
|
+
"Tag to apply": "Tag to apply",
|
|
34
|
+
"Tags to apply to subscriber": "Tags to apply to subscriber",
|
|
35
|
+
"Custom field data about the subscriber": "Custom field data about the subscriber",
|
|
36
|
+
"Postal code in which the subscriber resides": "Postal code in which the subscriber resides",
|
|
37
|
+
"The country in which the subscriber resides": "The country in which the subscriber resides",
|
|
38
|
+
"The region in which the subscriber resides": "The region in which the subscriber resides",
|
|
39
|
+
"The city in which the subscriber resides": "The city in which the subscriber resides",
|
|
40
|
+
"The subscriber's primary phone number": "The subscriber's primary phone number",
|
|
41
|
+
"The subscriber's mailing address": "The subscriber's mailing address",
|
|
42
42
|
"Authorization headers are injected automatically from your connection.": "授权头自动从您的连接中注入。",
|
|
43
|
-
"Enable for files like PDFs, images, etc..": "
|
|
43
|
+
"Enable for files like PDFs, images, etc..": "Enable for files like PDFs, images, etc..",
|
|
44
44
|
"GET": "获取",
|
|
45
45
|
"POST": "帖子",
|
|
46
46
|
"PATCH": "PATCH",
|
|
47
47
|
"PUT": "弹出",
|
|
48
48
|
"DELETE": "删除",
|
|
49
49
|
"HEAD": "黑色",
|
|
50
|
-
"New Subscriber": "
|
|
51
|
-
"Tag Applied": "
|
|
52
|
-
"Triggers when a subscriber is created in your Drip account.": "
|
|
53
|
-
"Triggers when a tag is applied.": "
|
|
50
|
+
"New Subscriber": "New Subscriber",
|
|
51
|
+
"Tag Applied": "Tag Applied",
|
|
52
|
+
"Triggers when a subscriber is created in your Drip account.": "Triggers when a subscriber is created in your Drip account.",
|
|
53
|
+
"Triggers when a tag is applied.": "Triggers when a tag is applied."
|
|
54
54
|
}
|
package/src/index.js
CHANGED
|
@@ -32,7 +32,7 @@ exports.drip = (0, pieces_framework_1.createPiece)({
|
|
|
32
32
|
auth: exports.dripAuth,
|
|
33
33
|
authMapping: (auth) => tslib_1.__awaiter(void 0, void 0, void 0, function* () {
|
|
34
34
|
return ({
|
|
35
|
-
Authorization: `Basic ${Buffer.from(auth).toString('base64')}`,
|
|
35
|
+
Authorization: `Basic ${Buffer.from(auth.secret_text).toString('base64')}`,
|
|
36
36
|
});
|
|
37
37
|
}),
|
|
38
38
|
}),
|
package/src/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../packages/pieces/community/drip/src/index.ts"],"names":[],"mappings":";;;;AAAA,+DAAwE;AACxE,qEAAwE;AACxE,iDAAqD;AACrD,uGAA8F;AAC9F,iGA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;IAC/C,uBAAuB,EAAE,QAAQ;IACjC,OAAO,EAAE,8CAA8C;IACvD,OAAO,EAAE,CAAC,YAAY,EAAC,WAAW,EAAC,sBAAsB,EAAC,eAAe,EAAC,UAAU,CAAC;IACrF,UAAU,EAAE,CAAC,sBAAa,CAAC,SAAS,CAAC;IACrC,IAAI,EAAE,gBAAQ;IACd,OAAO,EAAE;QACP,yDAAwB;QACxB,+DAA2B;QAC3B,qDAA0B;QAC1B,IAAA,yCAAyB,EAAC;YACxB,OAAO,EAAE,GAAG,EAAE,CAAC,6BAA6B;YAC5C,IAAI,EAAE,gBAAQ;YACd,WAAW,EAAE,CAAO,IAAI,EAAE,EAAE;gBAAC,OAAA,CAAC;oBAC5B,aAAa,EAAE,SAAS,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC,QAAQ,CAC5D,QAAQ,CACT,EAAE;iBACJ,CAAC,CAAA;cAAA;SACH,CAAC;KACH;IACD,QAAQ,EAAE,CAAC,+CAAsB,EAAE,qCAAmB,CAAC;CACxD,CAAC,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export declare const dripAddSubscriberToCampaign: import("@activepieces/pieces-framework").IAction<import("@activepieces/pieces-framework").SecretTextProperty<true>, {
|
|
2
|
-
account_id: import("@activepieces/pieces-framework").DropdownProperty<string, true
|
|
3
|
-
campaign_id: import("@activepieces/pieces-framework").DropdownProperty<string, true
|
|
2
|
+
account_id: import("@activepieces/pieces-framework").DropdownProperty<string, true, import("@activepieces/pieces-framework").SecretTextProperty<true>>;
|
|
3
|
+
campaign_id: import("@activepieces/pieces-framework").DropdownProperty<string, true, import("@activepieces/pieces-framework").SecretTextProperty<true>>;
|
|
4
4
|
subscriber: import("@activepieces/pieces-framework").ShortTextProperty<true>;
|
|
5
5
|
tags: import("@activepieces/pieces-framework").ArrayProperty<false>;
|
|
6
6
|
custom_fields: import("@activepieces/pieces-framework").ObjectProperty<false>;
|
|
@@ -15,6 +15,7 @@ exports.dripAddSubscriberToCampaign = (0, pieces_framework_1.createAction)({
|
|
|
15
15
|
account_id: common_1.dripCommon.account_id,
|
|
16
16
|
campaign_id: pieces_framework_1.Property.Dropdown({
|
|
17
17
|
displayName: 'Email Series Campaign',
|
|
18
|
+
auth: __1.dripAuth,
|
|
18
19
|
refreshers: ['account_id'],
|
|
19
20
|
required: true,
|
|
20
21
|
options: (_a) => tslib_1.__awaiter(void 0, [_a], void 0, function* ({ auth, account_id }) {
|
|
@@ -36,7 +37,7 @@ exports.dripAddSubscriberToCampaign = (0, pieces_framework_1.createAction)({
|
|
|
36
37
|
method: pieces_common_1.HttpMethod.GET,
|
|
37
38
|
url: `${common_1.dripCommon.baseUrl(account_id)}/campaigns`,
|
|
38
39
|
headers: {
|
|
39
|
-
Authorization: `Basic ${Buffer.from(auth).toString('base64')}`,
|
|
40
|
+
Authorization: `Basic ${Buffer.from(auth.secret_text).toString('base64')}`,
|
|
40
41
|
},
|
|
41
42
|
};
|
|
42
43
|
const response = yield pieces_common_1.httpClient.sendRequest(request);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"add-subscriber-to-campaign.action.js","sourceRoot":"","sources":["../../../../../../../../packages/pieces/community/drip/src/lib/actions/add-subscriber-to-campaign.action.ts"],"names":[],"mappings":";;;;AAAA,qEAAwE;AACxE,+DAIqC;AACrC,sCAAuC;AACvC,8BAAkC;AAErB,QAAA,2BAA2B,GAAG,IAAA,+BAAY,EAAC;IACtD,IAAI,EAAE,YAAQ;IACd,IAAI,EAAE,4BAA4B;IAClC,WAAW,EAAE,+CAA+C;IAC5D,WAAW,EAAE,gCAAgC;IAC7C,KAAK,EAAE;QACL,UAAU,EAAE,mBAAU,CAAC,UAAU;QACjC,WAAW,EAAE,2BAAQ,CAAC,QAAQ,CAAC;YAC7B,WAAW,EAAE,uBAAuB;YACpC,UAAU,EAAE,CAAC,YAAY,CAAC;YAC1B,QAAQ,EAAE,IAAI;YACd,OAAO,EAAE,KAA6B,EAAE,oDAAxB,EAAE,IAAI,EAAE,UAAU,EAAE;gBAClC,IAAI,CAAC,IAAI,EAAE,CAAC;oBACV,OAAO;wBACL,QAAQ,EAAE,IAAI;wBACd,OAAO,EAAE,EAAE;wBACX,WAAW,EAAE,8BAA8B;qBAC5C,CAAC;gBACJ,CAAC;gBACD,IAAI,CAAC,UAAU,EAAE,CAAC;oBAChB,OAAO;wBACL,QAAQ,EAAE,IAAI;wBACd,OAAO,EAAE,EAAE;wBACX,WAAW,EAAE,gCAAgC;qBAC9C,CAAC;gBACJ,CAAC;gBACD,MAAM,OAAO,GAAgB;oBAC3B,MAAM,EAAE,0BAAU,CAAC,GAAG;oBACtB,GAAG,EAAE,GAAG,mBAAU,CAAC,OAAO,CAAC,UAAoB,CAAC,YAAY;oBAC5D,OAAO,EAAE;wBACP,aAAa,EAAE,SAAS,MAAM,CAAC,IAAI,CAAC,
|
|
1
|
+
{"version":3,"file":"add-subscriber-to-campaign.action.js","sourceRoot":"","sources":["../../../../../../../../packages/pieces/community/drip/src/lib/actions/add-subscriber-to-campaign.action.ts"],"names":[],"mappings":";;;;AAAA,qEAAwE;AACxE,+DAIqC;AACrC,sCAAuC;AACvC,8BAAkC;AAErB,QAAA,2BAA2B,GAAG,IAAA,+BAAY,EAAC;IACtD,IAAI,EAAE,YAAQ;IACd,IAAI,EAAE,4BAA4B;IAClC,WAAW,EAAE,+CAA+C;IAC5D,WAAW,EAAE,gCAAgC;IAC7C,KAAK,EAAE;QACL,UAAU,EAAE,mBAAU,CAAC,UAAU;QACjC,WAAW,EAAE,2BAAQ,CAAC,QAAQ,CAAC;YAC7B,WAAW,EAAE,uBAAuB;YACpC,IAAI,EAAE,YAAQ;YACd,UAAU,EAAE,CAAC,YAAY,CAAC;YAC1B,QAAQ,EAAE,IAAI;YACd,OAAO,EAAE,KAA6B,EAAE,oDAAxB,EAAE,IAAI,EAAE,UAAU,EAAE;gBAClC,IAAI,CAAC,IAAI,EAAE,CAAC;oBACV,OAAO;wBACL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AAG;qEAAC,EAAE,IAAI,EAAE,UAAU,EAAE;YAC5B,MAAM,OAAO,GAAgB;gBAC3B,MAAM,EAAE,0BAAU,CAAC,IAAI;gBACvB,GAAG,EAAE,GAAG,mBAAU,CAAC,OAAO,CAAC,UAAU,CAAC,UAAU,CAAC,cAC/C,UAAU,CAAC,WACb,cAAc;gBACd,IAAI,EAAE;oBACJ,WAAW,EAAE;wBACX;4BACE,KAAK,EAAE,UAAU,CAAC,UAAU;4BAC5B,IAAI,EAAE,UAAU,CAAC,IAAI;4BACrB,aAAa,EAAE,UAAU,CAAC,aAAa;yBACxC;qBACF;iBACF;gBACD,OAAO,EAAE;oBACP,aAAa,EAAE,mBAAU,CAAC,mBAAmB,CAAC,IAAI,CAAC;iBACpD;gBACD,WAAW,EAAE,EAAE;aAChB,CAAC;YACF,OAAO,MAAM,0BAAU,CAAC,WAAW,CAAwB,OAAO,CAAC,CAAC;QACtE,CAAC;KAAA;CACF,CAAC,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export declare const dripApplyTagToSubscriber: import("@activepieces/pieces-framework").IAction<import("@activepieces/pieces-framework").SecretTextProperty<true>, {
|
|
2
|
-
account_id: import("@activepieces/pieces-framework").DropdownProperty<string, true
|
|
2
|
+
account_id: import("@activepieces/pieces-framework").DropdownProperty<string, true, import("@activepieces/pieces-framework").SecretTextProperty<true>>;
|
|
3
3
|
subscriber: import("@activepieces/pieces-framework").ShortTextProperty<true>;
|
|
4
4
|
tag: import("@activepieces/pieces-framework").ShortTextProperty<true>;
|
|
5
5
|
}>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export declare const dripUpsertSubscriberAction: import("@activepieces/pieces-framework").IAction<import("@activepieces/pieces-framework").SecretTextProperty<true>, {
|
|
2
|
-
account_id: import("@activepieces/pieces-framework").DropdownProperty<string, true
|
|
2
|
+
account_id: import("@activepieces/pieces-framework").DropdownProperty<string, true, import("@activepieces/pieces-framework").SecretTextProperty<true>>;
|
|
3
3
|
subscriber: import("@activepieces/pieces-framework").ShortTextProperty<true>;
|
|
4
4
|
tags: import("@activepieces/pieces-framework").ArrayProperty<false>;
|
|
5
5
|
custom_fields: import("@activepieces/pieces-framework").ObjectProperty<false>;
|
|
@@ -1,8 +1,10 @@
|
|
|
1
|
+
import { AppConnectionValueForAuthProperty } from '@activepieces/pieces-framework';
|
|
2
|
+
import { dripAuth } from '../..';
|
|
1
3
|
export declare const dripCommon: {
|
|
2
4
|
baseUrl: (accountId: string) => string;
|
|
3
|
-
account_id: import("@activepieces/pieces-framework").DropdownProperty<string, true
|
|
5
|
+
account_id: import("@activepieces/pieces-framework").DropdownProperty<string, true, import("@activepieces/pieces-framework").SecretTextProperty<true>>;
|
|
4
6
|
subscriber: import("@activepieces/pieces-framework").ShortTextProperty<true>;
|
|
5
7
|
tags: import("@activepieces/pieces-framework").ArrayProperty<false>;
|
|
6
8
|
custom_fields: import("@activepieces/pieces-framework").ObjectProperty<false>;
|
|
7
|
-
authorizationHeader: (apiKey:
|
|
9
|
+
authorizationHeader: (apiKey: AppConnectionValueForAuthProperty<typeof dripAuth>) => string;
|
|
8
10
|
};
|
package/src/lib/common/index.js
CHANGED
|
@@ -4,11 +4,13 @@ exports.dripCommon = void 0;
|
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
5
|
const pieces_framework_1 = require("@activepieces/pieces-framework");
|
|
6
6
|
const pieces_common_1 = require("@activepieces/pieces-common");
|
|
7
|
+
const __1 = require("../..");
|
|
7
8
|
exports.dripCommon = {
|
|
8
9
|
baseUrl: (accountId) => {
|
|
9
10
|
return `https://api.getdrip.com/v2/${accountId}`;
|
|
10
11
|
},
|
|
11
12
|
account_id: pieces_framework_1.Property.Dropdown({
|
|
13
|
+
auth: __1.dripAuth,
|
|
12
14
|
displayName: 'Account',
|
|
13
15
|
required: true,
|
|
14
16
|
refreshers: [],
|
|
@@ -24,7 +26,7 @@ exports.dripCommon = {
|
|
|
24
26
|
method: pieces_common_1.HttpMethod.GET,
|
|
25
27
|
url: 'https://api.getdrip.com/v2/accounts',
|
|
26
28
|
headers: {
|
|
27
|
-
Authorization: `Basic ${Buffer.from(auth).toString('base64')}`,
|
|
29
|
+
Authorization: `Basic ${Buffer.from(auth.secret_text).toString('base64')}`,
|
|
28
30
|
},
|
|
29
31
|
};
|
|
30
32
|
const response = yield pieces_common_1.httpClient.sendRequest(request);
|
|
@@ -52,6 +54,6 @@ exports.dripCommon = {
|
|
|
52
54
|
required: false,
|
|
53
55
|
description: 'Custom field data about the subscriber',
|
|
54
56
|
}),
|
|
55
|
-
authorizationHeader: (apiKey) => `Basic ${Buffer.from(apiKey).toString('base64')}`,
|
|
57
|
+
authorizationHeader: (apiKey) => `Basic ${Buffer.from(apiKey.secret_text).toString('base64')}`,
|
|
56
58
|
};
|
|
57
59
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../../../packages/pieces/community/drip/src/lib/common/index.ts"],"names":[],"mappings":";;;;AAAA,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../../../packages/pieces/community/drip/src/lib/common/index.ts"],"names":[],"mappings":";;;;AAAA,qEAA6F;AAC7F,+DAIqC;AACrC,6BAAiC;AAEpB,QAAA,UAAU,GAAG;IACxB,OAAO,EAAE,CAAC,SAAiB,EAAE,EAAE;QAC7B,OAAO,8BAA8B,SAAS,EAAE,CAAC;IACnD,CAAC;IACD,UAAU,EAAE,2BAAQ,CAAC,QAAQ,CAAC;QAC5B,IAAI,EAAE,YAAQ;QACd,WAAW,EAAE,SAAS;QACtB,QAAQ,EAAE,IAAI;QACd,UAAU,EAAE,EAAE;QACd,OAAO,EAAE,KAAiB,EAAE,oDAAZ,EAAE,IAAI,EAAE;YACtB,IAAI,CAAC,IAAI,EAAE,CAAC;gBACV,OAAO;oBACL,QAAQ,EAAE,IAAI;oBACd,OAAO,EAAE,EAAE;oBACX,WAAW,EAAE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|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { TriggerStrategy } from '@activepieces/pieces-framework';
|
|
2
2
|
export declare const dripNewSubscriberEvent: import("@activepieces/pieces-framework").ITrigger<TriggerStrategy.WEBHOOK, import("@activepieces/pieces-framework").SecretTextProperty<true>, {
|
|
3
|
-
account_id: import("@activepieces/pieces-framework").DropdownProperty<string, true
|
|
3
|
+
account_id: import("@activepieces/pieces-framework").DropdownProperty<string, true, import("@activepieces/pieces-framework").SecretTextProperty<true>>;
|
|
4
4
|
}> | import("@activepieces/pieces-framework").ITrigger<TriggerStrategy.POLLING, import("@activepieces/pieces-framework").SecretTextProperty<true>, {
|
|
5
|
-
account_id: import("@activepieces/pieces-framework").DropdownProperty<string, true
|
|
5
|
+
account_id: import("@activepieces/pieces-framework").DropdownProperty<string, true, import("@activepieces/pieces-framework").SecretTextProperty<true>>;
|
|
6
6
|
}> | import("@activepieces/pieces-framework").ITrigger<TriggerStrategy.APP_WEBHOOK, import("@activepieces/pieces-framework").SecretTextProperty<true>, {
|
|
7
|
-
account_id: import("@activepieces/pieces-framework").DropdownProperty<string, true
|
|
7
|
+
account_id: import("@activepieces/pieces-framework").DropdownProperty<string, true, import("@activepieces/pieces-framework").SecretTextProperty<true>>;
|
|
8
8
|
}>;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { TriggerStrategy } from '@activepieces/pieces-framework';
|
|
2
2
|
export declare const dripTagAppliedEvent: import("@activepieces/pieces-framework").ITrigger<TriggerStrategy.WEBHOOK, import("@activepieces/pieces-framework").SecretTextProperty<true>, {
|
|
3
|
-
account_id: import("@activepieces/pieces-framework").DropdownProperty<string, true
|
|
3
|
+
account_id: import("@activepieces/pieces-framework").DropdownProperty<string, true, import("@activepieces/pieces-framework").SecretTextProperty<true>>;
|
|
4
4
|
}> | import("@activepieces/pieces-framework").ITrigger<TriggerStrategy.POLLING, import("@activepieces/pieces-framework").SecretTextProperty<true>, {
|
|
5
|
-
account_id: import("@activepieces/pieces-framework").DropdownProperty<string, true
|
|
5
|
+
account_id: import("@activepieces/pieces-framework").DropdownProperty<string, true, import("@activepieces/pieces-framework").SecretTextProperty<true>>;
|
|
6
6
|
}> | import("@activepieces/pieces-framework").ITrigger<TriggerStrategy.APP_WEBHOOK, import("@activepieces/pieces-framework").SecretTextProperty<true>, {
|
|
7
|
-
account_id: import("@activepieces/pieces-framework").DropdownProperty<string, true
|
|
7
|
+
account_id: import("@activepieces/pieces-framework").DropdownProperty<string, true, import("@activepieces/pieces-framework").SecretTextProperty<true>>;
|
|
8
8
|
}>;
|