@sudobility/mail_box_types 1.0.1
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/dist/index.cjs +27 -0
- package/dist/index.d.ts +10 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +27 -0
- package/dist/index.js.map +1 -0
- package/dist/types/common/index.cjs +15 -0
- package/dist/types/common/index.d.ts +37 -0
- package/dist/types/common/index.d.ts.map +1 -0
- package/dist/types/common/index.js +15 -0
- package/dist/types/common/index.js.map +1 -0
- package/dist/types/index.cjs +25 -0
- package/dist/types/index.d.ts +5 -0
- package/dist/types/index.d.ts.map +1 -0
- package/dist/types/index.js +25 -0
- package/dist/types/index.js.map +1 -0
- package/dist/types/indexer/index.cjs +31 -0
- package/dist/types/indexer/index.d.ts +3 -0
- package/dist/types/indexer/index.d.ts.map +1 -0
- package/dist/types/indexer/index.js +31 -0
- package/dist/types/indexer/index.js.map +1 -0
- package/dist/types/indexer/indexer-guards.cjs +303 -0
- package/dist/types/indexer/indexer-guards.d.ts +37 -0
- package/dist/types/indexer/indexer-guards.d.ts.map +1 -0
- package/dist/types/indexer/indexer-guards.js +303 -0
- package/dist/types/indexer/indexer-guards.js.map +1 -0
- package/dist/types/indexer/indexer-responses.cjs +7 -0
- package/dist/types/indexer/indexer-responses.d.ts +213 -0
- package/dist/types/indexer/indexer-responses.d.ts.map +1 -0
- package/dist/types/indexer/indexer-responses.js +7 -0
- package/dist/types/indexer/indexer-responses.js.map +1 -0
- package/dist/types/kyc/index.cjs +19 -0
- package/dist/types/kyc/index.d.ts +2 -0
- package/dist/types/kyc/index.d.ts.map +1 -0
- package/dist/types/kyc/index.js +19 -0
- package/dist/types/kyc/index.js.map +1 -0
- package/dist/types/kyc/kyc-types.cjs +85 -0
- package/dist/types/kyc/kyc-types.d.ts +307 -0
- package/dist/types/kyc/kyc-types.d.ts.map +1 -0
- package/dist/types/kyc/kyc-types.js +85 -0
- package/dist/types/kyc/kyc-types.js.map +1 -0
- package/dist/types/wildduck/index.cjs +20 -0
- package/dist/types/wildduck/index.d.ts +3 -0
- package/dist/types/wildduck/index.d.ts.map +1 -0
- package/dist/types/wildduck/index.js +20 -0
- package/dist/types/wildduck/index.js.map +1 -0
- package/dist/types/wildduck/wildduck-types.cjs +92 -0
- package/dist/types/wildduck/wildduck-types.d.ts +1242 -0
- package/dist/types/wildduck/wildduck-types.d.ts.map +1 -0
- package/dist/types/wildduck/wildduck-types.js +92 -0
- package/dist/types/wildduck/wildduck-types.js.map +1 -0
- package/dist/types/wildduck/wildduck-websocket-types.cjs +135 -0
- package/dist/types/wildduck/wildduck-websocket-types.d.ts +381 -0
- package/dist/types/wildduck/wildduck-websocket-types.d.ts.map +1 -0
- package/dist/types/wildduck/wildduck-websocket-types.js +135 -0
- package/dist/types/wildduck/wildduck-websocket-types.js.map +1 -0
- package/package.json +66 -0
|
@@ -0,0 +1,1242 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Comprehensive WildDuck API Type Definitions
|
|
3
|
+
* Generated based on WildDuck API specification
|
|
4
|
+
*/
|
|
5
|
+
export type WildduckObjectId = string;
|
|
6
|
+
/**
|
|
7
|
+
* Wildduck Configuration
|
|
8
|
+
*/
|
|
9
|
+
export interface WildduckConfig {
|
|
10
|
+
backendUrl: string;
|
|
11
|
+
apiToken: string;
|
|
12
|
+
cloudflareWorkerUrl?: string;
|
|
13
|
+
}
|
|
14
|
+
export interface WildduckAddress {
|
|
15
|
+
id: string;
|
|
16
|
+
address: string;
|
|
17
|
+
name?: string;
|
|
18
|
+
main: boolean;
|
|
19
|
+
created?: string;
|
|
20
|
+
metaData?: Record<string, unknown>;
|
|
21
|
+
tags?: string[];
|
|
22
|
+
}
|
|
23
|
+
export interface WildduckMessageAddress {
|
|
24
|
+
name?: string;
|
|
25
|
+
address: string;
|
|
26
|
+
}
|
|
27
|
+
export interface WildduckAttachment {
|
|
28
|
+
id: string;
|
|
29
|
+
hash?: string;
|
|
30
|
+
filename: string;
|
|
31
|
+
contentType: string;
|
|
32
|
+
disposition: string;
|
|
33
|
+
transferEncoding: string;
|
|
34
|
+
related: boolean;
|
|
35
|
+
sizeKb: number;
|
|
36
|
+
}
|
|
37
|
+
export interface WildduckContentType {
|
|
38
|
+
value: string;
|
|
39
|
+
params: Record<string, unknown>;
|
|
40
|
+
}
|
|
41
|
+
export interface WildduckBimiInfo {
|
|
42
|
+
certified: boolean;
|
|
43
|
+
url: string;
|
|
44
|
+
image: string;
|
|
45
|
+
type?: 'VMC' | 'CMC';
|
|
46
|
+
}
|
|
47
|
+
export interface WildduckLimitUsage {
|
|
48
|
+
allowed: number;
|
|
49
|
+
used: number;
|
|
50
|
+
}
|
|
51
|
+
export interface WildduckLimitUsageWithTtl extends WildduckLimitUsage {
|
|
52
|
+
ttl: number | false;
|
|
53
|
+
}
|
|
54
|
+
export interface WildduckSingleLimit {
|
|
55
|
+
allowed: number;
|
|
56
|
+
}
|
|
57
|
+
export interface WildduckLimits {
|
|
58
|
+
quota: WildduckLimitUsage;
|
|
59
|
+
recipients?: WildduckLimitUsageWithTtl;
|
|
60
|
+
forwards?: WildduckLimitUsageWithTtl;
|
|
61
|
+
received?: WildduckLimitUsageWithTtl;
|
|
62
|
+
filters?: WildduckLimitUsage;
|
|
63
|
+
imapUpload?: WildduckLimitUsageWithTtl;
|
|
64
|
+
imapDownload?: WildduckLimitUsageWithTtl;
|
|
65
|
+
pop3Download?: WildduckLimitUsageWithTtl;
|
|
66
|
+
pop3MaxMessages?: WildduckSingleLimit;
|
|
67
|
+
imapMaxConnections?: WildduckLimitUsage;
|
|
68
|
+
}
|
|
69
|
+
export interface WildduckKeyInfo {
|
|
70
|
+
name: string;
|
|
71
|
+
address: string;
|
|
72
|
+
fingerprint: string;
|
|
73
|
+
}
|
|
74
|
+
export interface WildduckUserAuth {
|
|
75
|
+
username: string;
|
|
76
|
+
userId: string;
|
|
77
|
+
accessToken: string;
|
|
78
|
+
}
|
|
79
|
+
export interface WildduckPreAuthRequest {
|
|
80
|
+
username: string;
|
|
81
|
+
scope?: string;
|
|
82
|
+
sess?: string;
|
|
83
|
+
ip?: string;
|
|
84
|
+
}
|
|
85
|
+
export interface WildduckPreAuthResponse {
|
|
86
|
+
success: boolean;
|
|
87
|
+
id?: string;
|
|
88
|
+
username?: string;
|
|
89
|
+
address?: string;
|
|
90
|
+
scope?: string;
|
|
91
|
+
require2fa?: string[];
|
|
92
|
+
error?: string;
|
|
93
|
+
code?: string;
|
|
94
|
+
message?: string;
|
|
95
|
+
}
|
|
96
|
+
export interface WildduckAuthenticateRequest {
|
|
97
|
+
username: string;
|
|
98
|
+
password?: string;
|
|
99
|
+
emailDomain?: string;
|
|
100
|
+
signature?: string;
|
|
101
|
+
message?: string;
|
|
102
|
+
signer?: string;
|
|
103
|
+
referralCode?: string;
|
|
104
|
+
protocol?: string;
|
|
105
|
+
scope?: string;
|
|
106
|
+
appId?: string;
|
|
107
|
+
token?: boolean;
|
|
108
|
+
sess?: string;
|
|
109
|
+
ip?: string;
|
|
110
|
+
}
|
|
111
|
+
export interface WildduckAuthResponse {
|
|
112
|
+
success: boolean;
|
|
113
|
+
id?: string;
|
|
114
|
+
username?: string;
|
|
115
|
+
address?: string;
|
|
116
|
+
scope?: string;
|
|
117
|
+
token?: string;
|
|
118
|
+
require2fa?: string[];
|
|
119
|
+
requirePasswordChange?: boolean;
|
|
120
|
+
error?: string;
|
|
121
|
+
code?: string;
|
|
122
|
+
message?: string;
|
|
123
|
+
}
|
|
124
|
+
export declare function createPreAuthRequest(username: string, options?: Partial<WildduckPreAuthRequest>): WildduckPreAuthRequest;
|
|
125
|
+
export declare function createAuthenticateRequest(username: string, signature?: string, message?: string, options?: Partial<WildduckAuthenticateRequest>): WildduckAuthenticateRequest;
|
|
126
|
+
/**
|
|
127
|
+
* Simplified Wildduck User type (from @johnqh/types pattern)
|
|
128
|
+
*/
|
|
129
|
+
export interface WildduckUser {
|
|
130
|
+
id: string;
|
|
131
|
+
username: string;
|
|
132
|
+
name?: string;
|
|
133
|
+
address?: string;
|
|
134
|
+
language?: string;
|
|
135
|
+
retention?: number;
|
|
136
|
+
quota?: {
|
|
137
|
+
allowed: number;
|
|
138
|
+
used: number;
|
|
139
|
+
};
|
|
140
|
+
disabled: boolean;
|
|
141
|
+
suspended: boolean;
|
|
142
|
+
tags?: string[];
|
|
143
|
+
hasPasswordSet?: boolean;
|
|
144
|
+
activated?: boolean;
|
|
145
|
+
created?: string;
|
|
146
|
+
}
|
|
147
|
+
export interface WildduckUserResponse {
|
|
148
|
+
success: boolean;
|
|
149
|
+
id: string;
|
|
150
|
+
username: string;
|
|
151
|
+
name: string;
|
|
152
|
+
address: string;
|
|
153
|
+
language?: string;
|
|
154
|
+
retention?: number;
|
|
155
|
+
uploadSentMessages?: boolean;
|
|
156
|
+
enabled2fa: string[];
|
|
157
|
+
autoreply: boolean;
|
|
158
|
+
encryptMessages: boolean;
|
|
159
|
+
encryptForwarded: boolean;
|
|
160
|
+
pubKey: string;
|
|
161
|
+
spamLevel: number;
|
|
162
|
+
keyInfo: WildduckKeyInfo;
|
|
163
|
+
metaData: Record<string, unknown>;
|
|
164
|
+
internalData: Record<string, unknown>;
|
|
165
|
+
targets: string[];
|
|
166
|
+
mtaRelay?: string;
|
|
167
|
+
limits: WildduckLimits;
|
|
168
|
+
fromWhitelist: string[];
|
|
169
|
+
featureFlags?: Record<string, unknown>;
|
|
170
|
+
disabledScopes: string[];
|
|
171
|
+
hasPasswordSet: boolean;
|
|
172
|
+
activated: boolean;
|
|
173
|
+
disabled: boolean;
|
|
174
|
+
suspended: boolean;
|
|
175
|
+
tags: string[];
|
|
176
|
+
}
|
|
177
|
+
export interface WildduckSimpleUserResponse {
|
|
178
|
+
success: boolean;
|
|
179
|
+
id?: string;
|
|
180
|
+
error?: string;
|
|
181
|
+
}
|
|
182
|
+
export interface WildduckCreateUserRequest {
|
|
183
|
+
username: string;
|
|
184
|
+
password?: string;
|
|
185
|
+
hashedPassword?: boolean;
|
|
186
|
+
allowUnsafe?: boolean;
|
|
187
|
+
address?: string;
|
|
188
|
+
emptyAddress?: boolean;
|
|
189
|
+
language?: string;
|
|
190
|
+
retention?: number;
|
|
191
|
+
name?: string;
|
|
192
|
+
targets?: string[];
|
|
193
|
+
spamLevel?: number;
|
|
194
|
+
quota?: number;
|
|
195
|
+
recipients?: number;
|
|
196
|
+
forwards?: number;
|
|
197
|
+
imapMaxUpload?: number;
|
|
198
|
+
imapMaxDownload?: number;
|
|
199
|
+
pop3MaxDownload?: number;
|
|
200
|
+
pop3MaxMessages?: number;
|
|
201
|
+
imapMaxConnections?: number;
|
|
202
|
+
receivedMax?: number;
|
|
203
|
+
fromWhitelist?: string[];
|
|
204
|
+
tags?: string[];
|
|
205
|
+
addTagsToAddress?: boolean;
|
|
206
|
+
uploadSentMessages?: boolean;
|
|
207
|
+
mailboxes?: Record<string, string>;
|
|
208
|
+
disabledScopes?: string[];
|
|
209
|
+
metaData?: Record<string, unknown> | string;
|
|
210
|
+
internalData?: Record<string, unknown> | string;
|
|
211
|
+
pubKey?: string;
|
|
212
|
+
encryptMessages?: boolean;
|
|
213
|
+
encryptForwarded?: boolean;
|
|
214
|
+
sess?: string;
|
|
215
|
+
ip?: string;
|
|
216
|
+
[key: string]: unknown;
|
|
217
|
+
}
|
|
218
|
+
export interface WildduckCreateUserResponse {
|
|
219
|
+
success: boolean;
|
|
220
|
+
id: string;
|
|
221
|
+
}
|
|
222
|
+
export interface WildduckUpdateUserRequest {
|
|
223
|
+
existingPassword?: string;
|
|
224
|
+
password?: string;
|
|
225
|
+
hashedPassword?: boolean;
|
|
226
|
+
allowUnsafe?: boolean;
|
|
227
|
+
language?: string;
|
|
228
|
+
name?: string;
|
|
229
|
+
targets?: string[];
|
|
230
|
+
spamLevel?: number;
|
|
231
|
+
quota?: number;
|
|
232
|
+
recipients?: number;
|
|
233
|
+
forwards?: number;
|
|
234
|
+
imapMaxUpload?: number;
|
|
235
|
+
imapMaxDownload?: number;
|
|
236
|
+
pop3MaxDownload?: number;
|
|
237
|
+
pop3MaxMessages?: number;
|
|
238
|
+
imapMaxConnections?: number;
|
|
239
|
+
receivedMax?: number;
|
|
240
|
+
fromWhitelist?: string[];
|
|
241
|
+
tags?: string[];
|
|
242
|
+
retention?: number;
|
|
243
|
+
uploadSentMessages?: boolean;
|
|
244
|
+
disabledScopes?: string[];
|
|
245
|
+
disabled?: boolean;
|
|
246
|
+
suspended?: boolean;
|
|
247
|
+
metaData?: Record<string, unknown> | string;
|
|
248
|
+
internalData?: Record<string, unknown> | string;
|
|
249
|
+
pubKey?: string;
|
|
250
|
+
encryptMessages?: boolean;
|
|
251
|
+
encryptForwarded?: boolean;
|
|
252
|
+
sess?: string;
|
|
253
|
+
ip?: string;
|
|
254
|
+
[key: string]: unknown;
|
|
255
|
+
}
|
|
256
|
+
export interface WildduckUserListItem {
|
|
257
|
+
id: string;
|
|
258
|
+
username: string;
|
|
259
|
+
name: string;
|
|
260
|
+
address: string;
|
|
261
|
+
tags: string[];
|
|
262
|
+
targets: string[];
|
|
263
|
+
enabled2fa: string[];
|
|
264
|
+
autoreply: boolean;
|
|
265
|
+
encryptMessages: boolean;
|
|
266
|
+
encryptForwarded: boolean;
|
|
267
|
+
quota: {
|
|
268
|
+
allowed: number;
|
|
269
|
+
used: number;
|
|
270
|
+
};
|
|
271
|
+
metaData?: Record<string, unknown>;
|
|
272
|
+
internalData?: Record<string, unknown>;
|
|
273
|
+
hasPasswordSet: boolean;
|
|
274
|
+
activated: boolean;
|
|
275
|
+
disabled: boolean;
|
|
276
|
+
suspended: boolean;
|
|
277
|
+
}
|
|
278
|
+
export interface WildduckUserListResponse {
|
|
279
|
+
success: boolean;
|
|
280
|
+
query: string;
|
|
281
|
+
total: number;
|
|
282
|
+
page: number;
|
|
283
|
+
previousCursor: string | false;
|
|
284
|
+
nextCursor: string | false;
|
|
285
|
+
results: WildduckUserListItem[];
|
|
286
|
+
}
|
|
287
|
+
export interface WildduckResolveUserResponse {
|
|
288
|
+
success: boolean;
|
|
289
|
+
id: string;
|
|
290
|
+
}
|
|
291
|
+
export interface WildduckLogoutUserRequest {
|
|
292
|
+
reason?: string;
|
|
293
|
+
sess?: string;
|
|
294
|
+
ip?: string;
|
|
295
|
+
}
|
|
296
|
+
export interface WildduckQuotaResetResponse {
|
|
297
|
+
success: boolean;
|
|
298
|
+
storageUsed: number;
|
|
299
|
+
previousStorageUsed: number;
|
|
300
|
+
}
|
|
301
|
+
export interface WildduckPasswordResetRequest {
|
|
302
|
+
validAfter?: string;
|
|
303
|
+
sess?: string;
|
|
304
|
+
ip?: string;
|
|
305
|
+
}
|
|
306
|
+
export interface WildduckPasswordResetResponse {
|
|
307
|
+
success: boolean;
|
|
308
|
+
password: string;
|
|
309
|
+
validAfter: string;
|
|
310
|
+
}
|
|
311
|
+
/**
|
|
312
|
+
* Special mailbox types (IMAP special-use flags)
|
|
313
|
+
* These correspond to standard IMAP mailbox flags
|
|
314
|
+
*/
|
|
315
|
+
export declare enum MailboxSpecialUse {
|
|
316
|
+
Inbox = "\\Inbox",
|
|
317
|
+
Sent = "\\Sent",
|
|
318
|
+
Trash = "\\Trash",
|
|
319
|
+
Drafts = "\\Drafts",
|
|
320
|
+
Junk = "\\Junk",
|
|
321
|
+
Settings = "\\App.Settings",
|
|
322
|
+
Developer = "\\App.Developer"
|
|
323
|
+
}
|
|
324
|
+
export type EmailFolder = MailboxSpecialUse | string;
|
|
325
|
+
export declare const EmailFolderUtils: {
|
|
326
|
+
/**
|
|
327
|
+
* Check if a folder name is one of the standard mailbox types
|
|
328
|
+
*/
|
|
329
|
+
isStandardFolder(folder: string): folder is MailboxSpecialUse;
|
|
330
|
+
/**
|
|
331
|
+
* Get all standard folder names
|
|
332
|
+
*/
|
|
333
|
+
getStandardFolders(): MailboxSpecialUse[];
|
|
334
|
+
/**
|
|
335
|
+
* Check if a folder is a custom folder (not one of the standard ones)
|
|
336
|
+
*/
|
|
337
|
+
isCustomFolder(folder: string): boolean;
|
|
338
|
+
/**
|
|
339
|
+
* Normalize folder name for display (capitalize first letter)
|
|
340
|
+
*/
|
|
341
|
+
displayName(folder: EmailFolder): string;
|
|
342
|
+
};
|
|
343
|
+
/**
|
|
344
|
+
* Simplified Wildduck Mailbox type (from @johnqh/types pattern)
|
|
345
|
+
*/
|
|
346
|
+
export interface WildduckMailbox {
|
|
347
|
+
id: string;
|
|
348
|
+
name: string;
|
|
349
|
+
path: string;
|
|
350
|
+
specialUse?: MailboxSpecialUse;
|
|
351
|
+
modifyIndex: number;
|
|
352
|
+
subscribed: boolean;
|
|
353
|
+
hidden: boolean;
|
|
354
|
+
total?: number;
|
|
355
|
+
unseen?: number;
|
|
356
|
+
size?: number;
|
|
357
|
+
}
|
|
358
|
+
export interface WildduckMailboxResponse {
|
|
359
|
+
success: boolean;
|
|
360
|
+
results: WildduckMailbox[];
|
|
361
|
+
error?: string;
|
|
362
|
+
}
|
|
363
|
+
/** Get mailboxes request */
|
|
364
|
+
export interface GetMailboxesRequest {
|
|
365
|
+
sess?: string;
|
|
366
|
+
ip?: string;
|
|
367
|
+
specialUse?: boolean;
|
|
368
|
+
showHidden?: boolean;
|
|
369
|
+
counters?: boolean;
|
|
370
|
+
sizes?: boolean;
|
|
371
|
+
}
|
|
372
|
+
/** Get messages request */
|
|
373
|
+
export interface GetMessagesRequest {
|
|
374
|
+
sess?: string;
|
|
375
|
+
ip?: string;
|
|
376
|
+
limit?: number;
|
|
377
|
+
page?: number;
|
|
378
|
+
next?: string;
|
|
379
|
+
previous?: string;
|
|
380
|
+
order?: 'asc' | 'desc';
|
|
381
|
+
unseen?: boolean;
|
|
382
|
+
flagged?: boolean;
|
|
383
|
+
thread?: string;
|
|
384
|
+
includeHeaders?: string[];
|
|
385
|
+
uid?: boolean;
|
|
386
|
+
}
|
|
387
|
+
/** Create new mailbox request */
|
|
388
|
+
export interface CreateMailboxRequest {
|
|
389
|
+
path: string;
|
|
390
|
+
hidden?: boolean;
|
|
391
|
+
retention?: number;
|
|
392
|
+
encryptMessages?: boolean;
|
|
393
|
+
sess?: string;
|
|
394
|
+
ip?: string;
|
|
395
|
+
}
|
|
396
|
+
/** Update existing mailbox request */
|
|
397
|
+
export interface UpdateMailboxRequest {
|
|
398
|
+
path?: string;
|
|
399
|
+
retention?: number;
|
|
400
|
+
subscribed?: boolean;
|
|
401
|
+
encryptMessages?: boolean;
|
|
402
|
+
hidden?: boolean;
|
|
403
|
+
sess?: string;
|
|
404
|
+
ip?: string;
|
|
405
|
+
}
|
|
406
|
+
export interface WildduckMailboxListItem {
|
|
407
|
+
id: string;
|
|
408
|
+
name: string;
|
|
409
|
+
path: string;
|
|
410
|
+
specialUse: string | false;
|
|
411
|
+
modifyIndex: number;
|
|
412
|
+
subscribed: boolean;
|
|
413
|
+
hidden: boolean;
|
|
414
|
+
total?: number;
|
|
415
|
+
unseen?: number;
|
|
416
|
+
size?: number;
|
|
417
|
+
}
|
|
418
|
+
export interface WildduckMailboxListResponse {
|
|
419
|
+
success: boolean;
|
|
420
|
+
results: WildduckMailboxListItem[];
|
|
421
|
+
}
|
|
422
|
+
export interface WildduckCreateMailboxRequest {
|
|
423
|
+
path: string;
|
|
424
|
+
hidden?: boolean;
|
|
425
|
+
retention?: number;
|
|
426
|
+
sess?: string;
|
|
427
|
+
ip?: string;
|
|
428
|
+
}
|
|
429
|
+
export interface WildduckCreateMailboxResponse {
|
|
430
|
+
success: boolean;
|
|
431
|
+
id: string;
|
|
432
|
+
}
|
|
433
|
+
export interface WildduckDetailedMailboxResponse {
|
|
434
|
+
success: boolean;
|
|
435
|
+
id: string;
|
|
436
|
+
name: string;
|
|
437
|
+
path: string;
|
|
438
|
+
specialUse: string | false;
|
|
439
|
+
modifyIndex: number;
|
|
440
|
+
subscribed: boolean;
|
|
441
|
+
hidden: boolean;
|
|
442
|
+
total: number;
|
|
443
|
+
unseen: number;
|
|
444
|
+
}
|
|
445
|
+
export interface WildduckUpdateMailboxRequest {
|
|
446
|
+
path?: string;
|
|
447
|
+
retention?: number;
|
|
448
|
+
subscribed?: boolean;
|
|
449
|
+
hidden?: boolean;
|
|
450
|
+
sess?: string;
|
|
451
|
+
ip?: string;
|
|
452
|
+
[key: string]: unknown;
|
|
453
|
+
}
|
|
454
|
+
export interface WildduckMessageAttachment {
|
|
455
|
+
id: string;
|
|
456
|
+
filename: string;
|
|
457
|
+
contentType: string;
|
|
458
|
+
hash?: string;
|
|
459
|
+
disposition?: string;
|
|
460
|
+
transferEncoding?: string;
|
|
461
|
+
related?: boolean;
|
|
462
|
+
size?: number;
|
|
463
|
+
sizeKb?: number;
|
|
464
|
+
}
|
|
465
|
+
export interface WildduckMessageListItem {
|
|
466
|
+
id: number;
|
|
467
|
+
mailbox: string;
|
|
468
|
+
thread: string;
|
|
469
|
+
threadMessageCount?: number;
|
|
470
|
+
from?: WildduckMessageAddress;
|
|
471
|
+
to: WildduckMessageAddress[];
|
|
472
|
+
cc: WildduckMessageAddress[];
|
|
473
|
+
bcc: WildduckMessageAddress[];
|
|
474
|
+
messageId: string;
|
|
475
|
+
subject: string;
|
|
476
|
+
date: string;
|
|
477
|
+
idate?: string;
|
|
478
|
+
intro: string;
|
|
479
|
+
attachments: boolean;
|
|
480
|
+
attachmentsList?: WildduckAttachment[];
|
|
481
|
+
size: number;
|
|
482
|
+
seen: boolean;
|
|
483
|
+
deleted: boolean;
|
|
484
|
+
flagged: boolean;
|
|
485
|
+
draft: boolean;
|
|
486
|
+
answered: boolean;
|
|
487
|
+
forwarded: boolean;
|
|
488
|
+
references: string[];
|
|
489
|
+
bimi?: WildduckBimiInfo;
|
|
490
|
+
contentType: WildduckContentType;
|
|
491
|
+
encrypted?: boolean;
|
|
492
|
+
metaData?: Record<string, unknown>;
|
|
493
|
+
headers?: Record<string, string>;
|
|
494
|
+
}
|
|
495
|
+
export type WildduckMessage = WildduckMessageListItem;
|
|
496
|
+
export interface WildduckMessagesResponse {
|
|
497
|
+
success: boolean;
|
|
498
|
+
total: number;
|
|
499
|
+
page: number;
|
|
500
|
+
previousCursor: string | false;
|
|
501
|
+
nextCursor: string | false;
|
|
502
|
+
specialUse: string;
|
|
503
|
+
results: WildduckMessageListItem[];
|
|
504
|
+
error?: string;
|
|
505
|
+
}
|
|
506
|
+
export interface WildduckMessageListResponse {
|
|
507
|
+
success: boolean;
|
|
508
|
+
total: number;
|
|
509
|
+
page: number;
|
|
510
|
+
previousCursor: string | false;
|
|
511
|
+
nextCursor: string | false;
|
|
512
|
+
specialUse: string;
|
|
513
|
+
results: WildduckMessageListItem[];
|
|
514
|
+
}
|
|
515
|
+
export interface WildduckEnvelopeRecipient {
|
|
516
|
+
value: string;
|
|
517
|
+
formatted: string;
|
|
518
|
+
}
|
|
519
|
+
export interface WildduckMessageEnvelope {
|
|
520
|
+
from: string;
|
|
521
|
+
rcpt: WildduckEnvelopeRecipient[];
|
|
522
|
+
}
|
|
523
|
+
export interface WildduckVerificationResults {
|
|
524
|
+
tls?: {
|
|
525
|
+
name: Record<string, unknown>;
|
|
526
|
+
version: Record<string, unknown>;
|
|
527
|
+
} | false;
|
|
528
|
+
spf?: Record<string, unknown> | false;
|
|
529
|
+
dkim?: Record<string, unknown> | false;
|
|
530
|
+
}
|
|
531
|
+
export interface WildduckMessageDetail {
|
|
532
|
+
id: number;
|
|
533
|
+
mailbox: string;
|
|
534
|
+
user: string;
|
|
535
|
+
envelope?: WildduckMessageEnvelope;
|
|
536
|
+
thread: string;
|
|
537
|
+
from?: WildduckMessageAddress;
|
|
538
|
+
replyTo?: WildduckMessageAddress;
|
|
539
|
+
to: WildduckMessageAddress[];
|
|
540
|
+
cc: WildduckMessageAddress[];
|
|
541
|
+
bcc: WildduckMessageAddress[];
|
|
542
|
+
subject: string;
|
|
543
|
+
messageId: string;
|
|
544
|
+
date: string;
|
|
545
|
+
idate?: string;
|
|
546
|
+
list?: {
|
|
547
|
+
id: string;
|
|
548
|
+
unsubscribe: string;
|
|
549
|
+
};
|
|
550
|
+
size: number;
|
|
551
|
+
expires?: string;
|
|
552
|
+
seen: boolean;
|
|
553
|
+
deleted: boolean;
|
|
554
|
+
flagged: boolean;
|
|
555
|
+
draft: boolean;
|
|
556
|
+
answered: boolean;
|
|
557
|
+
forwarded: boolean;
|
|
558
|
+
html?: string[];
|
|
559
|
+
text?: string;
|
|
560
|
+
intro?: string;
|
|
561
|
+
attachments: WildduckMessageAttachment[];
|
|
562
|
+
verificationResults?: WildduckVerificationResults;
|
|
563
|
+
bimi?: WildduckBimiInfo;
|
|
564
|
+
contentType: WildduckContentType;
|
|
565
|
+
metaData?: Record<string, unknown>;
|
|
566
|
+
references: string[];
|
|
567
|
+
files?: Record<string, unknown>;
|
|
568
|
+
outbound?: unknown[];
|
|
569
|
+
forwardTargets?: Record<string, unknown>;
|
|
570
|
+
reference?: Record<string, unknown>;
|
|
571
|
+
encrypted?: boolean;
|
|
572
|
+
headers?: Record<string, string | string[]>;
|
|
573
|
+
}
|
|
574
|
+
export interface WildduckMessageResponse extends WildduckMessageDetail {
|
|
575
|
+
success: boolean;
|
|
576
|
+
error?: string;
|
|
577
|
+
}
|
|
578
|
+
export type WildduckDetailedMessageResponse = WildduckMessageResponse;
|
|
579
|
+
export interface WildduckSearchMessagesRequest {
|
|
580
|
+
q?: string;
|
|
581
|
+
mailbox?: string;
|
|
582
|
+
id?: string;
|
|
583
|
+
thread?: string;
|
|
584
|
+
or?: {
|
|
585
|
+
query?: string;
|
|
586
|
+
from?: string;
|
|
587
|
+
to?: string;
|
|
588
|
+
subject?: string;
|
|
589
|
+
};
|
|
590
|
+
query?: string;
|
|
591
|
+
datestart?: string;
|
|
592
|
+
dateend?: string;
|
|
593
|
+
from?: string;
|
|
594
|
+
to?: string;
|
|
595
|
+
subject?: string;
|
|
596
|
+
minSize?: number;
|
|
597
|
+
maxSize?: number;
|
|
598
|
+
attachments?: boolean;
|
|
599
|
+
flagged?: boolean;
|
|
600
|
+
unseen?: boolean;
|
|
601
|
+
includeHeaders?: string[];
|
|
602
|
+
searchable?: boolean;
|
|
603
|
+
threadCounters?: boolean;
|
|
604
|
+
limit?: number;
|
|
605
|
+
order?: 'asc' | 'desc';
|
|
606
|
+
next?: string;
|
|
607
|
+
previous?: string;
|
|
608
|
+
sess?: string;
|
|
609
|
+
ip?: string;
|
|
610
|
+
}
|
|
611
|
+
export interface WildduckSearchMessagesResponse {
|
|
612
|
+
success: boolean;
|
|
613
|
+
query: string;
|
|
614
|
+
total: number;
|
|
615
|
+
page: number;
|
|
616
|
+
previousCursor: string | false;
|
|
617
|
+
nextCursor: string | false;
|
|
618
|
+
results: WildduckMessageListItem[];
|
|
619
|
+
}
|
|
620
|
+
export interface WildduckSearchApplyRequest extends WildduckSearchMessagesRequest {
|
|
621
|
+
action: {
|
|
622
|
+
moveTo?: string;
|
|
623
|
+
seen?: boolean;
|
|
624
|
+
flagged?: boolean;
|
|
625
|
+
};
|
|
626
|
+
}
|
|
627
|
+
export interface WildduckSearchApplyResponse {
|
|
628
|
+
success: boolean;
|
|
629
|
+
scheduled: string;
|
|
630
|
+
existing: boolean;
|
|
631
|
+
}
|
|
632
|
+
export interface WildduckUpdateMessageRequest {
|
|
633
|
+
message?: string;
|
|
634
|
+
moveTo?: string;
|
|
635
|
+
seen?: boolean;
|
|
636
|
+
deleted?: boolean;
|
|
637
|
+
flagged?: boolean;
|
|
638
|
+
draft?: boolean;
|
|
639
|
+
expires?: string | false;
|
|
640
|
+
metaData?: Record<string, unknown> | string;
|
|
641
|
+
sess?: string;
|
|
642
|
+
ip?: string;
|
|
643
|
+
[key: string]: unknown;
|
|
644
|
+
}
|
|
645
|
+
export interface WildduckUpdateMessageResponse {
|
|
646
|
+
success: boolean;
|
|
647
|
+
id?: Array<[number, number]>;
|
|
648
|
+
mailbox?: string;
|
|
649
|
+
updated?: number;
|
|
650
|
+
}
|
|
651
|
+
export interface WildduckUploadMessageRequest {
|
|
652
|
+
date?: string;
|
|
653
|
+
unseen?: boolean;
|
|
654
|
+
flagged?: boolean;
|
|
655
|
+
draft?: boolean;
|
|
656
|
+
raw?: string;
|
|
657
|
+
from?: WildduckAddress;
|
|
658
|
+
replyTo?: WildduckAddress;
|
|
659
|
+
to?: WildduckAddress[];
|
|
660
|
+
cc?: WildduckAddress[];
|
|
661
|
+
bcc?: WildduckAddress[];
|
|
662
|
+
headers?: Array<{
|
|
663
|
+
key: string;
|
|
664
|
+
value: string;
|
|
665
|
+
}>;
|
|
666
|
+
subject?: string;
|
|
667
|
+
text?: string;
|
|
668
|
+
html?: string;
|
|
669
|
+
files?: string[];
|
|
670
|
+
attachments?: Array<{
|
|
671
|
+
filename: string;
|
|
672
|
+
content: string;
|
|
673
|
+
contentType: string;
|
|
674
|
+
cid?: string;
|
|
675
|
+
}>;
|
|
676
|
+
metaData?: Record<string, unknown> | string;
|
|
677
|
+
reference?: {
|
|
678
|
+
mailbox: string;
|
|
679
|
+
id: number;
|
|
680
|
+
action: 'reply' | 'replyAll' | 'forward';
|
|
681
|
+
attachments?: boolean | string[];
|
|
682
|
+
};
|
|
683
|
+
replacePrevious?: {
|
|
684
|
+
mailbox: string;
|
|
685
|
+
id: number;
|
|
686
|
+
};
|
|
687
|
+
bimi?: {
|
|
688
|
+
domain: string;
|
|
689
|
+
selector?: string;
|
|
690
|
+
};
|
|
691
|
+
sess?: string;
|
|
692
|
+
ip?: string;
|
|
693
|
+
[key: string]: unknown;
|
|
694
|
+
}
|
|
695
|
+
export interface WildduckUploadMessageResponse {
|
|
696
|
+
success: boolean;
|
|
697
|
+
message: {
|
|
698
|
+
id: number;
|
|
699
|
+
mailbox: string;
|
|
700
|
+
size?: number;
|
|
701
|
+
};
|
|
702
|
+
}
|
|
703
|
+
export interface WildduckForwardMessageRequest {
|
|
704
|
+
target: number;
|
|
705
|
+
sess?: string;
|
|
706
|
+
ip?: string;
|
|
707
|
+
[key: string]: unknown;
|
|
708
|
+
}
|
|
709
|
+
export interface WildduckSubmitMessageRequest {
|
|
710
|
+
from?: WildduckAddress;
|
|
711
|
+
to: WildduckAddress[];
|
|
712
|
+
cc?: WildduckAddress[];
|
|
713
|
+
bcc?: WildduckAddress[];
|
|
714
|
+
subject?: string;
|
|
715
|
+
text?: string;
|
|
716
|
+
html?: string;
|
|
717
|
+
headers?: Array<{
|
|
718
|
+
key: string;
|
|
719
|
+
value: string;
|
|
720
|
+
}>;
|
|
721
|
+
files?: string[];
|
|
722
|
+
attachments?: Array<{
|
|
723
|
+
filename: string;
|
|
724
|
+
content: string;
|
|
725
|
+
contentType: string;
|
|
726
|
+
cid?: string;
|
|
727
|
+
}>;
|
|
728
|
+
sess?: string;
|
|
729
|
+
ip?: string;
|
|
730
|
+
[key: string]: unknown;
|
|
731
|
+
}
|
|
732
|
+
export interface WildduckSubmitMessageResponse {
|
|
733
|
+
success: boolean;
|
|
734
|
+
message: {
|
|
735
|
+
id: number;
|
|
736
|
+
mailbox: string;
|
|
737
|
+
queueId: string;
|
|
738
|
+
};
|
|
739
|
+
}
|
|
740
|
+
export interface WildduckAddressResponse {
|
|
741
|
+
success: boolean;
|
|
742
|
+
results?: WildduckAddress[];
|
|
743
|
+
error?: string;
|
|
744
|
+
}
|
|
745
|
+
export interface WildduckAddressListItem {
|
|
746
|
+
id: string;
|
|
747
|
+
name: string;
|
|
748
|
+
address: string;
|
|
749
|
+
tags: string[];
|
|
750
|
+
main: boolean;
|
|
751
|
+
created: string;
|
|
752
|
+
}
|
|
753
|
+
export interface WildduckAddressListResponse {
|
|
754
|
+
success: boolean;
|
|
755
|
+
results: WildduckAddressListItem[];
|
|
756
|
+
}
|
|
757
|
+
export interface WildduckCreateAddressRequest {
|
|
758
|
+
address: string;
|
|
759
|
+
name?: string;
|
|
760
|
+
main?: boolean;
|
|
761
|
+
tags?: string[];
|
|
762
|
+
sess?: string;
|
|
763
|
+
ip?: string;
|
|
764
|
+
}
|
|
765
|
+
export interface WildduckCreateAddressResponse {
|
|
766
|
+
success: boolean;
|
|
767
|
+
id: string;
|
|
768
|
+
}
|
|
769
|
+
export interface WildduckUpdateAddressRequest {
|
|
770
|
+
name?: string;
|
|
771
|
+
main?: boolean;
|
|
772
|
+
tags?: string[];
|
|
773
|
+
sess?: string;
|
|
774
|
+
ip?: string;
|
|
775
|
+
}
|
|
776
|
+
export interface WildduckForwardedAddressListItem {
|
|
777
|
+
id: string;
|
|
778
|
+
address: string;
|
|
779
|
+
name: string;
|
|
780
|
+
targets: string[];
|
|
781
|
+
forwards: number;
|
|
782
|
+
forwardedDisabled: boolean;
|
|
783
|
+
tags: string[];
|
|
784
|
+
created: string;
|
|
785
|
+
}
|
|
786
|
+
export interface WildduckForwardedAddressListResponse {
|
|
787
|
+
success: boolean;
|
|
788
|
+
results: WildduckForwardedAddressListItem[];
|
|
789
|
+
}
|
|
790
|
+
export interface WildduckCreateForwardedAddressRequest {
|
|
791
|
+
address: string;
|
|
792
|
+
name?: string;
|
|
793
|
+
targets: string[];
|
|
794
|
+
forwards?: number;
|
|
795
|
+
forwardedDisabled?: boolean;
|
|
796
|
+
tags?: string[];
|
|
797
|
+
sess?: string;
|
|
798
|
+
ip?: string;
|
|
799
|
+
}
|
|
800
|
+
export interface WildduckUpdateForwardedAddressRequest {
|
|
801
|
+
name?: string;
|
|
802
|
+
targets?: string[];
|
|
803
|
+
forwards?: number;
|
|
804
|
+
forwardedDisabled?: boolean;
|
|
805
|
+
tags?: string[];
|
|
806
|
+
sess?: string;
|
|
807
|
+
ip?: string;
|
|
808
|
+
}
|
|
809
|
+
export interface WildduckResolveAddressResponse {
|
|
810
|
+
success: boolean;
|
|
811
|
+
id: string;
|
|
812
|
+
}
|
|
813
|
+
/** Message filter query conditions */
|
|
814
|
+
export interface FilterQuery {
|
|
815
|
+
from?: string;
|
|
816
|
+
to?: string;
|
|
817
|
+
subject?: string;
|
|
818
|
+
listId?: string;
|
|
819
|
+
text?: string;
|
|
820
|
+
ha?: boolean;
|
|
821
|
+
size?: number;
|
|
822
|
+
}
|
|
823
|
+
/** Actions to take on filtered messages */
|
|
824
|
+
export interface FilterAction {
|
|
825
|
+
seen?: boolean;
|
|
826
|
+
flag?: boolean;
|
|
827
|
+
delete?: boolean;
|
|
828
|
+
spam?: boolean;
|
|
829
|
+
mailbox?: string;
|
|
830
|
+
targets?: string[];
|
|
831
|
+
}
|
|
832
|
+
export interface WildduckFilterQuery {
|
|
833
|
+
from?: string;
|
|
834
|
+
to?: string;
|
|
835
|
+
subject?: string;
|
|
836
|
+
text?: string;
|
|
837
|
+
ha?: boolean;
|
|
838
|
+
size?: number;
|
|
839
|
+
}
|
|
840
|
+
export interface WildduckFilterAction {
|
|
841
|
+
seen?: boolean;
|
|
842
|
+
flag?: boolean;
|
|
843
|
+
delete?: boolean;
|
|
844
|
+
spam?: boolean;
|
|
845
|
+
mailbox?: string;
|
|
846
|
+
targets?: string[];
|
|
847
|
+
forward?: string;
|
|
848
|
+
}
|
|
849
|
+
export interface WildduckFilterListItem {
|
|
850
|
+
id: string;
|
|
851
|
+
name: string;
|
|
852
|
+
query: WildduckFilterQuery;
|
|
853
|
+
action: WildduckFilterAction;
|
|
854
|
+
disabled: boolean;
|
|
855
|
+
created: string;
|
|
856
|
+
}
|
|
857
|
+
export interface WildduckFilterListResponse {
|
|
858
|
+
success: boolean;
|
|
859
|
+
results: WildduckFilterListItem[];
|
|
860
|
+
}
|
|
861
|
+
export interface WildduckCreateFilterRequest {
|
|
862
|
+
name: string;
|
|
863
|
+
query: WildduckFilterQuery;
|
|
864
|
+
action: WildduckFilterAction;
|
|
865
|
+
disabled?: boolean;
|
|
866
|
+
sess?: string;
|
|
867
|
+
ip?: string;
|
|
868
|
+
}
|
|
869
|
+
export interface WildduckCreateFilterResponse {
|
|
870
|
+
success: boolean;
|
|
871
|
+
id: string;
|
|
872
|
+
}
|
|
873
|
+
export interface WildduckUpdateFilterRequest {
|
|
874
|
+
name?: string;
|
|
875
|
+
query?: WildduckFilterQuery;
|
|
876
|
+
action?: WildduckFilterAction;
|
|
877
|
+
disabled?: boolean;
|
|
878
|
+
sess?: string;
|
|
879
|
+
ip?: string;
|
|
880
|
+
}
|
|
881
|
+
export interface WildduckFilterResponse {
|
|
882
|
+
success: boolean;
|
|
883
|
+
id: string;
|
|
884
|
+
name: string;
|
|
885
|
+
query: WildduckFilterQuery;
|
|
886
|
+
action: WildduckFilterAction;
|
|
887
|
+
disabled: boolean;
|
|
888
|
+
created: string;
|
|
889
|
+
}
|
|
890
|
+
/** Email filter */
|
|
891
|
+
export interface EmailFilter {
|
|
892
|
+
id: string;
|
|
893
|
+
name: string;
|
|
894
|
+
query: FilterQuery;
|
|
895
|
+
action: FilterAction;
|
|
896
|
+
disabled?: boolean;
|
|
897
|
+
}
|
|
898
|
+
/** Response from filter operations */
|
|
899
|
+
export interface FilterResponse {
|
|
900
|
+
success: boolean;
|
|
901
|
+
id?: string;
|
|
902
|
+
}
|
|
903
|
+
export interface WildduckAutoreplyRequest {
|
|
904
|
+
status?: boolean;
|
|
905
|
+
name?: string;
|
|
906
|
+
subject?: string;
|
|
907
|
+
text?: string;
|
|
908
|
+
html?: string;
|
|
909
|
+
start?: string;
|
|
910
|
+
end?: string;
|
|
911
|
+
sess?: string;
|
|
912
|
+
ip?: string;
|
|
913
|
+
[key: string]: unknown;
|
|
914
|
+
}
|
|
915
|
+
export interface WildduckAutoreplyResponse {
|
|
916
|
+
success: boolean;
|
|
917
|
+
status: boolean;
|
|
918
|
+
name: string;
|
|
919
|
+
subject: string;
|
|
920
|
+
text: string;
|
|
921
|
+
html: string;
|
|
922
|
+
start: string | false;
|
|
923
|
+
end: string | false;
|
|
924
|
+
}
|
|
925
|
+
export interface WildduckASPListItem {
|
|
926
|
+
id: string;
|
|
927
|
+
description: string;
|
|
928
|
+
scopes: string[];
|
|
929
|
+
lastUse: {
|
|
930
|
+
time: string;
|
|
931
|
+
event: string;
|
|
932
|
+
} | false;
|
|
933
|
+
created: string;
|
|
934
|
+
}
|
|
935
|
+
export interface WildduckASPListResponse {
|
|
936
|
+
success: boolean;
|
|
937
|
+
results: WildduckASPListItem[];
|
|
938
|
+
}
|
|
939
|
+
export interface WildduckCreateASPRequest {
|
|
940
|
+
description: string;
|
|
941
|
+
scopes: string[];
|
|
942
|
+
generateMobileconfig?: boolean;
|
|
943
|
+
sess?: string;
|
|
944
|
+
ip?: string;
|
|
945
|
+
}
|
|
946
|
+
export interface WildduckCreateASPResponse {
|
|
947
|
+
success: boolean;
|
|
948
|
+
id: string;
|
|
949
|
+
password: string;
|
|
950
|
+
mobileconfig?: string;
|
|
951
|
+
}
|
|
952
|
+
export interface WildduckASPResponse {
|
|
953
|
+
success: boolean;
|
|
954
|
+
id: string;
|
|
955
|
+
description: string;
|
|
956
|
+
scopes: string[];
|
|
957
|
+
lastUse: {
|
|
958
|
+
time: string;
|
|
959
|
+
event: string;
|
|
960
|
+
} | false;
|
|
961
|
+
created: string;
|
|
962
|
+
}
|
|
963
|
+
export interface WildduckStorageUploadRequest {
|
|
964
|
+
filename: string;
|
|
965
|
+
contentType: string;
|
|
966
|
+
encoding?: string;
|
|
967
|
+
content: string;
|
|
968
|
+
sess?: string;
|
|
969
|
+
ip?: string;
|
|
970
|
+
}
|
|
971
|
+
export interface WildduckStorageUploadResponse {
|
|
972
|
+
success: boolean;
|
|
973
|
+
id: string;
|
|
974
|
+
}
|
|
975
|
+
export interface WildduckStorageListItem {
|
|
976
|
+
id: string;
|
|
977
|
+
filename: string;
|
|
978
|
+
contentType: string;
|
|
979
|
+
size: number;
|
|
980
|
+
created: string;
|
|
981
|
+
}
|
|
982
|
+
export interface WildduckStorageListResponse {
|
|
983
|
+
success: boolean;
|
|
984
|
+
results: WildduckStorageListItem[];
|
|
985
|
+
}
|
|
986
|
+
export interface WildduckSettingItem {
|
|
987
|
+
key: string;
|
|
988
|
+
value: unknown;
|
|
989
|
+
description: string;
|
|
990
|
+
}
|
|
991
|
+
export interface WildduckSettingsListResponse {
|
|
992
|
+
success: boolean;
|
|
993
|
+
results: WildduckSettingItem[];
|
|
994
|
+
}
|
|
995
|
+
export interface WildduckSettingResponse {
|
|
996
|
+
success: boolean;
|
|
997
|
+
key: string;
|
|
998
|
+
value: unknown;
|
|
999
|
+
}
|
|
1000
|
+
export interface WildduckUpdateSettingRequest {
|
|
1001
|
+
value: unknown;
|
|
1002
|
+
}
|
|
1003
|
+
/**
|
|
1004
|
+
* User information response (detailed)
|
|
1005
|
+
*/
|
|
1006
|
+
export interface UserInfo {
|
|
1007
|
+
success: boolean;
|
|
1008
|
+
id: string;
|
|
1009
|
+
username: string;
|
|
1010
|
+
name?: string;
|
|
1011
|
+
address: string;
|
|
1012
|
+
retention?: number;
|
|
1013
|
+
enabled2fa?: string[];
|
|
1014
|
+
autoreply?: boolean;
|
|
1015
|
+
encryptMessages?: boolean;
|
|
1016
|
+
encryptForwarded?: boolean;
|
|
1017
|
+
pubKey?: string;
|
|
1018
|
+
metaData?: Record<string, unknown>;
|
|
1019
|
+
internalData?: Record<string, unknown>;
|
|
1020
|
+
hasPasswordSet?: boolean;
|
|
1021
|
+
activated?: boolean;
|
|
1022
|
+
disabled?: boolean;
|
|
1023
|
+
suspended?: boolean;
|
|
1024
|
+
quota: {
|
|
1025
|
+
allowed: number;
|
|
1026
|
+
used: number;
|
|
1027
|
+
};
|
|
1028
|
+
targets?: string[];
|
|
1029
|
+
spamLevel?: number;
|
|
1030
|
+
uploadSentMessages?: boolean;
|
|
1031
|
+
mtaRelay?: string;
|
|
1032
|
+
limits: {
|
|
1033
|
+
quota: {
|
|
1034
|
+
allowed: number;
|
|
1035
|
+
used: number;
|
|
1036
|
+
};
|
|
1037
|
+
recipients?: {
|
|
1038
|
+
allowed: number;
|
|
1039
|
+
used: number;
|
|
1040
|
+
ttl: number;
|
|
1041
|
+
};
|
|
1042
|
+
forwards?: {
|
|
1043
|
+
allowed: number;
|
|
1044
|
+
used: number;
|
|
1045
|
+
ttl: number;
|
|
1046
|
+
};
|
|
1047
|
+
received?: {
|
|
1048
|
+
allowed: number;
|
|
1049
|
+
used: number;
|
|
1050
|
+
ttl: number;
|
|
1051
|
+
};
|
|
1052
|
+
imapUpload?: {
|
|
1053
|
+
allowed: number;
|
|
1054
|
+
used: number;
|
|
1055
|
+
ttl: number;
|
|
1056
|
+
};
|
|
1057
|
+
imapDownload?: {
|
|
1058
|
+
allowed: number;
|
|
1059
|
+
used: number;
|
|
1060
|
+
ttl: number;
|
|
1061
|
+
};
|
|
1062
|
+
pop3Download?: {
|
|
1063
|
+
allowed: number;
|
|
1064
|
+
used: number;
|
|
1065
|
+
ttl: number;
|
|
1066
|
+
};
|
|
1067
|
+
imapMaxConnections?: {
|
|
1068
|
+
allowed: number;
|
|
1069
|
+
};
|
|
1070
|
+
};
|
|
1071
|
+
tags?: string[];
|
|
1072
|
+
disabledScopes?: string[];
|
|
1073
|
+
fromWhitelist?: string[];
|
|
1074
|
+
}
|
|
1075
|
+
/**
|
|
1076
|
+
* Auto-reply (out of office) settings response
|
|
1077
|
+
*/
|
|
1078
|
+
export interface AutoReplySettings {
|
|
1079
|
+
success: boolean;
|
|
1080
|
+
status?: boolean;
|
|
1081
|
+
name?: string;
|
|
1082
|
+
subject?: string;
|
|
1083
|
+
text?: string;
|
|
1084
|
+
html?: string;
|
|
1085
|
+
start?: string;
|
|
1086
|
+
end?: string;
|
|
1087
|
+
}
|
|
1088
|
+
/**
|
|
1089
|
+
* Forwarding target response types
|
|
1090
|
+
* Forwarding target - can be email, SMTP relay, or HTTP webhook
|
|
1091
|
+
*/
|
|
1092
|
+
export type ForwardingTarget = string;
|
|
1093
|
+
/**
|
|
1094
|
+
* Spam settings response
|
|
1095
|
+
*/
|
|
1096
|
+
export interface SpamSettings {
|
|
1097
|
+
success: boolean;
|
|
1098
|
+
spamLevel?: number;
|
|
1099
|
+
fromWhitelist?: string[];
|
|
1100
|
+
}
|
|
1101
|
+
/**
|
|
1102
|
+
* SMTP relay configuration
|
|
1103
|
+
*/
|
|
1104
|
+
export interface SMTPRelay {
|
|
1105
|
+
enabled: boolean;
|
|
1106
|
+
host?: string;
|
|
1107
|
+
port?: number;
|
|
1108
|
+
secure?: boolean;
|
|
1109
|
+
auth?: {
|
|
1110
|
+
user: string;
|
|
1111
|
+
pass: string;
|
|
1112
|
+
};
|
|
1113
|
+
}
|
|
1114
|
+
/**
|
|
1115
|
+
* Advanced settings response
|
|
1116
|
+
*/
|
|
1117
|
+
export interface AdvancedSettings {
|
|
1118
|
+
success: boolean;
|
|
1119
|
+
uploadSentMessages?: boolean;
|
|
1120
|
+
smtpRelay?: SMTPRelay;
|
|
1121
|
+
}
|
|
1122
|
+
export interface WildduckHealthResponse {
|
|
1123
|
+
success: boolean;
|
|
1124
|
+
version: string;
|
|
1125
|
+
mongodb: {
|
|
1126
|
+
status: string;
|
|
1127
|
+
responseTime: string;
|
|
1128
|
+
};
|
|
1129
|
+
redis: {
|
|
1130
|
+
status: string;
|
|
1131
|
+
responseTime: string;
|
|
1132
|
+
};
|
|
1133
|
+
imap: {
|
|
1134
|
+
status: string;
|
|
1135
|
+
};
|
|
1136
|
+
smtp: {
|
|
1137
|
+
status: string;
|
|
1138
|
+
};
|
|
1139
|
+
}
|
|
1140
|
+
export interface WildduckWebhookListItem {
|
|
1141
|
+
id: string;
|
|
1142
|
+
type: string;
|
|
1143
|
+
user: string;
|
|
1144
|
+
url: string;
|
|
1145
|
+
created: string;
|
|
1146
|
+
}
|
|
1147
|
+
export interface WildduckWebhookListResponse {
|
|
1148
|
+
success: boolean;
|
|
1149
|
+
results: WildduckWebhookListItem[];
|
|
1150
|
+
}
|
|
1151
|
+
export interface WildduckCreateWebhookRequest {
|
|
1152
|
+
type: string;
|
|
1153
|
+
user: string;
|
|
1154
|
+
url: string;
|
|
1155
|
+
sess?: string;
|
|
1156
|
+
ip?: string;
|
|
1157
|
+
}
|
|
1158
|
+
export interface WildduckCreateWebhookResponse {
|
|
1159
|
+
success: boolean;
|
|
1160
|
+
id: string;
|
|
1161
|
+
}
|
|
1162
|
+
export interface WildduckCreateAuditRequest {
|
|
1163
|
+
user: string;
|
|
1164
|
+
start: string;
|
|
1165
|
+
end: string;
|
|
1166
|
+
expires?: string;
|
|
1167
|
+
sess?: string;
|
|
1168
|
+
ip?: string;
|
|
1169
|
+
}
|
|
1170
|
+
export interface WildduckCreateAuditResponse {
|
|
1171
|
+
success: boolean;
|
|
1172
|
+
id: string;
|
|
1173
|
+
}
|
|
1174
|
+
export interface WildduckAuditResponse {
|
|
1175
|
+
success: boolean;
|
|
1176
|
+
id: string;
|
|
1177
|
+
user: string;
|
|
1178
|
+
start: string;
|
|
1179
|
+
end: string;
|
|
1180
|
+
expires: string;
|
|
1181
|
+
import: {
|
|
1182
|
+
status: string;
|
|
1183
|
+
failed: number;
|
|
1184
|
+
copied: number;
|
|
1185
|
+
};
|
|
1186
|
+
}
|
|
1187
|
+
export interface WildduckDKIMListItem {
|
|
1188
|
+
id: string;
|
|
1189
|
+
domain: string;
|
|
1190
|
+
selector: string;
|
|
1191
|
+
description: string;
|
|
1192
|
+
fingerprint: string;
|
|
1193
|
+
created: string;
|
|
1194
|
+
}
|
|
1195
|
+
export interface WildduckDKIMListResponse {
|
|
1196
|
+
success: boolean;
|
|
1197
|
+
results: WildduckDKIMListItem[];
|
|
1198
|
+
}
|
|
1199
|
+
export interface WildduckCreateDKIMRequest {
|
|
1200
|
+
domain: string;
|
|
1201
|
+
selector: string;
|
|
1202
|
+
description?: string;
|
|
1203
|
+
privateKey?: string;
|
|
1204
|
+
sess?: string;
|
|
1205
|
+
ip?: string;
|
|
1206
|
+
}
|
|
1207
|
+
export interface WildduckCreateDKIMResponse {
|
|
1208
|
+
success: boolean;
|
|
1209
|
+
id: string;
|
|
1210
|
+
domain: string;
|
|
1211
|
+
selector: string;
|
|
1212
|
+
dnsTxt: {
|
|
1213
|
+
name: string;
|
|
1214
|
+
value: string;
|
|
1215
|
+
};
|
|
1216
|
+
}
|
|
1217
|
+
export interface WildduckSuccessResponse {
|
|
1218
|
+
success: boolean;
|
|
1219
|
+
}
|
|
1220
|
+
export interface WildduckDeleteResponse {
|
|
1221
|
+
success: boolean;
|
|
1222
|
+
}
|
|
1223
|
+
export interface WildduckErrorResponse {
|
|
1224
|
+
error: string;
|
|
1225
|
+
code: string;
|
|
1226
|
+
details?: unknown;
|
|
1227
|
+
}
|
|
1228
|
+
export interface WildduckPaginationParams {
|
|
1229
|
+
limit?: number;
|
|
1230
|
+
next?: string;
|
|
1231
|
+
previous?: string;
|
|
1232
|
+
page?: number;
|
|
1233
|
+
sess?: string;
|
|
1234
|
+
ip?: string;
|
|
1235
|
+
}
|
|
1236
|
+
export interface WildduckSessionParams {
|
|
1237
|
+
sess?: string;
|
|
1238
|
+
ip?: string;
|
|
1239
|
+
}
|
|
1240
|
+
export declare const isWildduckAuthResponse: (obj: unknown) => obj is WildduckAuthResponse;
|
|
1241
|
+
export declare const isWildduckMessage: (obj: unknown) => obj is WildduckMessage;
|
|
1242
|
+
//# sourceMappingURL=wildduck-types.d.ts.map
|