@activepieces/piece-savvycal 0.0.2 → 0.1.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 +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 +45 -13
- 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 +27 -36
- 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 +10 -2
- package/src/lib/actions/create-event.js +32 -17
- 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 +70 -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 +14 -0
- package/src/lib/auth.js +59 -0
- package/src/lib/auth.js.map +1 -0
- package/src/lib/common/index.d.ts +13 -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
package/src/index.d.ts
CHANGED
|
@@ -1,2 +1,3 @@
|
|
|
1
|
-
export declare const
|
|
2
|
-
|
|
1
|
+
export declare const savvyCal: import("@activepieces/pieces-framework").Piece<(import("@activepieces/pieces-framework").OAuth2Property<import("@activepieces/pieces-framework").OAuth2Props> | import("@activepieces/pieces-framework").CustomAuthProperty<{
|
|
2
|
+
token: import("@activepieces/pieces-framework").SecretTextProperty<true>;
|
|
3
|
+
}>)[]>;
|
package/src/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.savvyCal =
|
|
3
|
+
exports.savvyCal = 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");
|
|
@@ -12,46 +12,26 @@ const cancel_event_1 = require("./lib/actions/cancel-event");
|
|
|
12
12
|
const create_event_1 = require("./lib/actions/create-event");
|
|
13
13
|
const find_events_by_email_1 = require("./lib/actions/find-events-by-email");
|
|
14
14
|
const list_scheduling_links_1 = require("./lib/actions/list-scheduling-links");
|
|
15
|
-
const
|
|
16
|
-
const
|
|
17
|
-
const
|
|
15
|
+
const get_scheduling_link_1 = require("./lib/actions/get-scheduling-link");
|
|
16
|
+
const delete_scheduling_link_1 = require("./lib/actions/delete-scheduling-link");
|
|
17
|
+
const duplicate_scheduling_link_1 = require("./lib/actions/duplicate-scheduling-link");
|
|
18
|
+
const toggle_scheduling_link_1 = require("./lib/actions/toggle-scheduling-link");
|
|
19
|
+
const get_link_slots_1 = require("./lib/actions/get-link-slots");
|
|
20
|
+
const list_workflows_1 = require("./lib/actions/list-workflows");
|
|
21
|
+
const get_workflow_rules_1 = require("./lib/actions/get-workflow-rules");
|
|
18
22
|
const new_event_1 = require("./lib/triggers/new-event");
|
|
23
|
+
const new_poll_response_1 = require("./lib/triggers/new-poll-response");
|
|
24
|
+
const workflow_action_triggered_1 = require("./lib/triggers/workflow-action-triggered");
|
|
25
|
+
const auth_1 = require("./lib/auth");
|
|
19
26
|
const common_1 = require("./lib/common");
|
|
20
|
-
exports.savvyCalAuth = pieces_framework_1.PieceAuth.SecretText({
|
|
21
|
-
displayName: 'Personal Access Token',
|
|
22
|
-
description: `To get your SavvyCal API token:
|
|
23
|
-
1. Log in to your SavvyCal account at https://savvycal.com
|
|
24
|
-
2. Go to **Settings > Developer**
|
|
25
|
-
3. Click **Create Token**
|
|
26
|
-
4. Give it a name and copy the token (it starts with \`pt_secret_\`)
|
|
27
|
-
|
|
28
|
-
**Note:** Keep this token secret — it gives full access to your SavvyCal account.`,
|
|
29
|
-
required: true,
|
|
30
|
-
validate: (_a) => tslib_1.__awaiter(void 0, [_a], void 0, function* ({ auth }) {
|
|
31
|
-
try {
|
|
32
|
-
yield pieces_common_1.httpClient.sendRequest({
|
|
33
|
-
method: pieces_common_1.HttpMethod.GET,
|
|
34
|
-
url: `${common_1.SAVVYCAL_BASE_URL}/me`,
|
|
35
|
-
authentication: {
|
|
36
|
-
type: pieces_common_1.AuthenticationType.BEARER_TOKEN,
|
|
37
|
-
token: auth,
|
|
38
|
-
},
|
|
39
|
-
});
|
|
40
|
-
return { valid: true };
|
|
41
|
-
}
|
|
42
|
-
catch (_b) {
|
|
43
|
-
return { valid: false, error: 'Invalid token. Please check your Personal Access Token and try again.' };
|
|
44
|
-
}
|
|
45
|
-
}),
|
|
46
|
-
});
|
|
47
27
|
exports.savvyCal = (0, pieces_framework_1.createPiece)({
|
|
48
28
|
displayName: 'SavvyCal',
|
|
49
29
|
description: 'Scheduling tool that lets invitees overlay their calendar when picking a time.',
|
|
50
30
|
minimumSupportedRelease: '0.36.1',
|
|
51
31
|
logoUrl: 'https://cdn.activepieces.com/pieces/savvycal.png',
|
|
52
32
|
categories: [shared_1.PieceCategory.PRODUCTIVITY],
|
|
53
|
-
auth:
|
|
54
|
-
authors: ['bst1n', 'sanket-a11y'],
|
|
33
|
+
auth: auth_1.savvyCalAuth,
|
|
34
|
+
authors: ['bst1n', 'sanket-a11y', 'onyedikachi-david'],
|
|
55
35
|
actions: [
|
|
56
36
|
get_current_user_1.getCurrentUserAction,
|
|
57
37
|
list_events_1.listEventsAction,
|
|
@@ -60,16 +40,27 @@ exports.savvyCal = (0, pieces_framework_1.createPiece)({
|
|
|
60
40
|
create_event_1.createEventAction,
|
|
61
41
|
find_events_by_email_1.findEventsByEmailAction,
|
|
62
42
|
list_scheduling_links_1.listSchedulingLinksAction,
|
|
43
|
+
get_scheduling_link_1.getSchedulingLinkAction,
|
|
44
|
+
delete_scheduling_link_1.deleteSchedulingLinkAction,
|
|
45
|
+
duplicate_scheduling_link_1.duplicateSchedulingLinkAction,
|
|
46
|
+
toggle_scheduling_link_1.toggleSchedulingLinkAction,
|
|
47
|
+
get_link_slots_1.getLinkSlotsAction,
|
|
48
|
+
list_workflows_1.listWorkflowsAction,
|
|
49
|
+
get_workflow_rules_1.getWorkflowRulesAction,
|
|
63
50
|
(0, pieces_common_1.createCustomApiCallAction)({
|
|
64
51
|
baseUrl: () => common_1.SAVVYCAL_BASE_URL,
|
|
65
|
-
auth:
|
|
52
|
+
auth: auth_1.savvyCalAuth,
|
|
66
53
|
authMapping: (auth) => tslib_1.__awaiter(void 0, void 0, void 0, function* () {
|
|
67
54
|
return ({
|
|
68
|
-
Authorization: `Bearer ${auth}`,
|
|
55
|
+
Authorization: `Bearer ${(0, auth_1.getToken)(auth)}`,
|
|
69
56
|
});
|
|
70
57
|
}),
|
|
71
58
|
}),
|
|
72
59
|
],
|
|
73
|
-
triggers: [
|
|
60
|
+
triggers: [
|
|
61
|
+
new_event_1.newEventTrigger,
|
|
62
|
+
new_poll_response_1.newPollResponseTrigger,
|
|
63
|
+
workflow_action_triggered_1.workflowActionTriggeredTrigger,
|
|
64
|
+
],
|
|
74
65
|
});
|
|
75
66
|
//# sourceMappingURL=index.js.map
|
package/src/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";;;;AAAA,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";;;;AAAA,qEAA6D;AAC7D,+DAAwE;AACxE,iDAAqD;AAErD,qEAAsE;AACtE,2DAA6D;AAC7D,uDAAyD;AACzD,6DAA+D;AAC/D,6DAA+D;AAC/D,6EAA6E;AAC7E,+EAAgF;AAChF,2EAA4E;AAC5E,iFAAkF;AAClF,uFAAwF;AACxF,iFAAkF;AAClF,iEAAkE;AAClE,iEAAmE;AACnE,yEAA0E;AAE1E,wDAA2D;AAC3D,wEAA0E;AAC1E,wFAA0F;AAE1F,qCAAoD;AACpD,yCAAiD;AAEpC,QAAA,QAAQ,GAAG,IAAA,8BAAW,EAAC;IAClC,WAAW,EAAE,UAAU;IACvB,WAAW,EAAE,gFAAgF;IAC7F,uBAAuB,EAAE,QAAQ;IACjC,OAAO,EAAE,kDAAkD;IAC3D,UAAU,EAAE,CAAC,sBAAa,CAAC,YAAY,CAAC;IACxC,IAAI,EAAE,mBAAY;IAClB,OAAO,EAAE,CAAC,OAAO,EAAC,aAAa,EAAE,mBAAmB,CAAC;IACrD,OAAO,EAAE;QACP,uCAAoB;QACpB,8BAAgB;QAChB,0BAAc;QACd,gCAAiB;QACjB,gCAAiB;QACjB,8CAAuB;QACvB,iDAAyB;QACzB,6CAAuB;QACvB,mDAA0B;QAC1B,yDAA6B;QAC7B,mDAA0B;QAC1B,mCAAkB;QAClB,oCAAmB;QACnB,2CAAsB;QACtB,IAAA,yCAAyB,EAAC;YACxB,OAAO,EAAE,GAAG,EAAE,CAAC,0BAAiB;YAChC,IAAI,EAAE,mBAAY;YAClB,WAAW,EAAE,CAAO,IAAI,EAAE,EAAE;gBAAC,OAAA,CAAC;oBAC5B,aAAa,EAAE,UAAU,IAAA,eAAQ,EAAC,IAAI,CAAC,EAAE;iBAC1C,CAAC,CAAA;cAAA;SACH,CAAC;KACH;IACD,QAAQ,EAAE;QACR,2BAAe;QACf,0CAAsB;QACtB,0DAA8B;KAC/B;CACF,CAAC,CAAC"}
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
-
export declare const cancelEventAction: import("@activepieces/pieces-framework").IAction<import("@activepieces/pieces-framework").
|
|
1
|
+
export declare const cancelEventAction: 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.cancelEventAction = (0, pieces_framework_1.createAction)({
|
|
10
|
-
auth:
|
|
10
|
+
auth: auth_1.savvyCalAuth,
|
|
11
11
|
name: 'cancel_event',
|
|
12
12
|
displayName: 'Cancel Event',
|
|
13
13
|
description: 'Cancels a scheduled meeting in SavvyCal.',
|
|
@@ -21,7 +21,7 @@ exports.cancelEventAction = (0, pieces_framework_1.createAction)({
|
|
|
21
21
|
run(context) {
|
|
22
22
|
return tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
23
23
|
yield (0, common_1.savvyCalApiCall)({
|
|
24
|
-
token: context.auth
|
|
24
|
+
token: (0, auth_1.getToken)(context.auth),
|
|
25
25
|
method: pieces_common_1.HttpMethod.POST,
|
|
26
26
|
path: `/events/${context.propsValue.event_id}/cancel`,
|
|
27
27
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cancel-event.js","sourceRoot":"","sources":["../../../../src/lib/actions/cancel-event.ts"],"names":[],"mappings":";;;;AAAA,qEAAwE;AACxE,+DAAyD;AACzD,sCAA4C;AAC5C,
|
|
1
|
+
{"version":3,"file":"cancel-event.js","sourceRoot":"","sources":["../../../../src/lib/actions/cancel-event.ts"],"names":[],"mappings":";;;;AAAA,qEAAwE;AACxE,+DAAyD;AACzD,sCAA4C;AAC5C,kCAAiD;AAEpC,QAAA,iBAAiB,GAAG,IAAA,+BAAY,EAAC;IAC5C,IAAI,EAAE,mBAAY;IAClB,IAAI,EAAE,cAAc;IACpB,WAAW,EAAE,cAAc;IAC3B,WAAW,EAAE,0CAA0C;IACvD,KAAK,EAAE;QACL,QAAQ,EAAE,2BAAQ,CAAC,SAAS,CAAC;YAC3B,WAAW,EAAE,UAAU;YACvB,WAAW,EAAE,8HAA8H;YAC3I,QAAQ,EAAE,IAAI;SACf,CAAC;KACH;IACK,GAAG,CAAC,OAAO;;YACf,MAAM,IAAA,wBAAe,EAAC;gBACpB,KAAK,EAAE,IAAA,eAAQ,EAAC,OAAO,CAAC,IAAI,CAAC;gBAC7B,MAAM,EAAE,0BAAU,CAAC,IAAI;gBACvB,IAAI,EAAE,WAAW,OAAO,CAAC,UAAU,CAAC,QAAQ,SAAS;aACtD,CAAC,CAAC;YAEH,OAAO;gBACL,OAAO,EAAE,IAAI;gBACb,QAAQ,EAAE,OAAO,CAAC,UAAU,CAAC,QAAQ;gBACrC,OAAO,EAAE,+BAA+B;aACzC,CAAC;QACJ,CAAC;KAAA;CACF,CAAC,CAAC"}
|
|
@@ -1,7 +1,15 @@
|
|
|
1
|
-
export declare const createEventAction: import("@activepieces/pieces-framework").IAction<import("@activepieces/pieces-framework").
|
|
2
|
-
|
|
1
|
+
export declare const createEventAction: 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
|
+
}>)[]>;
|
|
3
10
|
start_at: import("@activepieces/pieces-framework").DateTimeProperty<true>;
|
|
4
11
|
end_at: import("@activepieces/pieces-framework").DateTimeProperty<true>;
|
|
5
12
|
attendee_name: import("@activepieces/pieces-framework").ShortTextProperty<true>;
|
|
6
13
|
attendee_email: import("@activepieces/pieces-framework").ShortTextProperty<true>;
|
|
14
|
+
time_zone: import("@activepieces/pieces-framework").ShortTextProperty<true>;
|
|
7
15
|
}>;
|
|
@@ -5,20 +5,38 @@ 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.createEventAction = (0, pieces_framework_1.createAction)({
|
|
10
|
-
auth:
|
|
10
|
+
auth: auth_1.savvyCalAuth,
|
|
11
11
|
name: 'create_event',
|
|
12
12
|
displayName: 'Create Event',
|
|
13
13
|
description: 'Books a meeting on a scheduling link at a specific time slot.',
|
|
14
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
|
+
}),
|
|
15
33
|
link_id: pieces_framework_1.Property.Dropdown({
|
|
16
|
-
auth:
|
|
34
|
+
auth: auth_1.savvyCalAuth,
|
|
17
35
|
displayName: 'Scheduling Link',
|
|
18
36
|
description: 'Select the scheduling link to book a meeting on.',
|
|
19
|
-
refreshers: [],
|
|
37
|
+
refreshers: ['team_id'],
|
|
20
38
|
required: true,
|
|
21
|
-
options: (_a) => tslib_1.__awaiter(void 0, [_a], void 0, function* ({ auth }) {
|
|
39
|
+
options: (_a) => tslib_1.__awaiter(void 0, [_a], void 0, function* ({ auth, team_id }) {
|
|
22
40
|
if (!auth)
|
|
23
41
|
return {
|
|
24
42
|
disabled: true,
|
|
@@ -26,17 +44,8 @@ exports.createEventAction = (0, pieces_framework_1.createAction)({
|
|
|
26
44
|
placeholder: 'Please connect your account first',
|
|
27
45
|
};
|
|
28
46
|
try {
|
|
29
|
-
const
|
|
30
|
-
|
|
31
|
-
path: '/links',
|
|
32
|
-
});
|
|
33
|
-
return {
|
|
34
|
-
disabled: false,
|
|
35
|
-
options: links.map((l) => ({
|
|
36
|
-
label: `${l.name} (${l.slug})`,
|
|
37
|
-
value: l.id,
|
|
38
|
-
})),
|
|
39
|
-
};
|
|
47
|
+
const options = yield (0, common_1.buildLinkOptions)((0, auth_1.getToken)(auth), team_id);
|
|
48
|
+
return { disabled: false, options };
|
|
40
49
|
}
|
|
41
50
|
catch (_b) {
|
|
42
51
|
return {
|
|
@@ -67,11 +76,16 @@ exports.createEventAction = (0, pieces_framework_1.createAction)({
|
|
|
67
76
|
description: 'Email address of the person booking the meeting.',
|
|
68
77
|
required: true,
|
|
69
78
|
}),
|
|
79
|
+
time_zone: pieces_framework_1.Property.ShortText({
|
|
80
|
+
displayName: 'Time Zone',
|
|
81
|
+
description: "Attendee's local time zone in Olson format (e.g. America/New_York, Europe/London, Africa/Lagos).",
|
|
82
|
+
required: true,
|
|
83
|
+
}),
|
|
70
84
|
},
|
|
71
85
|
run(context) {
|
|
72
86
|
return tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
73
87
|
const response = yield (0, common_1.savvyCalApiCall)({
|
|
74
|
-
token: context.auth
|
|
88
|
+
token: (0, auth_1.getToken)(context.auth),
|
|
75
89
|
method: pieces_common_1.HttpMethod.POST,
|
|
76
90
|
path: `/links/${context.propsValue.link_id}/events`,
|
|
77
91
|
body: {
|
|
@@ -79,6 +93,7 @@ exports.createEventAction = (0, pieces_framework_1.createAction)({
|
|
|
79
93
|
end_at: context.propsValue.end_at,
|
|
80
94
|
display_name: context.propsValue.attendee_name,
|
|
81
95
|
email: context.propsValue.attendee_email,
|
|
96
|
+
time_zone: context.propsValue.time_zone,
|
|
82
97
|
},
|
|
83
98
|
});
|
|
84
99
|
return (0, common_1.flattenEvent)(response.body);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"create-event.js","sourceRoot":"","sources":["../../../../src/lib/actions/create-event.ts"],"names":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,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,IAAI;gBACvB,IAAI,EAAE,UAAU,OAAO,CAAC,UAAU,CAAC,OAAO,SAAS;gBACnD,IAAI,EAAE;oBACJ,QAAQ,EAAE,OAAO,CAAC,UAAU,CAAC,QAAQ;oBACrC,MAAM,EAAE,OAAO,CAAC,UAAU,CAAC,MAAM;oBACjC,YAAY,EAAE,OAAO,CAAC,UAAU,CAAC,aAAa;oBAC9C,KAAK,EAAE,OAAO,CAAC,UAAU,CAAC,cAAc;oBACxC,SAAS,EAAE,OAAO,CAAC,UAAU,CAAC,SAAS;iBACxC;aACF,CAAC,CAAC;YACH,OAAO,IAAA,qBAAY,EAAC,QAAQ,CAAC,IAAI,CAAC,CAAC;QACrC,CAAC;KAAA;CACF,CAAC,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export declare const deleteSchedulingLinkAction: 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,67 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.deleteSchedulingLinkAction = 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.deleteSchedulingLinkAction = (0, pieces_framework_1.createAction)({
|
|
10
|
+
auth: auth_1.savvyCalAuth,
|
|
11
|
+
name: 'delete_scheduling_link',
|
|
12
|
+
displayName: 'Delete Scheduling Link',
|
|
13
|
+
description: 'Permanently deletes a scheduling link from your SavvyCal account.',
|
|
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 delete. This action cannot be undone.',
|
|
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
|
+
yield (0, common_1.savvyCalApiCall)({
|
|
55
|
+
token: (0, auth_1.getToken)(context.auth),
|
|
56
|
+
method: pieces_common_1.HttpMethod.DELETE,
|
|
57
|
+
path: `/links/${context.propsValue.link_id}`,
|
|
58
|
+
});
|
|
59
|
+
return {
|
|
60
|
+
success: true,
|
|
61
|
+
link_id: context.propsValue.link_id,
|
|
62
|
+
message: 'Scheduling link deleted successfully.',
|
|
63
|
+
};
|
|
64
|
+
});
|
|
65
|
+
},
|
|
66
|
+
});
|
|
67
|
+
//# sourceMappingURL=delete-scheduling-link.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"delete-scheduling-link.js","sourceRoot":"","sources":["../../../../src/lib/actions/delete-scheduling-link.ts"],"names":[],"mappings":";;;;AAAA,qEAAwE;AACxE,+DAAyD;AACzD,sCAAgF;AAChF,kCAAiD;AAEpC,QAAA,0BAA0B,GAAG,IAAA,+BAAY,EAAC;IACrD,IAAI,EAAE,mBAAY;IAClB,IAAI,EAAE,wBAAwB;IAC9B,WAAW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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,IAAA,wBAAe,EAAC;gBACpB,KAAK,EAAE,IAAA,eAAQ,EAAC,OAAO,CAAC,IAAI,CAAC;gBAC7B,MAAM,EAAE,0BAAU,CAAC,MAAM;gBACzB,IAAI,EAAE,UAAU,OAAO,CAAC,UAAU,CAAC,OAAO,EAAE;aAC7C,CAAC,CAAC;YACH,OAAO;gBACL,OAAO,EAAE,IAAI;gBACb,OAAO,EAAE,OAAO,CAAC,UAAU,CAAC,OAAO;gBACnC,OAAO,EAAE,uCAAuC;aACjD,CAAC;QACJ,CAAC;KAAA;CACF,CAAC,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export declare const duplicateSchedulingLinkAction: 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,63 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.duplicateSchedulingLinkAction = 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.duplicateSchedulingLinkAction = (0, pieces_framework_1.createAction)({
|
|
10
|
+
auth: auth_1.savvyCalAuth,
|
|
11
|
+
name: 'duplicate_scheduling_link',
|
|
12
|
+
displayName: 'Duplicate Scheduling Link',
|
|
13
|
+
description: 'Creates a copy of an existing scheduling link.',
|
|
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 duplicate.',
|
|
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.POST,
|
|
57
|
+
path: `/links/${context.propsValue.link_id}/duplicate`,
|
|
58
|
+
});
|
|
59
|
+
return (0, common_1.flattenLink)(response.body);
|
|
60
|
+
});
|
|
61
|
+
},
|
|
62
|
+
});
|
|
63
|
+
//# sourceMappingURL=duplicate-scheduling-link.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"duplicate-scheduling-link.js","sourceRoot":"","sources":["../../../../src/lib/actions/duplicate-scheduling-link.ts"],"names":[],"mappings":";;;;AAAA,qEAAwE;AACxE,+DAAyD;AACzD,sCAMmB;AACnB,kCAAiD;AAEpC,QAAA,6BAA6B,GAAG,IAAA,+BAAY,EAAC;IACxD,IAAI,EAAE,mBAAY;IAClB,IAAI,EAAE,2BAA2B;IACjC,WAAW,EAAE,2BAA2B;IACxC,WAAW,EAAE,gDAAgD;IAC7D,KAAK,E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,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,IAAI;gBACvB,IAAI,EAAE,UAAU,OAAO,CAAC,UAAU,CAAC,OAAO,YAAY;aACvD,CAAC,CAAC;YACH,OAAO,IAAA,oBAAW,EAAC,QAAQ,CAAC,IAAI,CAAC,CAAC;QACpC,CAAC;KAAA;CACF,CAAC,CAAC"}
|
|
@@ -1,4 +1,6 @@
|
|
|
1
|
-
export declare const findEventsByEmailAction: import("@activepieces/pieces-framework").IAction<import("@activepieces/pieces-framework").
|
|
1
|
+
export declare const findEventsByEmailAction: 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
|
attendee_email: import("@activepieces/pieces-framework").ShortTextProperty<true>;
|
|
3
5
|
start_after: import("@activepieces/pieces-framework").DateTimeProperty<false>;
|
|
4
6
|
start_before: import("@activepieces/pieces-framework").DateTimeProperty<false>;
|
|
@@ -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;IAClB,IAAI,EAAE,sBAAsB;IAC5B,WAAW,EAAE,+BAA+B;IAC5C,WAAW,EAAE,0EAA0E;IACvF,KAAK,EAAE;QACL,cAAc,EAAE,2BAAQ,CAAC,SAAS,CAAC;YACjC,WAAW,EAAE,gBAAgB;YAC7B,WAAW,EAAE,kDAAkD;YAC/D,QAAQ,EAAE,IAAI;SACf,CAAC;QACF,WAAW,EAAE,2BAAQ,CAAC,QAAQ,CAAC;YAC7B,WAAW,EAAE,aAAa;YAC1B,WAAW,EAAE,0GAA0G;YACvH,QAAQ,EAAE,KAAK;SAChB,CAAC;QACF,YAAY,EAAE,2BAAQ,CAAC,QAAQ,CAAC;YAC9B,WAAW,EAAE,cAAc;YAC3B,WAAW,EAAE,+CAA+C;YAC5D,QAAQ,EAAE,KAAK;SAChB,CAAC;KACH;IACK,GAAG,CAAC,OAAO;;YACf,MAAM,KAAK,GAAG,IAAA,eAAQ,EAAC,OAAO,CAAC,IAAI,CAAC,CAAC;YACrC,MAAM,EAAE,cAAc,EAAE,WAAW,EAAE,YAAY,EAAE,GAAG,OAAO,CAAC,UAAU,CAAC;YAEzE,MAAM,WAAW,GAA2B,EAAE,CAAC;YAC/C,IAAI,WAAW;gBAAE,WAAW,CAAC,aAAa,CAAC,GAAG,WAAW,CAAC;YAC1D,IAAI,YAAY;gBAAE,WAAW,CAAC,cAAc,CAAC,GAAG,YAAY,CAAC;YAE7D,MAAM,MAAM,GAAG,MAAM,IAAA,8BAAqB,EAAgB;gBACxD,KAAK;gBACL,IAAI,EAAE,SAAS;gBACf,WAAW;aACZ,CAAC,CAAC;YAEH,MAAM,eAAe,GAAG,cAAc,CAAC,WAAW,EAAE,CAAC,IAAI,EAAE,CAAC;YAC5D,OAAO,MAAM;iBACV,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,WAAC,OAAA,MAAA,CAAC,CAAC,SAAS,0CAAE,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,WAAC,OAAA,CAAA,MAAA,CAAC,CAAC,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
|
+
}>;
|