@near-kit-tool-box/fun 0.0.4 → 0.0.5

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.
@@ -1,5 +1,540 @@
1
1
  import { Near } from "near-kit";
2
+ import type { POOL_GET_ACCOUNTS_ACCOUNTS_TYPE } from "../../types/pool_types";
3
+ import type { AmountInput } from "@near-kit-tool-box/fun";
2
4
  export declare function pool_get_number_of_accounts_fun(near: Near, pool_contractId: string): Promise<number>;
5
+ export declare function pool_get_accounts_fun(near: Near, pool_contractId: string, from_index: number, limit: number): Promise<POOL_GET_ACCOUNTS_ACCOUNTS_TYPE>;
6
+ export declare function pool_deposit_and_stake_fun(near: Near, pool_contractId: string, attachedDeposit: AmountInput): Promise<{
7
+ final_execution_status: "NONE";
8
+ transaction?: {
9
+ hash: string;
10
+ signer_id: string;
11
+ receiver_id: string;
12
+ nonce: number;
13
+ } | undefined;
14
+ } | {
15
+ final_execution_status: "INCLUDED";
16
+ transaction?: {
17
+ hash: string;
18
+ signer_id: string;
19
+ receiver_id: string;
20
+ nonce: number;
21
+ } | undefined;
22
+ } | {
23
+ final_execution_status: "INCLUDED_FINAL";
24
+ transaction?: {
25
+ hash: string;
26
+ signer_id: string;
27
+ receiver_id: string;
28
+ nonce: number;
29
+ } | undefined;
30
+ } | {
31
+ final_execution_status: "EXECUTED_OPTIMISTIC";
32
+ status: "Unknown" | "Pending" | {
33
+ SuccessValue: string;
34
+ } | {
35
+ SuccessReceiptId: string;
36
+ } | {
37
+ Failure: {
38
+ [x: string]: any;
39
+ error_message?: string | undefined;
40
+ error_type?: string | undefined;
41
+ };
42
+ };
43
+ transaction: {
44
+ signer_id: string;
45
+ public_key: string;
46
+ nonce: number;
47
+ receiver_id: string;
48
+ actions: ("CreateAccount" | {
49
+ CreateAccount: Record<string, never>;
50
+ } | {
51
+ Transfer: {
52
+ deposit: string;
53
+ };
54
+ } | {
55
+ FunctionCall: {
56
+ method_name: string;
57
+ args: string;
58
+ gas: number;
59
+ deposit: string;
60
+ };
61
+ } | {
62
+ DeployContract: {
63
+ code: string;
64
+ };
65
+ } | {
66
+ DeployGlobalContract: {
67
+ code: string;
68
+ };
69
+ } | {
70
+ DeployGlobalContractByAccountId: {
71
+ code: string;
72
+ };
73
+ } | {
74
+ Stake: {
75
+ stake: string;
76
+ public_key: string;
77
+ };
78
+ } | {
79
+ AddKey: {
80
+ public_key: string;
81
+ access_key: {
82
+ nonce: number;
83
+ permission: "FullAccess" | {
84
+ FunctionCall: {
85
+ receiver_id: string;
86
+ method_names: string[];
87
+ allowance?: string | null | undefined;
88
+ };
89
+ };
90
+ };
91
+ };
92
+ } | {
93
+ DeleteKey: {
94
+ public_key: string;
95
+ };
96
+ } | {
97
+ DeleteAccount: {
98
+ beneficiary_id: string;
99
+ };
100
+ } | {
101
+ UseGlobalContract: {
102
+ code_hash: string;
103
+ };
104
+ } | {
105
+ UseGlobalContractByAccountId: {
106
+ account_id: string;
107
+ };
108
+ } | {
109
+ Delegate: {
110
+ delegate_action: {
111
+ sender_id: string;
112
+ receiver_id: string;
113
+ actions: any[];
114
+ nonce: number;
115
+ max_block_height: number;
116
+ public_key: string;
117
+ };
118
+ signature: string;
119
+ };
120
+ } | {
121
+ DeterministicStateInit: {
122
+ deposit: string;
123
+ };
124
+ })[];
125
+ signature: string;
126
+ hash: string;
127
+ priority_fee?: number | undefined;
128
+ };
129
+ transaction_outcome: {
130
+ id: string;
131
+ outcome: {
132
+ logs: string[];
133
+ receipt_ids: string[];
134
+ gas_burnt: number;
135
+ tokens_burnt: string;
136
+ executor_id: string;
137
+ status: "Unknown" | "Pending" | {
138
+ SuccessValue: string;
139
+ } | {
140
+ SuccessReceiptId: string;
141
+ } | {
142
+ Failure: {
143
+ [x: string]: any;
144
+ error_message?: string | undefined;
145
+ error_type?: string | undefined;
146
+ };
147
+ };
148
+ metadata?: {
149
+ version: number;
150
+ gas_profile?: {
151
+ [x: string]: any;
152
+ cost?: string | undefined;
153
+ cost_category?: string | undefined;
154
+ gas_used?: string | undefined;
155
+ }[] | null | undefined;
156
+ } | undefined;
157
+ };
158
+ block_hash: string;
159
+ proof: {
160
+ hash: string;
161
+ direction: "Left" | "Right";
162
+ }[];
163
+ };
164
+ receipts_outcome: {
165
+ id: string;
166
+ outcome: {
167
+ logs: string[];
168
+ receipt_ids: string[];
169
+ gas_burnt: number;
170
+ tokens_burnt: string;
171
+ executor_id: string;
172
+ status: "Unknown" | "Pending" | {
173
+ SuccessValue: string;
174
+ } | {
175
+ SuccessReceiptId: string;
176
+ } | {
177
+ Failure: {
178
+ [x: string]: any;
179
+ error_message?: string | undefined;
180
+ error_type?: string | undefined;
181
+ };
182
+ };
183
+ metadata?: {
184
+ version: number;
185
+ gas_profile?: {
186
+ [x: string]: any;
187
+ cost?: string | undefined;
188
+ cost_category?: string | undefined;
189
+ gas_used?: string | undefined;
190
+ }[] | null | undefined;
191
+ } | undefined;
192
+ };
193
+ block_hash: string;
194
+ proof: {
195
+ hash: string;
196
+ direction: "Left" | "Right";
197
+ }[];
198
+ }[];
199
+ } | {
200
+ final_execution_status: "EXECUTED";
201
+ status: "Unknown" | "Pending" | {
202
+ SuccessValue: string;
203
+ } | {
204
+ SuccessReceiptId: string;
205
+ } | {
206
+ Failure: {
207
+ [x: string]: any;
208
+ error_message?: string | undefined;
209
+ error_type?: string | undefined;
210
+ };
211
+ };
212
+ transaction: {
213
+ signer_id: string;
214
+ public_key: string;
215
+ nonce: number;
216
+ receiver_id: string;
217
+ actions: ("CreateAccount" | {
218
+ CreateAccount: Record<string, never>;
219
+ } | {
220
+ Transfer: {
221
+ deposit: string;
222
+ };
223
+ } | {
224
+ FunctionCall: {
225
+ method_name: string;
226
+ args: string;
227
+ gas: number;
228
+ deposit: string;
229
+ };
230
+ } | {
231
+ DeployContract: {
232
+ code: string;
233
+ };
234
+ } | {
235
+ DeployGlobalContract: {
236
+ code: string;
237
+ };
238
+ } | {
239
+ DeployGlobalContractByAccountId: {
240
+ code: string;
241
+ };
242
+ } | {
243
+ Stake: {
244
+ stake: string;
245
+ public_key: string;
246
+ };
247
+ } | {
248
+ AddKey: {
249
+ public_key: string;
250
+ access_key: {
251
+ nonce: number;
252
+ permission: "FullAccess" | {
253
+ FunctionCall: {
254
+ receiver_id: string;
255
+ method_names: string[];
256
+ allowance?: string | null | undefined;
257
+ };
258
+ };
259
+ };
260
+ };
261
+ } | {
262
+ DeleteKey: {
263
+ public_key: string;
264
+ };
265
+ } | {
266
+ DeleteAccount: {
267
+ beneficiary_id: string;
268
+ };
269
+ } | {
270
+ UseGlobalContract: {
271
+ code_hash: string;
272
+ };
273
+ } | {
274
+ UseGlobalContractByAccountId: {
275
+ account_id: string;
276
+ };
277
+ } | {
278
+ Delegate: {
279
+ delegate_action: {
280
+ sender_id: string;
281
+ receiver_id: string;
282
+ actions: any[];
283
+ nonce: number;
284
+ max_block_height: number;
285
+ public_key: string;
286
+ };
287
+ signature: string;
288
+ };
289
+ } | {
290
+ DeterministicStateInit: {
291
+ deposit: string;
292
+ };
293
+ })[];
294
+ signature: string;
295
+ hash: string;
296
+ priority_fee?: number | undefined;
297
+ };
298
+ transaction_outcome: {
299
+ id: string;
300
+ outcome: {
301
+ logs: string[];
302
+ receipt_ids: string[];
303
+ gas_burnt: number;
304
+ tokens_burnt: string;
305
+ executor_id: string;
306
+ status: "Unknown" | "Pending" | {
307
+ SuccessValue: string;
308
+ } | {
309
+ SuccessReceiptId: string;
310
+ } | {
311
+ Failure: {
312
+ [x: string]: any;
313
+ error_message?: string | undefined;
314
+ error_type?: string | undefined;
315
+ };
316
+ };
317
+ metadata?: {
318
+ version: number;
319
+ gas_profile?: {
320
+ [x: string]: any;
321
+ cost?: string | undefined;
322
+ cost_category?: string | undefined;
323
+ gas_used?: string | undefined;
324
+ }[] | null | undefined;
325
+ } | undefined;
326
+ };
327
+ block_hash: string;
328
+ proof: {
329
+ hash: string;
330
+ direction: "Left" | "Right";
331
+ }[];
332
+ };
333
+ receipts_outcome: {
334
+ id: string;
335
+ outcome: {
336
+ logs: string[];
337
+ receipt_ids: string[];
338
+ gas_burnt: number;
339
+ tokens_burnt: string;
340
+ executor_id: string;
341
+ status: "Unknown" | "Pending" | {
342
+ SuccessValue: string;
343
+ } | {
344
+ SuccessReceiptId: string;
345
+ } | {
346
+ Failure: {
347
+ [x: string]: any;
348
+ error_message?: string | undefined;
349
+ error_type?: string | undefined;
350
+ };
351
+ };
352
+ metadata?: {
353
+ version: number;
354
+ gas_profile?: {
355
+ [x: string]: any;
356
+ cost?: string | undefined;
357
+ cost_category?: string | undefined;
358
+ gas_used?: string | undefined;
359
+ }[] | null | undefined;
360
+ } | undefined;
361
+ };
362
+ block_hash: string;
363
+ proof: {
364
+ hash: string;
365
+ direction: "Left" | "Right";
366
+ }[];
367
+ }[];
368
+ } | {
369
+ final_execution_status: "FINAL";
370
+ status: "Unknown" | "Pending" | {
371
+ SuccessValue: string;
372
+ } | {
373
+ SuccessReceiptId: string;
374
+ } | {
375
+ Failure: {
376
+ [x: string]: any;
377
+ error_message?: string | undefined;
378
+ error_type?: string | undefined;
379
+ };
380
+ };
381
+ transaction: {
382
+ signer_id: string;
383
+ public_key: string;
384
+ nonce: number;
385
+ receiver_id: string;
386
+ actions: ("CreateAccount" | {
387
+ CreateAccount: Record<string, never>;
388
+ } | {
389
+ Transfer: {
390
+ deposit: string;
391
+ };
392
+ } | {
393
+ FunctionCall: {
394
+ method_name: string;
395
+ args: string;
396
+ gas: number;
397
+ deposit: string;
398
+ };
399
+ } | {
400
+ DeployContract: {
401
+ code: string;
402
+ };
403
+ } | {
404
+ DeployGlobalContract: {
405
+ code: string;
406
+ };
407
+ } | {
408
+ DeployGlobalContractByAccountId: {
409
+ code: string;
410
+ };
411
+ } | {
412
+ Stake: {
413
+ stake: string;
414
+ public_key: string;
415
+ };
416
+ } | {
417
+ AddKey: {
418
+ public_key: string;
419
+ access_key: {
420
+ nonce: number;
421
+ permission: "FullAccess" | {
422
+ FunctionCall: {
423
+ receiver_id: string;
424
+ method_names: string[];
425
+ allowance?: string | null | undefined;
426
+ };
427
+ };
428
+ };
429
+ };
430
+ } | {
431
+ DeleteKey: {
432
+ public_key: string;
433
+ };
434
+ } | {
435
+ DeleteAccount: {
436
+ beneficiary_id: string;
437
+ };
438
+ } | {
439
+ UseGlobalContract: {
440
+ code_hash: string;
441
+ };
442
+ } | {
443
+ UseGlobalContractByAccountId: {
444
+ account_id: string;
445
+ };
446
+ } | {
447
+ Delegate: {
448
+ delegate_action: {
449
+ sender_id: string;
450
+ receiver_id: string;
451
+ actions: any[];
452
+ nonce: number;
453
+ max_block_height: number;
454
+ public_key: string;
455
+ };
456
+ signature: string;
457
+ };
458
+ } | {
459
+ DeterministicStateInit: {
460
+ deposit: string;
461
+ };
462
+ })[];
463
+ signature: string;
464
+ hash: string;
465
+ priority_fee?: number | undefined;
466
+ };
467
+ transaction_outcome: {
468
+ id: string;
469
+ outcome: {
470
+ logs: string[];
471
+ receipt_ids: string[];
472
+ gas_burnt: number;
473
+ tokens_burnt: string;
474
+ executor_id: string;
475
+ status: "Unknown" | "Pending" | {
476
+ SuccessValue: string;
477
+ } | {
478
+ SuccessReceiptId: string;
479
+ } | {
480
+ Failure: {
481
+ [x: string]: any;
482
+ error_message?: string | undefined;
483
+ error_type?: string | undefined;
484
+ };
485
+ };
486
+ metadata?: {
487
+ version: number;
488
+ gas_profile?: {
489
+ [x: string]: any;
490
+ cost?: string | undefined;
491
+ cost_category?: string | undefined;
492
+ gas_used?: string | undefined;
493
+ }[] | null | undefined;
494
+ } | undefined;
495
+ };
496
+ block_hash: string;
497
+ proof: {
498
+ hash: string;
499
+ direction: "Left" | "Right";
500
+ }[];
501
+ };
502
+ receipts_outcome: {
503
+ id: string;
504
+ outcome: {
505
+ logs: string[];
506
+ receipt_ids: string[];
507
+ gas_burnt: number;
508
+ tokens_burnt: string;
509
+ executor_id: string;
510
+ status: "Unknown" | "Pending" | {
511
+ SuccessValue: string;
512
+ } | {
513
+ SuccessReceiptId: string;
514
+ } | {
515
+ Failure: {
516
+ [x: string]: any;
517
+ error_message?: string | undefined;
518
+ error_type?: string | undefined;
519
+ };
520
+ };
521
+ metadata?: {
522
+ version: number;
523
+ gas_profile?: {
524
+ [x: string]: any;
525
+ cost?: string | undefined;
526
+ cost_category?: string | undefined;
527
+ gas_used?: string | undefined;
528
+ }[] | null | undefined;
529
+ } | undefined;
530
+ };
531
+ block_hash: string;
532
+ proof: {
533
+ hash: string;
534
+ direction: "Left" | "Right";
535
+ }[];
536
+ }[];
537
+ }>;
3
538
  export declare function pool_ping_fun(near: Near, pool_contractId: string): Promise<{
4
539
  final_execution_status: "NONE";
5
540
  transaction?: {
@@ -1 +1 @@
1
- {"version":3,"file":"pool_fun.d.ts","sourceRoot":"","sources":["../../../src/fun/pool/pool_fun.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,UAAU,CAAC;AAShC,wBAAsB,+BAA+B,CACnD,IAAI,EAAE,IAAI,EACV,eAAe,EAAE,MAAM,mBAOxB;AAED,wBAAsB,aAAa,CAAC,IAAI,EAAE,IAAI,EAAE,eAAe,EAAE,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAS7B;AAGD,wBAAsB,aAAa,CAAC,IAAI,EAAE,IAAI,EAAE,eAAe,EAAE,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAKtE"}
@@ -3,14 +3,30 @@ import { pool_methods_const } from "@sleet-js/staking-pool-contract-methods-cons
3
3
  // ===========================================
4
4
  // view
5
5
  // get_number_of_accounts
6
+ // get_accounts
6
7
  // call
7
8
  // ping
9
+ // deposit_and_stake
8
10
  // ===========================================
11
+ // get_number_of_accounts
9
12
  export async function pool_get_number_of_accounts_fun(near, pool_contractId) {
10
13
  const result = await near.view(pool_contractId, pool_methods_const.get_number_of_accounts);
11
14
  return result;
12
15
  }
13
16
  // ===========================================
17
+ // get_accounts
18
+ export async function pool_get_accounts_fun(near, pool_contractId, from_index, limit) {
19
+ const result = await near.view(pool_contractId, pool_methods_const.get_accounts, { from_index: from_index, limit: limit });
20
+ return result;
21
+ }
22
+ // ===========================================
23
+ // deposit_and_stake
24
+ export async function pool_deposit_and_stake_fun(near, pool_contractId, attachedDeposit) {
25
+ const result = await near.call(pool_contractId, pool_methods_const.deposit_and_stake, {}, { attachedDeposit: attachedDeposit });
26
+ return result;
27
+ }
28
+ // ===========================================
29
+ // pool_ping_fun
14
30
  export async function pool_ping_fun(near, pool_contractId) {
15
31
  const result = await near.call(pool_contractId, pool_methods_const.ping, {
16
32
  gas: "30 Tgas",
@@ -1 +1 @@
1
- {"version":3,"file":"pool_fun.js","sourceRoot":"","sources":["../../../src/fun/pool/pool_fun.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,UAAU,CAAC;AAChC,OAAO,EAAE,kBAAkB,EAAE,MAAM,+CAA+C,CAAC;AAEnF,8CAA8C;AAC9C,OAAO;AACP,yBAAyB;AACzB,OAAO;AACP,OAAO;AACP,8CAA8C;AAC9C,MAAM,CAAC,KAAK,UAAU,+BAA+B,CACnD,IAAU,EACV,eAAuB;IAEvB,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,IAAI,CAC5B,eAAe,EACf,kBAAkB,CAAC,sBAAsB,CAC1C,CAAC;IACF,OAAO,MAAgB,CAAC;AAC1B,CAAC;AACD,8CAA8C;AAC9C,MAAM,CAAC,KAAK,UAAU,aAAa,CAAC,IAAU,EAAE,eAAuB;IACrE,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,IAAI,CAAC,eAAe,EAAE,kBAAkB,CAAC,IAAI,EAAE;QACvE,GAAG,EAAE,SAAS;KACf,CAAC,CAAC;IACH,OAAO,MAA+B,CAAC;AACzC,CAAC;AACD,8CAA8C"}
1
+ {"version":3,"file":"pool_fun.js","sourceRoot":"","sources":["../../../src/fun/pool/pool_fun.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,UAAU,CAAC;AAChC,OAAO,EAAE,kBAAkB,EAAE,MAAM,+CAA+C,CAAC;AAInF,8CAA8C;AA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NT_INTERFACE {
2
+ account_id: string;
3
+ unstaked_balance: string;
4
+ staked_balance: string;
5
+ can_withdraw: boolean;
6
+ }
7
+ export type POOL_GET_ACCOUNTS_ACCOUNTS_TYPE = POOL_GET_ACCOUNTS_ACCOUNT_INTERFACE[];
8
+ export {};
9
+ //# sourceMappingURL=pool_types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"pool_types.d.ts","sourceRoot":"","sources":["../../src/types/pool_types.ts"],"names":[],"mappings":"AACA,UAAU,mCAAmC;IAC3C,UAAU,EAAE,MAAM,CAAC;IACnB,gBAAgB,EAAE,MAAM,CAAC;IACzB,cAAc,EAAE,MAAM,CAAC;IACvB,YAAY,EAAE,OAAO,CAAC;CACvB;AAED,MAAM,MAAM,+BAA+B,GACzC,mCAAmC,EAAE,CAAC"}
@@ -0,0 +1,3 @@
1
+ export {};
2
+ // ===========================================
3
+ //# sourceMappingURL=pool_types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"pool_types.js","sourceRoot":"","sources":["../../src/types/pool_types.ts"],"names":[],"mappings":";AAUA,8CAA8C"}
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@near-kit-tool-box/fun",
3
3
  "description": "Reusable contract functions for common NEAR contracts",
4
- "version": "0.0.4",
4
+ "version": "0.0.5",
5
5
  "homepage": "https://sleet-js.near.page",
6
6
  "main": "dist/index.js",
7
7
  "module": "dist/index.js",
@@ -31,19 +31,19 @@
31
31
  "access": "public"
32
32
  },
33
33
  "peerDependencies": {
34
- "typescript": "^6.0.2"
34
+ "typescript": "^6.0.3"
35
35
  },
36
36
  "dependencies": {
37
- "@hot-labs/near-connect": "0.11.1",
37
+ "@hot-labs/near-connect": "0.11.2",
38
38
  "@sleet-js/ft-methods-const": "^0.0.7",
39
39
  "@sleet-js/ref-exchange-methods-const": "^0.0.7",
40
40
  "@sleet-js/staking-pool-contract-methods-const": "^0.0.7",
41
41
  "@sleet-js/wrap-near-contract-methods-const": "^0.0.7",
42
- "near-kit": "^0.12.0",
43
- "prettier": "^3.8.1",
44
- "zod": "^4.3.6"
42
+ "near-kit": "^0.13.1",
43
+ "prettier": "^3.8.3",
44
+ "zod": "^4.4.1"
45
45
  },
46
46
  "devDependencies": {
47
- "@types/bun": "^1.3.11"
47
+ "@types/bun": "^1.3.13"
48
48
  }
49
49
  }