@dfinity/nns 8.0.1 → 8.1.0-next-2025-01-16

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/README.md CHANGED
@@ -173,7 +173,7 @@ Parameters:
173
173
 
174
174
  ### :factory: GovernanceCanister
175
175
 
176
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L88)
176
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L91)
177
177
 
178
178
  #### Methods
179
179
 
@@ -200,6 +200,7 @@ Parameters:
200
200
  - [registerVote](#gear-registervote)
201
201
  - [setFollowees](#gear-setfollowees)
202
202
  - [disburse](#gear-disburse)
203
+ - [refreshVotingPower](#gear-refreshvotingpower)
203
204
  - [mergeMaturity](#gear-mergematurity)
204
205
  - [stakeMaturity](#gear-stakematurity)
205
206
  - [spawnNeuron](#gear-spawnneuron)
@@ -208,6 +209,7 @@ Parameters:
208
209
  - [claimOrRefreshNeuronFromAccount](#gear-claimorrefreshneuronfromaccount)
209
210
  - [claimOrRefreshNeuron](#gear-claimorrefreshneuron)
210
211
  - [getNeuron](#gear-getneuron)
212
+ - [getNetworkEconomicsParameters](#gear-getnetworkeconomicsparameters)
211
213
 
212
214
  ##### :gear: create
213
215
 
@@ -215,7 +217,7 @@ Parameters:
215
217
  | -------- | ------------------------------------------------------------- |
216
218
  | `create` | `(options?: GovernanceCanisterOptions) => GovernanceCanister` |
217
219
 
218
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L103)
220
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L106)
219
221
 
220
222
  ##### :gear: listNeurons
221
223
 
@@ -232,7 +234,7 @@ The backend treats `includeEmptyNeurons` as true if absent.
232
234
  | ------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
233
235
  | `listNeurons` | `({ certified, neuronIds, includeEmptyNeurons, includePublicNeurons, }: { certified: boolean; neuronIds?: bigint[] or undefined; includeEmptyNeurons?: boolean or undefined; includePublicNeurons?: boolean or undefined; }) => Promise<NeuronInfo[]>` |
234
236
 
235
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L143)
237
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L146)
236
238
 
237
239
  ##### :gear: listKnownNeurons
238
240
 
@@ -246,7 +248,7 @@ it is fetched using a query call.
246
248
  | ------------------ | ------------------------------------------------- |
247
249
  | `listKnownNeurons` | `(certified?: boolean) => Promise<KnownNeuron[]>` |
248
250
 
249
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L186)
251
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L189)
250
252
 
251
253
  ##### :gear: getLastestRewardEvent
252
254
 
@@ -259,7 +261,7 @@ it's fetched using a query call.
259
261
  | ----------------------- | ----------------------------------------------- |
260
262
  | `getLastestRewardEvent` | `(certified?: boolean) => Promise<RewardEvent>` |
261
263
 
262
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L208)
264
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L211)
263
265
 
264
266
  ##### :gear: listProposals
265
267
 
@@ -278,7 +280,7 @@ Parameters:
278
280
  - `request`: the options to list the proposals (limit number of results, topics to search for, etc.)
279
281
  - `certified`: query or update calls
280
282
 
281
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L224)
283
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L227)
282
284
 
283
285
  ##### :gear: stakeNeuron
284
286
 
@@ -286,7 +288,7 @@ Parameters:
286
288
  | ------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
287
289
  | `stakeNeuron` | `({ stake, principal, fromSubAccount, ledgerCanister, createdAt, fee, }: { stake: bigint; principal: Principal; fromSubAccount?: number[] or undefined; ledgerCanister: LedgerCanister; createdAt?: bigint or undefined; fee?: bigint or undefined; }) => Promise<...>` |
288
290
 
289
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L243)
291
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L246)
290
292
 
291
293
  ##### :gear: increaseDissolveDelay
292
294
 
@@ -296,7 +298,7 @@ Increases dissolve delay of a neuron
296
298
  | ----------------------- | --------------------------------------------------------------------------------------------------------------------------------- |
297
299
  | `increaseDissolveDelay` | `({ neuronId, additionalDissolveDelaySeconds, }: { neuronId: bigint; additionalDissolveDelaySeconds: number; }) => Promise<void>` |
298
300
 
299
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L304)
301
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L307)
300
302
 
301
303
  ##### :gear: setDissolveDelay
302
304
 
@@ -307,7 +309,7 @@ The new date is now + dissolveDelaySeconds.
307
309
  | ------------------ | ------------------------------------------------------------------------------------------------------------- |
308
310
  | `setDissolveDelay` | `({ neuronId, dissolveDelaySeconds, }: { neuronId: bigint; dissolveDelaySeconds: number; }) => Promise<void>` |
309
311
 
310
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L330)
312
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L333)
311
313
 
312
314
  ##### :gear: startDissolving
313
315
 
@@ -317,7 +319,7 @@ Start dissolving process of a neuron
317
319
  | ----------------- | ------------------------------------- |
318
320
  | `startDissolving` | `(neuronId: bigint) => Promise<void>` |
319
321
 
320
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L353)
322
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L356)
321
323
 
322
324
  ##### :gear: stopDissolving
323
325
 
@@ -327,7 +329,7 @@ Stop dissolving process of a neuron
327
329
  | ---------------- | ------------------------------------- |
328
330
  | `stopDissolving` | `(neuronId: bigint) => Promise<void>` |
329
331
 
330
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L367)
332
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L370)
331
333
 
332
334
  ##### :gear: joinCommunityFund
333
335
 
@@ -337,7 +339,7 @@ Neuron joins the community fund
337
339
  | ------------------- | ------------------------------------- |
338
340
  | `joinCommunityFund` | `(neuronId: bigint) => Promise<void>` |
339
341
 
340
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L381)
342
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L384)
341
343
 
342
344
  ##### :gear: autoStakeMaturity
343
345
 
@@ -352,7 +354,7 @@ Parameters:
352
354
  - `neuronId`: The id of the neuron for which to request a change of the auto stake feature
353
355
  - `autoStake`: `true` to enable the auto-stake maturity for this neuron, `false` to turn it off
354
356
 
355
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L399)
357
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L402)
356
358
 
357
359
  ##### :gear: leaveCommunityFund
358
360
 
@@ -362,7 +364,7 @@ Neuron leaves the community fund
362
364
  | -------------------- | ------------------------------------- |
363
365
  | `leaveCommunityFund` | `(neuronId: bigint) => Promise<void>` |
364
366
 
365
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L414)
367
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L417)
366
368
 
367
369
  ##### :gear: setVisibility
368
370
 
@@ -372,7 +374,7 @@ Set visibility of a neuron
372
374
  | --------------- | ------------------------------------------------------------------- |
373
375
  | `setVisibility` | `(neuronId: bigint, visibility: NeuronVisibility) => Promise<void>` |
374
376
 
375
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L428)
377
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L431)
376
378
 
377
379
  ##### :gear: setNodeProviderAccount
378
380
 
@@ -383,7 +385,7 @@ Where the reward is paid to.
383
385
  | ------------------------ | ---------------------------------------------- |
384
386
  | `setNodeProviderAccount` | `(accountIdentifier: string) => Promise<void>` |
385
387
 
386
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L448)
388
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L451)
387
389
 
388
390
  ##### :gear: mergeNeurons
389
391
 
@@ -393,7 +395,7 @@ Merge two neurons
393
395
  | -------------- | --------------------------------------------------------------------------------- |
394
396
  | `mergeNeurons` | `(request: { sourceNeuronId: bigint; targetNeuronId: bigint; }) => Promise<void>` |
395
397
 
396
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L468)
398
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L471)
397
399
 
398
400
  ##### :gear: simulateMergeNeurons
399
401
 
@@ -403,7 +405,7 @@ Simulate merging two neurons
403
405
  | ---------------------- | --------------------------------------------------------------------------------------- |
404
406
  | `simulateMergeNeurons` | `(request: { sourceNeuronId: bigint; targetNeuronId: bigint; }) => Promise<NeuronInfo>` |
405
407
 
406
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L485)
408
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L488)
407
409
 
408
410
  ##### :gear: splitNeuron
409
411
 
@@ -413,7 +415,7 @@ Splits a neuron creating a new one
413
415
  | ------------- | ----------------------------------------------------------------------------------- |
414
416
  | `splitNeuron` | `({ neuronId, amount, }: { neuronId: bigint; amount: bigint; }) => Promise<bigint>` |
415
417
 
416
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L530)
418
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L533)
417
419
 
418
420
  ##### :gear: getProposal
419
421
 
@@ -426,7 +428,7 @@ it is fetched using a query call.
426
428
  | ------------- | ------------------------------------------------------------------------------------------------------------------------------- |
427
429
  | `getProposal` | `({ proposalId, certified, }: { proposalId: bigint; certified?: boolean or undefined; }) => Promise<ProposalInfo or undefined>` |
428
430
 
429
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L570)
431
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L573)
430
432
 
431
433
  ##### :gear: makeProposal
432
434
 
@@ -436,7 +438,7 @@ Create new proposal
436
438
  | -------------- | ---------------------------------------------------------------- |
437
439
  | `makeProposal` | `(request: MakeProposalRequest) => Promise<bigint or undefined>` |
438
440
 
439
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L588)
441
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L591)
440
442
 
441
443
  ##### :gear: registerVote
442
444
 
@@ -446,7 +448,7 @@ Registers vote for a proposal from the neuron passed.
446
448
  | -------------- | ----------------------------------------------------------------------------------------------------------- |
447
449
  | `registerVote` | `({ neuronId, vote, proposalId, }: { neuronId: bigint; vote: Vote; proposalId: bigint; }) => Promise<void>` |
448
450
 
449
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L609)
451
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L612)
450
452
 
451
453
  ##### :gear: setFollowees
452
454
 
@@ -456,7 +458,7 @@ Edit neuron followees per topic
456
458
  | -------------- | ------------------------------------------------- |
457
459
  | `setFollowees` | `(followRequest: FollowRequest) => Promise<void>` |
458
460
 
459
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L631)
461
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L634)
460
462
 
461
463
  ##### :gear: disburse
462
464
 
@@ -466,7 +468,19 @@ Disburse neuron on Account
466
468
  | ---------- | ----------------------------------------------------------------------------------------------------------------------------------------------- |
467
469
  | `disburse` | `({ neuronId, toAccountId, amount, }: { neuronId: bigint; toAccountId?: string or undefined; amount?: bigint or undefined; }) => Promise<void>` |
468
470
 
469
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L646)
471
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L649)
472
+
473
+ ##### :gear: refreshVotingPower
474
+
475
+ Refreshes voting power of a neuron
476
+ (Resets the `votingPowerRefreshedTimestampSeconds`
477
+ parameter of the neuron to the current time).
478
+
479
+ | Method | Type |
480
+ | -------------------- | --------------------------------------------------------- |
481
+ | `refreshVotingPower` | `({ neuronId, }: { neuronId: bigint; }) => Promise<void>` |
482
+
483
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L685)
470
484
 
471
485
  ##### :gear: mergeMaturity
472
486
 
@@ -476,7 +490,7 @@ Merge Maturity of a neuron
476
490
  | --------------- | ------------------------------------------------------------------------------------------------------- |
477
491
  | `mergeMaturity` | `({ neuronId, percentageToMerge, }: { neuronId: bigint; percentageToMerge: number; }) => Promise<void>` |
478
492
 
479
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L682)
493
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L707)
480
494
 
481
495
  ##### :gear: stakeMaturity
482
496
 
@@ -491,7 +505,7 @@ Parameters:
491
505
  - `neuronId`: The id of the neuron for which to stake the maturity
492
506
  - `percentageToStake`: Optional. Percentage of the current maturity to stake. If not provided, all of the neuron's current maturity will be staked.
493
507
 
494
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L711)
508
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L736)
495
509
 
496
510
  ##### :gear: spawnNeuron
497
511
 
@@ -501,7 +515,7 @@ Merge Maturity of a neuron
501
515
  | ------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
502
516
  | `spawnNeuron` | `({ neuronId, percentageToSpawn, newController, nonce, }: { neuronId: bigint; percentageToSpawn?: number or undefined; newController?: Principal or undefined; nonce?: bigint or undefined; }) => Promise<bigint>` |
503
517
 
504
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L733)
518
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L758)
505
519
 
506
520
  ##### :gear: addHotkey
507
521
 
@@ -511,7 +525,7 @@ Add hotkey to neuron
511
525
  | ----------- | ------------------------------------------------------------------------------------------ |
512
526
  | `addHotkey` | `({ neuronId, principal, }: { neuronId: bigint; principal: Principal; }) => Promise<void>` |
513
527
 
514
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L780)
528
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L805)
515
529
 
516
530
  ##### :gear: removeHotkey
517
531
 
@@ -521,7 +535,7 @@ Remove hotkey to neuron
521
535
  | -------------- | ------------------------------------------------------------------------------------------ |
522
536
  | `removeHotkey` | `({ neuronId, principal, }: { neuronId: bigint; principal: Principal; }) => Promise<void>` |
523
537
 
524
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L800)
538
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L825)
525
539
 
526
540
  ##### :gear: claimOrRefreshNeuronFromAccount
527
541
 
@@ -531,7 +545,7 @@ Gets the NeuronID of a newly created neuron.
531
545
  | --------------------------------- | ----------------------------------------------------------------------------------------------------------------- |
532
546
  | `claimOrRefreshNeuronFromAccount` | `({ memo, controller, }: { memo: bigint; controller?: Principal or undefined; }) => Promise<bigint or undefined>` |
533
547
 
534
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L818)
548
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L843)
535
549
 
536
550
  ##### :gear: claimOrRefreshNeuron
537
551
 
@@ -542,7 +556,7 @@ Uses query call only.
542
556
  | ---------------------- | ------------------------------------------------------------------------ |
543
557
  | `claimOrRefreshNeuron` | `(request: ClaimOrRefreshNeuronRequest) => Promise<bigint or undefined>` |
544
558
 
545
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L849)
559
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L874)
546
560
 
547
561
  ##### :gear: getNeuron
548
562
 
@@ -552,7 +566,17 @@ Return the data of the neuron provided as id.
552
566
  | ----------- | ----------------------------------------------------------------------------------------------------------- |
553
567
  | `getNeuron` | `({ certified, neuronId, }: { certified: boolean; neuronId: bigint; }) => Promise<NeuronInfo or undefined>` |
554
568
 
555
- [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L874)
569
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L899)
570
+
571
+ ##### :gear: getNetworkEconomicsParameters
572
+
573
+ Return the [Network Economics](https://github.com/dfinity/ic/blob/d90e934eb440c730d44d9d9b1ece2cc3f9505d05/rs/nns/governance/proto/ic_nns_governance/pb/v1/governance.proto#L1847).
574
+
575
+ | Method | Type |
576
+ | ------------------------------- | ------------------------------------------------------------------------ |
577
+ | `getNetworkEconomicsParameters` | `({ certified, }: { certified: boolean; }) => Promise<NetworkEconomics>` |
578
+
579
+ [:link: Source](https://github.com/dfinity/ic-js/tree/main/packages/nns/src/governance.canister.ts#L920)
556
580
 
557
581
  ### :factory: SnsWasmCanister
558
582
 
@@ -1,4 +1,4 @@
1
- // Generated from IC repo commit 5d20289 (2024-11-21 tags: release-2024-11-21_03-11-24.04-base-kernel) 'rs/nns/gtc/canister/gtc.did' by import-candid
1
+ // Generated from IC repo commit 0f35ac817b (2024-12-06) 'rs/nns/gtc/canister/gtc.did' by import-candid
2
2
  type AccountState = record {
3
3
  authenticated_principal_id : opt principal;
4
4
  successfully_transferred_neurons : vec TransferredNeuron;
@@ -22,6 +22,7 @@ export const idlFactory = ({ IDL }) => {
22
22
  'topic' : IDL.Int32,
23
23
  'followees' : IDL.Vec(NeuronId),
24
24
  });
25
+ const RefreshVotingPower = IDL.Record({});
25
26
  const ClaimOrRefreshNeuronFromAccount = IDL.Record({
26
27
  'controller' : IDL.Opt(IDL.Principal),
27
28
  'memo' : IDL.Nat64,
@@ -86,6 +87,7 @@ export const idlFactory = ({ IDL }) => {
86
87
  'Spawn' : Spawn,
87
88
  'Split' : Split,
88
89
  'Follow' : Follow,
90
+ 'RefreshVotingPower' : RefreshVotingPower,
89
91
  'ClaimOrRefresh' : ClaimOrRefresh,
90
92
  'Configure' : Configure,
91
93
  'RegisterVote' : RegisterVote,
@@ -274,6 +276,10 @@ export const idlFactory = ({ IDL }) => {
274
276
  'use_registry_derived_rewards' : IDL.Opt(IDL.Bool),
275
277
  'rewards' : IDL.Vec(RewardNodeProvider),
276
278
  });
279
+ const VotingPowerEconomics = IDL.Record({
280
+ 'start_reducing_voting_power_after_seconds' : IDL.Opt(IDL.Nat64),
281
+ 'clear_following_after_seconds' : IDL.Opt(IDL.Nat64),
282
+ });
277
283
  const Decimal = IDL.Record({ 'human_readable' : IDL.Opt(IDL.Text) });
278
284
  const NeuronsFundMatchedFundingCurveCoefficients = IDL.Record({
279
285
  'contribution_threshold_xdr' : IDL.Opt(Decimal),
@@ -290,6 +296,7 @@ export const idlFactory = ({ IDL }) => {
290
296
  });
291
297
  const NetworkEconomics = IDL.Record({
292
298
  'neuron_minimum_stake_e8s' : IDL.Nat64,
299
+ 'voting_power_economics' : IDL.Opt(VotingPowerEconomics),
293
300
  'max_proposals_to_keep_per_topic' : IDL.Nat32,
294
301
  'neuron_management_fee_per_proposal_e8s' : IDL.Nat64,
295
302
  'reject_cost_e8s' : IDL.Nat64,
@@ -602,9 +609,11 @@ export const idlFactory = ({ IDL }) => {
602
609
  'recent_ballots' : IDL.Vec(BallotInfo),
603
610
  'voting_power_refreshed_timestamp_seconds' : IDL.Opt(IDL.Nat64),
604
611
  'kyc_verified' : IDL.Bool,
612
+ 'potential_voting_power' : IDL.Opt(IDL.Nat64),
605
613
  'neuron_type' : IDL.Opt(IDL.Int32),
606
614
  'not_for_profit' : IDL.Bool,
607
615
  'maturity_e8s_equivalent' : IDL.Nat64,
616
+ 'deciding_voting_power' : IDL.Opt(IDL.Nat64),
608
617
  'cached_neuron_stake_e8s' : IDL.Nat64,
609
618
  'created_timestamp_seconds' : IDL.Nat64,
610
619
  'auto_stake_maturity' : IDL.Opt(IDL.Bool),
@@ -669,7 +678,9 @@ export const idlFactory = ({ IDL }) => {
669
678
  'dissolve_delay_seconds' : IDL.Nat64,
670
679
  'recent_ballots' : IDL.Vec(BallotInfo),
671
680
  'voting_power_refreshed_timestamp_seconds' : IDL.Opt(IDL.Nat64),
681
+ 'potential_voting_power' : IDL.Opt(IDL.Nat64),
672
682
  'neuron_type' : IDL.Opt(IDL.Int32),
683
+ 'deciding_voting_power' : IDL.Opt(IDL.Nat64),
673
684
  'created_timestamp_seconds' : IDL.Nat64,
674
685
  'state' : IDL.Int32,
675
686
  'stake_e8s' : IDL.Nat64,
@@ -790,6 +801,7 @@ export const idlFactory = ({ IDL }) => {
790
801
  'Spawn' : Spawn,
791
802
  'Split' : Split,
792
803
  'Follow' : Follow,
804
+ 'RefreshVotingPower' : RefreshVotingPower,
793
805
  'ClaimOrRefresh' : ClaimOrRefresh,
794
806
  'Configure' : Configure,
795
807
  'RegisterVote' : RegisterVote,
@@ -808,6 +820,7 @@ export const idlFactory = ({ IDL }) => {
808
820
  })
809
821
  );
810
822
  const SpawnResponse = IDL.Record({ 'created_neuron_id' : IDL.Opt(NeuronId) });
823
+ const RefreshVotingPowerResponse = IDL.Record({});
811
824
  const ClaimOrRefreshResponse = IDL.Record({
812
825
  'refreshed_neuron_id' : IDL.Opt(NeuronId),
813
826
  });
@@ -835,6 +848,7 @@ export const idlFactory = ({ IDL }) => {
835
848
  'Spawn' : SpawnResponse,
836
849
  'Split' : SpawnResponse,
837
850
  'Follow' : IDL.Record({}),
851
+ 'RefreshVotingPower' : RefreshVotingPowerResponse,
838
852
  'ClaimOrRefresh' : ClaimOrRefreshResponse,
839
853
  'Configure' : IDL.Record({}),
840
854
  'RegisterVote' : IDL.Record({}),
@@ -991,6 +1005,7 @@ export const init = ({ IDL }) => {
991
1005
  'topic' : IDL.Int32,
992
1006
  'followees' : IDL.Vec(NeuronId),
993
1007
  });
1008
+ const RefreshVotingPower = IDL.Record({});
994
1009
  const ClaimOrRefreshNeuronFromAccount = IDL.Record({
995
1010
  'controller' : IDL.Opt(IDL.Principal),
996
1011
  'memo' : IDL.Nat64,
@@ -1055,6 +1070,7 @@ export const init = ({ IDL }) => {
1055
1070
  'Spawn' : Spawn,
1056
1071
  'Split' : Split,
1057
1072
  'Follow' : Follow,
1073
+ 'RefreshVotingPower' : RefreshVotingPower,
1058
1074
  'ClaimOrRefresh' : ClaimOrRefresh,
1059
1075
  'Configure' : Configure,
1060
1076
  'RegisterVote' : RegisterVote,
@@ -1243,6 +1259,10 @@ export const init = ({ IDL }) => {
1243
1259
  'use_registry_derived_rewards' : IDL.Opt(IDL.Bool),
1244
1260
  'rewards' : IDL.Vec(RewardNodeProvider),
1245
1261
  });
1262
+ const VotingPowerEconomics = IDL.Record({
1263
+ 'start_reducing_voting_power_after_seconds' : IDL.Opt(IDL.Nat64),
1264
+ 'clear_following_after_seconds' : IDL.Opt(IDL.Nat64),
1265
+ });
1246
1266
  const Decimal = IDL.Record({ 'human_readable' : IDL.Opt(IDL.Text) });
1247
1267
  const NeuronsFundMatchedFundingCurveCoefficients = IDL.Record({
1248
1268
  'contribution_threshold_xdr' : IDL.Opt(Decimal),
@@ -1259,6 +1279,7 @@ export const init = ({ IDL }) => {
1259
1279
  });
1260
1280
  const NetworkEconomics = IDL.Record({
1261
1281
  'neuron_minimum_stake_e8s' : IDL.Nat64,
1282
+ 'voting_power_economics' : IDL.Opt(VotingPowerEconomics),
1262
1283
  'max_proposals_to_keep_per_topic' : IDL.Nat32,
1263
1284
  'neuron_management_fee_per_proposal_e8s' : IDL.Nat64,
1264
1285
  'reject_cost_e8s' : IDL.Nat64,
@@ -1571,9 +1592,11 @@ export const init = ({ IDL }) => {
1571
1592
  'recent_ballots' : IDL.Vec(BallotInfo),
1572
1593
  'voting_power_refreshed_timestamp_seconds' : IDL.Opt(IDL.Nat64),
1573
1594
  'kyc_verified' : IDL.Bool,
1595
+ 'potential_voting_power' : IDL.Opt(IDL.Nat64),
1574
1596
  'neuron_type' : IDL.Opt(IDL.Int32),
1575
1597
  'not_for_profit' : IDL.Bool,
1576
1598
  'maturity_e8s_equivalent' : IDL.Nat64,
1599
+ 'deciding_voting_power' : IDL.Opt(IDL.Nat64),
1577
1600
  'cached_neuron_stake_e8s' : IDL.Nat64,
1578
1601
  'created_timestamp_seconds' : IDL.Nat64,
1579
1602
  'auto_stake_maturity' : IDL.Opt(IDL.Bool),
@@ -91,6 +91,7 @@ export type Command =
91
91
  | { Spawn: Spawn }
92
92
  | { Split: Split }
93
93
  | { Follow: Follow }
94
+ | { RefreshVotingPower: RefreshVotingPower }
94
95
  | { ClaimOrRefresh: ClaimOrRefresh }
95
96
  | { Configure: Configure }
96
97
  | { RegisterVote: RegisterVote }
@@ -105,6 +106,7 @@ export type Command_1 =
105
106
  | { Spawn: SpawnResponse }
106
107
  | { Split: SpawnResponse }
107
108
  | { Follow: {} }
109
+ | { RefreshVotingPower: RefreshVotingPowerResponse }
108
110
  | { ClaimOrRefresh: ClaimOrRefreshResponse }
109
111
  | { Configure: {} }
110
112
  | { RegisterVote: {} }
@@ -401,6 +403,7 @@ export type ManageNeuronCommandRequest =
401
403
  | { Spawn: Spawn }
402
404
  | { Split: Split }
403
405
  | { Follow: Follow }
406
+ | { RefreshVotingPower: RefreshVotingPower }
404
407
  | { ClaimOrRefresh: ClaimOrRefresh }
405
408
  | { Configure: Configure }
406
409
  | { RegisterVote: RegisterVote }
@@ -457,6 +460,7 @@ export interface Motion {
457
460
  }
458
461
  export interface NetworkEconomics {
459
462
  neuron_minimum_stake_e8s: bigint;
463
+ voting_power_economics: [] | [VotingPowerEconomics];
460
464
  max_proposals_to_keep_per_topic: number;
461
465
  neuron_management_fee_per_proposal_e8s: bigint;
462
466
  reject_cost_e8s: bigint;
@@ -473,9 +477,11 @@ export interface Neuron {
473
477
  recent_ballots: Array<BallotInfo>;
474
478
  voting_power_refreshed_timestamp_seconds: [] | [bigint];
475
479
  kyc_verified: boolean;
480
+ potential_voting_power: [] | [bigint];
476
481
  neuron_type: [] | [number];
477
482
  not_for_profit: boolean;
478
483
  maturity_e8s_equivalent: bigint;
484
+ deciding_voting_power: [] | [bigint];
479
485
  cached_neuron_stake_e8s: bigint;
480
486
  created_timestamp_seconds: bigint;
481
487
  auto_stake_maturity: [] | [boolean];
@@ -520,7 +526,9 @@ export interface NeuronInfo {
520
526
  dissolve_delay_seconds: bigint;
521
527
  recent_ballots: Array<BallotInfo>;
522
528
  voting_power_refreshed_timestamp_seconds: [] | [bigint];
529
+ potential_voting_power: [] | [bigint];
523
530
  neuron_type: [] | [number];
531
+ deciding_voting_power: [] | [bigint];
524
532
  created_timestamp_seconds: bigint;
525
533
  state: number;
526
534
  stake_e8s: bigint;
@@ -716,6 +724,8 @@ export interface ProposalInfo {
716
724
  proposer: [] | [NeuronId];
717
725
  executed_timestamp_seconds: bigint;
718
726
  }
727
+ export type RefreshVotingPower = {};
728
+ export type RefreshVotingPowerResponse = {};
719
729
  export interface RegisterVote {
720
730
  vote: number;
721
731
  proposal: [] | [ProposalId];
@@ -881,6 +891,10 @@ export interface UpdateCanisterSettings {
881
891
  export interface UpdateNodeProvider {
882
892
  reward_account: [] | [AccountIdentifier];
883
893
  }
894
+ export interface VotingPowerEconomics {
895
+ start_reducing_voting_power_after_seconds: [] | [bigint];
896
+ clear_following_after_seconds: [] | [bigint];
897
+ }
884
898
  export interface VotingRewardParameters {
885
899
  reward_rate_transition_duration: [] | [Duration];
886
900
  initial_reward_rate: [] | [Percentage];