@superdurable/connector-brevo 0.1.1 → 0.2.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/README.md +3 -1
- package/dex-connector.json +878 -4
- package/dist/chunk-VBTEJFWF.js +749 -0
- package/dist/connection-BZu1qFOK.d.ts +513 -0
- package/dist/index.d.ts +752 -5
- package/dist/index.js +1039 -48
- package/dist/mock.d.ts +265 -4
- package/dist/mock.js +652 -7
- package/package.json +4 -3
- package/dist/chunk-NI2F5J36.js +0 -131
- package/dist/connection-BmKZ2txn.d.ts +0 -98
package/dist/mock.js
CHANGED
|
@@ -1,23 +1,153 @@
|
|
|
1
1
|
import {
|
|
2
|
+
AttributeChangeResultSchema,
|
|
3
|
+
AttributeEnumerationValueSchema,
|
|
4
|
+
AttributeIdentitySchema,
|
|
5
|
+
AttributesListSchema,
|
|
6
|
+
ContactChangeResultSchema,
|
|
7
|
+
ContactIdentitySchema,
|
|
2
8
|
ContactSchema,
|
|
3
9
|
ContactWriteResultSchema,
|
|
10
|
+
ContactsListSchema,
|
|
11
|
+
CreateAttributeDefinition,
|
|
12
|
+
CreateAttributeInputSchema,
|
|
13
|
+
CreateContactDefinition,
|
|
14
|
+
CreateContactInputSchema,
|
|
4
15
|
CreateOrUpdateContactDefinition,
|
|
5
16
|
CreateOrUpdateContactInputSchema,
|
|
17
|
+
CreateSenderDefinition,
|
|
18
|
+
CreateSenderInputSchema,
|
|
19
|
+
DeleteAttributeDefinition,
|
|
20
|
+
DeleteAttributeInputSchema,
|
|
21
|
+
DeleteContactDefinition,
|
|
22
|
+
DeleteContactInputSchema,
|
|
23
|
+
DeleteSenderDefinition,
|
|
24
|
+
DeleteSenderInputSchema,
|
|
25
|
+
EmailSendResultSchema,
|
|
6
26
|
GetContactDefinition,
|
|
7
27
|
GetContactInputSchema,
|
|
28
|
+
ListAttributesDefinition,
|
|
29
|
+
ListAttributesInputSchema,
|
|
30
|
+
ListContactsDefinition,
|
|
31
|
+
ListContactsInputSchema,
|
|
32
|
+
ListSendersDefinition,
|
|
33
|
+
ListSendersInputSchema,
|
|
8
34
|
ProviderID,
|
|
9
|
-
|
|
10
|
-
|
|
35
|
+
SendEmailDefinition,
|
|
36
|
+
SendEmailInputSchema,
|
|
37
|
+
SendTemplateEmailDefinition,
|
|
38
|
+
SendTemplateEmailInputSchema,
|
|
39
|
+
SenderChangeResultSchema,
|
|
40
|
+
SenderIdentitySchema,
|
|
41
|
+
SendersListSchema,
|
|
42
|
+
UpdateAttributeDefinition,
|
|
43
|
+
UpdateAttributeInputSchema,
|
|
44
|
+
UpdateContactDefinition,
|
|
45
|
+
UpdateContactInputSchema,
|
|
46
|
+
UpdateSenderDefinition,
|
|
47
|
+
UpdateSenderInputSchema,
|
|
48
|
+
newConnectionWithOperations,
|
|
49
|
+
parseExactIntegerJSON
|
|
50
|
+
} from "./chunk-VBTEJFWF.js";
|
|
11
51
|
|
|
12
52
|
// src/generated/mock.ts
|
|
13
|
-
import { branchCase, retryCase, newMutation, newQuery } from "@superdurable/connectors-sdk/connectormock";
|
|
14
|
-
var
|
|
53
|
+
import { branchCase, retryCase, uncertainCase, newMutation, newQuery } from "@superdurable/connectors-sdk/connectormock";
|
|
54
|
+
var emptyCreateContactInput = CreateContactInputSchema.parse({
|
|
15
55
|
"email": ""
|
|
16
56
|
});
|
|
17
57
|
var emptyContactWriteResult = ContactWriteResultSchema.parse({
|
|
18
58
|
"email": "",
|
|
19
59
|
"created": false
|
|
20
60
|
});
|
|
61
|
+
var emptyListContactsInput = ListContactsInputSchema.parse({
|
|
62
|
+
"limit": 0,
|
|
63
|
+
"offset": 0
|
|
64
|
+
});
|
|
65
|
+
var emptyContactIdentity = ContactIdentitySchema.parse({
|
|
66
|
+
"id": 0
|
|
67
|
+
});
|
|
68
|
+
var emptyContactsList = ContactsListSchema.parse({
|
|
69
|
+
"contacts": [],
|
|
70
|
+
"count": 0
|
|
71
|
+
});
|
|
72
|
+
var emptyUpdateContactInput = UpdateContactInputSchema.parse({
|
|
73
|
+
"email": "",
|
|
74
|
+
"attributes": {}
|
|
75
|
+
});
|
|
76
|
+
var emptyContactChangeResult = ContactChangeResultSchema.parse({
|
|
77
|
+
"email": ""
|
|
78
|
+
});
|
|
79
|
+
var emptyDeleteContactInput = DeleteContactInputSchema.parse({
|
|
80
|
+
"email": ""
|
|
81
|
+
});
|
|
82
|
+
var emptyListAttributesInput = ListAttributesInputSchema.parse({});
|
|
83
|
+
var emptyAttributeIdentity = AttributeIdentitySchema.parse({
|
|
84
|
+
"name": "",
|
|
85
|
+
"category": "",
|
|
86
|
+
"type": ""
|
|
87
|
+
});
|
|
88
|
+
var emptyAttributesList = AttributesListSchema.parse({
|
|
89
|
+
"attributes": []
|
|
90
|
+
});
|
|
91
|
+
var emptyAttributeEnumerationValue = AttributeEnumerationValueSchema.parse({
|
|
92
|
+
"value": 0,
|
|
93
|
+
"label": ""
|
|
94
|
+
});
|
|
95
|
+
var emptyCreateAttributeInput = CreateAttributeInputSchema.parse({
|
|
96
|
+
"category": "",
|
|
97
|
+
"name": ""
|
|
98
|
+
});
|
|
99
|
+
var emptyAttributeChangeResult = AttributeChangeResultSchema.parse({
|
|
100
|
+
"category": "",
|
|
101
|
+
"name": ""
|
|
102
|
+
});
|
|
103
|
+
var emptyUpdateAttributeInput = UpdateAttributeInputSchema.parse({
|
|
104
|
+
"category": "",
|
|
105
|
+
"name": ""
|
|
106
|
+
});
|
|
107
|
+
var emptyDeleteAttributeInput = DeleteAttributeInputSchema.parse({
|
|
108
|
+
"category": "",
|
|
109
|
+
"name": ""
|
|
110
|
+
});
|
|
111
|
+
var emptyListSendersInput = ListSendersInputSchema.parse({});
|
|
112
|
+
var emptySenderIdentity = SenderIdentitySchema.parse({
|
|
113
|
+
"id": 0,
|
|
114
|
+
"name": "",
|
|
115
|
+
"email": "",
|
|
116
|
+
"active": false
|
|
117
|
+
});
|
|
118
|
+
var emptySendersList = SendersListSchema.parse({
|
|
119
|
+
"senders": []
|
|
120
|
+
});
|
|
121
|
+
var emptyCreateSenderInput = CreateSenderInputSchema.parse({
|
|
122
|
+
"email": "",
|
|
123
|
+
"name": ""
|
|
124
|
+
});
|
|
125
|
+
var emptySenderChangeResult = SenderChangeResultSchema.parse({
|
|
126
|
+
"id": 0
|
|
127
|
+
});
|
|
128
|
+
var emptyUpdateSenderInput = UpdateSenderInputSchema.parse({
|
|
129
|
+
"id": 0,
|
|
130
|
+
"name": ""
|
|
131
|
+
});
|
|
132
|
+
var emptyDeleteSenderInput = DeleteSenderInputSchema.parse({
|
|
133
|
+
"id": 0
|
|
134
|
+
});
|
|
135
|
+
var emptySendEmailInput = SendEmailInputSchema.parse({
|
|
136
|
+
"senderEmail": "",
|
|
137
|
+
"senderName": "",
|
|
138
|
+
"toEmail": "",
|
|
139
|
+
"subject": ""
|
|
140
|
+
});
|
|
141
|
+
var emptyEmailSendResult = EmailSendResultSchema.parse({
|
|
142
|
+
"messageId": ""
|
|
143
|
+
});
|
|
144
|
+
var emptySendTemplateEmailInput = SendTemplateEmailInputSchema.parse({
|
|
145
|
+
"templateId": 0,
|
|
146
|
+
"toEmail": ""
|
|
147
|
+
});
|
|
148
|
+
var emptyCreateOrUpdateContactInput = CreateOrUpdateContactInputSchema.parse({
|
|
149
|
+
"email": ""
|
|
150
|
+
});
|
|
21
151
|
var emptyGetContactInput = GetContactInputSchema.parse({
|
|
22
152
|
"email": ""
|
|
23
153
|
});
|
|
@@ -25,6 +155,314 @@ var emptyContact = ContactSchema.parse({
|
|
|
25
155
|
"id": 0,
|
|
26
156
|
"email": ""
|
|
27
157
|
});
|
|
158
|
+
function createContactCreated(value, failure) {
|
|
159
|
+
return branchCase("created", value, failure);
|
|
160
|
+
}
|
|
161
|
+
function createContactProviderRejected(value, failure) {
|
|
162
|
+
return branchCase("providerRejected", value, failure);
|
|
163
|
+
}
|
|
164
|
+
function createContactDefect(value, failure) {
|
|
165
|
+
return branchCase("defect", value, failure);
|
|
166
|
+
}
|
|
167
|
+
function createContactRetry(failure, retryAfterMs = 0) {
|
|
168
|
+
return retryCase(failure, retryAfterMs);
|
|
169
|
+
}
|
|
170
|
+
function createContactUncertain(value, failure) {
|
|
171
|
+
return uncertainCase(value, failure);
|
|
172
|
+
}
|
|
173
|
+
function createContactCreatedDefault() {
|
|
174
|
+
const value = ContactWriteResultSchema.parse(parseExactIntegerJSON('{"created":true,"email":"member@meridian.example","id":21}'));
|
|
175
|
+
return branchCase("created", value);
|
|
176
|
+
}
|
|
177
|
+
function createContactDefault() {
|
|
178
|
+
return createContactCreatedDefault();
|
|
179
|
+
}
|
|
180
|
+
function listContactsListed(value, failure) {
|
|
181
|
+
return branchCase("listed", value, failure);
|
|
182
|
+
}
|
|
183
|
+
function listContactsProviderRejected(value, failure) {
|
|
184
|
+
return branchCase("providerRejected", value, failure);
|
|
185
|
+
}
|
|
186
|
+
function listContactsInvalidResponse(value, failure) {
|
|
187
|
+
return branchCase("invalidResponse", value, failure);
|
|
188
|
+
}
|
|
189
|
+
function listContactsDefect(value, failure) {
|
|
190
|
+
return branchCase("defect", value, failure);
|
|
191
|
+
}
|
|
192
|
+
function listContactsRetry(failure, retryAfterMs = 0) {
|
|
193
|
+
return retryCase(failure, retryAfterMs);
|
|
194
|
+
}
|
|
195
|
+
function listContactsListedDefault() {
|
|
196
|
+
const value = ContactsListSchema.parse(parseExactIntegerJSON('{"contacts":[{"email":"member@meridian.example","id":21}],"count":1}'));
|
|
197
|
+
return branchCase("listed", value);
|
|
198
|
+
}
|
|
199
|
+
function listContactsDefault() {
|
|
200
|
+
return listContactsListedDefault();
|
|
201
|
+
}
|
|
202
|
+
function updateContactUpdated(value, failure) {
|
|
203
|
+
return branchCase("updated", value, failure);
|
|
204
|
+
}
|
|
205
|
+
function updateContactNotFound(value, failure) {
|
|
206
|
+
return branchCase("notFound", value, failure);
|
|
207
|
+
}
|
|
208
|
+
function updateContactProviderRejected(value, failure) {
|
|
209
|
+
return branchCase("providerRejected", value, failure);
|
|
210
|
+
}
|
|
211
|
+
function updateContactDefect(value, failure) {
|
|
212
|
+
return branchCase("defect", value, failure);
|
|
213
|
+
}
|
|
214
|
+
function updateContactRetry(failure, retryAfterMs = 0) {
|
|
215
|
+
return retryCase(failure, retryAfterMs);
|
|
216
|
+
}
|
|
217
|
+
function updateContactUpdatedDefault() {
|
|
218
|
+
const value = ContactChangeResultSchema.parse(parseExactIntegerJSON('{"email":"member@meridian.example"}'));
|
|
219
|
+
return branchCase("updated", value);
|
|
220
|
+
}
|
|
221
|
+
function updateContactDefault() {
|
|
222
|
+
return updateContactUpdatedDefault();
|
|
223
|
+
}
|
|
224
|
+
function deleteContactDeleted(value, failure) {
|
|
225
|
+
return branchCase("deleted", value, failure);
|
|
226
|
+
}
|
|
227
|
+
function deleteContactNotFound(value, failure) {
|
|
228
|
+
return branchCase("notFound", value, failure);
|
|
229
|
+
}
|
|
230
|
+
function deleteContactProviderRejected(value, failure) {
|
|
231
|
+
return branchCase("providerRejected", value, failure);
|
|
232
|
+
}
|
|
233
|
+
function deleteContactDefect(value, failure) {
|
|
234
|
+
return branchCase("defect", value, failure);
|
|
235
|
+
}
|
|
236
|
+
function deleteContactRetry(failure, retryAfterMs = 0) {
|
|
237
|
+
return retryCase(failure, retryAfterMs);
|
|
238
|
+
}
|
|
239
|
+
function deleteContactDeletedDefault() {
|
|
240
|
+
const value = ContactChangeResultSchema.parse(parseExactIntegerJSON('{"email":"member@meridian.example"}'));
|
|
241
|
+
return branchCase("deleted", value);
|
|
242
|
+
}
|
|
243
|
+
function deleteContactDefault() {
|
|
244
|
+
return deleteContactDeletedDefault();
|
|
245
|
+
}
|
|
246
|
+
function listAttributesListed(value, failure) {
|
|
247
|
+
return branchCase("listed", value, failure);
|
|
248
|
+
}
|
|
249
|
+
function listAttributesProviderRejected(value, failure) {
|
|
250
|
+
return branchCase("providerRejected", value, failure);
|
|
251
|
+
}
|
|
252
|
+
function listAttributesInvalidResponse(value, failure) {
|
|
253
|
+
return branchCase("invalidResponse", value, failure);
|
|
254
|
+
}
|
|
255
|
+
function listAttributesDefect(value, failure) {
|
|
256
|
+
return branchCase("defect", value, failure);
|
|
257
|
+
}
|
|
258
|
+
function listAttributesRetry(failure, retryAfterMs = 0) {
|
|
259
|
+
return retryCase(failure, retryAfterMs);
|
|
260
|
+
}
|
|
261
|
+
function listAttributesListedDefault() {
|
|
262
|
+
const value = AttributesListSchema.parse(parseExactIntegerJSON('{"attributes":[{"category":"normal","name":"FIRSTNAME","type":"text"}]}'));
|
|
263
|
+
return branchCase("listed", value);
|
|
264
|
+
}
|
|
265
|
+
function listAttributesDefault() {
|
|
266
|
+
return listAttributesListedDefault();
|
|
267
|
+
}
|
|
268
|
+
function createAttributeCreated(value, failure) {
|
|
269
|
+
return branchCase("created", value, failure);
|
|
270
|
+
}
|
|
271
|
+
function createAttributeProviderRejected(value, failure) {
|
|
272
|
+
return branchCase("providerRejected", value, failure);
|
|
273
|
+
}
|
|
274
|
+
function createAttributeDefect(value, failure) {
|
|
275
|
+
return branchCase("defect", value, failure);
|
|
276
|
+
}
|
|
277
|
+
function createAttributeRetry(failure, retryAfterMs = 0) {
|
|
278
|
+
return retryCase(failure, retryAfterMs);
|
|
279
|
+
}
|
|
280
|
+
function createAttributeUncertain(value, failure) {
|
|
281
|
+
return uncertainCase(value, failure);
|
|
282
|
+
}
|
|
283
|
+
function createAttributeCreatedDefault() {
|
|
284
|
+
const value = AttributeChangeResultSchema.parse(parseExactIntegerJSON('{"category":"normal","name":"CUSTOMER_CODE"}'));
|
|
285
|
+
return branchCase("created", value);
|
|
286
|
+
}
|
|
287
|
+
function createAttributeDefault() {
|
|
288
|
+
return createAttributeCreatedDefault();
|
|
289
|
+
}
|
|
290
|
+
function updateAttributeUpdated(value, failure) {
|
|
291
|
+
return branchCase("updated", value, failure);
|
|
292
|
+
}
|
|
293
|
+
function updateAttributeNotFound(value, failure) {
|
|
294
|
+
return branchCase("notFound", value, failure);
|
|
295
|
+
}
|
|
296
|
+
function updateAttributeProviderRejected(value, failure) {
|
|
297
|
+
return branchCase("providerRejected", value, failure);
|
|
298
|
+
}
|
|
299
|
+
function updateAttributeDefect(value, failure) {
|
|
300
|
+
return branchCase("defect", value, failure);
|
|
301
|
+
}
|
|
302
|
+
function updateAttributeRetry(failure, retryAfterMs = 0) {
|
|
303
|
+
return retryCase(failure, retryAfterMs);
|
|
304
|
+
}
|
|
305
|
+
function updateAttributeUpdatedDefault() {
|
|
306
|
+
const value = AttributeChangeResultSchema.parse(parseExactIntegerJSON('{"category":"normal","name":"CUSTOMER_TIER"}'));
|
|
307
|
+
return branchCase("updated", value);
|
|
308
|
+
}
|
|
309
|
+
function updateAttributeDefault() {
|
|
310
|
+
return updateAttributeUpdatedDefault();
|
|
311
|
+
}
|
|
312
|
+
function deleteAttributeDeleted(value, failure) {
|
|
313
|
+
return branchCase("deleted", value, failure);
|
|
314
|
+
}
|
|
315
|
+
function deleteAttributeNotFound(value, failure) {
|
|
316
|
+
return branchCase("notFound", value, failure);
|
|
317
|
+
}
|
|
318
|
+
function deleteAttributeProviderRejected(value, failure) {
|
|
319
|
+
return branchCase("providerRejected", value, failure);
|
|
320
|
+
}
|
|
321
|
+
function deleteAttributeDefect(value, failure) {
|
|
322
|
+
return branchCase("defect", value, failure);
|
|
323
|
+
}
|
|
324
|
+
function deleteAttributeRetry(failure, retryAfterMs = 0) {
|
|
325
|
+
return retryCase(failure, retryAfterMs);
|
|
326
|
+
}
|
|
327
|
+
function deleteAttributeDeletedDefault() {
|
|
328
|
+
const value = AttributeChangeResultSchema.parse(parseExactIntegerJSON('{"category":"normal","name":"CUSTOMER_CODE"}'));
|
|
329
|
+
return branchCase("deleted", value);
|
|
330
|
+
}
|
|
331
|
+
function deleteAttributeDefault() {
|
|
332
|
+
return deleteAttributeDeletedDefault();
|
|
333
|
+
}
|
|
334
|
+
function listSendersListed(value, failure) {
|
|
335
|
+
return branchCase("listed", value, failure);
|
|
336
|
+
}
|
|
337
|
+
function listSendersProviderRejected(value, failure) {
|
|
338
|
+
return branchCase("providerRejected", value, failure);
|
|
339
|
+
}
|
|
340
|
+
function listSendersInvalidResponse(value, failure) {
|
|
341
|
+
return branchCase("invalidResponse", value, failure);
|
|
342
|
+
}
|
|
343
|
+
function listSendersDefect(value, failure) {
|
|
344
|
+
return branchCase("defect", value, failure);
|
|
345
|
+
}
|
|
346
|
+
function listSendersRetry(failure, retryAfterMs = 0) {
|
|
347
|
+
return retryCase(failure, retryAfterMs);
|
|
348
|
+
}
|
|
349
|
+
function listSendersListedDefault() {
|
|
350
|
+
const value = SendersListSchema.parse(parseExactIntegerJSON('{"senders":[{"active":true,"email":"support@example.com","id":1,"name":"Support"}]}'));
|
|
351
|
+
return branchCase("listed", value);
|
|
352
|
+
}
|
|
353
|
+
function listSendersDefault() {
|
|
354
|
+
return listSendersListedDefault();
|
|
355
|
+
}
|
|
356
|
+
function createSenderCreated(value, failure) {
|
|
357
|
+
return branchCase("created", value, failure);
|
|
358
|
+
}
|
|
359
|
+
function createSenderProviderRejected(value, failure) {
|
|
360
|
+
return branchCase("providerRejected", value, failure);
|
|
361
|
+
}
|
|
362
|
+
function createSenderDefect(value, failure) {
|
|
363
|
+
return branchCase("defect", value, failure);
|
|
364
|
+
}
|
|
365
|
+
function createSenderRetry(failure, retryAfterMs = 0) {
|
|
366
|
+
return retryCase(failure, retryAfterMs);
|
|
367
|
+
}
|
|
368
|
+
function createSenderUncertain(value, failure) {
|
|
369
|
+
return uncertainCase(value, failure);
|
|
370
|
+
}
|
|
371
|
+
function createSenderCreatedDefault() {
|
|
372
|
+
const value = SenderChangeResultSchema.parse(parseExactIntegerJSON('{"id":1}'));
|
|
373
|
+
return branchCase("created", value);
|
|
374
|
+
}
|
|
375
|
+
function createSenderDefault() {
|
|
376
|
+
return createSenderCreatedDefault();
|
|
377
|
+
}
|
|
378
|
+
function updateSenderUpdated(value, failure) {
|
|
379
|
+
return branchCase("updated", value, failure);
|
|
380
|
+
}
|
|
381
|
+
function updateSenderNotFound(value, failure) {
|
|
382
|
+
return branchCase("notFound", value, failure);
|
|
383
|
+
}
|
|
384
|
+
function updateSenderProviderRejected(value, failure) {
|
|
385
|
+
return branchCase("providerRejected", value, failure);
|
|
386
|
+
}
|
|
387
|
+
function updateSenderDefect(value, failure) {
|
|
388
|
+
return branchCase("defect", value, failure);
|
|
389
|
+
}
|
|
390
|
+
function updateSenderRetry(failure, retryAfterMs = 0) {
|
|
391
|
+
return retryCase(failure, retryAfterMs);
|
|
392
|
+
}
|
|
393
|
+
function updateSenderUpdatedDefault() {
|
|
394
|
+
const value = SenderChangeResultSchema.parse(parseExactIntegerJSON('{"id":1}'));
|
|
395
|
+
return branchCase("updated", value);
|
|
396
|
+
}
|
|
397
|
+
function updateSenderDefault() {
|
|
398
|
+
return updateSenderUpdatedDefault();
|
|
399
|
+
}
|
|
400
|
+
function deleteSenderDeleted(value, failure) {
|
|
401
|
+
return branchCase("deleted", value, failure);
|
|
402
|
+
}
|
|
403
|
+
function deleteSenderNotFound(value, failure) {
|
|
404
|
+
return branchCase("notFound", value, failure);
|
|
405
|
+
}
|
|
406
|
+
function deleteSenderProviderRejected(value, failure) {
|
|
407
|
+
return branchCase("providerRejected", value, failure);
|
|
408
|
+
}
|
|
409
|
+
function deleteSenderDefect(value, failure) {
|
|
410
|
+
return branchCase("defect", value, failure);
|
|
411
|
+
}
|
|
412
|
+
function deleteSenderRetry(failure, retryAfterMs = 0) {
|
|
413
|
+
return retryCase(failure, retryAfterMs);
|
|
414
|
+
}
|
|
415
|
+
function deleteSenderDeletedDefault() {
|
|
416
|
+
const value = SenderChangeResultSchema.parse(parseExactIntegerJSON('{"id":1}'));
|
|
417
|
+
return branchCase("deleted", value);
|
|
418
|
+
}
|
|
419
|
+
function deleteSenderDefault() {
|
|
420
|
+
return deleteSenderDeletedDefault();
|
|
421
|
+
}
|
|
422
|
+
function sendEmailSent(value, failure) {
|
|
423
|
+
return branchCase("sent", value, failure);
|
|
424
|
+
}
|
|
425
|
+
function sendEmailProviderRejected(value, failure) {
|
|
426
|
+
return branchCase("providerRejected", value, failure);
|
|
427
|
+
}
|
|
428
|
+
function sendEmailDefect(value, failure) {
|
|
429
|
+
return branchCase("defect", value, failure);
|
|
430
|
+
}
|
|
431
|
+
function sendEmailRetry(failure, retryAfterMs = 0) {
|
|
432
|
+
return retryCase(failure, retryAfterMs);
|
|
433
|
+
}
|
|
434
|
+
function sendEmailUncertain(value, failure) {
|
|
435
|
+
return uncertainCase(value, failure);
|
|
436
|
+
}
|
|
437
|
+
function sendEmailSentDefault() {
|
|
438
|
+
const value = EmailSendResultSchema.parse(parseExactIntegerJSON('{"messageId":"\\u003csample@relay.example\\u003e"}'));
|
|
439
|
+
return branchCase("sent", value);
|
|
440
|
+
}
|
|
441
|
+
function sendEmailDefault() {
|
|
442
|
+
return sendEmailSentDefault();
|
|
443
|
+
}
|
|
444
|
+
function sendTemplateEmailSent(value, failure) {
|
|
445
|
+
return branchCase("sent", value, failure);
|
|
446
|
+
}
|
|
447
|
+
function sendTemplateEmailProviderRejected(value, failure) {
|
|
448
|
+
return branchCase("providerRejected", value, failure);
|
|
449
|
+
}
|
|
450
|
+
function sendTemplateEmailDefect(value, failure) {
|
|
451
|
+
return branchCase("defect", value, failure);
|
|
452
|
+
}
|
|
453
|
+
function sendTemplateEmailRetry(failure, retryAfterMs = 0) {
|
|
454
|
+
return retryCase(failure, retryAfterMs);
|
|
455
|
+
}
|
|
456
|
+
function sendTemplateEmailUncertain(value, failure) {
|
|
457
|
+
return uncertainCase(value, failure);
|
|
458
|
+
}
|
|
459
|
+
function sendTemplateEmailSentDefault() {
|
|
460
|
+
const value = EmailSendResultSchema.parse(parseExactIntegerJSON('{"messageId":"\\u003csample-template@relay.example\\u003e"}'));
|
|
461
|
+
return branchCase("sent", value);
|
|
462
|
+
}
|
|
463
|
+
function sendTemplateEmailDefault() {
|
|
464
|
+
return sendTemplateEmailSentDefault();
|
|
465
|
+
}
|
|
28
466
|
function createOrUpdateContactSaved(value, failure) {
|
|
29
467
|
return branchCase("saved", value, failure);
|
|
30
468
|
}
|
|
@@ -41,7 +479,7 @@ function createOrUpdateContactRetry(failure, retryAfterMs = 0) {
|
|
|
41
479
|
return retryCase(failure, retryAfterMs);
|
|
42
480
|
}
|
|
43
481
|
function createOrUpdateContactSavedDefaultContact() {
|
|
44
|
-
const value = ContactWriteResultSchema.parse({
|
|
482
|
+
const value = ContactWriteResultSchema.parse(parseExactIntegerJSON('{"created":true,"email":"member@meridian.example","id":21}'));
|
|
45
483
|
return branchCase("saved", value);
|
|
46
484
|
}
|
|
47
485
|
function createOrUpdateContactDefault() {
|
|
@@ -66,17 +504,45 @@ function getContactRetry(failure, retryAfterMs = 0) {
|
|
|
66
504
|
return retryCase(failure, retryAfterMs);
|
|
67
505
|
}
|
|
68
506
|
function getContactFoundDefaultContact() {
|
|
69
|
-
const value = ContactSchema.parse({
|
|
507
|
+
const value = ContactSchema.parse(parseExactIntegerJSON('{"email":"member@meridian.example","id":21}'));
|
|
70
508
|
return branchCase("found", value);
|
|
71
509
|
}
|
|
72
510
|
function getContactDefault() {
|
|
73
511
|
return getContactFoundDefaultContact();
|
|
74
512
|
}
|
|
75
513
|
var GeneratedMock = class {
|
|
514
|
+
#createContact;
|
|
515
|
+
#listContacts;
|
|
516
|
+
#updateContact;
|
|
517
|
+
#deleteContact;
|
|
518
|
+
#listAttributes;
|
|
519
|
+
#createAttribute;
|
|
520
|
+
#updateAttribute;
|
|
521
|
+
#deleteAttribute;
|
|
522
|
+
#listSenders;
|
|
523
|
+
#createSender;
|
|
524
|
+
#updateSender;
|
|
525
|
+
#deleteSender;
|
|
526
|
+
#sendEmail;
|
|
527
|
+
#sendTemplateEmail;
|
|
76
528
|
#createOrUpdateContact;
|
|
77
529
|
#getContact;
|
|
78
530
|
#connection;
|
|
79
531
|
constructor(connectionName) {
|
|
532
|
+
this.#createContact = newMutation(CreateContactDefinition).default(createContactDefault());
|
|
533
|
+
this.#listContacts = newQuery(ListContactsDefinition).default(listContactsDefault());
|
|
534
|
+
this.#updateContact = newMutation(UpdateContactDefinition).default(updateContactDefault());
|
|
535
|
+
this.#deleteContact = newMutation(DeleteContactDefinition).default(deleteContactDefault());
|
|
536
|
+
this.#listAttributes = newQuery(ListAttributesDefinition).default(listAttributesDefault());
|
|
537
|
+
this.#createAttribute = newMutation(CreateAttributeDefinition).default(createAttributeDefault());
|
|
538
|
+
this.#updateAttribute = newMutation(UpdateAttributeDefinition).default(updateAttributeDefault());
|
|
539
|
+
this.#deleteAttribute = newMutation(DeleteAttributeDefinition).default(deleteAttributeDefault());
|
|
540
|
+
this.#listSenders = newQuery(ListSendersDefinition).default(listSendersDefault());
|
|
541
|
+
this.#createSender = newMutation(CreateSenderDefinition).default(createSenderDefault());
|
|
542
|
+
this.#updateSender = newMutation(UpdateSenderDefinition).default(updateSenderDefault());
|
|
543
|
+
this.#deleteSender = newMutation(DeleteSenderDefinition).default(deleteSenderDefault());
|
|
544
|
+
this.#sendEmail = newMutation(SendEmailDefinition).default(sendEmailDefault());
|
|
545
|
+
this.#sendTemplateEmail = newMutation(SendTemplateEmailDefinition).default(sendTemplateEmailDefault());
|
|
80
546
|
this.#createOrUpdateContact = newMutation(CreateOrUpdateContactDefinition).default(createOrUpdateContactDefault());
|
|
81
547
|
this.#getContact = newQuery(GetContactDefinition).default(getContactDefault());
|
|
82
548
|
this.#connection = newConnectionWithOperations(this, { provider: ProviderID, name: connectionName });
|
|
@@ -84,6 +550,48 @@ var GeneratedMock = class {
|
|
|
84
550
|
connection() {
|
|
85
551
|
return this.#connection;
|
|
86
552
|
}
|
|
553
|
+
createContact() {
|
|
554
|
+
return this.#createContact;
|
|
555
|
+
}
|
|
556
|
+
listContacts() {
|
|
557
|
+
return this.#listContacts;
|
|
558
|
+
}
|
|
559
|
+
updateContact() {
|
|
560
|
+
return this.#updateContact;
|
|
561
|
+
}
|
|
562
|
+
deleteContact() {
|
|
563
|
+
return this.#deleteContact;
|
|
564
|
+
}
|
|
565
|
+
listAttributes() {
|
|
566
|
+
return this.#listAttributes;
|
|
567
|
+
}
|
|
568
|
+
createAttribute() {
|
|
569
|
+
return this.#createAttribute;
|
|
570
|
+
}
|
|
571
|
+
updateAttribute() {
|
|
572
|
+
return this.#updateAttribute;
|
|
573
|
+
}
|
|
574
|
+
deleteAttribute() {
|
|
575
|
+
return this.#deleteAttribute;
|
|
576
|
+
}
|
|
577
|
+
listSenders() {
|
|
578
|
+
return this.#listSenders;
|
|
579
|
+
}
|
|
580
|
+
createSender() {
|
|
581
|
+
return this.#createSender;
|
|
582
|
+
}
|
|
583
|
+
updateSender() {
|
|
584
|
+
return this.#updateSender;
|
|
585
|
+
}
|
|
586
|
+
deleteSender() {
|
|
587
|
+
return this.#deleteSender;
|
|
588
|
+
}
|
|
589
|
+
sendEmail() {
|
|
590
|
+
return this.#sendEmail;
|
|
591
|
+
}
|
|
592
|
+
sendTemplateEmail() {
|
|
593
|
+
return this.#sendTemplateEmail;
|
|
594
|
+
}
|
|
87
595
|
createOrUpdateContact() {
|
|
88
596
|
return this.#createOrUpdateContact;
|
|
89
597
|
}
|
|
@@ -91,12 +599,40 @@ var GeneratedMock = class {
|
|
|
91
599
|
return this.#getContact;
|
|
92
600
|
}
|
|
93
601
|
assertNoFailures() {
|
|
602
|
+
this.#createContact.assertNoFailures();
|
|
603
|
+
this.#listContacts.assertNoFailures();
|
|
604
|
+
this.#updateContact.assertNoFailures();
|
|
605
|
+
this.#deleteContact.assertNoFailures();
|
|
606
|
+
this.#listAttributes.assertNoFailures();
|
|
607
|
+
this.#createAttribute.assertNoFailures();
|
|
608
|
+
this.#updateAttribute.assertNoFailures();
|
|
609
|
+
this.#deleteAttribute.assertNoFailures();
|
|
610
|
+
this.#listSenders.assertNoFailures();
|
|
611
|
+
this.#createSender.assertNoFailures();
|
|
612
|
+
this.#updateSender.assertNoFailures();
|
|
613
|
+
this.#deleteSender.assertNoFailures();
|
|
614
|
+
this.#sendEmail.assertNoFailures();
|
|
615
|
+
this.#sendTemplateEmail.assertNoFailures();
|
|
94
616
|
this.#createOrUpdateContact.assertNoFailures();
|
|
95
617
|
this.#getContact.assertNoFailures();
|
|
96
618
|
}
|
|
97
619
|
};
|
|
98
620
|
export {
|
|
99
621
|
GeneratedMock,
|
|
622
|
+
createAttributeCreated,
|
|
623
|
+
createAttributeCreatedDefault,
|
|
624
|
+
createAttributeDefault,
|
|
625
|
+
createAttributeDefect,
|
|
626
|
+
createAttributeProviderRejected,
|
|
627
|
+
createAttributeRetry,
|
|
628
|
+
createAttributeUncertain,
|
|
629
|
+
createContactCreated,
|
|
630
|
+
createContactCreatedDefault,
|
|
631
|
+
createContactDefault,
|
|
632
|
+
createContactDefect,
|
|
633
|
+
createContactProviderRejected,
|
|
634
|
+
createContactRetry,
|
|
635
|
+
createContactUncertain,
|
|
100
636
|
createOrUpdateContactDefault,
|
|
101
637
|
createOrUpdateContactDefect,
|
|
102
638
|
createOrUpdateContactInvalidResponse,
|
|
@@ -104,10 +640,63 @@ export {
|
|
|
104
640
|
createOrUpdateContactRetry,
|
|
105
641
|
createOrUpdateContactSaved,
|
|
106
642
|
createOrUpdateContactSavedDefaultContact,
|
|
643
|
+
createSenderCreated,
|
|
644
|
+
createSenderCreatedDefault,
|
|
645
|
+
createSenderDefault,
|
|
646
|
+
createSenderDefect,
|
|
647
|
+
createSenderProviderRejected,
|
|
648
|
+
createSenderRetry,
|
|
649
|
+
createSenderUncertain,
|
|
650
|
+
deleteAttributeDefault,
|
|
651
|
+
deleteAttributeDefect,
|
|
652
|
+
deleteAttributeDeleted,
|
|
653
|
+
deleteAttributeDeletedDefault,
|
|
654
|
+
deleteAttributeNotFound,
|
|
655
|
+
deleteAttributeProviderRejected,
|
|
656
|
+
deleteAttributeRetry,
|
|
657
|
+
deleteContactDefault,
|
|
658
|
+
deleteContactDefect,
|
|
659
|
+
deleteContactDeleted,
|
|
660
|
+
deleteContactDeletedDefault,
|
|
661
|
+
deleteContactNotFound,
|
|
662
|
+
deleteContactProviderRejected,
|
|
663
|
+
deleteContactRetry,
|
|
664
|
+
deleteSenderDefault,
|
|
665
|
+
deleteSenderDefect,
|
|
666
|
+
deleteSenderDeleted,
|
|
667
|
+
deleteSenderDeletedDefault,
|
|
668
|
+
deleteSenderNotFound,
|
|
669
|
+
deleteSenderProviderRejected,
|
|
670
|
+
deleteSenderRetry,
|
|
671
|
+
emptyAttributeChangeResult,
|
|
672
|
+
emptyAttributeEnumerationValue,
|
|
673
|
+
emptyAttributeIdentity,
|
|
674
|
+
emptyAttributesList,
|
|
107
675
|
emptyContact,
|
|
676
|
+
emptyContactChangeResult,
|
|
677
|
+
emptyContactIdentity,
|
|
108
678
|
emptyContactWriteResult,
|
|
679
|
+
emptyContactsList,
|
|
680
|
+
emptyCreateAttributeInput,
|
|
681
|
+
emptyCreateContactInput,
|
|
109
682
|
emptyCreateOrUpdateContactInput,
|
|
683
|
+
emptyCreateSenderInput,
|
|
684
|
+
emptyDeleteAttributeInput,
|
|
685
|
+
emptyDeleteContactInput,
|
|
686
|
+
emptyDeleteSenderInput,
|
|
687
|
+
emptyEmailSendResult,
|
|
110
688
|
emptyGetContactInput,
|
|
689
|
+
emptyListAttributesInput,
|
|
690
|
+
emptyListContactsInput,
|
|
691
|
+
emptyListSendersInput,
|
|
692
|
+
emptySendEmailInput,
|
|
693
|
+
emptySendTemplateEmailInput,
|
|
694
|
+
emptySenderChangeResult,
|
|
695
|
+
emptySenderIdentity,
|
|
696
|
+
emptySendersList,
|
|
697
|
+
emptyUpdateAttributeInput,
|
|
698
|
+
emptyUpdateContactInput,
|
|
699
|
+
emptyUpdateSenderInput,
|
|
111
700
|
getContactDefault,
|
|
112
701
|
getContactDefect,
|
|
113
702
|
getContactFound,
|
|
@@ -115,5 +704,61 @@ export {
|
|
|
115
704
|
getContactInvalidResponse,
|
|
116
705
|
getContactNotFound,
|
|
117
706
|
getContactProviderRejected,
|
|
118
|
-
getContactRetry
|
|
707
|
+
getContactRetry,
|
|
708
|
+
listAttributesDefault,
|
|
709
|
+
listAttributesDefect,
|
|
710
|
+
listAttributesInvalidResponse,
|
|
711
|
+
listAttributesListed,
|
|
712
|
+
listAttributesListedDefault,
|
|
713
|
+
listAttributesProviderRejected,
|
|
714
|
+
listAttributesRetry,
|
|
715
|
+
listContactsDefault,
|
|
716
|
+
listContactsDefect,
|
|
717
|
+
listContactsInvalidResponse,
|
|
718
|
+
listContactsListed,
|
|
719
|
+
listContactsListedDefault,
|
|
720
|
+
listContactsProviderRejected,
|
|
721
|
+
listContactsRetry,
|
|
722
|
+
listSendersDefault,
|
|
723
|
+
listSendersDefect,
|
|
724
|
+
listSendersInvalidResponse,
|
|
725
|
+
listSendersListed,
|
|
726
|
+
listSendersListedDefault,
|
|
727
|
+
listSendersProviderRejected,
|
|
728
|
+
listSendersRetry,
|
|
729
|
+
sendEmailDefault,
|
|
730
|
+
sendEmailDefect,
|
|
731
|
+
sendEmailProviderRejected,
|
|
732
|
+
sendEmailRetry,
|
|
733
|
+
sendEmailSent,
|
|
734
|
+
sendEmailSentDefault,
|
|
735
|
+
sendEmailUncertain,
|
|
736
|
+
sendTemplateEmailDefault,
|
|
737
|
+
sendTemplateEmailDefect,
|
|
738
|
+
sendTemplateEmailProviderRejected,
|
|
739
|
+
sendTemplateEmailRetry,
|
|
740
|
+
sendTemplateEmailSent,
|
|
741
|
+
sendTemplateEmailSentDefault,
|
|
742
|
+
sendTemplateEmailUncertain,
|
|
743
|
+
updateAttributeDefault,
|
|
744
|
+
updateAttributeDefect,
|
|
745
|
+
updateAttributeNotFound,
|
|
746
|
+
updateAttributeProviderRejected,
|
|
747
|
+
updateAttributeRetry,
|
|
748
|
+
updateAttributeUpdated,
|
|
749
|
+
updateAttributeUpdatedDefault,
|
|
750
|
+
updateContactDefault,
|
|
751
|
+
updateContactDefect,
|
|
752
|
+
updateContactNotFound,
|
|
753
|
+
updateContactProviderRejected,
|
|
754
|
+
updateContactRetry,
|
|
755
|
+
updateContactUpdated,
|
|
756
|
+
updateContactUpdatedDefault,
|
|
757
|
+
updateSenderDefault,
|
|
758
|
+
updateSenderDefect,
|
|
759
|
+
updateSenderNotFound,
|
|
760
|
+
updateSenderProviderRejected,
|
|
761
|
+
updateSenderRetry,
|
|
762
|
+
updateSenderUpdated,
|
|
763
|
+
updateSenderUpdatedDefault
|
|
119
764
|
};
|