@dfinity/sns 3.0.2 → 3.0.3-next-2024-05-10
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/candid/sns_governance.certified.idl.js +62 -10
- package/dist/candid/sns_governance.d.ts +34 -0
- package/dist/candid/sns_governance.did +41 -15
- package/dist/candid/sns_governance.idl.js +62 -10
- package/dist/candid/sns_governance_test.certified.idl.js +62 -10
- package/dist/candid/sns_governance_test.d.ts +34 -0
- package/dist/candid/sns_governance_test.did +41 -15
- package/dist/candid/sns_governance_test.idl.js +62 -10
- package/dist/candid/sns_root.certified.idl.js +23 -1
- package/dist/candid/sns_root.d.ts +25 -1
- package/dist/candid/sns_root.did +27 -7
- package/dist/candid/sns_root.idl.js +23 -1
- package/dist/candid/sns_swap.d.ts +3 -0
- package/dist/candid/sns_swap.did +6 -6
- package/dist/cjs/index.cjs.js +1 -1
- package/dist/cjs/index.cjs.js.map +4 -4
- package/dist/esm/chunk-4GE7OJRF.js +2 -0
- package/dist/esm/chunk-4GE7OJRF.js.map +7 -0
- package/dist/esm/chunk-CQAJ2SZB.js +7 -0
- package/dist/esm/chunk-CQAJ2SZB.js.map +7 -0
- package/dist/esm/chunk-VUTJEPVF.js +2 -0
- package/dist/esm/chunk-VUTJEPVF.js.map +7 -0
- package/dist/esm/{chunk-HI3EK7WH.js → chunk-VWOOXKKM.js} +2 -2
- package/dist/esm/governance.canister.js +1 -1
- package/dist/esm/index.js +1 -1
- package/dist/esm/index.js.map +3 -3
- package/dist/esm/root.canister.js +1 -1
- package/dist/esm/sns.js +1 -1
- package/dist/esm/sns.wrapper.js +1 -1
- package/dist/types/root.canister.d.ts +1 -1
- package/package.json +7 -7
- package/dist/esm/chunk-HO3ELWLY.js +0 -2
- package/dist/esm/chunk-HO3ELWLY.js.map +0 -7
- package/dist/esm/chunk-TT4OPWTE.js +0 -2
- package/dist/esm/chunk-TT4OPWTE.js.map +0 -7
- package/dist/esm/chunk-WQJQSVHV.js +0 -7
- package/dist/esm/chunk-WQJQSVHV.js.map +0 -7
- /package/dist/esm/{chunk-HI3EK7WH.js.map → chunk-VWOOXKKM.js.map} +0 -0
|
@@ -94,6 +94,7 @@ export const idlFactory = ({ IDL }) => {
|
|
|
94
94
|
'rounds_since_last_distribution' : IDL.Opt(IDL.Nat64),
|
|
95
95
|
'actual_timestamp_seconds' : IDL.Nat64,
|
|
96
96
|
'end_timestamp_seconds' : IDL.Opt(IDL.Nat64),
|
|
97
|
+
'total_available_e8s_equivalent' : IDL.Opt(IDL.Nat64),
|
|
97
98
|
'distributed_e8s_equivalent' : IDL.Nat64,
|
|
98
99
|
'round' : IDL.Nat64,
|
|
99
100
|
'settled_proposals' : IDL.Vec(ProposalId),
|
|
@@ -108,6 +109,31 @@ export const idlFactory = ({ IDL }) => {
|
|
|
108
109
|
'error_message' : IDL.Text,
|
|
109
110
|
'error_type' : IDL.Int32,
|
|
110
111
|
});
|
|
112
|
+
const Subaccount = IDL.Record({ 'subaccount' : IDL.Vec(IDL.Nat8) });
|
|
113
|
+
const Account = IDL.Record({
|
|
114
|
+
'owner' : IDL.Opt(IDL.Principal),
|
|
115
|
+
'subaccount' : IDL.Opt(Subaccount),
|
|
116
|
+
});
|
|
117
|
+
const Decimal = IDL.Record({ 'human_readable' : IDL.Opt(IDL.Text) });
|
|
118
|
+
const Tokens = IDL.Record({ 'e8s' : IDL.Opt(IDL.Nat64) });
|
|
119
|
+
const ValuationFactors = IDL.Record({
|
|
120
|
+
'xdrs_per_icp' : IDL.Opt(Decimal),
|
|
121
|
+
'icps_per_token' : IDL.Opt(Decimal),
|
|
122
|
+
'tokens' : IDL.Opt(Tokens),
|
|
123
|
+
});
|
|
124
|
+
const Valuation = IDL.Record({
|
|
125
|
+
'token' : IDL.Opt(IDL.Int32),
|
|
126
|
+
'account' : IDL.Opt(Account),
|
|
127
|
+
'valuation_factors' : IDL.Opt(ValuationFactors),
|
|
128
|
+
'timestamp_seconds' : IDL.Opt(IDL.Nat64),
|
|
129
|
+
});
|
|
130
|
+
const MintSnsTokensActionAuxiliary = IDL.Record({
|
|
131
|
+
'valuation' : IDL.Opt(Valuation),
|
|
132
|
+
});
|
|
133
|
+
const ActionAuxiliary = IDL.Variant({
|
|
134
|
+
'TransferSnsTreasuryFunds' : MintSnsTokensActionAuxiliary,
|
|
135
|
+
'MintSnsTokens' : MintSnsTokensActionAuxiliary,
|
|
136
|
+
});
|
|
111
137
|
const Ballot = IDL.Record({
|
|
112
138
|
'vote' : IDL.Int32,
|
|
113
139
|
'cast_timestamp_seconds' : IDL.Nat64,
|
|
@@ -125,13 +151,13 @@ export const idlFactory = ({ IDL }) => {
|
|
|
125
151
|
'canister_ids' : IDL.Vec(IDL.Principal),
|
|
126
152
|
'reserved_cycles_limit' : IDL.Opt(IDL.Nat64),
|
|
127
153
|
'log_visibility' : IDL.Opt(IDL.Int32),
|
|
154
|
+
'wasm_memory_limit' : IDL.Opt(IDL.Nat64),
|
|
128
155
|
'memory_allocation' : IDL.Opt(IDL.Nat64),
|
|
129
156
|
'compute_allocation' : IDL.Opt(IDL.Nat64),
|
|
130
157
|
});
|
|
131
158
|
const RegisterDappCanisters = IDL.Record({
|
|
132
159
|
'canister_ids' : IDL.Vec(IDL.Principal),
|
|
133
160
|
});
|
|
134
|
-
const Subaccount = IDL.Record({ 'subaccount' : IDL.Vec(IDL.Nat8) });
|
|
135
161
|
const TransferSnsTreasuryFunds = IDL.Record({
|
|
136
162
|
'from_treasury' : IDL.Int32,
|
|
137
163
|
'to_principal' : IDL.Opt(IDL.Principal),
|
|
@@ -166,7 +192,10 @@ export const idlFactory = ({ IDL }) => {
|
|
|
166
192
|
'payload' : IDL.Vec(IDL.Nat8),
|
|
167
193
|
});
|
|
168
194
|
const ManageLedgerParameters = IDL.Record({
|
|
195
|
+
'token_symbol' : IDL.Opt(IDL.Text),
|
|
169
196
|
'transfer_fee' : IDL.Opt(IDL.Nat64),
|
|
197
|
+
'token_logo' : IDL.Opt(IDL.Text),
|
|
198
|
+
'token_name' : IDL.Opt(IDL.Text),
|
|
170
199
|
});
|
|
171
200
|
const Motion = IDL.Record({ 'motion_text' : IDL.Text });
|
|
172
201
|
const Action = IDL.Variant({
|
|
@@ -200,6 +229,7 @@ export const idlFactory = ({ IDL }) => {
|
|
|
200
229
|
'payload_text_rendering' : IDL.Opt(IDL.Text),
|
|
201
230
|
'action' : IDL.Nat64,
|
|
202
231
|
'failure_reason' : IDL.Opt(GovernanceError),
|
|
232
|
+
'action_auxiliary' : IDL.Opt(ActionAuxiliary),
|
|
203
233
|
'ballots' : IDL.Vec(IDL.Tuple(IDL.Text, Ballot)),
|
|
204
234
|
'minimum_yes_proportion_of_total' : IDL.Opt(Percentage),
|
|
205
235
|
'reward_event_round' : IDL.Nat64,
|
|
@@ -223,10 +253,6 @@ export const idlFactory = ({ IDL }) => {
|
|
|
223
253
|
'function_id' : IDL.Nat64,
|
|
224
254
|
'followees' : IDL.Vec(NeuronId),
|
|
225
255
|
});
|
|
226
|
-
const Account = IDL.Record({
|
|
227
|
-
'owner' : IDL.Opt(IDL.Principal),
|
|
228
|
-
'subaccount' : IDL.Opt(Subaccount),
|
|
229
|
-
});
|
|
230
256
|
const DisburseMaturity = IDL.Record({
|
|
231
257
|
'to_account' : IDL.Opt(Account),
|
|
232
258
|
'percentage_to_disburse' : IDL.Nat32,
|
|
@@ -660,6 +686,7 @@ export const init = ({ IDL }) => {
|
|
|
660
686
|
'rounds_since_last_distribution' : IDL.Opt(IDL.Nat64),
|
|
661
687
|
'actual_timestamp_seconds' : IDL.Nat64,
|
|
662
688
|
'end_timestamp_seconds' : IDL.Opt(IDL.Nat64),
|
|
689
|
+
'total_available_e8s_equivalent' : IDL.Opt(IDL.Nat64),
|
|
663
690
|
'distributed_e8s_equivalent' : IDL.Nat64,
|
|
664
691
|
'round' : IDL.Nat64,
|
|
665
692
|
'settled_proposals' : IDL.Vec(ProposalId),
|
|
@@ -674,6 +701,31 @@ export const init = ({ IDL }) => {
|
|
|
674
701
|
'error_message' : IDL.Text,
|
|
675
702
|
'error_type' : IDL.Int32,
|
|
676
703
|
});
|
|
704
|
+
const Subaccount = IDL.Record({ 'subaccount' : IDL.Vec(IDL.Nat8) });
|
|
705
|
+
const Account = IDL.Record({
|
|
706
|
+
'owner' : IDL.Opt(IDL.Principal),
|
|
707
|
+
'subaccount' : IDL.Opt(Subaccount),
|
|
708
|
+
});
|
|
709
|
+
const Decimal = IDL.Record({ 'human_readable' : IDL.Opt(IDL.Text) });
|
|
710
|
+
const Tokens = IDL.Record({ 'e8s' : IDL.Opt(IDL.Nat64) });
|
|
711
|
+
const ValuationFactors = IDL.Record({
|
|
712
|
+
'xdrs_per_icp' : IDL.Opt(Decimal),
|
|
713
|
+
'icps_per_token' : IDL.Opt(Decimal),
|
|
714
|
+
'tokens' : IDL.Opt(Tokens),
|
|
715
|
+
});
|
|
716
|
+
const Valuation = IDL.Record({
|
|
717
|
+
'token' : IDL.Opt(IDL.Int32),
|
|
718
|
+
'account' : IDL.Opt(Account),
|
|
719
|
+
'valuation_factors' : IDL.Opt(ValuationFactors),
|
|
720
|
+
'timestamp_seconds' : IDL.Opt(IDL.Nat64),
|
|
721
|
+
});
|
|
722
|
+
const MintSnsTokensActionAuxiliary = IDL.Record({
|
|
723
|
+
'valuation' : IDL.Opt(Valuation),
|
|
724
|
+
});
|
|
725
|
+
const ActionAuxiliary = IDL.Variant({
|
|
726
|
+
'TransferSnsTreasuryFunds' : MintSnsTokensActionAuxiliary,
|
|
727
|
+
'MintSnsTokens' : MintSnsTokensActionAuxiliary,
|
|
728
|
+
});
|
|
677
729
|
const Ballot = IDL.Record({
|
|
678
730
|
'vote' : IDL.Int32,
|
|
679
731
|
'cast_timestamp_seconds' : IDL.Nat64,
|
|
@@ -691,13 +743,13 @@ export const init = ({ IDL }) => {
|
|
|
691
743
|
'canister_ids' : IDL.Vec(IDL.Principal),
|
|
692
744
|
'reserved_cycles_limit' : IDL.Opt(IDL.Nat64),
|
|
693
745
|
'log_visibility' : IDL.Opt(IDL.Int32),
|
|
746
|
+
'wasm_memory_limit' : IDL.Opt(IDL.Nat64),
|
|
694
747
|
'memory_allocation' : IDL.Opt(IDL.Nat64),
|
|
695
748
|
'compute_allocation' : IDL.Opt(IDL.Nat64),
|
|
696
749
|
});
|
|
697
750
|
const RegisterDappCanisters = IDL.Record({
|
|
698
751
|
'canister_ids' : IDL.Vec(IDL.Principal),
|
|
699
752
|
});
|
|
700
|
-
const Subaccount = IDL.Record({ 'subaccount' : IDL.Vec(IDL.Nat8) });
|
|
701
753
|
const TransferSnsTreasuryFunds = IDL.Record({
|
|
702
754
|
'from_treasury' : IDL.Int32,
|
|
703
755
|
'to_principal' : IDL.Opt(IDL.Principal),
|
|
@@ -732,7 +784,10 @@ export const init = ({ IDL }) => {
|
|
|
732
784
|
'payload' : IDL.Vec(IDL.Nat8),
|
|
733
785
|
});
|
|
734
786
|
const ManageLedgerParameters = IDL.Record({
|
|
787
|
+
'token_symbol' : IDL.Opt(IDL.Text),
|
|
735
788
|
'transfer_fee' : IDL.Opt(IDL.Nat64),
|
|
789
|
+
'token_logo' : IDL.Opt(IDL.Text),
|
|
790
|
+
'token_name' : IDL.Opt(IDL.Text),
|
|
736
791
|
});
|
|
737
792
|
const Motion = IDL.Record({ 'motion_text' : IDL.Text });
|
|
738
793
|
const Action = IDL.Variant({
|
|
@@ -766,6 +821,7 @@ export const init = ({ IDL }) => {
|
|
|
766
821
|
'payload_text_rendering' : IDL.Opt(IDL.Text),
|
|
767
822
|
'action' : IDL.Nat64,
|
|
768
823
|
'failure_reason' : IDL.Opt(GovernanceError),
|
|
824
|
+
'action_auxiliary' : IDL.Opt(ActionAuxiliary),
|
|
769
825
|
'ballots' : IDL.Vec(IDL.Tuple(IDL.Text, Ballot)),
|
|
770
826
|
'minimum_yes_proportion_of_total' : IDL.Opt(Percentage),
|
|
771
827
|
'reward_event_round' : IDL.Nat64,
|
|
@@ -789,10 +845,6 @@ export const init = ({ IDL }) => {
|
|
|
789
845
|
'function_id' : IDL.Nat64,
|
|
790
846
|
'followees' : IDL.Vec(NeuronId),
|
|
791
847
|
});
|
|
792
|
-
const Account = IDL.Record({
|
|
793
|
-
'owner' : IDL.Opt(IDL.Principal),
|
|
794
|
-
'subaccount' : IDL.Opt(Subaccount),
|
|
795
|
-
});
|
|
796
848
|
const DisburseMaturity = IDL.Record({
|
|
797
849
|
'to_account' : IDL.Opt(Account),
|
|
798
850
|
'percentage_to_disburse' : IDL.Nat32,
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { ActorMethod } from "@dfinity/agent";
|
|
2
|
+
import type { IDL } from "@dfinity/candid";
|
|
2
3
|
import type { Principal } from "@dfinity/principal";
|
|
3
4
|
|
|
4
5
|
export interface Account {
|
|
@@ -25,6 +26,11 @@ export type Action =
|
|
|
25
26
|
}
|
|
26
27
|
| { ManageLedgerParameters: ManageLedgerParameters }
|
|
27
28
|
| { Motion: Motion };
|
|
29
|
+
export type ActionAuxiliary =
|
|
30
|
+
| {
|
|
31
|
+
TransferSnsTreasuryFunds: MintSnsTokensActionAuxiliary;
|
|
32
|
+
}
|
|
33
|
+
| { MintSnsTokens: MintSnsTokensActionAuxiliary };
|
|
28
34
|
export interface AddMaturityRequest {
|
|
29
35
|
id: [] | [NeuronId];
|
|
30
36
|
amount_e8s: [] | [bigint];
|
|
@@ -122,6 +128,9 @@ export type Command_2 =
|
|
|
122
128
|
export interface Configure {
|
|
123
129
|
operation: [] | [Operation];
|
|
124
130
|
}
|
|
131
|
+
export interface Decimal {
|
|
132
|
+
human_readable: [] | [string];
|
|
133
|
+
}
|
|
125
134
|
export interface DefaultFollowees {
|
|
126
135
|
followees: Array<[bigint, Followees]>;
|
|
127
136
|
}
|
|
@@ -286,11 +295,15 @@ export interface ManageDappCanisterSettings {
|
|
|
286
295
|
canister_ids: Array<Principal>;
|
|
287
296
|
reserved_cycles_limit: [] | [bigint];
|
|
288
297
|
log_visibility: [] | [number];
|
|
298
|
+
wasm_memory_limit: [] | [bigint];
|
|
289
299
|
memory_allocation: [] | [bigint];
|
|
290
300
|
compute_allocation: [] | [bigint];
|
|
291
301
|
}
|
|
292
302
|
export interface ManageLedgerParameters {
|
|
303
|
+
token_symbol: [] | [string];
|
|
293
304
|
transfer_fee: [] | [bigint];
|
|
305
|
+
token_logo: [] | [string];
|
|
306
|
+
token_name: [] | [string];
|
|
294
307
|
}
|
|
295
308
|
export interface ManageNeuron {
|
|
296
309
|
subaccount: Uint8Array | number[];
|
|
@@ -326,6 +339,9 @@ export interface MintSnsTokens {
|
|
|
326
339
|
memo: [] | [bigint];
|
|
327
340
|
amount_e8s: [] | [bigint];
|
|
328
341
|
}
|
|
342
|
+
export interface MintSnsTokensActionAuxiliary {
|
|
343
|
+
valuation: [] | [Valuation];
|
|
344
|
+
}
|
|
329
345
|
export interface MintTokensRequest {
|
|
330
346
|
recipient: [] | [Account];
|
|
331
347
|
amount_e8s: [] | [bigint];
|
|
@@ -423,6 +439,7 @@ export interface ProposalData {
|
|
|
423
439
|
payload_text_rendering: [] | [string];
|
|
424
440
|
action: bigint;
|
|
425
441
|
failure_reason: [] | [GovernanceError];
|
|
442
|
+
action_auxiliary: [] | [ActionAuxiliary];
|
|
426
443
|
ballots: Array<[string, Ballot]>;
|
|
427
444
|
minimum_yes_proportion_of_total: [] | [Percentage];
|
|
428
445
|
reward_event_round: bigint;
|
|
@@ -461,6 +478,7 @@ export interface RewardEvent {
|
|
|
461
478
|
rounds_since_last_distribution: [] | [bigint];
|
|
462
479
|
actual_timestamp_seconds: bigint;
|
|
463
480
|
end_timestamp_seconds: [] | [bigint];
|
|
481
|
+
total_available_e8s_equivalent: [] | [bigint];
|
|
464
482
|
distributed_e8s_equivalent: bigint;
|
|
465
483
|
round: bigint;
|
|
466
484
|
settled_proposals: Array<ProposalId>;
|
|
@@ -498,6 +516,9 @@ export interface Tally {
|
|
|
498
516
|
total: bigint;
|
|
499
517
|
timestamp_seconds: bigint;
|
|
500
518
|
}
|
|
519
|
+
export interface Tokens {
|
|
520
|
+
e8s: [] | [bigint];
|
|
521
|
+
}
|
|
501
522
|
export interface TransferSnsTreasuryFunds {
|
|
502
523
|
from_treasury: number;
|
|
503
524
|
to_principal: [] | [Principal];
|
|
@@ -517,6 +538,17 @@ export interface UpgradeSnsControlledCanister {
|
|
|
517
538
|
canister_id: [] | [Principal];
|
|
518
539
|
canister_upgrade_arg: [] | [Uint8Array | number[]];
|
|
519
540
|
}
|
|
541
|
+
export interface Valuation {
|
|
542
|
+
token: [] | [number];
|
|
543
|
+
account: [] | [Account];
|
|
544
|
+
valuation_factors: [] | [ValuationFactors];
|
|
545
|
+
timestamp_seconds: [] | [bigint];
|
|
546
|
+
}
|
|
547
|
+
export interface ValuationFactors {
|
|
548
|
+
xdrs_per_icp: [] | [Decimal];
|
|
549
|
+
icps_per_token: [] | [Decimal];
|
|
550
|
+
tokens: [] | [Tokens];
|
|
551
|
+
}
|
|
520
552
|
export interface Version {
|
|
521
553
|
archive_wasm_hash: Uint8Array | number[];
|
|
522
554
|
root_wasm_hash: Uint8Array | number[];
|
|
@@ -566,3 +598,5 @@ export interface _SERVICE {
|
|
|
566
598
|
set_mode: ActorMethod<[SetMode], {}>;
|
|
567
599
|
update_neuron: ActorMethod<[Neuron], [] | [GovernanceError]>;
|
|
568
600
|
}
|
|
601
|
+
export declare const idlFactory: IDL.InterfaceFactory;
|
|
602
|
+
export declare const init: (args: { IDL: typeof IDL }) => IDL.Type[];
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
// Generated from IC repo commit
|
|
1
|
+
// Generated from IC repo commit f58424c (2024-04-24 tags: release-2024-05-01_23-01-storage-layer) 'rs/sns/governance/canister/governance_test.did' by import-candid
|
|
2
2
|
type Account = record { owner : opt principal; subaccount : opt Subaccount };
|
|
3
3
|
type Action = variant {
|
|
4
4
|
ManageNervousSystemParameters : NervousSystemParameters;
|
|
@@ -17,6 +17,10 @@ type Action = variant {
|
|
|
17
17
|
ManageLedgerParameters : ManageLedgerParameters;
|
|
18
18
|
Motion : Motion;
|
|
19
19
|
};
|
|
20
|
+
type ActionAuxiliary = variant {
|
|
21
|
+
TransferSnsTreasuryFunds : MintSnsTokensActionAuxiliary;
|
|
22
|
+
MintSnsTokens : MintSnsTokensActionAuxiliary;
|
|
23
|
+
};
|
|
20
24
|
type AddMaturityRequest = record { id : opt NeuronId; amount_e8s : opt nat64 };
|
|
21
25
|
type AddMaturityResponse = record { new_maturity_e8s : opt nat64 };
|
|
22
26
|
type AddNeuronPermissions = record {
|
|
@@ -39,7 +43,7 @@ type CanisterStatusResultV2 = record {
|
|
|
39
43
|
cycles : nat;
|
|
40
44
|
settings : DefiniteCanisterSettingsArgs;
|
|
41
45
|
idle_cycles_burned_per_day : nat;
|
|
42
|
-
module_hash : opt
|
|
46
|
+
module_hash : opt blob;
|
|
43
47
|
};
|
|
44
48
|
type CanisterStatusType = variant { stopped; stopping; running };
|
|
45
49
|
type ChangeAutoStakeMaturity = record {
|
|
@@ -100,6 +104,7 @@ type Command_2 = variant {
|
|
|
100
104
|
Disburse : Disburse;
|
|
101
105
|
};
|
|
102
106
|
type Configure = record { operation : opt Operation };
|
|
107
|
+
type Decimal = record { human_readable : opt text };
|
|
103
108
|
type DefaultFollowees = record { followees : vec record { nat64; Followees } };
|
|
104
109
|
type DefiniteCanisterSettingsArgs = record {
|
|
105
110
|
freezing_threshold : nat;
|
|
@@ -133,7 +138,7 @@ type DissolveState = variant {
|
|
|
133
138
|
};
|
|
134
139
|
type ExecuteGenericNervousSystemFunction = record {
|
|
135
140
|
function_id : nat64;
|
|
136
|
-
payload :
|
|
141
|
+
payload : blob;
|
|
137
142
|
};
|
|
138
143
|
type FinalizeDisburseMaturity = record {
|
|
139
144
|
amount_to_be_disbursed_e8s : nat64;
|
|
@@ -239,11 +244,17 @@ type ManageDappCanisterSettings = record {
|
|
|
239
244
|
canister_ids : vec principal;
|
|
240
245
|
reserved_cycles_limit : opt nat64;
|
|
241
246
|
log_visibility : opt int32;
|
|
247
|
+
wasm_memory_limit : opt nat64;
|
|
242
248
|
memory_allocation : opt nat64;
|
|
243
249
|
compute_allocation : opt nat64;
|
|
244
250
|
};
|
|
245
|
-
type ManageLedgerParameters = record {
|
|
246
|
-
|
|
251
|
+
type ManageLedgerParameters = record {
|
|
252
|
+
token_symbol : opt text;
|
|
253
|
+
transfer_fee : opt nat64;
|
|
254
|
+
token_logo : opt text;
|
|
255
|
+
token_name : opt text;
|
|
256
|
+
};
|
|
257
|
+
type ManageNeuron = record { subaccount : blob; command : opt Command };
|
|
247
258
|
type ManageNeuronResponse = record { command : opt Command_1 };
|
|
248
259
|
type ManageSnsMetadata = record {
|
|
249
260
|
url : opt text;
|
|
@@ -267,6 +278,7 @@ type MintSnsTokens = record {
|
|
|
267
278
|
memo : opt nat64;
|
|
268
279
|
amount_e8s : opt nat64;
|
|
269
280
|
};
|
|
281
|
+
type MintSnsTokensActionAuxiliary = record { valuation : opt Valuation };
|
|
270
282
|
type MintTokensRequest = record {
|
|
271
283
|
recipient : opt Account;
|
|
272
284
|
amount_e8s : opt nat64;
|
|
@@ -317,7 +329,7 @@ type Neuron = record {
|
|
|
317
329
|
followees : vec record { nat64; Followees };
|
|
318
330
|
neuron_fees_e8s : nat64;
|
|
319
331
|
};
|
|
320
|
-
type NeuronId = record { id :
|
|
332
|
+
type NeuronId = record { id : blob };
|
|
321
333
|
type NeuronInFlightCommand = record {
|
|
322
334
|
command : opt Command_2;
|
|
323
335
|
timestamp : nat64;
|
|
@@ -355,6 +367,7 @@ type ProposalData = record {
|
|
|
355
367
|
payload_text_rendering : opt text;
|
|
356
368
|
action : nat64;
|
|
357
369
|
failure_reason : opt GovernanceError;
|
|
370
|
+
action_auxiliary : opt ActionAuxiliary;
|
|
358
371
|
ballots : vec record { text; Ballot };
|
|
359
372
|
minimum_yes_proportion_of_total : opt Percentage;
|
|
360
373
|
reward_event_round : nat64;
|
|
@@ -386,6 +399,7 @@ type RewardEvent = record {
|
|
|
386
399
|
rounds_since_last_distribution : opt nat64;
|
|
387
400
|
actual_timestamp_seconds : nat64;
|
|
388
401
|
end_timestamp_seconds : opt nat64;
|
|
402
|
+
total_available_e8s_equivalent : opt nat64;
|
|
389
403
|
distributed_e8s_equivalent : nat64;
|
|
390
404
|
round : nat64;
|
|
391
405
|
settled_proposals : vec ProposalId;
|
|
@@ -399,7 +413,7 @@ type StakeMaturityResponse = record {
|
|
|
399
413
|
maturity_e8s : nat64;
|
|
400
414
|
staked_maturity_e8s : nat64;
|
|
401
415
|
};
|
|
402
|
-
type Subaccount = record { subaccount :
|
|
416
|
+
type Subaccount = record { subaccount : blob };
|
|
403
417
|
type SwapNeuron = record { id : opt NeuronId; status : int32 };
|
|
404
418
|
type Tally = record {
|
|
405
419
|
no : nat64;
|
|
@@ -407,6 +421,7 @@ type Tally = record {
|
|
|
407
421
|
total : nat64;
|
|
408
422
|
timestamp_seconds : nat64;
|
|
409
423
|
};
|
|
424
|
+
type Tokens = record { e8s : opt nat64 };
|
|
410
425
|
type TransferSnsTreasuryFunds = record {
|
|
411
426
|
from_treasury : int32;
|
|
412
427
|
to_principal : opt principal;
|
|
@@ -421,18 +436,29 @@ type UpgradeInProgress = record {
|
|
|
421
436
|
target_version : opt Version;
|
|
422
437
|
};
|
|
423
438
|
type UpgradeSnsControlledCanister = record {
|
|
424
|
-
new_canister_wasm :
|
|
439
|
+
new_canister_wasm : blob;
|
|
425
440
|
mode : opt int32;
|
|
426
441
|
canister_id : opt principal;
|
|
427
|
-
canister_upgrade_arg : opt
|
|
442
|
+
canister_upgrade_arg : opt blob;
|
|
443
|
+
};
|
|
444
|
+
type Valuation = record {
|
|
445
|
+
token : opt int32;
|
|
446
|
+
account : opt Account;
|
|
447
|
+
valuation_factors : opt ValuationFactors;
|
|
448
|
+
timestamp_seconds : opt nat64;
|
|
449
|
+
};
|
|
450
|
+
type ValuationFactors = record {
|
|
451
|
+
xdrs_per_icp : opt Decimal;
|
|
452
|
+
icps_per_token : opt Decimal;
|
|
453
|
+
tokens : opt Tokens;
|
|
428
454
|
};
|
|
429
455
|
type Version = record {
|
|
430
|
-
archive_wasm_hash :
|
|
431
|
-
root_wasm_hash :
|
|
432
|
-
swap_wasm_hash :
|
|
433
|
-
ledger_wasm_hash :
|
|
434
|
-
governance_wasm_hash :
|
|
435
|
-
index_wasm_hash :
|
|
456
|
+
archive_wasm_hash : blob;
|
|
457
|
+
root_wasm_hash : blob;
|
|
458
|
+
swap_wasm_hash : blob;
|
|
459
|
+
ledger_wasm_hash : blob;
|
|
460
|
+
governance_wasm_hash : blob;
|
|
461
|
+
index_wasm_hash : blob;
|
|
436
462
|
};
|
|
437
463
|
type VotingRewardsParameters = record {
|
|
438
464
|
final_reward_rate_basis_points : opt nat64;
|
|
@@ -94,6 +94,7 @@ export const idlFactory = ({ IDL }) => {
|
|
|
94
94
|
'rounds_since_last_distribution' : IDL.Opt(IDL.Nat64),
|
|
95
95
|
'actual_timestamp_seconds' : IDL.Nat64,
|
|
96
96
|
'end_timestamp_seconds' : IDL.Opt(IDL.Nat64),
|
|
97
|
+
'total_available_e8s_equivalent' : IDL.Opt(IDL.Nat64),
|
|
97
98
|
'distributed_e8s_equivalent' : IDL.Nat64,
|
|
98
99
|
'round' : IDL.Nat64,
|
|
99
100
|
'settled_proposals' : IDL.Vec(ProposalId),
|
|
@@ -108,6 +109,31 @@ export const idlFactory = ({ IDL }) => {
|
|
|
108
109
|
'error_message' : IDL.Text,
|
|
109
110
|
'error_type' : IDL.Int32,
|
|
110
111
|
});
|
|
112
|
+
const Subaccount = IDL.Record({ 'subaccount' : IDL.Vec(IDL.Nat8) });
|
|
113
|
+
const Account = IDL.Record({
|
|
114
|
+
'owner' : IDL.Opt(IDL.Principal),
|
|
115
|
+
'subaccount' : IDL.Opt(Subaccount),
|
|
116
|
+
});
|
|
117
|
+
const Decimal = IDL.Record({ 'human_readable' : IDL.Opt(IDL.Text) });
|
|
118
|
+
const Tokens = IDL.Record({ 'e8s' : IDL.Opt(IDL.Nat64) });
|
|
119
|
+
const ValuationFactors = IDL.Record({
|
|
120
|
+
'xdrs_per_icp' : IDL.Opt(Decimal),
|
|
121
|
+
'icps_per_token' : IDL.Opt(Decimal),
|
|
122
|
+
'tokens' : IDL.Opt(Tokens),
|
|
123
|
+
});
|
|
124
|
+
const Valuation = IDL.Record({
|
|
125
|
+
'token' : IDL.Opt(IDL.Int32),
|
|
126
|
+
'account' : IDL.Opt(Account),
|
|
127
|
+
'valuation_factors' : IDL.Opt(ValuationFactors),
|
|
128
|
+
'timestamp_seconds' : IDL.Opt(IDL.Nat64),
|
|
129
|
+
});
|
|
130
|
+
const MintSnsTokensActionAuxiliary = IDL.Record({
|
|
131
|
+
'valuation' : IDL.Opt(Valuation),
|
|
132
|
+
});
|
|
133
|
+
const ActionAuxiliary = IDL.Variant({
|
|
134
|
+
'TransferSnsTreasuryFunds' : MintSnsTokensActionAuxiliary,
|
|
135
|
+
'MintSnsTokens' : MintSnsTokensActionAuxiliary,
|
|
136
|
+
});
|
|
111
137
|
const Ballot = IDL.Record({
|
|
112
138
|
'vote' : IDL.Int32,
|
|
113
139
|
'cast_timestamp_seconds' : IDL.Nat64,
|
|
@@ -125,13 +151,13 @@ export const idlFactory = ({ IDL }) => {
|
|
|
125
151
|
'canister_ids' : IDL.Vec(IDL.Principal),
|
|
126
152
|
'reserved_cycles_limit' : IDL.Opt(IDL.Nat64),
|
|
127
153
|
'log_visibility' : IDL.Opt(IDL.Int32),
|
|
154
|
+
'wasm_memory_limit' : IDL.Opt(IDL.Nat64),
|
|
128
155
|
'memory_allocation' : IDL.Opt(IDL.Nat64),
|
|
129
156
|
'compute_allocation' : IDL.Opt(IDL.Nat64),
|
|
130
157
|
});
|
|
131
158
|
const RegisterDappCanisters = IDL.Record({
|
|
132
159
|
'canister_ids' : IDL.Vec(IDL.Principal),
|
|
133
160
|
});
|
|
134
|
-
const Subaccount = IDL.Record({ 'subaccount' : IDL.Vec(IDL.Nat8) });
|
|
135
161
|
const TransferSnsTreasuryFunds = IDL.Record({
|
|
136
162
|
'from_treasury' : IDL.Int32,
|
|
137
163
|
'to_principal' : IDL.Opt(IDL.Principal),
|
|
@@ -166,7 +192,10 @@ export const idlFactory = ({ IDL }) => {
|
|
|
166
192
|
'payload' : IDL.Vec(IDL.Nat8),
|
|
167
193
|
});
|
|
168
194
|
const ManageLedgerParameters = IDL.Record({
|
|
195
|
+
'token_symbol' : IDL.Opt(IDL.Text),
|
|
169
196
|
'transfer_fee' : IDL.Opt(IDL.Nat64),
|
|
197
|
+
'token_logo' : IDL.Opt(IDL.Text),
|
|
198
|
+
'token_name' : IDL.Opt(IDL.Text),
|
|
170
199
|
});
|
|
171
200
|
const Motion = IDL.Record({ 'motion_text' : IDL.Text });
|
|
172
201
|
const Action = IDL.Variant({
|
|
@@ -200,6 +229,7 @@ export const idlFactory = ({ IDL }) => {
|
|
|
200
229
|
'payload_text_rendering' : IDL.Opt(IDL.Text),
|
|
201
230
|
'action' : IDL.Nat64,
|
|
202
231
|
'failure_reason' : IDL.Opt(GovernanceError),
|
|
232
|
+
'action_auxiliary' : IDL.Opt(ActionAuxiliary),
|
|
203
233
|
'ballots' : IDL.Vec(IDL.Tuple(IDL.Text, Ballot)),
|
|
204
234
|
'minimum_yes_proportion_of_total' : IDL.Opt(Percentage),
|
|
205
235
|
'reward_event_round' : IDL.Nat64,
|
|
@@ -223,10 +253,6 @@ export const idlFactory = ({ IDL }) => {
|
|
|
223
253
|
'function_id' : IDL.Nat64,
|
|
224
254
|
'followees' : IDL.Vec(NeuronId),
|
|
225
255
|
});
|
|
226
|
-
const Account = IDL.Record({
|
|
227
|
-
'owner' : IDL.Opt(IDL.Principal),
|
|
228
|
-
'subaccount' : IDL.Opt(Subaccount),
|
|
229
|
-
});
|
|
230
256
|
const DisburseMaturity = IDL.Record({
|
|
231
257
|
'to_account' : IDL.Opt(Account),
|
|
232
258
|
'percentage_to_disburse' : IDL.Nat32,
|
|
@@ -668,6 +694,7 @@ export const init = ({ IDL }) => {
|
|
|
668
694
|
'rounds_since_last_distribution' : IDL.Opt(IDL.Nat64),
|
|
669
695
|
'actual_timestamp_seconds' : IDL.Nat64,
|
|
670
696
|
'end_timestamp_seconds' : IDL.Opt(IDL.Nat64),
|
|
697
|
+
'total_available_e8s_equivalent' : IDL.Opt(IDL.Nat64),
|
|
671
698
|
'distributed_e8s_equivalent' : IDL.Nat64,
|
|
672
699
|
'round' : IDL.Nat64,
|
|
673
700
|
'settled_proposals' : IDL.Vec(ProposalId),
|
|
@@ -682,6 +709,31 @@ export const init = ({ IDL }) => {
|
|
|
682
709
|
'error_message' : IDL.Text,
|
|
683
710
|
'error_type' : IDL.Int32,
|
|
684
711
|
});
|
|
712
|
+
const Subaccount = IDL.Record({ 'subaccount' : IDL.Vec(IDL.Nat8) });
|
|
713
|
+
const Account = IDL.Record({
|
|
714
|
+
'owner' : IDL.Opt(IDL.Principal),
|
|
715
|
+
'subaccount' : IDL.Opt(Subaccount),
|
|
716
|
+
});
|
|
717
|
+
const Decimal = IDL.Record({ 'human_readable' : IDL.Opt(IDL.Text) });
|
|
718
|
+
const Tokens = IDL.Record({ 'e8s' : IDL.Opt(IDL.Nat64) });
|
|
719
|
+
const ValuationFactors = IDL.Record({
|
|
720
|
+
'xdrs_per_icp' : IDL.Opt(Decimal),
|
|
721
|
+
'icps_per_token' : IDL.Opt(Decimal),
|
|
722
|
+
'tokens' : IDL.Opt(Tokens),
|
|
723
|
+
});
|
|
724
|
+
const Valuation = IDL.Record({
|
|
725
|
+
'token' : IDL.Opt(IDL.Int32),
|
|
726
|
+
'account' : IDL.Opt(Account),
|
|
727
|
+
'valuation_factors' : IDL.Opt(ValuationFactors),
|
|
728
|
+
'timestamp_seconds' : IDL.Opt(IDL.Nat64),
|
|
729
|
+
});
|
|
730
|
+
const MintSnsTokensActionAuxiliary = IDL.Record({
|
|
731
|
+
'valuation' : IDL.Opt(Valuation),
|
|
732
|
+
});
|
|
733
|
+
const ActionAuxiliary = IDL.Variant({
|
|
734
|
+
'TransferSnsTreasuryFunds' : MintSnsTokensActionAuxiliary,
|
|
735
|
+
'MintSnsTokens' : MintSnsTokensActionAuxiliary,
|
|
736
|
+
});
|
|
685
737
|
const Ballot = IDL.Record({
|
|
686
738
|
'vote' : IDL.Int32,
|
|
687
739
|
'cast_timestamp_seconds' : IDL.Nat64,
|
|
@@ -699,13 +751,13 @@ export const init = ({ IDL }) => {
|
|
|
699
751
|
'canister_ids' : IDL.Vec(IDL.Principal),
|
|
700
752
|
'reserved_cycles_limit' : IDL.Opt(IDL.Nat64),
|
|
701
753
|
'log_visibility' : IDL.Opt(IDL.Int32),
|
|
754
|
+
'wasm_memory_limit' : IDL.Opt(IDL.Nat64),
|
|
702
755
|
'memory_allocation' : IDL.Opt(IDL.Nat64),
|
|
703
756
|
'compute_allocation' : IDL.Opt(IDL.Nat64),
|
|
704
757
|
});
|
|
705
758
|
const RegisterDappCanisters = IDL.Record({
|
|
706
759
|
'canister_ids' : IDL.Vec(IDL.Principal),
|
|
707
760
|
});
|
|
708
|
-
const Subaccount = IDL.Record({ 'subaccount' : IDL.Vec(IDL.Nat8) });
|
|
709
761
|
const TransferSnsTreasuryFunds = IDL.Record({
|
|
710
762
|
'from_treasury' : IDL.Int32,
|
|
711
763
|
'to_principal' : IDL.Opt(IDL.Principal),
|
|
@@ -740,7 +792,10 @@ export const init = ({ IDL }) => {
|
|
|
740
792
|
'payload' : IDL.Vec(IDL.Nat8),
|
|
741
793
|
});
|
|
742
794
|
const ManageLedgerParameters = IDL.Record({
|
|
795
|
+
'token_symbol' : IDL.Opt(IDL.Text),
|
|
743
796
|
'transfer_fee' : IDL.Opt(IDL.Nat64),
|
|
797
|
+
'token_logo' : IDL.Opt(IDL.Text),
|
|
798
|
+
'token_name' : IDL.Opt(IDL.Text),
|
|
744
799
|
});
|
|
745
800
|
const Motion = IDL.Record({ 'motion_text' : IDL.Text });
|
|
746
801
|
const Action = IDL.Variant({
|
|
@@ -774,6 +829,7 @@ export const init = ({ IDL }) => {
|
|
|
774
829
|
'payload_text_rendering' : IDL.Opt(IDL.Text),
|
|
775
830
|
'action' : IDL.Nat64,
|
|
776
831
|
'failure_reason' : IDL.Opt(GovernanceError),
|
|
832
|
+
'action_auxiliary' : IDL.Opt(ActionAuxiliary),
|
|
777
833
|
'ballots' : IDL.Vec(IDL.Tuple(IDL.Text, Ballot)),
|
|
778
834
|
'minimum_yes_proportion_of_total' : IDL.Opt(Percentage),
|
|
779
835
|
'reward_event_round' : IDL.Nat64,
|
|
@@ -797,10 +853,6 @@ export const init = ({ IDL }) => {
|
|
|
797
853
|
'function_id' : IDL.Nat64,
|
|
798
854
|
'followees' : IDL.Vec(NeuronId),
|
|
799
855
|
});
|
|
800
|
-
const Account = IDL.Record({
|
|
801
|
-
'owner' : IDL.Opt(IDL.Principal),
|
|
802
|
-
'subaccount' : IDL.Opt(Subaccount),
|
|
803
|
-
});
|
|
804
856
|
const DisburseMaturity = IDL.Record({
|
|
805
857
|
'to_account' : IDL.Opt(Account),
|
|
806
858
|
'percentage_to_disburse' : IDL.Nat32,
|
|
@@ -17,14 +17,20 @@ export const idlFactory = ({ IDL }) => {
|
|
|
17
17
|
'running' : IDL.Null,
|
|
18
18
|
});
|
|
19
19
|
const DefiniteCanisterSettings = IDL.Record({
|
|
20
|
+
'freezing_threshold' : IDL.Opt(IDL.Nat),
|
|
20
21
|
'controllers' : IDL.Vec(IDL.Principal),
|
|
22
|
+
'reserved_cycles_limit' : IDL.Opt(IDL.Nat),
|
|
23
|
+
'memory_allocation' : IDL.Opt(IDL.Nat),
|
|
24
|
+
'compute_allocation' : IDL.Opt(IDL.Nat),
|
|
21
25
|
});
|
|
22
26
|
const CanisterStatusResult = IDL.Record({
|
|
23
27
|
'status' : CanisterStatusType,
|
|
24
28
|
'memory_size' : IDL.Nat,
|
|
25
29
|
'cycles' : IDL.Nat,
|
|
26
30
|
'settings' : DefiniteCanisterSettings,
|
|
31
|
+
'idle_cycles_burned_per_day' : IDL.Opt(IDL.Nat),
|
|
27
32
|
'module_hash' : IDL.Opt(IDL.Vec(IDL.Nat8)),
|
|
33
|
+
'reserved_cycles' : IDL.Opt(IDL.Nat),
|
|
28
34
|
});
|
|
29
35
|
const CanisterInstallMode = IDL.Variant({
|
|
30
36
|
'reinstall' : IDL.Null,
|
|
@@ -37,7 +43,6 @@ export const idlFactory = ({ IDL }) => {
|
|
|
37
43
|
'stop_before_installing' : IDL.Bool,
|
|
38
44
|
'mode' : CanisterInstallMode,
|
|
39
45
|
'canister_id' : IDL.Principal,
|
|
40
|
-
'query_allocation' : IDL.Opt(IDL.Nat),
|
|
41
46
|
'memory_allocation' : IDL.Opt(IDL.Nat),
|
|
42
47
|
'compute_allocation' : IDL.Opt(IDL.Nat),
|
|
43
48
|
});
|
|
@@ -80,6 +85,18 @@ export const idlFactory = ({ IDL }) => {
|
|
|
80
85
|
'dapps' : IDL.Vec(IDL.Principal),
|
|
81
86
|
'archives' : IDL.Vec(IDL.Principal),
|
|
82
87
|
});
|
|
88
|
+
const ManageDappCanisterSettingsRequest = IDL.Record({
|
|
89
|
+
'freezing_threshold' : IDL.Opt(IDL.Nat64),
|
|
90
|
+
'canister_ids' : IDL.Vec(IDL.Principal),
|
|
91
|
+
'reserved_cycles_limit' : IDL.Opt(IDL.Nat64),
|
|
92
|
+
'log_visibility' : IDL.Opt(IDL.Int32),
|
|
93
|
+
'wasm_memory_limit' : IDL.Opt(IDL.Nat64),
|
|
94
|
+
'memory_allocation' : IDL.Opt(IDL.Nat64),
|
|
95
|
+
'compute_allocation' : IDL.Opt(IDL.Nat64),
|
|
96
|
+
});
|
|
97
|
+
const ManageDappCanisterSettingsResponse = IDL.Record({
|
|
98
|
+
'failure_reason' : IDL.Opt(IDL.Text),
|
|
99
|
+
});
|
|
83
100
|
const RegisterDappCanisterRequest = IDL.Record({
|
|
84
101
|
'canister_id' : IDL.Opt(IDL.Principal),
|
|
85
102
|
});
|
|
@@ -119,6 +136,11 @@ export const idlFactory = ({ IDL }) => {
|
|
|
119
136
|
[ListSnsCanistersResponse],
|
|
120
137
|
[],
|
|
121
138
|
),
|
|
139
|
+
'manage_dapp_canister_settings' : IDL.Func(
|
|
140
|
+
[ManageDappCanisterSettingsRequest],
|
|
141
|
+
[ManageDappCanisterSettingsResponse],
|
|
142
|
+
[],
|
|
143
|
+
),
|
|
122
144
|
'register_dapp_canister' : IDL.Func(
|
|
123
145
|
[RegisterDappCanisterRequest],
|
|
124
146
|
[IDL.Record({})],
|