@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 orgConnections: {
|
|
3
|
-
list: import("@orpc/contract").
|
|
3
|
+
list: import("@orpc/contract").ProcedureContractBuilderWithOutput<z.ZodObject<{
|
|
4
4
|
items: z.ZodArray<z.ZodObject<{
|
|
5
5
|
id: z.ZodUUID;
|
|
6
6
|
kind: z.ZodEnum<{
|
|
@@ -48,7 +48,7 @@ export declare const orgConnections: {
|
|
|
48
48
|
createdAt: z.ZodPreprocess<z.ZodDate, Date>;
|
|
49
49
|
updatedAt: z.ZodPreprocess<z.ZodDate, Date>;
|
|
50
50
|
}, z.core.$strip>>;
|
|
51
|
-
}, z.core.$strip>, import("
|
|
51
|
+
}, z.core.$strip>, import("../errors.js").DeclaredErrors<{
|
|
52
52
|
readonly invalid_input: "The request does not match the operation's input schema (a malformed body included); data.issues names each problem.";
|
|
53
53
|
readonly unauthenticated: "No usable credential: none was sent, or it is malformed, unknown, revoked or an expired account token.";
|
|
54
54
|
readonly api_key_expired: "The API key is past its expiry (or the grace of the rotation that replaced it).";
|
|
@@ -65,8 +65,8 @@ export declare const orgConnections: {
|
|
|
65
65
|
readonly invalid_idempotency_key: "POST only: the Idempotency-Key header is not 1 to 255 printable ASCII characters.";
|
|
66
66
|
readonly idempotency_key_reused: "POST only: the Idempotency-Key was used in the last 24 hours with another method, path or body.";
|
|
67
67
|
readonly idempotency_key_in_progress: "POST only: the request first sent with this Idempotency-Key has not been answered yet.";
|
|
68
|
-
}
|
|
69
|
-
create: import("@orpc/contract").
|
|
68
|
+
}>>;
|
|
69
|
+
create: import("@orpc/contract").ProcedureContractBuilderWithInputOutput<z.ZodDiscriminatedUnion<[
|
|
70
70
|
z.ZodObject<{
|
|
71
71
|
kind: z.ZodLiteral<"google_delegation">;
|
|
72
72
|
name: z.ZodString;
|
|
@@ -151,7 +151,7 @@ export declare const orgConnections: {
|
|
|
151
151
|
accounts: z.ZodNumber;
|
|
152
152
|
createdAt: z.ZodPreprocess<z.ZodDate, Date>;
|
|
153
153
|
updatedAt: z.ZodPreprocess<z.ZodDate, Date>;
|
|
154
|
-
}, z.core.$strip>,
|
|
154
|
+
}, z.core.$strip>, Omit<import("../errors.js").DeclaredErrors<{
|
|
155
155
|
readonly invalid_input: "The request does not match the operation's input schema (a malformed body included); data.issues names each problem.";
|
|
156
156
|
readonly unauthenticated: "No usable credential: none was sent, or it is malformed, unknown, revoked or an expired account token.";
|
|
157
157
|
readonly api_key_expired: "The API key is past its expiry (or the grace of the rotation that replaced it).";
|
|
@@ -168,33 +168,27 @@ export declare const orgConnections: {
|
|
|
168
168
|
readonly invalid_idempotency_key: "POST only: the Idempotency-Key header is not 1 to 255 printable ASCII characters.";
|
|
169
169
|
readonly idempotency_key_reused: "POST only: the Idempotency-Key was used in the last 24 hours with another method, path or body.";
|
|
170
170
|
readonly idempotency_key_in_progress: "POST only: the request first sent with this Idempotency-Key has not been answered yet.";
|
|
171
|
-
}
|
|
171
|
+
}>, "provider_not_configured" | "connect_domain_inactive" | "invalid_certificate" | "invalid_service_account_key" | "connect_domain_unsupported" | "directory_id_not_allowed"> & {
|
|
172
172
|
provider_not_configured: {
|
|
173
|
-
status: 400;
|
|
174
173
|
message: string;
|
|
175
174
|
};
|
|
176
175
|
connect_domain_inactive: {
|
|
177
|
-
status: 409;
|
|
178
176
|
message: string;
|
|
179
177
|
};
|
|
180
178
|
connect_domain_unsupported: {
|
|
181
|
-
status: 400;
|
|
182
179
|
message: string;
|
|
183
180
|
};
|
|
184
181
|
invalid_certificate: {
|
|
185
|
-
status: 400;
|
|
186
182
|
message: string;
|
|
187
183
|
};
|
|
188
184
|
invalid_service_account_key: {
|
|
189
|
-
status: 400;
|
|
190
185
|
message: string;
|
|
191
186
|
};
|
|
192
187
|
directory_id_not_allowed: {
|
|
193
|
-
status: 400;
|
|
194
188
|
message: string;
|
|
195
189
|
};
|
|
196
|
-
}
|
|
197
|
-
get: import("@orpc/contract").
|
|
190
|
+
}>;
|
|
191
|
+
get: import("@orpc/contract").ProcedureContractBuilderWithInputOutput<z.ZodObject<{
|
|
198
192
|
connectionId: z.ZodUUID;
|
|
199
193
|
}, z.core.$strip>, z.ZodObject<{
|
|
200
194
|
id: z.ZodUUID;
|
|
@@ -242,7 +236,7 @@ export declare const orgConnections: {
|
|
|
242
236
|
accounts: z.ZodNumber;
|
|
243
237
|
createdAt: z.ZodPreprocess<z.ZodDate, Date>;
|
|
244
238
|
updatedAt: z.ZodPreprocess<z.ZodDate, Date>;
|
|
245
|
-
}, z.core.$strip>,
|
|
239
|
+
}, z.core.$strip>, Omit<import("../errors.js").DeclaredErrors<{
|
|
246
240
|
readonly invalid_input: "The request does not match the operation's input schema (a malformed body included); data.issues names each problem.";
|
|
247
241
|
readonly unauthenticated: "No usable credential: none was sent, or it is malformed, unknown, revoked or an expired account token.";
|
|
248
242
|
readonly api_key_expired: "The API key is past its expiry (or the grace of the rotation that replaced it).";
|
|
@@ -259,10 +253,10 @@ export declare const orgConnections: {
|
|
|
259
253
|
readonly invalid_idempotency_key: "POST only: the Idempotency-Key header is not 1 to 255 printable ASCII characters.";
|
|
260
254
|
readonly idempotency_key_reused: "POST only: the Idempotency-Key was used in the last 24 hours with another method, path or body.";
|
|
261
255
|
readonly idempotency_key_in_progress: "POST only: the request first sent with this Idempotency-Key has not been answered yet.";
|
|
262
|
-
}
|
|
256
|
+
}>, "org_connection_not_found"> & import("../errors.js").DeclaredErrors<{
|
|
263
257
|
readonly org_connection_not_found: "The organization connection does not exist.";
|
|
264
|
-
}
|
|
265
|
-
update: import("@orpc/contract").
|
|
258
|
+
}>>;
|
|
259
|
+
update: import("@orpc/contract").ProcedureContractBuilderWithInputOutput<z.ZodObject<{
|
|
266
260
|
connectionId: z.ZodUUID;
|
|
267
261
|
name: z.ZodOptional<z.ZodString>;
|
|
268
262
|
serviceAccountKey: z.ZodOptional<z.ZodString>;
|
|
@@ -321,7 +315,7 @@ export declare const orgConnections: {
|
|
|
321
315
|
accounts: z.ZodNumber;
|
|
322
316
|
createdAt: z.ZodPreprocess<z.ZodDate, Date>;
|
|
323
317
|
updatedAt: z.ZodPreprocess<z.ZodDate, Date>;
|
|
324
|
-
}, z.core.$strip>,
|
|
318
|
+
}, z.core.$strip>, Omit<import("../errors.js").DeclaredErrors<{
|
|
325
319
|
readonly invalid_input: "The request does not match the operation's input schema (a malformed body included); data.issues names each problem.";
|
|
326
320
|
readonly unauthenticated: "No usable credential: none was sent, or it is malformed, unknown, revoked or an expired account token.";
|
|
327
321
|
readonly api_key_expired: "The API key is past its expiry (or the grace of the rotation that replaced it).";
|
|
@@ -338,39 +332,32 @@ export declare const orgConnections: {
|
|
|
338
332
|
readonly invalid_idempotency_key: "POST only: the Idempotency-Key header is not 1 to 255 printable ASCII characters.";
|
|
339
333
|
readonly idempotency_key_reused: "POST only: the Idempotency-Key was used in the last 24 hours with another method, path or body.";
|
|
340
334
|
readonly idempotency_key_in_progress: "POST only: the request first sent with this Idempotency-Key has not been answered yet.";
|
|
341
|
-
}
|
|
335
|
+
}>, "connect_domain_inactive" | "invalid_certificate" | "invalid_service_account_key" | "org_connection_not_found" | "connect_domain_unsupported" | "directory_id_not_allowed" | "credential_mismatch"> & {
|
|
342
336
|
credential_mismatch: {
|
|
343
|
-
status: 400;
|
|
344
337
|
message: string;
|
|
345
338
|
};
|
|
346
339
|
connect_domain_inactive: {
|
|
347
|
-
status: 409;
|
|
348
340
|
message: string;
|
|
349
341
|
};
|
|
350
342
|
connect_domain_unsupported: {
|
|
351
|
-
status: 400;
|
|
352
343
|
message: string;
|
|
353
344
|
};
|
|
354
345
|
invalid_certificate: {
|
|
355
|
-
status: 400;
|
|
356
346
|
message: string;
|
|
357
347
|
};
|
|
358
348
|
invalid_service_account_key: {
|
|
359
|
-
status: 400;
|
|
360
349
|
message: string;
|
|
361
350
|
};
|
|
362
351
|
directory_id_not_allowed: {
|
|
363
|
-
status: 400;
|
|
364
352
|
message: string;
|
|
365
353
|
};
|
|
366
354
|
org_connection_not_found: {
|
|
367
|
-
status: 404;
|
|
368
355
|
message: string;
|
|
369
356
|
};
|
|
370
|
-
}
|
|
371
|
-
delete: import("@orpc/contract").
|
|
357
|
+
}>;
|
|
358
|
+
delete: import("@orpc/contract").ProcedureContractBuilderWithInputOutput<z.ZodObject<{
|
|
372
359
|
connectionId: z.ZodUUID;
|
|
373
|
-
}, z.core.$strip>, z.ZodVoid,
|
|
360
|
+
}, z.core.$strip>, z.ZodVoid, Omit<import("../errors.js").DeclaredErrors<{
|
|
374
361
|
readonly invalid_input: "The request does not match the operation's input schema (a malformed body included); data.issues names each problem.";
|
|
375
362
|
readonly unauthenticated: "No usable credential: none was sent, or it is malformed, unknown, revoked or an expired account token.";
|
|
376
363
|
readonly api_key_expired: "The API key is past its expiry (or the grace of the rotation that replaced it).";
|
|
@@ -387,23 +374,21 @@ export declare const orgConnections: {
|
|
|
387
374
|
readonly invalid_idempotency_key: "POST only: the Idempotency-Key header is not 1 to 255 printable ASCII characters.";
|
|
388
375
|
readonly idempotency_key_reused: "POST only: the Idempotency-Key was used in the last 24 hours with another method, path or body.";
|
|
389
376
|
readonly idempotency_key_in_progress: "POST only: the request first sent with this Idempotency-Key has not been answered yet.";
|
|
390
|
-
}
|
|
377
|
+
}>, "org_connection_not_found" | "connection_in_use"> & {
|
|
391
378
|
connection_in_use: {
|
|
392
|
-
status: 409;
|
|
393
379
|
message: string;
|
|
394
380
|
};
|
|
395
381
|
org_connection_not_found: {
|
|
396
|
-
status: 404;
|
|
397
382
|
message: string;
|
|
398
383
|
};
|
|
399
|
-
}
|
|
400
|
-
consent: import("@orpc/contract").
|
|
384
|
+
}>;
|
|
385
|
+
consent: import("@orpc/contract").ProcedureContractBuilderWithInputOutput<z.ZodObject<{
|
|
401
386
|
connectionId: z.ZodUUID;
|
|
402
387
|
redirectUri: z.ZodURL;
|
|
403
388
|
state: z.ZodOptional<z.ZodString>;
|
|
404
389
|
}, z.core.$strip>, z.ZodObject<{
|
|
405
390
|
consentUrl: z.ZodURL;
|
|
406
|
-
}, z.core.$strip>,
|
|
391
|
+
}, z.core.$strip>, Omit<import("../errors.js").DeclaredErrors<{
|
|
407
392
|
readonly invalid_input: "The request does not match the operation's input schema (a malformed body included); data.issues names each problem.";
|
|
408
393
|
readonly unauthenticated: "No usable credential: none was sent, or it is malformed, unknown, revoked or an expired account token.";
|
|
409
394
|
readonly api_key_expired: "The API key is past its expiry (or the grace of the rotation that replaced it).";
|
|
@@ -420,33 +405,27 @@ export declare const orgConnections: {
|
|
|
420
405
|
readonly invalid_idempotency_key: "POST only: the Idempotency-Key header is not 1 to 255 printable ASCII characters.";
|
|
421
406
|
readonly idempotency_key_reused: "POST only: the Idempotency-Key was used in the last 24 hours with another method, path or body.";
|
|
422
407
|
readonly idempotency_key_in_progress: "POST only: the request first sent with this Idempotency-Key has not been answered yet.";
|
|
423
|
-
}
|
|
408
|
+
}>, "provider_not_configured" | "connect_domain_inactive" | "org_connection_not_found" | "session_required" | "redirect_uri_not_allowed" | "not_microsoft"> & {
|
|
424
409
|
provider_not_configured: {
|
|
425
|
-
status: 400;
|
|
426
410
|
message: string;
|
|
427
411
|
};
|
|
428
412
|
connect_domain_inactive: {
|
|
429
|
-
status: 409;
|
|
430
413
|
message: string;
|
|
431
414
|
};
|
|
432
415
|
session_required: {
|
|
433
|
-
status: 403;
|
|
434
416
|
message: string;
|
|
435
417
|
};
|
|
436
418
|
redirect_uri_not_allowed: {
|
|
437
|
-
status: 400;
|
|
438
419
|
message: string;
|
|
439
420
|
};
|
|
440
421
|
not_microsoft: {
|
|
441
|
-
status: 400;
|
|
442
422
|
message: string;
|
|
443
423
|
};
|
|
444
424
|
org_connection_not_found: {
|
|
445
|
-
status: 404;
|
|
446
425
|
message: string;
|
|
447
426
|
};
|
|
448
|
-
}
|
|
449
|
-
test: import("@orpc/contract").
|
|
427
|
+
}>;
|
|
428
|
+
test: import("@orpc/contract").ProcedureContractBuilderWithInputOutput<z.ZodObject<{
|
|
450
429
|
connectionId: z.ZodUUID;
|
|
451
430
|
user: z.ZodOptional<z.ZodEmail>;
|
|
452
431
|
}, z.core.$strip>, z.ZodObject<{
|
|
@@ -503,7 +482,7 @@ export declare const orgConnections: {
|
|
|
503
482
|
isRequired: z.ZodBoolean;
|
|
504
483
|
detail: z.ZodString;
|
|
505
484
|
}, z.core.$strip>>;
|
|
506
|
-
}, z.core.$strip>,
|
|
485
|
+
}, z.core.$strip>, Omit<import("../errors.js").DeclaredErrors<{
|
|
507
486
|
readonly invalid_input: "The request does not match the operation's input schema (a malformed body included); data.issues names each problem.";
|
|
508
487
|
readonly unauthenticated: "No usable credential: none was sent, or it is malformed, unknown, revoked or an expired account token.";
|
|
509
488
|
readonly api_key_expired: "The API key is past its expiry (or the grace of the rotation that replaced it).";
|
|
@@ -520,21 +499,18 @@ export declare const orgConnections: {
|
|
|
520
499
|
readonly invalid_idempotency_key: "POST only: the Idempotency-Key header is not 1 to 255 printable ASCII characters.";
|
|
521
500
|
readonly idempotency_key_reused: "POST only: the Idempotency-Key was used in the last 24 hours with another method, path or body.";
|
|
522
501
|
readonly idempotency_key_in_progress: "POST only: the request first sent with this Idempotency-Key has not been answered yet.";
|
|
523
|
-
}
|
|
502
|
+
}>, "consent_required" | "org_connection_not_found" | "user_required"> & {
|
|
524
503
|
user_required: {
|
|
525
|
-
status: 400;
|
|
526
504
|
message: string;
|
|
527
505
|
};
|
|
528
506
|
consent_required: {
|
|
529
|
-
status: 409;
|
|
530
507
|
message: string;
|
|
531
508
|
};
|
|
532
509
|
org_connection_not_found: {
|
|
533
|
-
status: 404;
|
|
534
510
|
message: string;
|
|
535
511
|
};
|
|
536
|
-
}
|
|
537
|
-
directoryEntries: import("@orpc/contract").
|
|
512
|
+
}>;
|
|
513
|
+
directoryEntries: import("@orpc/contract").ProcedureContractBuilderWithInputOutput<z.ZodObject<{
|
|
538
514
|
connectionId: z.ZodUUID;
|
|
539
515
|
cursor: z.ZodOptional<z.ZodString>;
|
|
540
516
|
limit: z.ZodDefault<z.ZodCoercedNumber<unknown>>;
|
|
@@ -547,7 +523,7 @@ export declare const orgConnections: {
|
|
|
547
523
|
accountId: z.ZodNullable<z.ZodUUID>;
|
|
548
524
|
}, z.core.$strip>>;
|
|
549
525
|
nextCursor: z.ZodNullable<z.ZodString>;
|
|
550
|
-
}, z.core.$strip>,
|
|
526
|
+
}, z.core.$strip>, Omit<import("../errors.js").DeclaredErrors<{
|
|
551
527
|
readonly invalid_input: "The request does not match the operation's input schema (a malformed body included); data.issues names each problem.";
|
|
552
528
|
readonly unauthenticated: "No usable credential: none was sent, or it is malformed, unknown, revoked or an expired account token.";
|
|
553
529
|
readonly api_key_expired: "The API key is past its expiry (or the grace of the rotation that replaced it).";
|
|
@@ -564,41 +540,33 @@ export declare const orgConnections: {
|
|
|
564
540
|
readonly invalid_idempotency_key: "POST only: the Idempotency-Key header is not 1 to 255 printable ASCII characters.";
|
|
565
541
|
readonly idempotency_key_reused: "POST only: the Idempotency-Key was used in the last 24 hours with another method, path or body.";
|
|
566
542
|
readonly idempotency_key_in_progress: "POST only: the request first sent with this Idempotency-Key has not been answered yet.";
|
|
567
|
-
}
|
|
543
|
+
}>, "provider_unavailable" | "consent_required" | "directory_unavailable" | "org_connection_not_found" | "invalid_cursor" | "provider_not_found" | "provider_throttled" | "provider_rejected"> & {
|
|
568
544
|
directory_unavailable: {
|
|
569
|
-
status: 409;
|
|
570
545
|
message: string;
|
|
571
546
|
};
|
|
572
547
|
provider_not_found: {
|
|
573
|
-
status: 404;
|
|
574
548
|
message: string;
|
|
575
549
|
};
|
|
576
550
|
provider_rejected: {
|
|
577
|
-
status: 400;
|
|
578
551
|
message: string;
|
|
579
552
|
};
|
|
580
553
|
provider_unavailable: {
|
|
581
|
-
status: 502;
|
|
582
554
|
message: string;
|
|
583
555
|
};
|
|
584
556
|
provider_throttled: {
|
|
585
|
-
status: 429;
|
|
586
557
|
message: string;
|
|
587
558
|
};
|
|
588
559
|
invalid_cursor: {
|
|
589
|
-
status: 400;
|
|
590
560
|
message: string;
|
|
591
561
|
};
|
|
592
562
|
consent_required: {
|
|
593
|
-
status: 409;
|
|
594
563
|
message: string;
|
|
595
564
|
};
|
|
596
565
|
org_connection_not_found: {
|
|
597
|
-
status: 404;
|
|
598
566
|
message: string;
|
|
599
567
|
};
|
|
600
|
-
}
|
|
601
|
-
addAccounts: import("@orpc/contract").
|
|
568
|
+
}>;
|
|
569
|
+
addAccounts: import("@orpc/contract").ProcedureContractBuilderWithInputOutput<z.ZodObject<{
|
|
602
570
|
connectionId: z.ZodUUID;
|
|
603
571
|
mailboxes: z.ZodArray<z.ZodObject<{
|
|
604
572
|
email: z.ZodEmail;
|
|
@@ -639,7 +607,7 @@ export declare const orgConnections: {
|
|
|
639
607
|
message: z.ZodString;
|
|
640
608
|
}, z.core.$strip>>;
|
|
641
609
|
}, z.core.$strip>>;
|
|
642
|
-
}, z.core.$strip>,
|
|
610
|
+
}, z.core.$strip>, Omit<import("../errors.js").DeclaredErrors<{
|
|
643
611
|
readonly invalid_input: "The request does not match the operation's input schema (a malformed body included); data.issues names each problem.";
|
|
644
612
|
readonly unauthenticated: "No usable credential: none was sent, or it is malformed, unknown, revoked or an expired account token.";
|
|
645
613
|
readonly api_key_expired: "The API key is past its expiry (or the grace of the rotation that replaced it).";
|
|
@@ -656,26 +624,22 @@ export declare const orgConnections: {
|
|
|
656
624
|
readonly invalid_idempotency_key: "POST only: the Idempotency-Key header is not 1 to 255 printable ASCII characters.";
|
|
657
625
|
readonly idempotency_key_reused: "POST only: the Idempotency-Key was used in the last 24 hours with another method, path or body.";
|
|
658
626
|
readonly idempotency_key_in_progress: "POST only: the request first sent with this Idempotency-Key has not been answered yet.";
|
|
659
|
-
}
|
|
627
|
+
}>, "consent_required" | "org_connection_not_found" | "billing_past_due" | "plan_limit_storage" | "storage_unavailable"> & {
|
|
660
628
|
billing_past_due: {
|
|
661
|
-
status: 402;
|
|
662
629
|
message: string;
|
|
663
630
|
};
|
|
664
631
|
plan_limit_storage: import("../errors.js").DeclaredError<"plan_limit_storage">;
|
|
665
632
|
storage_unavailable: {
|
|
666
|
-
status: 400;
|
|
667
633
|
message: string;
|
|
668
634
|
};
|
|
669
635
|
consent_required: {
|
|
670
|
-
status: 409;
|
|
671
636
|
message: string;
|
|
672
637
|
};
|
|
673
638
|
org_connection_not_found: {
|
|
674
|
-
status: 404;
|
|
675
639
|
message: string;
|
|
676
640
|
};
|
|
677
|
-
}
|
|
678
|
-
addGroup: import("@orpc/contract").
|
|
641
|
+
}>;
|
|
642
|
+
addGroup: import("@orpc/contract").ProcedureContractBuilderWithInputOutput<z.ZodObject<{
|
|
679
643
|
connectionId: z.ZodUUID;
|
|
680
644
|
email: z.ZodEmail;
|
|
681
645
|
relayEmail: z.ZodEmail;
|
|
@@ -837,7 +801,7 @@ export declare const orgConnections: {
|
|
|
837
801
|
contactsInitializedAt: z.ZodNullable<z.ZodPreprocess<z.ZodDate, Date>>;
|
|
838
802
|
createdAt: z.ZodPreprocess<z.ZodDate, Date>;
|
|
839
803
|
updatedAt: z.ZodPreprocess<z.ZodDate, Date>;
|
|
840
|
-
}, z.core.$strip>,
|
|
804
|
+
}, z.core.$strip>, Omit<import("../errors.js").DeclaredErrors<{
|
|
841
805
|
readonly invalid_input: "The request does not match the operation's input schema (a malformed body included); data.issues names each problem.";
|
|
842
806
|
readonly unauthenticated: "No usable credential: none was sent, or it is malformed, unknown, revoked or an expired account token.";
|
|
843
807
|
readonly api_key_expired: "The API key is past its expiry (or the grace of the rotation that replaced it).";
|
|
@@ -854,37 +818,29 @@ export declare const orgConnections: {
|
|
|
854
818
|
readonly invalid_idempotency_key: "POST only: the Idempotency-Key header is not 1 to 255 printable ASCII characters.";
|
|
855
819
|
readonly idempotency_key_reused: "POST only: the Idempotency-Key was used in the last 24 hours with another method, path or body.";
|
|
856
820
|
readonly idempotency_key_in_progress: "POST only: the request first sent with this Idempotency-Key has not been answered yet.";
|
|
857
|
-
}
|
|
821
|
+
}>, "provider_unavailable" | "account_exists" | "org_connection_not_found" | "plan_limit_accounts" | "plan_required" | "spend_cap_reached" | "plan_module_unavailable" | "billing_past_due" | "plan_limit_storage" | "storage_unavailable" | "provider_throttled" | "scope_missing" | "group_unsupported" | "group_relay_inaccessible" | "group_alias_unverified"> & {
|
|
858
822
|
account_exists: {
|
|
859
|
-
status: 409;
|
|
860
823
|
message: string;
|
|
861
824
|
};
|
|
862
825
|
scope_missing: {
|
|
863
|
-
status: 400;
|
|
864
826
|
message: string;
|
|
865
827
|
};
|
|
866
828
|
group_unsupported: {
|
|
867
|
-
status: 400;
|
|
868
829
|
message: string;
|
|
869
830
|
};
|
|
870
831
|
group_relay_inaccessible: {
|
|
871
|
-
status: 422;
|
|
872
832
|
message: string;
|
|
873
833
|
};
|
|
874
834
|
group_alias_unverified: {
|
|
875
|
-
status: 409;
|
|
876
835
|
message: string;
|
|
877
836
|
};
|
|
878
837
|
provider_unavailable: {
|
|
879
|
-
status: 502;
|
|
880
838
|
message: string;
|
|
881
839
|
};
|
|
882
840
|
provider_throttled: {
|
|
883
|
-
status: 429;
|
|
884
841
|
message: string;
|
|
885
842
|
};
|
|
886
843
|
billing_past_due: {
|
|
887
|
-
status: 402;
|
|
888
844
|
message: string;
|
|
889
845
|
};
|
|
890
846
|
plan_limit_accounts: import("../errors.js").DeclaredError<"plan_limit_accounts">;
|
|
@@ -892,21 +848,18 @@ export declare const orgConnections: {
|
|
|
892
848
|
spend_cap_reached: import("../errors.js").DeclaredError<"spend_cap_reached">;
|
|
893
849
|
plan_limit_storage: import("../errors.js").DeclaredError<"plan_limit_storage">;
|
|
894
850
|
storage_unavailable: {
|
|
895
|
-
status: 400;
|
|
896
851
|
message: string;
|
|
897
852
|
};
|
|
898
853
|
plan_module_unavailable: {
|
|
899
|
-
status: 403;
|
|
900
854
|
message: string;
|
|
901
855
|
};
|
|
902
856
|
org_connection_not_found: {
|
|
903
|
-
status: 404;
|
|
904
857
|
message: string;
|
|
905
858
|
};
|
|
906
|
-
}
|
|
859
|
+
}>;
|
|
907
860
|
};
|
|
908
861
|
export declare const sharedMailboxes: {
|
|
909
|
-
create: import("@orpc/contract").
|
|
862
|
+
create: import("@orpc/contract").ProcedureContractBuilderWithInputOutput<z.ZodObject<{
|
|
910
863
|
accountId: z.ZodUUID;
|
|
911
864
|
email: z.ZodEmail;
|
|
912
865
|
displayName: z.ZodOptional<z.ZodString>;
|
|
@@ -1067,7 +1020,7 @@ export declare const sharedMailboxes: {
|
|
|
1067
1020
|
contactsInitializedAt: z.ZodNullable<z.ZodPreprocess<z.ZodDate, Date>>;
|
|
1068
1021
|
createdAt: z.ZodPreprocess<z.ZodDate, Date>;
|
|
1069
1022
|
updatedAt: z.ZodPreprocess<z.ZodDate, Date>;
|
|
1070
|
-
}, z.core.$strip>,
|
|
1023
|
+
}, z.core.$strip>, Omit<import("../errors.js").DeclaredErrors<{
|
|
1071
1024
|
readonly invalid_input: "The request does not match the operation's input schema (a malformed body included); data.issues names each problem.";
|
|
1072
1025
|
readonly unauthenticated: "No usable credential: none was sent, or it is malformed, unknown, revoked or an expired account token.";
|
|
1073
1026
|
readonly api_key_expired: "The API key is past its expiry (or the grace of the rotation that replaced it).";
|
|
@@ -1084,53 +1037,41 @@ export declare const sharedMailboxes: {
|
|
|
1084
1037
|
readonly invalid_idempotency_key: "POST only: the Idempotency-Key header is not 1 to 255 printable ASCII characters.";
|
|
1085
1038
|
readonly idempotency_key_reused: "POST only: the Idempotency-Key was used in the last 24 hours with another method, path or body.";
|
|
1086
1039
|
readonly idempotency_key_in_progress: "POST only: the request first sent with this Idempotency-Key has not been answered yet.";
|
|
1087
|
-
}
|
|
1040
|
+
}>, "provider_unavailable" | "account_exists" | "account_not_found" | "plan_limit_accounts" | "plan_required" | "spend_cap_reached" | "plan_module_unavailable" | "billing_past_due" | "plan_limit_storage" | "storage_unavailable" | "account_paused" | "account_disabled" | "account_reauth_required" | "account_misconfigured" | "provider_throttled" | "shared_mailbox_unsupported" | "scope_missing" | "shared_mailbox_inaccessible"> & {
|
|
1088
1041
|
account_exists: {
|
|
1089
|
-
status: 409;
|
|
1090
1042
|
message: string;
|
|
1091
1043
|
};
|
|
1092
1044
|
account_not_found: {
|
|
1093
|
-
status: 404;
|
|
1094
1045
|
message: string;
|
|
1095
1046
|
};
|
|
1096
1047
|
shared_mailbox_unsupported: {
|
|
1097
|
-
status: 400;
|
|
1098
1048
|
message: string;
|
|
1099
1049
|
};
|
|
1100
1050
|
scope_missing: {
|
|
1101
|
-
status: 400;
|
|
1102
1051
|
message: string;
|
|
1103
1052
|
};
|
|
1104
1053
|
shared_mailbox_inaccessible: {
|
|
1105
|
-
status: 422;
|
|
1106
1054
|
message: string;
|
|
1107
1055
|
};
|
|
1108
1056
|
provider_unavailable: {
|
|
1109
|
-
status: 502;
|
|
1110
1057
|
message: string;
|
|
1111
1058
|
};
|
|
1112
1059
|
provider_throttled: {
|
|
1113
|
-
status: 429;
|
|
1114
1060
|
message: string;
|
|
1115
1061
|
};
|
|
1116
1062
|
account_paused: {
|
|
1117
|
-
status: 409;
|
|
1118
1063
|
message: string;
|
|
1119
1064
|
};
|
|
1120
1065
|
account_disabled: {
|
|
1121
|
-
status: 409;
|
|
1122
1066
|
message: string;
|
|
1123
1067
|
};
|
|
1124
1068
|
account_reauth_required: {
|
|
1125
|
-
status: 409;
|
|
1126
1069
|
message: string;
|
|
1127
1070
|
};
|
|
1128
1071
|
account_misconfigured: {
|
|
1129
|
-
status: 409;
|
|
1130
1072
|
message: string;
|
|
1131
1073
|
};
|
|
1132
1074
|
billing_past_due: {
|
|
1133
|
-
status: 402;
|
|
1134
1075
|
message: string;
|
|
1135
1076
|
};
|
|
1136
1077
|
plan_limit_accounts: import("../errors.js").DeclaredError<"plan_limit_accounts">;
|
|
@@ -1138,12 +1079,10 @@ export declare const sharedMailboxes: {
|
|
|
1138
1079
|
spend_cap_reached: import("../errors.js").DeclaredError<"spend_cap_reached">;
|
|
1139
1080
|
plan_limit_storage: import("../errors.js").DeclaredError<"plan_limit_storage">;
|
|
1140
1081
|
storage_unavailable: {
|
|
1141
|
-
status: 400;
|
|
1142
1082
|
message: string;
|
|
1143
1083
|
};
|
|
1144
1084
|
plan_module_unavailable: {
|
|
1145
|
-
status: 403;
|
|
1146
1085
|
message: string;
|
|
1147
1086
|
};
|
|
1148
|
-
}
|
|
1087
|
+
}>;
|
|
1149
1088
|
};
|
package/contract/primitives.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { OpenAPIV3_2 } from "@orpc/openapi";
|
|
2
2
|
import * as z from "zod";
|
|
3
|
-
export declare const openApiComponents: Map<string, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>;
|
|
4
3
|
export declare function named<T extends z.ZodType>(name: string, schema: T): T;
|
|
4
|
+
export declare const componentMetadata: z.core.$ZodRegistry<z.core.GlobalMeta>;
|
|
5
5
|
export declare const Id: z.ZodUUID;
|
|
6
6
|
export declare const ProviderId: z.ZodString;
|
|
7
7
|
export declare const EventId: z.ZodString;
|
|
@@ -69,7 +69,7 @@ export declare const AccountIdInput: z.ZodObject<{
|
|
|
69
69
|
export type AccountIdInput = z.infer<typeof AccountIdInput>;
|
|
70
70
|
export declare const StreamedFile: z.ZodPipe<z.ZodCustom<ReadableStream<Uint8Array<ArrayBufferLike>>, ReadableStream<Uint8Array<ArrayBufferLike>>>, z.ZodTransform<File, ReadableStream<Uint8Array<ArrayBufferLike>>>>;
|
|
71
71
|
export declare function isFileOutput(schema: unknown): boolean;
|
|
72
|
-
type Operation =
|
|
72
|
+
type Operation = OpenAPIV3_2.OperationObject;
|
|
73
73
|
export declare const publicOperation: (operation: Operation) => Operation;
|
|
74
74
|
export declare function fileResponse(file: {
|
|
75
75
|
mediaType: string;
|
|
@@ -81,5 +81,8 @@ export declare function fileResponse(file: {
|
|
|
81
81
|
type: "string";
|
|
82
82
|
};
|
|
83
83
|
}>;
|
|
84
|
-
}):
|
|
84
|
+
}): {
|
|
85
|
+
spec: (operation: Operation) => Operation;
|
|
86
|
+
responseBodyHint: "file";
|
|
87
|
+
};
|
|
85
88
|
export {};
|
package/contract/reasons.d.ts
CHANGED
|
@@ -1263,7 +1263,6 @@ export declare const REASONS: {
|
|
|
1263
1263
|
};
|
|
1264
1264
|
export type Reasons = typeof REASONS;
|
|
1265
1265
|
export type ErrorReason = keyof Reasons;
|
|
1266
|
-
export type ReasonStatus<R extends ErrorReason> = Reasons[R]["status"];
|
|
1267
1266
|
export type ReasonDataSchema<R extends ErrorReason> = Reasons[R] extends {
|
|
1268
1267
|
data: infer S extends z.ZodType;
|
|
1269
1268
|
} ? S : undefined;
|