@dfinity/nns 6.0.0 → 7.0.0
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/genesis_token.did +23 -6
- package/dist/candid/governance.certified.idl.js +1 -31
- package/dist/candid/governance.d.ts +3 -18
- package/dist/candid/governance.did +386 -87
- package/dist/candid/governance.idl.js +1 -31
- package/dist/candid/governance_test.certified.idl.js +1 -31
- package/dist/candid/governance_test.d.ts +3 -18
- package/dist/candid/governance_test.did +388 -87
- package/dist/candid/governance_test.idl.js +1 -31
- package/dist/candid/sns_wasm.did +136 -27
- package/dist/cjs/index.cjs.js +1 -1
- package/dist/cjs/index.cjs.js.map +3 -3
- package/dist/esm/chunk-QAGO7B5R.js +19 -0
- package/dist/esm/chunk-QAGO7B5R.js.map +7 -0
- 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/types/types/governance_converters.d.ts +0 -6
- package/package.json +6 -6
- package/dist/esm/chunk-L6YE6E7N.js +0 -19
- package/dist/esm/chunk-L6YE6E7N.js.map +0 -7
|
@@ -1,5 +1,8 @@
|
|
|
1
|
-
// Generated from IC repo commit
|
|
2
|
-
type AccountIdentifier = record {
|
|
1
|
+
// Generated from IC repo commit c43a488 (2024-09-27 tags: release-2024-09-26_01-31-no-canister-snapshots) 'rs/nns/governance/canister/governance_test.did' by import-candid
|
|
2
|
+
type AccountIdentifier = record {
|
|
3
|
+
hash : blob;
|
|
4
|
+
};
|
|
5
|
+
|
|
3
6
|
type Action = variant {
|
|
4
7
|
RegisterKnownNeuron : KnownNeuron;
|
|
5
8
|
ManageNeuron : ManageNeuron;
|
|
@@ -18,18 +21,43 @@ type Action = variant {
|
|
|
18
21
|
AddOrRemoveNodeProvider : AddOrRemoveNodeProvider;
|
|
19
22
|
Motion : Motion;
|
|
20
23
|
};
|
|
21
|
-
|
|
22
|
-
type
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
type
|
|
24
|
+
|
|
25
|
+
type AddHotKey = record {
|
|
26
|
+
new_hot_key : opt principal;
|
|
27
|
+
};
|
|
28
|
+
|
|
29
|
+
type AddOrRemoveNodeProvider = record {
|
|
30
|
+
change : opt Change;
|
|
31
|
+
};
|
|
32
|
+
|
|
33
|
+
type Amount = record {
|
|
34
|
+
e8s : nat64;
|
|
35
|
+
};
|
|
36
|
+
|
|
37
|
+
type ApproveGenesisKyc = record {
|
|
38
|
+
principals : vec principal;
|
|
39
|
+
};
|
|
40
|
+
|
|
41
|
+
type Ballot = record {
|
|
42
|
+
vote : int32;
|
|
43
|
+
voting_power : nat64;
|
|
44
|
+
};
|
|
45
|
+
|
|
46
|
+
type BallotInfo = record {
|
|
47
|
+
vote : int32;
|
|
48
|
+
proposal_id : opt NeuronId;
|
|
49
|
+
};
|
|
50
|
+
|
|
27
51
|
type By = variant {
|
|
28
52
|
NeuronIdOrSubaccount : record {};
|
|
29
53
|
MemoAndController : ClaimOrRefreshNeuronFromAccount;
|
|
30
54
|
Memo : nat64;
|
|
31
55
|
};
|
|
32
|
-
|
|
56
|
+
|
|
57
|
+
type Canister = record {
|
|
58
|
+
id : opt principal;
|
|
59
|
+
};
|
|
60
|
+
|
|
33
61
|
type CanisterSettings = record {
|
|
34
62
|
freezing_threshold : opt nat64;
|
|
35
63
|
controllers : opt Controllers;
|
|
@@ -38,6 +66,7 @@ type CanisterSettings = record {
|
|
|
38
66
|
memory_allocation : opt nat64;
|
|
39
67
|
compute_allocation : opt nat64;
|
|
40
68
|
};
|
|
69
|
+
|
|
41
70
|
type CanisterStatusResultV2 = record {
|
|
42
71
|
status : opt int32;
|
|
43
72
|
freezing_threshold : opt nat64;
|
|
@@ -47,32 +76,38 @@ type CanisterStatusResultV2 = record {
|
|
|
47
76
|
idle_cycles_burned_per_day : opt nat64;
|
|
48
77
|
module_hash : blob;
|
|
49
78
|
};
|
|
79
|
+
|
|
50
80
|
type CanisterSummary = record {
|
|
51
81
|
status : opt CanisterStatusResultV2;
|
|
52
82
|
canister_id : opt principal;
|
|
53
83
|
};
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
amount_icp_e8s : nat64;
|
|
59
|
-
};
|
|
60
|
-
type CfParticipant = record {
|
|
61
|
-
controller : opt principal;
|
|
62
|
-
hotkey_principal : text;
|
|
63
|
-
cf_neurons : vec CfNeuron;
|
|
84
|
+
|
|
85
|
+
type Change = variant {
|
|
86
|
+
ToRemove : NodeProvider;
|
|
87
|
+
ToAdd : NodeProvider;
|
|
64
88
|
};
|
|
65
|
-
|
|
89
|
+
|
|
66
90
|
type ChangeAutoStakeMaturity = record {
|
|
67
91
|
requested_setting_for_auto_stake_maturity : bool;
|
|
68
92
|
};
|
|
69
|
-
|
|
93
|
+
|
|
94
|
+
type ClaimOrRefresh = record {
|
|
95
|
+
by : opt By;
|
|
96
|
+
};
|
|
97
|
+
|
|
70
98
|
type ClaimOrRefreshNeuronFromAccount = record {
|
|
71
99
|
controller : opt principal;
|
|
72
100
|
memo : nat64;
|
|
73
101
|
};
|
|
74
|
-
|
|
75
|
-
type
|
|
102
|
+
|
|
103
|
+
type ClaimOrRefreshNeuronFromAccountResponse = record {
|
|
104
|
+
result : opt Result_1;
|
|
105
|
+
};
|
|
106
|
+
|
|
107
|
+
type ClaimOrRefreshResponse = record {
|
|
108
|
+
refreshed_neuron_id : opt NeuronId;
|
|
109
|
+
};
|
|
110
|
+
|
|
76
111
|
type Command = variant {
|
|
77
112
|
Spawn : Spawn;
|
|
78
113
|
Split : Split;
|
|
@@ -87,6 +122,7 @@ type Command = variant {
|
|
|
87
122
|
MergeMaturity : MergeMaturity;
|
|
88
123
|
Disburse : Disburse;
|
|
89
124
|
};
|
|
125
|
+
|
|
90
126
|
type Command_1 = variant {
|
|
91
127
|
Error : GovernanceError;
|
|
92
128
|
Spawn : SpawnResponse;
|
|
@@ -102,6 +138,7 @@ type Command_1 = variant {
|
|
|
102
138
|
MergeMaturity : MergeMaturityResponse;
|
|
103
139
|
Disburse : DisburseResponse;
|
|
104
140
|
};
|
|
141
|
+
|
|
105
142
|
type Command_2 = variant {
|
|
106
143
|
Spawn : NeuronId;
|
|
107
144
|
Split : Split;
|
|
@@ -113,19 +150,31 @@ type Command_2 = variant {
|
|
|
113
150
|
MergeMaturity : MergeMaturity;
|
|
114
151
|
Disburse : Disburse;
|
|
115
152
|
};
|
|
153
|
+
|
|
116
154
|
type Committed = record {
|
|
117
155
|
total_direct_contribution_icp_e8s : opt nat64;
|
|
118
156
|
total_neurons_fund_contribution_icp_e8s : opt nat64;
|
|
119
157
|
sns_governance_canister_id : opt principal;
|
|
120
158
|
};
|
|
159
|
+
|
|
121
160
|
type Committed_1 = record {
|
|
122
161
|
total_direct_participation_icp_e8s : opt nat64;
|
|
123
162
|
total_neurons_fund_participation_icp_e8s : opt nat64;
|
|
124
163
|
sns_governance_canister_id : opt principal;
|
|
125
164
|
};
|
|
126
|
-
|
|
127
|
-
type
|
|
128
|
-
|
|
165
|
+
|
|
166
|
+
type Configure = record {
|
|
167
|
+
operation : opt Operation;
|
|
168
|
+
};
|
|
169
|
+
|
|
170
|
+
type Controllers = record {
|
|
171
|
+
controllers : vec principal;
|
|
172
|
+
};
|
|
173
|
+
|
|
174
|
+
type Countries = record {
|
|
175
|
+
iso_codes : vec text;
|
|
176
|
+
};
|
|
177
|
+
|
|
129
178
|
type CreateServiceNervousSystem = record {
|
|
130
179
|
url : opt text;
|
|
131
180
|
governance_parameters : opt GovernanceParameters;
|
|
@@ -138,22 +187,33 @@ type CreateServiceNervousSystem = record {
|
|
|
138
187
|
swap_parameters : opt SwapParameters;
|
|
139
188
|
initial_token_distribution : opt InitialTokenDistribution;
|
|
140
189
|
};
|
|
190
|
+
|
|
141
191
|
type DateRangeFilter = record {
|
|
142
192
|
start_timestamp_seconds : opt nat64;
|
|
143
193
|
end_timestamp_seconds : opt nat64;
|
|
144
194
|
};
|
|
145
|
-
|
|
195
|
+
|
|
196
|
+
type Decimal = record {
|
|
197
|
+
human_readable : opt text;
|
|
198
|
+
};
|
|
199
|
+
|
|
146
200
|
type DerivedProposalInformation = record {
|
|
147
201
|
swap_background_information : opt SwapBackgroundInformation;
|
|
148
202
|
};
|
|
203
|
+
|
|
149
204
|
type DeveloperDistribution = record {
|
|
150
205
|
developer_neurons : vec NeuronDistribution;
|
|
151
206
|
};
|
|
207
|
+
|
|
152
208
|
type Disburse = record {
|
|
153
209
|
to_account : opt AccountIdentifier;
|
|
154
210
|
amount : opt Amount;
|
|
155
211
|
};
|
|
156
|
-
|
|
212
|
+
|
|
213
|
+
type DisburseResponse = record {
|
|
214
|
+
transfer_block_height : nat64;
|
|
215
|
+
};
|
|
216
|
+
|
|
157
217
|
type DisburseToNeuron = record {
|
|
158
218
|
dissolve_delay_seconds : nat64;
|
|
159
219
|
kyc_verified : bool;
|
|
@@ -161,19 +221,52 @@ type DisburseToNeuron = record {
|
|
|
161
221
|
new_controller : opt principal;
|
|
162
222
|
nonce : nat64;
|
|
163
223
|
};
|
|
224
|
+
|
|
164
225
|
type DissolveState = variant {
|
|
165
226
|
DissolveDelaySeconds : nat64;
|
|
166
227
|
WhenDissolvedTimestampSeconds : nat64;
|
|
167
228
|
};
|
|
168
|
-
|
|
169
|
-
type
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
type
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
229
|
+
|
|
230
|
+
type Duration = record {
|
|
231
|
+
seconds : opt nat64;
|
|
232
|
+
};
|
|
233
|
+
|
|
234
|
+
type ExecuteNnsFunction = record {
|
|
235
|
+
nns_function : int32;
|
|
236
|
+
payload : blob;
|
|
237
|
+
};
|
|
238
|
+
|
|
239
|
+
type Follow = record {
|
|
240
|
+
topic : int32;
|
|
241
|
+
followees : vec NeuronId;
|
|
242
|
+
};
|
|
243
|
+
|
|
244
|
+
type Followees = record {
|
|
245
|
+
followees : vec NeuronId;
|
|
246
|
+
};
|
|
247
|
+
|
|
248
|
+
type Followers = record {
|
|
249
|
+
followers : vec NeuronId;
|
|
250
|
+
};
|
|
251
|
+
|
|
252
|
+
type FollowersMap = record {
|
|
253
|
+
followers_map : vec record {
|
|
254
|
+
nat64;
|
|
255
|
+
Followers;
|
|
256
|
+
} };
|
|
257
|
+
|
|
258
|
+
type GetNeuronsFundAuditInfoRequest = record {
|
|
259
|
+
nns_proposal_id : opt NeuronId;
|
|
260
|
+
};
|
|
261
|
+
|
|
262
|
+
type GetNeuronsFundAuditInfoResponse = record {
|
|
263
|
+
result : opt Result_6;
|
|
264
|
+
};
|
|
265
|
+
|
|
266
|
+
type GlobalTimeOfDay = record {
|
|
267
|
+
seconds_after_utc_midnight : opt nat64;
|
|
268
|
+
};
|
|
269
|
+
|
|
177
270
|
type Governance = record {
|
|
178
271
|
default_followees : vec record { int32; Followees };
|
|
179
272
|
making_sns_proposal : opt MakingSnsProposal;
|
|
@@ -198,6 +291,7 @@ type Governance = record {
|
|
|
198
291
|
neurons : vec record { nat64; Neuron };
|
|
199
292
|
genesis_timestamp_seconds : nat64;
|
|
200
293
|
};
|
|
294
|
+
|
|
201
295
|
type GovernanceCachedMetrics = record {
|
|
202
296
|
total_maturity_e8s_equivalent : nat64;
|
|
203
297
|
not_dissolving_neurons_e8s_buckets : vec record { nat64; float64 };
|
|
@@ -245,7 +339,12 @@ type GovernanceCachedMetrics = record {
|
|
|
245
339
|
timestamp_seconds : nat64;
|
|
246
340
|
seed_neuron_count : nat64;
|
|
247
341
|
};
|
|
248
|
-
|
|
342
|
+
|
|
343
|
+
type GovernanceError = record {
|
|
344
|
+
error_message : text;
|
|
345
|
+
error_type : int32;
|
|
346
|
+
};
|
|
347
|
+
|
|
249
348
|
type GovernanceParameters = record {
|
|
250
349
|
neuron_maximum_dissolve_delay_bonus : opt Percentage;
|
|
251
350
|
neuron_maximum_age_for_age_bonus : opt Duration;
|
|
@@ -258,18 +357,25 @@ type GovernanceParameters = record {
|
|
|
258
357
|
proposal_rejection_fee : opt Tokens;
|
|
259
358
|
voting_reward_parameters : opt VotingRewardParameters;
|
|
260
359
|
};
|
|
360
|
+
|
|
261
361
|
type IdealMatchedParticipationFunction = record {
|
|
262
362
|
serialized_representation : opt text;
|
|
263
363
|
};
|
|
264
|
-
|
|
364
|
+
|
|
365
|
+
type Image = record {
|
|
366
|
+
base64_encoding : opt text;
|
|
367
|
+
};
|
|
368
|
+
|
|
265
369
|
type IncreaseDissolveDelay = record {
|
|
266
370
|
additional_dissolve_delay_seconds : nat32;
|
|
267
371
|
};
|
|
372
|
+
|
|
268
373
|
type InitialTokenDistribution = record {
|
|
269
374
|
treasury_distribution : opt SwapDistribution;
|
|
270
375
|
developer_distribution : opt DeveloperDistribution;
|
|
271
376
|
swap_distribution : opt SwapDistribution;
|
|
272
377
|
};
|
|
378
|
+
|
|
273
379
|
type InstallCode = record {
|
|
274
380
|
skip_stopping_before_installing : opt bool;
|
|
275
381
|
wasm_module_hash : opt blob;
|
|
@@ -277,6 +383,7 @@ type InstallCode = record {
|
|
|
277
383
|
arg_hash : opt blob;
|
|
278
384
|
install_mode : opt int32;
|
|
279
385
|
};
|
|
386
|
+
|
|
280
387
|
type InstallCodeRequest = record {
|
|
281
388
|
arg : opt blob;
|
|
282
389
|
wasm_module : opt blob;
|
|
@@ -284,35 +391,52 @@ type InstallCodeRequest = record {
|
|
|
284
391
|
canister_id : opt principal;
|
|
285
392
|
install_mode : opt int32;
|
|
286
393
|
};
|
|
394
|
+
|
|
287
395
|
type KnownNeuron = record {
|
|
288
396
|
id : opt NeuronId;
|
|
289
397
|
known_neuron_data : opt KnownNeuronData;
|
|
290
398
|
};
|
|
291
|
-
|
|
399
|
+
|
|
400
|
+
type KnownNeuronData = record {
|
|
401
|
+
name : text;
|
|
402
|
+
description : opt text;
|
|
403
|
+
};
|
|
404
|
+
|
|
292
405
|
type LedgerParameters = record {
|
|
293
406
|
transaction_fee : opt Tokens;
|
|
294
407
|
token_symbol : opt text;
|
|
295
408
|
token_logo : opt Image;
|
|
296
409
|
token_name : opt text;
|
|
297
410
|
};
|
|
298
|
-
|
|
411
|
+
|
|
412
|
+
type ListKnownNeuronsResponse = record {
|
|
413
|
+
known_neurons : vec KnownNeuron;
|
|
414
|
+
};
|
|
415
|
+
|
|
299
416
|
type ListNeurons = record {
|
|
300
417
|
include_public_neurons_in_full_neurons : opt bool;
|
|
301
418
|
neuron_ids : vec nat64;
|
|
302
419
|
include_empty_neurons_readable_by_caller : opt bool;
|
|
303
420
|
include_neurons_readable_by_caller : bool;
|
|
304
421
|
};
|
|
422
|
+
|
|
305
423
|
type ListNeuronsResponse = record {
|
|
306
424
|
neuron_infos : vec record { nat64; NeuronInfo };
|
|
307
425
|
full_neurons : vec Neuron;
|
|
308
426
|
};
|
|
427
|
+
|
|
309
428
|
type ListNodeProviderRewardsRequest = record {
|
|
310
429
|
date_filter : opt DateRangeFilter;
|
|
311
430
|
};
|
|
431
|
+
|
|
312
432
|
type ListNodeProviderRewardsResponse = record {
|
|
313
433
|
rewards : vec MonthlyNodeProviderRewards;
|
|
314
434
|
};
|
|
315
|
-
|
|
435
|
+
|
|
436
|
+
type ListNodeProvidersResponse = record {
|
|
437
|
+
node_providers : vec NodeProvider;
|
|
438
|
+
};
|
|
439
|
+
|
|
316
440
|
type ListProposalInfo = record {
|
|
317
441
|
include_reward_status : vec int32;
|
|
318
442
|
omit_large_fields : opt bool;
|
|
@@ -322,27 +446,35 @@ type ListProposalInfo = record {
|
|
|
322
446
|
include_all_manage_neuron_proposals : opt bool;
|
|
323
447
|
include_status : vec int32;
|
|
324
448
|
};
|
|
325
|
-
|
|
449
|
+
|
|
450
|
+
type ListProposalInfoResponse = record {
|
|
451
|
+
proposal_info : vec ProposalInfo;
|
|
452
|
+
};
|
|
453
|
+
|
|
326
454
|
type MakeProposalRequest = record {
|
|
327
455
|
url : text;
|
|
328
456
|
title : opt text;
|
|
329
457
|
action : opt ProposalActionRequest;
|
|
330
458
|
summary : text;
|
|
331
459
|
};
|
|
460
|
+
|
|
332
461
|
type MakeProposalResponse = record {
|
|
333
462
|
message : opt text;
|
|
334
463
|
proposal_id : opt NeuronId;
|
|
335
464
|
};
|
|
465
|
+
|
|
336
466
|
type MakingSnsProposal = record {
|
|
337
467
|
proposal : opt Proposal;
|
|
338
468
|
caller : opt principal;
|
|
339
469
|
proposer_id : opt NeuronId;
|
|
340
470
|
};
|
|
471
|
+
|
|
341
472
|
type ManageNeuron = record {
|
|
342
473
|
id : opt NeuronId;
|
|
343
474
|
command : opt Command;
|
|
344
475
|
neuron_id_or_subaccount : opt NeuronIdOrSubaccount;
|
|
345
476
|
};
|
|
477
|
+
|
|
346
478
|
type ManageNeuronCommandRequest = variant {
|
|
347
479
|
Spawn : Spawn;
|
|
348
480
|
Split : Split;
|
|
@@ -357,33 +489,48 @@ type ManageNeuronCommandRequest = variant {
|
|
|
357
489
|
MergeMaturity : MergeMaturity;
|
|
358
490
|
Disburse : Disburse;
|
|
359
491
|
};
|
|
492
|
+
|
|
360
493
|
type ManageNeuronRequest = record {
|
|
361
494
|
id : opt NeuronId;
|
|
362
495
|
command : opt ManageNeuronCommandRequest;
|
|
363
496
|
neuron_id_or_subaccount : opt NeuronIdOrSubaccount;
|
|
364
497
|
};
|
|
365
|
-
|
|
366
|
-
type
|
|
367
|
-
|
|
498
|
+
|
|
499
|
+
type ManageNeuronResponse = record {
|
|
500
|
+
command : opt Command_1;
|
|
501
|
+
};
|
|
502
|
+
|
|
503
|
+
type Merge = record {
|
|
504
|
+
source_neuron_id : opt NeuronId;
|
|
505
|
+
};
|
|
506
|
+
|
|
507
|
+
type MergeMaturity = record {
|
|
508
|
+
percentage_to_merge : nat32;
|
|
509
|
+
};
|
|
510
|
+
|
|
368
511
|
type MergeMaturityResponse = record {
|
|
369
512
|
merged_maturity_e8s : nat64;
|
|
370
513
|
new_stake_e8s : nat64;
|
|
371
514
|
};
|
|
515
|
+
|
|
372
516
|
type MergeResponse = record {
|
|
373
517
|
target_neuron : opt Neuron;
|
|
374
518
|
source_neuron : opt Neuron;
|
|
375
519
|
target_neuron_info : opt NeuronInfo;
|
|
376
520
|
source_neuron_info : opt NeuronInfo;
|
|
377
521
|
};
|
|
522
|
+
|
|
378
523
|
type Migration = record {
|
|
379
524
|
status : opt int32;
|
|
380
525
|
failure_reason : opt text;
|
|
381
526
|
progress : opt Progress;
|
|
382
527
|
};
|
|
528
|
+
|
|
383
529
|
type Migrations = record {
|
|
384
530
|
neuron_indexes_migration : opt Migration;
|
|
385
531
|
copy_inactive_neurons_to_stable_memory_migration : opt Migration;
|
|
386
532
|
};
|
|
533
|
+
|
|
387
534
|
type MonthlyNodeProviderRewards = record {
|
|
388
535
|
minimum_xdr_permyriad_per_icp : opt nat64;
|
|
389
536
|
registry_version : opt nat64;
|
|
@@ -393,7 +540,11 @@ type MonthlyNodeProviderRewards = record {
|
|
|
393
540
|
xdr_conversion_rate : opt XdrConversionRate;
|
|
394
541
|
maximum_node_provider_rewards_e8s : opt nat64;
|
|
395
542
|
};
|
|
396
|
-
|
|
543
|
+
|
|
544
|
+
type Motion = record {
|
|
545
|
+
motion_text : text;
|
|
546
|
+
};
|
|
547
|
+
|
|
397
548
|
type NetworkEconomics = record {
|
|
398
549
|
neuron_minimum_stake_e8s : nat64;
|
|
399
550
|
max_proposals_to_keep_per_topic : nat32;
|
|
@@ -405,6 +556,7 @@ type NetworkEconomics = record {
|
|
|
405
556
|
maximum_node_provider_rewards_e8s : nat64;
|
|
406
557
|
neurons_fund_economics : opt NeuronsFundEconomics;
|
|
407
558
|
};
|
|
559
|
+
|
|
408
560
|
type Neuron = record {
|
|
409
561
|
id : opt NeuronId;
|
|
410
562
|
staked_maturity_e8s_equivalent : opt nat64;
|
|
@@ -429,14 +581,17 @@ type Neuron = record {
|
|
|
429
581
|
known_neuron_data : opt KnownNeuronData;
|
|
430
582
|
spawn_at_timestamp_seconds : opt nat64;
|
|
431
583
|
};
|
|
584
|
+
|
|
432
585
|
type NeuronBasketConstructionParameters = record {
|
|
433
586
|
dissolve_delay_interval : opt Duration;
|
|
434
587
|
count : opt nat64;
|
|
435
588
|
};
|
|
589
|
+
|
|
436
590
|
type NeuronBasketConstructionParameters_1 = record {
|
|
437
591
|
dissolve_delay_interval_seconds : nat64;
|
|
438
592
|
count : nat64;
|
|
439
593
|
};
|
|
594
|
+
|
|
440
595
|
type NeuronDistribution = record {
|
|
441
596
|
controller : opt principal;
|
|
442
597
|
dissolve_delay : opt Duration;
|
|
@@ -444,12 +599,21 @@ type NeuronDistribution = record {
|
|
|
444
599
|
vesting_period : opt Duration;
|
|
445
600
|
stake : opt Tokens;
|
|
446
601
|
};
|
|
447
|
-
|
|
448
|
-
type
|
|
602
|
+
|
|
603
|
+
type NeuronId = record {
|
|
604
|
+
id : nat64;
|
|
605
|
+
};
|
|
606
|
+
|
|
607
|
+
type NeuronIdOrSubaccount = variant {
|
|
608
|
+
Subaccount : blob;
|
|
609
|
+
NeuronId : NeuronId;
|
|
610
|
+
};
|
|
611
|
+
|
|
449
612
|
type NeuronInFlightCommand = record {
|
|
450
613
|
command : opt Command_2;
|
|
451
614
|
timestamp : nat64;
|
|
452
615
|
};
|
|
616
|
+
|
|
453
617
|
type NeuronInfo = record {
|
|
454
618
|
dissolve_delay_seconds : nat64;
|
|
455
619
|
recent_ballots : vec BallotInfo;
|
|
@@ -464,6 +628,7 @@ type NeuronInfo = record {
|
|
|
464
628
|
voting_power : nat64;
|
|
465
629
|
age_seconds : nat64;
|
|
466
630
|
};
|
|
631
|
+
|
|
467
632
|
type NeuronStakeTransfer = record {
|
|
468
633
|
to_subaccount : blob;
|
|
469
634
|
neuron_stake_e8s : nat64;
|
|
@@ -473,6 +638,7 @@ type NeuronStakeTransfer = record {
|
|
|
473
638
|
transfer_timestamp : nat64;
|
|
474
639
|
block_height : nat64;
|
|
475
640
|
};
|
|
641
|
+
|
|
476
642
|
type NeuronSubsetMetrics = record {
|
|
477
643
|
total_maturity_e8s_equivalent : opt nat64;
|
|
478
644
|
maturity_e8s_equivalent_buckets : vec record { nat64; nat64 };
|
|
@@ -485,44 +651,49 @@ type NeuronSubsetMetrics = record {
|
|
|
485
651
|
total_voting_power : opt nat64;
|
|
486
652
|
count_buckets : vec record { nat64; nat64 };
|
|
487
653
|
};
|
|
654
|
+
|
|
488
655
|
type NeuronsFundAuditInfo = record {
|
|
489
656
|
final_neurons_fund_participation : opt NeuronsFundParticipation;
|
|
490
657
|
initial_neurons_fund_participation : opt NeuronsFundParticipation;
|
|
491
658
|
neurons_fund_refunds : opt NeuronsFundSnapshot;
|
|
492
659
|
};
|
|
660
|
+
|
|
493
661
|
type NeuronsFundData = record {
|
|
494
662
|
final_neurons_fund_participation : opt NeuronsFundParticipation;
|
|
495
663
|
initial_neurons_fund_participation : opt NeuronsFundParticipation;
|
|
496
664
|
neurons_fund_refunds : opt NeuronsFundSnapshot;
|
|
497
665
|
};
|
|
666
|
+
|
|
498
667
|
type NeuronsFundEconomics = record {
|
|
499
668
|
maximum_icp_xdr_rate : opt Percentage;
|
|
500
669
|
neurons_fund_matched_funding_curve_coefficients : opt NeuronsFundMatchedFundingCurveCoefficients;
|
|
501
670
|
max_theoretical_neurons_fund_participation_amount_xdr : opt Decimal;
|
|
502
671
|
minimum_icp_xdr_rate : opt Percentage;
|
|
503
672
|
};
|
|
673
|
+
|
|
504
674
|
type NeuronsFundMatchedFundingCurveCoefficients = record {
|
|
505
675
|
contribution_threshold_xdr : opt Decimal;
|
|
506
676
|
one_third_participation_milestone_xdr : opt Decimal;
|
|
507
677
|
full_participation_milestone_xdr : opt Decimal;
|
|
508
678
|
};
|
|
679
|
+
|
|
509
680
|
type NeuronsFundNeuron = record {
|
|
510
681
|
controller : opt principal;
|
|
511
|
-
hotkey_principal : opt text;
|
|
512
682
|
hotkeys : opt Principals;
|
|
513
683
|
is_capped : opt bool;
|
|
514
684
|
nns_neuron_id : opt nat64;
|
|
515
685
|
amount_icp_e8s : opt nat64;
|
|
516
686
|
};
|
|
687
|
+
|
|
517
688
|
type NeuronsFundNeuronPortion = record {
|
|
518
689
|
controller : opt principal;
|
|
519
|
-
hotkey_principal : opt principal;
|
|
520
690
|
hotkeys : vec principal;
|
|
521
691
|
is_capped : opt bool;
|
|
522
692
|
maturity_equivalent_icp_e8s : opt nat64;
|
|
523
693
|
nns_neuron_id : opt NeuronId;
|
|
524
694
|
amount_icp_e8s : opt nat64;
|
|
525
695
|
};
|
|
696
|
+
|
|
526
697
|
type NeuronsFundParticipation = record {
|
|
527
698
|
total_maturity_equivalent_icp_e8s : opt nat64;
|
|
528
699
|
intended_neurons_fund_participation_icp_e8s : opt nat64;
|
|
@@ -533,20 +704,30 @@ type NeuronsFundParticipation = record {
|
|
|
533
704
|
ideal_matched_participation_function : opt IdealMatchedParticipationFunction;
|
|
534
705
|
allocated_neurons_fund_participation_icp_e8s : opt nat64;
|
|
535
706
|
};
|
|
707
|
+
|
|
536
708
|
type NeuronsFundSnapshot = record {
|
|
537
709
|
neurons_fund_neuron_portions : vec NeuronsFundNeuronPortion;
|
|
538
710
|
};
|
|
711
|
+
|
|
539
712
|
type NodeProvider = record {
|
|
540
713
|
id : opt principal;
|
|
541
714
|
reward_account : opt AccountIdentifier;
|
|
542
715
|
};
|
|
543
|
-
|
|
544
|
-
type
|
|
716
|
+
|
|
717
|
+
type Ok = record {
|
|
718
|
+
neurons_fund_audit_info : opt NeuronsFundAuditInfo;
|
|
719
|
+
};
|
|
720
|
+
|
|
721
|
+
type Ok_1 = record {
|
|
722
|
+
neurons_fund_neuron_portions : vec NeuronsFundNeuron;
|
|
723
|
+
};
|
|
724
|
+
|
|
545
725
|
type OpenSnsTokenSwap = record {
|
|
546
726
|
community_fund_investment_e8s : opt nat64;
|
|
547
727
|
target_swap_canister_id : opt principal;
|
|
548
728
|
params : opt Params;
|
|
549
729
|
};
|
|
730
|
+
|
|
550
731
|
type Operation = variant {
|
|
551
732
|
RemoveHotKey : RemoveHotKey;
|
|
552
733
|
AddHotKey : AddHotKey;
|
|
@@ -559,6 +740,7 @@ type Operation = variant {
|
|
|
559
740
|
LeaveCommunityFund : record {};
|
|
560
741
|
SetDissolveTimestamp : SetDissolveTimestamp;
|
|
561
742
|
};
|
|
743
|
+
|
|
562
744
|
type Params = record {
|
|
563
745
|
min_participant_icp_e8s : nat64;
|
|
564
746
|
neuron_basket_construction_parameters : opt NeuronBasketConstructionParameters_1;
|
|
@@ -572,15 +754,26 @@ type Params = record {
|
|
|
572
754
|
min_icp_e8s : nat64;
|
|
573
755
|
max_direct_participation_icp_e8s : opt nat64;
|
|
574
756
|
};
|
|
575
|
-
|
|
576
|
-
type
|
|
577
|
-
|
|
757
|
+
|
|
758
|
+
type Percentage = record {
|
|
759
|
+
basis_points : opt nat64;
|
|
760
|
+
};
|
|
761
|
+
|
|
762
|
+
type Principals = record {
|
|
763
|
+
principals : vec principal;
|
|
764
|
+
};
|
|
765
|
+
|
|
766
|
+
type Progress = variant {
|
|
767
|
+
LastNeuronId : NeuronId;
|
|
768
|
+
};
|
|
769
|
+
|
|
578
770
|
type Proposal = record {
|
|
579
771
|
url : text;
|
|
580
772
|
title : opt text;
|
|
581
773
|
action : opt Action;
|
|
582
774
|
summary : text;
|
|
583
775
|
};
|
|
776
|
+
|
|
584
777
|
type ProposalActionRequest = variant {
|
|
585
778
|
RegisterKnownNeuron : KnownNeuron;
|
|
586
779
|
ManageNeuron : ManageNeuronRequest;
|
|
@@ -590,19 +783,16 @@ type ProposalActionRequest = variant {
|
|
|
590
783
|
CreateServiceNervousSystem : CreateServiceNervousSystem;
|
|
591
784
|
ExecuteNnsFunction : ExecuteNnsFunction;
|
|
592
785
|
RewardNodeProvider : RewardNodeProvider;
|
|
593
|
-
OpenSnsTokenSwap : OpenSnsTokenSwap;
|
|
594
|
-
SetSnsTokenSwapOpenTimeWindow : SetSnsTokenSwapOpenTimeWindow;
|
|
595
|
-
SetDefaultFollowees : SetDefaultFollowees;
|
|
596
786
|
RewardNodeProviders : RewardNodeProviders;
|
|
597
787
|
ManageNetworkEconomics : NetworkEconomics;
|
|
598
788
|
ApproveGenesisKyc : Principals;
|
|
599
789
|
AddOrRemoveNodeProvider : AddOrRemoveNodeProvider;
|
|
600
790
|
Motion : Motion;
|
|
601
791
|
};
|
|
792
|
+
|
|
602
793
|
type ProposalData = record {
|
|
603
794
|
id : opt NeuronId;
|
|
604
795
|
failure_reason : opt GovernanceError;
|
|
605
|
-
cf_participants : vec CfParticipant;
|
|
606
796
|
ballots : vec record { nat64; Ballot };
|
|
607
797
|
proposal_timestamp_seconds : nat64;
|
|
608
798
|
reward_event_round : nat64;
|
|
@@ -619,6 +809,7 @@ type ProposalData = record {
|
|
|
619
809
|
executed_timestamp_seconds : nat64;
|
|
620
810
|
original_total_community_fund_maturity_e8s_equivalent : opt nat64;
|
|
621
811
|
};
|
|
812
|
+
|
|
622
813
|
type ProposalInfo = record {
|
|
623
814
|
id : opt NeuronId;
|
|
624
815
|
status : int32;
|
|
@@ -638,29 +829,81 @@ type ProposalInfo = record {
|
|
|
638
829
|
proposer : opt NeuronId;
|
|
639
830
|
executed_timestamp_seconds : nat64;
|
|
640
831
|
};
|
|
641
|
-
|
|
642
|
-
type
|
|
832
|
+
|
|
833
|
+
type RegisterVote = record {
|
|
834
|
+
vote : int32;
|
|
835
|
+
proposal : opt NeuronId;
|
|
836
|
+
};
|
|
837
|
+
|
|
838
|
+
type RemoveHotKey = record {
|
|
839
|
+
hot_key_to_remove : opt principal;
|
|
840
|
+
};
|
|
841
|
+
|
|
643
842
|
type RestoreAgingNeuronGroup = record {
|
|
644
843
|
count : opt nat64;
|
|
645
844
|
previous_total_stake_e8s : opt nat64;
|
|
646
845
|
current_total_stake_e8s : opt nat64;
|
|
647
846
|
group_type : int32;
|
|
648
847
|
};
|
|
848
|
+
|
|
649
849
|
type RestoreAgingSummary = record {
|
|
650
850
|
groups : vec RestoreAgingNeuronGroup;
|
|
651
851
|
timestamp_seconds : opt nat64;
|
|
652
852
|
};
|
|
653
|
-
|
|
654
|
-
type
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
type
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
|
|
853
|
+
|
|
854
|
+
type Result = variant {
|
|
855
|
+
Ok;
|
|
856
|
+
Err : GovernanceError;
|
|
857
|
+
};
|
|
858
|
+
|
|
859
|
+
type Result_1 = variant {
|
|
860
|
+
Error : GovernanceError;
|
|
861
|
+
NeuronId : NeuronId;
|
|
862
|
+
};
|
|
863
|
+
|
|
864
|
+
type Result_10 = variant {
|
|
865
|
+
Ok : Ok_1;
|
|
866
|
+
Err : GovernanceError;
|
|
867
|
+
};
|
|
868
|
+
|
|
869
|
+
type Result_2 = variant {
|
|
870
|
+
Ok : Neuron;
|
|
871
|
+
Err : GovernanceError;
|
|
872
|
+
};
|
|
873
|
+
|
|
874
|
+
type Result_3 = variant {
|
|
875
|
+
Ok : GovernanceCachedMetrics;
|
|
876
|
+
Err : GovernanceError;
|
|
877
|
+
};
|
|
878
|
+
|
|
879
|
+
type Result_4 = variant {
|
|
880
|
+
Ok : MonthlyNodeProviderRewards;
|
|
881
|
+
Err : GovernanceError;
|
|
882
|
+
};
|
|
883
|
+
|
|
884
|
+
type Result_5 = variant {
|
|
885
|
+
Ok : NeuronInfo;
|
|
886
|
+
Err : GovernanceError;
|
|
887
|
+
};
|
|
888
|
+
|
|
889
|
+
type Result_6 = variant {
|
|
890
|
+
Ok : Ok;
|
|
891
|
+
Err : GovernanceError;
|
|
892
|
+
};
|
|
893
|
+
|
|
894
|
+
type Result_7 = variant {
|
|
895
|
+
Ok : NodeProvider;
|
|
896
|
+
Err : GovernanceError;
|
|
897
|
+
};
|
|
898
|
+
|
|
899
|
+
type Result_8 = variant {
|
|
900
|
+
Committed : Committed;
|
|
901
|
+
Aborted : record {} };
|
|
902
|
+
|
|
903
|
+
type Result_9 = variant {
|
|
904
|
+
Committed : Committed_1;
|
|
905
|
+
Aborted : record {} };
|
|
906
|
+
|
|
664
907
|
type RewardEvent = record {
|
|
665
908
|
rounds_since_last_distribution : opt nat64;
|
|
666
909
|
day_after_genesis : nat64;
|
|
@@ -670,56 +913,94 @@ type RewardEvent = record {
|
|
|
670
913
|
distributed_e8s_equivalent : nat64;
|
|
671
914
|
settled_proposals : vec NeuronId;
|
|
672
915
|
};
|
|
916
|
+
|
|
673
917
|
type RewardMode = variant {
|
|
674
918
|
RewardToNeuron : RewardToNeuron;
|
|
675
919
|
RewardToAccount : RewardToAccount;
|
|
676
920
|
};
|
|
921
|
+
|
|
677
922
|
type RewardNodeProvider = record {
|
|
678
923
|
node_provider : opt NodeProvider;
|
|
679
924
|
reward_mode : opt RewardMode;
|
|
680
925
|
amount_e8s : nat64;
|
|
681
926
|
};
|
|
927
|
+
|
|
682
928
|
type RewardNodeProviders = record {
|
|
683
929
|
use_registry_derived_rewards : opt bool;
|
|
684
930
|
rewards : vec RewardNodeProvider;
|
|
685
931
|
};
|
|
686
|
-
|
|
687
|
-
type
|
|
932
|
+
|
|
933
|
+
type RewardToAccount = record {
|
|
934
|
+
to_account : opt AccountIdentifier;
|
|
935
|
+
};
|
|
936
|
+
|
|
937
|
+
type RewardToNeuron = record {
|
|
938
|
+
dissolve_delay_seconds : nat64;
|
|
939
|
+
};
|
|
940
|
+
|
|
688
941
|
type SetDefaultFollowees = record {
|
|
689
942
|
default_followees : vec record { int32; Followees };
|
|
690
943
|
};
|
|
691
|
-
|
|
692
|
-
type
|
|
944
|
+
|
|
945
|
+
type SetDissolveTimestamp = record {
|
|
946
|
+
dissolve_timestamp_seconds : nat64;
|
|
947
|
+
};
|
|
948
|
+
|
|
949
|
+
type SetOpenTimeWindowRequest = record {
|
|
950
|
+
open_time_window : opt TimeWindow;
|
|
951
|
+
};
|
|
952
|
+
|
|
693
953
|
type SetSnsTokenSwapOpenTimeWindow = record {
|
|
694
954
|
request : opt SetOpenTimeWindowRequest;
|
|
695
955
|
swap_canister_id : opt principal;
|
|
696
956
|
};
|
|
697
|
-
|
|
957
|
+
|
|
958
|
+
type SetVisibility = record {
|
|
959
|
+
visibility : opt int32;
|
|
960
|
+
};
|
|
961
|
+
|
|
698
962
|
type SettleCommunityFundParticipation = record {
|
|
699
963
|
result : opt Result_8;
|
|
700
964
|
open_sns_token_swap_proposal_id : opt nat64;
|
|
701
965
|
};
|
|
966
|
+
|
|
702
967
|
type SettleNeuronsFundParticipationRequest = record {
|
|
703
968
|
result : opt Result_9;
|
|
704
969
|
nns_proposal_id : opt nat64;
|
|
705
970
|
};
|
|
706
|
-
|
|
971
|
+
|
|
972
|
+
type SettleNeuronsFundParticipationResponse = record {
|
|
973
|
+
result : opt Result_10;
|
|
974
|
+
};
|
|
975
|
+
|
|
707
976
|
type Spawn = record {
|
|
708
977
|
percentage_to_spawn : opt nat32;
|
|
709
978
|
new_controller : opt principal;
|
|
710
979
|
nonce : opt nat64;
|
|
711
980
|
};
|
|
712
|
-
|
|
713
|
-
type
|
|
714
|
-
|
|
981
|
+
|
|
982
|
+
type SpawnResponse = record {
|
|
983
|
+
created_neuron_id : opt NeuronId;
|
|
984
|
+
};
|
|
985
|
+
|
|
986
|
+
type Split = record {
|
|
987
|
+
amount_e8s : nat64;
|
|
988
|
+
};
|
|
989
|
+
|
|
990
|
+
type StakeMaturity = record {
|
|
991
|
+
percentage_to_stake : opt nat32;
|
|
992
|
+
};
|
|
993
|
+
|
|
715
994
|
type StakeMaturityResponse = record {
|
|
716
995
|
maturity_e8s : nat64;
|
|
717
996
|
staked_maturity_e8s : nat64;
|
|
718
997
|
};
|
|
998
|
+
|
|
719
999
|
type StopOrStartCanister = record {
|
|
720
1000
|
action : opt int32;
|
|
721
1001
|
canister_id : opt principal;
|
|
722
1002
|
};
|
|
1003
|
+
|
|
723
1004
|
type SwapBackgroundInformation = record {
|
|
724
1005
|
ledger_index_canister_summary : opt CanisterSummary;
|
|
725
1006
|
fallback_controller_principal_ids : vec principal;
|
|
@@ -730,7 +1011,11 @@ type SwapBackgroundInformation = record {
|
|
|
730
1011
|
root_canister_summary : opt CanisterSummary;
|
|
731
1012
|
dapp_canister_summaries : vec CanisterSummary;
|
|
732
1013
|
};
|
|
733
|
-
|
|
1014
|
+
|
|
1015
|
+
type SwapDistribution = record {
|
|
1016
|
+
total : opt Tokens;
|
|
1017
|
+
};
|
|
1018
|
+
|
|
734
1019
|
type SwapParameters = record {
|
|
735
1020
|
minimum_participants : opt nat64;
|
|
736
1021
|
neurons_fund_participation : opt bool;
|
|
@@ -747,38 +1032,54 @@ type SwapParameters = record {
|
|
|
747
1032
|
neurons_fund_investment_icp : opt Tokens;
|
|
748
1033
|
restricted_countries : opt Countries;
|
|
749
1034
|
};
|
|
1035
|
+
|
|
750
1036
|
type SwapParticipationLimits = record {
|
|
751
1037
|
min_participant_icp_e8s : opt nat64;
|
|
752
1038
|
max_participant_icp_e8s : opt nat64;
|
|
753
1039
|
min_direct_participation_icp_e8s : opt nat64;
|
|
754
1040
|
max_direct_participation_icp_e8s : opt nat64;
|
|
755
1041
|
};
|
|
1042
|
+
|
|
756
1043
|
type Tally = record {
|
|
757
1044
|
no : nat64;
|
|
758
1045
|
yes : nat64;
|
|
759
1046
|
total : nat64;
|
|
760
1047
|
timestamp_seconds : nat64;
|
|
761
1048
|
};
|
|
1049
|
+
|
|
762
1050
|
type TimeWindow = record {
|
|
763
1051
|
start_timestamp_seconds : nat64;
|
|
764
1052
|
end_timestamp_seconds : nat64;
|
|
765
1053
|
};
|
|
766
|
-
|
|
1054
|
+
|
|
1055
|
+
type Tokens = record {
|
|
1056
|
+
e8s : opt nat64;
|
|
1057
|
+
};
|
|
1058
|
+
|
|
767
1059
|
type UpdateCanisterSettings = record {
|
|
768
1060
|
canister_id : opt principal;
|
|
769
1061
|
settings : opt CanisterSettings;
|
|
770
1062
|
};
|
|
771
|
-
|
|
1063
|
+
|
|
1064
|
+
type UpdateNodeProvider = record {
|
|
1065
|
+
reward_account : opt AccountIdentifier;
|
|
1066
|
+
};
|
|
1067
|
+
|
|
772
1068
|
type VotingRewardParameters = record {
|
|
773
1069
|
reward_rate_transition_duration : opt Duration;
|
|
774
1070
|
initial_reward_rate : opt Percentage;
|
|
775
1071
|
final_reward_rate : opt Percentage;
|
|
776
1072
|
};
|
|
777
|
-
|
|
1073
|
+
|
|
1074
|
+
type WaitForQuietState = record {
|
|
1075
|
+
current_deadline_timestamp_seconds : nat64;
|
|
1076
|
+
};
|
|
1077
|
+
|
|
778
1078
|
type XdrConversionRate = record {
|
|
779
1079
|
xdr_permyriad_per_icp : opt nat64;
|
|
780
1080
|
timestamp_seconds : opt nat64;
|
|
781
1081
|
};
|
|
1082
|
+
|
|
782
1083
|
service : (Governance) -> {
|
|
783
1084
|
claim_gtc_neurons : (principal, vec NeuronId) -> (Result);
|
|
784
1085
|
claim_or_refresh_neuron_from_account : (ClaimOrRefreshNeuronFromAccount) -> (
|
|
@@ -826,4 +1127,4 @@ service : (Governance) -> {
|
|
|
826
1127
|
transfer_gtc_neuron : (NeuronId, NeuronId) -> (Result);
|
|
827
1128
|
update_neuron : (Neuron) -> (opt GovernanceError);
|
|
828
1129
|
update_node_provider : (UpdateNodeProvider) -> (Result);
|
|
829
|
-
}
|
|
1130
|
+
}
|