@dfinity/sns 3.1.0 → 3.2.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/sns_governance.certified.idl.js +23 -0
- package/dist/candid/sns_governance.d.ts +24 -0
- package/dist/candid/sns_governance.did +19 -1
- package/dist/candid/sns_governance.idl.js +23 -0
- package/dist/candid/sns_governance_test.certified.idl.js +23 -0
- package/dist/candid/sns_governance_test.d.ts +24 -0
- package/dist/candid/sns_governance_test.did +19 -1
- package/dist/candid/sns_governance_test.idl.js +23 -0
- package/dist/candid/sns_root.certified.idl.js +6 -0
- package/dist/candid/sns_root.d.ts +3 -0
- package/dist/candid/sns_root.did +4 -1
- package/dist/candid/sns_root.idl.js +6 -0
- package/dist/candid/sns_swap.certified.idl.js +18 -33
- package/dist/candid/sns_swap.d.ts +11 -11
- package/dist/candid/sns_swap.did +14 -11
- package/dist/candid/sns_swap.idl.js +18 -33
- package/dist/cjs/index.cjs.js +1 -1
- package/dist/cjs/index.cjs.js.map +3 -3
- package/dist/esm/chunk-7CU6QPD4.js +2 -0
- package/dist/esm/chunk-7CU6QPD4.js.map +7 -0
- package/dist/esm/chunk-C7HBQQIL.js +2 -0
- package/dist/esm/chunk-C7HBQQIL.js.map +7 -0
- package/dist/esm/chunk-K2WYATWO.js +2 -0
- package/dist/esm/chunk-K2WYATWO.js.map +7 -0
- package/dist/esm/{chunk-R7I3KJ5Z.js → chunk-TVXJJLBF.js} +2 -2
- package/dist/esm/governance.canister.js +1 -1
- package/dist/esm/index.js +1 -1
- package/dist/esm/index.js.map +3 -3
- package/dist/esm/root.canister.js +1 -1
- package/dist/esm/sns.js +1 -1
- package/dist/esm/swap.canister.js +1 -1
- package/package.json +6 -6
- package/dist/esm/chunk-34CD4QJG.js +0 -2
- package/dist/esm/chunk-34CD4QJG.js.map +0 -7
- package/dist/esm/chunk-4GE7OJRF.js +0 -2
- package/dist/esm/chunk-4GE7OJRF.js.map +0 -7
- package/dist/esm/chunk-VUTJEPVF.js +0 -2
- package/dist/esm/chunk-VUTJEPVF.js.map +0 -7
- /package/dist/esm/{chunk-R7I3KJ5Z.js.map → chunk-TVXJJLBF.js.map} +0 -0
package/dist/candid/sns_swap.did
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
// Generated from IC repo commit
|
|
1
|
+
// Generated from IC repo commit 3d6a76e (2024-08-14 tags: release-2024-08-21_15-36-canister-snapshots) 'rs/sns/swap/canister/swap.did' by import-candid
|
|
2
2
|
type BuyerState = record {
|
|
3
3
|
icp : opt TransferableAmount;
|
|
4
4
|
has_created_neuron_recipes : opt bool;
|
|
@@ -13,13 +13,20 @@ type CanisterStatusResultV2 = record {
|
|
|
13
13
|
module_hash : opt blob;
|
|
14
14
|
};
|
|
15
15
|
type CanisterStatusType = variant { stopped; stopping; running };
|
|
16
|
-
type CfInvestment = record {
|
|
16
|
+
type CfInvestment = record {
|
|
17
|
+
controller : opt principal;
|
|
18
|
+
hotkey_principal : text;
|
|
19
|
+
hotkeys : opt Principals;
|
|
20
|
+
nns_neuron_id : nat64;
|
|
21
|
+
};
|
|
17
22
|
type CfNeuron = record {
|
|
18
23
|
has_created_neuron_recipes : opt bool;
|
|
24
|
+
hotkeys : opt Principals;
|
|
19
25
|
nns_neuron_id : nat64;
|
|
20
26
|
amount_icp_e8s : nat64;
|
|
21
27
|
};
|
|
22
28
|
type CfParticipant = record {
|
|
29
|
+
controller : opt principal;
|
|
23
30
|
hotkey_principal : text;
|
|
24
31
|
cf_neurons : vec CfNeuron;
|
|
25
32
|
};
|
|
@@ -115,7 +122,6 @@ type Init = record {
|
|
|
115
122
|
icp_ledger_canister_id : text;
|
|
116
123
|
sns_ledger_canister_id : text;
|
|
117
124
|
neurons_fund_participation_constraints : opt NeuronsFundParticipationConstraints;
|
|
118
|
-
neurons_fund_participants : opt NeuronsFundParticipants;
|
|
119
125
|
should_auto_finalize : opt bool;
|
|
120
126
|
max_participant_icp_e8s : opt nat64;
|
|
121
127
|
sns_governance_canister_id : text;
|
|
@@ -143,6 +149,9 @@ type ListCommunityFundParticipantsRequest = record {
|
|
|
143
149
|
offset : opt nat64;
|
|
144
150
|
limit : opt nat32;
|
|
145
151
|
};
|
|
152
|
+
type ListCommunityFundParticipantsResponse = record {
|
|
153
|
+
cf_participants : vec CfParticipant;
|
|
154
|
+
};
|
|
146
155
|
type ListDirectParticipantsRequest = record {
|
|
147
156
|
offset : opt nat32;
|
|
148
157
|
limit : opt nat32;
|
|
@@ -165,7 +174,6 @@ type NeuronBasketConstructionParameters = record {
|
|
|
165
174
|
count : nat64;
|
|
166
175
|
};
|
|
167
176
|
type NeuronId = record { id : blob };
|
|
168
|
-
type NeuronsFundParticipants = record { cf_participants : vec CfParticipant };
|
|
169
177
|
type NeuronsFundParticipationConstraints = record {
|
|
170
178
|
coefficient_intervals : vec LinearScalingCoefficient;
|
|
171
179
|
max_neurons_fund_participation_icp_e8s : opt nat64;
|
|
@@ -183,11 +191,6 @@ type Ok_1 = record {
|
|
|
183
191
|
neurons_fund_neurons_count : opt nat64;
|
|
184
192
|
};
|
|
185
193
|
type Ok_2 = record { ticket : opt Ticket };
|
|
186
|
-
type OpenRequest = record {
|
|
187
|
-
cf_participants : vec CfParticipant;
|
|
188
|
-
params : opt Params;
|
|
189
|
-
open_sns_token_swap_proposal_id : opt nat64;
|
|
190
|
-
};
|
|
191
194
|
type Params = record {
|
|
192
195
|
min_participant_icp_e8s : nat64;
|
|
193
196
|
neuron_basket_construction_parameters : opt NeuronBasketConstructionParameters;
|
|
@@ -212,6 +215,7 @@ type Possibility = variant {
|
|
|
212
215
|
type Possibility_1 = variant { Ok : Response; Err : CanisterCallError };
|
|
213
216
|
type Possibility_2 = variant { Ok : Ok_1; Err : Error };
|
|
214
217
|
type Possibility_3 = variant { Ok : record {}; Err : CanisterCallError };
|
|
218
|
+
type Principals = record { principals : vec principal };
|
|
215
219
|
type RefreshBuyerTokensRequest = record {
|
|
216
220
|
confirmation_text : opt text;
|
|
217
221
|
buyer : text;
|
|
@@ -294,7 +298,7 @@ service : (Init) -> {
|
|
|
294
298
|
get_sale_parameters : (record {}) -> (GetSaleParametersResponse) query;
|
|
295
299
|
get_state : (record {}) -> (GetStateResponse) query;
|
|
296
300
|
list_community_fund_participants : (ListCommunityFundParticipantsRequest) -> (
|
|
297
|
-
|
|
301
|
+
ListCommunityFundParticipantsResponse,
|
|
298
302
|
) query;
|
|
299
303
|
list_direct_participants : (ListDirectParticipantsRequest) -> (
|
|
300
304
|
ListDirectParticipantsResponse,
|
|
@@ -304,7 +308,6 @@ service : (Init) -> {
|
|
|
304
308
|
) query;
|
|
305
309
|
new_sale_ticket : (NewSaleTicketRequest) -> (NewSaleTicketResponse);
|
|
306
310
|
notify_payment_failure : (record {}) -> (Ok_2);
|
|
307
|
-
open : (OpenRequest) -> (record {});
|
|
308
311
|
refresh_buyer_tokens : (RefreshBuyerTokensRequest) -> (
|
|
309
312
|
RefreshBuyerTokensResponse,
|
|
310
313
|
);
|
|
@@ -22,18 +22,6 @@ export const idlFactory = ({ IDL }) => {
|
|
|
22
22
|
IdealMatchedParticipationFunction
|
|
23
23
|
),
|
|
24
24
|
});
|
|
25
|
-
const CfNeuron = IDL.Record({
|
|
26
|
-
'has_created_neuron_recipes' : IDL.Opt(IDL.Bool),
|
|
27
|
-
'nns_neuron_id' : IDL.Nat64,
|
|
28
|
-
'amount_icp_e8s' : IDL.Nat64,
|
|
29
|
-
});
|
|
30
|
-
const CfParticipant = IDL.Record({
|
|
31
|
-
'hotkey_principal' : IDL.Text,
|
|
32
|
-
'cf_neurons' : IDL.Vec(CfNeuron),
|
|
33
|
-
});
|
|
34
|
-
const NeuronsFundParticipants = IDL.Record({
|
|
35
|
-
'cf_participants' : IDL.Vec(CfParticipant),
|
|
36
|
-
});
|
|
37
25
|
const Countries = IDL.Record({ 'iso_codes' : IDL.Vec(IDL.Text) });
|
|
38
26
|
const Init = IDL.Record({
|
|
39
27
|
'nns_proposal_id' : IDL.Opt(IDL.Nat64),
|
|
@@ -58,7 +46,6 @@ export const idlFactory = ({ IDL }) => {
|
|
|
58
46
|
'neurons_fund_participation_constraints' : IDL.Opt(
|
|
59
47
|
NeuronsFundParticipationConstraints
|
|
60
48
|
),
|
|
61
|
-
'neurons_fund_participants' : IDL.Opt(NeuronsFundParticipants),
|
|
62
49
|
'should_auto_finalize' : IDL.Opt(IDL.Bool),
|
|
63
50
|
'max_participant_icp_e8s' : IDL.Opt(IDL.Nat64),
|
|
64
51
|
'sns_governance_canister_id' : IDL.Text,
|
|
@@ -240,8 +227,11 @@ export const idlFactory = ({ IDL }) => {
|
|
|
240
227
|
'memo' : IDL.Nat64,
|
|
241
228
|
'followees' : IDL.Vec(NeuronId),
|
|
242
229
|
});
|
|
230
|
+
const Principals = IDL.Record({ 'principals' : IDL.Vec(IDL.Principal) });
|
|
243
231
|
const CfInvestment = IDL.Record({
|
|
232
|
+
'controller' : IDL.Opt(IDL.Principal),
|
|
244
233
|
'hotkey_principal' : IDL.Text,
|
|
234
|
+
'hotkeys' : IDL.Opt(Principals),
|
|
245
235
|
'nns_neuron_id' : IDL.Nat64,
|
|
246
236
|
});
|
|
247
237
|
const DirectInvestment = IDL.Record({ 'buyer_principal' : IDL.Text });
|
|
@@ -255,6 +245,17 @@ export const idlFactory = ({ IDL }) => {
|
|
|
255
245
|
'neuron_attributes' : IDL.Opt(NeuronAttributes),
|
|
256
246
|
'investor' : IDL.Opt(Investor),
|
|
257
247
|
});
|
|
248
|
+
const CfNeuron = IDL.Record({
|
|
249
|
+
'has_created_neuron_recipes' : IDL.Opt(IDL.Bool),
|
|
250
|
+
'hotkeys' : IDL.Opt(Principals),
|
|
251
|
+
'nns_neuron_id' : IDL.Nat64,
|
|
252
|
+
'amount_icp_e8s' : IDL.Nat64,
|
|
253
|
+
});
|
|
254
|
+
const CfParticipant = IDL.Record({
|
|
255
|
+
'controller' : IDL.Opt(IDL.Principal),
|
|
256
|
+
'hotkey_principal' : IDL.Text,
|
|
257
|
+
'cf_neurons' : IDL.Vec(CfNeuron),
|
|
258
|
+
});
|
|
258
259
|
const Swap = IDL.Record({
|
|
259
260
|
'auto_finalize_swap_response' : IDL.Opt(FinalizeSwapResponse),
|
|
260
261
|
'neuron_recipes' : IDL.Vec(SnsNeuronRecipe),
|
|
@@ -293,6 +294,9 @@ export const idlFactory = ({ IDL }) => {
|
|
|
293
294
|
'offset' : IDL.Opt(IDL.Nat64),
|
|
294
295
|
'limit' : IDL.Opt(IDL.Nat32),
|
|
295
296
|
});
|
|
297
|
+
const ListCommunityFundParticipantsResponse = IDL.Record({
|
|
298
|
+
'cf_participants' : IDL.Vec(CfParticipant),
|
|
299
|
+
});
|
|
296
300
|
const ListDirectParticipantsRequest = IDL.Record({
|
|
297
301
|
'offset' : IDL.Opt(IDL.Nat32),
|
|
298
302
|
'limit' : IDL.Opt(IDL.Nat32),
|
|
@@ -326,11 +330,6 @@ export const idlFactory = ({ IDL }) => {
|
|
|
326
330
|
});
|
|
327
331
|
const Result_2 = IDL.Variant({ 'Ok' : Ok_2, 'Err' : Err_2 });
|
|
328
332
|
const NewSaleTicketResponse = IDL.Record({ 'result' : IDL.Opt(Result_2) });
|
|
329
|
-
const OpenRequest = IDL.Record({
|
|
330
|
-
'cf_participants' : IDL.Vec(CfParticipant),
|
|
331
|
-
'params' : IDL.Opt(Params),
|
|
332
|
-
'open_sns_token_swap_proposal_id' : IDL.Opt(IDL.Nat64),
|
|
333
|
-
});
|
|
334
333
|
const RefreshBuyerTokensRequest = IDL.Record({
|
|
335
334
|
'confirmation_text' : IDL.Opt(IDL.Text),
|
|
336
335
|
'buyer' : IDL.Text,
|
|
@@ -390,7 +389,7 @@ export const idlFactory = ({ IDL }) => {
|
|
|
390
389
|
'get_state' : IDL.Func([IDL.Record({})], [GetStateResponse], ['query']),
|
|
391
390
|
'list_community_fund_participants' : IDL.Func(
|
|
392
391
|
[ListCommunityFundParticipantsRequest],
|
|
393
|
-
[
|
|
392
|
+
[ListCommunityFundParticipantsResponse],
|
|
394
393
|
['query'],
|
|
395
394
|
),
|
|
396
395
|
'list_direct_participants' : IDL.Func(
|
|
@@ -409,7 +408,6 @@ export const idlFactory = ({ IDL }) => {
|
|
|
409
408
|
[],
|
|
410
409
|
),
|
|
411
410
|
'notify_payment_failure' : IDL.Func([IDL.Record({})], [Ok_2], []),
|
|
412
|
-
'open' : IDL.Func([OpenRequest], [IDL.Record({})], []),
|
|
413
411
|
'refresh_buyer_tokens' : IDL.Func(
|
|
414
412
|
[RefreshBuyerTokensRequest],
|
|
415
413
|
[RefreshBuyerTokensResponse],
|
|
@@ -440,18 +438,6 @@ export const init = ({ IDL }) => {
|
|
|
440
438
|
IdealMatchedParticipationFunction
|
|
441
439
|
),
|
|
442
440
|
});
|
|
443
|
-
const CfNeuron = IDL.Record({
|
|
444
|
-
'has_created_neuron_recipes' : IDL.Opt(IDL.Bool),
|
|
445
|
-
'nns_neuron_id' : IDL.Nat64,
|
|
446
|
-
'amount_icp_e8s' : IDL.Nat64,
|
|
447
|
-
});
|
|
448
|
-
const CfParticipant = IDL.Record({
|
|
449
|
-
'hotkey_principal' : IDL.Text,
|
|
450
|
-
'cf_neurons' : IDL.Vec(CfNeuron),
|
|
451
|
-
});
|
|
452
|
-
const NeuronsFundParticipants = IDL.Record({
|
|
453
|
-
'cf_participants' : IDL.Vec(CfParticipant),
|
|
454
|
-
});
|
|
455
441
|
const Countries = IDL.Record({ 'iso_codes' : IDL.Vec(IDL.Text) });
|
|
456
442
|
const Init = IDL.Record({
|
|
457
443
|
'nns_proposal_id' : IDL.Opt(IDL.Nat64),
|
|
@@ -476,7 +462,6 @@ export const init = ({ IDL }) => {
|
|
|
476
462
|
'neurons_fund_participation_constraints' : IDL.Opt(
|
|
477
463
|
NeuronsFundParticipationConstraints
|
|
478
464
|
),
|
|
479
|
-
'neurons_fund_participants' : IDL.Opt(NeuronsFundParticipants),
|
|
480
465
|
'should_auto_finalize' : IDL.Opt(IDL.Bool),
|
|
481
466
|
'max_participant_icp_e8s' : IDL.Opt(IDL.Nat64),
|
|
482
467
|
'sns_governance_canister_id' : IDL.Text,
|