@activepieces/piece-savvycal 0.0.2 → 0.1.1
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 +5 -5
- package/src/i18n/de.json +73 -94
- package/src/i18n/es.json +73 -94
- package/src/i18n/fr.json +81 -75
- package/src/i18n/ja.json +73 -94
- package/src/i18n/nl.json +72 -93
- package/src/i18n/pt.json +73 -94
- package/src/i18n/ru.json +74 -0
- package/src/i18n/translation.json +38 -14
- package/src/i18n/vi.json +74 -0
- package/src/i18n/zh.json +40 -61
- package/src/index.d.ts +3 -2
- package/src/index.js +31 -40
- package/src/index.js.map +1 -1
- package/src/lib/actions/cancel-event.d.ts +3 -1
- package/src/lib/actions/cancel-event.js +3 -3
- package/src/lib/actions/cancel-event.js.map +1 -1
- package/src/lib/actions/create-event.d.ts +15 -2
- package/src/lib/actions/create-event.js +169 -24
- package/src/lib/actions/create-event.js.map +1 -1
- package/src/lib/actions/delete-scheduling-link.d.ts +10 -0
- package/src/lib/actions/delete-scheduling-link.js +67 -0
- package/src/lib/actions/delete-scheduling-link.js.map +1 -0
- package/src/lib/actions/duplicate-scheduling-link.d.ts +10 -0
- package/src/lib/actions/duplicate-scheduling-link.js +63 -0
- package/src/lib/actions/duplicate-scheduling-link.js.map +1 -0
- package/src/lib/actions/find-events-by-email.d.ts +3 -1
- package/src/lib/actions/find-events-by-email.js +3 -3
- package/src/lib/actions/find-events-by-email.js.map +1 -1
- package/src/lib/actions/get-current-user.d.ts +3 -1
- package/src/lib/actions/get-current-user.js +3 -3
- package/src/lib/actions/get-current-user.js.map +1 -1
- package/src/lib/actions/get-event.d.ts +3 -1
- package/src/lib/actions/get-event.js +3 -3
- package/src/lib/actions/get-event.js.map +1 -1
- package/src/lib/actions/get-link-slots.d.ts +10 -0
- package/src/lib/actions/get-link-slots.js +70 -0
- package/src/lib/actions/get-link-slots.js.map +1 -0
- package/src/lib/actions/get-scheduling-link.d.ts +10 -0
- package/src/lib/actions/get-scheduling-link.js +63 -0
- package/src/lib/actions/get-scheduling-link.js.map +1 -0
- package/src/lib/actions/get-workflow-rules.d.ts +7 -0
- package/src/lib/actions/get-workflow-rules.js +50 -0
- package/src/lib/actions/get-workflow-rules.js.map +1 -0
- package/src/lib/actions/list-events.d.ts +10 -3
- package/src/lib/actions/list-events.js +76 -24
- package/src/lib/actions/list-events.js.map +1 -1
- package/src/lib/actions/list-scheduling-links.d.ts +7 -1
- package/src/lib/actions/list-scheduling-links.js +30 -17
- package/src/lib/actions/list-scheduling-links.js.map +1 -1
- package/src/lib/actions/list-workflows.d.ts +3 -0
- package/src/lib/actions/list-workflows.js +35 -0
- package/src/lib/actions/list-workflows.js.map +1 -0
- package/src/lib/actions/toggle-scheduling-link.d.ts +10 -0
- package/src/lib/actions/toggle-scheduling-link.js +63 -0
- package/src/lib/actions/toggle-scheduling-link.js.map +1 -0
- package/src/lib/auth.d.ts +6 -0
- package/src/lib/auth.js +60 -0
- package/src/lib/auth.js.map +1 -0
- package/src/lib/common/index.d.ts +28 -0
- package/src/lib/common/index.js +98 -29
- package/src/lib/common/index.js.map +1 -1
- package/src/lib/triggers/new-event.d.ts +36 -4
- package/src/lib/triggers/new-event.js +85 -18
- package/src/lib/triggers/new-event.js.map +1 -1
- package/src/lib/triggers/new-poll-response.d.ts +18 -0
- package/src/lib/triggers/new-poll-response.js +81 -0
- package/src/lib/triggers/new-poll-response.js.map +1 -0
- package/src/lib/triggers/workflow-action-triggered.d.ts +10 -0
- package/src/lib/triggers/workflow-action-triggered.js +65 -0
- package/src/lib/triggers/workflow-action-triggered.js.map +1 -0
- package/src/lib/common/webhook-trigger-factory.d.ts +0 -7
- package/src/lib/common/webhook-trigger-factory.js +0 -96
- package/src/lib/common/webhook-trigger-factory.js.map +0 -1
- package/src/lib/triggers/booking-canceled.d.ts +0 -1
- package/src/lib/triggers/booking-canceled.js +0 -11
- package/src/lib/triggers/booking-canceled.js.map +0 -1
- package/src/lib/triggers/booking-rescheduled.d.ts +0 -1
- package/src/lib/triggers/booking-rescheduled.js +0 -11
- package/src/lib/triggers/booking-rescheduled.js.map +0 -1
- package/src/lib/triggers/new-booking.d.ts +0 -1
- package/src/lib/triggers/new-booking.js +0 -11
- package/src/lib/triggers/new-booking.js.map +0 -1
|
@@ -4,9 +4,9 @@ exports.findEventsByEmailAction = void 0;
|
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
5
|
const pieces_framework_1 = require("@activepieces/pieces-framework");
|
|
6
6
|
const common_1 = require("../common");
|
|
7
|
-
const
|
|
7
|
+
const auth_1 = require("../auth");
|
|
8
8
|
exports.findEventsByEmailAction = (0, pieces_framework_1.createAction)({
|
|
9
|
-
auth:
|
|
9
|
+
auth: auth_1.savvyCalAuth,
|
|
10
10
|
name: 'find_events_by_email',
|
|
11
11
|
displayName: 'Find Events by Attendee Email',
|
|
12
12
|
description: "Returns all events where the attendee's email matches the given address.",
|
|
@@ -29,7 +29,7 @@ exports.findEventsByEmailAction = (0, pieces_framework_1.createAction)({
|
|
|
29
29
|
},
|
|
30
30
|
run(context) {
|
|
31
31
|
return tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
32
|
-
const token = context.auth
|
|
32
|
+
const token = (0, auth_1.getToken)(context.auth);
|
|
33
33
|
const { attendee_email, start_after, start_before } = context.propsValue;
|
|
34
34
|
const queryParams = {};
|
|
35
35
|
if (start_after)
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"find-events-by-email.js","sourceRoot":"","sources":["../../../../src/lib/actions/find-events-by-email.ts"],"names":[],"mappings":";;;;AAAA,qEAAwE;AACxE,sCAA+E;AAC/E,
|
|
1
|
+
{"version":3,"file":"find-events-by-email.js","sourceRoot":"","sources":["../../../../src/lib/actions/find-events-by-email.ts"],"names":[],"mappings":";;;;AAAA,qEAAwE;AACxE,sCAA+E;AAC/E,kCAAiD;AAEpC,QAAA,uBAAuB,GAAG,IAAA,+BAAY,EAAC;IAClD,IAAI,EAAE,mBAAY;IA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,KAAK,0CAAE,WAAW,EAAE,MAAK,eAAe,CAAA,EAAA,CAAC,CAAA,EAAA,CAAC;iBACnF,GAAG,CAAC,qBAAY,CAAC,CAAC;QACvB,CAAC;KAAA;CACF,CAAC,CAAC"}
|
|
@@ -1 +1,3 @@
|
|
|
1
|
-
export declare const getCurrentUserAction: import("@activepieces/pieces-framework").IAction<import("@activepieces/pieces-framework").
|
|
1
|
+
export declare const getCurrentUserAction: import("@activepieces/pieces-framework").IAction<(import("@activepieces/pieces-framework").OAuth2Property<import("@activepieces/pieces-framework").OAuth2Props> | import("@activepieces/pieces-framework").CustomAuthProperty<{
|
|
2
|
+
token: import("@activepieces/pieces-framework").SecretTextProperty<true>;
|
|
3
|
+
}>)[], {}>;
|
|
@@ -5,9 +5,9 @@ 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
7
|
const common_1 = require("../common");
|
|
8
|
-
const
|
|
8
|
+
const auth_1 = require("../auth");
|
|
9
9
|
exports.getCurrentUserAction = (0, pieces_framework_1.createAction)({
|
|
10
|
-
auth:
|
|
10
|
+
auth: auth_1.savvyCalAuth,
|
|
11
11
|
name: 'get_current_user',
|
|
12
12
|
displayName: 'Get Current User',
|
|
13
13
|
description: 'Retrieves the profile of the currently authenticated SavvyCal user.',
|
|
@@ -16,7 +16,7 @@ exports.getCurrentUserAction = (0, pieces_framework_1.createAction)({
|
|
|
16
16
|
return tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
17
17
|
var _a, _b, _c;
|
|
18
18
|
const response = yield (0, common_1.savvyCalApiCall)({
|
|
19
|
-
token: context.auth
|
|
19
|
+
token: (0, auth_1.getToken)(context.auth),
|
|
20
20
|
method: pieces_common_1.HttpMethod.GET,
|
|
21
21
|
path: '/me',
|
|
22
22
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get-current-user.js","sourceRoot":"","sources":["../../../../src/lib/actions/get-current-user.ts"],"names":[],"mappings":";;;;AAAA,qEAA8D;AAC9D,+DAAyD;AACzD,sCAA4C;AAC5C,
|
|
1
|
+
{"version":3,"file":"get-current-user.js","sourceRoot":"","sources":["../../../../src/lib/actions/get-current-user.ts"],"names":[],"mappings":";;;;AAAA,qEAA8D;AAC9D,+DAAyD;AACzD,sCAA4C;AAC5C,kCAAiD;AAEpC,QAAA,oBAAoB,GAAG,IAAA,+BAAY,EAAC;IAC/C,IAAI,EAAE,mBAAY;IAClB,IAAI,EAAE,kBAAkB;IACxB,WAAW,EAAE,kBAAkB;IAC/B,WAAW,EAAE,qEAAqE;IAClF,KAAK,EAAE,EAAE;IACH,GAAG,CAAC,OAAO;;;YACf,MAAM,QAAQ,GAAG,MAAM,IAAA,wBAAe,EAQnC;gBACD,KAAK,EAAE,IAAA,eAAQ,EAAC,OAAO,CAAC,IAAI,CAAC;gBAC7B,MAAM,EAAE,0BAAU,CAAC,GAAG;gBACtB,IAAI,EAAE,KAAK;aACZ,CAAC,CAAC;YAEH,MAAM,IAAI,GAAG,QAAQ,CAAC,IAAI,CAAC;YAC3B,OAAO;gBACL,EAAE,EAAE,IAAI,CAAC,EAAE;gBACX,IAAI,EAAE,IAAI,CAAC,IAAI;gBACf,KAAK,EAAE,IAAI,CAAC,KAAK;gBACjB,IAAI,EAAE,MAAA,IAAI,CAAC,IAAI,mCAAI,IAAI;gBACvB,SAAS,EAAE,MAAA,IAAI,CAAC,SAAS,mCAAI,IAAI;gBACjC,UAAU,EAAE,IAAI,CAAC,UAAU;gBAC3B,UAAU,EAAE,MAAA,IAAI,CAAC,UAAU,mCAAI,IAAI;aACpC,CAAC;QACJ,CAAC;KAAA;CACF,CAAC,CAAC"}
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
-
export declare const getEventAction: import("@activepieces/pieces-framework").IAction<import("@activepieces/pieces-framework").
|
|
1
|
+
export declare const getEventAction: import("@activepieces/pieces-framework").IAction<(import("@activepieces/pieces-framework").OAuth2Property<import("@activepieces/pieces-framework").OAuth2Props> | import("@activepieces/pieces-framework").CustomAuthProperty<{
|
|
2
|
+
token: import("@activepieces/pieces-framework").SecretTextProperty<true>;
|
|
3
|
+
}>)[], {
|
|
2
4
|
event_id: import("@activepieces/pieces-framework").ShortTextProperty<true>;
|
|
3
5
|
}>;
|
|
@@ -5,9 +5,9 @@ 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
7
|
const common_1 = require("../common");
|
|
8
|
-
const
|
|
8
|
+
const auth_1 = require("../auth");
|
|
9
9
|
exports.getEventAction = (0, pieces_framework_1.createAction)({
|
|
10
|
-
auth:
|
|
10
|
+
auth: auth_1.savvyCalAuth,
|
|
11
11
|
name: 'get_event',
|
|
12
12
|
displayName: 'Get Event',
|
|
13
13
|
description: 'Retrieves the details of a specific scheduled meeting by its ID.',
|
|
@@ -21,7 +21,7 @@ exports.getEventAction = (0, pieces_framework_1.createAction)({
|
|
|
21
21
|
run(context) {
|
|
22
22
|
return tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
23
23
|
const response = yield (0, common_1.savvyCalApiCall)({
|
|
24
|
-
token: context.auth
|
|
24
|
+
token: (0, auth_1.getToken)(context.auth),
|
|
25
25
|
method: pieces_common_1.HttpMethod.GET,
|
|
26
26
|
path: `/events/${context.propsValue.event_id}`,
|
|
27
27
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get-event.js","sourceRoot":"","sources":["../../../../src/lib/actions/get-event.ts"],"names":[],"mappings":";;;;AAAA,qEAAwE;AACxE,+DAAyD;AACzD,sCAAyE;AACzE,
|
|
1
|
+
{"version":3,"file":"get-event.js","sourceRoot":"","sources":["../../../../src/lib/actions/get-event.ts"],"names":[],"mappings":";;;;AAAA,qEAAwE;AACxE,+DAAyD;AACzD,sCAAyE;AACzE,kCAAiD;AAEpC,QAAA,cAAc,GAAG,IAAA,+BAAY,EAAC;IACzC,IAAI,EAAE,mBAAY;IAClB,IAAI,EAAE,WAAW;IACjB,WAAW,EAAE,WAAW;IACxB,WAAW,EAAE,kEAAkE;IAC/E,KAAK,EAAE;QACL,QAAQ,EAAE,2BAAQ,CAAC,SAAS,CAAC;YAC3B,WAAW,EAAE,UAAU;YACvB,WAAW,EAAE,oIAAoI;YACjJ,QAAQ,EAAE,IAAI;SACf,CAAC;KACH;IACK,GAAG,CAAC,OAAO;;YACf,MAAM,QAAQ,GAAG,MAAM,IAAA,wBAAe,EAAgB;gBACpD,KAAK,EAAE,IAAA,eAAQ,EAAC,OAAO,CAAC,IAAI,CAAC;gBAC7B,MAAM,EAAE,0BAAU,CAAC,GAAG;gBACtB,IAAI,EAAE,WAAW,OAAO,CAAC,UAAU,CAAC,QAAQ,EAAE;aAC/C,CAAC,CAAC;YAEH,OAAO,IAAA,qBAAY,EAAC,QAAQ,CAAC,IAAI,CAAC,CAAC;QACrC,CAAC;KAAA;CACF,CAAC,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export declare const getLinkSlotsAction: import("@activepieces/pieces-framework").IAction<(import("@activepieces/pieces-framework").OAuth2Property<import("@activepieces/pieces-framework").OAuth2Props> | import("@activepieces/pieces-framework").CustomAuthProperty<{
|
|
2
|
+
token: import("@activepieces/pieces-framework").SecretTextProperty<true>;
|
|
3
|
+
}>)[], {
|
|
4
|
+
team_id: import("@activepieces/pieces-framework").DropdownProperty<string, false, (import("@activepieces/pieces-framework").OAuth2Property<import("@activepieces/pieces-framework").OAuth2Props> | import("@activepieces/pieces-framework").CustomAuthProperty<{
|
|
5
|
+
token: import("@activepieces/pieces-framework").SecretTextProperty<true>;
|
|
6
|
+
}>)[]>;
|
|
7
|
+
link_id: import("@activepieces/pieces-framework").DropdownProperty<string, true, (import("@activepieces/pieces-framework").OAuth2Property<import("@activepieces/pieces-framework").OAuth2Props> | import("@activepieces/pieces-framework").CustomAuthProperty<{
|
|
8
|
+
token: import("@activepieces/pieces-framework").SecretTextProperty<true>;
|
|
9
|
+
}>)[]>;
|
|
10
|
+
}>;
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.getLinkSlotsAction = void 0;
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
const pieces_framework_1 = require("@activepieces/pieces-framework");
|
|
6
|
+
const pieces_common_1 = require("@activepieces/pieces-common");
|
|
7
|
+
const common_1 = require("../common");
|
|
8
|
+
const auth_1 = require("../auth");
|
|
9
|
+
exports.getLinkSlotsAction = (0, pieces_framework_1.createAction)({
|
|
10
|
+
auth: auth_1.savvyCalAuth,
|
|
11
|
+
name: 'get_link_slots',
|
|
12
|
+
displayName: 'Get Available Slots',
|
|
13
|
+
description: 'Returns available time slots for booking on a scheduling link. Useful for displaying availability or for picking a slot before calling Create Event.',
|
|
14
|
+
props: {
|
|
15
|
+
team_id: pieces_framework_1.Property.Dropdown({
|
|
16
|
+
auth: auth_1.savvyCalAuth,
|
|
17
|
+
displayName: 'Team',
|
|
18
|
+
description: 'Filter scheduling links by team. Leave empty to show all teams.',
|
|
19
|
+
refreshers: [],
|
|
20
|
+
required: false,
|
|
21
|
+
options: (_a) => tslib_1.__awaiter(void 0, [_a], void 0, function* ({ auth }) {
|
|
22
|
+
if (!auth)
|
|
23
|
+
return { disabled: true, options: [], placeholder: 'Please connect your account first' };
|
|
24
|
+
try {
|
|
25
|
+
const options = yield (0, common_1.buildTeamOptions)((0, auth_1.getToken)(auth));
|
|
26
|
+
return { disabled: false, options };
|
|
27
|
+
}
|
|
28
|
+
catch (_b) {
|
|
29
|
+
return { disabled: true, options: [], placeholder: 'Failed to load teams.' };
|
|
30
|
+
}
|
|
31
|
+
}),
|
|
32
|
+
}),
|
|
33
|
+
link_id: pieces_framework_1.Property.Dropdown({
|
|
34
|
+
auth: auth_1.savvyCalAuth,
|
|
35
|
+
displayName: 'Scheduling Link',
|
|
36
|
+
description: 'Select the scheduling link to query slots for.',
|
|
37
|
+
refreshers: ['team_id'],
|
|
38
|
+
required: true,
|
|
39
|
+
options: (_a) => tslib_1.__awaiter(void 0, [_a], void 0, function* ({ auth, team_id }) {
|
|
40
|
+
if (!auth)
|
|
41
|
+
return { disabled: true, options: [], placeholder: 'Please connect your account first' };
|
|
42
|
+
try {
|
|
43
|
+
const options = yield (0, common_1.buildLinkOptions)((0, auth_1.getToken)(auth), team_id);
|
|
44
|
+
return { disabled: false, options };
|
|
45
|
+
}
|
|
46
|
+
catch (_b) {
|
|
47
|
+
return { disabled: true, options: [], placeholder: 'Failed to load scheduling links.' };
|
|
48
|
+
}
|
|
49
|
+
}),
|
|
50
|
+
}),
|
|
51
|
+
},
|
|
52
|
+
run(context) {
|
|
53
|
+
return tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
54
|
+
var _a;
|
|
55
|
+
const response = yield (0, common_1.savvyCalApiCall)({
|
|
56
|
+
token: (0, auth_1.getToken)(context.auth),
|
|
57
|
+
method: pieces_common_1.HttpMethod.GET,
|
|
58
|
+
path: `/links/${context.propsValue.link_id}/slots`,
|
|
59
|
+
});
|
|
60
|
+
const slots = Array.isArray(response.body) ? response.body : (_a = response.body.entries) !== null && _a !== void 0 ? _a : [];
|
|
61
|
+
return slots.map((slot) => ({
|
|
62
|
+
start_at: slot.start_at,
|
|
63
|
+
end_at: slot.end_at,
|
|
64
|
+
duration_minutes: slot.duration,
|
|
65
|
+
rank: slot.rank,
|
|
66
|
+
}));
|
|
67
|
+
});
|
|
68
|
+
},
|
|
69
|
+
});
|
|
70
|
+
//# sourceMappingURL=get-link-slots.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-link-slots.js","sourceRoot":"","sources":["../../../../src/lib/actions/get-link-slots.ts"],"names":[],"mappings":";;;;AAAA,qEAAwE;AACxE,+DAAyD;AACzD,sCAAgF;AAChF,kCAAiD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property<import("@activepieces/pieces-framework").OAuth2Props> | import("@activepieces/pieces-framework").CustomAuthProperty<{
|
|
2
|
+
token: import("@activepieces/pieces-framework").SecretTextProperty<true>;
|
|
3
|
+
}>)[], {
|
|
4
|
+
team_id: import("@activepieces/pieces-framework").DropdownProperty<string, false, (import("@activepieces/pieces-framework").OAuth2Property<import("@activepieces/pieces-framework").OAuth2Props> | import("@activepieces/pieces-framework").CustomAuthProperty<{
|
|
5
|
+
token: import("@activepieces/pieces-framework").SecretTextProperty<true>;
|
|
6
|
+
}>)[]>;
|
|
7
|
+
link_id: import("@activepieces/pieces-framework").DropdownProperty<string, true, (import("@activepieces/pieces-framework").OAuth2Property<import("@activepieces/pieces-framework").OAuth2Props> | import("@activepieces/pieces-framework").CustomAuthProperty<{
|
|
8
|
+
token: import("@activepieces/pieces-framework").SecretTextProperty<true>;
|
|
9
|
+
}>)[]>;
|
|
10
|
+
}>;
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.getSchedulingLinkAction = void 0;
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
const pieces_framework_1 = require("@activepieces/pieces-framework");
|
|
6
|
+
const pieces_common_1 = require("@activepieces/pieces-common");
|
|
7
|
+
const common_1 = require("../common");
|
|
8
|
+
const auth_1 = require("../auth");
|
|
9
|
+
exports.getSchedulingLinkAction = (0, pieces_framework_1.createAction)({
|
|
10
|
+
auth: auth_1.savvyCalAuth,
|
|
11
|
+
name: 'get_scheduling_link',
|
|
12
|
+
displayName: 'Get Scheduling Link',
|
|
13
|
+
description: 'Retrieves the details of a specific scheduling link by its ID.',
|
|
14
|
+
props: {
|
|
15
|
+
team_id: pieces_framework_1.Property.Dropdown({
|
|
16
|
+
auth: auth_1.savvyCalAuth,
|
|
17
|
+
displayName: 'Team',
|
|
18
|
+
description: 'Filter scheduling links by team. Leave empty to show all teams.',
|
|
19
|
+
refreshers: [],
|
|
20
|
+
required: false,
|
|
21
|
+
options: (_a) => tslib_1.__awaiter(void 0, [_a], void 0, function* ({ auth }) {
|
|
22
|
+
if (!auth)
|
|
23
|
+
return { disabled: true, options: [], placeholder: 'Please connect your account first' };
|
|
24
|
+
try {
|
|
25
|
+
const options = yield (0, common_1.buildTeamOptions)((0, auth_1.getToken)(auth));
|
|
26
|
+
return { disabled: false, options };
|
|
27
|
+
}
|
|
28
|
+
catch (_b) {
|
|
29
|
+
return { disabled: true, options: [], placeholder: 'Failed to load teams.' };
|
|
30
|
+
}
|
|
31
|
+
}),
|
|
32
|
+
}),
|
|
33
|
+
link_id: pieces_framework_1.Property.Dropdown({
|
|
34
|
+
auth: auth_1.savvyCalAuth,
|
|
35
|
+
displayName: 'Scheduling Link',
|
|
36
|
+
description: 'Select the scheduling link to retrieve.',
|
|
37
|
+
refreshers: ['team_id'],
|
|
38
|
+
required: true,
|
|
39
|
+
options: (_a) => tslib_1.__awaiter(void 0, [_a], void 0, function* ({ auth, team_id }) {
|
|
40
|
+
if (!auth)
|
|
41
|
+
return { disabled: true, options: [], placeholder: 'Please connect your account first' };
|
|
42
|
+
try {
|
|
43
|
+
const options = yield (0, common_1.buildLinkOptions)((0, auth_1.getToken)(auth), team_id);
|
|
44
|
+
return { disabled: false, options };
|
|
45
|
+
}
|
|
46
|
+
catch (_b) {
|
|
47
|
+
return { disabled: true, options: [], placeholder: 'Failed to load scheduling links.' };
|
|
48
|
+
}
|
|
49
|
+
}),
|
|
50
|
+
}),
|
|
51
|
+
},
|
|
52
|
+
run(context) {
|
|
53
|
+
return tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
54
|
+
const response = yield (0, common_1.savvyCalApiCall)({
|
|
55
|
+
token: (0, auth_1.getToken)(context.auth),
|
|
56
|
+
method: pieces_common_1.HttpMethod.GET,
|
|
57
|
+
path: `/links/${context.propsValue.link_id}`,
|
|
58
|
+
});
|
|
59
|
+
return (0, common_1.flattenLink)(response.body);
|
|
60
|
+
});
|
|
61
|
+
},
|
|
62
|
+
});
|
|
63
|
+
//# sourceMappingURL=get-scheduling-link.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-scheduling-link.js","sourceRoot":"","sources":["../../../../src/lib/actions/get-scheduling-link.ts"],"names":[],"mappings":";;;;AAAA,qEAAwE;AACxE,+DAAyD;AACzD,sCAMmB;AACnB,kCAAiD;AAEpC,QAAA,uBAAuB,GAAG,IAAA,+BAAY,EAAC;IAClD,IAAI,EAAE,mBAAY;IAClB,IAAI,EAAE,qBAAqB;IAC3B,WAAW,EAAE,qBAAqB;IAClC,WAAW,EAAE,gEAAgE;IAC7E,KAAK,EAAE;QACL,OAAO,EAAE,2BAAQ,CAAC,QAAQ,CAAC;YACzB,IAAI,EAAE,mBAAY;YAClB,WAAW,EAAE,MAAM;YACnB,WAAW,EAAE,iEAAiE;YAC9E,UAAU,EAAE,EAAE;YACd,QAAQ,EAAE,KAAK;YACf,OAAO,EAAE,KAAiB,EAAE,oDAAZ,EAAE,IAAI,EAAE;gBACtB,IAAI,CAAC,IAAI;oBAAE,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,OAAO,EAAE,EAAE,EAAE,WAAW,EAAE,mCAAmC,EAAE,CAAC;gBACpG,IAAI,CAAC;oBACH,MAAM,OAAO,GAAG,MAAM,IAAA,yBAAgB,EAAC,IAAA,eAAQ,EAAC,IAAI,CAAC,CAAC,CAAC;oBACvD,OAAO,EAAE,QAAQ,EAAE,KAAK,EAAE,OAAO,EAAE,CAAC;gBACtC,CAAC;gBAAC,WAAM,CAAC;oBACP,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,OAAO,EAAE,EAAE,EAAE,WAAW,EAAE,uBAAuB,EAAE,CAAC;gBAC/E,CAAC;YACH,CAAC,CAAA;SACF,CAAC;QACF,OAAO,EAAE,2BAAQ,CAAC,QAAQ,CAAC;YACzB,IAAI,EAAE,mBAAY;YAClB,WAAW,EAAE,iBAAiB;YAC9B,WAAW,EAAE,yCAAyC;YACtD,UAAU,EAAE,CAAC,SAAS,CAAC;YACvB,QAAQ,EAAE,IAAI;YACd,OAAO,EAAE,KAA0B,EAAE,oDAArB,EAAE,IAAI,EAAE,OAAO,EAAE;gBAC/B,IAAI,CAAC,IAAI;oBAAE,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,OAAO,EAAE,EAAE,EAAE,WAAW,EAAE,mCAAmC,EAAE,CAAC;gBACpG,IAAI,CAAC;oBACH,MAAM,OAAO,GAAG,MAAM,IAAA,yBAAgB,EAAC,IAAA,eAAQ,EAAC,IAAI,CAAC,EAAE,OAAwB,CAAC,CAAC;oBACjF,OAAO,EAAE,QAAQ,EAAE,KAAK,EAAE,OAAO,EAAE,CAAC;gBACtC,CAAC;gBAAC,WAAM,CAAC;oBACP,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,OAAO,EAAE,EAAE,EAAE,WAAW,EAAE,kCAAkC,EAAE,CAAC;gBAC1F,CAAC;YACH,CAAC,CAAA;SACF,CAAC;KACH;IACK,GAAG,CAAC,OAAO;;YACf,MAAM,QAAQ,GAAG,MAAM,IAAA,wBAAe,EAAyB;gBAC7D,KAAK,EAAE,IAAA,eAAQ,EAAC,OAAO,CAAC,IAAI,CAAC;gBAC7B,MAAM,EAAE,0BAAU,CAAC,GAAG;gBACtB,IAAI,EAAE,UAAU,OAAO,CAAC,UAAU,CAAC,OAAO,EAAE;aAC7C,CAAC,CAAC;YACH,OAAO,IAAA,oBAAW,EAAC,QAAQ,CAAC,IAAI,CAAC,CAAC;QACpC,CAAC;KAAA;CACF,CAAC,CAAC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export declare const getWorkflowRulesAction: import("@activepieces/pieces-framework").IAction<(import("@activepieces/pieces-framework").OAuth2Property<import("@activepieces/pieces-framework").OAuth2Props> | import("@activepieces/pieces-framework").CustomAuthProperty<{
|
|
2
|
+
token: import("@activepieces/pieces-framework").SecretTextProperty<true>;
|
|
3
|
+
}>)[], {
|
|
4
|
+
workflow_id: import("@activepieces/pieces-framework").DropdownProperty<string, true, (import("@activepieces/pieces-framework").OAuth2Property<import("@activepieces/pieces-framework").OAuth2Props> | import("@activepieces/pieces-framework").CustomAuthProperty<{
|
|
5
|
+
token: import("@activepieces/pieces-framework").SecretTextProperty<true>;
|
|
6
|
+
}>)[]>;
|
|
7
|
+
}>;
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.getWorkflowRulesAction = void 0;
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
const pieces_framework_1 = require("@activepieces/pieces-framework");
|
|
6
|
+
const pieces_common_1 = require("@activepieces/pieces-common");
|
|
7
|
+
const common_1 = require("../common");
|
|
8
|
+
const auth_1 = require("../auth");
|
|
9
|
+
exports.getWorkflowRulesAction = (0, pieces_framework_1.createAction)({
|
|
10
|
+
auth: auth_1.savvyCalAuth,
|
|
11
|
+
name: 'get_workflow_rules',
|
|
12
|
+
displayName: 'Get Workflow Rules',
|
|
13
|
+
description: 'Returns the rules configured for a specific workflow.',
|
|
14
|
+
props: {
|
|
15
|
+
workflow_id: pieces_framework_1.Property.Dropdown({
|
|
16
|
+
auth: auth_1.savvyCalAuth,
|
|
17
|
+
displayName: 'Workflow',
|
|
18
|
+
description: 'Select the workflow whose rules you want to retrieve.',
|
|
19
|
+
refreshers: [],
|
|
20
|
+
required: true,
|
|
21
|
+
options: (_a) => tslib_1.__awaiter(void 0, [_a], void 0, function* ({ auth }) {
|
|
22
|
+
if (!auth)
|
|
23
|
+
return { disabled: true, options: [], placeholder: 'Please connect your account first' };
|
|
24
|
+
try {
|
|
25
|
+
const options = yield (0, common_1.buildWorkflowOptions)((0, auth_1.getToken)(auth));
|
|
26
|
+
return { disabled: false, options };
|
|
27
|
+
}
|
|
28
|
+
catch (_b) {
|
|
29
|
+
return { disabled: true, options: [], placeholder: 'Failed to load workflows.' };
|
|
30
|
+
}
|
|
31
|
+
}),
|
|
32
|
+
}),
|
|
33
|
+
},
|
|
34
|
+
run(context) {
|
|
35
|
+
return tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
36
|
+
var _a;
|
|
37
|
+
const response = yield (0, common_1.savvyCalApiCall)({
|
|
38
|
+
token: (0, auth_1.getToken)(context.auth),
|
|
39
|
+
method: pieces_common_1.HttpMethod.GET,
|
|
40
|
+
path: `/workflows/${context.propsValue.workflow_id}/rules`,
|
|
41
|
+
});
|
|
42
|
+
const rules = Array.isArray(response.body) ? response.body : (_a = response.body.entries) !== null && _a !== void 0 ? _a : [];
|
|
43
|
+
return {
|
|
44
|
+
workflow_id: context.propsValue.workflow_id,
|
|
45
|
+
rules,
|
|
46
|
+
};
|
|
47
|
+
});
|
|
48
|
+
},
|
|
49
|
+
});
|
|
50
|
+
//# sourceMappingURL=get-workflow-rules.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-workflow-rules.js","sourceRoot":"","sources":["../../../../src/lib/actions/get-workflow-rules.ts"],"names":[],"mappings":";;;;AAAA,qEAAwE;AACxE,+DAAyD;AACzD,sCAAkE;AAClE,kCAAiD;AAUpC,QAAA,sBAAsB,GAAG,IAAA,+BAAY,EAAC;IACjD,IAAI,EAAE,mBAAY;IAClB,IAAI,EAAE,oBAAoB;IAC1B,WAAW,EAAE,oBAAoB;IACjC,WAAW,EAAE,uDAAuD;IACpE,KAAK,EAAE;QACL,WAAW,EAAE,2BAAQ,CAAC,QAAQ,CAAC;YAC7B,IAAI,EAAE,mBAAY;YAClB,WAAW,EAAE,UAAU;YACvB,WAAW,EAAE,uDAAuD;YACpE,UAAU,EAAE,EAAE;YACd,QAAQ,EAAE,IAAI;YACd,OAAO,EAAE,KAAiB,EAAE,oDAAZ,EAAE,IAAI,EAAE;gBACtB,IAAI,CAAC,IAAI;oBAAE,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,OAAO,EAAE,EAAE,EAAE,WAAW,EAAE,mCAAmC,EAAE,CAAC;gBACpG,IAAI,CAAC;oBACH,MAAM,OAAO,GAAG,MAAM,IAAA,6BAAoB,EAAC,IAAA,eAAQ,EAAC,IAAI,CAAC,CAAC,CAAC;oBAC3D,OAAO,EAAE,QAAQ,EAAE,KAAK,EAAE,OAAO,EAAE,CAAC;gBACtC,CAAC;gBAAC,WAAM,CAAC;oBACP,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,OAAO,EAAE,EAAE,EAAE,WAAW,EAAE,2BAA2B,EAAE,CAAC;gBACnF,CAAC;YACH,CAAC,CAAA;SACF,CAAC;KACH;IACK,GAAG,CAAC,OAAO;;;YACf,MAAM,QAAQ,GAAG,MAAM,IAAA,wBAAe,EAA+D;gBACnG,KAAK,EAAE,IAAA,eAAQ,EAAC,OAAO,CAAC,IAAI,CAAC;gBAC7B,MAAM,EAAE,0BAAU,CAAC,GAAG;gBACtB,IAAI,EAAE,cAAc,OAAO,CAAC,UAAU,CAAC,WAAW,QAAQ;aAC3D,CAAC,CAAC;YACH,MAAM,KAAK,GAAG,KAAK,CAAC,OAAO,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC,CAAC,MAAA,QAAQ,CAAC,IAAI,CAAC,OAAO,mCAAI,EAAE,CAAC;YACzF,OAAO;gBACL,WAAW,EAAE,OAAO,CAAC,UAAU,CAAC,WAAW;gBAC3C,KAAK;aACN,CAAC;QACJ,CAAC;KAAA;CACF,CAAC,CAAC"}
|
|
@@ -1,7 +1,14 @@
|
|
|
1
|
-
export declare const listEventsAction: import("@activepieces/pieces-framework").IAction<import("@activepieces/pieces-framework").
|
|
2
|
-
|
|
1
|
+
export declare const listEventsAction: import("@activepieces/pieces-framework").IAction<(import("@activepieces/pieces-framework").OAuth2Property<import("@activepieces/pieces-framework").OAuth2Props> | import("@activepieces/pieces-framework").CustomAuthProperty<{
|
|
2
|
+
token: import("@activepieces/pieces-framework").SecretTextProperty<true>;
|
|
3
|
+
}>)[], {
|
|
4
|
+
states: import("@activepieces/pieces-framework").StaticMultiSelectDropdownProperty<string, false>;
|
|
3
5
|
start_after: import("@activepieces/pieces-framework").DateTimeProperty<false>;
|
|
4
6
|
start_before: import("@activepieces/pieces-framework").DateTimeProperty<false>;
|
|
5
|
-
|
|
7
|
+
team_id: import("@activepieces/pieces-framework").DropdownProperty<string, false, (import("@activepieces/pieces-framework").OAuth2Property<import("@activepieces/pieces-framework").OAuth2Props> | import("@activepieces/pieces-framework").CustomAuthProperty<{
|
|
8
|
+
token: import("@activepieces/pieces-framework").SecretTextProperty<true>;
|
|
9
|
+
}>)[]>;
|
|
10
|
+
link_ids: import("@activepieces/pieces-framework").MultiSelectDropdownProperty<string, false, (import("@activepieces/pieces-framework").OAuth2Property<import("@activepieces/pieces-framework").OAuth2Props> | import("@activepieces/pieces-framework").CustomAuthProperty<{
|
|
11
|
+
token: import("@activepieces/pieces-framework").SecretTextProperty<true>;
|
|
12
|
+
}>)[]>;
|
|
6
13
|
limit: import("@activepieces/pieces-framework").NumberProperty<false>;
|
|
7
14
|
}>;
|
|
@@ -5,22 +5,27 @@ 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
7
|
const common_1 = require("../common");
|
|
8
|
-
const
|
|
8
|
+
const auth_1 = require("../auth");
|
|
9
9
|
exports.listEventsAction = (0, pieces_framework_1.createAction)({
|
|
10
|
-
auth:
|
|
10
|
+
auth: auth_1.savvyCalAuth,
|
|
11
11
|
name: 'list_events',
|
|
12
12
|
displayName: 'List Events',
|
|
13
13
|
description: 'Returns a list of scheduled meetings from your SavvyCal account.',
|
|
14
14
|
props: {
|
|
15
|
-
|
|
15
|
+
states: pieces_framework_1.Property.StaticMultiSelectDropdown({
|
|
16
16
|
displayName: 'State',
|
|
17
|
-
description: 'Filter events by their current status.',
|
|
17
|
+
description: 'Filter events by their current status. Leave empty to return all statuses.',
|
|
18
18
|
required: false,
|
|
19
19
|
options: {
|
|
20
20
|
options: [
|
|
21
|
-
{ label: 'All', value: '' },
|
|
22
21
|
{ label: 'Confirmed', value: 'confirmed' },
|
|
23
22
|
{ label: 'Canceled', value: 'canceled' },
|
|
23
|
+
{ label: 'Awaiting Reschedule', value: 'awaiting_reschedule' },
|
|
24
|
+
{ label: 'Awaiting Checkout', value: 'awaiting_checkout' },
|
|
25
|
+
{ label: 'Checkout Expired', value: 'checkout_expired' },
|
|
26
|
+
{ label: 'Awaiting Approval', value: 'awaiting_approval' },
|
|
27
|
+
{ label: 'Declined', value: 'declined' },
|
|
28
|
+
{ label: 'Tentative', value: 'tentative' },
|
|
24
29
|
],
|
|
25
30
|
},
|
|
26
31
|
}),
|
|
@@ -34,24 +39,36 @@ exports.listEventsAction = (0, pieces_framework_1.createAction)({
|
|
|
34
39
|
description: 'Only return events that start before this date and time.',
|
|
35
40
|
required: false,
|
|
36
41
|
}),
|
|
37
|
-
|
|
38
|
-
auth:
|
|
39
|
-
displayName: '
|
|
40
|
-
description: '
|
|
42
|
+
team_id: pieces_framework_1.Property.Dropdown({
|
|
43
|
+
auth: auth_1.savvyCalAuth,
|
|
44
|
+
displayName: 'Team',
|
|
45
|
+
description: 'Filter scheduling links by team. Leave empty to show all teams.',
|
|
41
46
|
refreshers: [],
|
|
42
47
|
required: false,
|
|
43
48
|
options: (_a) => tslib_1.__awaiter(void 0, [_a], void 0, function* ({ auth }) {
|
|
44
49
|
if (!auth)
|
|
45
50
|
return { disabled: true, options: [], placeholder: 'Please connect your account first' };
|
|
46
51
|
try {
|
|
47
|
-
const
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
return {
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
52
|
+
const options = yield (0, common_1.buildTeamOptions)((0, auth_1.getToken)(auth));
|
|
53
|
+
return { disabled: false, options };
|
|
54
|
+
}
|
|
55
|
+
catch (_b) {
|
|
56
|
+
return { disabled: true, options: [], placeholder: 'Failed to load teams.' };
|
|
57
|
+
}
|
|
58
|
+
}),
|
|
59
|
+
}),
|
|
60
|
+
link_ids: pieces_framework_1.Property.MultiSelectDropdown({
|
|
61
|
+
auth: auth_1.savvyCalAuth,
|
|
62
|
+
displayName: 'Scheduling Links',
|
|
63
|
+
description: 'Only return events booked through the selected scheduling links. Leave empty for all links.',
|
|
64
|
+
refreshers: ['team_id'],
|
|
65
|
+
required: false,
|
|
66
|
+
options: (_a) => tslib_1.__awaiter(void 0, [_a], void 0, function* ({ auth, team_id }) {
|
|
67
|
+
if (!auth)
|
|
68
|
+
return { disabled: true, options: [], placeholder: 'Please connect your account first' };
|
|
69
|
+
try {
|
|
70
|
+
const options = yield (0, common_1.buildLinkOptions)((0, auth_1.getToken)(auth), team_id);
|
|
71
|
+
return { disabled: false, options };
|
|
55
72
|
}
|
|
56
73
|
catch (_b) {
|
|
57
74
|
return { disabled: true, options: [], placeholder: 'Failed to load scheduling links.' };
|
|
@@ -66,17 +83,49 @@ exports.listEventsAction = (0, pieces_framework_1.createAction)({
|
|
|
66
83
|
},
|
|
67
84
|
run(context) {
|
|
68
85
|
return tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
69
|
-
|
|
70
|
-
const
|
|
86
|
+
var _a, _b;
|
|
87
|
+
const token = (0, auth_1.getToken)(context.auth);
|
|
88
|
+
const { states, start_after, start_before, link_ids, limit } = context.propsValue;
|
|
89
|
+
const selectedStates = states;
|
|
90
|
+
const selectedLinkIds = link_ids;
|
|
91
|
+
const hasLinkFilter = selectedLinkIds && selectedLinkIds.length > 0;
|
|
92
|
+
const needsClientFilter = (hasLinkFilter && selectedLinkIds.length > 1) || (selectedStates && selectedStates.length > 1);
|
|
71
93
|
const queryParams = {};
|
|
72
|
-
if (state)
|
|
73
|
-
queryParams['state'] = state;
|
|
74
94
|
if (start_after)
|
|
75
95
|
queryParams['start_after'] = start_after;
|
|
76
96
|
if (start_before)
|
|
77
97
|
queryParams['start_before'] = start_before;
|
|
78
|
-
if (
|
|
79
|
-
queryParams['
|
|
98
|
+
if (selectedStates && selectedStates.length === 1) {
|
|
99
|
+
queryParams['state'] = selectedStates[0];
|
|
100
|
+
}
|
|
101
|
+
if (hasLinkFilter && selectedLinkIds.length === 1) {
|
|
102
|
+
queryParams['link_id'] = selectedLinkIds[0];
|
|
103
|
+
}
|
|
104
|
+
if (limit && needsClientFilter) {
|
|
105
|
+
// Paginate page by page and stop as soon as we have enough post-filter results,
|
|
106
|
+
// so we never fetch unbounded pages when a limit is set alongside a client-side filter.
|
|
107
|
+
let after = null;
|
|
108
|
+
const collected = [];
|
|
109
|
+
do {
|
|
110
|
+
const params = Object.assign({ limit: '100' }, queryParams);
|
|
111
|
+
if (after)
|
|
112
|
+
params['after'] = after;
|
|
113
|
+
const response = yield (0, common_1.savvyCalApiCall)({
|
|
114
|
+
token,
|
|
115
|
+
method: pieces_common_1.HttpMethod.GET,
|
|
116
|
+
path: '/events',
|
|
117
|
+
queryParams: params,
|
|
118
|
+
});
|
|
119
|
+
for (const event of response.body.entries) {
|
|
120
|
+
const matchesState = !selectedStates || selectedStates.length === 0 || selectedStates.includes(event.state);
|
|
121
|
+
const matchesLink = !hasLinkFilter || selectedLinkIds.includes((_b = (_a = event.link) === null || _a === void 0 ? void 0 : _a.id) !== null && _b !== void 0 ? _b : '');
|
|
122
|
+
if (matchesState && matchesLink)
|
|
123
|
+
collected.push(event);
|
|
124
|
+
}
|
|
125
|
+
after = collected.length >= limit ? null : response.body.metadata.after;
|
|
126
|
+
} while (after);
|
|
127
|
+
return collected.slice(0, limit).map(common_1.flattenEvent);
|
|
128
|
+
}
|
|
80
129
|
if (limit) {
|
|
81
130
|
queryParams['limit'] = String(limit);
|
|
82
131
|
const response = yield (0, common_1.savvyCalApiCall)({
|
|
@@ -88,7 +137,10 @@ exports.listEventsAction = (0, pieces_framework_1.createAction)({
|
|
|
88
137
|
return response.body.entries.map(common_1.flattenEvent);
|
|
89
138
|
}
|
|
90
139
|
const events = yield (0, common_1.savvyCalPaginatedCall)({ token, path: '/events', queryParams });
|
|
91
|
-
return events
|
|
140
|
+
return events
|
|
141
|
+
.filter((e) => !selectedStates || selectedStates.length === 0 || selectedStates.includes(e.state))
|
|
142
|
+
.filter((e) => { var _a, _b; return !hasLinkFilter || selectedLinkIds.includes((_b = (_a = e.link) === null || _a === void 0 ? void 0 : _a.id) !== null && _b !== void 0 ? _b : ''); })
|
|
143
|
+
.map(common_1.flattenEvent);
|
|
92
144
|
});
|
|
93
145
|
},
|
|
94
146
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"list-events.js","sourceRoot":"","sources":["../../../../src/lib/actions/list-events.ts"],"names":[],"mappings":";;;;AAAA,qEAAwE;AACxE,+DAAyD;AACzD,
|
|
1
|
+
{"version":3,"file":"list-events.js","sourceRoot":"","sources":["../../../../src/lib/actions/list-events.ts"],"names":[],"mappings":";;;;AAAA,qEAAwE;AACxE,+DAAyD;AACzD,sCAAoI;AACpI,kCAAiD;AAEpC,QAAA,gBAAgB,GAAG,IAAA,+BAAY,EAAC;IAC3C,IAAI,EAAE,mBAAY;IAClB,IAAI,EAAE,aAAa;IACnB,WAAW,EAAE,aAAa;IAC1B,WAAW,EAAE,kEAAkE;IAC/E,KAAK,EAAE;QACL,MAAM,EAAE,2BAAQ,CAAC,yBAAyB,CAAC;YACzC,WAAW,EAAE,OAAO;YACpB,WAAW,EAAE,4EAA4E;YACzF,QAAQ,EAAE,KAAK;YACf,OAAO,EAAE;gBACP,OAAO,EAAE;oBACP,EAAE,KAAK,EAAE,WAAW,EAAE,KAAK,EAAE,WAAW,EAAE;oBAC1C,EAAE,KAAK,EAAE,UAAU,EAAE,KAAK,EAAE,UAAU,EAAE;oBACxC,EAAE,KAAK,EAAE,qBAAqB,EAAE,KAAK,EAAE,qBAAqB,EAAE;oBAC9D,EAAE,KAAK,EAAE,mBAAmB,EAAE,KAAK,EAAE,mBAA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AQ,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC;iBACjG,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,eAAC,OAAA,CAAC,aAAa,IAAI,eAAe,CAAC,QAAQ,CAAC,MAAA,MAAA,CAAC,CAAC,IAAI,0CAAE,EAAE,mCAAI,EAAE,CAAC,CAAA,EAAA,CAAC;iBAC3E,GAAG,CAAC,qBAAY,CAAC,CAAC;QACvB,CAAC;KAAA;CACF,CAAC,CAAC"}
|
|
@@ -1 +1,7 @@
|
|
|
1
|
-
export declare const listSchedulingLinksAction: import("@activepieces/pieces-framework").IAction<import("@activepieces/pieces-framework").
|
|
1
|
+
export declare const listSchedulingLinksAction: import("@activepieces/pieces-framework").IAction<(import("@activepieces/pieces-framework").OAuth2Property<import("@activepieces/pieces-framework").OAuth2Props> | import("@activepieces/pieces-framework").CustomAuthProperty<{
|
|
2
|
+
token: import("@activepieces/pieces-framework").SecretTextProperty<true>;
|
|
3
|
+
}>)[], {
|
|
4
|
+
team_id: import("@activepieces/pieces-framework").DropdownProperty<string, false, (import("@activepieces/pieces-framework").OAuth2Property<import("@activepieces/pieces-framework").OAuth2Props> | import("@activepieces/pieces-framework").CustomAuthProperty<{
|
|
5
|
+
token: import("@activepieces/pieces-framework").SecretTextProperty<true>;
|
|
6
|
+
}>)[]>;
|
|
7
|
+
}>;
|
|
@@ -4,32 +4,45 @@ exports.listSchedulingLinksAction = void 0;
|
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
5
|
const pieces_framework_1 = require("@activepieces/pieces-framework");
|
|
6
6
|
const common_1 = require("../common");
|
|
7
|
-
const
|
|
7
|
+
const auth_1 = require("../auth");
|
|
8
8
|
exports.listSchedulingLinksAction = (0, pieces_framework_1.createAction)({
|
|
9
|
-
auth:
|
|
9
|
+
auth: auth_1.savvyCalAuth,
|
|
10
10
|
name: 'list_scheduling_links',
|
|
11
11
|
displayName: 'List Scheduling Links',
|
|
12
12
|
description: 'Returns all scheduling links configured in your SavvyCal account.',
|
|
13
|
-
props: {
|
|
13
|
+
props: {
|
|
14
|
+
team_id: pieces_framework_1.Property.Dropdown({
|
|
15
|
+
auth: auth_1.savvyCalAuth,
|
|
16
|
+
displayName: 'Team',
|
|
17
|
+
description: 'Filter scheduling links by team. Leave empty to show all teams.',
|
|
18
|
+
refreshers: [],
|
|
19
|
+
required: false,
|
|
20
|
+
options: (_a) => tslib_1.__awaiter(void 0, [_a], void 0, function* ({ auth }) {
|
|
21
|
+
if (!auth)
|
|
22
|
+
return { disabled: true, options: [], placeholder: 'Please connect your account first' };
|
|
23
|
+
try {
|
|
24
|
+
const options = yield (0, common_1.buildTeamOptions)((0, auth_1.getToken)(auth));
|
|
25
|
+
return { disabled: false, options };
|
|
26
|
+
}
|
|
27
|
+
catch (_b) {
|
|
28
|
+
return { disabled: true, options: [], placeholder: 'Failed to load teams.' };
|
|
29
|
+
}
|
|
30
|
+
}),
|
|
31
|
+
}),
|
|
32
|
+
},
|
|
14
33
|
run(context) {
|
|
15
34
|
return tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
16
35
|
const links = yield (0, common_1.savvyCalPaginatedCall)({
|
|
17
|
-
token: context.auth
|
|
36
|
+
token: (0, auth_1.getToken)(context.auth),
|
|
18
37
|
path: '/links',
|
|
19
38
|
});
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
active: (_b = link.active) !== null && _b !== void 0 ? _b : null,
|
|
28
|
-
duration_minutes: (_c = link.duration) !== null && _c !== void 0 ? _c : null,
|
|
29
|
-
created_at: link.created_at,
|
|
30
|
-
updated_at: link.updated_at,
|
|
31
|
-
});
|
|
32
|
-
});
|
|
39
|
+
const { team_id } = context.propsValue;
|
|
40
|
+
const filtered = team_id
|
|
41
|
+
? team_id === 'personal'
|
|
42
|
+
? links.filter((l) => l.scope === null)
|
|
43
|
+
: links.filter((l) => { var _a; return ((_a = l.scope) === null || _a === void 0 ? void 0 : _a.id) === team_id; })
|
|
44
|
+
: links;
|
|
45
|
+
return filtered.map(common_1.flattenLink);
|
|
33
46
|
});
|
|
34
47
|
},
|
|
35
48
|
});
|