@green-api/n8n-nodes-telegram-greenapi 0.0.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/LICENSE.md +19 -0
- package/README.md +113 -0
- package/dist/credentials/GreenApiAuthApi.credentials.d.ts +8 -0
- package/dist/credentials/GreenApiAuthApi.credentials.js +64 -0
- package/dist/credentials/GreenApiAuthApi.credentials.js.map +1 -0
- package/dist/nodes/Greenapi/Greenapi.node.d.ts +5 -0
- package/dist/nodes/Greenapi/Greenapi.node.js +123 -0
- package/dist/nodes/Greenapi/Greenapi.node.js.map +1 -0
- package/dist/nodes/Greenapi/GreenapiTrigger.node.d.ts +6 -0
- package/dist/nodes/Greenapi/GreenapiTrigger.node.js +163 -0
- package/dist/nodes/Greenapi/GreenapiTrigger.node.js.map +1 -0
- package/dist/nodes/Greenapi/greenapi.svg +47 -0
- package/dist/nodes/Greenapi/helpers/executePerItem.d.ts +2 -0
- package/dist/nodes/Greenapi/helpers/executePerItem.js +30 -0
- package/dist/nodes/Greenapi/helpers/executePerItem.js.map +1 -0
- package/dist/nodes/Greenapi/helpers/getParams.d.ts +8 -0
- package/dist/nodes/Greenapi/helpers/getParams.js +11 -0
- package/dist/nodes/Greenapi/helpers/getParams.js.map +1 -0
- package/dist/nodes/Greenapi/helpers/request.d.ts +2 -0
- package/dist/nodes/Greenapi/helpers/request.js +19 -0
- package/dist/nodes/Greenapi/helpers/request.js.map +1 -0
- package/dist/nodes/Greenapi/operations/checkAccount.d.ts +2 -0
- package/dist/nodes/Greenapi/operations/checkAccount.js +14 -0
- package/dist/nodes/Greenapi/operations/checkAccount.js.map +1 -0
- package/dist/nodes/Greenapi/operations/getAccountSettings.d.ts +2 -0
- package/dist/nodes/Greenapi/operations/getAccountSettings.js +10 -0
- package/dist/nodes/Greenapi/operations/getAccountSettings.js.map +1 -0
- package/dist/nodes/Greenapi/operations/getAvatar.d.ts +2 -0
- package/dist/nodes/Greenapi/operations/getAvatar.js +14 -0
- package/dist/nodes/Greenapi/operations/getAvatar.js.map +1 -0
- package/dist/nodes/Greenapi/operations/getChatHistory.d.ts +2 -0
- package/dist/nodes/Greenapi/operations/getChatHistory.js +16 -0
- package/dist/nodes/Greenapi/operations/getChatHistory.js.map +1 -0
- package/dist/nodes/Greenapi/operations/getChats.d.ts +2 -0
- package/dist/nodes/Greenapi/operations/getChats.js +10 -0
- package/dist/nodes/Greenapi/operations/getChats.js.map +1 -0
- package/dist/nodes/Greenapi/operations/getContactInfo.d.ts +2 -0
- package/dist/nodes/Greenapi/operations/getContactInfo.js +14 -0
- package/dist/nodes/Greenapi/operations/getContactInfo.js.map +1 -0
- package/dist/nodes/Greenapi/operations/getContacts.d.ts +2 -0
- package/dist/nodes/Greenapi/operations/getContacts.js +10 -0
- package/dist/nodes/Greenapi/operations/getContacts.js.map +1 -0
- package/dist/nodes/Greenapi/operations/getGroupData.d.ts +2 -0
- package/dist/nodes/Greenapi/operations/getGroupData.js +14 -0
- package/dist/nodes/Greenapi/operations/getGroupData.js.map +1 -0
- package/dist/nodes/Greenapi/operations/getMessage.d.ts +2 -0
- package/dist/nodes/Greenapi/operations/getMessage.js +16 -0
- package/dist/nodes/Greenapi/operations/getMessage.js.map +1 -0
- package/dist/nodes/Greenapi/operations/getStateInstance.d.ts +2 -0
- package/dist/nodes/Greenapi/operations/getStateInstance.js +10 -0
- package/dist/nodes/Greenapi/operations/getStateInstance.js.map +1 -0
- package/dist/nodes/Greenapi/operations/lastIncomingMessages.d.ts +2 -0
- package/dist/nodes/Greenapi/operations/lastIncomingMessages.js +23 -0
- package/dist/nodes/Greenapi/operations/lastIncomingMessages.js.map +1 -0
- package/dist/nodes/Greenapi/operations/lastOutgoingMessages.d.ts +2 -0
- package/dist/nodes/Greenapi/operations/lastOutgoingMessages.js +23 -0
- package/dist/nodes/Greenapi/operations/lastOutgoingMessages.js.map +1 -0
- package/dist/nodes/Greenapi/operations/readChat.d.ts +2 -0
- package/dist/nodes/Greenapi/operations/readChat.js +14 -0
- package/dist/nodes/Greenapi/operations/readChat.js.map +1 -0
- package/dist/nodes/Greenapi/operations/reboot.d.ts +2 -0
- package/dist/nodes/Greenapi/operations/reboot.js +10 -0
- package/dist/nodes/Greenapi/operations/reboot.js.map +1 -0
- package/dist/nodes/Greenapi/operations/sendFileByUrl.d.ts +2 -0
- package/dist/nodes/Greenapi/operations/sendFileByUrl.js +22 -0
- package/dist/nodes/Greenapi/operations/sendFileByUrl.js.map +1 -0
- package/dist/nodes/Greenapi/operations/sendMessage.d.ts +2 -0
- package/dist/nodes/Greenapi/operations/sendMessage.js +20 -0
- package/dist/nodes/Greenapi/operations/sendMessage.js.map +1 -0
- package/dist/nodes/Greenapi/operations/sendPoll.d.ts +2 -0
- package/dist/nodes/Greenapi/operations/sendPoll.js +32 -0
- package/dist/nodes/Greenapi/operations/sendPoll.js.map +1 -0
- package/dist/nodes/Greenapi/properties/account/account.description.d.ts +1 -0
- package/dist/nodes/Greenapi/properties/account/account.description.js +16 -0
- package/dist/nodes/Greenapi/properties/account/account.description.js.map +1 -0
- package/dist/nodes/Greenapi/properties/account/accountOperations.d.ts +2 -0
- package/dist/nodes/Greenapi/properties/account/accountOperations.js +24 -0
- package/dist/nodes/Greenapi/properties/account/accountOperations.js.map +1 -0
- package/dist/nodes/Greenapi/properties/account/fields/getAccountSettings.d.ts +2 -0
- package/dist/nodes/Greenapi/properties/account/fields/getAccountSettings.js +5 -0
- package/dist/nodes/Greenapi/properties/account/fields/getAccountSettings.js.map +1 -0
- package/dist/nodes/Greenapi/properties/account/fields/getStateInstance.d.ts +2 -0
- package/dist/nodes/Greenapi/properties/account/fields/getStateInstance.js +5 -0
- package/dist/nodes/Greenapi/properties/account/fields/getStateInstance.js.map +1 -0
- package/dist/nodes/Greenapi/properties/account/fields/reboot.d.ts +2 -0
- package/dist/nodes/Greenapi/properties/account/fields/reboot.js +5 -0
- package/dist/nodes/Greenapi/properties/account/fields/reboot.js.map +1 -0
- package/dist/nodes/Greenapi/properties/account/fields/setSettings.d.ts +2 -0
- package/dist/nodes/Greenapi/properties/account/fields/setSettings.js +121 -0
- package/dist/nodes/Greenapi/properties/account/fields/setSettings.js.map +1 -0
- package/dist/nodes/Greenapi/properties/index.d.ts +4 -0
- package/dist/nodes/Greenapi/properties/index.js +32 -0
- package/dist/nodes/Greenapi/properties/index.js.map +1 -0
- package/dist/nodes/Greenapi/properties/journal.d.ts +2 -0
- package/dist/nodes/Greenapi/properties/journal.js +78 -0
- package/dist/nodes/Greenapi/properties/journal.js.map +1 -0
- package/dist/nodes/Greenapi/properties/sending.d.ts +2 -0
- package/dist/nodes/Greenapi/properties/sending.js +153 -0
- package/dist/nodes/Greenapi/properties/sending.js.map +1 -0
- package/dist/nodes/Greenapi/properties/service.d.ts +2 -0
- package/dist/nodes/Greenapi/properties/service.js +55 -0
- package/dist/nodes/Greenapi/properties/service.js.map +1 -0
- package/dist/nodes/Greenapi/types/types.d.ts +60 -0
- package/dist/nodes/Greenapi/types/types.js +3 -0
- package/dist/nodes/Greenapi/types/types.js.map +1 -0
- package/dist/package.json +56 -0
- package/dist/tsconfig.tsbuildinfo +1 -0
- package/package.json +56 -0
|
@@ -0,0 +1,121 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.setSettingsFields = void 0;
|
|
4
|
+
exports.setSettingsFields = [
|
|
5
|
+
{
|
|
6
|
+
displayName: 'Settings',
|
|
7
|
+
name: 'settings',
|
|
8
|
+
type: 'collection',
|
|
9
|
+
default: {},
|
|
10
|
+
options: [
|
|
11
|
+
{
|
|
12
|
+
displayName: 'webhookUrl',
|
|
13
|
+
name: 'webhookUrl',
|
|
14
|
+
type: 'string',
|
|
15
|
+
default: '',
|
|
16
|
+
description: 'URL for sending notifications',
|
|
17
|
+
},
|
|
18
|
+
{
|
|
19
|
+
displayName: 'webhookUrlToken',
|
|
20
|
+
name: 'webhookUrlToken',
|
|
21
|
+
type: 'string',
|
|
22
|
+
typeOptions: { password: true },
|
|
23
|
+
default: '',
|
|
24
|
+
description: 'Token to access your notification server',
|
|
25
|
+
},
|
|
26
|
+
{
|
|
27
|
+
displayName: 'delaySendMessagesMilliseconds',
|
|
28
|
+
name: 'delaySendMessagesMilliseconds',
|
|
29
|
+
type: 'number',
|
|
30
|
+
placeholder: 'Recommended 15000',
|
|
31
|
+
default: 15000,
|
|
32
|
+
description: 'Message sending delay is in milliseconds. Recommended value: 15000.',
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
displayName: 'markIncomingMessagesReaded',
|
|
36
|
+
name: 'markIncomingMessagesReaded',
|
|
37
|
+
type: 'boolean',
|
|
38
|
+
default: false,
|
|
39
|
+
description: 'Mark incoming messages read on reply from API',
|
|
40
|
+
},
|
|
41
|
+
{
|
|
42
|
+
displayName: 'outgoingWebhook',
|
|
43
|
+
name: 'outgoingWebhook',
|
|
44
|
+
type: 'boolean',
|
|
45
|
+
default: false,
|
|
46
|
+
description: 'Receive notifications about outgoing messages statuses',
|
|
47
|
+
},
|
|
48
|
+
{
|
|
49
|
+
displayName: 'outgoingMessageWebhook',
|
|
50
|
+
name: 'outgoingMessageWebhook',
|
|
51
|
+
type: 'boolean',
|
|
52
|
+
default: false,
|
|
53
|
+
description: 'Receive notifications about messages sent from the phone',
|
|
54
|
+
},
|
|
55
|
+
{
|
|
56
|
+
displayName: 'outgoingAPIMessageWebhook',
|
|
57
|
+
name: 'outgoingAPIMessageWebhook',
|
|
58
|
+
type: 'boolean',
|
|
59
|
+
default: false,
|
|
60
|
+
description: 'Receive notifications about messages sent from API',
|
|
61
|
+
},
|
|
62
|
+
{
|
|
63
|
+
displayName: 'stateWebhook',
|
|
64
|
+
name: 'stateWebhook',
|
|
65
|
+
type: 'boolean',
|
|
66
|
+
default: false,
|
|
67
|
+
description: 'Receive notifications about the instance authorization state change',
|
|
68
|
+
},
|
|
69
|
+
{
|
|
70
|
+
displayName: 'incomingWebhook',
|
|
71
|
+
name: 'incomingWebhook',
|
|
72
|
+
type: 'boolean',
|
|
73
|
+
default: false,
|
|
74
|
+
description: 'Receive notifications about incoming messages and files',
|
|
75
|
+
},
|
|
76
|
+
{
|
|
77
|
+
displayName: 'keepOnlineStatus',
|
|
78
|
+
name: 'keepOnlineStatus',
|
|
79
|
+
type: 'boolean',
|
|
80
|
+
default: false,
|
|
81
|
+
description: 'Keep "online" status',
|
|
82
|
+
},
|
|
83
|
+
{
|
|
84
|
+
displayName: 'pollMessageWebhook',
|
|
85
|
+
name: 'pollMessageWebhook',
|
|
86
|
+
type: 'boolean',
|
|
87
|
+
default: false,
|
|
88
|
+
description: 'Receive notifications about polls',
|
|
89
|
+
},
|
|
90
|
+
{
|
|
91
|
+
displayName: 'incomingCallWebhook',
|
|
92
|
+
name: 'incomingCallWebhook',
|
|
93
|
+
type: 'boolean',
|
|
94
|
+
default: false,
|
|
95
|
+
description: 'Receive notifications about incoming calls',
|
|
96
|
+
},
|
|
97
|
+
{
|
|
98
|
+
displayName: 'editedMessageWebhook',
|
|
99
|
+
name: 'editedMessageWebhook',
|
|
100
|
+
type: 'boolean',
|
|
101
|
+
default: false,
|
|
102
|
+
description: 'Receive notifications about edited messages',
|
|
103
|
+
},
|
|
104
|
+
{
|
|
105
|
+
displayName: 'deletedMessageWebhook',
|
|
106
|
+
name: 'deletedMessageWebhook',
|
|
107
|
+
type: 'boolean',
|
|
108
|
+
default: false,
|
|
109
|
+
description: 'Receive notifications about deleted messages',
|
|
110
|
+
},
|
|
111
|
+
],
|
|
112
|
+
displayOptions: {
|
|
113
|
+
show: {
|
|
114
|
+
resource: ['account'],
|
|
115
|
+
operation: ['setSettings'],
|
|
116
|
+
},
|
|
117
|
+
},
|
|
118
|
+
required: true,
|
|
119
|
+
},
|
|
120
|
+
];
|
|
121
|
+
//# sourceMappingURL=setSettings.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"setSettings.js","sourceRoot":"","sources":["../../../../../../nodes/Greenapi/proper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";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.properties = exports.baseProperties = void 0;
|
|
4
|
+
const account_description_1 = require("./account/account.description");
|
|
5
|
+
const sending_1 = require("./sending");
|
|
6
|
+
const journal_1 = require("./journal");
|
|
7
|
+
const service_1 = require("./service");
|
|
8
|
+
exports.baseProperties = [
|
|
9
|
+
{
|
|
10
|
+
displayName: 'Resource',
|
|
11
|
+
name: 'resource',
|
|
12
|
+
type: 'options',
|
|
13
|
+
options: [
|
|
14
|
+
{ name: 'Account', value: 'account' },
|
|
15
|
+
{ name: 'Journal', value: 'journal' },
|
|
16
|
+
{ name: 'Sending', value: 'sending' },
|
|
17
|
+
{ name: 'Service', value: 'service' },
|
|
18
|
+
],
|
|
19
|
+
noDataExpression: true,
|
|
20
|
+
required: true,
|
|
21
|
+
default: 'sending',
|
|
22
|
+
},
|
|
23
|
+
];
|
|
24
|
+
exports.properties = [
|
|
25
|
+
...exports.baseProperties,
|
|
26
|
+
...account_description_1.accountDescription,
|
|
27
|
+
...sending_1.sendingOperations,
|
|
28
|
+
...journal_1.journalOperations,
|
|
29
|
+
...service_1.serviceOperations,
|
|
30
|
+
];
|
|
31
|
+
exports.default = exports.properties;
|
|
32
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../nodes/Greenapi/properties/index.ts"],"names":[],"mappings":";;;AACA,uEAAmE;AACnE,uCAA8C;AAC9C,uCAA8C;AAC9C,uCAA8C;AAEjC,QAAA,cAAc,GAAsB;IAChD;QACC,WAAW,EAAE,UAAU;QACvB,IAAI,EAAE,UAAU;QAChB,IAAI,EAAE,SAAS;QACf,OAAO,EAAE;YACR,EAAE,IAAI,EAAE,SAAS,EAAE,KAAK,EAAE,SAAS,EAAE;YACrC,EAAE,IAAI,EAAE,SAAS,EAAE,KAAK,EAAE,SAAS,EAAE;YACrC,EAAE,IAAI,EAAE,SAAS,EAAE,KAAK,EAAE,SAAS,EAAE;YACrC,EAAE,IAAI,EAAE,SAAS,EAAE,KAAK,EAAE,SAAS,EAAE;SACrC;QACD,gBAAgB,EAAE,IAAI;QACtB,QAAQ,EAAE,IAAI;QACd,OAAO,EAAE,SAAS;KAClB;CACD,CAAC;AAEW,QAAA,UAAU,GAAsB;IAC5C,GAAG,sBAAc;IACjB,GAAG,wCAAkB;IACrB,GAAG,2BAAiB;IACpB,GAAG,2BAAiB;IACpB,GAAG,2BAAiB;CACpB,CAAC;AAEF,kBAAe,kBAAU,CAAC"}
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.journalOperations = void 0;
|
|
4
|
+
exports.journalOperations = [
|
|
5
|
+
{
|
|
6
|
+
displayName: 'Operation',
|
|
7
|
+
name: 'operation',
|
|
8
|
+
type: 'options',
|
|
9
|
+
noDataExpression: true,
|
|
10
|
+
displayOptions: {
|
|
11
|
+
show: {
|
|
12
|
+
resource: ['journal'],
|
|
13
|
+
},
|
|
14
|
+
},
|
|
15
|
+
options: [
|
|
16
|
+
{ name: 'getChatHistory', value: 'getChatHistory', action: 'Get chat history' },
|
|
17
|
+
{ name: 'getMessage', value: 'getMessage', action: 'Get a message' },
|
|
18
|
+
{ name: 'lastIncomingMessages', value: 'lastIncomingMessages', action: 'Get last incoming messages' },
|
|
19
|
+
{ name: 'lastOutgoingMessages', value: 'lastOutgoingMessages', action: 'Get last outgoing messages' },
|
|
20
|
+
],
|
|
21
|
+
default: 'lastIncomingMessages',
|
|
22
|
+
},
|
|
23
|
+
{
|
|
24
|
+
displayName: 'Minutes',
|
|
25
|
+
name: 'minutes',
|
|
26
|
+
type: 'string',
|
|
27
|
+
default: '',
|
|
28
|
+
placeholder: '(1440 minutes by default)',
|
|
29
|
+
displayOptions: {
|
|
30
|
+
show: {
|
|
31
|
+
operation: ['lastIncomingMessages', 'lastOutgoingMessages'],
|
|
32
|
+
},
|
|
33
|
+
},
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
displayName: 'chatId',
|
|
37
|
+
name: 'chatId',
|
|
38
|
+
placeholder: '7596558806',
|
|
39
|
+
type: 'string',
|
|
40
|
+
default: '',
|
|
41
|
+
displayOptions: {
|
|
42
|
+
show: {
|
|
43
|
+
resource: ['journal',],
|
|
44
|
+
operation: ['getChatHistory', 'getMessage',],
|
|
45
|
+
},
|
|
46
|
+
},
|
|
47
|
+
required: true,
|
|
48
|
+
},
|
|
49
|
+
{
|
|
50
|
+
displayName: 'idMessage',
|
|
51
|
+
name: 'idMessage',
|
|
52
|
+
placeholder: 'BAE01234567890ABC',
|
|
53
|
+
type: 'string',
|
|
54
|
+
default: '',
|
|
55
|
+
displayOptions: {
|
|
56
|
+
show: {
|
|
57
|
+
resource: ['journal',],
|
|
58
|
+
operation: ['getMessage',],
|
|
59
|
+
},
|
|
60
|
+
},
|
|
61
|
+
required: true,
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
displayName: 'count',
|
|
65
|
+
name: 'count',
|
|
66
|
+
placeholder: 'BAE01234567890ABC',
|
|
67
|
+
type: 'number',
|
|
68
|
+
default: 100,
|
|
69
|
+
displayOptions: {
|
|
70
|
+
show: {
|
|
71
|
+
resource: ['journal',],
|
|
72
|
+
operation: ['getChatHistory',],
|
|
73
|
+
},
|
|
74
|
+
},
|
|
75
|
+
required: false,
|
|
76
|
+
},
|
|
77
|
+
];
|
|
78
|
+
//# sourceMappingURL=journal.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"journal.js","sourceRoot":"","sources":["../../../../nodes/Greenapi/properties/journal.ts"],"names":[],"mappings":";;;AAEa,QAAA,iBAAiB,GAAsB;IAChD;QACI,WAAW,EAAE,WAAW;QACxB,IAAI,EAAE,WAAW;QACjB,IAAI,EAAE,SAAS;QACf,gBAAgB,EAAE,IAAI;QACtB,cAAc,EAAE;YACZ,IAAI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C5B;SACJ;QACD,QAAQ,EAAE,IAAI;KACjB;IACD;QACI,WAAW,EAAE,OAAO;QACpB,IAAI,EAAE,OAAO;QACb,WAAW,EAAE,mBAAmB;QAChC,IAAI,EAAE,QAAQ;QACd,OAAO,EAAE,GAAG;QACZ,cAAc,EAAE;YACZ,IAAI,EAAE;gBACF,QAAQ,EAAE,CAAC,SAAS,EAAE;gBACtB,SAAS,EAAC,CAAC,gBAAgB,EAAE;aAChC;SACJ;QACD,QAAQ,EAAE,KAAK;KAClB;CACJ,CAAC"}
|
|
@@ -0,0 +1,153 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.sendingOperations = void 0;
|
|
4
|
+
exports.sendingOperations = [
|
|
5
|
+
{
|
|
6
|
+
displayName: 'Operation',
|
|
7
|
+
name: 'operation',
|
|
8
|
+
type: 'options',
|
|
9
|
+
noDataExpression: true,
|
|
10
|
+
displayOptions: {
|
|
11
|
+
show: {
|
|
12
|
+
resource: ['sending'],
|
|
13
|
+
},
|
|
14
|
+
},
|
|
15
|
+
options: [
|
|
16
|
+
{ name: 'sendFileByUrl', value: 'sendFileByUrl', action: 'Send file by url' },
|
|
17
|
+
{ name: 'sendMessage', value: 'sendMessage', action: 'Send message' },
|
|
18
|
+
{ name: 'sendPoll', value: 'sendPoll', action: 'Send poll' },
|
|
19
|
+
],
|
|
20
|
+
default: 'sendMessage',
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
displayName: 'chatId',
|
|
24
|
+
name: 'chatId',
|
|
25
|
+
type: 'string',
|
|
26
|
+
required: true,
|
|
27
|
+
default: '',
|
|
28
|
+
placeholder: 'chatId',
|
|
29
|
+
displayOptions: {
|
|
30
|
+
show: {
|
|
31
|
+
operation: ['sendMessage', 'sendFileByUrl', 'sendPoll'],
|
|
32
|
+
},
|
|
33
|
+
},
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
displayName: 'quotedMessageId',
|
|
37
|
+
name: 'quotedMessageId',
|
|
38
|
+
required: false,
|
|
39
|
+
type: 'string',
|
|
40
|
+
default: '',
|
|
41
|
+
placeholder: '(optional)',
|
|
42
|
+
displayOptions: {
|
|
43
|
+
show: {
|
|
44
|
+
operation: ['sendMessage', 'sendFileByUrl', 'sendPoll'],
|
|
45
|
+
},
|
|
46
|
+
},
|
|
47
|
+
},
|
|
48
|
+
{
|
|
49
|
+
displayName: 'Message',
|
|
50
|
+
name: 'message',
|
|
51
|
+
type: 'string',
|
|
52
|
+
default: '',
|
|
53
|
+
required: true,
|
|
54
|
+
displayOptions: {
|
|
55
|
+
show: {
|
|
56
|
+
operation: ['sendMessage', 'sendPoll'],
|
|
57
|
+
},
|
|
58
|
+
},
|
|
59
|
+
},
|
|
60
|
+
{
|
|
61
|
+
displayName: 'Caption',
|
|
62
|
+
name: 'caption',
|
|
63
|
+
type: 'string',
|
|
64
|
+
default: '',
|
|
65
|
+
displayOptions: {
|
|
66
|
+
show: {
|
|
67
|
+
operation: ['sendFileByUrl'],
|
|
68
|
+
},
|
|
69
|
+
},
|
|
70
|
+
},
|
|
71
|
+
{
|
|
72
|
+
displayName: 'fileName',
|
|
73
|
+
name: 'fileName',
|
|
74
|
+
type: 'string',
|
|
75
|
+
default: '',
|
|
76
|
+
placeholder: 'image.jpg',
|
|
77
|
+
required: true,
|
|
78
|
+
displayOptions: {
|
|
79
|
+
show: {
|
|
80
|
+
operation: ['sendFileByUrl'],
|
|
81
|
+
},
|
|
82
|
+
},
|
|
83
|
+
},
|
|
84
|
+
{
|
|
85
|
+
displayName: 'urlFile',
|
|
86
|
+
name: 'urlFile',
|
|
87
|
+
type: 'string',
|
|
88
|
+
default: '',
|
|
89
|
+
placeholder: 'https://my.site.com/my/image.jpg',
|
|
90
|
+
required: true,
|
|
91
|
+
displayOptions: {
|
|
92
|
+
show: {
|
|
93
|
+
operation: ['sendFileByUrl'],
|
|
94
|
+
},
|
|
95
|
+
},
|
|
96
|
+
},
|
|
97
|
+
{
|
|
98
|
+
displayName: 'Options',
|
|
99
|
+
name: 'options',
|
|
100
|
+
type: 'fixedCollection',
|
|
101
|
+
placeholder: 'Add Option',
|
|
102
|
+
default: {},
|
|
103
|
+
typeOptions: {
|
|
104
|
+
multipleValues: true,
|
|
105
|
+
},
|
|
106
|
+
options: [
|
|
107
|
+
{
|
|
108
|
+
displayName: 'Option',
|
|
109
|
+
name: 'option',
|
|
110
|
+
values: [
|
|
111
|
+
{
|
|
112
|
+
displayName: 'Option Name',
|
|
113
|
+
name: 'optionName',
|
|
114
|
+
type: 'string',
|
|
115
|
+
default: '',
|
|
116
|
+
placeholder: 'green, red, blue...',
|
|
117
|
+
},
|
|
118
|
+
],
|
|
119
|
+
},
|
|
120
|
+
],
|
|
121
|
+
displayOptions: {
|
|
122
|
+
show: {
|
|
123
|
+
operation: ['sendPoll'],
|
|
124
|
+
},
|
|
125
|
+
},
|
|
126
|
+
},
|
|
127
|
+
{
|
|
128
|
+
displayName: 'multipleAnswers',
|
|
129
|
+
name: 'multipleAnswers',
|
|
130
|
+
type: 'boolean',
|
|
131
|
+
default: false,
|
|
132
|
+
required: true,
|
|
133
|
+
displayOptions: {
|
|
134
|
+
show: {
|
|
135
|
+
operation: ['sendPoll'],
|
|
136
|
+
},
|
|
137
|
+
},
|
|
138
|
+
},
|
|
139
|
+
{
|
|
140
|
+
displayName: 'typingTime',
|
|
141
|
+
name: 'typingTime',
|
|
142
|
+
type: 'number',
|
|
143
|
+
default: '',
|
|
144
|
+
placeholder: '5000',
|
|
145
|
+
required: false,
|
|
146
|
+
displayOptions: {
|
|
147
|
+
show: {
|
|
148
|
+
operation: ['sendMessage', 'sendFileByUrl', 'sendPoll'],
|
|
149
|
+
},
|
|
150
|
+
},
|
|
151
|
+
},
|
|
152
|
+
];
|
|
153
|
+
//# sourceMappingURL=sending.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sending.js","sourceRoot":"","sources":["../../../../nodes/Greenapi/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WAAW,EAAE,iBAAiB;QAC9B,IAAI,EAAE,iBAAiB;QACvB,IAAI,EAAE,SAAS;QACf,OAAO,EAAE,KAAK;QACd,QAAQ,EAAE,IAAI;QACd,cAAc,EAAE;YACf,IAAI,EAAE;gBACL,SAAS,EAAE,CAAC,UAAU,CAAC;aACvB;SACD;KACD;IACD;QACC,WAAW,EAAE,YAAY;QACzB,IAAI,EAAE,YAAY;QAClB,IAAI,EAAE,QAAQ;QACd,OAAO,EAAE,EAAE;QACX,WAAW,EAAE,MAAM;QACnB,QAAQ,EAAE,KAAK;QACf,cAAc,EAAE;YACf,IAAI,EAAE;gBACL,SAAS,EAAE,CAAC,aAAa,EAAE,eAAe,EAAE,UAAU,CAAC;aACvD;SACD;KACD;CACD,CAAC"}
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.serviceOperations = void 0;
|
|
4
|
+
exports.serviceOperations = [
|
|
5
|
+
{
|
|
6
|
+
displayName: 'Operation',
|
|
7
|
+
name: 'operation',
|
|
8
|
+
type: 'options',
|
|
9
|
+
noDataExpression: true,
|
|
10
|
+
displayOptions: {
|
|
11
|
+
show: {
|
|
12
|
+
resource: ['service'],
|
|
13
|
+
},
|
|
14
|
+
},
|
|
15
|
+
options: [
|
|
16
|
+
{ name: 'checkAccount', value: 'checkAccount', action: 'Check TG account availability' },
|
|
17
|
+
{ name: 'getAvatar', value: 'getAvatar', action: 'Get avatar' },
|
|
18
|
+
{ name: 'getContactInfo', value: 'getContactInfo', action: 'Get contact info' },
|
|
19
|
+
{ name: 'getContacts', value: 'getContacts', action: 'Get contacts' },
|
|
20
|
+
{ name: 'getChats', value: 'getChats', action: 'Get chats' },
|
|
21
|
+
{ name: 'readChat', value: 'readChat', action: 'Mark chat as read' },
|
|
22
|
+
{ name: 'getGroupData', value: 'getGroupData', action: 'Get group data' },
|
|
23
|
+
],
|
|
24
|
+
default: 'getContacts',
|
|
25
|
+
},
|
|
26
|
+
{
|
|
27
|
+
displayName: 'chatId',
|
|
28
|
+
name: 'chatId',
|
|
29
|
+
placeholder: '7596558806',
|
|
30
|
+
type: 'string',
|
|
31
|
+
default: '',
|
|
32
|
+
displayOptions: {
|
|
33
|
+
show: {
|
|
34
|
+
resource: ['service',],
|
|
35
|
+
operation: ['getAvatar', 'getContactInfo', 'getGroupData', 'readChat'],
|
|
36
|
+
},
|
|
37
|
+
},
|
|
38
|
+
required: true,
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
displayName: 'phoneNumber',
|
|
42
|
+
name: 'phoneNumber',
|
|
43
|
+
placeholder: '77780738519',
|
|
44
|
+
type: 'number',
|
|
45
|
+
default: '',
|
|
46
|
+
displayOptions: {
|
|
47
|
+
show: {
|
|
48
|
+
resource: ['service',],
|
|
49
|
+
operation: ['checkAccount',],
|
|
50
|
+
},
|
|
51
|
+
},
|
|
52
|
+
required: true,
|
|
53
|
+
},
|
|
54
|
+
];
|
|
55
|
+
//# sourceMappingURL=service.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"service.js","sourceRoot":"","sources":["../../../../nodes/Greenapi/properties/service.ts"],"names":[],"mappings":";;;AAEa,QAAA,iBAAiB,GAAsB;IAChD;QACI,WAAW,EAAE,WAAW;QACxB,IAAI,EAAE,WAAW;QACjB,IAAI,EAAE,SAAS;QACf,gBAAgB,EAAE,IAAI;QACtB,cAAc,EAAE;YACZ,IAAI,EAAE;gBACF,QAAQ,EAAE,CAAC,SAAS,CAAC;aACxB;SACJ;QACD,OAAO,EAAE;YACL,EAAE,IAAI,EAAE,cAAc,EAAE,KAAK,EAAE,cAAc,EAAE,MAAM,EAAE,+BAA+B,EAAE;YACxF,EAAE,IAAI,EAAE,WAAW,EAAE,KAAK,EAAE,WAAW,EAAE,MAAM,EAAE,YAAY,EAAE;YAC/D,EAAE,IAAI,EAAE,gBAAgB,EAAE,KAAK,EAAE,gBAAgB,EAAE,MAAM,EAAE,kBAAkB,EAAE;YAC/E,EAAE,IAAI,EAAE,aAAa,EAAE,KAAK,EAAE,aAAa,EAAE,MAAM,EAAE,cAAc,EAAE;YACrE,EAAE,IAAI,EAAE,UAAU,EAAE,KAAK,EAAE,UAAU,EAAE,MAAM,EAAE,WAAW,EAAE;YAC5D,EAAE,IAAI,EAAE,UAAU,EAAE,KAAK,EAAE,UAAU,EAAE,MAAM,EAAE,mBAAmB,EAAE;YACpE,EAAE,IAAI,EAAE,cAAc,EAAE,KAAK,EAAE,cAAc,EAAE,MAAM,EAAE,gBAAgB,EAAC;SAC3E;QACD,OAAO,EAAE,aAAa;KACzB;IACD;QACI,WAAW,EAAE,QAAQ;QACrB,IAAI,EAAE,QAAQ;QACd,WAAW,EAAE,YAAY;QACzB,IAAI,EAAE,QAAQ;QACd,OAAO,EAAE,EAAE;QACX,cAAc,EAAE;YACZ,IAAI,EAAE;gBACF,QAAQ,EAAE,CAAC,SAAS,EAAE;gBACtB,SAAS,EAAC,CAAC,WAAW,EAAE,gBAAgB,EAAE,cAAc,EAAE,UAAU,CAAC;aACxE;SACJ;QACD,QAAQ,EAAE,IAAI;KACjB;IACD;QACI,WAAW,EAAE,aAAa;QAC1B,IAAI,EAAE,aAAa;QACnB,WAAW,EAAE,aAAa;QAC1B,IAAI,EAAE,QAAQ;QACd,OAAO,EAAE,EAAE;QACX,cAAc,EAAE;YACZ,IAAI,EAAE;gBACF,QAAQ,EAAE,CAAC,SAAS,EAAE;gBACtB,SAAS,EAAC,CAAC,cAAc,EAAE;aAC9B;SACJ;QACD,QAAQ,EAAE,IAAI;KACjB;CACJ,CAAC"}
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
export interface BaseParams {
|
|
2
|
+
chatId: string;
|
|
3
|
+
quotedMessageId?: string;
|
|
4
|
+
typingTime?: number;
|
|
5
|
+
}
|
|
6
|
+
export interface SendMessageParams extends BaseParams {
|
|
7
|
+
message: string;
|
|
8
|
+
}
|
|
9
|
+
export interface SendFileByUrlParams extends BaseParams {
|
|
10
|
+
urlFile: string;
|
|
11
|
+
fileName: string;
|
|
12
|
+
caption?: string;
|
|
13
|
+
}
|
|
14
|
+
export interface SendPollParams extends BaseParams {
|
|
15
|
+
message: string;
|
|
16
|
+
options: {
|
|
17
|
+
optionName: string;
|
|
18
|
+
}[];
|
|
19
|
+
multipleAnswers: boolean;
|
|
20
|
+
}
|
|
21
|
+
export interface LastIncomingMessagesParams {
|
|
22
|
+
minutes?: number;
|
|
23
|
+
}
|
|
24
|
+
export interface LastOutgoingMessagesParams {
|
|
25
|
+
minutes?: number;
|
|
26
|
+
}
|
|
27
|
+
export interface GetMessageParams {
|
|
28
|
+
chatId: string;
|
|
29
|
+
idMessage: string;
|
|
30
|
+
}
|
|
31
|
+
export interface GetChatHistoryParams {
|
|
32
|
+
chatId: string;
|
|
33
|
+
count?: number;
|
|
34
|
+
}
|
|
35
|
+
export interface GetStateInstanceParams {
|
|
36
|
+
}
|
|
37
|
+
export interface GetAccountSettingsParams {
|
|
38
|
+
}
|
|
39
|
+
export interface RebootParams {
|
|
40
|
+
}
|
|
41
|
+
export interface CheckAccountParams {
|
|
42
|
+
phoneNumber: number;
|
|
43
|
+
}
|
|
44
|
+
export interface ReadChatParams {
|
|
45
|
+
chatId: string;
|
|
46
|
+
}
|
|
47
|
+
export interface GetContactsParams {
|
|
48
|
+
}
|
|
49
|
+
export interface GetChatsParams {
|
|
50
|
+
}
|
|
51
|
+
export interface GetContactInfoParams {
|
|
52
|
+
chatId: string;
|
|
53
|
+
}
|
|
54
|
+
export interface GetAvatarParams {
|
|
55
|
+
chatId: string;
|
|
56
|
+
}
|
|
57
|
+
export interface GetGroupDataParams {
|
|
58
|
+
chatId: string;
|
|
59
|
+
}
|
|
60
|
+
export type GreenApiParams = SendMessageParams | SendFileByUrlParams | SendPollParams | GetStateInstanceParams | GetAccountSettingsParams | RebootParams | LastIncomingMessagesParams | LastOutgoingMessagesParams | GetMessageParams | GetChatHistoryParams | CheckAccountParams | ReadChatParams | GetContactsParams | GetChatsParams | GetContactInfoParams | GetAvatarParams | GetGroupDataParams;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../../nodes/Greenapi/types/types.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@green-api/n8n-nodes-telegram-greenapi",
|
|
3
|
+
"version": "0.0.1",
|
|
4
|
+
"description": "n8n node for Green-API for Telegramm",
|
|
5
|
+
"keywords": [
|
|
6
|
+
"n8n-community-node-package",
|
|
7
|
+
"greenapi",
|
|
8
|
+
"green-api",
|
|
9
|
+
"telegram",
|
|
10
|
+
"messaging",
|
|
11
|
+
"automation"
|
|
12
|
+
],
|
|
13
|
+
"license": "MIT",
|
|
14
|
+
"homepage": "",
|
|
15
|
+
"author": {
|
|
16
|
+
"name": "GREEN API",
|
|
17
|
+
"email": "support@green-api.com"
|
|
18
|
+
},
|
|
19
|
+
"repository": {
|
|
20
|
+
"type": "git",
|
|
21
|
+
"url": "https://github.com/green-api/n8n-nodes-telegram-green-api.git"
|
|
22
|
+
},
|
|
23
|
+
"main": "dist/index.js",
|
|
24
|
+
"scripts": {
|
|
25
|
+
"build": "tsc && gulp build:icons",
|
|
26
|
+
"dev": "tsc --watch",
|
|
27
|
+
"format": "prettier nodes credentials --write",
|
|
28
|
+
"lint": "eslint nodes credentials package.json",
|
|
29
|
+
"lintfix": "eslint nodes credentials package.json --fix",
|
|
30
|
+
"prepublishOnly": "npm run build"
|
|
31
|
+
},
|
|
32
|
+
"files": [
|
|
33
|
+
"dist"
|
|
34
|
+
],
|
|
35
|
+
"n8n": {
|
|
36
|
+
"n8nNodesApiVersion": 1,
|
|
37
|
+
"credentials": [
|
|
38
|
+
"dist/credentials/GreenApiAuthApi.credentials.js"
|
|
39
|
+
],
|
|
40
|
+
"nodes": [
|
|
41
|
+
"dist/nodes/Greenapi/Greenapi.node.js",
|
|
42
|
+
"dist/nodes/Greenapi/GreenapiTrigger.node.js"
|
|
43
|
+
]
|
|
44
|
+
},
|
|
45
|
+
"devDependencies": {
|
|
46
|
+
"@typescript-eslint/parser": "^6.21.0",
|
|
47
|
+
"eslint": "^8.57.1",
|
|
48
|
+
"eslint-plugin-n8n-nodes-base": "^1.16.4",
|
|
49
|
+
"gulp": "^5.0.1",
|
|
50
|
+
"prettier": "^2.7.1",
|
|
51
|
+
"typescript": "^5.9.3"
|
|
52
|
+
},
|
|
53
|
+
"peerDependencies": {
|
|
54
|
+
"n8n-workflow": "^2.6.0"
|
|
55
|
+
}
|
|
56
|
+
}
|