@argonprotocol/mainchain 1.4.13 → 1.5.0-dev.d2f56d16
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/browser/index.d.ts +634 -347
- package/browser/index.js +3 -8
- package/browser/index.js.map +1 -1
- package/lib/index.cjs +3 -8
- package/lib/index.cjs.map +1 -1
- package/lib/index.d.cts +634 -347
- package/lib/index.d.ts +634 -347
- package/lib/index.js +3 -8
- package/lib/index.js.map +1 -1
- package/package.json +13 -10
- package/src/interfaces/augment-api-consts.ts +48 -13
- package/src/interfaces/augment-api-errors.ts +23 -11
- package/src/interfaces/augment-api-events.ts +54 -10
- package/src/interfaces/augment-api-query.ts +74 -24
- package/src/interfaces/augment-api-rpc.ts +22 -2
- package/src/interfaces/augment-api-tx.ts +58 -13
- package/src/interfaces/augment-types.ts +8 -1
- package/src/interfaces/lookup.ts +387 -271
- package/src/interfaces/registry.ts +22 -6
- package/src/interfaces/types-lookup.ts +413 -280
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@argonprotocol/mainchain",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.5.0-dev.d2f56d16",
|
|
4
4
|
"description": "A client for accessing the Argon mainchain apis.",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -21,6 +21,7 @@
|
|
|
21
21
|
"tsc": "yarn workspace @argonprotocol/ethereum-contracts build && yarn generate:contract-declarations && tsup && yarn validate:package",
|
|
22
22
|
"tsup": "yarn tsc",
|
|
23
23
|
"validate:package": "tsx src/scripts/validatePackage.ts",
|
|
24
|
+
"backfill:flexible-bond-metrics": "tsx src/scripts/backfillFlexibleBondMetrics.ts",
|
|
24
25
|
"watch": "yarn generate:contract-declarations && tsup --watch",
|
|
25
26
|
"typecheck": "tsc --noEmit -p tsconfig.test.json"
|
|
26
27
|
},
|
|
@@ -52,13 +53,13 @@
|
|
|
52
53
|
"dependencies": {
|
|
53
54
|
"@ethereumjs/block": "^10.1.1",
|
|
54
55
|
"@ethereumjs/mpt": "^10.1.1",
|
|
55
|
-
"@polkadot/api": "^
|
|
56
|
-
"@polkadot/api-base": "^
|
|
56
|
+
"@polkadot/api": "^17.0.1",
|
|
57
|
+
"@polkadot/api-base": "^17.0.1",
|
|
57
58
|
"@polkadot/keyring": "^14.0.3",
|
|
58
|
-
"@polkadot/rpc-core": "^
|
|
59
|
-
"@polkadot/rpc-provider": "^
|
|
60
|
-
"@polkadot/types": "^
|
|
61
|
-
"@polkadot/types-codec": "^
|
|
59
|
+
"@polkadot/rpc-core": "^17.0.1",
|
|
60
|
+
"@polkadot/rpc-provider": "^17.0.1",
|
|
61
|
+
"@polkadot/types": "^17.0.1",
|
|
62
|
+
"@polkadot/types-codec": "^17.0.1",
|
|
62
63
|
"@polkadot/util": "^14.0.3",
|
|
63
64
|
"@polkadot/util-crypto": "^14.0.3",
|
|
64
65
|
"bignumber.js": "^9.3.1",
|
|
@@ -67,15 +68,17 @@
|
|
|
67
68
|
},
|
|
68
69
|
"devDependencies": {
|
|
69
70
|
"@argonprotocol/ethereum-contracts": "workspace:*",
|
|
70
|
-
"@argonprotocol/testing": "1.
|
|
71
|
-
"@polkadot/typegen": "^
|
|
71
|
+
"@argonprotocol/testing": "1.5.0-dev.d2f56d16",
|
|
72
|
+
"@polkadot/typegen": "^17.0.1",
|
|
72
73
|
"@substrate/ss58-registry": "^1.51.0",
|
|
73
74
|
"@types/node": "^20",
|
|
75
|
+
"@types/ws": "^8.18.1",
|
|
74
76
|
"shx": "^0.4.0",
|
|
75
77
|
"tsup": "^8.5.0",
|
|
76
78
|
"tsx": "^4.20.4",
|
|
77
79
|
"typescript": "^5.9.2",
|
|
78
|
-
"vitest": "^5.0.0"
|
|
80
|
+
"vitest": "^5.0.0",
|
|
81
|
+
"ws": "^8.18.0"
|
|
79
82
|
},
|
|
80
83
|
"packageManager": "yarn@4.1.0"
|
|
81
84
|
}
|
|
@@ -7,7 +7,7 @@ import type {} from '@polkadot/api-base/types/consts';
|
|
|
7
7
|
import type { ApiTypes, AugmentedConst } from '@polkadot/api-base/types';
|
|
8
8
|
import type { u128, u16, u32, u64, u8 } from '@polkadot/types-codec';
|
|
9
9
|
import type { ITuple } from '@polkadot/types-codec/types';
|
|
10
|
-
import type { AccountId32, Percent } from '@polkadot/types/interfaces/runtime';
|
|
10
|
+
import type { AccountId32, Percent, Permill } from '@polkadot/types/interfaces/runtime';
|
|
11
11
|
import type {
|
|
12
12
|
FrameSupportPalletId,
|
|
13
13
|
FrameSystemLimitsBlockLength,
|
|
@@ -370,6 +370,10 @@ declare module '@polkadot/api-base/types/consts' {
|
|
|
370
370
|
metaChangesTickDelay: u64 & AugmentedConst<ApiType>;
|
|
371
371
|
};
|
|
372
372
|
operationalAccounts: {
|
|
373
|
+
/**
|
|
374
|
+
* Allowed Bitcoin valuation shortfall below the liquidity minimum.
|
|
375
|
+
**/
|
|
376
|
+
bitcoinLiquidityTolerance: Percent & AugmentedConst<ApiType>;
|
|
373
377
|
/**
|
|
374
378
|
* Additional argon amount (base units) required per follow-on access code after an account
|
|
375
379
|
* becomes operational.
|
|
@@ -384,7 +388,7 @@ declare module '@polkadot/api-base/types/consts' {
|
|
|
384
388
|
**/
|
|
385
389
|
maxAvailableAccessCodes: u32 & AugmentedConst<ApiType>;
|
|
386
390
|
/**
|
|
387
|
-
* Minimum
|
|
391
|
+
* Minimum Bitcoin-backed ARGON liquidity required to register and activate.
|
|
388
392
|
**/
|
|
389
393
|
minimumBitcoin: u128 & AugmentedConst<ApiType>;
|
|
390
394
|
/**
|
|
@@ -590,10 +594,18 @@ declare module '@polkadot/api-base/types/consts' {
|
|
|
590
594
|
operationalFeeMultiplier: u8 & AugmentedConst<ApiType>;
|
|
591
595
|
};
|
|
592
596
|
treasury: {
|
|
597
|
+
/**
|
|
598
|
+
* Default percent of maximum Bitcoin-mintable Argons targeted by the network.
|
|
599
|
+
**/
|
|
600
|
+
defaultTargetBitcoinPercent: Percent & AugmentedConst<ApiType>;
|
|
593
601
|
/**
|
|
594
602
|
* The maximum number of active Argonot bond lots.
|
|
595
603
|
**/
|
|
596
604
|
maxActiveArgonotBondLots: u32 & AugmentedConst<ApiType>;
|
|
605
|
+
/**
|
|
606
|
+
* Maximum live Argon bond lots while direct frame payouts iterate every lot.
|
|
607
|
+
**/
|
|
608
|
+
maxArgonBondLots: u32 & AugmentedConst<ApiType>;
|
|
597
609
|
/**
|
|
598
610
|
* The maximum percent of ownership-token circulation that can be bonded.
|
|
599
611
|
**/
|
|
@@ -602,10 +614,6 @@ declare module '@polkadot/api-base/types/consts' {
|
|
|
602
614
|
* The maximum number of bond lots whose release delay may mature in a single frame.
|
|
603
615
|
**/
|
|
604
616
|
maxPendingUnlocksPerFrame: u32 & AugmentedConst<ApiType>;
|
|
605
|
-
/**
|
|
606
|
-
* The maximum number of accepted bond lots in a vault's accepted bond-lot list.
|
|
607
|
-
**/
|
|
608
|
-
maxTreasuryContributors: u32 & AugmentedConst<ApiType>;
|
|
609
617
|
/**
|
|
610
618
|
* The maximum number of vaults that can participate in one frame's locked vault capital.
|
|
611
619
|
**/
|
|
@@ -614,18 +622,38 @@ declare module '@polkadot/api-base/types/consts' {
|
|
|
614
622
|
* The minimum whole-bond purchase amount.
|
|
615
623
|
**/
|
|
616
624
|
minimumArgonsPerContributor: u128 & AugmentedConst<ApiType>;
|
|
625
|
+
/**
|
|
626
|
+
* Minimum vault earnings rate before securitization coverage is applied.
|
|
627
|
+
**/
|
|
628
|
+
minimumVaultProfitPercent: Percent & AugmentedConst<ApiType>;
|
|
617
629
|
/**
|
|
618
630
|
* Treasury pallet id retained in metadata for account derivation.
|
|
619
631
|
**/
|
|
620
632
|
palletId: FrameSupportPalletId & AugmentedConst<ApiType>;
|
|
621
633
|
/**
|
|
622
|
-
*
|
|
634
|
+
* Maximum percent paid to Argon bonds when the network target is filled.
|
|
635
|
+
**/
|
|
636
|
+
percentForArgonBondPool: Percent & AugmentedConst<ApiType>;
|
|
637
|
+
/**
|
|
638
|
+
* Percent reserved for Bitcoin Liquids and burned in this release.
|
|
623
639
|
**/
|
|
624
|
-
|
|
640
|
+
percentForBitcoinLiquidPool: Percent & AugmentedConst<ApiType>;
|
|
641
|
+
/**
|
|
642
|
+
* Percent reserved for future mining-operator rewards and burned in this release.
|
|
643
|
+
**/
|
|
644
|
+
percentForMiningOperatorPool: Percent & AugmentedConst<ApiType>;
|
|
645
|
+
/**
|
|
646
|
+
* Percent of the full bid pool paid to Argonot Stakes.
|
|
647
|
+
**/
|
|
648
|
+
percentForStakePool: Percent & AugmentedConst<ApiType>;
|
|
625
649
|
/**
|
|
626
650
|
* Percent of the bid pool reserved for treasury reserves.
|
|
627
651
|
**/
|
|
628
652
|
percentForTreasuryReserves: Percent & AugmentedConst<ApiType>;
|
|
653
|
+
/**
|
|
654
|
+
* Maximum percent paid to vaults when the network target is filled.
|
|
655
|
+
**/
|
|
656
|
+
percentForVaultPool: Percent & AugmentedConst<ApiType>;
|
|
629
657
|
/**
|
|
630
658
|
* The number of frames a releasing bond lot remains held before release.
|
|
631
659
|
**/
|
|
@@ -634,6 +662,9 @@ declare module '@polkadot/api-base/types/consts' {
|
|
|
634
662
|
* Account that holds treasury reserves for claims and reserve-funded payouts.
|
|
635
663
|
**/
|
|
636
664
|
treasuryReservesAccount: AccountId32 & AugmentedConst<ApiType>;
|
|
665
|
+
upstreamBitcoinTarget: u128 & AugmentedConst<ApiType>;
|
|
666
|
+
upstreamBitcoinWeight: Permill & AugmentedConst<ApiType>;
|
|
667
|
+
upstreamBondTarget: u128 & AugmentedConst<ApiType>;
|
|
637
668
|
};
|
|
638
669
|
txPause: {
|
|
639
670
|
/**
|
|
@@ -650,6 +681,10 @@ declare module '@polkadot/api-base/types/consts' {
|
|
|
650
681
|
batchedCallsLimit: u32 & AugmentedConst<ApiType>;
|
|
651
682
|
};
|
|
652
683
|
vaults: {
|
|
684
|
+
/**
|
|
685
|
+
* Bitcoin blocks in the term of a newly created Bitcoin lock.
|
|
686
|
+
**/
|
|
687
|
+
bitcoinLockDurationBlocks: u64 & AugmentedConst<ApiType>;
|
|
653
688
|
/**
|
|
654
689
|
* Max concurrent cosigns pending per vault
|
|
655
690
|
**/
|
|
@@ -663,17 +698,17 @@ declare module '@polkadot/api-base/types/consts' {
|
|
|
663
698
|
**/
|
|
664
699
|
maxVaults: u32 & AugmentedConst<ApiType>;
|
|
665
700
|
/**
|
|
666
|
-
*
|
|
667
|
-
**/
|
|
668
|
-
operationalMinimumVaultLockTicks: u64 & AugmentedConst<ApiType>;
|
|
669
|
-
/**
|
|
670
|
-
* Minimum vault securitization required while the operational floor lock is active.
|
|
701
|
+
* Vault securitization committed when the operator becomes operational.
|
|
671
702
|
**/
|
|
672
703
|
operationalMinimumVaultSecuritization: u128 & AugmentedConst<ApiType>;
|
|
673
704
|
/**
|
|
674
705
|
* The number of frames within which revenue must be collected
|
|
675
706
|
**/
|
|
676
707
|
revenueCollectionExpirationFrames: u64 & AugmentedConst<ApiType>;
|
|
708
|
+
/**
|
|
709
|
+
* Bitcoin blocks in the securitization exit notice period.
|
|
710
|
+
**/
|
|
711
|
+
securitizationExitNoticeBlocks: u64 & AugmentedConst<ApiType>;
|
|
677
712
|
};
|
|
678
713
|
} // AugmentedConsts
|
|
679
714
|
} // declare module
|
|
@@ -1361,10 +1361,18 @@ declare module '@polkadot/api-base/types/errors' {
|
|
|
1361
1361
|
* The bond lot is already scheduled for release.
|
|
1362
1362
|
**/
|
|
1363
1363
|
BondLotAlreadyReleasing: AugmentedError<ApiType>;
|
|
1364
|
+
/**
|
|
1365
|
+
* Historical metrics can only be backfilled for vault bond lots.
|
|
1366
|
+
**/
|
|
1367
|
+
BondLotCannotBeBackfilled: AugmentedError<ApiType>;
|
|
1364
1368
|
/**
|
|
1365
1369
|
* Only an active vault bond owned by its operator can be used as flexible.
|
|
1366
1370
|
**/
|
|
1367
1371
|
BondLotCannotBeFlexible: AugmentedError<ApiType>;
|
|
1372
|
+
/**
|
|
1373
|
+
* The lot's metrics changed since the backfill was calculated.
|
|
1374
|
+
**/
|
|
1375
|
+
BondLotMetricsChanged: AugmentedError<ApiType>;
|
|
1368
1376
|
/**
|
|
1369
1377
|
* The bond lot could not be found.
|
|
1370
1378
|
**/
|
|
@@ -1381,10 +1389,6 @@ declare module '@polkadot/api-base/types/errors' {
|
|
|
1381
1389
|
* The bonus approval nonce has already been consumed or superseded.
|
|
1382
1390
|
**/
|
|
1383
1391
|
BonusApprovalAlreadyUsed: AugmentedError<ApiType>;
|
|
1384
|
-
/**
|
|
1385
|
-
* The approved bonus plus the vault's profit sharing exceeds 100%.
|
|
1386
|
-
**/
|
|
1387
|
-
BonusApprovalExceedsProfitSharing: AugmentedError<ApiType>;
|
|
1388
1392
|
/**
|
|
1389
1393
|
* The bonus approval already expired.
|
|
1390
1394
|
**/
|
|
@@ -1398,21 +1402,29 @@ declare module '@polkadot/api-base/types/errors' {
|
|
|
1398
1402
|
**/
|
|
1399
1403
|
BonusApprovalWrongVault: AugmentedError<ApiType>;
|
|
1400
1404
|
/**
|
|
1401
|
-
* The vault doesn't have enough
|
|
1405
|
+
* The vault doesn't have enough raw securitization to support this bond purchase.
|
|
1402
1406
|
**/
|
|
1403
1407
|
InsufficientBondSpace: AugmentedError<ApiType>;
|
|
1404
1408
|
/**
|
|
1405
1409
|
* An internal error occurred.
|
|
1406
1410
|
**/
|
|
1407
1411
|
InternalError: AugmentedError<ApiType>;
|
|
1412
|
+
/**
|
|
1413
|
+
* The proposed backfill would reduce or corrupt the lot's earnings metrics.
|
|
1414
|
+
**/
|
|
1415
|
+
InvalidBondLotMetrics: AugmentedError<ApiType>;
|
|
1408
1416
|
/**
|
|
1409
1417
|
* The bonus approval signature is invalid or unauthorized.
|
|
1410
1418
|
**/
|
|
1411
1419
|
InvalidBonusApprovalSignature: AugmentedError<ApiType>;
|
|
1412
1420
|
/**
|
|
1413
|
-
* The
|
|
1421
|
+
* The network has reached the direct-payout vault bond lot admission limit.
|
|
1422
|
+
**/
|
|
1423
|
+
MaxArgonBondLotsExceeded: AugmentedError<ApiType>;
|
|
1424
|
+
/**
|
|
1425
|
+
* The vault already has the maximum number of flexible bond lots.
|
|
1414
1426
|
**/
|
|
1415
|
-
|
|
1427
|
+
MaxFlexibleBondLotsExceeded: AugmentedError<ApiType>;
|
|
1416
1428
|
/**
|
|
1417
1429
|
* Too many bond lot releases are scheduled for the same frame.
|
|
1418
1430
|
**/
|
|
@@ -1461,13 +1473,13 @@ declare module '@polkadot/api-base/types/errors' {
|
|
|
1461
1473
|
**/
|
|
1462
1474
|
AccountBelowMinimumBalance: AugmentedError<ApiType>;
|
|
1463
1475
|
/**
|
|
1464
|
-
*
|
|
1476
|
+
* Held Argonots cannot be reduced below the amount already crosschain-encumbered.
|
|
1465
1477
|
**/
|
|
1466
|
-
|
|
1478
|
+
ArgonotsBelowEncumberedBacking: AugmentedError<ApiType>;
|
|
1467
1479
|
/**
|
|
1468
|
-
*
|
|
1480
|
+
* Bitcoin conversion to compressed pubkey failed
|
|
1469
1481
|
**/
|
|
1470
|
-
|
|
1482
|
+
BitcoinConversionFailed: AugmentedError<ApiType>;
|
|
1471
1483
|
/**
|
|
1472
1484
|
* A funding change is already scheduled
|
|
1473
1485
|
**/
|
|
@@ -21,7 +21,7 @@ import type {
|
|
|
21
21
|
u64,
|
|
22
22
|
} from '@polkadot/types-codec';
|
|
23
23
|
import type { ITuple } from '@polkadot/types-codec/types';
|
|
24
|
-
import type { AccountId32, H160, H256 } from '@polkadot/types/interfaces/runtime';
|
|
24
|
+
import type { AccountId32, H160, H256, Percent } from '@polkadot/types/interfaces/runtime';
|
|
25
25
|
import type {
|
|
26
26
|
ArgonNotaryAuditErrorVerifyError,
|
|
27
27
|
ArgonPrimitivesBitcoinUtxoRef,
|
|
@@ -1916,6 +1916,15 @@ declare module '@polkadot/api-base/types/events' {
|
|
|
1916
1916
|
>;
|
|
1917
1917
|
};
|
|
1918
1918
|
treasury: {
|
|
1919
|
+
/**
|
|
1920
|
+
* Historical flexible-bond earnings were attributed to a surviving vault lot. No funds
|
|
1921
|
+
* move.
|
|
1922
|
+
**/
|
|
1923
|
+
BondLotEarningsBackfilled: AugmentedEvent<
|
|
1924
|
+
ApiType,
|
|
1925
|
+
[bondLotId: u64, addedFrames: u32, addedEarnings: u128],
|
|
1926
|
+
{ bondLotId: u64; addedFrames: u32; addedEarnings: u128 }
|
|
1927
|
+
>;
|
|
1919
1928
|
BondLotFlexibilityChanged: AugmentedEvent<
|
|
1920
1929
|
ApiType,
|
|
1921
1930
|
[vaultId: u32, bondLotId: u64, isFlexible: bool],
|
|
@@ -1981,6 +1990,14 @@ declare module '@polkadot/api-base/types/events' {
|
|
|
1981
1990
|
reason: PalletTreasuryBondReleaseReason;
|
|
1982
1991
|
}
|
|
1983
1992
|
>;
|
|
1993
|
+
/**
|
|
1994
|
+
* A fixed or unearned reward allocation could not be burned.
|
|
1995
|
+
**/
|
|
1996
|
+
CouldNotBurnRewardAllocation: AugmentedEvent<
|
|
1997
|
+
ApiType,
|
|
1998
|
+
[frameId: u64, amount: u128, dispatchError: SpRuntimeDispatchError],
|
|
1999
|
+
{ frameId: u64; amount: u128; dispatchError: SpRuntimeDispatchError }
|
|
2000
|
+
>;
|
|
1984
2001
|
/**
|
|
1985
2002
|
* An error occurred while paying frame earnings for an Argonot bond lot.
|
|
1986
2003
|
**/
|
|
@@ -2070,18 +2087,20 @@ declare module '@polkadot/api-base/types/events' {
|
|
|
2070
2087
|
[
|
|
2071
2088
|
frameId: u64,
|
|
2072
2089
|
bidPoolDistributed: u128,
|
|
2073
|
-
|
|
2074
|
-
|
|
2075
|
-
|
|
2090
|
+
stakePoolDistributed: u128,
|
|
2091
|
+
argonBondPoolDistributed: u128,
|
|
2092
|
+
vaultPoolDistributed: u128,
|
|
2093
|
+
burned: u128,
|
|
2076
2094
|
treasuryReserves: u128,
|
|
2077
2095
|
participatingVaults: u32,
|
|
2078
2096
|
],
|
|
2079
2097
|
{
|
|
2080
2098
|
frameId: u64;
|
|
2081
2099
|
bidPoolDistributed: u128;
|
|
2082
|
-
|
|
2083
|
-
|
|
2084
|
-
|
|
2100
|
+
stakePoolDistributed: u128;
|
|
2101
|
+
argonBondPoolDistributed: u128;
|
|
2102
|
+
vaultPoolDistributed: u128;
|
|
2103
|
+
burned: u128;
|
|
2085
2104
|
treasuryReserves: u128;
|
|
2086
2105
|
participatingVaults: u32;
|
|
2087
2106
|
}
|
|
@@ -2091,14 +2110,19 @@ declare module '@polkadot/api-base/types/events' {
|
|
|
2091
2110
|
**/
|
|
2092
2111
|
FrameVaultCapitalLocked: AugmentedEvent<
|
|
2093
2112
|
ApiType,
|
|
2094
|
-
[frameId: u64,
|
|
2095
|
-
{ frameId: u64;
|
|
2113
|
+
[frameId: u64, totalActiveBonds: u128, participatingVaults: u32],
|
|
2114
|
+
{ frameId: u64; totalActiveBonds: u128; participatingVaults: u32 }
|
|
2096
2115
|
>;
|
|
2097
2116
|
ReservedBondSpaceChanged: AugmentedEvent<
|
|
2098
2117
|
ApiType,
|
|
2099
2118
|
[vaultId: u32, reservedBondSpace: u32],
|
|
2100
2119
|
{ vaultId: u32; reservedBondSpace: u32 }
|
|
2101
2120
|
>;
|
|
2121
|
+
RewardEconomicsConfigured: AugmentedEvent<
|
|
2122
|
+
ApiType,
|
|
2123
|
+
[targetBitcoinPercent: Percent],
|
|
2124
|
+
{ targetBitcoinPercent: Percent }
|
|
2125
|
+
>;
|
|
2102
2126
|
};
|
|
2103
2127
|
txPause: {
|
|
2104
2128
|
/**
|
|
@@ -2170,7 +2194,17 @@ declare module '@polkadot/api-base/types/events' {
|
|
|
2170
2194
|
>;
|
|
2171
2195
|
};
|
|
2172
2196
|
vaults: {
|
|
2173
|
-
|
|
2197
|
+
ArgonotExitReleased: AugmentedEvent<
|
|
2198
|
+
ApiType,
|
|
2199
|
+
[vaultId: u32, amount: u128],
|
|
2200
|
+
{ vaultId: u32; amount: u128 }
|
|
2201
|
+
>;
|
|
2202
|
+
ArgonotExitRequested: AugmentedEvent<
|
|
2203
|
+
ApiType,
|
|
2204
|
+
[vaultId: u32, amount: u128, noticeEndsAt: u64],
|
|
2205
|
+
{ vaultId: u32; amount: u128; noticeEndsAt: u64 }
|
|
2206
|
+
>;
|
|
2207
|
+
ArgonotSecuritizationSet: AugmentedEvent<
|
|
2174
2208
|
ApiType,
|
|
2175
2209
|
[vaultId: u32, operatorAccountId: AccountId32, amount: u128],
|
|
2176
2210
|
{ vaultId: u32; operatorAccountId: AccountId32; amount: u128 }
|
|
@@ -2212,6 +2246,16 @@ declare module '@polkadot/api-base/types/events' {
|
|
|
2212
2246
|
[vaultId: u32, reservedSecuritizationSpace: u128],
|
|
2213
2247
|
{ vaultId: u32; reservedSecuritizationSpace: u128 }
|
|
2214
2248
|
>;
|
|
2249
|
+
SecuritizationExitReleased: AugmentedEvent<
|
|
2250
|
+
ApiType,
|
|
2251
|
+
[vaultId: u32, amount: u128],
|
|
2252
|
+
{ vaultId: u32; amount: u128 }
|
|
2253
|
+
>;
|
|
2254
|
+
SecuritizationExitRequested: AugmentedEvent<
|
|
2255
|
+
ApiType,
|
|
2256
|
+
[vaultId: u32, amount: u128, noticeEndsAt: u64],
|
|
2257
|
+
{ vaultId: u32; amount: u128; noticeEndsAt: u64 }
|
|
2258
|
+
>;
|
|
2215
2259
|
SecuritizationReserved: AugmentedEvent<
|
|
2216
2260
|
ApiType,
|
|
2217
2261
|
[
|
|
@@ -21,9 +21,10 @@ import type {
|
|
|
21
21
|
u8,
|
|
22
22
|
} from '@polkadot/types-codec';
|
|
23
23
|
import type { AnyNumber, ITuple } from '@polkadot/types-codec/types';
|
|
24
|
-
import type { AccountId32, H160, H256 } from '@polkadot/types/interfaces/runtime';
|
|
24
|
+
import type { AccountId32, H160, H256, Percent } from '@polkadot/types/interfaces/runtime';
|
|
25
25
|
import type {
|
|
26
26
|
ArgonNotaryAuditErrorVerifyError,
|
|
27
|
+
ArgonPrimitivesAmountRankAmountRankKey,
|
|
27
28
|
ArgonPrimitivesBalanceChangeAccountOrigin,
|
|
28
29
|
ArgonPrimitivesBitcoinBitcoinBlock,
|
|
29
30
|
ArgonPrimitivesBitcoinBitcoinCosignScriptPubkey,
|
|
@@ -49,8 +50,9 @@ import type {
|
|
|
49
50
|
ArgonPrimitivesNotaryNotaryRecord,
|
|
50
51
|
ArgonPrimitivesProvidersBlockSealerInfo,
|
|
51
52
|
ArgonPrimitivesTickTicker,
|
|
53
|
+
ArgonPrimitivesTreasuryPositionQuantities,
|
|
52
54
|
ArgonPrimitivesVault,
|
|
53
|
-
|
|
55
|
+
ArgonPrimitivesVaultVaultArgonotSecuritization,
|
|
54
56
|
FrameSupportDispatchPerDispatchClassWeight,
|
|
55
57
|
FrameSupportTokensFungibleImbalance,
|
|
56
58
|
FrameSupportTokensMiscIdAmountRuntimeFreezeReason,
|
|
@@ -93,6 +95,7 @@ import type {
|
|
|
93
95
|
PalletGrandpaStoredState,
|
|
94
96
|
PalletLocalchainTransferQueuedTransferOut,
|
|
95
97
|
PalletMiningSlotMinerNonceScoring,
|
|
98
|
+
PalletMiningSlotSeatPriceStats,
|
|
96
99
|
PalletMintMintAction,
|
|
97
100
|
PalletMintMintQueueCursor,
|
|
98
101
|
PalletMintPendingBitcoinMint,
|
|
@@ -111,6 +114,7 @@ import type {
|
|
|
111
114
|
PalletTreasuryBondLotSummary,
|
|
112
115
|
PalletTreasuryFrameArgonotBondParticipants,
|
|
113
116
|
PalletTreasuryFrameVaultCapital,
|
|
117
|
+
PalletTreasuryPositionsPosition,
|
|
114
118
|
PalletTreasuryVaultBondState,
|
|
115
119
|
PalletVaultsVaultFrameRevenue,
|
|
116
120
|
SpConsensusGrandpaAppPublic,
|
|
@@ -1085,9 +1089,14 @@ declare module '@polkadot/api-base/types/storage' {
|
|
|
1085
1089
|
**/
|
|
1086
1090
|
argonotsPerMiningSeat: AugmentedQuery<ApiType, () => Observable<u128>, []>;
|
|
1087
1091
|
/**
|
|
1088
|
-
*
|
|
1092
|
+
* Winning bid totals and seat counts for averaging prices over the last 10 frames (newest
|
|
1093
|
+
* first).
|
|
1089
1094
|
**/
|
|
1090
|
-
averagePricePerSeat: AugmentedQuery<
|
|
1095
|
+
averagePricePerSeat: AugmentedQuery<
|
|
1096
|
+
ApiType,
|
|
1097
|
+
() => Observable<Vec<PalletMiningSlotSeatPriceStats>>,
|
|
1098
|
+
[]
|
|
1099
|
+
>;
|
|
1091
1100
|
/**
|
|
1092
1101
|
* The cohort set to go into effect in the next slot. The Vec has all
|
|
1093
1102
|
* registrants with their bid amount
|
|
@@ -1201,13 +1210,9 @@ declare module '@polkadot/api-base/types/storage' {
|
|
|
1201
1210
|
**/
|
|
1202
1211
|
miningMintPerCohort: AugmentedQuery<ApiType, () => Observable<BTreeMap<u64, u128>>, []>;
|
|
1203
1212
|
/**
|
|
1204
|
-
*
|
|
1213
|
+
* Bitcoin-minted Argons that have not been explicitly repaid through Fission settlement.
|
|
1205
1214
|
**/
|
|
1206
1215
|
mintedBitcoinMicrogons: AugmentedQuery<ApiType, () => Observable<u128>, []>;
|
|
1207
|
-
/**
|
|
1208
|
-
* The total amount of microgons minted for mining
|
|
1209
|
-
**/
|
|
1210
|
-
mintedMiningMicrogons: AugmentedQuery<ApiType, () => Observable<u128>, []>;
|
|
1211
1216
|
/**
|
|
1212
1217
|
* The next monotonic queue index to assign to a pending bitcoin mint.
|
|
1213
1218
|
**/
|
|
@@ -1796,12 +1801,22 @@ declare module '@polkadot/api-base/types/storage' {
|
|
|
1796
1801
|
) => Observable<Option<Null>>,
|
|
1797
1802
|
[AccountId32, u64]
|
|
1798
1803
|
>;
|
|
1804
|
+
/**
|
|
1805
|
+
* Live Argon bond lot ids associated with a vault, including lots awaiting release. Direct
|
|
1806
|
+
* frame payouts iterate this admission-bounded index.
|
|
1807
|
+
**/
|
|
1808
|
+
bondLotIdsByVault: AugmentedQuery<
|
|
1809
|
+
ApiType,
|
|
1810
|
+
(
|
|
1811
|
+
arg1: u32 | AnyNumber | Uint8Array,
|
|
1812
|
+
arg2: u64 | AnyNumber | Uint8Array,
|
|
1813
|
+
) => Observable<Option<Null>>,
|
|
1814
|
+
[u32, u64]
|
|
1815
|
+
>;
|
|
1799
1816
|
/**
|
|
1800
1817
|
* The active bond state for a vault.
|
|
1801
1818
|
*
|
|
1802
|
-
*
|
|
1803
|
-
* when amounts tie. Flexible lots remain in `BondLotById` and are represented here by their
|
|
1804
|
-
* aggregate.
|
|
1819
|
+
* Admission totals and flexible displacement; individual lots live in `BondLotById`.
|
|
1805
1820
|
**/
|
|
1806
1821
|
bondLotsByVault: AugmentedQuery<
|
|
1807
1822
|
ApiType,
|
|
@@ -1819,9 +1834,7 @@ declare module '@polkadot/api-base/types/storage' {
|
|
|
1819
1834
|
[]
|
|
1820
1835
|
>;
|
|
1821
1836
|
/**
|
|
1822
|
-
* The vault capital locked for the current frame.
|
|
1823
|
-
*
|
|
1824
|
-
* Payout uses this to see which vaults and bond lots are participating in the frame.
|
|
1837
|
+
* The network bond total and vault capital locked for the current frame's payout.
|
|
1825
1838
|
**/
|
|
1826
1839
|
currentFrameVaultCapital: AugmentedQuery<
|
|
1827
1840
|
ApiType,
|
|
@@ -1866,9 +1879,36 @@ declare module '@polkadot/api-base/types/storage' {
|
|
|
1866
1879
|
[u64]
|
|
1867
1880
|
>;
|
|
1868
1881
|
/**
|
|
1869
|
-
*
|
|
1882
|
+
* Configurable percent of maximum Bitcoin-mintable Argons targeted by the network.
|
|
1870
1883
|
**/
|
|
1871
|
-
|
|
1884
|
+
targetBitcoinPercent: AugmentedQuery<ApiType, () => Observable<Percent>, []>;
|
|
1885
|
+
/**
|
|
1886
|
+
* Live Argon bond lots, including those awaiting release; stakes have a separate admission
|
|
1887
|
+
* limit.
|
|
1888
|
+
**/
|
|
1889
|
+
totalArgonBondLots: AugmentedQuery<ApiType, () => Observable<u32>, []>;
|
|
1890
|
+
};
|
|
1891
|
+
treasuryPositions: {
|
|
1892
|
+
/**
|
|
1893
|
+
* Maintained network quantities, updated together with their account contributions.
|
|
1894
|
+
* Treasury reads these when freezing frame inputs. This replaces its live Argonot stake total.
|
|
1895
|
+
**/
|
|
1896
|
+
networkTotals: AugmentedQuery<
|
|
1897
|
+
ApiType,
|
|
1898
|
+
() => Observable<ArgonPrimitivesTreasuryPositionQuantities>,
|
|
1899
|
+
[]
|
|
1900
|
+
>;
|
|
1901
|
+
/**
|
|
1902
|
+
* Maintained source quantities keyed by the actual position owner. Upstream quantities belong
|
|
1903
|
+
* to the linked vault account; primary and mining account balances are separate owners.
|
|
1904
|
+
**/
|
|
1905
|
+
positionsByAccount: AugmentedQuery<
|
|
1906
|
+
ApiType,
|
|
1907
|
+
(
|
|
1908
|
+
arg: AccountId32 | string | Uint8Array,
|
|
1909
|
+
) => Observable<Option<PalletTreasuryPositionsPosition>>,
|
|
1910
|
+
[AccountId32]
|
|
1911
|
+
>;
|
|
1872
1912
|
};
|
|
1873
1913
|
txPause: {
|
|
1874
1914
|
/**
|
|
@@ -1884,13 +1924,13 @@ declare module '@polkadot/api-base/types/storage' {
|
|
|
1884
1924
|
};
|
|
1885
1925
|
vaults: {
|
|
1886
1926
|
/**
|
|
1887
|
-
*
|
|
1927
|
+
* Argonots held for the vault, with reward commitments and cross-chain encumbrances.
|
|
1888
1928
|
**/
|
|
1889
|
-
|
|
1929
|
+
argonotSecuritizationByVaultId: AugmentedQuery<
|
|
1890
1930
|
ApiType,
|
|
1891
1931
|
(
|
|
1892
1932
|
arg: u32 | AnyNumber | Uint8Array,
|
|
1893
|
-
) => Observable<Option<
|
|
1933
|
+
) => Observable<Option<ArgonPrimitivesVaultVaultArgonotSecuritization>>,
|
|
1894
1934
|
[u32]
|
|
1895
1935
|
>;
|
|
1896
1936
|
/**
|
|
@@ -1941,6 +1981,10 @@ declare module '@polkadot/api-base/types/storage' {
|
|
|
1941
1981
|
[u32]
|
|
1942
1982
|
>;
|
|
1943
1983
|
revenuePerFrameByVaultCount: AugmentedQuery<ApiType, () => Observable<u32>, []>;
|
|
1984
|
+
/**
|
|
1985
|
+
* Raw securitization across all open vaults, including those below the payout cutoff.
|
|
1986
|
+
**/
|
|
1987
|
+
totalVaultSecuritization: AugmentedQuery<ApiType, () => Observable<u128>, []>;
|
|
1944
1988
|
/**
|
|
1945
1989
|
* The vaults that have funds releasing at a given bitcoin height
|
|
1946
1990
|
**/
|
|
@@ -1966,12 +2010,18 @@ declare module '@polkadot/api-base/types/storage' {
|
|
|
1966
2010
|
[u32]
|
|
1967
2011
|
>;
|
|
1968
2012
|
/**
|
|
1969
|
-
*
|
|
2013
|
+
* Open vaults ordered by raw securitization (largest first), then vault ID.
|
|
1970
2014
|
**/
|
|
1971
|
-
|
|
2015
|
+
vaultSecuritizationRanks: AugmentedQuery<
|
|
1972
2016
|
ApiType,
|
|
1973
|
-
(
|
|
1974
|
-
|
|
2017
|
+
(
|
|
2018
|
+
arg:
|
|
2019
|
+
| ArgonPrimitivesAmountRankAmountRankKey
|
|
2020
|
+
| { descendingAmount?: any; orderedId?: any }
|
|
2021
|
+
| string
|
|
2022
|
+
| Uint8Array,
|
|
2023
|
+
) => Observable<Option<Null>>,
|
|
2024
|
+
[ArgonPrimitivesAmountRankAmountRankKey]
|
|
1975
2025
|
>;
|
|
1976
2026
|
/**
|
|
1977
2027
|
* Vault Bitcoin Xpub and current child counter by VaultId
|
|
@@ -23,7 +23,11 @@ import type {
|
|
|
23
23
|
u64,
|
|
24
24
|
} from '@polkadot/types-codec';
|
|
25
25
|
import type { AnyNumber, Codec } from '@polkadot/types-codec/types';
|
|
26
|
-
import type {
|
|
26
|
+
import type {
|
|
27
|
+
ExtrinsicOrHash,
|
|
28
|
+
ExtrinsicStatus,
|
|
29
|
+
GeneratedSessionKeys,
|
|
30
|
+
} from '@polkadot/types/interfaces/author';
|
|
27
31
|
import type { EpochAuthorship } from '@polkadot/types/interfaces/babe';
|
|
28
32
|
import type { BeefyVersionedFinalityProof } from '@polkadot/types/interfaces/beefy';
|
|
29
33
|
import type { BlockHash } from '@polkadot/types/interfaces/chain';
|
|
@@ -61,7 +65,7 @@ import type {
|
|
|
61
65
|
JustificationNotification,
|
|
62
66
|
ReportedRoundStates,
|
|
63
67
|
} from '@polkadot/types/interfaces/grandpa';
|
|
64
|
-
import type { MmrHash, MmrLeafBatchProof } from '@polkadot/types/interfaces/mmr';
|
|
68
|
+
import type { MmrAncestryProof, MmrHash, MmrLeafBatchProof } from '@polkadot/types/interfaces/mmr';
|
|
65
69
|
import type { StorageKind } from '@polkadot/types/interfaces/offchain';
|
|
66
70
|
import type { FeeDetails, RuntimeDispatchInfoV1 } from '@polkadot/types/interfaces/payment';
|
|
67
71
|
import type { RpcMethods } from '@polkadot/types/interfaces/rpc';
|
|
@@ -140,6 +144,12 @@ declare module '@polkadot/rpc-core/types/jsonrpc' {
|
|
|
140
144
|
* Generate new session keys and returns the corresponding public keys
|
|
141
145
|
**/
|
|
142
146
|
rotateKeys: AugmentedRpc<() => Observable<Bytes>>;
|
|
147
|
+
/**
|
|
148
|
+
* Generate new session keys and returns the corresponding public keys and owner proof
|
|
149
|
+
**/
|
|
150
|
+
rotateKeysWithOwner: AugmentedRpc<
|
|
151
|
+
(owner: Bytes | string | Uint8Array) => Observable<GeneratedSessionKeys>
|
|
152
|
+
>;
|
|
143
153
|
/**
|
|
144
154
|
* Submit and subscribe to watch an extrinsic until unsubscribed
|
|
145
155
|
**/
|
|
@@ -721,6 +731,16 @@ declare module '@polkadot/rpc-core/types/jsonrpc' {
|
|
|
721
731
|
subscribeJustifications: AugmentedRpc<() => Observable<JustificationNotification>>;
|
|
722
732
|
};
|
|
723
733
|
mmr: {
|
|
734
|
+
/**
|
|
735
|
+
* Generate an MMR ancestry proof for the given block number.
|
|
736
|
+
**/
|
|
737
|
+
generateAncestryProof: AugmentedRpc<
|
|
738
|
+
(
|
|
739
|
+
prevBlockNumber: u64 | AnyNumber | Uint8Array,
|
|
740
|
+
bestKnownBlockNumber?: u64 | AnyNumber | Uint8Array,
|
|
741
|
+
at?: BlockHash | string | Uint8Array,
|
|
742
|
+
) => Observable<MmrAncestryProof>
|
|
743
|
+
>;
|
|
724
744
|
/**
|
|
725
745
|
* Generate MMR proof for the given block numbers.
|
|
726
746
|
**/
|