n8n-nodes-couchbase 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.
Files changed (33) hide show
  1. package/LICENSE.md +19 -0
  2. package/README.md +47 -0
  3. package/dist/credentials/CouchbaseCredentialsApi.credentials.d.ts +8 -0
  4. package/dist/credentials/CouchbaseCredentialsApi.credentials.js +46 -0
  5. package/dist/credentials/CouchbaseCredentialsApi.credentials.js.map +1 -0
  6. package/dist/credentials/ExampleCredentialsApi.credentials.d.ts +8 -0
  7. package/dist/credentials/ExampleCredentialsApi.credentials.js +46 -0
  8. package/dist/credentials/ExampleCredentialsApi.credentials.js.map +1 -0
  9. package/dist/credentials/HttpBinApi.credentials.d.ts +9 -0
  10. package/dist/credentials/HttpBinApi.credentials.js +40 -0
  11. package/dist/credentials/HttpBinApi.credentials.js.map +1 -0
  12. package/dist/nodes/CouchbaseDB/CBLogomark.svg +350 -0
  13. package/dist/nodes/CouchbaseDB/CouchbaseDB.node.d.ts +6 -0
  14. package/dist/nodes/CouchbaseDB/CouchbaseDB.node.js +274 -0
  15. package/dist/nodes/CouchbaseDB/CouchbaseDB.node.js.map +1 -0
  16. package/dist/nodes/CouchbaseNode/CBLogomark.svg +350 -0
  17. package/dist/nodes/CouchbaseNode/CouchbaseDb.node.d.ts +6 -0
  18. package/dist/nodes/CouchbaseNode/CouchbaseDb.node.js +274 -0
  19. package/dist/nodes/CouchbaseNode/CouchbaseDb.node.js.map +1 -0
  20. package/dist/nodes/CouchbaseNode/CouchbaseNode.node.d.ts +6 -0
  21. package/dist/nodes/CouchbaseNode/CouchbaseNode.node.js +274 -0
  22. package/dist/nodes/CouchbaseNode/CouchbaseNode.node.js.map +1 -0
  23. package/dist/nodes/ExampleNode/CBLogomark.svg +350 -0
  24. package/dist/nodes/ExampleNode/CouchbaseNode.node.d.ts +6 -0
  25. package/dist/nodes/ExampleNode/CouchbaseNode.node.js +234 -0
  26. package/dist/nodes/ExampleNode/CouchbaseNode.node.js.map +1 -0
  27. package/dist/nodes/ExampleNode/ExampleNode.node.d.ts +6 -0
  28. package/dist/nodes/ExampleNode/ExampleNode.node.js +234 -0
  29. package/dist/nodes/ExampleNode/ExampleNode.node.js.map +1 -0
  30. package/dist/package.json +54 -0
  31. package/dist/tsconfig.tsbuildinfo +1 -0
  32. package/index.js +0 -0
  33. package/package.json +54 -0
@@ -0,0 +1,274 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.CouchbaseDB = void 0;
4
+ const n8n_workflow_1 = require("n8n-workflow");
5
+ const couchbase_1 = require("couchbase");
6
+ class CouchbaseDB {
7
+ constructor() {
8
+ this.description = {
9
+ displayName: 'Couchbase',
10
+ name: 'couchbaseDB',
11
+ icon: 'file:CBLogomark.svg',
12
+ group: ['transform'],
13
+ version: 1,
14
+ description: 'Couchbase Node to add, update and delete data from couchbase',
15
+ defaults: {
16
+ name: 'Couchbase',
17
+ },
18
+ inputs: ['main'],
19
+ outputs: ['main'],
20
+ properties: [
21
+ {
22
+ displayName: 'Operation',
23
+ name: 'operation',
24
+ type: 'options',
25
+ noDataExpression: true,
26
+ options: [
27
+ {
28
+ name: 'Insert',
29
+ value: 'insert',
30
+ description: 'Insert document in couchbase',
31
+ action: 'Insert document in couchbase',
32
+ },
33
+ {
34
+ name: 'Update',
35
+ value: 'update',
36
+ description: 'Update document in couchbase',
37
+ action: 'Update document in couchbase',
38
+ },
39
+ {
40
+ name: 'Remove',
41
+ value: 'remove',
42
+ description: 'Remove document in couchbase',
43
+ action: 'Remove document in couchbase',
44
+ },
45
+ {
46
+ name: 'Find',
47
+ value: 'find',
48
+ description: 'Find document in couchbase',
49
+ action: 'Find document in couchbase',
50
+ },
51
+ ],
52
+ default: 'insert',
53
+ },
54
+ {
55
+ displayName: 'Connection String',
56
+ name: 'myConnection',
57
+ type: 'string',
58
+ displayOptions: {
59
+ show: {
60
+ operation: ['insert', 'update', 'remove', 'find'],
61
+ },
62
+ },
63
+ default: '',
64
+ placeholder: 'Enter Connection String',
65
+ description: 'The description text',
66
+ },
67
+ {
68
+ displayName: 'Username',
69
+ name: 'myUsername',
70
+ type: 'string',
71
+ displayOptions: {
72
+ show: {
73
+ operation: ['insert', 'update', 'remove', 'find'],
74
+ },
75
+ },
76
+ default: '',
77
+ placeholder: 'Enter Your Username',
78
+ description: 'The description text',
79
+ },
80
+ {
81
+ displayName: 'Password',
82
+ name: 'myPassword',
83
+ type: 'string',
84
+ displayOptions: {
85
+ show: {
86
+ operation: ['insert', 'update', 'remove', 'find'],
87
+ },
88
+ },
89
+ default: '',
90
+ placeholder: 'Enter Your Password',
91
+ description: 'The description text',
92
+ },
93
+ {
94
+ displayName: 'Bucket',
95
+ name: 'myBucket',
96
+ type: 'string',
97
+ displayOptions: {
98
+ show: {
99
+ operation: ['insert', 'update', 'remove', 'find'],
100
+ },
101
+ },
102
+ default: '',
103
+ placeholder: 'Enter Bucket Name',
104
+ description: 'The description text',
105
+ },
106
+ {
107
+ displayName: 'Scope',
108
+ name: 'myScope',
109
+ type: 'string',
110
+ displayOptions: {
111
+ show: {
112
+ operation: ['insert', 'update', 'remove', 'find'],
113
+ },
114
+ },
115
+ default: '',
116
+ placeholder: 'Enter Scope Name',
117
+ description: 'The description text',
118
+ },
119
+ {
120
+ displayName: 'Colection',
121
+ name: 'myCollection',
122
+ type: 'string',
123
+ displayOptions: {
124
+ show: {
125
+ operation: ['insert', 'update', 'remove', 'find'],
126
+ },
127
+ },
128
+ default: '',
129
+ placeholder: 'Enter Collection Name',
130
+ description: 'The description text',
131
+ },
132
+ {
133
+ displayName: 'Value',
134
+ name: 'myDocument',
135
+ type: 'string',
136
+ displayOptions: {
137
+ show: {
138
+ operation: ['insert'],
139
+ },
140
+ },
141
+ default: '',
142
+ placeholder: 'Placeholder value',
143
+ description: 'The description text',
144
+ },
145
+ {
146
+ displayName: 'ID',
147
+ name: 'myDocument',
148
+ type: 'string',
149
+ displayOptions: {
150
+ show: {
151
+ operation: ['update'],
152
+ },
153
+ },
154
+ default: '',
155
+ placeholder: 'Placeholder value',
156
+ description: 'The description text',
157
+ },
158
+ {
159
+ displayName: 'Value',
160
+ name: 'myValue',
161
+ type: 'string',
162
+ displayOptions: {
163
+ show: {
164
+ operation: ['update'],
165
+ },
166
+ },
167
+ default: '',
168
+ placeholder: 'Placeholder value',
169
+ description: 'The description text',
170
+ },
171
+ {
172
+ displayName: 'ID',
173
+ name: 'myDocument',
174
+ type: 'string',
175
+ displayOptions: {
176
+ show: {
177
+ operation: ['remove'],
178
+ },
179
+ },
180
+ default: '',
181
+ placeholder: 'Placeholder value',
182
+ description: 'The description text',
183
+ },
184
+ {
185
+ displayName: 'ID',
186
+ name: 'myDocument',
187
+ type: 'string',
188
+ displayOptions: {
189
+ show: {
190
+ operation: ['find'],
191
+ },
192
+ },
193
+ default: '',
194
+ placeholder: 'Placeholder value',
195
+ description: 'The description text',
196
+ },
197
+ ],
198
+ };
199
+ }
200
+ async execute() {
201
+ const items = this.getInputData();
202
+ let item;
203
+ let item2;
204
+ let myDocument;
205
+ let myNewValue;
206
+ let myUsername;
207
+ let myPassword;
208
+ let myBucket;
209
+ let myScope;
210
+ let myCollection;
211
+ let myConnection;
212
+ for (let itemIndex = 0; itemIndex < items.length; itemIndex++) {
213
+ try {
214
+ myNewValue = this.getNodeParameter('myValue', itemIndex, '');
215
+ myDocument = this.getNodeParameter('myDocument', itemIndex, '');
216
+ myUsername = this.getNodeParameter('myUsername', itemIndex, '');
217
+ myPassword = this.getNodeParameter('myPassword', itemIndex, '');
218
+ myBucket = this.getNodeParameter('myBucket', itemIndex, '');
219
+ myScope = this.getNodeParameter('myScope', itemIndex, '');
220
+ myCollection = this.getNodeParameter('myCollection', itemIndex, '');
221
+ myConnection = this.getNodeParameter('myConnection', itemIndex, '');
222
+ const clusterConnStr = myConnection;
223
+ const username = myUsername;
224
+ const password = myPassword;
225
+ const bucketName = myBucket;
226
+ const cluster = await (0, couchbase_1.connect)(clusterConnStr, {
227
+ username: username,
228
+ password: password,
229
+ configProfile: 'wanDevelopment'
230
+ });
231
+ const bucket = cluster.bucket(bucketName);
232
+ const collection = bucket
233
+ .scope(myScope)
234
+ .collection(myCollection);
235
+ item = items[itemIndex];
236
+ item.json['myDocument'] = myDocument;
237
+ const operation = this.getNodeParameter('operation', 0);
238
+ if (operation === 'insert') {
239
+ await collection.insert(myDocument, item.json);
240
+ }
241
+ else if (operation === 'update') {
242
+ item2 = items[itemIndex];
243
+ item2.json['myDocument'] = myNewValue;
244
+ await collection.upsert(myDocument, item2.json);
245
+ }
246
+ else if (operation === 'remove') {
247
+ await collection.remove(myDocument);
248
+ }
249
+ else if (operation === 'find') {
250
+ const getResult = await collection.get(myDocument);
251
+ console.log('Get Result:', getResult);
252
+ await collection.get(myDocument);
253
+ }
254
+ }
255
+ catch (error) {
256
+ if (this.continueOnFail()) {
257
+ items.push({ json: this.getInputData(itemIndex)[0].json, error, pairedItem: itemIndex });
258
+ }
259
+ else {
260
+ if (error.context) {
261
+ error.context.itemIndex = itemIndex;
262
+ throw error;
263
+ }
264
+ throw new n8n_workflow_1.NodeOperationError(this.getNode(), error, {
265
+ itemIndex,
266
+ });
267
+ }
268
+ }
269
+ }
270
+ return this.prepareOutputData(items);
271
+ }
272
+ }
273
+ exports.CouchbaseDB = CouchbaseDB;
274
+ //# sourceMappingURL=CouchbaseDB.node.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CouchbaseDB.node.js","sourceRoot":"","sources":["../../../nodes/CouchbaseNode/CouchbaseDB.node.ts"],"names":[],"mappings":";;;AACA,+CAKsB;AAEtB,yCAKoB;AAEpB,MAAa,WAAW;IAAxB;QACC,gBAAW,GAAyB;YACnC,WAAW,EAAE,WAAW;YACxB,IAAI,EAAE,aAAa;YACnB,IAAI,EAAE,qBAAqB;YAC3B,KAAK,EAAE,CAAC,WAAW,CAAC;YACpB,OAAO,EAAE,CAAC;YACV,WAAW,EAAE,8DAA8D;YAC3E,QAAQ,EAAE;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AAC;oBAE9B,MAAM,SAAS,GAAc,MAAM,UAAU,CAAC,GAAG,CAAC,UAAU,CAAC,CAAA;oBAC7D,OAAO,CAAC,GAAG,CAAC,aAAa,EAAE,SAAS,CAAC,CAAA;oBACrC,MAAM,UAAU,CAAC,GAAG,CAAC,UAAU,CAAC,CAAA;iBAEhC;aAGD;YAAC,OAAO,KAAK,EAAE;gBAGf,IAAI,IAAI,CAAC,cAAc,EAAE,EAAE;oBAC1B,KAAK,CAAC,IAAI,CAAC,EAAE,IAAI,EAAE,IAAI,CAAC,YAAY,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC,IAAI,EAAE,KAAK,EAAE,UAAU,EAAE,SAAS,EAAE,CAAC,CAAC;iBACzF;qBAAM;oBAEN,IAAI,KAAK,CAAC,OAAO,EAAE;wBAGlB,KAAK,CAAC,OAAO,CAAC,SAAS,GAAG,SAAS,CAAC;wBACpC,MAAM,KAAK,CAAC;qBACZ;oBACD,MAAM,IAAI,iCAAkB,CAAC,IAAI,CAAC,OAAO,EAAE,EAAE,KAAK,EAAE;wBACnD,SAAS;qBACT,CAAC,CAAC;iBACH;aACD;SACD;QAED,OAAO,IAAI,CAAC,iBAAiB,CAAC,KAAK,CAAC,CAAC;IACtC,CAAC;CACD;AAnUD,kCAmUC"}
@@ -0,0 +1,6 @@
1
+ import { IExecuteFunctions } from 'n8n-core';
2
+ import { INodeExecutionData, INodeType, INodeTypeDescription } from 'n8n-workflow';
3
+ export declare class CouchbaseNode implements INodeType {
4
+ description: INodeTypeDescription;
5
+ execute(this: IExecuteFunctions): Promise<INodeExecutionData[][]>;
6
+ }
@@ -0,0 +1,274 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.CouchbaseNode = void 0;
4
+ const n8n_workflow_1 = require("n8n-workflow");
5
+ const couchbase_1 = require("couchbase");
6
+ class CouchbaseNode {
7
+ constructor() {
8
+ this.description = {
9
+ displayName: 'Couchbase',
10
+ name: 'couchbaseDB',
11
+ icon: 'file:CBLogomark.svg',
12
+ group: ['transform'],
13
+ version: 1,
14
+ description: 'Couchbase Node to add, update and delete data from couchbase',
15
+ defaults: {
16
+ name: 'Couchbase',
17
+ },
18
+ inputs: ['main'],
19
+ outputs: ['main'],
20
+ properties: [
21
+ {
22
+ displayName: 'Operation',
23
+ name: 'operation',
24
+ type: 'options',
25
+ noDataExpression: true,
26
+ options: [
27
+ {
28
+ name: 'Insert',
29
+ value: 'insert',
30
+ description: 'Insert document in couchbase',
31
+ action: 'Insert document in couchbase',
32
+ },
33
+ {
34
+ name: 'Update',
35
+ value: 'update',
36
+ description: 'Update document in couchbase',
37
+ action: 'Update document in couchbase',
38
+ },
39
+ {
40
+ name: 'Remove',
41
+ value: 'remove',
42
+ description: 'Remove document in couchbase',
43
+ action: 'Remove document in couchbase',
44
+ },
45
+ {
46
+ name: 'Find',
47
+ value: 'find',
48
+ description: 'Find document in couchbase',
49
+ action: 'Find document in couchbase',
50
+ },
51
+ ],
52
+ default: 'insert',
53
+ },
54
+ {
55
+ displayName: 'Connection String',
56
+ name: 'myConnection',
57
+ type: 'string',
58
+ displayOptions: {
59
+ show: {
60
+ operation: ['insert', 'update', 'remove', 'find'],
61
+ },
62
+ },
63
+ default: '',
64
+ placeholder: 'Enter Connection String',
65
+ description: 'The description text',
66
+ },
67
+ {
68
+ displayName: 'Username',
69
+ name: 'myUsername',
70
+ type: 'string',
71
+ displayOptions: {
72
+ show: {
73
+ operation: ['insert', 'update', 'remove', 'find'],
74
+ },
75
+ },
76
+ default: '',
77
+ placeholder: 'Enter Your Username',
78
+ description: 'The description text',
79
+ },
80
+ {
81
+ displayName: 'Password',
82
+ name: 'myPassword',
83
+ type: 'string',
84
+ displayOptions: {
85
+ show: {
86
+ operation: ['insert', 'update', 'remove', 'find'],
87
+ },
88
+ },
89
+ default: '',
90
+ placeholder: 'Enter Your Password',
91
+ description: 'The description text',
92
+ },
93
+ {
94
+ displayName: 'Bucket',
95
+ name: 'myBucket',
96
+ type: 'string',
97
+ displayOptions: {
98
+ show: {
99
+ operation: ['insert', 'update', 'remove', 'find'],
100
+ },
101
+ },
102
+ default: '',
103
+ placeholder: 'Enter Bucket Name',
104
+ description: 'The description text',
105
+ },
106
+ {
107
+ displayName: 'Scope',
108
+ name: 'myScope',
109
+ type: 'string',
110
+ displayOptions: {
111
+ show: {
112
+ operation: ['insert', 'update', 'remove', 'find'],
113
+ },
114
+ },
115
+ default: '',
116
+ placeholder: 'Enter Scope Name',
117
+ description: 'The description text',
118
+ },
119
+ {
120
+ displayName: 'Colection',
121
+ name: 'myCollection',
122
+ type: 'string',
123
+ displayOptions: {
124
+ show: {
125
+ operation: ['insert', 'update', 'remove', 'find'],
126
+ },
127
+ },
128
+ default: '',
129
+ placeholder: 'Enter Collection Name',
130
+ description: 'The description text',
131
+ },
132
+ {
133
+ displayName: 'Value',
134
+ name: 'myDocument',
135
+ type: 'string',
136
+ displayOptions: {
137
+ show: {
138
+ operation: ['insert'],
139
+ },
140
+ },
141
+ default: '',
142
+ placeholder: 'Placeholder value',
143
+ description: 'The description text',
144
+ },
145
+ {
146
+ displayName: 'ID',
147
+ name: 'myDocument',
148
+ type: 'string',
149
+ displayOptions: {
150
+ show: {
151
+ operation: ['update'],
152
+ },
153
+ },
154
+ default: '',
155
+ placeholder: 'Placeholder value',
156
+ description: 'The description text',
157
+ },
158
+ {
159
+ displayName: 'Value',
160
+ name: 'myValue',
161
+ type: 'string',
162
+ displayOptions: {
163
+ show: {
164
+ operation: ['update'],
165
+ },
166
+ },
167
+ default: '',
168
+ placeholder: 'Placeholder value',
169
+ description: 'The description text',
170
+ },
171
+ {
172
+ displayName: 'ID',
173
+ name: 'myDocument',
174
+ type: 'string',
175
+ displayOptions: {
176
+ show: {
177
+ operation: ['remove'],
178
+ },
179
+ },
180
+ default: '',
181
+ placeholder: 'Placeholder value',
182
+ description: 'The description text',
183
+ },
184
+ {
185
+ displayName: 'ID',
186
+ name: 'myDocument',
187
+ type: 'string',
188
+ displayOptions: {
189
+ show: {
190
+ operation: ['find'],
191
+ },
192
+ },
193
+ default: '',
194
+ placeholder: 'Placeholder value',
195
+ description: 'The description text',
196
+ },
197
+ ],
198
+ };
199
+ }
200
+ async execute() {
201
+ const items = this.getInputData();
202
+ let item;
203
+ let item2;
204
+ let myDocument;
205
+ let myNewValue;
206
+ let myUsername;
207
+ let myPassword;
208
+ let myBucket;
209
+ let myScope;
210
+ let myCollection;
211
+ let myConnection;
212
+ for (let itemIndex = 0; itemIndex < items.length; itemIndex++) {
213
+ try {
214
+ myNewValue = this.getNodeParameter('myValue', itemIndex, '');
215
+ myDocument = this.getNodeParameter('myDocument', itemIndex, '');
216
+ myUsername = this.getNodeParameter('myUsername', itemIndex, '');
217
+ myPassword = this.getNodeParameter('myPassword', itemIndex, '');
218
+ myBucket = this.getNodeParameter('myBucket', itemIndex, '');
219
+ myScope = this.getNodeParameter('myScope', itemIndex, '');
220
+ myCollection = this.getNodeParameter('myCollection', itemIndex, '');
221
+ myConnection = this.getNodeParameter('myConnection', itemIndex, '');
222
+ const clusterConnStr = myConnection;
223
+ const username = myUsername;
224
+ const password = myPassword;
225
+ const bucketName = myBucket;
226
+ const cluster = await (0, couchbase_1.connect)(clusterConnStr, {
227
+ username: username,
228
+ password: password,
229
+ configProfile: 'wanDevelopment'
230
+ });
231
+ const bucket = cluster.bucket(bucketName);
232
+ const collection = bucket
233
+ .scope(myScope)
234
+ .collection(myCollection);
235
+ item = items[itemIndex];
236
+ item.json['myDocument'] = myDocument;
237
+ const operation = this.getNodeParameter('operation', 0);
238
+ if (operation === 'insert') {
239
+ await collection.insert(myDocument, item.json);
240
+ }
241
+ else if (operation === 'update') {
242
+ item2 = items[itemIndex];
243
+ item2.json['myDocument'] = myNewValue;
244
+ await collection.upsert(myDocument, item2.json);
245
+ }
246
+ else if (operation === 'remove') {
247
+ await collection.remove(myDocument);
248
+ }
249
+ else if (operation === 'find') {
250
+ const getResult = await collection.get(myDocument);
251
+ console.log('Get Result:', getResult);
252
+ await collection.get(myDocument);
253
+ }
254
+ }
255
+ catch (error) {
256
+ if (this.continueOnFail()) {
257
+ items.push({ json: this.getInputData(itemIndex)[0].json, error, pairedItem: itemIndex });
258
+ }
259
+ else {
260
+ if (error.context) {
261
+ error.context.itemIndex = itemIndex;
262
+ throw error;
263
+ }
264
+ throw new n8n_workflow_1.NodeOperationError(this.getNode(), error, {
265
+ itemIndex,
266
+ });
267
+ }
268
+ }
269
+ }
270
+ return this.prepareOutputData(items);
271
+ }
272
+ }
273
+ exports.CouchbaseNode = CouchbaseNode;
274
+ //# sourceMappingURL=CouchbaseNode.node.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CouchbaseNode.node.js","sourceRoot":"","sources":["../../../nodes/CouchbaseNode/CouchbaseNode.node.ts"],"names":[],"mappings":";;;AACA,+CAKsB;AAEtB,yCAKoB;AAEpB,MAAa,aAAa;IAA1B;QACC,gBAAW,GAAyB;YACnC,WAAW,EAAE,WAAW;YACxB,IAAI,EAAE,aAAa;YACnB,IAAI,EAAE,qBAAqB;YAC3B,KAAK,EAAE,CAAC,WAAW,CAAC;YACpB,OAAO,EAAE,CAAC;YACV,WAAW,EAAE,8DAA8D;YAC3E,QAAQ,EAAE;gBACT,IAAI,EAAE,WAAW;aACjB;YACD,MAAM,EAAE,CAAC,MAAM,CAAC;YAChB,OAAO,EAAE,CAAC,MAAM,CAAC;YACjB,UAAU,EAAE;gBACX;oBACa,WAAW,EAAE,WAAW;oBACxB,IAAI,EAAE,WAAW;oBACjB,IAAI,EAAE,SAAS;oBACf,gBAAgB,EAAE,IAAI;oBACtB,OAAO,EAAE;wBACL;4BACI,IAAI,EAAE,QAAQ;4BACd,KAAK,EAAE,QAAQ;4BACf,WAAW,EAAE,8BAA8B;4BAC3C,MAAM,EAAE,8BAA8B;yBACzC;wBAChB;4BACC,IAAI,EAAE,QAAQ;4BACd,KAAK,EAAE,QAAQ;4BACf,WAAW,EAAE,8BAA8B;4BAC3C,MAAM,EAAE,8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