@workwae/sdk 0.1.0-alpha.6 → 0.1.0-alpha.7
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/client.d.ts +2 -2
- package/contract/accounts/routes.d.ts +40 -96
- package/contract/ai/routes.d.ts +4 -19
- package/contract/audit-log/routes.d.ts +4 -6
- package/contract/calendar/routes.d.ts +48 -248
- package/contract/connect/routes.d.ts +24 -74
- package/contract/connect-domain/routes.d.ts +15 -29
- package/contract/contacts/routes.d.ts +28 -102
- package/contract/email-validation/routes.d.ts +8 -8
- package/contract/errors.d.ts +4 -8
- package/contract/events/routes.d.ts +4 -4
- package/contract/exports/routes.d.ts +20 -28
- package/contract/identities/routes.d.ts +24 -51
- package/contract/mail/routes.d.ts +44 -201
- package/contract/mcp-keys/routes.d.ts +12 -16
- package/contract/meetings/routes.d.ts +36 -60
- package/contract/oauth-apps/routes.d.ts +15 -25
- package/contract/org-connections/routes.d.ts +43 -104
- package/contract/primitives.d.ts +7 -4
- package/contract/reasons.d.ts +0 -1
- package/contract/router.d.ts +620 -1582
- package/contract/scheduling/routes.d.ts +32 -81
- package/contract/send/routes.d.ts +56 -209
- package/contract/settings/routes.d.ts +7 -9
- package/contract/suppressions/routes.d.ts +48 -50
- package/contract/templates/routes.d.ts +30 -37
- package/contract/threads/routes.d.ts +16 -56
- package/contract/tracking-domain/routes.d.ts +15 -28
- package/contract/usage/routes.d.ts +4 -4
- package/contract/webhooks/routes.d.ts +43 -66
- package/errors.d.ts +2 -0
- package/index.js +1 -1
- package/package.json +4 -4
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as z from "zod";
|
|
2
2
|
export declare const contactFolders: {
|
|
3
|
-
list: import("@orpc/contract").
|
|
3
|
+
list: import("@orpc/contract").ProcedureContractBuilderWithInputOutput<z.ZodObject<{
|
|
4
4
|
accountId: z.ZodUUID;
|
|
5
5
|
}, z.core.$strip>, z.ZodObject<{
|
|
6
6
|
items: z.ZodArray<z.ZodObject<{
|
|
@@ -8,7 +8,7 @@ export declare const contactFolders: {
|
|
|
8
8
|
name: z.ZodString;
|
|
9
9
|
isDefault: z.ZodBoolean;
|
|
10
10
|
}, z.core.$strip>>;
|
|
11
|
-
}, z.core.$strip>,
|
|
11
|
+
}, z.core.$strip>, Omit<import("../errors.js").DeclaredErrors<{
|
|
12
12
|
readonly invalid_input: "The request does not match the operation's input schema (a malformed body included); data.issues names each problem.";
|
|
13
13
|
readonly unauthenticated: "No usable credential: none was sent, or it is malformed, unknown, revoked or an expired account token.";
|
|
14
14
|
readonly api_key_expired: "The API key is past its expiry (or the grace of the rotation that replaced it).";
|
|
@@ -25,23 +25,20 @@ export declare const contactFolders: {
|
|
|
25
25
|
readonly invalid_idempotency_key: "POST only: the Idempotency-Key header is not 1 to 255 printable ASCII characters.";
|
|
26
26
|
readonly idempotency_key_reused: "POST only: the Idempotency-Key was used in the last 24 hours with another method, path or body.";
|
|
27
27
|
readonly idempotency_key_in_progress: "POST only: the request first sent with this Idempotency-Key has not been answered yet.";
|
|
28
|
-
}
|
|
28
|
+
}>, "account_not_found" | "plan_module_unavailable" | "contacts_disabled"> & {
|
|
29
29
|
contacts_disabled: {
|
|
30
|
-
status: 409;
|
|
31
30
|
message: string;
|
|
32
31
|
};
|
|
33
32
|
account_not_found: {
|
|
34
|
-
status: 404;
|
|
35
33
|
message: string;
|
|
36
34
|
};
|
|
37
35
|
plan_module_unavailable: {
|
|
38
|
-
status: 403;
|
|
39
36
|
message: string;
|
|
40
37
|
};
|
|
41
|
-
}
|
|
38
|
+
}>;
|
|
42
39
|
};
|
|
43
40
|
export declare const contacts: {
|
|
44
|
-
list: import("@orpc/contract").
|
|
41
|
+
list: import("@orpc/contract").ProcedureContractBuilderWithInputOutput<z.ZodObject<{
|
|
45
42
|
accountId: z.ZodUUID;
|
|
46
43
|
q: z.ZodOptional<z.ZodString>;
|
|
47
44
|
folderId: z.ZodOptional<z.ZodUUID>;
|
|
@@ -82,7 +79,7 @@ export declare const contacts: {
|
|
|
82
79
|
updatedAt: z.ZodPreprocess<z.ZodDate, Date>;
|
|
83
80
|
}, z.core.$strip>>;
|
|
84
81
|
nextCursor: z.ZodNullable<z.ZodString>;
|
|
85
|
-
}, z.core.$strip>,
|
|
82
|
+
}, z.core.$strip>, Omit<import("../errors.js").DeclaredErrors<{
|
|
86
83
|
readonly invalid_input: "The request does not match the operation's input schema (a malformed body included); data.issues names each problem.";
|
|
87
84
|
readonly unauthenticated: "No usable credential: none was sent, or it is malformed, unknown, revoked or an expired account token.";
|
|
88
85
|
readonly api_key_expired: "The API key is past its expiry (or the grace of the rotation that replaced it).";
|
|
@@ -99,29 +96,24 @@ export declare const contacts: {
|
|
|
99
96
|
readonly invalid_idempotency_key: "POST only: the Idempotency-Key header is not 1 to 255 printable ASCII characters.";
|
|
100
97
|
readonly idempotency_key_reused: "POST only: the Idempotency-Key was used in the last 24 hours with another method, path or body.";
|
|
101
98
|
readonly idempotency_key_in_progress: "POST only: the request first sent with this Idempotency-Key has not been answered yet.";
|
|
102
|
-
}
|
|
99
|
+
}>, "account_not_found" | "plan_module_unavailable" | "invalid_cursor" | "contacts_disabled" | "unknown_contact_folder"> & {
|
|
103
100
|
unknown_contact_folder: {
|
|
104
|
-
status: 422;
|
|
105
101
|
message: string;
|
|
106
102
|
};
|
|
107
103
|
invalid_cursor: {
|
|
108
|
-
status: 400;
|
|
109
104
|
message: string;
|
|
110
105
|
};
|
|
111
106
|
contacts_disabled: {
|
|
112
|
-
status: 409;
|
|
113
107
|
message: string;
|
|
114
108
|
};
|
|
115
109
|
account_not_found: {
|
|
116
|
-
status: 404;
|
|
117
110
|
message: string;
|
|
118
111
|
};
|
|
119
112
|
plan_module_unavailable: {
|
|
120
|
-
status: 403;
|
|
121
113
|
message: string;
|
|
122
114
|
};
|
|
123
|
-
}
|
|
124
|
-
get: import("@orpc/contract").
|
|
115
|
+
}>;
|
|
116
|
+
get: import("@orpc/contract").ProcedureContractBuilderWithInputOutput<z.ZodObject<{
|
|
125
117
|
accountId: z.ZodUUID;
|
|
126
118
|
contactId: z.ZodUUID;
|
|
127
119
|
}, z.core.$strip>, z.ZodObject<{
|
|
@@ -156,7 +148,7 @@ export declare const contacts: {
|
|
|
156
148
|
notes: z.ZodNullable<z.ZodString>;
|
|
157
149
|
hasPhoto: z.ZodNullable<z.ZodBoolean>;
|
|
158
150
|
updatedAt: z.ZodPreprocess<z.ZodDate, Date>;
|
|
159
|
-
}, z.core.$strip>,
|
|
151
|
+
}, z.core.$strip>, Omit<import("../errors.js").DeclaredErrors<{
|
|
160
152
|
readonly invalid_input: "The request does not match the operation's input schema (a malformed body included); data.issues names each problem.";
|
|
161
153
|
readonly unauthenticated: "No usable credential: none was sent, or it is malformed, unknown, revoked or an expired account token.";
|
|
162
154
|
readonly api_key_expired: "The API key is past its expiry (or the grace of the rotation that replaced it).";
|
|
@@ -173,28 +165,24 @@ export declare const contacts: {
|
|
|
173
165
|
readonly invalid_idempotency_key: "POST only: the Idempotency-Key header is not 1 to 255 printable ASCII characters.";
|
|
174
166
|
readonly idempotency_key_reused: "POST only: the Idempotency-Key was used in the last 24 hours with another method, path or body.";
|
|
175
167
|
readonly idempotency_key_in_progress: "POST only: the request first sent with this Idempotency-Key has not been answered yet.";
|
|
176
|
-
}
|
|
168
|
+
}>, "account_not_found" | "plan_module_unavailable" | "contacts_disabled" | "contact_not_found"> & {
|
|
177
169
|
contact_not_found: {
|
|
178
|
-
status: 404;
|
|
179
170
|
message: string;
|
|
180
171
|
};
|
|
181
172
|
contacts_disabled: {
|
|
182
|
-
status: 409;
|
|
183
173
|
message: string;
|
|
184
174
|
};
|
|
185
175
|
account_not_found: {
|
|
186
|
-
status: 404;
|
|
187
176
|
message: string;
|
|
188
177
|
};
|
|
189
178
|
plan_module_unavailable: {
|
|
190
|
-
status: 403;
|
|
191
179
|
message: string;
|
|
192
180
|
};
|
|
193
|
-
}
|
|
194
|
-
photo: import("@orpc/contract").
|
|
181
|
+
}>;
|
|
182
|
+
photo: import("@orpc/contract").ProcedureContractBuilderWithInputOutput<z.ZodObject<{
|
|
195
183
|
accountId: z.ZodUUID;
|
|
196
184
|
contactId: z.ZodUUID;
|
|
197
|
-
}, z.core.$strip>, z.ZodFile,
|
|
185
|
+
}, z.core.$strip>, z.ZodFile, Omit<import("../errors.js").DeclaredErrors<{
|
|
198
186
|
readonly invalid_input: "The request does not match the operation's input schema (a malformed body included); data.issues names each problem.";
|
|
199
187
|
readonly unauthenticated: "No usable credential: none was sent, or it is malformed, unknown, revoked or an expired account token.";
|
|
200
188
|
readonly api_key_expired: "The API key is past its expiry (or the grace of the rotation that replaced it).";
|
|
@@ -211,69 +199,54 @@ export declare const contacts: {
|
|
|
211
199
|
readonly invalid_idempotency_key: "POST only: the Idempotency-Key header is not 1 to 255 printable ASCII characters.";
|
|
212
200
|
readonly idempotency_key_reused: "POST only: the Idempotency-Key was used in the last 24 hours with another method, path or body.";
|
|
213
201
|
readonly idempotency_key_in_progress: "POST only: the request first sent with this Idempotency-Key has not been answered yet.";
|
|
214
|
-
}
|
|
202
|
+
}>, "provider_unavailable" | "account_not_found" | "plan_module_unavailable" | "account_paused" | "account_disabled" | "account_reauth_required" | "account_misconfigured" | "contacts_disabled" | "provider_not_found" | "provider_throttled" | "provider_forbidden" | "provider_conflict" | "provider_rejected" | "contact_not_found" | "photo_not_found"> & {
|
|
215
203
|
photo_not_found: {
|
|
216
|
-
status: 404;
|
|
217
204
|
message: string;
|
|
218
205
|
};
|
|
219
206
|
provider_not_found: {
|
|
220
|
-
status: 404;
|
|
221
207
|
message: string;
|
|
222
208
|
};
|
|
223
209
|
provider_forbidden: {
|
|
224
|
-
status: 403;
|
|
225
210
|
message: string;
|
|
226
211
|
};
|
|
227
212
|
provider_conflict: {
|
|
228
|
-
status: 409;
|
|
229
213
|
message: string;
|
|
230
214
|
};
|
|
231
215
|
provider_rejected: {
|
|
232
|
-
status: 400;
|
|
233
216
|
message: string;
|
|
234
217
|
};
|
|
235
218
|
provider_unavailable: {
|
|
236
|
-
status: 502;
|
|
237
219
|
message: string;
|
|
238
220
|
};
|
|
239
221
|
provider_throttled: {
|
|
240
|
-
status: 429;
|
|
241
222
|
message: string;
|
|
242
223
|
};
|
|
243
224
|
account_paused: {
|
|
244
|
-
status: 409;
|
|
245
225
|
message: string;
|
|
246
226
|
};
|
|
247
227
|
account_disabled: {
|
|
248
|
-
status: 409;
|
|
249
228
|
message: string;
|
|
250
229
|
};
|
|
251
230
|
account_reauth_required: {
|
|
252
|
-
status: 409;
|
|
253
231
|
message: string;
|
|
254
232
|
};
|
|
255
233
|
account_misconfigured: {
|
|
256
|
-
status: 409;
|
|
257
234
|
message: string;
|
|
258
235
|
};
|
|
259
236
|
contact_not_found: {
|
|
260
|
-
status: 404;
|
|
261
237
|
message: string;
|
|
262
238
|
};
|
|
263
239
|
contacts_disabled: {
|
|
264
|
-
status: 409;
|
|
265
240
|
message: string;
|
|
266
241
|
};
|
|
267
242
|
account_not_found: {
|
|
268
|
-
status: 404;
|
|
269
243
|
message: string;
|
|
270
244
|
};
|
|
271
245
|
plan_module_unavailable: {
|
|
272
|
-
status: 403;
|
|
273
246
|
message: string;
|
|
274
247
|
};
|
|
275
|
-
}
|
|
276
|
-
create: import("@orpc/contract").
|
|
248
|
+
}>;
|
|
249
|
+
create: import("@orpc/contract").ProcedureContractBuilderWithInputOutput<z.ZodObject<{
|
|
277
250
|
accountId: z.ZodUUID;
|
|
278
251
|
folderId: z.ZodOptional<z.ZodUUID>;
|
|
279
252
|
displayName: z.ZodOptional<z.ZodString>;
|
|
@@ -335,7 +308,7 @@ export declare const contacts: {
|
|
|
335
308
|
notes: z.ZodNullable<z.ZodString>;
|
|
336
309
|
hasPhoto: z.ZodNullable<z.ZodBoolean>;
|
|
337
310
|
updatedAt: z.ZodPreprocess<z.ZodDate, Date>;
|
|
338
|
-
}, z.core.$strip>,
|
|
311
|
+
}, z.core.$strip>, Omit<import("../errors.js").DeclaredErrors<{
|
|
339
312
|
readonly invalid_input: "The request does not match the operation's input schema (a malformed body included); data.issues names each problem.";
|
|
340
313
|
readonly unauthenticated: "No usable credential: none was sent, or it is malformed, unknown, revoked or an expired account token.";
|
|
341
314
|
readonly api_key_expired: "The API key is past its expiry (or the grace of the rotation that replaced it).";
|
|
@@ -352,77 +325,60 @@ export declare const contacts: {
|
|
|
352
325
|
readonly invalid_idempotency_key: "POST only: the Idempotency-Key header is not 1 to 255 printable ASCII characters.";
|
|
353
326
|
readonly idempotency_key_reused: "POST only: the Idempotency-Key was used in the last 24 hours with another method, path or body.";
|
|
354
327
|
readonly idempotency_key_in_progress: "POST only: the request first sent with this Idempotency-Key has not been answered yet.";
|
|
355
|
-
}
|
|
328
|
+
}>, "provider_unavailable" | "account_not_found" | "plan_module_unavailable" | "contact_unidentifiable" | "account_paused" | "account_disabled" | "account_reauth_required" | "account_misconfigured" | "contacts_disabled" | "provider_not_found" | "provider_throttled" | "provider_forbidden" | "provider_conflict" | "provider_unsupported" | "provider_rejected" | "contact_not_found" | "unknown_contact_folder"> & {
|
|
356
329
|
contact_not_found: {
|
|
357
|
-
status: 404;
|
|
358
330
|
message: string;
|
|
359
331
|
};
|
|
360
332
|
unknown_contact_folder: {
|
|
361
|
-
status: 422;
|
|
362
333
|
message: string;
|
|
363
334
|
};
|
|
364
335
|
contact_unidentifiable: {
|
|
365
|
-
status: 400;
|
|
366
336
|
message: string;
|
|
367
337
|
};
|
|
368
338
|
provider_unsupported: {
|
|
369
|
-
status: 400;
|
|
370
339
|
message: string;
|
|
371
340
|
};
|
|
372
341
|
provider_not_found: {
|
|
373
|
-
status: 404;
|
|
374
342
|
message: string;
|
|
375
343
|
};
|
|
376
344
|
provider_forbidden: {
|
|
377
|
-
status: 403;
|
|
378
345
|
message: string;
|
|
379
346
|
};
|
|
380
347
|
provider_conflict: {
|
|
381
|
-
status: 409;
|
|
382
348
|
message: string;
|
|
383
349
|
};
|
|
384
350
|
provider_rejected: {
|
|
385
|
-
status: 400;
|
|
386
351
|
message: string;
|
|
387
352
|
};
|
|
388
353
|
provider_unavailable: {
|
|
389
|
-
status: 502;
|
|
390
354
|
message: string;
|
|
391
355
|
};
|
|
392
356
|
provider_throttled: {
|
|
393
|
-
status: 429;
|
|
394
357
|
message: string;
|
|
395
358
|
};
|
|
396
359
|
account_paused: {
|
|
397
|
-
status: 409;
|
|
398
360
|
message: string;
|
|
399
361
|
};
|
|
400
362
|
account_disabled: {
|
|
401
|
-
status: 409;
|
|
402
363
|
message: string;
|
|
403
364
|
};
|
|
404
365
|
account_reauth_required: {
|
|
405
|
-
status: 409;
|
|
406
366
|
message: string;
|
|
407
367
|
};
|
|
408
368
|
account_misconfigured: {
|
|
409
|
-
status: 409;
|
|
410
369
|
message: string;
|
|
411
370
|
};
|
|
412
371
|
contacts_disabled: {
|
|
413
|
-
status: 409;
|
|
414
372
|
message: string;
|
|
415
373
|
};
|
|
416
374
|
account_not_found: {
|
|
417
|
-
status: 404;
|
|
418
375
|
message: string;
|
|
419
376
|
};
|
|
420
377
|
plan_module_unavailable: {
|
|
421
|
-
status: 403;
|
|
422
378
|
message: string;
|
|
423
379
|
};
|
|
424
|
-
}
|
|
425
|
-
update: import("@orpc/contract").
|
|
380
|
+
}>;
|
|
381
|
+
update: import("@orpc/contract").ProcedureContractBuilderWithInputOutput<z.ZodObject<{
|
|
426
382
|
accountId: z.ZodUUID;
|
|
427
383
|
contactId: z.ZodUUID;
|
|
428
384
|
displayName: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
@@ -484,7 +440,7 @@ export declare const contacts: {
|
|
|
484
440
|
notes: z.ZodNullable<z.ZodString>;
|
|
485
441
|
hasPhoto: z.ZodNullable<z.ZodBoolean>;
|
|
486
442
|
updatedAt: z.ZodPreprocess<z.ZodDate, Date>;
|
|
487
|
-
}, z.core.$strip>,
|
|
443
|
+
}, z.core.$strip>, Omit<import("../errors.js").DeclaredErrors<{
|
|
488
444
|
readonly invalid_input: "The request does not match the operation's input schema (a malformed body included); data.issues names each problem.";
|
|
489
445
|
readonly unauthenticated: "No usable credential: none was sent, or it is malformed, unknown, revoked or an expired account token.";
|
|
490
446
|
readonly api_key_expired: "The API key is past its expiry (or the grace of the rotation that replaced it).";
|
|
@@ -501,76 +457,60 @@ export declare const contacts: {
|
|
|
501
457
|
readonly invalid_idempotency_key: "POST only: the Idempotency-Key header is not 1 to 255 printable ASCII characters.";
|
|
502
458
|
readonly idempotency_key_reused: "POST only: the Idempotency-Key was used in the last 24 hours with another method, path or body.";
|
|
503
459
|
readonly idempotency_key_in_progress: "POST only: the request first sent with this Idempotency-Key has not been answered yet.";
|
|
504
|
-
}
|
|
460
|
+
}>, "provider_unavailable" | "account_not_found" | "plan_module_unavailable" | "contact_unidentifiable" | "account_paused" | "account_disabled" | "account_reauth_required" | "account_misconfigured" | "contacts_disabled" | "provider_not_found" | "provider_throttled" | "provider_forbidden" | "provider_conflict" | "provider_unsupported" | "provider_rejected" | "contact_not_found"> & {
|
|
505
461
|
contact_unidentifiable: {
|
|
506
|
-
status: 400;
|
|
507
462
|
message: string;
|
|
508
463
|
};
|
|
509
464
|
provider_unsupported: {
|
|
510
|
-
status: 400;
|
|
511
465
|
message: string;
|
|
512
466
|
};
|
|
513
467
|
provider_not_found: {
|
|
514
|
-
status: 404;
|
|
515
468
|
message: string;
|
|
516
469
|
};
|
|
517
470
|
provider_forbidden: {
|
|
518
|
-
status: 403;
|
|
519
471
|
message: string;
|
|
520
472
|
};
|
|
521
473
|
provider_conflict: {
|
|
522
|
-
status: 409;
|
|
523
474
|
message: string;
|
|
524
475
|
};
|
|
525
476
|
provider_rejected: {
|
|
526
|
-
status: 400;
|
|
527
477
|
message: string;
|
|
528
478
|
};
|
|
529
479
|
provider_unavailable: {
|
|
530
|
-
status: 502;
|
|
531
480
|
message: string;
|
|
532
481
|
};
|
|
533
482
|
provider_throttled: {
|
|
534
|
-
status: 429;
|
|
535
483
|
message: string;
|
|
536
484
|
};
|
|
537
485
|
account_paused: {
|
|
538
|
-
status: 409;
|
|
539
486
|
message: string;
|
|
540
487
|
};
|
|
541
488
|
account_disabled: {
|
|
542
|
-
status: 409;
|
|
543
489
|
message: string;
|
|
544
490
|
};
|
|
545
491
|
account_reauth_required: {
|
|
546
|
-
status: 409;
|
|
547
492
|
message: string;
|
|
548
493
|
};
|
|
549
494
|
account_misconfigured: {
|
|
550
|
-
status: 409;
|
|
551
495
|
message: string;
|
|
552
496
|
};
|
|
553
497
|
contact_not_found: {
|
|
554
|
-
status: 404;
|
|
555
498
|
message: string;
|
|
556
499
|
};
|
|
557
500
|
contacts_disabled: {
|
|
558
|
-
status: 409;
|
|
559
501
|
message: string;
|
|
560
502
|
};
|
|
561
503
|
account_not_found: {
|
|
562
|
-
status: 404;
|
|
563
504
|
message: string;
|
|
564
505
|
};
|
|
565
506
|
plan_module_unavailable: {
|
|
566
|
-
status: 403;
|
|
567
507
|
message: string;
|
|
568
508
|
};
|
|
569
|
-
}
|
|
570
|
-
delete: import("@orpc/contract").
|
|
509
|
+
}>;
|
|
510
|
+
delete: import("@orpc/contract").ProcedureContractBuilderWithInputOutput<z.ZodObject<{
|
|
571
511
|
accountId: z.ZodUUID;
|
|
572
512
|
contactId: z.ZodUUID;
|
|
573
|
-
}, z.core.$strip>, z.ZodVoid,
|
|
513
|
+
}, z.core.$strip>, z.ZodVoid, Omit<import("../errors.js").DeclaredErrors<{
|
|
574
514
|
readonly invalid_input: "The request does not match the operation's input schema (a malformed body included); data.issues names each problem.";
|
|
575
515
|
readonly unauthenticated: "No usable credential: none was sent, or it is malformed, unknown, revoked or an expired account token.";
|
|
576
516
|
readonly api_key_expired: "The API key is past its expiry (or the grace of the rotation that replaced it).";
|
|
@@ -587,62 +527,48 @@ export declare const contacts: {
|
|
|
587
527
|
readonly invalid_idempotency_key: "POST only: the Idempotency-Key header is not 1 to 255 printable ASCII characters.";
|
|
588
528
|
readonly idempotency_key_reused: "POST only: the Idempotency-Key was used in the last 24 hours with another method, path or body.";
|
|
589
529
|
readonly idempotency_key_in_progress: "POST only: the request first sent with this Idempotency-Key has not been answered yet.";
|
|
590
|
-
}
|
|
530
|
+
}>, "provider_unavailable" | "account_not_found" | "plan_module_unavailable" | "account_paused" | "account_disabled" | "account_reauth_required" | "account_misconfigured" | "contacts_disabled" | "provider_not_found" | "provider_throttled" | "provider_forbidden" | "provider_conflict" | "provider_rejected" | "contact_not_found"> & {
|
|
591
531
|
provider_not_found: {
|
|
592
|
-
status: 404;
|
|
593
532
|
message: string;
|
|
594
533
|
};
|
|
595
534
|
provider_forbidden: {
|
|
596
|
-
status: 403;
|
|
597
535
|
message: string;
|
|
598
536
|
};
|
|
599
537
|
provider_conflict: {
|
|
600
|
-
status: 409;
|
|
601
538
|
message: string;
|
|
602
539
|
};
|
|
603
540
|
provider_rejected: {
|
|
604
|
-
status: 400;
|
|
605
541
|
message: string;
|
|
606
542
|
};
|
|
607
543
|
provider_unavailable: {
|
|
608
|
-
status: 502;
|
|
609
544
|
message: string;
|
|
610
545
|
};
|
|
611
546
|
provider_throttled: {
|
|
612
|
-
status: 429;
|
|
613
547
|
message: string;
|
|
614
548
|
};
|
|
615
549
|
account_paused: {
|
|
616
|
-
status: 409;
|
|
617
550
|
message: string;
|
|
618
551
|
};
|
|
619
552
|
account_disabled: {
|
|
620
|
-
status: 409;
|
|
621
553
|
message: string;
|
|
622
554
|
};
|
|
623
555
|
account_reauth_required: {
|
|
624
|
-
status: 409;
|
|
625
556
|
message: string;
|
|
626
557
|
};
|
|
627
558
|
account_misconfigured: {
|
|
628
|
-
status: 409;
|
|
629
559
|
message: string;
|
|
630
560
|
};
|
|
631
561
|
contact_not_found: {
|
|
632
|
-
status: 404;
|
|
633
562
|
message: string;
|
|
634
563
|
};
|
|
635
564
|
contacts_disabled: {
|
|
636
|
-
status: 409;
|
|
637
565
|
message: string;
|
|
638
566
|
};
|
|
639
567
|
account_not_found: {
|
|
640
|
-
status: 404;
|
|
641
568
|
message: string;
|
|
642
569
|
};
|
|
643
570
|
plan_module_unavailable: {
|
|
644
|
-
status: 403;
|
|
645
571
|
message: string;
|
|
646
572
|
};
|
|
647
|
-
}
|
|
573
|
+
}>;
|
|
648
574
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export declare const emailValidations: {
|
|
2
|
-
create: import("@orpc/contract").
|
|
2
|
+
create: import("@orpc/contract").ProcedureContractBuilderWithInputOutput<import("zod").ZodObject<{
|
|
3
3
|
addresses: import("zod").ZodArray<import("zod").ZodEmail>;
|
|
4
4
|
suppressInvalid: import("zod").ZodDefault<import("zod").ZodBoolean>;
|
|
5
5
|
refresh: import("zod").ZodDefault<import("zod").ZodBoolean>;
|
|
@@ -24,7 +24,7 @@ export declare const emailValidations: {
|
|
|
24
24
|
cached: import("zod").ZodBoolean;
|
|
25
25
|
checkedAt: import("zod").ZodPreprocess<import("zod").ZodDate, Date>;
|
|
26
26
|
}, import("zod/v4/core").$strip>>;
|
|
27
|
-
}, import("zod/v4/core").$strip>,
|
|
27
|
+
}, import("zod/v4/core").$strip>, Omit<import("../errors.js").DeclaredErrors<{
|
|
28
28
|
readonly invalid_input: "The request does not match the operation's input schema (a malformed body included); data.issues names each problem.";
|
|
29
29
|
readonly unauthenticated: "No usable credential: none was sent, or it is malformed, unknown, revoked or an expired account token.";
|
|
30
30
|
readonly api_key_expired: "The API key is past its expiry (or the grace of the rotation that replaced it).";
|
|
@@ -41,15 +41,15 @@ export declare const emailValidations: {
|
|
|
41
41
|
readonly invalid_idempotency_key: "POST only: the Idempotency-Key header is not 1 to 255 printable ASCII characters.";
|
|
42
42
|
readonly idempotency_key_reused: "POST only: the Idempotency-Key was used in the last 24 hours with another method, path or body.";
|
|
43
43
|
readonly idempotency_key_in_progress: "POST only: the request first sent with this Idempotency-Key has not been answered yet.";
|
|
44
|
-
}
|
|
44
|
+
}>, "plan_required" | "plan_limit_validations" | "validation_credits_exhausted" | "email_validation_disabled" | "email_validation_unavailable" | "email_validation_suspended"> & import("../errors.js").DeclaredErrors<{
|
|
45
45
|
readonly email_validation_disabled: "Email validation is unavailable.";
|
|
46
46
|
readonly email_validation_unavailable: "The validation service fails or does not answer in time; no address is suppressed.";
|
|
47
47
|
readonly email_validation_suspended: "The validation service refuses Workwae's requests for now; try again later.";
|
|
48
48
|
readonly plan_limit_validations: "The addresses to check again exceed what the plan allows today (UTC); nothing was checked.";
|
|
49
49
|
readonly plan_required: "The workspace has no plan and is not its owner's Free workspace (the Free plan covers one workspace per owner): choose a plan under Billing.";
|
|
50
50
|
readonly validation_credits_exhausted: "The tenant has fewer email validation credits than the addresses to check again; data.balance and data.needed say how many; nothing was checked.";
|
|
51
|
-
}
|
|
52
|
-
list: import("@orpc/contract").
|
|
51
|
+
}>>;
|
|
52
|
+
list: import("@orpc/contract").ProcedureContractBuilderWithInputOutput<import("zod").ZodObject<{
|
|
53
53
|
limit: import("zod").ZodDefault<import("zod").ZodCoercedNumber<unknown>>;
|
|
54
54
|
cursor: import("zod").ZodOptional<import("zod").ZodString>;
|
|
55
55
|
address: import("zod").ZodOptional<import("zod").ZodString>;
|
|
@@ -83,7 +83,7 @@ export declare const emailValidations: {
|
|
|
83
83
|
createdAt: import("zod").ZodPreprocess<import("zod").ZodDate, Date>;
|
|
84
84
|
}, import("zod/v4/core").$strip>>;
|
|
85
85
|
nextCursor: import("zod").ZodNullable<import("zod").ZodString>;
|
|
86
|
-
}, import("zod/v4/core").$strip>,
|
|
86
|
+
}, import("zod/v4/core").$strip>, Omit<import("../errors.js").DeclaredErrors<{
|
|
87
87
|
readonly invalid_input: "The request does not match the operation's input schema (a malformed body included); data.issues names each problem.";
|
|
88
88
|
readonly unauthenticated: "No usable credential: none was sent, or it is malformed, unknown, revoked or an expired account token.";
|
|
89
89
|
readonly api_key_expired: "The API key is past its expiry (or the grace of the rotation that replaced it).";
|
|
@@ -100,7 +100,7 @@ export declare const emailValidations: {
|
|
|
100
100
|
readonly invalid_idempotency_key: "POST only: the Idempotency-Key header is not 1 to 255 printable ASCII characters.";
|
|
101
101
|
readonly idempotency_key_reused: "POST only: the Idempotency-Key was used in the last 24 hours with another method, path or body.";
|
|
102
102
|
readonly idempotency_key_in_progress: "POST only: the request first sent with this Idempotency-Key has not been answered yet.";
|
|
103
|
-
}
|
|
103
|
+
}>, "invalid_cursor"> & import("../errors.js").DeclaredErrors<{
|
|
104
104
|
readonly invalid_cursor: "The cursor is not one this list issued.";
|
|
105
|
-
}
|
|
105
|
+
}>>;
|
|
106
106
|
};
|
package/contract/errors.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import
|
|
1
|
+
import "@orpc/openapi/extensions/route";
|
|
2
|
+
import { type ErrorReason, type ReasonDataSchema, type ReasonTable } from "./reasons.js";
|
|
2
3
|
export type DeclaredError<R extends ErrorReason> = {
|
|
3
|
-
status: ReasonStatus<R>;
|
|
4
4
|
message: string;
|
|
5
5
|
} & (ReasonDataSchema<R> extends undefined ? unknown : {
|
|
6
6
|
data: ReasonDataSchema<R>;
|
|
@@ -9,7 +9,6 @@ export type DeclaredErrors<C> = {
|
|
|
9
9
|
[R in keyof C & ErrorReason]: DeclaredError<R>;
|
|
10
10
|
};
|
|
11
11
|
export declare function errorMap(table: ReasonTable, conditions: Record<string, string | undefined>): Record<string, {
|
|
12
|
-
status: number;
|
|
13
12
|
message: string;
|
|
14
13
|
data?: unknown;
|
|
15
14
|
}>;
|
|
@@ -34,7 +33,7 @@ export declare const GLOBAL_ERRORS: DeclaredErrors<{
|
|
|
34
33
|
readonly idempotency_key_reused: "POST only: the Idempotency-Key was used in the last 24 hours with another method, path or body.";
|
|
35
34
|
readonly idempotency_key_in_progress: "POST only: the request first sent with this Idempotency-Key has not been answered yet.";
|
|
36
35
|
}>;
|
|
37
|
-
export declare const base: import("@orpc/contract").ContractBuilder<
|
|
36
|
+
export declare const base: import("@orpc/contract").ContractBuilder<DeclaredErrors<{
|
|
38
37
|
readonly invalid_input: "The request does not match the operation's input schema (a malformed body included); data.issues names each problem.";
|
|
39
38
|
readonly unauthenticated: "No usable credential: none was sent, or it is malformed, unknown, revoked or an expired account token.";
|
|
40
39
|
readonly api_key_expired: "The API key is past its expiry (or the grace of the rotation that replaced it).";
|
|
@@ -51,7 +50,7 @@ export declare const base: import("@orpc/contract").ContractBuilder<import("@orp
|
|
|
51
50
|
readonly invalid_idempotency_key: "POST only: the Idempotency-Key header is not 1 to 255 printable ASCII characters.";
|
|
52
51
|
readonly idempotency_key_reused: "POST only: the Idempotency-Key was used in the last 24 hours with another method, path or body.";
|
|
53
52
|
readonly idempotency_key_in_progress: "POST only: the request first sent with this Idempotency-Key has not been answered yet.";
|
|
54
|
-
}
|
|
53
|
+
}>>;
|
|
55
54
|
export declare const SESSION_ONLY: DeclaredErrors<{
|
|
56
55
|
readonly session_required: "The caller is not a console session (only console sessions may call this).";
|
|
57
56
|
}>;
|
|
@@ -69,15 +68,12 @@ export declare const ACCOUNT_NOT_FOUND: DeclaredErrors<{
|
|
|
69
68
|
}>;
|
|
70
69
|
export declare const MAIL_ACCOUNT: {
|
|
71
70
|
mail_disabled: {
|
|
72
|
-
status: 409;
|
|
73
71
|
message: string;
|
|
74
72
|
};
|
|
75
73
|
account_not_found: {
|
|
76
|
-
status: 404;
|
|
77
74
|
message: string;
|
|
78
75
|
};
|
|
79
76
|
plan_module_unavailable: {
|
|
80
|
-
status: 403;
|
|
81
77
|
message: string;
|
|
82
78
|
};
|
|
83
79
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export declare const changes: {
|
|
2
|
-
list: import("@orpc/contract").
|
|
2
|
+
list: import("@orpc/contract").ProcedureContractBuilderWithInputOutput<import("zod").ZodObject<{
|
|
3
3
|
cursor: import("zod").ZodOptional<import("zod").ZodString>;
|
|
4
4
|
limit: import("zod").ZodDefault<import("zod").ZodCoercedNumber<unknown>>;
|
|
5
5
|
types: import("zod").ZodOptional<import("zod").ZodPipe<import("zod").ZodPipe<import("zod").ZodUnion<readonly [
|
|
@@ -94,7 +94,7 @@ export declare const changes: {
|
|
|
94
94
|
...(import("./models.js").EventEnvelope<"account.connected"> | import("./models.js").EventEnvelope<"account.updated"> | import("./models.js").EventEnvelope<"account.deleted"> | import("./models.js").EventEnvelope<"account.reauth_required"> | import("./models.js").EventEnvelope<"account.initialized"> | import("./models.js").EventEnvelope<"account.purged"> | import("./models.js").EventEnvelope<"mailbox.created"> | import("./models.js").EventEnvelope<"mailbox.updated"> | import("./models.js").EventEnvelope<"mailbox.deleted"> | import("./models.js").EventEnvelope<"message.created"> | import("./models.js").EventEnvelope<"message.updated"> | import("./models.js").EventEnvelope<"message.deleted"> | import("./models.js").EventEnvelope<"message.bounced"> | import("./models.js").EventEnvelope<"message.classified"> | import("./models.js").EventEnvelope<"message.opened"> | import("./models.js").EventEnvelope<"message.clicked"> | import("./models.js").EventEnvelope<"send.sent"> | import("./models.js").EventEnvelope<"send.retrying"> | import("./models.js").EventEnvelope<"send.failed"> | import("./models.js").EventEnvelope<"send.rescheduled"> | import("./models.js").EventEnvelope<"send.cancelled"> | import("./models.js").EventEnvelope<"suppression.created"> | import("./models.js").EventEnvelope<"calendar.initialized"> | import("./models.js").EventEnvelope<"calendar.created"> | import("./models.js").EventEnvelope<"calendar.updated"> | import("./models.js").EventEnvelope<"calendar.deleted"> | import("./models.js").EventEnvelope<"calendar_event.created"> | import("./models.js").EventEnvelope<"calendar_event.updated"> | import("./models.js").EventEnvelope<"calendar_event.deleted"> | import("./models.js").EventEnvelope<"contacts.initialized"> | import("./models.js").EventEnvelope<"contact.created"> | import("./models.js").EventEnvelope<"contact.updated"> | import("./models.js").EventEnvelope<"contact.deleted"> | import("./models.js").EventEnvelope<"export.completed"> | import("./models.js").EventEnvelope<"export.failed"> | import("./models.js").EventEnvelope<"meeting_connection.connected"> | import("./models.js").EventEnvelope<"meeting_connection.reauth_required"> | import("./models.js").EventEnvelope<"booking.created"> | import("./models.js").EventEnvelope<"booking.cancelled"> | import("./models.js").EventEnvelope<"webhook.test">)[]
|
|
95
95
|
], "type">>;
|
|
96
96
|
nextCursor: import("zod").ZodString;
|
|
97
|
-
}, import("zod/v4/core").$strip>,
|
|
97
|
+
}, import("zod/v4/core").$strip>, Omit<import("../errors.js").DeclaredErrors<{
|
|
98
98
|
readonly invalid_input: "The request does not match the operation's input schema (a malformed body included); data.issues names each problem.";
|
|
99
99
|
readonly unauthenticated: "No usable credential: none was sent, or it is malformed, unknown, revoked or an expired account token.";
|
|
100
100
|
readonly api_key_expired: "The API key is past its expiry (or the grace of the rotation that replaced it).";
|
|
@@ -111,7 +111,7 @@ export declare const changes: {
|
|
|
111
111
|
readonly invalid_idempotency_key: "POST only: the Idempotency-Key header is not 1 to 255 printable ASCII characters.";
|
|
112
112
|
readonly idempotency_key_reused: "POST only: the Idempotency-Key was used in the last 24 hours with another method, path or body.";
|
|
113
113
|
readonly idempotency_key_in_progress: "POST only: the request first sent with this Idempotency-Key has not been answered yet.";
|
|
114
|
-
}
|
|
114
|
+
}>, "invalid_cursor"> & import("../errors.js").DeclaredErrors<{
|
|
115
115
|
readonly invalid_cursor: "The cursor is not one this list issued.";
|
|
116
|
-
}
|
|
116
|
+
}>>;
|
|
117
117
|
};
|