@proton/wrap-constants 0.0.31 → 0.0.35

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.
@@ -0,0 +1,505 @@
1
+ import * as z from 'zod';
2
+ declare const withdrawBodyBaseAction: z.ZodObject<{
3
+ account: z.ZodString | z.ZodLiteral<string>;
4
+ name: z.ZodLiteral<string>;
5
+ data: z.ZodObject<{
6
+ from: z.ZodString;
7
+ to: z.ZodLiteral<"proton.wrap">;
8
+ quantity: z.ZodString;
9
+ memo: z.ZodString;
10
+ }, {
11
+ strict: true;
12
+ }, {
13
+ from: string;
14
+ to: "proton.wrap";
15
+ quantity: string;
16
+ memo: string;
17
+ }>;
18
+ authorization: z.ZodArray<z.ZodObject<{
19
+ actor: z.ZodString;
20
+ permission: z.ZodString;
21
+ }, {
22
+ strict: true;
23
+ }, {
24
+ actor: string;
25
+ permission: string;
26
+ }>>;
27
+ }, {
28
+ strict: true;
29
+ }, {
30
+ account: string;
31
+ name: string;
32
+ data: {
33
+ from: string;
34
+ to: "proton.wrap";
35
+ quantity: string;
36
+ memo: string;
37
+ };
38
+ authorization: {
39
+ actor: string;
40
+ permission: string;
41
+ }[];
42
+ }>;
43
+ export declare type WithdrawBodyBaseAction = z.infer<typeof withdrawBodyBaseAction>;
44
+ export declare const withdrawBodyParser: z.ZodObject<{
45
+ signer: z.ZodObject<{
46
+ actor: z.ZodString;
47
+ permission: z.ZodString;
48
+ }, {
49
+ strict: true;
50
+ }, {
51
+ actor: string;
52
+ permission: string;
53
+ }>;
54
+ signatures: z.ZodArray<z.ZodString>;
55
+ transaction: z.ZodObject<{
56
+ expiration: z.ZodString;
57
+ ref_block_num: z.ZodNumber;
58
+ ref_block_prefix: z.ZodNumber;
59
+ max_net_usage_words: z.ZodNumber;
60
+ max_cpu_usage_ms: z.ZodNumber;
61
+ delay_sec: z.ZodNumber;
62
+ context_free_actions: z.ZodArray<z.ZodAny>;
63
+ transaction_extensions: z.ZodArray<z.ZodAny>;
64
+ } & {
65
+ actions: z.ZodArray<z.ZodUnion<[z.ZodObject<{
66
+ account: z.ZodString | z.ZodLiteral<string>;
67
+ name: z.ZodLiteral<string>;
68
+ data: z.ZodObject<import("zod/lib/src/types/base").ZodRawShape, {
69
+ strict: true;
70
+ }, {
71
+ [x: string]: any;
72
+ [x: number]: any;
73
+ }>;
74
+ authorization: z.ZodArray<z.ZodObject<{
75
+ actor: z.ZodString;
76
+ permission: z.ZodString;
77
+ }, {
78
+ strict: true;
79
+ }, {
80
+ actor: string;
81
+ permission: string;
82
+ }>>;
83
+ }, {
84
+ strict: true;
85
+ }, {
86
+ account: string;
87
+ name: string;
88
+ data: {
89
+ [x: string]: any;
90
+ [x: number]: any;
91
+ };
92
+ authorization: {
93
+ actor: string;
94
+ permission: string;
95
+ }[];
96
+ }>, z.ZodObject<{
97
+ account: z.ZodLiteral<"webauthn">;
98
+ name: z.ZodLiteral<"exec">;
99
+ data: z.ZodObject<{
100
+ account: z.ZodString;
101
+ key: z.ZodObject<{
102
+ key: z.ZodArray<z.ZodUnion<[z.ZodString, z.ZodObject<{
103
+ modulus: z.ZodString;
104
+ exponent: z.ZodString;
105
+ }, {
106
+ strict: true;
107
+ }, {
108
+ modulus: string;
109
+ exponent: string;
110
+ }>]>>;
111
+ user_presence: z.ZodNumber;
112
+ rpid: z.ZodString;
113
+ }, {
114
+ strict: true;
115
+ }, {
116
+ key: (string | {
117
+ modulus: string;
118
+ exponent: string;
119
+ })[];
120
+ user_presence: number;
121
+ rpid: string;
122
+ }>;
123
+ nonce: z.ZodNumber;
124
+ permissions: z.ZodArray<z.ZodObject<{
125
+ actor: z.ZodString;
126
+ permission: z.ZodString;
127
+ }, {
128
+ strict: true;
129
+ }, {
130
+ actor: string;
131
+ permission: string;
132
+ }>>;
133
+ signature: z.ZodObject<{
134
+ auth_data: z.ZodString;
135
+ client_json: z.ZodString;
136
+ signature: z.ZodString;
137
+ }, {
138
+ strict: true;
139
+ }, {
140
+ auth_data: string;
141
+ client_json: string;
142
+ signature: string;
143
+ }>;
144
+ trx: z.ZodObject<{
145
+ expiration: z.ZodString;
146
+ ref_block_num: z.ZodNumber;
147
+ ref_block_prefix: z.ZodNumber;
148
+ max_net_usage_words: z.ZodNumber;
149
+ max_cpu_usage_ms: z.ZodNumber;
150
+ delay_sec: z.ZodNumber;
151
+ context_free_actions: z.ZodArray<z.ZodAny>;
152
+ transaction_extensions: z.ZodArray<z.ZodAny>;
153
+ } & {
154
+ actions: z.ZodArray<z.ZodObject<{
155
+ account: z.ZodString | z.ZodLiteral<string>;
156
+ name: z.ZodLiteral<string>;
157
+ data: z.ZodUnion<[z.ZodString, z.ZodObject<import("zod/lib/src/types/base").ZodRawShape, {
158
+ strict: true;
159
+ }, {
160
+ [x: string]: any;
161
+ [x: number]: any;
162
+ }>]>;
163
+ authorization: z.ZodArray<z.ZodObject<{
164
+ actor: z.ZodString;
165
+ permission: z.ZodString;
166
+ }, {
167
+ strict: true;
168
+ }, {
169
+ actor: string;
170
+ permission: string;
171
+ }>>;
172
+ }, {
173
+ strict: true;
174
+ }, {
175
+ account: string;
176
+ name: string;
177
+ data: string | {
178
+ [x: string]: any;
179
+ [x: number]: any;
180
+ };
181
+ authorization: {
182
+ actor: string;
183
+ permission: string;
184
+ }[];
185
+ }>>;
186
+ }, import("zod/lib/src/helpers/objectUtil").objectUtil.MergeObjectParams<{
187
+ strict: true;
188
+ }, {
189
+ strict: true;
190
+ }>, {
191
+ expiration: string;
192
+ ref_block_num: number;
193
+ ref_block_prefix: number;
194
+ max_net_usage_words: number;
195
+ max_cpu_usage_ms: number;
196
+ delay_sec: number;
197
+ context_free_actions: any[];
198
+ transaction_extensions: any[];
199
+ actions: {
200
+ account: string;
201
+ name: string;
202
+ data: string | {
203
+ [x: string]: any;
204
+ [x: number]: any;
205
+ };
206
+ authorization: {
207
+ actor: string;
208
+ permission: string;
209
+ }[];
210
+ }[];
211
+ }>;
212
+ }, {
213
+ strict: true;
214
+ }, {
215
+ account: string;
216
+ key: {
217
+ key: (string | {
218
+ modulus: string;
219
+ exponent: string;
220
+ })[];
221
+ user_presence: number;
222
+ rpid: string;
223
+ };
224
+ signature: {
225
+ auth_data: string;
226
+ client_json: string;
227
+ signature: string;
228
+ };
229
+ nonce: number;
230
+ permissions: {
231
+ actor: string;
232
+ permission: string;
233
+ }[];
234
+ trx: {
235
+ expiration: string;
236
+ ref_block_num: number;
237
+ ref_block_prefix: number;
238
+ max_net_usage_words: number;
239
+ max_cpu_usage_ms: number;
240
+ delay_sec: number;
241
+ context_free_actions: any[];
242
+ transaction_extensions: any[];
243
+ actions: {
244
+ account: string;
245
+ name: string;
246
+ data: string | {
247
+ [x: string]: any;
248
+ [x: number]: any;
249
+ };
250
+ authorization: {
251
+ actor: string;
252
+ permission: string;
253
+ }[];
254
+ }[];
255
+ };
256
+ }>;
257
+ authorization: z.ZodArray<z.ZodObject<{
258
+ actor: z.ZodString;
259
+ permission: z.ZodString;
260
+ }, {
261
+ strict: true;
262
+ }, {
263
+ actor: string;
264
+ permission: string;
265
+ }>>;
266
+ }, {
267
+ strict: true;
268
+ }, {
269
+ account: "webauthn";
270
+ name: "exec";
271
+ data: {
272
+ account: string;
273
+ key: {
274
+ key: (string | {
275
+ modulus: string;
276
+ exponent: string;
277
+ })[];
278
+ user_presence: number;
279
+ rpid: string;
280
+ };
281
+ signature: {
282
+ auth_data: string;
283
+ client_json: string;
284
+ signature: string;
285
+ };
286
+ nonce: number;
287
+ permissions: {
288
+ actor: string;
289
+ permission: string;
290
+ }[];
291
+ trx: {
292
+ expiration: string;
293
+ ref_block_num: number;
294
+ ref_block_prefix: number;
295
+ max_net_usage_words: number;
296
+ max_cpu_usage_ms: number;
297
+ delay_sec: number;
298
+ context_free_actions: any[];
299
+ transaction_extensions: any[];
300
+ actions: {
301
+ account: string;
302
+ name: string;
303
+ data: string | {
304
+ [x: string]: any;
305
+ [x: number]: any;
306
+ };
307
+ authorization: {
308
+ actor: string;
309
+ permission: string;
310
+ }[];
311
+ }[];
312
+ };
313
+ };
314
+ authorization: {
315
+ actor: string;
316
+ permission: string;
317
+ }[];
318
+ }>]>>;
319
+ }, import("zod/lib/src/helpers/objectUtil").objectUtil.MergeObjectParams<{
320
+ strict: true;
321
+ }, {
322
+ strict: true;
323
+ }>, {
324
+ expiration: string;
325
+ ref_block_num: number;
326
+ ref_block_prefix: number;
327
+ max_net_usage_words: number;
328
+ max_cpu_usage_ms: number;
329
+ delay_sec: number;
330
+ context_free_actions: any[];
331
+ transaction_extensions: any[];
332
+ actions: ({
333
+ account: string;
334
+ name: string;
335
+ data: {
336
+ [x: string]: any;
337
+ [x: number]: any;
338
+ };
339
+ authorization: {
340
+ actor: string;
341
+ permission: string;
342
+ }[];
343
+ } | {
344
+ account: "webauthn";
345
+ name: "exec";
346
+ data: {
347
+ account: string;
348
+ key: {
349
+ key: (string | {
350
+ modulus: string;
351
+ exponent: string;
352
+ })[];
353
+ user_presence: number;
354
+ rpid: string;
355
+ };
356
+ signature: {
357
+ auth_data: string;
358
+ client_json: string;
359
+ signature: string;
360
+ };
361
+ nonce: number;
362
+ permissions: {
363
+ actor: string;
364
+ permission: string;
365
+ }[];
366
+ trx: {
367
+ expiration: string;
368
+ ref_block_num: number;
369
+ ref_block_prefix: number;
370
+ max_net_usage_words: number;
371
+ max_cpu_usage_ms: number;
372
+ delay_sec: number;
373
+ context_free_actions: any[];
374
+ transaction_extensions: any[];
375
+ actions: {
376
+ account: string;
377
+ name: string;
378
+ data: string | {
379
+ [x: string]: any;
380
+ [x: number]: any;
381
+ };
382
+ authorization: {
383
+ actor: string;
384
+ permission: string;
385
+ }[];
386
+ }[];
387
+ };
388
+ };
389
+ authorization: {
390
+ actor: string;
391
+ permission: string;
392
+ }[];
393
+ })[];
394
+ }>;
395
+ quoteId: z.ZodString;
396
+ provider: z.ZodUnion<[z.ZodString, z.ZodUndefined]>;
397
+ }, {
398
+ strict: true;
399
+ }, {
400
+ provider?: string | undefined;
401
+ signer: {
402
+ actor: string;
403
+ permission: string;
404
+ };
405
+ signatures: string[];
406
+ transaction: {
407
+ expiration: string;
408
+ ref_block_num: number;
409
+ ref_block_prefix: number;
410
+ max_net_usage_words: number;
411
+ max_cpu_usage_ms: number;
412
+ delay_sec: number;
413
+ context_free_actions: any[];
414
+ transaction_extensions: any[];
415
+ actions: ({
416
+ account: string;
417
+ name: string;
418
+ data: {
419
+ [x: string]: any;
420
+ [x: number]: any;
421
+ };
422
+ authorization: {
423
+ actor: string;
424
+ permission: string;
425
+ }[];
426
+ } | {
427
+ account: "webauthn";
428
+ name: "exec";
429
+ data: {
430
+ account: string;
431
+ key: {
432
+ key: (string | {
433
+ modulus: string;
434
+ exponent: string;
435
+ })[];
436
+ user_presence: number;
437
+ rpid: string;
438
+ };
439
+ signature: {
440
+ auth_data: string;
441
+ client_json: string;
442
+ signature: string;
443
+ };
444
+ nonce: number;
445
+ permissions: {
446
+ actor: string;
447
+ permission: string;
448
+ }[];
449
+ trx: {
450
+ expiration: string;
451
+ ref_block_num: number;
452
+ ref_block_prefix: number;
453
+ max_net_usage_words: number;
454
+ max_cpu_usage_ms: number;
455
+ delay_sec: number;
456
+ context_free_actions: any[];
457
+ transaction_extensions: any[];
458
+ actions: {
459
+ account: string;
460
+ name: string;
461
+ data: string | {
462
+ [x: string]: any;
463
+ [x: number]: any;
464
+ };
465
+ authorization: {
466
+ actor: string;
467
+ permission: string;
468
+ }[];
469
+ }[];
470
+ };
471
+ };
472
+ authorization: {
473
+ actor: string;
474
+ permission: string;
475
+ }[];
476
+ })[];
477
+ };
478
+ quoteId: string;
479
+ }>;
480
+ export declare type WithdrawBody = z.infer<typeof withdrawBodyParser>;
481
+ export declare const withdrawMetalResponseParser: z.ZodObject<{
482
+ success: z.ZodBoolean;
483
+ id: z.ZodString;
484
+ }, {
485
+ strict: true;
486
+ }, {
487
+ success: boolean;
488
+ id: string;
489
+ }>;
490
+ export declare type WithdrawMetalResponse = z.infer<typeof withdrawMetalResponseParser>;
491
+ export declare const withdrawalFeeQuoteParser: z.ZodObject<{
492
+ quoteId: z.ZodString;
493
+ estimatedFee: z.ZodString;
494
+ currency: z.ZodString;
495
+ network: z.ZodString;
496
+ }, {
497
+ strict: true;
498
+ }, {
499
+ quoteId: string;
500
+ estimatedFee: string;
501
+ currency: string;
502
+ network: string;
503
+ }>;
504
+ export declare type WithdrawalFeeQuote = z.infer<typeof withdrawalFeeQuoteParser>;
505
+ export {};
@@ -0,0 +1,70 @@
1
+ import * as z from 'zod';
2
+ export declare const withdrawHistoryMetalSwapParser: z.ZodObject<{
3
+ id: z.ZodString;
4
+ status: z.ZodString;
5
+ amount: z.ZodString;
6
+ currency: z.ZodString;
7
+ network: z.ZodString;
8
+ created: z.ZodString;
9
+ withdrawalAddress: z.ZodString;
10
+ withdrawalHash: z.ZodUnion<[z.ZodString, z.ZodUndefined]>;
11
+ }, {
12
+ strict: true;
13
+ }, {
14
+ withdrawalHash?: string | undefined;
15
+ id: string;
16
+ status: string;
17
+ amount: string;
18
+ currency: string;
19
+ network: string;
20
+ created: string;
21
+ withdrawalAddress: string;
22
+ }>;
23
+ export declare type WithdrawHistoryMetalSwap = z.infer<typeof withdrawHistoryMetalSwapParser>;
24
+ export declare const withdrawHistoryMetalResponseParser: z.ZodObject<{
25
+ swaps: z.ZodArray<z.ZodObject<{
26
+ id: z.ZodString;
27
+ status: z.ZodString;
28
+ amount: z.ZodString;
29
+ currency: z.ZodString;
30
+ network: z.ZodString;
31
+ created: z.ZodString;
32
+ withdrawalAddress: z.ZodString;
33
+ withdrawalHash: z.ZodUnion<[z.ZodString, z.ZodUndefined]>;
34
+ }, {
35
+ strict: true;
36
+ }, {
37
+ withdrawalHash?: string | undefined;
38
+ id: string;
39
+ status: string;
40
+ amount: string;
41
+ currency: string;
42
+ network: string;
43
+ created: string;
44
+ withdrawalAddress: string;
45
+ }>>;
46
+ page: z.ZodNumber;
47
+ pageSize: z.ZodNumber;
48
+ numberOfElements: z.ZodNumber;
49
+ totalPages: z.ZodNumber;
50
+ totalElements: z.ZodNumber;
51
+ }, {
52
+ strict: true;
53
+ }, {
54
+ swaps: {
55
+ withdrawalHash?: string | undefined;
56
+ id: string;
57
+ status: string;
58
+ amount: string;
59
+ currency: string;
60
+ network: string;
61
+ created: string;
62
+ withdrawalAddress: string;
63
+ }[];
64
+ page: number;
65
+ pageSize: number;
66
+ numberOfElements: number;
67
+ totalPages: number;
68
+ totalElements: number;
69
+ }>;
70
+ export declare type WithdrawHistoryMetalResponse = z.infer<typeof withdrawHistoryMetalResponseParser>;
@@ -0,0 +1,85 @@
1
+ import * as z from 'zod';
2
+ export declare enum Status {
3
+ PENDING = "pending",
4
+ SUCCESS = "success",
5
+ FAIL = "fail",
6
+ PROCESSING = "processing"
7
+ }
8
+ export declare const wrapStartParser: z.ZodObject<{
9
+ balance: z.ZodObject<{
10
+ quantity: z.ZodString;
11
+ contract: z.ZodString;
12
+ }, {
13
+ strict: true;
14
+ }, {
15
+ quantity: string;
16
+ contract: string;
17
+ }>;
18
+ id: z.ZodString;
19
+ txid: z.ZodString;
20
+ chain: z.ZodString;
21
+ deposit_address: z.ZodString;
22
+ confirmations: z.ZodNumber;
23
+ }, {
24
+ strict: true;
25
+ }, {
26
+ balance: {
27
+ quantity: string;
28
+ contract: string;
29
+ };
30
+ id: string;
31
+ txid: string;
32
+ chain: string;
33
+ deposit_address: string;
34
+ confirmations: number;
35
+ }>;
36
+ export declare type WrapStart = z.infer<typeof wrapStartParser>;
37
+ export declare const wrapSetConfParser: z.ZodObject<{
38
+ wrap_hash: z.ZodString;
39
+ confirmations: z.ZodNumber;
40
+ }, {
41
+ strict: true;
42
+ }, {
43
+ confirmations: number;
44
+ wrap_hash: string;
45
+ }>;
46
+ export declare type WrapSetConf = z.infer<typeof wrapSetConfParser>;
47
+ export declare const wrapParser: z.ZodObject<{
48
+ index: z.ZodNumber;
49
+ proton_account: z.ZodString;
50
+ balance: z.ZodObject<{
51
+ quantity: z.ZodString;
52
+ contract: z.ZodString;
53
+ }, {
54
+ strict: true;
55
+ }, {
56
+ quantity: string;
57
+ contract: string;
58
+ }>;
59
+ id: z.ZodString;
60
+ txid: z.ZodString;
61
+ chain: z.ZodString;
62
+ deposit_address: z.ZodString;
63
+ status: z.ZodNativeEnum<typeof Status>;
64
+ finish_txid: z.ZodString;
65
+ wrap_hash: z.ZodString;
66
+ confirmations: z.ZodNumber;
67
+ }, {
68
+ strict: true;
69
+ }, {
70
+ balance: {
71
+ quantity: string;
72
+ contract: string;
73
+ };
74
+ id: string;
75
+ txid: string;
76
+ chain: string;
77
+ deposit_address: string;
78
+ confirmations: number;
79
+ wrap_hash: string;
80
+ index: number;
81
+ proton_account: string;
82
+ status: Status;
83
+ finish_txid: string;
84
+ }>;
85
+ export declare type Wrap = z.infer<typeof wrapParser>;