@workwae/sdk 0.1.0-alpha.2 → 0.1.0-alpha.4

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.
@@ -135,6 +135,12 @@ export declare const AccountAuthMethod: z.ZodEnum<{
135
135
  google_group: "google_group";
136
136
  }>;
137
137
  export type AccountAuthMethod = z.infer<typeof AccountAuthMethod>;
138
+ export declare const MailPermissions: z.ZodEnum<{
139
+ full: "full";
140
+ read_send: "read_send";
141
+ read: "read";
142
+ }>;
143
+ export type MailPermissions = z.infer<typeof MailPermissions>;
138
144
  export declare const AccountAuth: z.ZodObject<{
139
145
  method: z.ZodEnum<{
140
146
  password: "password";
@@ -275,6 +281,11 @@ export declare const Account: z.ZodObject<{
275
281
  delegateAccountId: z.ZodNullable<z.ZodUUID>;
276
282
  relayEmail: z.ZodNullable<z.ZodEmail>;
277
283
  }, z.core.$strip>;
284
+ mailPermissions: z.ZodNullable<z.ZodEnum<{
285
+ full: "full";
286
+ read_send: "read_send";
287
+ read: "read";
288
+ }>>;
278
289
  initializedAt: z.ZodNullable<z.ZodPreprocess<z.ZodDate, Date>>;
279
290
  calendarInitializedAt: z.ZodNullable<z.ZodPreprocess<z.ZodDate, Date>>;
280
291
  contactsInitializedAt: z.ZodNullable<z.ZodPreprocess<z.ZodDate, Date>>;
@@ -431,6 +442,11 @@ export declare const AccountPage: z.ZodObject<{
431
442
  delegateAccountId: z.ZodNullable<z.ZodUUID>;
432
443
  relayEmail: z.ZodNullable<z.ZodEmail>;
433
444
  }, z.core.$strip>;
445
+ mailPermissions: z.ZodNullable<z.ZodEnum<{
446
+ full: "full";
447
+ read_send: "read_send";
448
+ read: "read";
449
+ }>>;
434
450
  initializedAt: z.ZodNullable<z.ZodPreprocess<z.ZodDate, Date>>;
435
451
  calendarInitializedAt: z.ZodNullable<z.ZodPreprocess<z.ZodDate, Date>>;
436
452
  contactsInitializedAt: z.ZodNullable<z.ZodPreprocess<z.ZodDate, Date>>;
@@ -490,6 +506,11 @@ export declare const CreateAccount: z.ZodObject<{
490
506
  sendsPerMinute: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
491
507
  }, z.core.$strip>>;
492
508
  sharedMailboxesEnabled: z.ZodOptional<z.ZodBoolean>;
509
+ mailPermissions: z.ZodOptional<z.ZodEnum<{
510
+ full: "full";
511
+ read_send: "read_send";
512
+ read: "read";
513
+ }>>;
493
514
  }, z.core.$strip>;
494
515
  export type CreateAccount = z.infer<typeof CreateAccount>;
495
516
  export declare const UpdateAccount: z.ZodObject<{
@@ -158,6 +158,11 @@ export declare const accounts: {
158
158
  delegateAccountId: z.ZodNullable<z.ZodUUID>;
159
159
  relayEmail: z.ZodNullable<z.ZodEmail>;
160
160
  }, z.core.$strip>;
161
+ mailPermissions: z.ZodNullable<z.ZodEnum<{
162
+ full: "full";
163
+ read_send: "read_send";
164
+ read: "read";
165
+ }>>;
161
166
  initializedAt: z.ZodNullable<z.ZodPreprocess<z.ZodDate, Date>>;
162
167
  calendarInitializedAt: z.ZodNullable<z.ZodPreprocess<z.ZodDate, Date>>;
163
168
  contactsInitializedAt: z.ZodNullable<z.ZodPreprocess<z.ZodDate, Date>>;
@@ -313,6 +318,11 @@ export declare const accounts: {
313
318
  delegateAccountId: z.ZodNullable<z.ZodUUID>;
314
319
  relayEmail: z.ZodNullable<z.ZodEmail>;
315
320
  }, z.core.$strip>;
321
+ mailPermissions: z.ZodNullable<z.ZodEnum<{
322
+ full: "full";
323
+ read_send: "read_send";
324
+ read: "read";
325
+ }>>;
316
326
  initializedAt: z.ZodNullable<z.ZodPreprocess<z.ZodDate, Date>>;
317
327
  calendarInitializedAt: z.ZodNullable<z.ZodPreprocess<z.ZodDate, Date>>;
318
328
  contactsInitializedAt: z.ZodNullable<z.ZodPreprocess<z.ZodDate, Date>>;
@@ -373,6 +383,11 @@ export declare const accounts: {
373
383
  sendsPerMinute: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
374
384
  }, z.core.$strip>>;
375
385
  sharedMailboxesEnabled: z.ZodOptional<z.ZodBoolean>;
386
+ mailPermissions: z.ZodOptional<z.ZodEnum<{
387
+ full: "full";
388
+ read_send: "read_send";
389
+ read: "read";
390
+ }>>;
376
391
  }, z.core.$strip>, z.ZodObject<{
377
392
  id: z.ZodUUID;
378
393
  externalRef: z.ZodNullable<z.ZodString>;
@@ -499,6 +514,11 @@ export declare const accounts: {
499
514
  delegateAccountId: z.ZodNullable<z.ZodUUID>;
500
515
  relayEmail: z.ZodNullable<z.ZodEmail>;
501
516
  }, z.core.$strip>;
517
+ mailPermissions: z.ZodNullable<z.ZodEnum<{
518
+ full: "full";
519
+ read_send: "read_send";
520
+ read: "read";
521
+ }>>;
502
522
  initializedAt: z.ZodNullable<z.ZodPreprocess<z.ZodDate, Date>>;
503
523
  calendarInitializedAt: z.ZodNullable<z.ZodPreprocess<z.ZodDate, Date>>;
504
524
  contactsInitializedAt: z.ZodNullable<z.ZodPreprocess<z.ZodDate, Date>>;
@@ -558,6 +578,10 @@ export declare const accounts: {
558
578
  status: 400;
559
579
  message: string;
560
580
  };
581
+ mail_permissions_unsupported: {
582
+ status: 400;
583
+ message: string;
584
+ };
561
585
  provider_not_configured: {
562
586
  status: 400;
563
587
  message: string;
@@ -744,6 +768,11 @@ export declare const accounts: {
744
768
  delegateAccountId: z.ZodNullable<z.ZodUUID>;
745
769
  relayEmail: z.ZodNullable<z.ZodEmail>;
746
770
  }, z.core.$strip>;
771
+ mailPermissions: z.ZodNullable<z.ZodEnum<{
772
+ full: "full";
773
+ read_send: "read_send";
774
+ read: "read";
775
+ }>>;
747
776
  initializedAt: z.ZodNullable<z.ZodPreprocess<z.ZodDate, Date>>;
748
777
  calendarInitializedAt: z.ZodNullable<z.ZodPreprocess<z.ZodDate, Date>>;
749
778
  contactsInitializedAt: z.ZodNullable<z.ZodPreprocess<z.ZodDate, Date>>;
@@ -1073,6 +1102,11 @@ export declare const imapAccounts: {
1073
1102
  delegateAccountId: z.ZodNullable<z.ZodUUID>;
1074
1103
  relayEmail: z.ZodNullable<z.ZodEmail>;
1075
1104
  }, z.core.$strip>;
1105
+ mailPermissions: z.ZodNullable<z.ZodEnum<{
1106
+ full: "full";
1107
+ read_send: "read_send";
1108
+ read: "read";
1109
+ }>>;
1076
1110
  initializedAt: z.ZodNullable<z.ZodPreprocess<z.ZodDate, Date>>;
1077
1111
  calendarInitializedAt: z.ZodNullable<z.ZodPreprocess<z.ZodDate, Date>>;
1078
1112
  contactsInitializedAt: z.ZodNullable<z.ZodPreprocess<z.ZodDate, Date>>;
@@ -1304,6 +1338,11 @@ export declare const imapSettings: {
1304
1338
  delegateAccountId: z.ZodNullable<z.ZodUUID>;
1305
1339
  relayEmail: z.ZodNullable<z.ZodEmail>;
1306
1340
  }, z.core.$strip>;
1341
+ mailPermissions: z.ZodNullable<z.ZodEnum<{
1342
+ full: "full";
1343
+ read_send: "read_send";
1344
+ read: "read";
1345
+ }>>;
1307
1346
  initializedAt: z.ZodNullable<z.ZodPreprocess<z.ZodDate, Date>>;
1308
1347
  calendarInitializedAt: z.ZodNullable<z.ZodPreprocess<z.ZodDate, Date>>;
1309
1348
  contactsInitializedAt: z.ZodNullable<z.ZodPreprocess<z.ZodDate, Date>>;
@@ -21,6 +21,7 @@ export declare const AuditActor: z.ZodObject<{
21
21
  export type AuditActor = z.infer<typeof AuditActor>;
22
22
  export declare const AuditSurface: z.ZodEnum<{
23
23
  auth: "auth";
24
+ smtp: "smtp";
24
25
  v1: "v1";
25
26
  rpc: "rpc";
26
27
  mcp: "mcp";
@@ -48,6 +49,7 @@ export declare const AuditEntry: z.ZodObject<{
48
49
  action: z.ZodString;
49
50
  surface: z.ZodEnum<{
50
51
  auth: "auth";
52
+ smtp: "smtp";
51
53
  v1: "v1";
52
54
  rpc: "rpc";
53
55
  mcp: "mcp";
@@ -81,6 +83,7 @@ export declare const AuditEntryPage: z.ZodObject<{
81
83
  action: z.ZodString;
82
84
  surface: z.ZodEnum<{
83
85
  auth: "auth";
86
+ smtp: "smtp";
84
87
  v1: "v1";
85
88
  rpc: "rpc";
86
89
  mcp: "mcp";
@@ -36,6 +36,7 @@ export declare const auditLog: {
36
36
  action: import("zod").ZodString;
37
37
  surface: import("zod").ZodEnum<{
38
38
  auth: "auth";
39
+ smtp: "smtp";
39
40
  v1: "v1";
40
41
  rpc: "rpc";
41
42
  mcp: "mcp";
@@ -18,6 +18,11 @@ export declare const ConnectOptions: z.ZodObject<{
18
18
  api: "api";
19
19
  }>>;
20
20
  sharedMailboxesEnabled: z.ZodOptional<z.ZodBoolean>;
21
+ mailPermissions: z.ZodOptional<z.ZodEnum<{
22
+ full: "full";
23
+ read_send: "read_send";
24
+ read: "read";
25
+ }>>;
21
26
  }, z.core.$strip>;
22
27
  export type ConnectOptions = z.infer<typeof ConnectOptions>;
23
28
  export declare const ConnectProvider: z.ZodEnum<{
@@ -63,6 +68,7 @@ export declare const ConnectErrorCode: z.ZodEnum<{
63
68
  unknown_meeting_app: "unknown_meeting_app";
64
69
  meeting_app_mismatch: "meeting_app_mismatch";
65
70
  meeting_app_secret_unreadable: "meeting_app_secret_unreadable";
71
+ connect_domain_inactive: "connect_domain_inactive";
66
72
  consent_failed: "consent_failed";
67
73
  consent_required: "consent_required";
68
74
  consent_revoked: "consent_revoked";
@@ -149,6 +155,7 @@ export declare const ConnectSession: z.ZodObject<{
149
155
  unknown_meeting_app: "unknown_meeting_app";
150
156
  meeting_app_mismatch: "meeting_app_mismatch";
151
157
  meeting_app_secret_unreadable: "meeting_app_secret_unreadable";
158
+ connect_domain_inactive: "connect_domain_inactive";
152
159
  consent_failed: "consent_failed";
153
160
  consent_required: "consent_required";
154
161
  consent_revoked: "consent_revoked";
@@ -215,6 +222,11 @@ export declare const CreateConnectSession: z.ZodObject<{
215
222
  api: "api";
216
223
  }>>;
217
224
  sharedMailboxesEnabled: z.ZodOptional<z.ZodBoolean>;
225
+ mailPermissions: z.ZodOptional<z.ZodEnum<{
226
+ full: "full";
227
+ read_send: "read_send";
228
+ read: "read";
229
+ }>>;
218
230
  }, z.core.$strip>>;
219
231
  mcp: z.ZodOptional<z.ZodObject<{
220
232
  scopes: z.ZodArray<z.ZodEnum<{
@@ -267,6 +279,11 @@ export declare const StartOAuthRequest: z.ZodObject<{
267
279
  api: "api";
268
280
  }>>;
269
281
  sharedMailboxesEnabled: z.ZodOptional<z.ZodBoolean>;
282
+ mailPermissions: z.ZodOptional<z.ZodEnum<{
283
+ full: "full";
284
+ read_send: "read_send";
285
+ read: "read";
286
+ }>>;
270
287
  }, z.core.$strip>>;
271
288
  }, z.core.$strip>;
272
289
  export type StartOAuthRequest = z.infer<typeof StartOAuthRequest>;
@@ -34,6 +34,11 @@ export declare const connectSessions: {
34
34
  api: "api";
35
35
  }>>;
36
36
  sharedMailboxesEnabled: import("zod").ZodOptional<import("zod").ZodBoolean>;
37
+ mailPermissions: import("zod").ZodOptional<import("zod").ZodEnum<{
38
+ full: "full";
39
+ read_send: "read_send";
40
+ read: "read";
41
+ }>>;
37
42
  }, import("zod/v4/core").$strip>>;
38
43
  mcp: import("zod").ZodOptional<import("zod").ZodObject<{
39
44
  scopes: import("zod").ZodArray<import("zod").ZodEnum<{
@@ -99,6 +104,10 @@ export declare const connectSessions: {
99
104
  status: 402;
100
105
  message: string;
101
106
  };
107
+ mail_permissions_unsupported: {
108
+ status: 400;
109
+ message: string;
110
+ };
102
111
  unknown_account: import("../errors.js").DeclaredError<"unknown_account">;
103
112
  redirect_uri_not_allowed: {
104
113
  status: 400;
@@ -153,6 +162,7 @@ export declare const connectSessions: {
153
162
  unknown_meeting_app: "unknown_meeting_app";
154
163
  meeting_app_mismatch: "meeting_app_mismatch";
155
164
  meeting_app_secret_unreadable: "meeting_app_secret_unreadable";
165
+ connect_domain_inactive: "connect_domain_inactive";
156
166
  consent_failed: "consent_failed";
157
167
  consent_required: "consent_required";
158
168
  consent_revoked: "consent_revoked";
@@ -232,6 +242,11 @@ export declare const oauthAuthorizations: {
232
242
  api: "api";
233
243
  }>>;
234
244
  sharedMailboxesEnabled: import("zod").ZodOptional<import("zod").ZodBoolean>;
245
+ mailPermissions: import("zod").ZodOptional<import("zod").ZodEnum<{
246
+ full: "full";
247
+ read_send: "read_send";
248
+ read: "read";
249
+ }>>;
235
250
  }, import("zod/v4/core").$strip>>;
236
251
  }, import("zod/v4/core").$strip>, import("zod").ZodObject<{
237
252
  authorizeUrl: import("zod").ZodURL;
@@ -261,6 +276,10 @@ export declare const oauthAuthorizations: {
261
276
  status: 400;
262
277
  message: string;
263
278
  };
279
+ connect_domain_inactive: {
280
+ status: 409;
281
+ message: string;
282
+ };
264
283
  connect_grants_nothing: {
265
284
  status: 400;
266
285
  message: string;
@@ -294,6 +313,10 @@ export declare const oauthAuthorizations: {
294
313
  status: 402;
295
314
  message: string;
296
315
  };
316
+ mail_permissions_unsupported: {
317
+ status: 400;
318
+ message: string;
319
+ };
297
320
  unknown_account: import("../errors.js").DeclaredError<"unknown_account">;
298
321
  redirect_uri_not_allowed: {
299
322
  status: 400;
@@ -0,0 +1,41 @@
1
+ import * as z from "zod";
2
+ export declare const ConnectDomainHostname: z.ZodString;
3
+ export type ConnectDomainHostname = z.infer<typeof ConnectDomainHostname>;
4
+ export declare const ConnectDomainStatus: z.ZodEnum<{
5
+ active: "active";
6
+ pending: "pending";
7
+ failed: "failed";
8
+ }>;
9
+ export type ConnectDomainStatus = z.infer<typeof ConnectDomainStatus>;
10
+ export declare const ConnectDomainRecord: z.ZodObject<{
11
+ type: z.ZodString;
12
+ name: z.ZodString;
13
+ value: z.ZodString;
14
+ }, z.core.$strip>;
15
+ export type ConnectDomainRecord = z.infer<typeof ConnectDomainRecord>;
16
+ export declare const ConnectDomain: z.ZodObject<{
17
+ hostname: z.ZodString;
18
+ status: z.ZodEnum<{
19
+ active: "active";
20
+ pending: "pending";
21
+ failed: "failed";
22
+ }>;
23
+ records: z.ZodArray<z.ZodObject<{
24
+ type: z.ZodString;
25
+ name: z.ZodString;
26
+ value: z.ZodString;
27
+ }, z.core.$strip>>;
28
+ ownership: z.ZodObject<{
29
+ type: z.ZodString;
30
+ name: z.ZodString;
31
+ value: z.ZodString;
32
+ }, z.core.$strip>;
33
+ error: z.ZodNullable<z.ZodString>;
34
+ activatedAt: z.ZodNullable<z.ZodPreprocess<z.ZodDate, Date>>;
35
+ createdAt: z.ZodPreprocess<z.ZodDate, Date>;
36
+ }, z.core.$strip>;
37
+ export type ConnectDomain = z.infer<typeof ConnectDomain>;
38
+ export declare const SetConnectDomain: z.ZodObject<{
39
+ hostname: z.ZodString;
40
+ }, z.core.$strip>;
41
+ export type SetConnectDomain = z.infer<typeof SetConnectDomain>;
@@ -0,0 +1,197 @@
1
+ import * as z from "zod";
2
+ export declare const connectDomain: {
3
+ get: import("@orpc/contract").ContractProcedureBuilderWithOutput<import("@orpc/contract").Schema<unknown, unknown>, z.ZodObject<{
4
+ hostname: z.ZodString;
5
+ status: z.ZodEnum<{
6
+ active: "active";
7
+ pending: "pending";
8
+ failed: "failed";
9
+ }>;
10
+ records: z.ZodArray<z.ZodObject<{
11
+ type: z.ZodString;
12
+ name: z.ZodString;
13
+ value: z.ZodString;
14
+ }, z.core.$strip>>;
15
+ ownership: z.ZodObject<{
16
+ type: z.ZodString;
17
+ name: z.ZodString;
18
+ value: z.ZodString;
19
+ }, z.core.$strip>;
20
+ error: z.ZodNullable<z.ZodString>;
21
+ activatedAt: z.ZodNullable<z.ZodPreprocess<z.ZodDate, Date>>;
22
+ createdAt: z.ZodPreprocess<z.ZodDate, Date>;
23
+ }, z.core.$strip>, import("@orpc/contract").MergedErrorMap<import("@orpc/contract").MergedErrorMap<Record<never, never>, import("../errors.js").DeclaredErrors<{
24
+ readonly invalid_input: "The request does not match the operation's input schema (a malformed body included); data.issues names each problem.";
25
+ readonly unauthenticated: "No usable credential: none was sent, or it is malformed, unknown, revoked or an expired account token.";
26
+ readonly api_key_expired: "The API key is past its expiry (or the grace of the rotation that replaced it).";
27
+ readonly missing_scope: "The API key lacks the scope the operation needs.";
28
+ readonly role_forbidden: "The member's role does not allow the operation.";
29
+ readonly account_token_forbidden: "An account token called an operation account tokens cannot call.";
30
+ readonly account_scope_forbidden: "A credential limited to specific accounts called an operation that reaches beyond them.";
31
+ readonly mcp_only_key: "An MCP-only key (minted for an end user's MCP client) was used outside the MCP server.";
32
+ readonly rate_limited: "The tenant used up its plan's request rate; Retry-After says when the window ends.";
33
+ readonly too_many_requests: "The credential has too many requests in flight at once; retry after Retry-After.";
34
+ readonly overloaded: "The API is shedding load; retry after Retry-After.";
35
+ readonly payload_too_large: "The request body is larger than the API accepts.";
36
+ readonly internal_error: "An unexpected failure on our side.";
37
+ readonly invalid_idempotency_key: "POST only: the Idempotency-Key header is not 1 to 255 printable ASCII characters.";
38
+ readonly idempotency_key_reused: "POST only: the Idempotency-Key was used in the last 24 hours with another method, path or body.";
39
+ readonly idempotency_key_in_progress: "POST only: the request first sent with this Idempotency-Key has not been answered yet.";
40
+ }>>, {
41
+ connect_domain_not_found: {
42
+ status: 404;
43
+ message: string;
44
+ };
45
+ connect_domain_unavailable: {
46
+ status: 400;
47
+ message: string;
48
+ };
49
+ }>, Record<never, never>>;
50
+ set: import("@orpc/contract").ContractProcedureBuilderWithInputOutput<z.ZodObject<{
51
+ hostname: z.ZodString;
52
+ }, z.core.$strip>, z.ZodObject<{
53
+ hostname: z.ZodString;
54
+ status: z.ZodEnum<{
55
+ active: "active";
56
+ pending: "pending";
57
+ failed: "failed";
58
+ }>;
59
+ records: z.ZodArray<z.ZodObject<{
60
+ type: z.ZodString;
61
+ name: z.ZodString;
62
+ value: z.ZodString;
63
+ }, z.core.$strip>>;
64
+ ownership: z.ZodObject<{
65
+ type: z.ZodString;
66
+ name: z.ZodString;
67
+ value: z.ZodString;
68
+ }, z.core.$strip>;
69
+ error: z.ZodNullable<z.ZodString>;
70
+ activatedAt: z.ZodNullable<z.ZodPreprocess<z.ZodDate, Date>>;
71
+ createdAt: z.ZodPreprocess<z.ZodDate, Date>;
72
+ }, z.core.$strip>, import("@orpc/contract").MergedErrorMap<import("@orpc/contract").MergedErrorMap<Record<never, never>, import("../errors.js").DeclaredErrors<{
73
+ readonly invalid_input: "The request does not match the operation's input schema (a malformed body included); data.issues names each problem.";
74
+ readonly unauthenticated: "No usable credential: none was sent, or it is malformed, unknown, revoked or an expired account token.";
75
+ readonly api_key_expired: "The API key is past its expiry (or the grace of the rotation that replaced it).";
76
+ readonly missing_scope: "The API key lacks the scope the operation needs.";
77
+ readonly role_forbidden: "The member's role does not allow the operation.";
78
+ readonly account_token_forbidden: "An account token called an operation account tokens cannot call.";
79
+ readonly account_scope_forbidden: "A credential limited to specific accounts called an operation that reaches beyond them.";
80
+ readonly mcp_only_key: "An MCP-only key (minted for an end user's MCP client) was used outside the MCP server.";
81
+ readonly rate_limited: "The tenant used up its plan's request rate; Retry-After says when the window ends.";
82
+ readonly too_many_requests: "The credential has too many requests in flight at once; retry after Retry-After.";
83
+ readonly overloaded: "The API is shedding load; retry after Retry-After.";
84
+ readonly payload_too_large: "The request body is larger than the API accepts.";
85
+ readonly internal_error: "An unexpected failure on our side.";
86
+ readonly invalid_idempotency_key: "POST only: the Idempotency-Key header is not 1 to 255 printable ASCII characters.";
87
+ readonly idempotency_key_reused: "POST only: the Idempotency-Key was used in the last 24 hours with another method, path or body.";
88
+ readonly idempotency_key_in_progress: "POST only: the request first sent with this Idempotency-Key has not been answered yet.";
89
+ }>>, {
90
+ connect_domain_not_allowed: {
91
+ status: 400;
92
+ message: string;
93
+ };
94
+ connect_domain_taken: {
95
+ status: 409;
96
+ message: string;
97
+ };
98
+ connect_domain_in_use: {
99
+ status: 409;
100
+ message: string;
101
+ };
102
+ connect_domain_edge_unavailable: {
103
+ status: 502;
104
+ message: string;
105
+ };
106
+ connect_domain_unavailable: {
107
+ status: 400;
108
+ message: string;
109
+ };
110
+ }>, Record<never, never>>;
111
+ delete: import("@orpc/contract").ContractProcedureBuilderWithOutput<import("@orpc/contract").Schema<unknown, unknown>, z.ZodVoid, import("@orpc/contract").MergedErrorMap<import("@orpc/contract").MergedErrorMap<Record<never, never>, import("../errors.js").DeclaredErrors<{
112
+ readonly invalid_input: "The request does not match the operation's input schema (a malformed body included); data.issues names each problem.";
113
+ readonly unauthenticated: "No usable credential: none was sent, or it is malformed, unknown, revoked or an expired account token.";
114
+ readonly api_key_expired: "The API key is past its expiry (or the grace of the rotation that replaced it).";
115
+ readonly missing_scope: "The API key lacks the scope the operation needs.";
116
+ readonly role_forbidden: "The member's role does not allow the operation.";
117
+ readonly account_token_forbidden: "An account token called an operation account tokens cannot call.";
118
+ readonly account_scope_forbidden: "A credential limited to specific accounts called an operation that reaches beyond them.";
119
+ readonly mcp_only_key: "An MCP-only key (minted for an end user's MCP client) was used outside the MCP server.";
120
+ readonly rate_limited: "The tenant used up its plan's request rate; Retry-After says when the window ends.";
121
+ readonly too_many_requests: "The credential has too many requests in flight at once; retry after Retry-After.";
122
+ readonly overloaded: "The API is shedding load; retry after Retry-After.";
123
+ readonly payload_too_large: "The request body is larger than the API accepts.";
124
+ readonly internal_error: "An unexpected failure on our side.";
125
+ readonly invalid_idempotency_key: "POST only: the Idempotency-Key header is not 1 to 255 printable ASCII characters.";
126
+ readonly idempotency_key_reused: "POST only: the Idempotency-Key was used in the last 24 hours with another method, path or body.";
127
+ readonly idempotency_key_in_progress: "POST only: the request first sent with this Idempotency-Key has not been answered yet.";
128
+ }>>, {
129
+ connect_domain_in_use: {
130
+ status: 409;
131
+ message: string;
132
+ };
133
+ connect_domain_edge_unavailable: {
134
+ status: 502;
135
+ message: string;
136
+ };
137
+ connect_domain_not_found: {
138
+ status: 404;
139
+ message: string;
140
+ };
141
+ connect_domain_unavailable: {
142
+ status: 400;
143
+ message: string;
144
+ };
145
+ }>, Record<never, never>>;
146
+ refresh: import("@orpc/contract").ContractProcedureBuilderWithOutput<import("@orpc/contract").Schema<unknown, unknown>, z.ZodObject<{
147
+ hostname: z.ZodString;
148
+ status: z.ZodEnum<{
149
+ active: "active";
150
+ pending: "pending";
151
+ failed: "failed";
152
+ }>;
153
+ records: z.ZodArray<z.ZodObject<{
154
+ type: z.ZodString;
155
+ name: z.ZodString;
156
+ value: z.ZodString;
157
+ }, z.core.$strip>>;
158
+ ownership: z.ZodObject<{
159
+ type: z.ZodString;
160
+ name: z.ZodString;
161
+ value: z.ZodString;
162
+ }, z.core.$strip>;
163
+ error: z.ZodNullable<z.ZodString>;
164
+ activatedAt: z.ZodNullable<z.ZodPreprocess<z.ZodDate, Date>>;
165
+ createdAt: z.ZodPreprocess<z.ZodDate, Date>;
166
+ }, z.core.$strip>, import("@orpc/contract").MergedErrorMap<import("@orpc/contract").MergedErrorMap<Record<never, never>, import("../errors.js").DeclaredErrors<{
167
+ readonly invalid_input: "The request does not match the operation's input schema (a malformed body included); data.issues names each problem.";
168
+ readonly unauthenticated: "No usable credential: none was sent, or it is malformed, unknown, revoked or an expired account token.";
169
+ readonly api_key_expired: "The API key is past its expiry (or the grace of the rotation that replaced it).";
170
+ readonly missing_scope: "The API key lacks the scope the operation needs.";
171
+ readonly role_forbidden: "The member's role does not allow the operation.";
172
+ readonly account_token_forbidden: "An account token called an operation account tokens cannot call.";
173
+ readonly account_scope_forbidden: "A credential limited to specific accounts called an operation that reaches beyond them.";
174
+ readonly mcp_only_key: "An MCP-only key (minted for an end user's MCP client) was used outside the MCP server.";
175
+ readonly rate_limited: "The tenant used up its plan's request rate; Retry-After says when the window ends.";
176
+ readonly too_many_requests: "The credential has too many requests in flight at once; retry after Retry-After.";
177
+ readonly overloaded: "The API is shedding load; retry after Retry-After.";
178
+ readonly payload_too_large: "The request body is larger than the API accepts.";
179
+ readonly internal_error: "An unexpected failure on our side.";
180
+ readonly invalid_idempotency_key: "POST only: the Idempotency-Key header is not 1 to 255 printable ASCII characters.";
181
+ readonly idempotency_key_reused: "POST only: the Idempotency-Key was used in the last 24 hours with another method, path or body.";
182
+ readonly idempotency_key_in_progress: "POST only: the request first sent with this Idempotency-Key has not been answered yet.";
183
+ }>>, {
184
+ connect_domain_edge_unavailable: {
185
+ status: 502;
186
+ message: string;
187
+ };
188
+ connect_domain_not_found: {
189
+ status: 404;
190
+ message: string;
191
+ };
192
+ connect_domain_unavailable: {
193
+ status: 400;
194
+ message: string;
195
+ };
196
+ }>, Record<never, never>>;
197
+ };
@@ -0,0 +1,12 @@
1
+ import * as z from "zod";
2
+ export declare const customDomainHostname: (example: string) => z.ZodString;
3
+ export declare const CUSTOM_DOMAIN_STATUSES: readonly [
4
+ "pending",
5
+ "active",
6
+ "failed"
7
+ ];
8
+ export declare const customDomainRecord: () => z.ZodObject<{
9
+ type: z.ZodString;
10
+ name: z.ZodString;
11
+ value: z.ZodString;
12
+ }, z.core.$strip>;
@@ -81,6 +81,12 @@ export declare const MAIL_ACCOUNT: {
81
81
  message: string;
82
82
  };
83
83
  };
84
+ export declare const MAIL_CHANGE: DeclaredErrors<{
85
+ readonly mail_permission_missing: "The account's grant cannot change the mailbox (mailPermissions read_send or read); reconnect it with options.mailPermissions full.";
86
+ }>;
87
+ export declare const MAIL_SEND: DeclaredErrors<{
88
+ readonly mail_permission_missing: "The account's grant cannot send (mailPermissions read); reconnect it with options.mailPermissions read_send or full.";
89
+ }>;
84
90
  export declare function accountState(account?: string): DeclaredErrors<{
85
91
  readonly account_paused: `${string} is paused.`;
86
92
  readonly account_disabled: `${string} is disabled.`;
@@ -35,12 +35,18 @@ export declare const MAX_FILENAME_LENGTH = 255;
35
35
  export declare const MAX_CONTENT_TYPE_LENGTH = 255;
36
36
  export declare const MAX_CONTENT_ID_LENGTH = 255;
37
37
  export declare const MAX_SEND_REFERENCE_LENGTH = 255;
38
+ export declare const MAX_SEND_WAIT_SECONDS = 30;
39
+ export declare const MAX_SEND_HEADERS = 50;
40
+ export declare const MAX_HEADER_VALUE_LENGTH = 4096;
41
+ export declare const MAX_CALENDAR_LENGTH: number;
38
42
  export declare const MAX_MAILBOX_CHANGES = 50;
39
43
  export declare const MAX_SEARCH_QUERY_LENGTH = 500;
40
44
  export declare const MAX_SEARCH_PAGE_SIZE = 100;
41
45
  export declare const DEFAULT_SEARCH_PAGE_SIZE = 25;
42
46
  export declare const MAX_THREAD_PAGE_SIZE = 100;
43
47
  export declare const DEFAULT_THREAD_PAGE_SIZE = 25;
48
+ export declare const MAX_MESSAGE_BODIES_PAGE_SIZE = 25;
49
+ export declare const MAX_REFERENCES = 100;
44
50
  export declare const MAX_SIGNATURE_HTML_LENGTH = 100000;
45
51
  export declare const MAX_SIGNATURE_TEXT_LENGTH = 20000;
46
52
  export declare const MAX_TEMPLATE_NAME_LENGTH = 255;