@remit/api-zod-schemas 0.0.42 → 0.0.44

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -98,18 +98,22 @@ type CognitoAuthorizer = z.infer<typeof CognitoAuthorizerSchema>;
98
98
  - `FlagPushOperationSchema` - Enum for FlagPushOperation
99
99
  - `MessageFlagPushStateSchema` - Enum for MessageFlagPushState
100
100
  - `CognitoAuthorizerSchema` - CognitoAuthorizer model
101
- - `ValidationErrorSchema` - ValidationError model
102
101
  - `ApiErrorSchema` - ApiError model
102
+ - `ValidationErrorSchema` - ValidationError model
103
+ - `RequestValidationDetailSchema` - RequestValidationDetail model
104
+ - `UnauthorizedErrorSchema` - UnauthorizedError model
105
+ - `NotFoundErrorSchema` - NotFoundError model
106
+ - `ConflictErrorSchema` - ConflictError model
107
+ - `UnprocessableEntityErrorSchema` - UnprocessableEntityError model
108
+ - `ForbiddenErrorSchema` - ForbiddenError model
109
+ - `NoContentSchema` - NoContent model
103
110
  - `FolderRoleConflictSchema` - FolderRoleConflict model
104
111
  - `AppointFolderRoleConflictSchema` - AppointFolderRoleConflict model
105
- - `NotFoundErrorSchema` - NotFoundError model
106
112
  - `PreconditionFailedErrorSchema` - PreconditionFailedError model
107
113
  - `DeleteMessagesConflictSchema` - DeleteMessagesConflict model
108
114
  - `MessagePlacementConflictSchema` - MessagePlacementConflict model
109
115
  - `AmazonApiGatewayIntegrationSchema` - AmazonApiGatewayIntegration model
110
116
  - `InternalServerErrorSchema` - InternalServerError model
111
- - `UnauthorizedErrorSchema` - UnauthorizedError model
112
- - `ForbiddenErrorSchema` - ForbiddenError model
113
117
  - `DeleteMeInputSchema` - DeleteMeInput model
114
118
  - `DeleteAccountConfigResponseSchema` - DeleteAccountConfigResponse model
115
119
  - `VipSuggestionsResponseSchema` - VipSuggestionsResponse model
@@ -202,8 +206,8 @@ type CognitoAuthorizer = z.infer<typeof CognitoAuthorizerSchema>;
202
206
  - `UpdateOutboxMessageInputSchema` - UpdateOutboxMessageInput model
203
207
  - `MintOutboxAttachmentInputSchema` - MintOutboxAttachmentInput model
204
208
  - `MintOutboxAttachmentResponseSchema` - MintOutboxAttachmentResponse model
205
- - `OutboxAttachmentRejectedSchema` - OutboxAttachmentRejected model
206
209
  - `OutboxAttachmentRejectionSchema` - OutboxAttachmentRejection model
210
+ - `OutboxAttachmentRejectedSchema` - OutboxAttachmentRejected model
207
211
  - `AddressSchema` - Address model
208
212
  - `AddressFlagsSchema` - AddressFlags model
209
213
  - `TrustedFlagSchema` - TrustedFlag model
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@remit/api-zod-schemas",
3
- "version": "0.0.42",
3
+ "version": "0.0.44",
4
4
  "type": "module",
5
5
  "main": "./schemas.js",
6
6
  "types": "./schemas.d.ts",
package/schemas.d.ts CHANGED
@@ -99,37 +99,91 @@ export declare const ApiErrorSchema: z.ZodObject<{
99
99
  message: string;
100
100
  details?: Record<string, string> | undefined;
101
101
  }>;
102
+ export declare const RequestValidationDetailSchema: z.ZodObject<{
103
+ path: z.ZodString;
104
+ rule: z.ZodString;
105
+ message: z.ZodString;
106
+ }, "strip", z.ZodTypeAny, {
107
+ path: string;
108
+ message: string;
109
+ rule: string;
110
+ }, {
111
+ path: string;
112
+ message: string;
113
+ rule: string;
114
+ }>;
102
115
  export declare const ValidationErrorSchema: z.ZodObject<{
103
116
  statusCode: z.ZodLiteral<400>;
104
- error: z.ZodObject<{
105
- code: z.ZodString;
117
+ code: z.ZodString;
118
+ message: z.ZodString;
119
+ details: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
120
+ errors: z.ZodOptional<z.ZodArray<z.ZodObject<{
121
+ path: z.ZodString;
122
+ rule: z.ZodString;
106
123
  message: z.ZodString;
107
- details: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
108
124
  }, "strip", z.ZodTypeAny, {
109
- code: string;
125
+ path: string;
110
126
  message: string;
111
- details?: Record<string, string> | undefined;
127
+ rule: string;
112
128
  }, {
113
- code: string;
129
+ path: string;
114
130
  message: string;
115
- details?: Record<string, string> | undefined;
116
- }>;
131
+ rule: string;
132
+ }>, "many">>;
117
133
  }, "strip", z.ZodTypeAny, {
118
- error: {
119
- code: string;
120
- message: string;
121
- details?: Record<string, string> | undefined;
122
- };
134
+ code: string;
135
+ message: string;
123
136
  statusCode: 400;
124
- }, {
125
- error: {
126
- code: string;
137
+ details?: Record<string, string> | undefined;
138
+ errors?: {
139
+ path: string;
127
140
  message: string;
128
- details?: Record<string, string> | undefined;
129
- };
141
+ rule: string;
142
+ }[] | undefined;
143
+ }, {
144
+ code: string;
145
+ message: string;
130
146
  statusCode: 400;
147
+ details?: Record<string, string> | undefined;
148
+ errors?: {
149
+ path: string;
150
+ message: string;
151
+ rule: string;
152
+ }[] | undefined;
131
153
  }>;
132
- export declare const FolderRoleConflictSchema: z.ZodObject<{
154
+ export declare const UnauthorizedErrorSchema: z.ZodObject<{
155
+ statusCode: z.ZodLiteral<401>;
156
+ code: z.ZodString;
157
+ message: z.ZodString;
158
+ details: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
159
+ }, "strip", z.ZodTypeAny, {
160
+ code: string;
161
+ message: string;
162
+ statusCode: 401;
163
+ details?: Record<string, string> | undefined;
164
+ }, {
165
+ code: string;
166
+ message: string;
167
+ statusCode: 401;
168
+ details?: Record<string, string> | undefined;
169
+ }>;
170
+ export declare const NotFoundErrorSchema: z.ZodObject<{
171
+ statusCode: z.ZodLiteral<404>;
172
+ code: z.ZodString;
173
+ message: z.ZodString;
174
+ details: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
175
+ }, "strip", z.ZodTypeAny, {
176
+ code: string;
177
+ message: string;
178
+ statusCode: 404;
179
+ details?: Record<string, string> | undefined;
180
+ }, {
181
+ code: string;
182
+ message: string;
183
+ statusCode: 404;
184
+ details?: Record<string, string> | undefined;
185
+ }>;
186
+ export declare const ConflictErrorSchema: z.ZodObject<{
133
187
  statusCode: z.ZodLiteral<409>;
134
188
  code: z.ZodString;
135
189
  message: z.ZodString;
@@ -145,7 +199,46 @@ export declare const FolderRoleConflictSchema: z.ZodObject<{
145
199
  statusCode: 409;
146
200
  details?: Record<string, string> | undefined;
147
201
  }>;
148
- export declare const AppointFolderRoleConflictSchema: z.ZodObject<{
202
+ export declare const UnprocessableEntityErrorSchema: z.ZodObject<{
203
+ statusCode: z.ZodLiteral<422>;
204
+ code: z.ZodString;
205
+ message: z.ZodString;
206
+ details: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
207
+ }, "strip", z.ZodTypeAny, {
208
+ code: string;
209
+ message: string;
210
+ statusCode: 422;
211
+ details?: Record<string, string> | undefined;
212
+ }, {
213
+ code: string;
214
+ message: string;
215
+ statusCode: 422;
216
+ details?: Record<string, string> | undefined;
217
+ }>;
218
+ export declare const ForbiddenErrorSchema: z.ZodObject<{
219
+ statusCode: z.ZodLiteral<403>;
220
+ code: z.ZodString;
221
+ message: z.ZodString;
222
+ details: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
223
+ }, "strip", z.ZodTypeAny, {
224
+ code: string;
225
+ message: string;
226
+ statusCode: 403;
227
+ details?: Record<string, string> | undefined;
228
+ }, {
229
+ code: string;
230
+ message: string;
231
+ statusCode: 403;
232
+ details?: Record<string, string> | undefined;
233
+ }>;
234
+ export declare const NoContentSchema: z.ZodObject<{
235
+ statusCode: z.ZodLiteral<204>;
236
+ }, "strip", z.ZodTypeAny, {
237
+ statusCode: 204;
238
+ }, {
239
+ statusCode: 204;
240
+ }>;
241
+ export declare const FolderRoleConflictSchema: z.ZodObject<{
149
242
  statusCode: z.ZodLiteral<409>;
150
243
  code: z.ZodString;
151
244
  message: z.ZodString;
@@ -161,65 +254,37 @@ export declare const AppointFolderRoleConflictSchema: z.ZodObject<{
161
254
  statusCode: 409;
162
255
  details?: Record<string, string> | undefined;
163
256
  }>;
164
- export declare const NotFoundErrorSchema: z.ZodObject<{
165
- statusCode: z.ZodLiteral<404>;
166
- error: z.ZodObject<{
167
- code: z.ZodString;
168
- message: z.ZodString;
169
- details: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
170
- }, "strip", z.ZodTypeAny, {
171
- code: string;
172
- message: string;
173
- details?: Record<string, string> | undefined;
174
- }, {
175
- code: string;
176
- message: string;
177
- details?: Record<string, string> | undefined;
178
- }>;
257
+ export declare const AppointFolderRoleConflictSchema: z.ZodObject<{
258
+ statusCode: z.ZodLiteral<409>;
259
+ code: z.ZodString;
260
+ message: z.ZodString;
261
+ details: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
179
262
  }, "strip", z.ZodTypeAny, {
180
- error: {
181
- code: string;
182
- message: string;
183
- details?: Record<string, string> | undefined;
184
- };
185
- statusCode: 404;
263
+ code: string;
264
+ message: string;
265
+ statusCode: 409;
266
+ details?: Record<string, string> | undefined;
186
267
  }, {
187
- error: {
188
- code: string;
189
- message: string;
190
- details?: Record<string, string> | undefined;
191
- };
192
- statusCode: 404;
268
+ code: string;
269
+ message: string;
270
+ statusCode: 409;
271
+ details?: Record<string, string> | undefined;
193
272
  }>;
194
273
  export declare const PreconditionFailedErrorSchema: z.ZodObject<{
195
274
  statusCode: z.ZodLiteral<412>;
196
- error: z.ZodObject<{
197
- code: z.ZodString;
198
- message: z.ZodString;
199
- details: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
200
- }, "strip", z.ZodTypeAny, {
201
- code: string;
202
- message: string;
203
- details?: Record<string, string> | undefined;
204
- }, {
205
- code: string;
206
- message: string;
207
- details?: Record<string, string> | undefined;
208
- }>;
275
+ code: z.ZodString;
276
+ message: z.ZodString;
277
+ details: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
209
278
  }, "strip", z.ZodTypeAny, {
210
- error: {
211
- code: string;
212
- message: string;
213
- details?: Record<string, string> | undefined;
214
- };
279
+ code: string;
280
+ message: string;
215
281
  statusCode: 412;
282
+ details?: Record<string, string> | undefined;
216
283
  }, {
217
- error: {
218
- code: string;
219
- message: string;
220
- details?: Record<string, string> | undefined;
221
- };
284
+ code: string;
285
+ message: string;
222
286
  statusCode: 412;
287
+ details?: Record<string, string> | undefined;
223
288
  }>;
224
289
  export declare const DeleteMessagesConflictSchema: z.ZodObject<{
225
290
  statusCode: z.ZodLiteral<409>;
@@ -281,93 +346,19 @@ export declare const AmazonApiGatewayIntegrationSchema: z.ZodObject<{
281
346
  }>;
282
347
  export declare const InternalServerErrorSchema: z.ZodObject<{
283
348
  statusCode: z.ZodLiteral<500>;
284
- error: z.ZodObject<{
285
- code: z.ZodString;
286
- message: z.ZodString;
287
- details: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
288
- }, "strip", z.ZodTypeAny, {
289
- code: string;
290
- message: string;
291
- details?: Record<string, string> | undefined;
292
- }, {
293
- code: string;
294
- message: string;
295
- details?: Record<string, string> | undefined;
296
- }>;
349
+ code: z.ZodString;
350
+ message: z.ZodString;
351
+ details: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
297
352
  }, "strip", z.ZodTypeAny, {
298
- error: {
299
- code: string;
300
- message: string;
301
- details?: Record<string, string> | undefined;
302
- };
353
+ code: string;
354
+ message: string;
303
355
  statusCode: 500;
356
+ details?: Record<string, string> | undefined;
304
357
  }, {
305
- error: {
306
- code: string;
307
- message: string;
308
- details?: Record<string, string> | undefined;
309
- };
358
+ code: string;
359
+ message: string;
310
360
  statusCode: 500;
311
- }>;
312
- export declare const UnauthorizedErrorSchema: z.ZodObject<{
313
- statusCode: z.ZodLiteral<401>;
314
- error: z.ZodObject<{
315
- code: z.ZodString;
316
- message: z.ZodString;
317
- details: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
318
- }, "strip", z.ZodTypeAny, {
319
- code: string;
320
- message: string;
321
- details?: Record<string, string> | undefined;
322
- }, {
323
- code: string;
324
- message: string;
325
- details?: Record<string, string> | undefined;
326
- }>;
327
- }, "strip", z.ZodTypeAny, {
328
- error: {
329
- code: string;
330
- message: string;
331
- details?: Record<string, string> | undefined;
332
- };
333
- statusCode: 401;
334
- }, {
335
- error: {
336
- code: string;
337
- message: string;
338
- details?: Record<string, string> | undefined;
339
- };
340
- statusCode: 401;
341
- }>;
342
- export declare const ForbiddenErrorSchema: z.ZodObject<{
343
- statusCode: z.ZodLiteral<403>;
344
- error: z.ZodObject<{
345
- code: z.ZodString;
346
- message: z.ZodString;
347
- details: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
348
- }, "strip", z.ZodTypeAny, {
349
- code: string;
350
- message: string;
351
- details?: Record<string, string> | undefined;
352
- }, {
353
- code: string;
354
- message: string;
355
- details?: Record<string, string> | undefined;
356
- }>;
357
- }, "strip", z.ZodTypeAny, {
358
- error: {
359
- code: string;
360
- message: string;
361
- details?: Record<string, string> | undefined;
362
- };
363
- statusCode: 403;
364
- }, {
365
- error: {
366
- code: string;
367
- message: string;
368
- details?: Record<string, string> | undefined;
369
- };
370
- statusCode: 403;
361
+ details?: Record<string, string> | undefined;
371
362
  }>;
372
363
  export declare const DeleteMeInputSchema: z.ZodObject<{
373
364
  confirmEmail: z.ZodString;
@@ -1658,6 +1649,11 @@ export declare const ConfigImportReportSchema: z.ZodObject<{
1658
1649
  accountsNeedingCredentials: z.ZodArray<z.ZodString, "many">;
1659
1650
  }, "strip", z.ZodTypeAny, {
1660
1651
  valid: boolean;
1652
+ errors: {
1653
+ code: string;
1654
+ message: string;
1655
+ details?: Record<string, string> | undefined;
1656
+ }[];
1661
1657
  schemaVersion: number;
1662
1658
  applied: boolean;
1663
1659
  items: {
@@ -1666,11 +1662,6 @@ export declare const ConfigImportReportSchema: z.ZodObject<{
1666
1662
  verdict: string;
1667
1663
  reason?: string | undefined;
1668
1664
  }[];
1669
- errors: {
1670
- code: string;
1671
- message: string;
1672
- details?: Record<string, string> | undefined;
1673
- }[];
1674
1665
  warnings: {
1675
1666
  code: string;
1676
1667
  message: string;
@@ -1680,6 +1671,11 @@ export declare const ConfigImportReportSchema: z.ZodObject<{
1680
1671
  importId?: string | undefined;
1681
1672
  }, {
1682
1673
  valid: boolean;
1674
+ errors: {
1675
+ code: string;
1676
+ message: string;
1677
+ details?: Record<string, string> | undefined;
1678
+ }[];
1683
1679
  schemaVersion: number;
1684
1680
  applied: boolean;
1685
1681
  items: {
@@ -1688,11 +1684,6 @@ export declare const ConfigImportReportSchema: z.ZodObject<{
1688
1684
  verdict: string;
1689
1685
  reason?: string | undefined;
1690
1686
  }[];
1691
- errors: {
1692
- code: string;
1693
- message: string;
1694
- details?: Record<string, string> | undefined;
1695
- }[];
1696
1687
  warnings: {
1697
1688
  code: string;
1698
1689
  message: string;
@@ -1901,9 +1892,9 @@ export declare const MailboxSchema: z.ZodObject<{
1901
1892
  lastMessageSyncAt: z.ZodNumber;
1902
1893
  initialSyncCompletedAt: z.ZodOptional<z.ZodNumber>;
1903
1894
  parentMailboxId: z.ZodString;
1904
- syncStatus: z.ZodOptional<z.ZodEnum<["synced", "pending", "failed", "deleting"]>>;
1895
+ syncStatus: z.ZodEnum<["synced", "pending", "failed", "deleting"]>;
1896
+ pendingPath: z.ZodOptional<z.ZodString>;
1905
1897
  cursorState: z.ZodEnum<["normal", "cursor_invalid", "rebuilding"]>;
1906
- oldPath: z.ZodOptional<z.ZodString>;
1907
1898
  specialUse: z.ZodOptional<z.ZodArray<z.ZodEnum<["All", "Archive", "Drafts", "Flagged", "Junk", "Sent", "Trash", "Important"]>, "many">>;
1908
1899
  createdAt: z.ZodNumber;
1909
1900
  updatedAt: z.ZodNumber;
@@ -1927,10 +1918,10 @@ export declare const MailboxSchema: z.ZodObject<{
1927
1918
  highWaterMarkUid: number;
1928
1919
  lastMessageSyncAt: number;
1929
1920
  parentMailboxId: string;
1921
+ syncStatus: "deleting" | "failed" | "synced" | "pending";
1930
1922
  cursorState: "normal" | "cursor_invalid" | "rebuilding";
1931
1923
  initialSyncCompletedAt?: number | undefined;
1932
- syncStatus?: "deleting" | "failed" | "synced" | "pending" | undefined;
1933
- oldPath?: string | undefined;
1924
+ pendingPath?: string | undefined;
1934
1925
  specialUse?: ("Drafts" | "Sent" | "Archive" | "Junk" | "Trash" | "All" | "Flagged" | "Important")[] | undefined;
1935
1926
  }, {
1936
1927
  createdAt: number;
@@ -1952,10 +1943,10 @@ export declare const MailboxSchema: z.ZodObject<{
1952
1943
  highWaterMarkUid: number;
1953
1944
  lastMessageSyncAt: number;
1954
1945
  parentMailboxId: string;
1946
+ syncStatus: "deleting" | "failed" | "synced" | "pending";
1955
1947
  cursorState: "normal" | "cursor_invalid" | "rebuilding";
1956
1948
  initialSyncCompletedAt?: number | undefined;
1957
- syncStatus?: "deleting" | "failed" | "synced" | "pending" | undefined;
1958
- oldPath?: string | undefined;
1949
+ pendingPath?: string | undefined;
1959
1950
  specialUse?: ("Drafts" | "Sent" | "Archive" | "Junk" | "Trash" | "All" | "Flagged" | "Important")[] | undefined;
1960
1951
  }>;
1961
1952
  export declare const MailboxResponseSchema: z.ZodObject<{
@@ -1971,7 +1962,8 @@ export declare const MailboxResponseSchema: z.ZodObject<{
1971
1962
  lastSyncUid: z.ZodNumber;
1972
1963
  highWaterMarkUid: z.ZodNumber;
1973
1964
  lastMessageSyncAt: z.ZodNumber;
1974
- syncStatus: z.ZodOptional<z.ZodEnum<["synced", "pending", "failed", "deleting"]>>;
1965
+ syncStatus: z.ZodEnum<["synced", "pending", "failed", "deleting"]>;
1966
+ pendingPath: z.ZodOptional<z.ZodString>;
1975
1967
  specialUse: z.ZodOptional<z.ZodArray<z.ZodEnum<["All", "Archive", "Drafts", "Flagged", "Junk", "Sent", "Trash", "Important"]>, "many">>;
1976
1968
  createdAt: z.ZodNumber;
1977
1969
  updatedAt: z.ZodNumber;
@@ -2010,6 +2002,7 @@ export declare const MailboxResponseSchema: z.ZodObject<{
2010
2002
  lastSyncUid: number;
2011
2003
  highWaterMarkUid: number;
2012
2004
  lastMessageSyncAt: number;
2005
+ syncStatus: "deleting" | "failed" | "synced" | "pending";
2013
2006
  muted?: {
2014
2007
  value: boolean;
2015
2008
  setAt: number;
@@ -2017,7 +2010,7 @@ export declare const MailboxResponseSchema: z.ZodObject<{
2017
2010
  setBy?: string | undefined;
2018
2011
  reason?: string | undefined;
2019
2012
  } | undefined;
2020
- syncStatus?: "deleting" | "failed" | "synced" | "pending" | undefined;
2013
+ pendingPath?: string | undefined;
2021
2014
  specialUse?: ("Drafts" | "Sent" | "Archive" | "Junk" | "Trash" | "All" | "Flagged" | "Important")[] | undefined;
2022
2015
  displayNameOverride?: string | undefined;
2023
2016
  }, {
@@ -2035,6 +2028,7 @@ export declare const MailboxResponseSchema: z.ZodObject<{
2035
2028
  lastSyncUid: number;
2036
2029
  highWaterMarkUid: number;
2037
2030
  lastMessageSyncAt: number;
2031
+ syncStatus: "deleting" | "failed" | "synced" | "pending";
2038
2032
  muted?: {
2039
2033
  value: boolean;
2040
2034
  setAt: number;
@@ -2042,7 +2036,7 @@ export declare const MailboxResponseSchema: z.ZodObject<{
2042
2036
  setBy?: string | undefined;
2043
2037
  reason?: string | undefined;
2044
2038
  } | undefined;
2045
- syncStatus?: "deleting" | "failed" | "synced" | "pending" | undefined;
2039
+ pendingPath?: string | undefined;
2046
2040
  specialUse?: ("Drafts" | "Sent" | "Archive" | "Junk" | "Trash" | "All" | "Flagged" | "Important")[] | undefined;
2047
2041
  displayNameOverride?: string | undefined;
2048
2042
  }>;
@@ -4504,16 +4498,19 @@ export declare const MintOutboxAttachmentResponseSchema: z.ZodObject<{
4504
4498
  uploadExpiresAt: number;
4505
4499
  }>;
4506
4500
  export declare const OutboxAttachmentRejectionSchema: z.ZodObject<{
4501
+ code: z.ZodString;
4507
4502
  reason: z.ZodEnum<["EmptyFile", "UnusableFilename", "FileTooLarge", "MessageTooLarge", "TooManyAttachments", "ReservationExpired", "UploadMissing", "SizeMismatch"]>;
4508
4503
  message: z.ZodString;
4509
4504
  limitBytes: z.ZodNumber;
4510
4505
  usedBytes: z.ZodNumber;
4511
4506
  }, "strip", z.ZodTypeAny, {
4507
+ code: string;
4512
4508
  message: string;
4513
4509
  reason: "EmptyFile" | "UnusableFilename" | "FileTooLarge" | "MessageTooLarge" | "TooManyAttachments" | "ReservationExpired" | "UploadMissing" | "SizeMismatch";
4514
4510
  limitBytes: number;
4515
4511
  usedBytes: number;
4516
4512
  }, {
4513
+ code: string;
4517
4514
  message: string;
4518
4515
  reason: "EmptyFile" | "UnusableFilename" | "FileTooLarge" | "MessageTooLarge" | "TooManyAttachments" | "ReservationExpired" | "UploadMissing" | "SizeMismatch";
4519
4516
  limitBytes: number;
@@ -4521,38 +4518,25 @@ export declare const OutboxAttachmentRejectionSchema: z.ZodObject<{
4521
4518
  }>;
4522
4519
  export declare const OutboxAttachmentRejectedSchema: z.ZodObject<{
4523
4520
  statusCode: z.ZodUnion<[z.ZodLiteral<400>, z.ZodLiteral<413>]>;
4524
- error: z.ZodObject<{
4525
- reason: z.ZodEnum<["EmptyFile", "UnusableFilename", "FileTooLarge", "MessageTooLarge", "TooManyAttachments", "ReservationExpired", "UploadMissing", "SizeMismatch"]>;
4526
- message: z.ZodString;
4527
- limitBytes: z.ZodNumber;
4528
- usedBytes: z.ZodNumber;
4529
- }, "strip", z.ZodTypeAny, {
4530
- message: string;
4531
- reason: "EmptyFile" | "UnusableFilename" | "FileTooLarge" | "MessageTooLarge" | "TooManyAttachments" | "ReservationExpired" | "UploadMissing" | "SizeMismatch";
4532
- limitBytes: number;
4533
- usedBytes: number;
4534
- }, {
4535
- message: string;
4536
- reason: "EmptyFile" | "UnusableFilename" | "FileTooLarge" | "MessageTooLarge" | "TooManyAttachments" | "ReservationExpired" | "UploadMissing" | "SizeMismatch";
4537
- limitBytes: number;
4538
- usedBytes: number;
4539
- }>;
4521
+ code: z.ZodString;
4522
+ reason: z.ZodEnum<["EmptyFile", "UnusableFilename", "FileTooLarge", "MessageTooLarge", "TooManyAttachments", "ReservationExpired", "UploadMissing", "SizeMismatch"]>;
4523
+ message: z.ZodString;
4524
+ limitBytes: z.ZodNumber;
4525
+ usedBytes: z.ZodNumber;
4540
4526
  }, "strip", z.ZodTypeAny, {
4541
- error: {
4542
- message: string;
4543
- reason: "EmptyFile" | "UnusableFilename" | "FileTooLarge" | "MessageTooLarge" | "TooManyAttachments" | "ReservationExpired" | "UploadMissing" | "SizeMismatch";
4544
- limitBytes: number;
4545
- usedBytes: number;
4546
- };
4527
+ code: string;
4528
+ message: string;
4547
4529
  statusCode: 400 | 413;
4530
+ reason: "EmptyFile" | "UnusableFilename" | "FileTooLarge" | "MessageTooLarge" | "TooManyAttachments" | "ReservationExpired" | "UploadMissing" | "SizeMismatch";
4531
+ limitBytes: number;
4532
+ usedBytes: number;
4548
4533
  }, {
4549
- error: {
4550
- message: string;
4551
- reason: "EmptyFile" | "UnusableFilename" | "FileTooLarge" | "MessageTooLarge" | "TooManyAttachments" | "ReservationExpired" | "UploadMissing" | "SizeMismatch";
4552
- limitBytes: number;
4553
- usedBytes: number;
4554
- };
4534
+ code: string;
4535
+ message: string;
4555
4536
  statusCode: 400 | 413;
4537
+ reason: "EmptyFile" | "UnusableFilename" | "FileTooLarge" | "MessageTooLarge" | "TooManyAttachments" | "ReservationExpired" | "UploadMissing" | "SizeMismatch";
4538
+ limitBytes: number;
4539
+ usedBytes: number;
4556
4540
  }>;
4557
4541
  export declare const TrustedFlagSchema: z.ZodObject<{
4558
4542
  setAt: z.ZodNumber;