@dfns/sdk 0.2.5 → 0.3.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.
@@ -1,133 +1,118 @@
1
1
  export type ArchivePolicyParams = {
2
2
  policyId: string;
3
3
  };
4
- export type ArchivePolicyResponse = {
5
- id: string;
6
- orgId: string;
7
- requester: {
8
- userId: string;
9
- tokenId: string;
10
- appId: string;
11
- };
12
- kind: "Policy";
13
- operationKind: "Create" | "Update" | "Delete";
14
- status: "Applied" | "Failed" | "Pending" | "Rejected";
15
- entityId: string;
16
- body: ({
17
- name: string;
18
- approvalGroups: {
19
- name?: string | undefined;
20
- quorum: number;
21
- approvers?: {
22
- [x: string]: {
23
- [x: string]: string[];
24
- };
25
- } | undefined;
26
- }[];
27
- autoRejectTimeout?: number | undefined;
28
- activityKind: "Permissions:Assign";
29
- rule: {
30
- kind: "AlwaysRequireApproval";
31
- configuration: {};
32
- };
33
- filters?: {
4
+ export type ArchivePolicyResponse = ({
5
+ name: string;
6
+ approvalGroups: {
7
+ name?: string | undefined;
8
+ quorum: number;
9
+ approvers: {
34
10
  [x: string]: {
35
11
  [x: string]: string[];
36
12
  };
37
- } | undefined;
38
- } | {
39
- name: string;
40
- approvalGroups: {
41
- name?: string | undefined;
42
- quorum: number;
43
- approvers?: {
44
- [x: string]: {
45
- [x: string]: string[];
46
- };
47
- } | undefined;
48
- }[];
49
- autoRejectTimeout?: number | undefined;
50
- activityKind: "Permissions:Modify";
51
- rule: {
52
- kind: "AlwaysRequireApproval";
53
- configuration: {};
54
13
  };
55
- filters?: {
14
+ }[];
15
+ autoRejectTimeout?: (number | undefined) | null;
16
+ activityKind: "Permissions:Assign";
17
+ rule: {
18
+ kind: "AlwaysRequireApproval";
19
+ configuration: {};
20
+ };
21
+ filters?: {
22
+ [x: string]: {
23
+ [x: string]: string[];
24
+ };
25
+ } | undefined;
26
+ } | {
27
+ name: string;
28
+ approvalGroups: {
29
+ name?: string | undefined;
30
+ quorum: number;
31
+ approvers: {
56
32
  [x: string]: {
57
33
  [x: string]: string[];
58
34
  };
59
- } | undefined;
60
- } | {
61
- name: string;
62
- approvalGroups: {
63
- name?: string | undefined;
64
- quorum: number;
65
- approvers?: {
66
- [x: string]: {
67
- [x: string]: string[];
68
- };
69
- } | undefined;
70
- }[];
71
- autoRejectTimeout?: number | undefined;
72
- activityKind: "Policies:Modify";
73
- rule: {
74
- kind: "AlwaysRequireApproval";
75
- configuration: {};
76
35
  };
77
- filters?: {
36
+ }[];
37
+ autoRejectTimeout?: (number | undefined) | null;
38
+ activityKind: "Permissions:Modify";
39
+ rule: {
40
+ kind: "AlwaysRequireApproval";
41
+ configuration: {};
42
+ };
43
+ filters?: {
44
+ [x: string]: {
45
+ [x: string]: string[];
46
+ };
47
+ } | undefined;
48
+ } | {
49
+ name: string;
50
+ approvalGroups: {
51
+ name?: string | undefined;
52
+ quorum: number;
53
+ approvers: {
78
54
  [x: string]: {
79
55
  [x: string]: string[];
80
56
  };
81
- } | undefined;
82
- } | {
83
- name: string;
84
- approvalGroups: {
85
- name?: string | undefined;
86
- quorum: number;
87
- approvers?: {
88
- [x: string]: {
89
- [x: string]: string[];
90
- };
91
- } | undefined;
92
- }[];
93
- autoRejectTimeout?: number | undefined;
94
- activityKind: "Wallets:Sign";
95
- rule: {
96
- kind: "AlwaysRequireApproval";
97
- configuration: {};
98
- } | {
99
- kind: "TransactionAmountLimit";
100
- configuration: {
101
- limit: number;
102
- currency: "EUR" | "USD";
103
- };
104
- } | {
105
- kind: "TransactionAmountVelocity";
106
- configuration: {
107
- limit: number;
108
- currency: "EUR" | "USD";
109
- timeframe: number;
110
- };
111
- } | {
112
- kind: "TransactionCountVelocity";
113
- configuration: {
114
- limit: number;
115
- timeframe: number;
116
- };
117
57
  };
118
- filters?: {
58
+ }[];
59
+ autoRejectTimeout?: (number | undefined) | null;
60
+ activityKind: "Policies:Modify";
61
+ rule: {
62
+ kind: "AlwaysRequireApproval";
63
+ configuration: {};
64
+ };
65
+ filters?: {
66
+ [x: string]: {
67
+ [x: string]: string[];
68
+ };
69
+ } | undefined;
70
+ } | {
71
+ name: string;
72
+ approvalGroups: {
73
+ name?: string | undefined;
74
+ quorum: number;
75
+ approvers: {
119
76
  [x: string]: {
120
77
  [x: string]: string[];
121
78
  };
122
- } | undefined;
123
- }) & {
124
- id: string;
125
- status: "Active" | "Archived";
126
- dateCreated?: string | undefined;
127
- dateUpdated?: string | undefined;
79
+ };
80
+ }[];
81
+ autoRejectTimeout?: (number | undefined) | null;
82
+ activityKind: "Wallets:Sign";
83
+ rule: {
84
+ kind: "AlwaysRequireApproval";
85
+ configuration: {};
86
+ } | {
87
+ kind: "TransactionAmountLimit";
88
+ configuration: {
89
+ limit: number;
90
+ currency: "EUR" | "USD";
91
+ };
92
+ } | {
93
+ kind: "TransactionAmountVelocity";
94
+ configuration: {
95
+ limit: number;
96
+ currency: "EUR" | "USD";
97
+ timeframe: number;
98
+ };
99
+ } | {
100
+ kind: "TransactionCountVelocity";
101
+ configuration: {
102
+ limit: number;
103
+ timeframe: number;
104
+ };
128
105
  };
129
- dateCreated: Date;
130
- dateResolved: Date;
106
+ filters?: {
107
+ [x: string]: {
108
+ [x: string]: string[];
109
+ };
110
+ } | undefined;
111
+ }) & {
112
+ id: string;
113
+ status: "Active" | "Archived";
114
+ dateCreated?: string | undefined;
115
+ dateUpdated?: string | undefined;
131
116
  };
132
117
  export type ArchivePolicyRequest = ArchivePolicyParams;
133
118
  export type CreateApprovalDecisionBody = {
@@ -136,10 +121,9 @@ export type CreateApprovalDecisionBody = {
136
121
  };
137
122
  export type CreateApprovalDecisionResponse = {
138
123
  id: string;
139
- orgId: string;
140
124
  initiatorId: string;
141
125
  activityId: string;
142
- activityKind: string;
126
+ activityKind: "Permissions:Assign" | "Permissions:Modify" | "Policies:Modify" | "Wallets:Sign";
143
127
  activity: {
144
128
  [x: string]: unknown;
145
129
  };
@@ -168,13 +152,13 @@ export type CreatePolicyBody = {
168
152
  approvalGroups: {
169
153
  name?: string | undefined;
170
154
  quorum: number;
171
- approvers?: {
155
+ approvers: {
172
156
  [x: string]: {
173
157
  [x: string]: string[];
174
158
  };
175
- } | undefined;
159
+ };
176
160
  }[];
177
- autoRejectTimeout?: number | undefined;
161
+ autoRejectTimeout?: (number | undefined) | null;
178
162
  activityKind: "Permissions:Assign";
179
163
  rule: {
180
164
  kind: "AlwaysRequireApproval";
@@ -190,13 +174,13 @@ export type CreatePolicyBody = {
190
174
  approvalGroups: {
191
175
  name?: string | undefined;
192
176
  quorum: number;
193
- approvers?: {
177
+ approvers: {
194
178
  [x: string]: {
195
179
  [x: string]: string[];
196
180
  };
197
- } | undefined;
181
+ };
198
182
  }[];
199
- autoRejectTimeout?: number | undefined;
183
+ autoRejectTimeout?: (number | undefined) | null;
200
184
  activityKind: "Permissions:Modify";
201
185
  rule: {
202
186
  kind: "AlwaysRequireApproval";
@@ -212,13 +196,13 @@ export type CreatePolicyBody = {
212
196
  approvalGroups: {
213
197
  name?: string | undefined;
214
198
  quorum: number;
215
- approvers?: {
199
+ approvers: {
216
200
  [x: string]: {
217
201
  [x: string]: string[];
218
202
  };
219
- } | undefined;
203
+ };
220
204
  }[];
221
- autoRejectTimeout?: number | undefined;
205
+ autoRejectTimeout?: (number | undefined) | null;
222
206
  activityKind: "Policies:Modify";
223
207
  rule: {
224
208
  kind: "AlwaysRequireApproval";
@@ -234,13 +218,13 @@ export type CreatePolicyBody = {
234
218
  approvalGroups: {
235
219
  name?: string | undefined;
236
220
  quorum: number;
237
- approvers?: {
221
+ approvers: {
238
222
  [x: string]: {
239
223
  [x: string]: string[];
240
224
  };
241
- } | undefined;
225
+ };
242
226
  }[];
243
- autoRejectTimeout?: number | undefined;
227
+ autoRejectTimeout?: (number | undefined) | null;
244
228
  activityKind: "Wallets:Sign";
245
229
  rule: {
246
230
  kind: "AlwaysRequireApproval";
@@ -271,133 +255,118 @@ export type CreatePolicyBody = {
271
255
  };
272
256
  } | undefined;
273
257
  };
274
- export type CreatePolicyResponse = {
275
- id: string;
276
- orgId: string;
277
- requester: {
278
- userId: string;
279
- tokenId: string;
280
- appId: string;
281
- };
282
- kind: "Policy";
283
- operationKind: "Create" | "Update" | "Delete";
284
- status: "Applied" | "Failed" | "Pending" | "Rejected";
285
- entityId: string;
286
- body: ({
287
- name: string;
288
- approvalGroups: {
289
- name?: string | undefined;
290
- quorum: number;
291
- approvers?: {
292
- [x: string]: {
293
- [x: string]: string[];
294
- };
295
- } | undefined;
296
- }[];
297
- autoRejectTimeout?: number | undefined;
298
- activityKind: "Permissions:Assign";
299
- rule: {
300
- kind: "AlwaysRequireApproval";
301
- configuration: {};
302
- };
303
- filters?: {
258
+ export type CreatePolicyResponse = ({
259
+ name: string;
260
+ approvalGroups: {
261
+ name?: string | undefined;
262
+ quorum: number;
263
+ approvers: {
304
264
  [x: string]: {
305
265
  [x: string]: string[];
306
266
  };
307
- } | undefined;
308
- } | {
309
- name: string;
310
- approvalGroups: {
311
- name?: string | undefined;
312
- quorum: number;
313
- approvers?: {
314
- [x: string]: {
315
- [x: string]: string[];
316
- };
317
- } | undefined;
318
- }[];
319
- autoRejectTimeout?: number | undefined;
320
- activityKind: "Permissions:Modify";
321
- rule: {
322
- kind: "AlwaysRequireApproval";
323
- configuration: {};
324
267
  };
325
- filters?: {
326
- [x: string]: {
327
- [x: string]: string[];
328
- };
329
- } | undefined;
330
- } | {
331
- name: string;
332
- approvalGroups: {
333
- name?: string | undefined;
334
- quorum: number;
335
- approvers?: {
336
- [x: string]: {
337
- [x: string]: string[];
338
- };
339
- } | undefined;
340
- }[];
341
- autoRejectTimeout?: number | undefined;
342
- activityKind: "Policies:Modify";
343
- rule: {
344
- kind: "AlwaysRequireApproval";
345
- configuration: {};
268
+ }[];
269
+ autoRejectTimeout?: (number | undefined) | null;
270
+ activityKind: "Permissions:Assign";
271
+ rule: {
272
+ kind: "AlwaysRequireApproval";
273
+ configuration: {};
274
+ };
275
+ filters?: {
276
+ [x: string]: {
277
+ [x: string]: string[];
346
278
  };
347
- filters?: {
279
+ } | undefined;
280
+ } | {
281
+ name: string;
282
+ approvalGroups: {
283
+ name?: string | undefined;
284
+ quorum: number;
285
+ approvers: {
348
286
  [x: string]: {
349
287
  [x: string]: string[];
350
288
  };
351
- } | undefined;
352
- } | {
353
- name: string;
354
- approvalGroups: {
355
- name?: string | undefined;
356
- quorum: number;
357
- approvers?: {
358
- [x: string]: {
359
- [x: string]: string[];
360
- };
361
- } | undefined;
362
- }[];
363
- autoRejectTimeout?: number | undefined;
364
- activityKind: "Wallets:Sign";
365
- rule: {
366
- kind: "AlwaysRequireApproval";
367
- configuration: {};
368
- } | {
369
- kind: "TransactionAmountLimit";
370
- configuration: {
371
- limit: number;
372
- currency: "EUR" | "USD";
373
- };
374
- } | {
375
- kind: "TransactionAmountVelocity";
376
- configuration: {
377
- limit: number;
378
- currency: "EUR" | "USD";
379
- timeframe: number;
380
- };
381
- } | {
382
- kind: "TransactionCountVelocity";
383
- configuration: {
384
- limit: number;
385
- timeframe: number;
289
+ };
290
+ }[];
291
+ autoRejectTimeout?: (number | undefined) | null;
292
+ activityKind: "Permissions:Modify";
293
+ rule: {
294
+ kind: "AlwaysRequireApproval";
295
+ configuration: {};
296
+ };
297
+ filters?: {
298
+ [x: string]: {
299
+ [x: string]: string[];
300
+ };
301
+ } | undefined;
302
+ } | {
303
+ name: string;
304
+ approvalGroups: {
305
+ name?: string | undefined;
306
+ quorum: number;
307
+ approvers: {
308
+ [x: string]: {
309
+ [x: string]: string[];
386
310
  };
387
311
  };
388
- filters?: {
312
+ }[];
313
+ autoRejectTimeout?: (number | undefined) | null;
314
+ activityKind: "Policies:Modify";
315
+ rule: {
316
+ kind: "AlwaysRequireApproval";
317
+ configuration: {};
318
+ };
319
+ filters?: {
320
+ [x: string]: {
321
+ [x: string]: string[];
322
+ };
323
+ } | undefined;
324
+ } | {
325
+ name: string;
326
+ approvalGroups: {
327
+ name?: string | undefined;
328
+ quorum: number;
329
+ approvers: {
389
330
  [x: string]: {
390
331
  [x: string]: string[];
391
332
  };
392
- } | undefined;
393
- }) & {
394
- id: string;
395
- status: "Active" | "Archived";
396
- dateCreated?: string | undefined;
397
- dateUpdated?: string | undefined;
333
+ };
334
+ }[];
335
+ autoRejectTimeout?: (number | undefined) | null;
336
+ activityKind: "Wallets:Sign";
337
+ rule: {
338
+ kind: "AlwaysRequireApproval";
339
+ configuration: {};
340
+ } | {
341
+ kind: "TransactionAmountLimit";
342
+ configuration: {
343
+ limit: number;
344
+ currency: "EUR" | "USD";
345
+ };
346
+ } | {
347
+ kind: "TransactionAmountVelocity";
348
+ configuration: {
349
+ limit: number;
350
+ currency: "EUR" | "USD";
351
+ timeframe: number;
352
+ };
353
+ } | {
354
+ kind: "TransactionCountVelocity";
355
+ configuration: {
356
+ limit: number;
357
+ timeframe: number;
358
+ };
398
359
  };
399
- dateCreated: Date;
400
- dateResolved: Date;
360
+ filters?: {
361
+ [x: string]: {
362
+ [x: string]: string[];
363
+ };
364
+ } | undefined;
365
+ }) & {
366
+ id: string;
367
+ status: "Active" | "Archived";
368
+ dateCreated?: string | undefined;
369
+ dateUpdated?: string | undefined;
401
370
  };
402
371
  export type CreatePolicyRequest = {
403
372
  body: CreatePolicyBody;
@@ -410,13 +379,13 @@ export type GetPolicyResponse = ({
410
379
  approvalGroups: {
411
380
  name?: string | undefined;
412
381
  quorum: number;
413
- approvers?: {
382
+ approvers: {
414
383
  [x: string]: {
415
384
  [x: string]: string[];
416
385
  };
417
- } | undefined;
386
+ };
418
387
  }[];
419
- autoRejectTimeout?: number | undefined;
388
+ autoRejectTimeout?: (number | undefined) | null;
420
389
  activityKind: "Permissions:Assign";
421
390
  rule: {
422
391
  kind: "AlwaysRequireApproval";
@@ -432,13 +401,13 @@ export type GetPolicyResponse = ({
432
401
  approvalGroups: {
433
402
  name?: string | undefined;
434
403
  quorum: number;
435
- approvers?: {
404
+ approvers: {
436
405
  [x: string]: {
437
406
  [x: string]: string[];
438
407
  };
439
- } | undefined;
408
+ };
440
409
  }[];
441
- autoRejectTimeout?: number | undefined;
410
+ autoRejectTimeout?: (number | undefined) | null;
442
411
  activityKind: "Permissions:Modify";
443
412
  rule: {
444
413
  kind: "AlwaysRequireApproval";
@@ -454,13 +423,13 @@ export type GetPolicyResponse = ({
454
423
  approvalGroups: {
455
424
  name?: string | undefined;
456
425
  quorum: number;
457
- approvers?: {
426
+ approvers: {
458
427
  [x: string]: {
459
428
  [x: string]: string[];
460
429
  };
461
- } | undefined;
430
+ };
462
431
  }[];
463
- autoRejectTimeout?: number | undefined;
432
+ autoRejectTimeout?: (number | undefined) | null;
464
433
  activityKind: "Policies:Modify";
465
434
  rule: {
466
435
  kind: "AlwaysRequireApproval";
@@ -476,13 +445,13 @@ export type GetPolicyResponse = ({
476
445
  approvalGroups: {
477
446
  name?: string | undefined;
478
447
  quorum: number;
479
- approvers?: {
448
+ approvers: {
480
449
  [x: string]: {
481
450
  [x: string]: string[];
482
451
  };
483
- } | undefined;
452
+ };
484
453
  }[];
485
- autoRejectTimeout?: number | undefined;
454
+ autoRejectTimeout?: (number | undefined) | null;
486
455
  activityKind: "Wallets:Sign";
487
456
  rule: {
488
457
  kind: "AlwaysRequireApproval";
@@ -530,10 +499,9 @@ export type ListApprovalsQuery = {
530
499
  export type ListApprovalsResponse = {
531
500
  items: {
532
501
  id: string;
533
- orgId: string;
534
502
  initiatorId: string;
535
503
  activityId: string;
536
- activityKind: string;
504
+ activityKind: "Permissions:Assign" | "Permissions:Modify" | "Policies:Modify" | "Wallets:Sign";
537
505
  activity: {
538
506
  [x: string]: unknown;
539
507
  };
@@ -569,13 +537,13 @@ export type ListPoliciesResponse = {
569
537
  approvalGroups: {
570
538
  name?: string | undefined;
571
539
  quorum: number;
572
- approvers?: {
540
+ approvers: {
573
541
  [x: string]: {
574
542
  [x: string]: string[];
575
543
  };
576
- } | undefined;
544
+ };
577
545
  }[];
578
- autoRejectTimeout?: number | undefined;
546
+ autoRejectTimeout?: (number | undefined) | null;
579
547
  activityKind: "Permissions:Assign";
580
548
  rule: {
581
549
  kind: "AlwaysRequireApproval";
@@ -591,13 +559,13 @@ export type ListPoliciesResponse = {
591
559
  approvalGroups: {
592
560
  name?: string | undefined;
593
561
  quorum: number;
594
- approvers?: {
562
+ approvers: {
595
563
  [x: string]: {
596
564
  [x: string]: string[];
597
565
  };
598
- } | undefined;
566
+ };
599
567
  }[];
600
- autoRejectTimeout?: number | undefined;
568
+ autoRejectTimeout?: (number | undefined) | null;
601
569
  activityKind: "Permissions:Modify";
602
570
  rule: {
603
571
  kind: "AlwaysRequireApproval";
@@ -613,13 +581,13 @@ export type ListPoliciesResponse = {
613
581
  approvalGroups: {
614
582
  name?: string | undefined;
615
583
  quorum: number;
616
- approvers?: {
584
+ approvers: {
617
585
  [x: string]: {
618
586
  [x: string]: string[];
619
587
  };
620
- } | undefined;
588
+ };
621
589
  }[];
622
- autoRejectTimeout?: number | undefined;
590
+ autoRejectTimeout?: (number | undefined) | null;
623
591
  activityKind: "Policies:Modify";
624
592
  rule: {
625
593
  kind: "AlwaysRequireApproval";
@@ -635,13 +603,13 @@ export type ListPoliciesResponse = {
635
603
  approvalGroups: {
636
604
  name?: string | undefined;
637
605
  quorum: number;
638
- approvers?: {
606
+ approvers: {
639
607
  [x: string]: {
640
608
  [x: string]: string[];
641
609
  };
642
- } | undefined;
610
+ };
643
611
  }[];
644
- autoRejectTimeout?: number | undefined;
612
+ autoRejectTimeout?: (number | undefined) | null;
645
613
  activityKind: "Wallets:Sign";
646
614
  rule: {
647
615
  kind: "AlwaysRequireApproval";
@@ -687,13 +655,13 @@ export type UpdatePolicyBody = {
687
655
  approvalGroups: {
688
656
  name?: string | undefined;
689
657
  quorum: number;
690
- approvers?: {
658
+ approvers: {
691
659
  [x: string]: {
692
660
  [x: string]: string[];
693
661
  };
694
- } | undefined;
662
+ };
695
663
  }[];
696
- autoRejectTimeout?: number | undefined;
664
+ autoRejectTimeout?: (number | undefined) | null;
697
665
  activityKind: "Permissions:Assign";
698
666
  rule: {
699
667
  kind: "AlwaysRequireApproval";
@@ -709,13 +677,13 @@ export type UpdatePolicyBody = {
709
677
  approvalGroups: {
710
678
  name?: string | undefined;
711
679
  quorum: number;
712
- approvers?: {
680
+ approvers: {
713
681
  [x: string]: {
714
682
  [x: string]: string[];
715
683
  };
716
- } | undefined;
684
+ };
717
685
  }[];
718
- autoRejectTimeout?: number | undefined;
686
+ autoRejectTimeout?: (number | undefined) | null;
719
687
  activityKind: "Permissions:Modify";
720
688
  rule: {
721
689
  kind: "AlwaysRequireApproval";
@@ -731,13 +699,13 @@ export type UpdatePolicyBody = {
731
699
  approvalGroups: {
732
700
  name?: string | undefined;
733
701
  quorum: number;
734
- approvers?: {
702
+ approvers: {
735
703
  [x: string]: {
736
704
  [x: string]: string[];
737
705
  };
738
- } | undefined;
706
+ };
739
707
  }[];
740
- autoRejectTimeout?: number | undefined;
708
+ autoRejectTimeout?: (number | undefined) | null;
741
709
  activityKind: "Policies:Modify";
742
710
  rule: {
743
711
  kind: "AlwaysRequireApproval";
@@ -753,13 +721,13 @@ export type UpdatePolicyBody = {
753
721
  approvalGroups: {
754
722
  name?: string | undefined;
755
723
  quorum: number;
756
- approvers?: {
724
+ approvers: {
757
725
  [x: string]: {
758
726
  [x: string]: string[];
759
727
  };
760
- } | undefined;
728
+ };
761
729
  }[];
762
- autoRejectTimeout?: number | undefined;
730
+ autoRejectTimeout?: (number | undefined) | null;
763
731
  activityKind: "Wallets:Sign";
764
732
  rule: {
765
733
  kind: "AlwaysRequireApproval";
@@ -793,133 +761,118 @@ export type UpdatePolicyBody = {
793
761
  export type UpdatePolicyParams = {
794
762
  policyId: string;
795
763
  };
796
- export type UpdatePolicyResponse = {
797
- id: string;
798
- orgId: string;
799
- requester: {
800
- userId: string;
801
- tokenId: string;
802
- appId: string;
803
- };
804
- kind: "Policy";
805
- operationKind: "Create" | "Update" | "Delete";
806
- status: "Applied" | "Failed" | "Pending" | "Rejected";
807
- entityId: string;
808
- body: ({
809
- name: string;
810
- approvalGroups: {
811
- name?: string | undefined;
812
- quorum: number;
813
- approvers?: {
814
- [x: string]: {
815
- [x: string]: string[];
816
- };
817
- } | undefined;
818
- }[];
819
- autoRejectTimeout?: number | undefined;
820
- activityKind: "Permissions:Assign";
821
- rule: {
822
- kind: "AlwaysRequireApproval";
823
- configuration: {};
824
- };
825
- filters?: {
764
+ export type UpdatePolicyResponse = ({
765
+ name: string;
766
+ approvalGroups: {
767
+ name?: string | undefined;
768
+ quorum: number;
769
+ approvers: {
826
770
  [x: string]: {
827
771
  [x: string]: string[];
828
772
  };
829
- } | undefined;
830
- } | {
831
- name: string;
832
- approvalGroups: {
833
- name?: string | undefined;
834
- quorum: number;
835
- approvers?: {
836
- [x: string]: {
837
- [x: string]: string[];
838
- };
839
- } | undefined;
840
- }[];
841
- autoRejectTimeout?: number | undefined;
842
- activityKind: "Permissions:Modify";
843
- rule: {
844
- kind: "AlwaysRequireApproval";
845
- configuration: {};
846
773
  };
847
- filters?: {
774
+ }[];
775
+ autoRejectTimeout?: (number | undefined) | null;
776
+ activityKind: "Permissions:Assign";
777
+ rule: {
778
+ kind: "AlwaysRequireApproval";
779
+ configuration: {};
780
+ };
781
+ filters?: {
782
+ [x: string]: {
783
+ [x: string]: string[];
784
+ };
785
+ } | undefined;
786
+ } | {
787
+ name: string;
788
+ approvalGroups: {
789
+ name?: string | undefined;
790
+ quorum: number;
791
+ approvers: {
848
792
  [x: string]: {
849
793
  [x: string]: string[];
850
794
  };
851
- } | undefined;
852
- } | {
853
- name: string;
854
- approvalGroups: {
855
- name?: string | undefined;
856
- quorum: number;
857
- approvers?: {
858
- [x: string]: {
859
- [x: string]: string[];
860
- };
861
- } | undefined;
862
- }[];
863
- autoRejectTimeout?: number | undefined;
864
- activityKind: "Policies:Modify";
865
- rule: {
866
- kind: "AlwaysRequireApproval";
867
- configuration: {};
868
795
  };
869
- filters?: {
796
+ }[];
797
+ autoRejectTimeout?: (number | undefined) | null;
798
+ activityKind: "Permissions:Modify";
799
+ rule: {
800
+ kind: "AlwaysRequireApproval";
801
+ configuration: {};
802
+ };
803
+ filters?: {
804
+ [x: string]: {
805
+ [x: string]: string[];
806
+ };
807
+ } | undefined;
808
+ } | {
809
+ name: string;
810
+ approvalGroups: {
811
+ name?: string | undefined;
812
+ quorum: number;
813
+ approvers: {
870
814
  [x: string]: {
871
815
  [x: string]: string[];
872
816
  };
873
- } | undefined;
874
- } | {
875
- name: string;
876
- approvalGroups: {
877
- name?: string | undefined;
878
- quorum: number;
879
- approvers?: {
880
- [x: string]: {
881
- [x: string]: string[];
882
- };
883
- } | undefined;
884
- }[];
885
- autoRejectTimeout?: number | undefined;
886
- activityKind: "Wallets:Sign";
887
- rule: {
888
- kind: "AlwaysRequireApproval";
889
- configuration: {};
890
- } | {
891
- kind: "TransactionAmountLimit";
892
- configuration: {
893
- limit: number;
894
- currency: "EUR" | "USD";
895
- };
896
- } | {
897
- kind: "TransactionAmountVelocity";
898
- configuration: {
899
- limit: number;
900
- currency: "EUR" | "USD";
901
- timeframe: number;
902
- };
903
- } | {
904
- kind: "TransactionCountVelocity";
905
- configuration: {
906
- limit: number;
907
- timeframe: number;
908
- };
909
817
  };
910
- filters?: {
818
+ }[];
819
+ autoRejectTimeout?: (number | undefined) | null;
820
+ activityKind: "Policies:Modify";
821
+ rule: {
822
+ kind: "AlwaysRequireApproval";
823
+ configuration: {};
824
+ };
825
+ filters?: {
826
+ [x: string]: {
827
+ [x: string]: string[];
828
+ };
829
+ } | undefined;
830
+ } | {
831
+ name: string;
832
+ approvalGroups: {
833
+ name?: string | undefined;
834
+ quorum: number;
835
+ approvers: {
911
836
  [x: string]: {
912
837
  [x: string]: string[];
913
838
  };
914
- } | undefined;
915
- }) & {
916
- id: string;
917
- status: "Active" | "Archived";
918
- dateCreated?: string | undefined;
919
- dateUpdated?: string | undefined;
839
+ };
840
+ }[];
841
+ autoRejectTimeout?: (number | undefined) | null;
842
+ activityKind: "Wallets:Sign";
843
+ rule: {
844
+ kind: "AlwaysRequireApproval";
845
+ configuration: {};
846
+ } | {
847
+ kind: "TransactionAmountLimit";
848
+ configuration: {
849
+ limit: number;
850
+ currency: "EUR" | "USD";
851
+ };
852
+ } | {
853
+ kind: "TransactionAmountVelocity";
854
+ configuration: {
855
+ limit: number;
856
+ currency: "EUR" | "USD";
857
+ timeframe: number;
858
+ };
859
+ } | {
860
+ kind: "TransactionCountVelocity";
861
+ configuration: {
862
+ limit: number;
863
+ timeframe: number;
864
+ };
920
865
  };
921
- dateCreated: Date;
922
- dateResolved: Date;
866
+ filters?: {
867
+ [x: string]: {
868
+ [x: string]: string[];
869
+ };
870
+ } | undefined;
871
+ }) & {
872
+ id: string;
873
+ status: "Active" | "Archived";
874
+ dateCreated?: string | undefined;
875
+ dateUpdated?: string | undefined;
923
876
  };
924
877
  export type UpdatePolicyRequest = UpdatePolicyParams & {
925
878
  body: UpdatePolicyBody;