@activepieces/piece-gmail 0.5.0 → 0.5.2
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/index.d.ts +2 -2
- package/src/index.js +23 -2
- package/src/index.js.map +1 -1
- package/src/lib/actions/get-mail-action.d.ts +1 -1
- package/src/lib/actions/get-mail-action.js +1 -1
- package/src/lib/actions/get-mail-action.js.map +1 -1
- package/src/lib/actions/get-thread-action.d.ts +1 -1
- package/src/lib/actions/search-email-action.d.ts +1 -1
- package/src/lib/actions/send-email-action.d.ts +1 -1
- package/src/lib/common/props.d.ts +1 -1
- package/src/lib/triggers/new-email.d.ts +13 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@activepieces/piece-gmail",
|
|
3
|
-
"version": "0.5.
|
|
3
|
+
"version": "0.5.2",
|
|
4
4
|
"dependencies": {
|
|
5
5
|
"@sinclair/typebox": "0.26.8",
|
|
6
6
|
"axios": "^1.6.3",
|
|
@@ -9,11 +9,11 @@
|
|
|
9
9
|
"lodash": "4.17.21",
|
|
10
10
|
"mime-types": "2.1.35",
|
|
11
11
|
"nanoid": "3.3.6",
|
|
12
|
-
"nodemailer": "6.9.
|
|
12
|
+
"nodemailer": "6.9.9",
|
|
13
13
|
"semver": "7.5.4",
|
|
14
|
-
"@activepieces/pieces-common": "0.2.
|
|
15
|
-
"@activepieces/pieces-framework": "0.7.
|
|
16
|
-
"@activepieces/shared": "0.10.
|
|
14
|
+
"@activepieces/pieces-common": "0.2.8",
|
|
15
|
+
"@activepieces/pieces-framework": "0.7.15",
|
|
16
|
+
"@activepieces/shared": "0.10.68",
|
|
17
17
|
"tslib": "2.6.2"
|
|
18
18
|
},
|
|
19
19
|
"main": "./src/index.js",
|
package/src/index.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const gmailAuth: import("@activepieces/pieces-framework").OAuth2Property<
|
|
2
|
-
export declare const gmail: import("@activepieces/pieces-framework").Piece<import("@activepieces/pieces-framework").OAuth2Property<
|
|
1
|
+
export declare const gmailAuth: import("@activepieces/pieces-framework").OAuth2Property<import("@activepieces/pieces-framework").OAuth2Props>;
|
|
2
|
+
export declare const gmail: import("@activepieces/pieces-framework").Piece<import("@activepieces/pieces-framework").OAuth2Property<import("@activepieces/pieces-framework").OAuth2Props>>;
|
package/src/index.js
CHANGED
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.gmail = exports.gmailAuth = void 0;
|
|
4
|
+
const pieces_common_1 = require("@activepieces/pieces-common");
|
|
4
5
|
const pieces_framework_1 = require("@activepieces/pieces-framework");
|
|
6
|
+
const shared_1 = require("@activepieces/shared");
|
|
5
7
|
const send_email_action_1 = require("./lib/actions/send-email-action");
|
|
6
8
|
exports.gmailAuth = pieces_framework_1.PieceAuth.OAuth2({
|
|
7
9
|
description: '',
|
|
@@ -14,9 +16,28 @@ exports.gmailAuth = pieces_framework_1.PieceAuth.OAuth2({
|
|
|
14
16
|
exports.gmail = (0, pieces_framework_1.createPiece)({
|
|
15
17
|
minimumSupportedRelease: '0.5.0',
|
|
16
18
|
logoUrl: 'https://cdn.activepieces.com/pieces/gmail.png',
|
|
17
|
-
|
|
19
|
+
categories: [
|
|
20
|
+
shared_1.PieceCategory.COMMUNICATION,
|
|
21
|
+
shared_1.PieceCategory.BUSINESS_INTELLIGENCE,
|
|
22
|
+
],
|
|
23
|
+
actions: [
|
|
24
|
+
send_email_action_1.gmailSendEmailAction,
|
|
25
|
+
(0, pieces_common_1.createCustomApiCallAction)({
|
|
26
|
+
baseUrl: () => 'https://gmail.googleapis.com/gmail/v1',
|
|
27
|
+
auth: exports.gmailAuth,
|
|
28
|
+
authMapping: (auth) => ({
|
|
29
|
+
Authorization: `Bearer ${auth.access_token}`,
|
|
30
|
+
}),
|
|
31
|
+
}),
|
|
32
|
+
],
|
|
18
33
|
displayName: 'Gmail',
|
|
19
|
-
authors: [
|
|
34
|
+
authors: [
|
|
35
|
+
'AbdulTheActivePiecer',
|
|
36
|
+
'kanarelo',
|
|
37
|
+
'BastienMe',
|
|
38
|
+
'PFernandez98',
|
|
39
|
+
'kishanprmr',
|
|
40
|
+
],
|
|
20
41
|
triggers: [],
|
|
21
42
|
auth: exports.gmailAuth,
|
|
22
43
|
});
|
package/src/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../packages/pieces/community/gmail/src/index.ts"],"names":[],"mappings":";;;AAAA
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../packages/pieces/community/gmail/src/index.ts"],"names":[],"mappings":";;;AAAA,+DAAwE;AACxE,qEAIwC;AACxC,iDAAqD;AACrD,uEAAuE;AAE1D,QAAA,SAAS,GAAG,4BAAS,CAAC,MAAM,CAAC;IACxC,WAAW,EAAE,EAAE;IAEf,OAAO,EAAE,2CAA2C;IACpD,QAAQ,EAAE,qCAAqC;IAC/C,QAAQ,EAAE,IAAI;IACd,sFAAsF;IACtF,KAAK,EAAE,CAAC,4CAA4C,EAAE,OAAO,CAAC;CAC/D,CAAC,CAAC;AAEU,QAAA,KAAK,GAAG,IAAA,8BAAW,EAAC;IAC/B,uBAAuB,EAAE,OAAO;IAChC,OAAO,EAAE,+CAA+C;IACxD,UAAU,EAAE;QACV,sBAAa,CAAC,aAAa;QAC3B,sBAAa,CAAC,qBAAqB;KACpC;IACD,OAAO,EAAE;QACP,wCAAoB;QACpB,IAAA,yCAAyB,EAAC;YACxB,OAAO,EAAE,GAAG,EAAE,CAAC,uCAAuC;YACtD,IAAI,EAAE,iBAAS;YACf,WAAW,EAAE,CAAC,IAAI,EAAE,EAAE,CAAC,CAAC;gBACtB,aAAa,EAAE,UAAW,IAA4B,CAAC,YAAY,EAAE;aACtE,CAAC;SACH,CAAC;KACH;IACD,WAAW,EAAE,OAAO;IACpB,OAAO,EAAE;QACP,sBAAsB;QACtB,UAAU;QACV,WAAW;QACX,cAAc;QACd,YAAY;KACb;IACD,QAAQ,EAAE,EAAE;IACZ,IAAI,EAAE,iBAAS;CAChB,CAAC,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { GmailMessageFormat } from '../common/models';
|
|
2
|
-
export declare const gmailGetEmail: import("@activepieces/pieces-framework").IAction<import("@activepieces/pieces-framework").OAuth2Property<
|
|
2
|
+
export declare const gmailGetEmail: import("@activepieces/pieces-framework").IAction<import("@activepieces/pieces-framework").OAuth2Property<import("@activepieces/pieces-framework").OAuth2Props>, {
|
|
3
3
|
message_id: import("@activepieces/pieces-framework").ShortTextProperty<true>;
|
|
4
4
|
format: import("@activepieces/pieces-framework").StaticDropdownProperty<GmailMessageFormat, false> | import("@activepieces/pieces-framework").StaticDropdownProperty<GmailMessageFormat, true>;
|
|
5
5
|
}>;
|
|
@@ -21,7 +21,7 @@ exports.gmailGetEmail = (0, pieces_framework_1.createAction)({
|
|
|
21
21
|
displayName: 'Format',
|
|
22
22
|
description: 'Format of the mail',
|
|
23
23
|
required: false,
|
|
24
|
-
defaultValue:
|
|
24
|
+
defaultValue: models_1.GmailMessageFormat.FULL,
|
|
25
25
|
options: {
|
|
26
26
|
disabled: false,
|
|
27
27
|
options: [
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get-mail-action.js","sourceRoot":"","sources":["../../../../../../../../packages/pieces/community/gmail/src/lib/actions/get-mail-action.ts"],"names":[],"mappings":";;;;AAAA,qEAAwE;AACxE,yCAA+C;AAC/C,6CAAsD;AACtD,8BAAmC;AAEtB,QAAA,aAAa,GAAG,IAAA,+BAAY,EAAC;IACxC,IAAI,EAAE,aAAS;IACf,IAAI,EAAE,gBAAgB;IACtB,WAAW,EAAE,6CAA6C;IAC1D,WAAW,EAAE,WAAW;IACxB,KAAK,EAAE;QACL,UAAU,EAAE,2BAAQ,CAAC,SAAS,CAAC;YAC7B,WAAW,EAAE,YAAY;YACzB,WAAW,EAAE,mCAAmC;YAChD,QAAQ,EAAE,IAAI;SACf,CAAC;QACF,MAAM,EAAE,2BAAQ,CAAC,cAAc,CAAqB;YAClD,WAAW,EAAE,QAAQ;YACrB,WAAW,EAAE,oBAAoB;YACjC,QAAQ,EAAE,KAAK;YACf,YAAY,EAAE,
|
|
1
|
+
{"version":3,"file":"get-mail-action.js","sourceRoot":"","sources":["../../../../../../../../packages/pieces/community/gmail/src/lib/actions/get-mail-action.ts"],"names":[],"mappings":";;;;AAAA,qEAAwE;AACxE,yCAA+C;AAC/C,6CAAsD;AACtD,8BAAmC;AAEtB,QAAA,aAAa,GAAG,IAAA,+BAAY,EAAC;IACxC,IAAI,EAAE,aAAS;IACf,IAAI,EAAE,gBAAgB;IACtB,WAAW,EAAE,6CAA6C;IAC1D,WAAW,EAAE,WAAW;IACxB,KAAK,EAAE;QACL,UAAU,EAAE,2BAAQ,CAAC,SAAS,CAAC;YAC7B,WAAW,EAAE,YAAY;YACzB,WAAW,EAAE,mCAAmC;YAChD,QAAQ,EAAE,IAAI;SACf,CAAC;QACF,MAAM,EAAE,2BAAQ,CAAC,cAAc,CAAqB;YAClD,WAAW,EAAE,QAAQ;YACrB,WAAW,EAAE,oBAAoB;YACjC,QAAQ,EAAE,KAAK;YACf,YAAY,EAAE,2BAAkB,CAAC,IAAI;YACrC,OAAO,EAAE;gBACP,QAAQ,EAAE,KAAK;gBACf,OAAO,EAAE;oBACP,EAAE,KAAK,EAAE,2BAAkB,CAAC,OAAO,EAAE,KAAK,EAAE,SAAS,EAAE;oBACvD,EAAE,KAAK,EAAE,2BAAkB,CAAC,IAAI,EAAE,KAAK,EAAE,MAAM,EAAE;oBACjD,EAAE,KAAK,EAAE,2BAAkB,CAAC,GAAG,EAAE,KAAK,EAAE,KAAK,EAAE;oBAC/C,EAAE,KAAK,EAAE,2BAAkB,CAAC,QAAQ,EAAE,KAAK,EAAE,UAAU,EAAE;iBAC1D;aACF;SACF,CAAC;KACH;IACD,GAAG,EAAE,CAAO,EAAE,IAAI,EAAE,UAAU,EAAE,EAAE,MAAM,EAAE,UAAU,EAAE,EAAE,EAAE,EAAE;QAC1D,OAAA,MAAM,oBAAa,CAAC,OAAO,CAAC;YAC1B,YAAY,EAAE,IAAI,CAAC,YAAY;YAC/B,UAAU;YACV,MAAM,EAAE,MAAM,aAAN,MAAM,cAAN,MAAM,GAAI,2BAAkB,CAAC,IAAI;SAC1C,CAAC,CAAA;MAAA;CACL,CAAC,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { GmailMessageFormat } from '../common/models';
|
|
2
|
-
export declare const gmailGetThread: import("@activepieces/pieces-framework").IAction<import("@activepieces/pieces-framework").OAuth2Property<
|
|
2
|
+
export declare const gmailGetThread: import("@activepieces/pieces-framework").IAction<import("@activepieces/pieces-framework").OAuth2Property<import("@activepieces/pieces-framework").OAuth2Props>, {
|
|
3
3
|
thread_id: import("@activepieces/pieces-framework").ShortTextProperty<true>;
|
|
4
4
|
format: import("@activepieces/pieces-framework").StaticDropdownProperty<GmailMessageFormat, false> | import("@activepieces/pieces-framework").StaticDropdownProperty<GmailMessageFormat, true>;
|
|
5
5
|
}>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { GmailLabel } from '../common/models';
|
|
2
|
-
export declare const gmailSearchMail: import("@activepieces/pieces-framework").IAction<import("@activepieces/pieces-framework").OAuth2Property<
|
|
2
|
+
export declare const gmailSearchMail: import("@activepieces/pieces-framework").IAction<import("@activepieces/pieces-framework").OAuth2Property<import("@activepieces/pieces-framework").OAuth2Props>, {
|
|
3
3
|
subject: import("@activepieces/pieces-framework").ShortTextProperty<false>;
|
|
4
4
|
from: import("@activepieces/pieces-framework").ShortTextProperty<false>;
|
|
5
5
|
to: import("@activepieces/pieces-framework").ShortTextProperty<false>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export declare const gmailSendEmailAction: import("@activepieces/pieces-framework").IAction<import("@activepieces/pieces-framework").OAuth2Property<
|
|
1
|
+
export declare const gmailSendEmailAction: import("@activepieces/pieces-framework").IAction<import("@activepieces/pieces-framework").OAuth2Property<import("@activepieces/pieces-framework").OAuth2Props>, {
|
|
2
2
|
receiver: import("@activepieces/pieces-framework").ArrayProperty<true>;
|
|
3
3
|
cc: import("@activepieces/pieces-framework").ArrayProperty<false>;
|
|
4
4
|
bcc: import("@activepieces/pieces-framework").ArrayProperty<false>;
|
|
@@ -5,5 +5,5 @@ export declare const GmailProps: {
|
|
|
5
5
|
subject: import("@activepieces/pieces-framework").ShortTextProperty<false>;
|
|
6
6
|
category: import("@activepieces/pieces-framework").StaticDropdownProperty<string, false>;
|
|
7
7
|
label: import("@activepieces/pieces-framework").DropdownProperty<GmailLabel, false> | import("@activepieces/pieces-framework").DropdownProperty<GmailLabel, true>;
|
|
8
|
-
unread: (required?: boolean) => import("@activepieces/pieces-framework").CheckboxProperty<
|
|
8
|
+
unread: (required?: boolean) => import("@activepieces/pieces-framework").CheckboxProperty<true> | import("@activepieces/pieces-framework").CheckboxProperty<false>;
|
|
9
9
|
};
|
|
@@ -1,6 +1,18 @@
|
|
|
1
1
|
import { TriggerStrategy } from '@activepieces/pieces-framework';
|
|
2
2
|
import { GmailLabel } from '../common/models';
|
|
3
|
-
export declare const gmailNewEmailTrigger: import("@activepieces/pieces-framework").ITrigger<TriggerStrategy.
|
|
3
|
+
export declare const gmailNewEmailTrigger: import("@activepieces/pieces-framework").ITrigger<TriggerStrategy.WEBHOOK, import("@activepieces/pieces-framework").OAuth2Property<import("@activepieces/pieces-framework").OAuth2Props>, {
|
|
4
|
+
subject: import("@activepieces/pieces-framework").ShortTextProperty<false>;
|
|
5
|
+
from: import("@activepieces/pieces-framework").ShortTextProperty<false>;
|
|
6
|
+
to: import("@activepieces/pieces-framework").ShortTextProperty<false>;
|
|
7
|
+
label: import("@activepieces/pieces-framework").DropdownProperty<GmailLabel, false> | import("@activepieces/pieces-framework").DropdownProperty<GmailLabel, true>;
|
|
8
|
+
category: import("@activepieces/pieces-framework").StaticDropdownProperty<string, false>;
|
|
9
|
+
}> | import("@activepieces/pieces-framework").ITrigger<TriggerStrategy.POLLING, import("@activepieces/pieces-framework").OAuth2Property<import("@activepieces/pieces-framework").OAuth2Props>, {
|
|
10
|
+
subject: import("@activepieces/pieces-framework").ShortTextProperty<false>;
|
|
11
|
+
from: import("@activepieces/pieces-framework").ShortTextProperty<false>;
|
|
12
|
+
to: import("@activepieces/pieces-framework").ShortTextProperty<false>;
|
|
13
|
+
label: import("@activepieces/pieces-framework").DropdownProperty<GmailLabel, false> | import("@activepieces/pieces-framework").DropdownProperty<GmailLabel, true>;
|
|
14
|
+
category: import("@activepieces/pieces-framework").StaticDropdownProperty<string, false>;
|
|
15
|
+
}> | import("@activepieces/pieces-framework").ITrigger<TriggerStrategy.APP_WEBHOOK, import("@activepieces/pieces-framework").OAuth2Property<import("@activepieces/pieces-framework").OAuth2Props>, {
|
|
4
16
|
subject: import("@activepieces/pieces-framework").ShortTextProperty<false>;
|
|
5
17
|
from: import("@activepieces/pieces-framework").ShortTextProperty<false>;
|
|
6
18
|
to: import("@activepieces/pieces-framework").ShortTextProperty<false>;
|