@dfinity/sns 5.0.0-next-2025-10-22.4 → 5.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/README.md +89 -89
- package/package.json +7 -7
package/README.md
CHANGED
|
@@ -96,11 +96,11 @@ Lookup for the canister ids of a Sns and initialize the wrapper to access its fe
|
|
|
96
96
|
| ---------------- | ---------------- |
|
|
97
97
|
| `initSnsWrapper` | `InitSnsWrapper` |
|
|
98
98
|
|
|
99
|
-
[:link: Source](https://github.com/dfinity/
|
|
99
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.ts#L36)
|
|
100
100
|
|
|
101
101
|
### :factory: SnsGovernanceCanister
|
|
102
102
|
|
|
103
|
-
[:link: Source](https://github.com/dfinity/
|
|
103
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/governance.canister.ts#L66)
|
|
104
104
|
|
|
105
105
|
#### Static Methods
|
|
106
106
|
|
|
@@ -118,7 +118,7 @@ Parameters:
|
|
|
118
118
|
|
|
119
119
|
- `options`: Miscellaneous options to initialize the canister. Its ID being the only mandatory parammeter.
|
|
120
120
|
|
|
121
|
-
[:link: Source](https://github.com/dfinity/
|
|
121
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/governance.canister.ts#L72)
|
|
122
122
|
|
|
123
123
|
#### Methods
|
|
124
124
|
|
|
@@ -157,7 +157,7 @@ List the neurons of the Sns
|
|
|
157
157
|
| ------------- | ----------------------------------------------------- |
|
|
158
158
|
| `listNeurons` | `(params: SnsListNeuronsParams) => Promise<Neuron[]>` |
|
|
159
159
|
|
|
160
|
-
[:link: Source](https://github.com/dfinity/
|
|
160
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/governance.canister.ts#L86)
|
|
161
161
|
|
|
162
162
|
##### :gear: listProposals
|
|
163
163
|
|
|
@@ -167,7 +167,7 @@ List the proposals of the Sns
|
|
|
167
167
|
| --------------- | -------------------------------------------------------------------- |
|
|
168
168
|
| `listProposals` | `(params: SnsListProposalsParams) => Promise<ListProposalsResponse>` |
|
|
169
169
|
|
|
170
|
-
[:link: Source](https://github.com/dfinity/
|
|
170
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/governance.canister.ts#L100)
|
|
171
171
|
|
|
172
172
|
##### :gear: listTopics
|
|
173
173
|
|
|
@@ -177,7 +177,7 @@ List the topics of the Sns
|
|
|
177
177
|
| ------------ | ------------------------------------------------------ |
|
|
178
178
|
| `listTopics` | `(params: QueryParams) => Promise<ListTopicsResponse>` |
|
|
179
179
|
|
|
180
|
-
[:link: Source](https://github.com/dfinity/
|
|
180
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/governance.canister.ts#L115)
|
|
181
181
|
|
|
182
182
|
##### :gear: getProposal
|
|
183
183
|
|
|
@@ -187,7 +187,7 @@ Get the proposal of the Sns
|
|
|
187
187
|
| ------------- | --------------------------------------------------------- |
|
|
188
188
|
| `getProposal` | `(params: SnsGetProposalParams) => Promise<ProposalData>` |
|
|
189
189
|
|
|
190
|
-
[:link: Source](https://github.com/dfinity/
|
|
190
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/governance.canister.ts#L126)
|
|
191
191
|
|
|
192
192
|
##### :gear: listNervousSystemFunctions
|
|
193
193
|
|
|
@@ -198,7 +198,7 @@ Neurons can follow other neurons in specific Nervous System Functions.
|
|
|
198
198
|
| ---------------------------- | ---------------------------------------------------------------------- |
|
|
199
199
|
| `listNervousSystemFunctions` | `(params: QueryParams) => Promise<ListNervousSystemFunctionsResponse>` |
|
|
200
200
|
|
|
201
|
-
[:link: Source](https://github.com/dfinity/
|
|
201
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/governance.canister.ts#L145)
|
|
202
202
|
|
|
203
203
|
##### :gear: metadata
|
|
204
204
|
|
|
@@ -208,7 +208,7 @@ Get the Sns metadata (title, description, etc.)
|
|
|
208
208
|
| ---------- | ------------------------------------------------------- |
|
|
209
209
|
| `metadata` | `(params: QueryParams) => Promise<GetMetadataResponse>` |
|
|
210
210
|
|
|
211
|
-
[:link: Source](https://github.com/dfinity/
|
|
211
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/governance.canister.ts#L153)
|
|
212
212
|
|
|
213
213
|
##### :gear: nervousSystemParameters
|
|
214
214
|
|
|
@@ -218,7 +218,7 @@ Get the Sns nervous system parameters (default followees, max dissolve delay, ma
|
|
|
218
218
|
| ------------------------- | ----------------------------------------------------------- |
|
|
219
219
|
| `nervousSystemParameters` | `(params: QueryParams) => Promise<NervousSystemParameters>` |
|
|
220
220
|
|
|
221
|
-
[:link: Source](https://github.com/dfinity/
|
|
221
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/governance.canister.ts#L159)
|
|
222
222
|
|
|
223
223
|
##### :gear: getNeuron
|
|
224
224
|
|
|
@@ -228,7 +228,7 @@ Get the neuron of the Sns
|
|
|
228
228
|
| ----------- | ------------------------------------------------- |
|
|
229
229
|
| `getNeuron` | `(params: SnsGetNeuronParams) => Promise<Neuron>` |
|
|
230
230
|
|
|
231
|
-
[:link: Source](https://github.com/dfinity/
|
|
231
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/governance.canister.ts#L167)
|
|
232
232
|
|
|
233
233
|
##### :gear: queryNeuron
|
|
234
234
|
|
|
@@ -238,7 +238,7 @@ Same as `getNeuron` but returns undefined instead of raising error when not foun
|
|
|
238
238
|
| ------------- | -------------------------------------------------------------- |
|
|
239
239
|
| `queryNeuron` | `(params: SnsGetNeuronParams) => Promise<Neuron or undefined>` |
|
|
240
240
|
|
|
241
|
-
[:link: Source](https://github.com/dfinity/
|
|
241
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/governance.canister.ts#L185)
|
|
242
242
|
|
|
243
243
|
##### :gear: manageNeuron
|
|
244
244
|
|
|
@@ -248,7 +248,7 @@ Manage neuron. For advanced users.
|
|
|
248
248
|
| -------------- | ---------------------------------------------------------- |
|
|
249
249
|
| `manageNeuron` | `(request: ManageNeuron) => Promise<ManageNeuronResponse>` |
|
|
250
250
|
|
|
251
|
-
[:link: Source](https://github.com/dfinity/
|
|
251
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/governance.canister.ts#L205)
|
|
252
252
|
|
|
253
253
|
##### :gear: addNeuronPermissions
|
|
254
254
|
|
|
@@ -258,7 +258,7 @@ Add permissions to a neuron for a specific principal
|
|
|
258
258
|
| ---------------------- | ------------------------------------------------------- |
|
|
259
259
|
| `addNeuronPermissions` | `(params: SnsNeuronPermissionsParams) => Promise<void>` |
|
|
260
260
|
|
|
261
|
-
[:link: Source](https://github.com/dfinity/
|
|
261
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/governance.canister.ts#L218)
|
|
262
262
|
|
|
263
263
|
##### :gear: removeNeuronPermissions
|
|
264
264
|
|
|
@@ -268,7 +268,7 @@ Remove permissions to a neuron for a specific principal
|
|
|
268
268
|
| ------------------------- | ------------------------------------------------------- |
|
|
269
269
|
| `removeNeuronPermissions` | `(params: SnsNeuronPermissionsParams) => Promise<void>` |
|
|
270
270
|
|
|
271
|
-
[:link: Source](https://github.com/dfinity/
|
|
271
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/governance.canister.ts#L228)
|
|
272
272
|
|
|
273
273
|
##### :gear: splitNeuron
|
|
274
274
|
|
|
@@ -278,7 +278,7 @@ Split neuron
|
|
|
278
278
|
| ------------- | ------------------------------------------------------------------ |
|
|
279
279
|
| `splitNeuron` | `(params: SnsSplitNeuronParams) => Promise<NeuronId or undefined>` |
|
|
280
280
|
|
|
281
|
-
[:link: Source](https://github.com/dfinity/
|
|
281
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/governance.canister.ts#L238)
|
|
282
282
|
|
|
283
283
|
##### :gear: disburse
|
|
284
284
|
|
|
@@ -288,7 +288,7 @@ Disburse neuron on Account
|
|
|
288
288
|
| ---------- | ---------------------------------------------------- |
|
|
289
289
|
| `disburse` | `(params: SnsDisburseNeuronParams) => Promise<void>` |
|
|
290
290
|
|
|
291
|
-
[:link: Source](https://github.com/dfinity/
|
|
291
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/governance.canister.ts#L269)
|
|
292
292
|
|
|
293
293
|
##### :gear: startDissolving
|
|
294
294
|
|
|
@@ -298,7 +298,7 @@ Start dissolving process of a neuron
|
|
|
298
298
|
| ----------------- | --------------------------------------- |
|
|
299
299
|
| `startDissolving` | `(neuronId: NeuronId) => Promise<void>` |
|
|
300
300
|
|
|
301
|
-
[:link: Source](https://github.com/dfinity/
|
|
301
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/governance.canister.ts#L277)
|
|
302
302
|
|
|
303
303
|
##### :gear: stopDissolving
|
|
304
304
|
|
|
@@ -308,7 +308,7 @@ Stop dissolving process of a neuron
|
|
|
308
308
|
| ---------------- | --------------------------------------- |
|
|
309
309
|
| `stopDissolving` | `(neuronId: NeuronId) => Promise<void>` |
|
|
310
310
|
|
|
311
|
-
[:link: Source](https://github.com/dfinity/
|
|
311
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/governance.canister.ts#L285)
|
|
312
312
|
|
|
313
313
|
##### :gear: stakeMaturity
|
|
314
314
|
|
|
@@ -323,7 +323,7 @@ Parameters:
|
|
|
323
323
|
- `neuronId`: The id of the neuron for which to stake the maturity
|
|
324
324
|
- `percentageToStake`: Optional. Percentage of the current maturity to stake. If not provided, all of the neuron's current maturity will be staked.
|
|
325
325
|
|
|
326
|
-
[:link: Source](https://github.com/dfinity/
|
|
326
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/governance.canister.ts#L297)
|
|
327
327
|
|
|
328
328
|
##### :gear: disburseMaturity
|
|
329
329
|
|
|
@@ -339,7 +339,7 @@ Parameters:
|
|
|
339
339
|
- `neuronId`: The id of the neuron for which to disburse the maturity
|
|
340
340
|
- `percentageToDisburse`: What percentage of the available maturity to disburse.
|
|
341
341
|
|
|
342
|
-
[:link: Source](https://github.com/dfinity/
|
|
342
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/governance.canister.ts#L318)
|
|
343
343
|
|
|
344
344
|
##### :gear: autoStakeMaturity
|
|
345
345
|
|
|
@@ -354,7 +354,7 @@ Parameters:
|
|
|
354
354
|
- `neuronId`: The id of the neuron for which to request a change of the auto stake feature
|
|
355
355
|
- `autoStake`: `true` to enable the auto-stake maturity for this neuron, `false` to turn it off
|
|
356
356
|
|
|
357
|
-
[:link: Source](https://github.com/dfinity/
|
|
357
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/governance.canister.ts#L334)
|
|
358
358
|
|
|
359
359
|
##### :gear: setDissolveTimestamp
|
|
360
360
|
|
|
@@ -364,7 +364,7 @@ Increase dissolve delay of a neuron
|
|
|
364
364
|
| ---------------------- | ---------------------------------------------------------- |
|
|
365
365
|
| `setDissolveTimestamp` | `(params: SnsSetDissolveTimestampParams) => Promise<void>` |
|
|
366
366
|
|
|
367
|
-
[:link: Source](https://github.com/dfinity/
|
|
367
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/governance.canister.ts#L344)
|
|
368
368
|
|
|
369
369
|
##### :gear: increaseDissolveDelay
|
|
370
370
|
|
|
@@ -374,7 +374,7 @@ Increase dissolve delay of a neuron
|
|
|
374
374
|
| ----------------------- | ----------------------------------------------------------- |
|
|
375
375
|
| `increaseDissolveDelay` | `(params: SnsIncreaseDissolveDelayParams) => Promise<void>` |
|
|
376
376
|
|
|
377
|
-
[:link: Source](https://github.com/dfinity/
|
|
377
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/governance.canister.ts#L354)
|
|
378
378
|
|
|
379
379
|
##### :gear: setTopicFollowees
|
|
380
380
|
|
|
@@ -384,7 +384,7 @@ Sets followees of a neuron for a specific Nervous System Function
|
|
|
384
384
|
| ------------------- | ------------------------------------------------- |
|
|
385
385
|
| `setTopicFollowees` | `(params: SnsSetTopicFollowees) => Promise<void>` |
|
|
386
386
|
|
|
387
|
-
[:link: Source](https://github.com/dfinity/
|
|
387
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/governance.canister.ts#L365)
|
|
388
388
|
|
|
389
389
|
##### :gear: setFollowing
|
|
390
390
|
|
|
@@ -394,7 +394,7 @@ Sets followees of a neuron for topics
|
|
|
394
394
|
| -------------- | -------------------------------------------------- |
|
|
395
395
|
| `setFollowing` | `(params: SnsSetFollowingParams) => Promise<void>` |
|
|
396
396
|
|
|
397
|
-
[:link: Source](https://github.com/dfinity/
|
|
397
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/governance.canister.ts#L373)
|
|
398
398
|
|
|
399
399
|
##### :gear: registerVote
|
|
400
400
|
|
|
@@ -404,7 +404,7 @@ Registers vote for a proposal from the neuron passed.
|
|
|
404
404
|
| -------------- | -------------------------------------------------- |
|
|
405
405
|
| `registerVote` | `(params: SnsRegisterVoteParams) => Promise<void>` |
|
|
406
406
|
|
|
407
|
-
[:link: Source](https://github.com/dfinity/
|
|
407
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/governance.canister.ts#L381)
|
|
408
408
|
|
|
409
409
|
##### :gear: refreshNeuron
|
|
410
410
|
|
|
@@ -414,7 +414,7 @@ Refresh neuron
|
|
|
414
414
|
| --------------- | --------------------------------------- |
|
|
415
415
|
| `refreshNeuron` | `(neuronId: NeuronId) => Promise<void>` |
|
|
416
416
|
|
|
417
|
-
[:link: Source](https://github.com/dfinity/
|
|
417
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/governance.canister.ts#L389)
|
|
418
418
|
|
|
419
419
|
##### :gear: claimNeuron
|
|
420
420
|
|
|
@@ -424,11 +424,11 @@ Claim neuron
|
|
|
424
424
|
| ------------- | -------------------------------------------------------------------------------- |
|
|
425
425
|
| `claimNeuron` | `({ memo, controller, subaccount, }: SnsClaimNeuronParams) => Promise<NeuronId>` |
|
|
426
426
|
|
|
427
|
-
[:link: Source](https://github.com/dfinity/
|
|
427
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/governance.canister.ts#L399)
|
|
428
428
|
|
|
429
429
|
### :factory: SnsRootCanister
|
|
430
430
|
|
|
431
|
-
[:link: Source](https://github.com/dfinity/
|
|
431
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/root.canister.ts#L10)
|
|
432
432
|
|
|
433
433
|
#### Static Methods
|
|
434
434
|
|
|
@@ -440,7 +440,7 @@ Claim neuron
|
|
|
440
440
|
| -------- | ------------------------------------------------------------ |
|
|
441
441
|
| `create` | `(options: SnsCanisterOptions<_SERVICE>) => SnsRootCanister` |
|
|
442
442
|
|
|
443
|
-
[:link: Source](https://github.com/dfinity/
|
|
443
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/root.canister.ts#L11)
|
|
444
444
|
|
|
445
445
|
#### Methods
|
|
446
446
|
|
|
@@ -464,11 +464,11 @@ Returns:
|
|
|
464
464
|
|
|
465
465
|
- A list of canisters ('root' | 'governance' | 'ledger' | 'dapps' | 'swap' | 'archives')
|
|
466
466
|
|
|
467
|
-
[:link: Source](https://github.com/dfinity/
|
|
467
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/root.canister.ts#L32)
|
|
468
468
|
|
|
469
469
|
### :factory: SnsSwapCanister
|
|
470
470
|
|
|
471
|
-
[:link: Source](https://github.com/dfinity/
|
|
471
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/swap.canister.ts#L33)
|
|
472
472
|
|
|
473
473
|
#### Static Methods
|
|
474
474
|
|
|
@@ -480,7 +480,7 @@ Returns:
|
|
|
480
480
|
| -------- | ------------------------------------------------------------ |
|
|
481
481
|
| `create` | `(options: SnsCanisterOptions<_SERVICE>) => SnsSwapCanister` |
|
|
482
482
|
|
|
483
|
-
[:link: Source](https://github.com/dfinity/
|
|
483
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/swap.canister.ts#L34)
|
|
484
484
|
|
|
485
485
|
#### Methods
|
|
486
486
|
|
|
@@ -503,7 +503,7 @@ Get the state of the swap
|
|
|
503
503
|
| ------- | ---------------------------------------------------- |
|
|
504
504
|
| `state` | `(params: QueryParams) => Promise<GetStateResponse>` |
|
|
505
505
|
|
|
506
|
-
[:link: Source](https://github.com/dfinity/
|
|
506
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/swap.canister.ts#L48)
|
|
507
507
|
|
|
508
508
|
##### :gear: notifyPaymentFailure
|
|
509
509
|
|
|
@@ -513,7 +513,7 @@ Notify of the payment failure to remove the ticket
|
|
|
513
513
|
| ---------------------- | ------------------------------------ |
|
|
514
514
|
| `notifyPaymentFailure` | `() => Promise<Ticket or undefined>` |
|
|
515
515
|
|
|
516
|
-
[:link: Source](https://github.com/dfinity/
|
|
516
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/swap.canister.ts#L54)
|
|
517
517
|
|
|
518
518
|
##### :gear: notifyParticipation
|
|
519
519
|
|
|
@@ -523,7 +523,7 @@ Notify of the user participating in the swap
|
|
|
523
523
|
| --------------------- | ---------------------------------------------------------------------------- |
|
|
524
524
|
| `notifyParticipation` | `(params: RefreshBuyerTokensRequest) => Promise<RefreshBuyerTokensResponse>` |
|
|
525
525
|
|
|
526
|
-
[:link: Source](https://github.com/dfinity/
|
|
526
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/swap.canister.ts#L64)
|
|
527
527
|
|
|
528
528
|
##### :gear: getUserCommitment
|
|
529
529
|
|
|
@@ -533,7 +533,7 @@ Get user commitment
|
|
|
533
533
|
| ------------------- | ------------------------------------------------------------------------------------ |
|
|
534
534
|
| `getUserCommitment` | `(params: GetBuyerStateRequest and QueryParams) => Promise<BuyerState or undefined>` |
|
|
535
535
|
|
|
536
|
-
[:link: Source](https://github.com/dfinity/
|
|
536
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/swap.canister.ts#L72)
|
|
537
537
|
|
|
538
538
|
##### :gear: getDerivedState
|
|
539
539
|
|
|
@@ -543,7 +543,7 @@ Get sale buyers state
|
|
|
543
543
|
| ----------------- | ------------------------------------------------------------------- |
|
|
544
544
|
| `getDerivedState` | `({ certified, }: QueryParams) => Promise<GetDerivedStateResponse>` |
|
|
545
545
|
|
|
546
|
-
[:link: Source](https://github.com/dfinity/
|
|
546
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/swap.canister.ts#L84)
|
|
547
547
|
|
|
548
548
|
##### :gear: getSaleParameters
|
|
549
549
|
|
|
@@ -553,7 +553,7 @@ Get sale parameters
|
|
|
553
553
|
| ------------------- | --------------------------------------------------------------------- |
|
|
554
554
|
| `getSaleParameters` | `({ certified, }: QueryParams) => Promise<GetSaleParametersResponse>` |
|
|
555
555
|
|
|
556
|
-
[:link: Source](https://github.com/dfinity/
|
|
556
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/swap.canister.ts#L92)
|
|
557
557
|
|
|
558
558
|
##### :gear: getOpenTicket
|
|
559
559
|
|
|
@@ -563,7 +563,7 @@ Return a sale ticket if created and not yet removed (payment flow)
|
|
|
563
563
|
| --------------- | ------------------------------------------------------- |
|
|
564
564
|
| `getOpenTicket` | `(params: QueryParams) => Promise<Ticket or undefined>` |
|
|
565
565
|
|
|
566
|
-
[:link: Source](https://github.com/dfinity/
|
|
566
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/swap.canister.ts#L100)
|
|
567
567
|
|
|
568
568
|
##### :gear: newSaleTicket
|
|
569
569
|
|
|
@@ -573,7 +573,7 @@ Create a sale ticket (payment flow)
|
|
|
573
573
|
| --------------- | -------------------------------------------------- |
|
|
574
574
|
| `newSaleTicket` | `(params: NewSaleTicketParams) => Promise<Ticket>` |
|
|
575
575
|
|
|
576
|
-
[:link: Source](https://github.com/dfinity/
|
|
576
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/swap.canister.ts#L117)
|
|
577
577
|
|
|
578
578
|
##### :gear: getLifecycle
|
|
579
579
|
|
|
@@ -583,7 +583,7 @@ Get sale lifecycle state
|
|
|
583
583
|
| -------------- | -------------------------------------------------------- |
|
|
584
584
|
| `getLifecycle` | `(params: QueryParams) => Promise<GetLifecycleResponse>` |
|
|
585
585
|
|
|
586
|
-
[:link: Source](https://github.com/dfinity/
|
|
586
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/swap.canister.ts#L142)
|
|
587
587
|
|
|
588
588
|
##### :gear: getFinalizationStatus
|
|
589
589
|
|
|
@@ -593,7 +593,7 @@ Get sale lifecycle state
|
|
|
593
593
|
| ----------------------- | --------------------------------------------------------------------- |
|
|
594
594
|
| `getFinalizationStatus` | `(params: QueryParams) => Promise<GetAutoFinalizationStatusResponse>` |
|
|
595
595
|
|
|
596
|
-
[:link: Source](https://github.com/dfinity/
|
|
596
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/swap.canister.ts#L148)
|
|
597
597
|
|
|
598
598
|
### :factory: SnsWrapper
|
|
599
599
|
|
|
@@ -601,7 +601,7 @@ Sns wrapper - notably used by NNS-dapp - ease the access to a particular Sns.
|
|
|
601
601
|
It knows all the Sns' canisters, wrap and enhance their available features.
|
|
602
602
|
A wrapper either performs query or update calls.
|
|
603
603
|
|
|
604
|
-
[:link: Source](https://github.com/dfinity/
|
|
604
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L89)
|
|
605
605
|
|
|
606
606
|
#### Constructors
|
|
607
607
|
|
|
@@ -664,7 +664,7 @@ Parameters:
|
|
|
664
664
|
| ------------- | ------------------------------------------------------------------------ |
|
|
665
665
|
| `listNeurons` | `(params: Omit<SnsListNeuronsParams, "certified">) => Promise<Neuron[]>` |
|
|
666
666
|
|
|
667
|
-
[:link: Source](https://github.com/dfinity/
|
|
667
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L135)
|
|
668
668
|
|
|
669
669
|
##### :gear: listProposals
|
|
670
670
|
|
|
@@ -672,7 +672,7 @@ Parameters:
|
|
|
672
672
|
| --------------- | --------------------------------------------------------------------------------------- |
|
|
673
673
|
| `listProposals` | `(params: Omit<SnsListProposalsParams, "certified">) => Promise<ListProposalsResponse>` |
|
|
674
674
|
|
|
675
|
-
[:link: Source](https://github.com/dfinity/
|
|
675
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L139)
|
|
676
676
|
|
|
677
677
|
##### :gear: getProposal
|
|
678
678
|
|
|
@@ -680,7 +680,7 @@ Parameters:
|
|
|
680
680
|
| ------------- | ---------------------------------------------------------------------------- |
|
|
681
681
|
| `getProposal` | `(params: Omit<SnsGetProposalParams, "certified">) => Promise<ProposalData>` |
|
|
682
682
|
|
|
683
|
-
[:link: Source](https://github.com/dfinity/
|
|
683
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L144)
|
|
684
684
|
|
|
685
685
|
##### :gear: listNervousSystemFunctions
|
|
686
686
|
|
|
@@ -688,7 +688,7 @@ Parameters:
|
|
|
688
688
|
| ---------------------------- | ----------------------------------------------------------------------------------------- |
|
|
689
689
|
| `listNervousSystemFunctions` | `(params: Omit<QueryParams, "certified">) => Promise<ListNervousSystemFunctionsResponse>` |
|
|
690
690
|
|
|
691
|
-
[:link: Source](https://github.com/dfinity/
|
|
691
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L149)
|
|
692
692
|
|
|
693
693
|
##### :gear: metadata
|
|
694
694
|
|
|
@@ -696,7 +696,7 @@ Parameters:
|
|
|
696
696
|
| ---------- | ------------------------------------------------------------------------------------------------------- |
|
|
697
697
|
| `metadata` | `(params: Omit<QueryParams, "certified">) => Promise<[GetMetadataResponse, IcrcTokenMetadataResponse]>` |
|
|
698
698
|
|
|
699
|
-
[:link: Source](https://github.com/dfinity/
|
|
699
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L154)
|
|
700
700
|
|
|
701
701
|
##### :gear: nervousSystemParameters
|
|
702
702
|
|
|
@@ -704,7 +704,7 @@ Parameters:
|
|
|
704
704
|
| ------------------------- | ------------------------------------------------------------------------------ |
|
|
705
705
|
| `nervousSystemParameters` | `(params: Omit<QueryParams, "certified">) => Promise<NervousSystemParameters>` |
|
|
706
706
|
|
|
707
|
-
[:link: Source](https://github.com/dfinity/
|
|
707
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L162)
|
|
708
708
|
|
|
709
709
|
##### :gear: ledgerMetadata
|
|
710
710
|
|
|
@@ -712,7 +712,7 @@ Parameters:
|
|
|
712
712
|
| ---------------- | -------------------------------------------------------------------------------- |
|
|
713
713
|
| `ledgerMetadata` | `(params: Omit<QueryParams, "certified">) => Promise<IcrcTokenMetadataResponse>` |
|
|
714
714
|
|
|
715
|
-
[:link: Source](https://github.com/dfinity/
|
|
715
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L167)
|
|
716
716
|
|
|
717
717
|
##### :gear: transactionFee
|
|
718
718
|
|
|
@@ -720,7 +720,7 @@ Parameters:
|
|
|
720
720
|
| ---------------- | ------------------------------------------------------------- |
|
|
721
721
|
| `transactionFee` | `(params: Omit<QueryParams, "certified">) => Promise<bigint>` |
|
|
722
722
|
|
|
723
|
-
[:link: Source](https://github.com/dfinity/
|
|
723
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L172)
|
|
724
724
|
|
|
725
725
|
##### :gear: totalTokensSupply
|
|
726
726
|
|
|
@@ -728,7 +728,7 @@ Parameters:
|
|
|
728
728
|
| ------------------- | ------------------------------------------------------------- |
|
|
729
729
|
| `totalTokensSupply` | `(params: Omit<QueryParams, "certified">) => Promise<bigint>` |
|
|
730
730
|
|
|
731
|
-
[:link: Source](https://github.com/dfinity/
|
|
731
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L177)
|
|
732
732
|
|
|
733
733
|
##### :gear: balance
|
|
734
734
|
|
|
@@ -736,7 +736,7 @@ Parameters:
|
|
|
736
736
|
| --------- | --------------------------------------------------------------- |
|
|
737
737
|
| `balance` | `(params: Omit<BalanceParams, "certified">) => Promise<bigint>` |
|
|
738
738
|
|
|
739
|
-
[:link: Source](https://github.com/dfinity/
|
|
739
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L182)
|
|
740
740
|
|
|
741
741
|
##### :gear: transfer
|
|
742
742
|
|
|
@@ -744,7 +744,7 @@ Parameters:
|
|
|
744
744
|
| ---------- | --------------------------------------------- |
|
|
745
745
|
| `transfer` | `(params: TransferParams) => Promise<bigint>` |
|
|
746
746
|
|
|
747
|
-
[:link: Source](https://github.com/dfinity/
|
|
747
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L186)
|
|
748
748
|
|
|
749
749
|
##### :gear: getNeuron
|
|
750
750
|
|
|
@@ -752,7 +752,7 @@ Parameters:
|
|
|
752
752
|
| ----------- | -------------------------------------------------------------------- |
|
|
753
753
|
| `getNeuron` | `(params: Omit<SnsGetNeuronParams, "certified">) => Promise<Neuron>` |
|
|
754
754
|
|
|
755
|
-
[:link: Source](https://github.com/dfinity/
|
|
755
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L189)
|
|
756
756
|
|
|
757
757
|
##### :gear: queryNeuron
|
|
758
758
|
|
|
@@ -760,7 +760,7 @@ Parameters:
|
|
|
760
760
|
| ------------- | --------------------------------------------------------------------------------- |
|
|
761
761
|
| `queryNeuron` | `(params: Omit<SnsGetNeuronParams, "certified">) => Promise<Neuron or undefined>` |
|
|
762
762
|
|
|
763
|
-
[:link: Source](https://github.com/dfinity/
|
|
763
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L193)
|
|
764
764
|
|
|
765
765
|
##### :gear: nextNeuronAccount
|
|
766
766
|
|
|
@@ -780,7 +780,7 @@ This is how the backend can identify which neuron is being claimed.
|
|
|
780
780
|
| ------------------- | ------------------------------------------------------------------------------ |
|
|
781
781
|
| `nextNeuronAccount` | `(controller: Principal) => Promise<{ account: IcrcAccount; index: bigint; }>` |
|
|
782
782
|
|
|
783
|
-
[:link: Source](https://github.com/dfinity/
|
|
783
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L214)
|
|
784
784
|
|
|
785
785
|
##### :gear: stakeNeuron
|
|
786
786
|
|
|
@@ -794,7 +794,7 @@ This is a convenient method that transfers the stake to the neuron subaccount an
|
|
|
794
794
|
| ------------- | ------------------------------------------------------------------------------------------------ |
|
|
795
795
|
| `stakeNeuron` | `({ stakeE8s, source, controller, createdAt, fee, }: SnsStakeNeuronParams) => Promise<NeuronId>` |
|
|
796
796
|
|
|
797
|
-
[:link: Source](https://github.com/dfinity/
|
|
797
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L261)
|
|
798
798
|
|
|
799
799
|
##### :gear: increaseStakeNeuron
|
|
800
800
|
|
|
@@ -808,7 +808,7 @@ This is a convenient method that transfers the stake to the neuron subaccount an
|
|
|
808
808
|
| --------------------- | ---------------------------------------------------------------------------------- |
|
|
809
809
|
| `increaseStakeNeuron` | `({ stakeE8s, source, neuronId, }: SnsIncreaseStakeNeuronParams) => Promise<void>` |
|
|
810
810
|
|
|
811
|
-
[:link: Source](https://github.com/dfinity/
|
|
811
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L308)
|
|
812
812
|
|
|
813
813
|
##### :gear: getNeuronBalance
|
|
814
814
|
|
|
@@ -816,7 +816,7 @@ This is a convenient method that transfers the stake to the neuron subaccount an
|
|
|
816
816
|
| ------------------ | ----------------------------------------- |
|
|
817
817
|
| `getNeuronBalance` | `(neuronId: NeuronId) => Promise<bigint>` |
|
|
818
818
|
|
|
819
|
-
[:link: Source](https://github.com/dfinity/
|
|
819
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L327)
|
|
820
820
|
|
|
821
821
|
##### :gear: addNeuronPermissions
|
|
822
822
|
|
|
@@ -824,7 +824,7 @@ This is a convenient method that transfers the stake to the neuron subaccount an
|
|
|
824
824
|
| ---------------------- | ------------------------------------------------------- |
|
|
825
825
|
| `addNeuronPermissions` | `(params: SnsNeuronPermissionsParams) => Promise<void>` |
|
|
826
826
|
|
|
827
|
-
[:link: Source](https://github.com/dfinity/
|
|
827
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L336)
|
|
828
828
|
|
|
829
829
|
##### :gear: refreshNeuron
|
|
830
830
|
|
|
@@ -832,7 +832,7 @@ This is a convenient method that transfers the stake to the neuron subaccount an
|
|
|
832
832
|
| --------------- | --------------------------------------- |
|
|
833
833
|
| `refreshNeuron` | `(neuronId: NeuronId) => Promise<void>` |
|
|
834
834
|
|
|
835
|
-
[:link: Source](https://github.com/dfinity/
|
|
835
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L340)
|
|
836
836
|
|
|
837
837
|
##### :gear: claimNeuron
|
|
838
838
|
|
|
@@ -840,7 +840,7 @@ This is a convenient method that transfers the stake to the neuron subaccount an
|
|
|
840
840
|
| ------------- | ----------------------------------------------------- |
|
|
841
841
|
| `claimNeuron` | `(params: SnsClaimNeuronParams) => Promise<NeuronId>` |
|
|
842
842
|
|
|
843
|
-
[:link: Source](https://github.com/dfinity/
|
|
843
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L344)
|
|
844
844
|
|
|
845
845
|
##### :gear: removeNeuronPermissions
|
|
846
846
|
|
|
@@ -848,7 +848,7 @@ This is a convenient method that transfers the stake to the neuron subaccount an
|
|
|
848
848
|
| ------------------------- | ------------------------------------------------------- |
|
|
849
849
|
| `removeNeuronPermissions` | `(params: SnsNeuronPermissionsParams) => Promise<void>` |
|
|
850
850
|
|
|
851
|
-
[:link: Source](https://github.com/dfinity/
|
|
851
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L348)
|
|
852
852
|
|
|
853
853
|
##### :gear: splitNeuron
|
|
854
854
|
|
|
@@ -856,7 +856,7 @@ This is a convenient method that transfers the stake to the neuron subaccount an
|
|
|
856
856
|
| ------------- | ------------------------------------------------------------------ |
|
|
857
857
|
| `splitNeuron` | `(params: SnsSplitNeuronParams) => Promise<NeuronId or undefined>` |
|
|
858
858
|
|
|
859
|
-
[:link: Source](https://github.com/dfinity/
|
|
859
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L353)
|
|
860
860
|
|
|
861
861
|
##### :gear: disburse
|
|
862
862
|
|
|
@@ -864,7 +864,7 @@ This is a convenient method that transfers the stake to the neuron subaccount an
|
|
|
864
864
|
| ---------- | ---------------------------------------------------- |
|
|
865
865
|
| `disburse` | `(params: SnsDisburseNeuronParams) => Promise<void>` |
|
|
866
866
|
|
|
867
|
-
[:link: Source](https://github.com/dfinity/
|
|
867
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L357)
|
|
868
868
|
|
|
869
869
|
##### :gear: startDissolving
|
|
870
870
|
|
|
@@ -872,7 +872,7 @@ This is a convenient method that transfers the stake to the neuron subaccount an
|
|
|
872
872
|
| ----------------- | --------------------------------------- |
|
|
873
873
|
| `startDissolving` | `(neuronId: NeuronId) => Promise<void>` |
|
|
874
874
|
|
|
875
|
-
[:link: Source](https://github.com/dfinity/
|
|
875
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L361)
|
|
876
876
|
|
|
877
877
|
##### :gear: stopDissolving
|
|
878
878
|
|
|
@@ -880,7 +880,7 @@ This is a convenient method that transfers the stake to the neuron subaccount an
|
|
|
880
880
|
| ---------------- | --------------------------------------- |
|
|
881
881
|
| `stopDissolving` | `(neuronId: NeuronId) => Promise<void>` |
|
|
882
882
|
|
|
883
|
-
[:link: Source](https://github.com/dfinity/
|
|
883
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L365)
|
|
884
884
|
|
|
885
885
|
##### :gear: setDissolveTimestamp
|
|
886
886
|
|
|
@@ -888,7 +888,7 @@ This is a convenient method that transfers the stake to the neuron subaccount an
|
|
|
888
888
|
| ---------------------- | ---------------------------------------------------------- |
|
|
889
889
|
| `setDissolveTimestamp` | `(params: SnsSetDissolveTimestampParams) => Promise<void>` |
|
|
890
890
|
|
|
891
|
-
[:link: Source](https://github.com/dfinity/
|
|
891
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L369)
|
|
892
892
|
|
|
893
893
|
##### :gear: increaseDissolveDelay
|
|
894
894
|
|
|
@@ -896,7 +896,7 @@ This is a convenient method that transfers the stake to the neuron subaccount an
|
|
|
896
896
|
| ----------------------- | ----------------------------------------------------------- |
|
|
897
897
|
| `increaseDissolveDelay` | `(params: SnsIncreaseDissolveDelayParams) => Promise<void>` |
|
|
898
898
|
|
|
899
|
-
[:link: Source](https://github.com/dfinity/
|
|
899
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L374)
|
|
900
900
|
|
|
901
901
|
##### :gear: setTopicFollowees
|
|
902
902
|
|
|
@@ -904,7 +904,7 @@ This is a convenient method that transfers the stake to the neuron subaccount an
|
|
|
904
904
|
| ------------------- | ------------------------------------------------- |
|
|
905
905
|
| `setTopicFollowees` | `(params: SnsSetTopicFollowees) => Promise<void>` |
|
|
906
906
|
|
|
907
|
-
[:link: Source](https://github.com/dfinity/
|
|
907
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L379)
|
|
908
908
|
|
|
909
909
|
##### :gear: setFollowing
|
|
910
910
|
|
|
@@ -912,7 +912,7 @@ This is a convenient method that transfers the stake to the neuron subaccount an
|
|
|
912
912
|
| -------------- | -------------------------------------------------- |
|
|
913
913
|
| `setFollowing` | `(params: SnsSetFollowingParams) => Promise<void>` |
|
|
914
914
|
|
|
915
|
-
[:link: Source](https://github.com/dfinity/
|
|
915
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L383)
|
|
916
916
|
|
|
917
917
|
##### :gear: registerVote
|
|
918
918
|
|
|
@@ -920,7 +920,7 @@ This is a convenient method that transfers the stake to the neuron subaccount an
|
|
|
920
920
|
| -------------- | -------------------------------------------------- |
|
|
921
921
|
| `registerVote` | `(params: SnsRegisterVoteParams) => Promise<void>` |
|
|
922
922
|
|
|
923
|
-
[:link: Source](https://github.com/dfinity/
|
|
923
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L387)
|
|
924
924
|
|
|
925
925
|
##### :gear: swapState
|
|
926
926
|
|
|
@@ -928,7 +928,7 @@ This is a convenient method that transfers the stake to the neuron subaccount an
|
|
|
928
928
|
| ----------- | ----------------------------------------------------------------------- |
|
|
929
929
|
| `swapState` | `(params: Omit<QueryParams, "certified">) => Promise<GetStateResponse>` |
|
|
930
930
|
|
|
931
|
-
[:link: Source](https://github.com/dfinity/
|
|
931
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L390)
|
|
932
932
|
|
|
933
933
|
##### :gear: notifyPaymentFailure
|
|
934
934
|
|
|
@@ -942,7 +942,7 @@ Always certified
|
|
|
942
942
|
| ---------------------- | ------------------------------------ |
|
|
943
943
|
| `notifyPaymentFailure` | `() => Promise<Ticket or undefined>` |
|
|
944
944
|
|
|
945
|
-
[:link: Source](https://github.com/dfinity/
|
|
945
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L403)
|
|
946
946
|
|
|
947
947
|
##### :gear: notifyParticipation
|
|
948
948
|
|
|
@@ -950,7 +950,7 @@ Always certified
|
|
|
950
950
|
| --------------------- | ---------------------------------------------------------------------------- |
|
|
951
951
|
| `notifyParticipation` | `(params: RefreshBuyerTokensRequest) => Promise<RefreshBuyerTokensResponse>` |
|
|
952
952
|
|
|
953
|
-
[:link: Source](https://github.com/dfinity/
|
|
953
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L407)
|
|
954
954
|
|
|
955
955
|
##### :gear: getUserCommitment
|
|
956
956
|
|
|
@@ -958,7 +958,7 @@ Always certified
|
|
|
958
958
|
| ------------------- | -------------------------------------------------------------------- |
|
|
959
959
|
| `getUserCommitment` | `(params: GetBuyerStateRequest) => Promise<BuyerState or undefined>` |
|
|
960
960
|
|
|
961
|
-
[:link: Source](https://github.com/dfinity/
|
|
961
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L412)
|
|
962
962
|
|
|
963
963
|
##### :gear: getOpenTicket
|
|
964
964
|
|
|
@@ -966,7 +966,7 @@ Always certified
|
|
|
966
966
|
| --------------- | -------------------------------------------------------------------------- |
|
|
967
967
|
| `getOpenTicket` | `(params: Omit<QueryParams, "certified">) => Promise<Ticket or undefined>` |
|
|
968
968
|
|
|
969
|
-
[:link: Source](https://github.com/dfinity/
|
|
969
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L417)
|
|
970
970
|
|
|
971
971
|
##### :gear: newSaleTicket
|
|
972
972
|
|
|
@@ -974,7 +974,7 @@ Always certified
|
|
|
974
974
|
| --------------- | -------------------------------------------------- |
|
|
975
975
|
| `newSaleTicket` | `(params: NewSaleTicketParams) => Promise<Ticket>` |
|
|
976
976
|
|
|
977
|
-
[:link: Source](https://github.com/dfinity/
|
|
977
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L423)
|
|
978
978
|
|
|
979
979
|
##### :gear: getLifecycle
|
|
980
980
|
|
|
@@ -982,7 +982,7 @@ Always certified
|
|
|
982
982
|
| -------------- | ---------------------------------------------------------------------------------------- |
|
|
983
983
|
| `getLifecycle` | `(params: Omit<QueryParams, "certified">) => Promise<GetLifecycleResponse or undefined>` |
|
|
984
984
|
|
|
985
|
-
[:link: Source](https://github.com/dfinity/
|
|
985
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L426)
|
|
986
986
|
|
|
987
987
|
##### :gear: getFinalizationStatus
|
|
988
988
|
|
|
@@ -990,7 +990,7 @@ Always certified
|
|
|
990
990
|
| ----------------------- | ----------------------------------------------------------------------------------------------------- |
|
|
991
991
|
| `getFinalizationStatus` | `(params: Omit<QueryParams, "certified">) => Promise<GetAutoFinalizationStatusResponse or undefined>` |
|
|
992
992
|
|
|
993
|
-
[:link: Source](https://github.com/dfinity/
|
|
993
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L431)
|
|
994
994
|
|
|
995
995
|
##### :gear: getSaleParameters
|
|
996
996
|
|
|
@@ -998,7 +998,7 @@ Always certified
|
|
|
998
998
|
| ------------------- | --------------------------------------------------------------------------------------------- |
|
|
999
999
|
| `getSaleParameters` | `(params: Omit<QueryParams, "certified">) => Promise<GetSaleParametersResponse or undefined>` |
|
|
1000
1000
|
|
|
1001
|
-
[:link: Source](https://github.com/dfinity/
|
|
1001
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L436)
|
|
1002
1002
|
|
|
1003
1003
|
##### :gear: getDerivedState
|
|
1004
1004
|
|
|
@@ -1006,7 +1006,7 @@ Always certified
|
|
|
1006
1006
|
| ----------------- | ------------------------------------------------------------------------------------------- |
|
|
1007
1007
|
| `getDerivedState` | `(params: Omit<QueryParams, "certified">) => Promise<GetDerivedStateResponse or undefined>` |
|
|
1008
1008
|
|
|
1009
|
-
[:link: Source](https://github.com/dfinity/
|
|
1009
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L441)
|
|
1010
1010
|
|
|
1011
1011
|
##### :gear: getTransactions
|
|
1012
1012
|
|
|
@@ -1014,7 +1014,7 @@ Always certified
|
|
|
1014
1014
|
| ----------------- | -------------------------------------------------------------------- |
|
|
1015
1015
|
| `getTransactions` | `(params: GetAccountTransactionsParams) => Promise<GetTransactions>` |
|
|
1016
1016
|
|
|
1017
|
-
[:link: Source](https://github.com/dfinity/
|
|
1017
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L447)
|
|
1018
1018
|
|
|
1019
1019
|
##### :gear: stakeMaturity
|
|
1020
1020
|
|
|
@@ -1022,7 +1022,7 @@ Always certified
|
|
|
1022
1022
|
| --------------- | --------------------------------------------------------- |
|
|
1023
1023
|
| `stakeMaturity` | `(params: SnsNeuronStakeMaturityParams) => Promise<void>` |
|
|
1024
1024
|
|
|
1025
|
-
[:link: Source](https://github.com/dfinity/
|
|
1025
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L452)
|
|
1026
1026
|
|
|
1027
1027
|
##### :gear: disburseMaturity
|
|
1028
1028
|
|
|
@@ -1030,7 +1030,7 @@ Always certified
|
|
|
1030
1030
|
| ------------------ | ------------------------------------------------------------ |
|
|
1031
1031
|
| `disburseMaturity` | `(params: SnsNeuronDisburseMaturityParams) => Promise<void>` |
|
|
1032
1032
|
|
|
1033
|
-
[:link: Source](https://github.com/dfinity/
|
|
1033
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L456)
|
|
1034
1034
|
|
|
1035
1035
|
##### :gear: autoStakeMaturity
|
|
1036
1036
|
|
|
@@ -1038,6 +1038,6 @@ Always certified
|
|
|
1038
1038
|
| ------------------- | ------------------------------------------------------------- |
|
|
1039
1039
|
| `autoStakeMaturity` | `(params: SnsNeuronAutoStakeMaturityParams) => Promise<void>` |
|
|
1040
1040
|
|
|
1041
|
-
[:link: Source](https://github.com/dfinity/
|
|
1041
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/sns/src/sns.wrapper.ts#L460)
|
|
1042
1042
|
|
|
1043
1043
|
<!-- TSDOC_END -->
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dfinity/sns",
|
|
3
|
-
"version": "5.0.0
|
|
3
|
+
"version": "5.0.0",
|
|
4
4
|
"description": "A library for interfacing with a Service Nervous System (SNS) project.",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"type": "module",
|
|
@@ -33,11 +33,11 @@
|
|
|
33
33
|
},
|
|
34
34
|
"repository": {
|
|
35
35
|
"type": "git",
|
|
36
|
-
"url": "git+https://github.com/dfinity/
|
|
36
|
+
"url": "git+https://github.com/dfinity/icp-js-canisters.git",
|
|
37
37
|
"directory": "packages/sns"
|
|
38
38
|
},
|
|
39
39
|
"bugs": {
|
|
40
|
-
"url": "https://github.com/dfinity/
|
|
40
|
+
"url": "https://github.com/dfinity/icp-js-canisters"
|
|
41
41
|
},
|
|
42
42
|
"keywords": [
|
|
43
43
|
"internet computer",
|
|
@@ -49,11 +49,11 @@
|
|
|
49
49
|
"sns"
|
|
50
50
|
],
|
|
51
51
|
"peerDependencies": {
|
|
52
|
-
"@dfinity/ledger-icrc": "
|
|
53
|
-
"@dfinity/utils": "
|
|
54
|
-
"@icp-sdk/core": "
|
|
52
|
+
"@dfinity/ledger-icrc": "^5",
|
|
53
|
+
"@dfinity/utils": "^4",
|
|
54
|
+
"@icp-sdk/core": "^4"
|
|
55
55
|
},
|
|
56
56
|
"dependencies": {
|
|
57
57
|
"@noble/hashes": "^1.8.0"
|
|
58
58
|
}
|
|
59
|
-
}
|
|
59
|
+
}
|