@argonprotocol/mainchain 1.5.2-dev.5254a99c → 1.5.2-dev.5a6c09ac

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.
Files changed (37) hide show
  1. package/README.md +20 -0
  2. package/browser/artifacts/contracts/ArgonBuyAndTransfer.sol/ArgonBuyAndTransfer.json +439 -0
  3. package/browser/artifacts/contracts/ArgonToken.sol/ArgonToken.json +11 -11
  4. package/browser/artifacts/contracts/ArgonotToken.sol/ArgonotToken.json +11 -11
  5. package/browser/artifacts/contracts/MintingGateway.sol/MintingGateway.json +290 -16
  6. package/browser/artifacts/contracts/ProxyArtifacts.sol/ProxyAdmin.json +3 -3
  7. package/browser/artifacts/contracts/ProxyArtifacts.sol/TransparentUpgradeableProxy.json +4 -4
  8. package/browser/artifacts/contracts/StabilizationPoolHook.sol/StabilizationPoolHook.json +699 -0
  9. package/browser/artifacts/contracts/StabilizationPoolSubscriber.sol/StabilizationPoolSubscriber.json +187 -0
  10. package/browser/artifacts/contracts/UniswapV4PriceQuoter.sol/UniswapV4PriceQuoter.json +391 -0
  11. package/browser/index.d.ts +4730 -516
  12. package/browser/index.js +3458 -796
  13. package/browser/index.js.map +1 -1
  14. package/lib/artifacts/contracts/ArgonBuyAndTransfer.sol/ArgonBuyAndTransfer.json +439 -0
  15. package/lib/artifacts/contracts/ArgonToken.sol/ArgonToken.json +11 -11
  16. package/lib/artifacts/contracts/ArgonotToken.sol/ArgonotToken.json +11 -11
  17. package/lib/artifacts/contracts/MintingGateway.sol/MintingGateway.json +290 -16
  18. package/lib/artifacts/contracts/ProxyArtifacts.sol/ProxyAdmin.json +3 -3
  19. package/lib/artifacts/contracts/ProxyArtifacts.sol/TransparentUpgradeableProxy.json +4 -4
  20. package/lib/artifacts/contracts/StabilizationPoolHook.sol/StabilizationPoolHook.json +699 -0
  21. package/lib/artifacts/contracts/StabilizationPoolSubscriber.sol/StabilizationPoolSubscriber.json +187 -0
  22. package/lib/artifacts/contracts/UniswapV4PriceQuoter.sol/UniswapV4PriceQuoter.json +391 -0
  23. package/lib/index.cjs +3470 -803
  24. package/lib/index.cjs.map +1 -1
  25. package/lib/index.d.cts +4730 -516
  26. package/lib/index.d.ts +4730 -516
  27. package/lib/index.js +3464 -797
  28. package/lib/index.js.map +1 -1
  29. package/package.json +8 -7
  30. package/src/interfaces/augment-api-consts.ts +53 -0
  31. package/src/interfaces/augment-api-errors.ts +95 -0
  32. package/src/interfaces/augment-api-events.ts +119 -1
  33. package/src/interfaces/augment-api-query.ts +186 -4
  34. package/src/interfaces/augment-api-tx.ts +95 -3
  35. package/src/interfaces/lookup.ts +611 -271
  36. package/src/interfaces/registry.ts +50 -4
  37. package/src/interfaces/types-lookup.ts +654 -278
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@argonprotocol/mainchain",
3
- "version": "1.5.2-dev.5254a99c",
3
+ "version": "1.5.2-dev.5a6c09ac",
4
4
  "description": "A client for accessing the Argon mainchain apis.",
5
5
  "repository": {
6
6
  "type": "git",
@@ -14,16 +14,16 @@
14
14
  "homepage": "https://github.com/argonprotocol/mainchain#readme",
15
15
  "scripts": {
16
16
  "build": "yarn generate:defs && yarn generate:meta && node clean-build.js && yarn tsc",
17
- "generate:contract-declarations": "tsc -p tsconfig.contracts.json",
17
+ "generate:contract-declarations": "yarn workspace @argonprotocol/ethereum-contracts build && tsc -p tsconfig.contracts.json",
18
18
  "generate:defs": "polkadot-types-from-defs --endpoint metadata.json --input ./src/interfaces --package @argonprotocol/mainchain/interfaces",
19
19
  "generate:meta": "polkadot-types-from-chain --endpoint metadata.json --output ./src/interfaces --package @argonprotocol/mainchain/interfaces --strict",
20
20
  "test": "vitest --run --config vitest.config.ts",
21
- "tsc": "yarn workspace @argonprotocol/ethereum-contracts build && yarn generate:contract-declarations && tsup && yarn validate:package",
21
+ "tsc": "yarn generate:contract-declarations && tsup && yarn validate:package",
22
22
  "tsup": "yarn tsc",
23
23
  "validate:package": "tsx src/scripts/validatePackage.ts",
24
24
  "backfill:flexible-bond-metrics": "tsx src/scripts/backfillFlexibleBondMetrics.ts",
25
25
  "watch": "yarn generate:contract-declarations && tsup --watch",
26
- "typecheck": "tsc --noEmit -p tsconfig.test.json"
26
+ "typecheck": "yarn workspace @argonprotocol/ethereum-contracts build && tsc --noEmit -p tsconfig.test.json"
27
27
  },
28
28
  "files": [
29
29
  "lib/",
@@ -51,8 +51,9 @@
51
51
  }
52
52
  },
53
53
  "dependencies": {
54
- "@ethereumjs/block": "^10.1.1",
55
- "@ethereumjs/mpt": "^10.1.1",
54
+ "@ethereumjs/block": "^10.1.3",
55
+ "@ethereumjs/common": "^10.1.3",
56
+ "@ethereumjs/mpt": "^10.1.3",
56
57
  "@polkadot/api": "^17.0.1",
57
58
  "@polkadot/api-base": "^17.0.1",
58
59
  "@polkadot/keyring": "^14.0.3",
@@ -68,7 +69,7 @@
68
69
  },
69
70
  "devDependencies": {
70
71
  "@argonprotocol/ethereum-contracts": "workspace:*",
71
- "@argonprotocol/testing": "1.5.2-dev.5254a99c",
72
+ "@argonprotocol/testing": "1.5.2-dev.5a6c09ac",
72
73
  "@polkadot/typegen": "^17.0.1",
73
74
  "@substrate/ss58-registry": "^1.51.0",
74
75
  "@types/node": "^20",
@@ -540,6 +540,55 @@ declare module '@polkadot/api-base/types/consts' {
540
540
  **/
541
541
  proxyDepositFactor: u128 & AugmentedConst<ApiType>;
542
542
  };
543
+ stabilizerBuys: {
544
+ /**
545
+ * Fraction of min(available funding, matching basis) reserved once; configure 90%.
546
+ **/
547
+ auctionBudgetPercent: Percent & AugmentedConst<ApiType>;
548
+ /**
549
+ * In the open bucket, allow USDC observations up to ten ticks before the purchase.
550
+ **/
551
+ maxCurrentHourPriceAgeTicks: u64 & AugmentedConst<ApiType>;
552
+ /**
553
+ * Maximum hourly reference buckets retained; configure 720.
554
+ **/
555
+ maxHourlyPriceReferences: u32 & AugmentedConst<ApiType>;
556
+ /**
557
+ * Maximum work in each automatic stage per block: ranked bid decisions, then account
558
+ * payout attempts. Failures and empty-auction completion consume work; excess stays
559
+ * queued.
560
+ **/
561
+ maxPayoutsPerBlock: u32 & AugmentedConst<ApiType>;
562
+ /**
563
+ * Positive submissions per account and auction; four allows an initial bid and three
564
+ * revisions.
565
+ **/
566
+ maxPositiveBids: u8 & AugmentedConst<ApiType>;
567
+ /**
568
+ * Maximum mature principal buckets released in one account payout visit.
569
+ * This bounds work, without limiting the number of purchases an account can hold.
570
+ **/
571
+ maxPrincipalPayouts: u32 & AugmentedConst<ApiType>;
572
+ /**
573
+ * Most recent tick observations retained for exact ARGON targets; configure 360.
574
+ **/
575
+ maxRecentPriceTicks: u32 & AugmentedConst<ApiType>;
576
+ /**
577
+ * Tick width of each older reference bucket; configure 60.
578
+ **/
579
+ priceHistoryBucketTicks: u64 & AugmentedConst<ApiType>;
580
+ /**
581
+ * Ticks after bidding close, configured for 30 elapsed days on the network.
582
+ **/
583
+ rewardMaturityTicks: u64 & AugmentedConst<ApiType>;
584
+ };
585
+ stabilizerPools: {
586
+ /**
587
+ * Opening references retained in financial-day frames, including the checkpoint buffer.
588
+ * Zero disables history. Both production runtimes retain 30 frames plus a 3-frame buffer.
589
+ **/
590
+ maxFramePriceHistoryFrames: u32 & AugmentedConst<ApiType>;
591
+ };
543
592
  system: {
544
593
  /**
545
594
  * Maximum number of block number to block hash mappings to keep (oldest pruned first).
@@ -684,6 +733,10 @@ declare module '@polkadot/api-base/types/consts' {
684
733
  upstreamBitcoinTarget: u128 & AugmentedConst<ApiType>;
685
734
  upstreamBitcoinWeight: Permill & AugmentedConst<ApiType>;
686
735
  upstreamBondTarget: u128 & AugmentedConst<ApiType>;
736
+ /**
737
+ * Maximum share of the full bid pool paid for vault Bitcoin participation.
738
+ **/
739
+ vaultBitcoinRewardPercent: Permill & AugmentedConst<ApiType>;
687
740
  };
688
741
  txPause: {
689
742
  /**
@@ -803,6 +803,7 @@ declare module '@polkadot/api-base/types/errors' {
803
803
  ExecutionHeaderAnchorNotHistorical: AugmentedError<ApiType>;
804
804
  ExpectedFinalizedHeaderNotStored: AugmentedError<ApiType>;
805
805
  ForkDataHashTreeRootFailed: AugmentedError<ApiType>;
806
+ GloasForkAlreadyActive: AugmentedError<ApiType>;
806
807
  Halted: AugmentedError<ApiType>;
807
808
  HeaderHashTreeRootFailed: AugmentedError<ApiType>;
808
809
  InvalidBackfillHeaderRoot: AugmentedError<ApiType>;
@@ -811,6 +812,7 @@ declare module '@polkadot/api-base/types/errors' {
811
812
  * The gap between finalized headers is larger than the retained historical window.
812
813
  **/
813
814
  InvalidFinalizedHeaderGap: AugmentedError<ApiType>;
815
+ InvalidForkSchedule: AugmentedError<ApiType>;
814
816
  InvalidHeaderMerkleProof: AugmentedError<ApiType>;
815
817
  InvalidSyncCommitteeMerkleProof: AugmentedError<ApiType>;
816
818
  /**
@@ -1286,6 +1288,10 @@ declare module '@polkadot/api-base/types/errors' {
1286
1288
  * Ethereum prices must be non-zero and correspond to the submitted price-index tick.
1287
1289
  **/
1288
1290
  InvalidEthereumPrices: AugmentedError<ApiType>;
1291
+ /**
1292
+ * A supplied USDC observation must be positive and no later than the current tick.
1293
+ **/
1294
+ InvalidUsdcPrice: AugmentedError<ApiType>;
1289
1295
  /**
1290
1296
  * Change in argon price is too large
1291
1297
  **/
@@ -1337,6 +1343,95 @@ declare module '@polkadot/api-base/types/errors' {
1337
1343
  **/
1338
1344
  Unproxyable: AugmentedError<ApiType>;
1339
1345
  };
1346
+ stabilizerBuys: {
1347
+ /**
1348
+ * No auction exists for the supplied admission frame.
1349
+ **/
1350
+ AuctionNotFound: AugmentedError<ApiType>;
1351
+ /**
1352
+ * An auction scheduled for allocation lacks its reservation or maturity anchor.
1353
+ **/
1354
+ AuctionNotReady: AugmentedError<ApiType>;
1355
+ /**
1356
+ * The call is outside F+1 or the auction no longer accepts bids.
1357
+ **/
1358
+ BiddingClosed: AugmentedError<ApiType>;
1359
+ /**
1360
+ * Positive submissions are exhausted; zero may still opt out.
1361
+ **/
1362
+ BidLimitReached: AugmentedError<ApiType>;
1363
+ /**
1364
+ * A positive rate produces zero whole microgons against the matching basis.
1365
+ **/
1366
+ BidRoundsToZero: AugmentedError<ApiType>;
1367
+ /**
1368
+ * A positive bid repeats the account's current rate.
1369
+ **/
1370
+ BidUnchanged: AugmentedError<ApiType>;
1371
+ /**
1372
+ * The account has no purchase bucket for this auction.
1373
+ **/
1374
+ EntryNotFound: AugmentedError<ApiType>;
1375
+ /**
1376
+ * The scheduled account has no mature principal or committed reward to pay.
1377
+ **/
1378
+ PayoutNotReady: AugmentedError<ApiType>;
1379
+ };
1380
+ stabilizerPools: {
1381
+ /**
1382
+ * The three account witnesses do not contain identical execution-block proofs.
1383
+ **/
1384
+ InconsistentProofBlocks: AugmentedError<ApiType>;
1385
+ /**
1386
+ * A deployment address is zero or reused, or the pool key fails ordering or encoding
1387
+ * bounds.
1388
+ **/
1389
+ InvalidPool: AugmentedError<ApiType>;
1390
+ /**
1391
+ * The packed PoolId mismatches, ticks are invalid/misaligned, or liquidity exceeds
1392
+ * uint128.
1393
+ **/
1394
+ InvalidPosition: AugmentedError<ApiType>;
1395
+ /**
1396
+ * The Ethereum verifier is unavailable, or header ancestry/account/storage authentication
1397
+ * fails.
1398
+ **/
1399
+ InvalidProof: AugmentedError<ApiType>;
1400
+ /**
1401
+ * A witness has the wrong slot count or slot addresses for the requested NFT position.
1402
+ **/
1403
+ InvalidStorageSlots: AugmentedError<ApiType>;
1404
+ /**
1405
+ * The NFT's subscriber or subscription flag is invalid, or its permanent revision is
1406
+ * zero.
1407
+ **/
1408
+ InvalidSubscription: AugmentedError<ApiType>;
1409
+ /**
1410
+ * The signer does not match the beneficiary encoded in the subscription witness.
1411
+ **/
1412
+ NotBeneficiary: AugmentedError<ApiType>;
1413
+ /**
1414
+ * This PoolManager/PoolId pair already has an immutable registration.
1415
+ **/
1416
+ PoolAlreadyRegistered: AugmentedError<ApiType>;
1417
+ /**
1418
+ * No approved configuration exists for the supplied PoolManager/PoolId pair.
1419
+ **/
1420
+ PoolNotRegistered: AugmentedError<ApiType>;
1421
+ /**
1422
+ * Beneficiary, subscriber, pool, tick range, or liquidity changed without a revision
1423
+ * increase.
1424
+ **/
1425
+ PositionChangedWithoutRevision: AugmentedError<ApiType>;
1426
+ /**
1427
+ * The subscriber revision is lower than the NFT's last accepted revision.
1428
+ **/
1429
+ RevisionRegressed: AugmentedError<ApiType>;
1430
+ /**
1431
+ * Ethereum block height or time does not strictly advance past the stored checkpoint.
1432
+ **/
1433
+ StaleCheckpoint: AugmentedError<ApiType>;
1434
+ };
1340
1435
  sudo: {
1341
1436
  /**
1342
1437
  * Sender must be the Sudo account.
@@ -7,9 +7,11 @@ import type {} from '@polkadot/api-base/types/events';
7
7
  import type { ApiTypes, AugmentedEvent } from '@polkadot/api-base/types';
8
8
  import type {
9
9
  Bytes,
10
+ Compact,
10
11
  Null,
11
12
  Option,
12
13
  Result,
14
+ U256,
13
15
  U8aFixed,
14
16
  Vec,
15
17
  bool,
@@ -18,9 +20,10 @@ import type {
18
20
  u16,
19
21
  u32,
20
22
  u64,
23
+ u8,
21
24
  } from '@polkadot/types-codec';
22
25
  import type { ITuple } from '@polkadot/types-codec/types';
23
- import type { AccountId32, H160, H256, Percent } from '@polkadot/types/interfaces/runtime';
26
+ import type { AccountId32, H160, H256, Percent, Permill } from '@polkadot/types/interfaces/runtime';
24
27
  import type {
25
28
  ArgonNotaryAuditErrorVerifyError,
26
29
  ArgonPrimitivesBitcoinUtxoRef,
@@ -44,14 +47,21 @@ import type {
44
47
  PalletCrosschainTransferGatewayState,
45
48
  PalletCrosschainTransferGatewaySyncPause,
46
49
  PalletCrosschainTransferSourceChain,
50
+ PalletCrosschainTransferSwapPurchaseEvidence,
47
51
  PalletCrosschainTransferTransferToArgonActivity,
48
52
  PalletDomainsDomainRegistration,
49
53
  PalletEthereumVerifierBasicOperatingMode,
50
54
  PalletMintMintType,
51
55
  PalletMultisigTimepoint,
52
56
  PalletProxyDepositKind,
57
+ PalletStabilizerBuysIneligibleReason,
58
+ PalletStabilizerBuysUniswapPurchasePurchasePool,
59
+ PalletStabilizerPoolsCheckpointOutcome,
60
+ PalletStabilizerPoolsPoolConfig,
61
+ PalletStabilizerPoolsPositionCheckpoint,
53
62
  PalletTreasuryBondProgramId,
54
63
  PalletTreasuryBondReleaseReason,
64
+ PalletTreasuryRewardReserveBalances,
55
65
  SpConsensusGrandpaAppPublic,
56
66
  SpRuntimeDispatchError,
57
67
  } from '@polkadot/types/lookup';
@@ -902,6 +912,24 @@ declare module '@polkadot/api-base/types/events' {
902
912
  mintingAuthorityTip: u128;
903
913
  }
904
914
  >;
915
+ /**
916
+ * A Uniswap purchase was credited without operational transfer credit.
917
+ **/
918
+ TransferToArgonFromSwapSettled: AugmentedEvent<
919
+ ApiType,
920
+ [
921
+ sourceChain: PalletCrosschainTransferSourceChain,
922
+ transfer: PalletCrosschainTransferTransferToArgonActivity,
923
+ purchase: PalletCrosschainTransferSwapPurchaseEvidence,
924
+ purchaseTick: u64,
925
+ ],
926
+ {
927
+ sourceChain: PalletCrosschainTransferSourceChain;
928
+ transfer: PalletCrosschainTransferTransferToArgonActivity;
929
+ purchase: PalletCrosschainTransferSwapPurchaseEvidence;
930
+ purchaseTick: u64;
931
+ }
932
+ >;
905
933
  /**
906
934
  * A `TransferToArgonStarted` activity was proven and settled locally.
907
935
  **/
@@ -977,6 +1005,11 @@ declare module '@polkadot/api-base/types/events' {
977
1005
  [blockHash: H256, blockNumber: u64],
978
1006
  { blockHash: H256; blockNumber: u64 }
979
1007
  >;
1008
+ GloasForkScheduled: AugmentedEvent<
1009
+ ApiType,
1010
+ [version: U8aFixed, epoch: Compact<u64>],
1011
+ { version: U8aFixed; epoch: Compact<u64> }
1012
+ >;
980
1013
  /**
981
1014
  * Set OperatingMode
982
1015
  **/
@@ -1832,6 +1865,86 @@ declare module '@polkadot/api-base/types/events' {
1832
1865
  }
1833
1866
  >;
1834
1867
  };
1868
+ stabilizerBuys: {
1869
+ ApprovedPoolChanged: AugmentedEvent<
1870
+ ApiType,
1871
+ [pool: Option<PalletStabilizerBuysUniswapPurchasePurchasePool>],
1872
+ { pool: Option<PalletStabilizerBuysUniswapPurchasePurchasePool> }
1873
+ >;
1874
+ AuctionAllocationFailed: AugmentedEvent<
1875
+ ApiType,
1876
+ [admissionFrame: u64, error: SpRuntimeDispatchError],
1877
+ { admissionFrame: u64; error: SpRuntimeDispatchError }
1878
+ >;
1879
+ AuctionFundingFailed: AugmentedEvent<
1880
+ ApiType,
1881
+ [admissionFrame: u64, error: SpRuntimeDispatchError],
1882
+ { admissionFrame: u64; error: SpRuntimeDispatchError }
1883
+ >;
1884
+ AuctionOpened: AugmentedEvent<
1885
+ ApiType,
1886
+ [admissionFrame: u64, budget: u128],
1887
+ { admissionFrame: u64; budget: u128 }
1888
+ >;
1889
+ AuctionSettled: AugmentedEvent<
1890
+ ApiType,
1891
+ [admissionFrame: u64, awarded: u128, returned: u128],
1892
+ { admissionFrame: u64; awarded: u128; returned: u128 }
1893
+ >;
1894
+ BidSubmitted: AugmentedEvent<
1895
+ ApiType,
1896
+ [account: AccountId32, admissionFrame: u64, rewardRate: Percent, positiveBidCount: u8],
1897
+ { account: AccountId32; admissionFrame: u64; rewardRate: Percent; positiveBidCount: u8 }
1898
+ >;
1899
+ MatchingRateChanged: AugmentedEvent<ApiType, [rate: Permill], { rate: Permill }>;
1900
+ PayoutCompleted: AugmentedEvent<
1901
+ ApiType,
1902
+ [account: AccountId32, principal: u128, reward: u128],
1903
+ { account: AccountId32; principal: u128; reward: u128 }
1904
+ >;
1905
+ PayoutFailed: AugmentedEvent<
1906
+ ApiType,
1907
+ [account: AccountId32, error: SpRuntimeDispatchError],
1908
+ { account: AccountId32; error: SpRuntimeDispatchError }
1909
+ >;
1910
+ PurchaseIneligible: AugmentedEvent<
1911
+ ApiType,
1912
+ [account: AccountId32, purchaseTick: u64, reason: PalletStabilizerBuysIneligibleReason],
1913
+ { account: AccountId32; purchaseTick: u64; reason: PalletStabilizerBuysIneligibleReason }
1914
+ >;
1915
+ PurchaseRecorded: AugmentedEvent<
1916
+ ApiType,
1917
+ [account: AccountId32, admissionFrame: u64, principal: u128, matchingBasis: u128],
1918
+ { account: AccountId32; admissionFrame: u64; principal: u128; matchingBasis: u128 }
1919
+ >;
1920
+ RewardAwarded: AugmentedEvent<
1921
+ ApiType,
1922
+ [account: AccountId32, admissionFrame: u64, amount: u128, maturesAtTick: u64],
1923
+ { account: AccountId32; admissionFrame: u64; amount: u128; maturesAtTick: u64 }
1924
+ >;
1925
+ };
1926
+ stabilizerPools: {
1927
+ PoolRegistered: AugmentedEvent<
1928
+ ApiType,
1929
+ [poolManager: H160, poolId: H256, config: PalletStabilizerPoolsPoolConfig],
1930
+ { poolManager: H160; poolId: H256; config: PalletStabilizerPoolsPoolConfig }
1931
+ >;
1932
+ PositionCheckpointed: AugmentedEvent<
1933
+ ApiType,
1934
+ [
1935
+ positionManager: H160,
1936
+ tokenId: U256,
1937
+ checkpoint: PalletStabilizerPoolsPositionCheckpoint,
1938
+ outcome: PalletStabilizerPoolsCheckpointOutcome,
1939
+ ],
1940
+ {
1941
+ positionManager: H160;
1942
+ tokenId: U256;
1943
+ checkpoint: PalletStabilizerPoolsPositionCheckpoint;
1944
+ outcome: PalletStabilizerPoolsCheckpointOutcome;
1945
+ }
1946
+ >;
1947
+ };
1835
1948
  sudo: {
1836
1949
  /**
1837
1950
  * The sudo key has been updated.
@@ -2135,6 +2248,11 @@ declare module '@polkadot/api-base/types/events' {
2135
2248
  [targetBitcoinPercent: Percent, upstreamParticipationFactor: Percent],
2136
2249
  { targetBitcoinPercent: Percent; upstreamParticipationFactor: Percent }
2137
2250
  >;
2251
+ RewardReservesUpdated: AugmentedEvent<
2252
+ ApiType,
2253
+ [reserves: PalletTreasuryRewardReserveBalances],
2254
+ { reserves: PalletTreasuryRewardReserveBalances }
2255
+ >;
2138
2256
  };
2139
2257
  txPause: {
2140
2258
  /**
@@ -11,6 +11,7 @@ import type {
11
11
  Bytes,
12
12
  Null,
13
13
  Option,
14
+ U256,
14
15
  U8aFixed,
15
16
  Vec,
16
17
  bool,
@@ -21,10 +22,12 @@ import type {
21
22
  u8,
22
23
  } from '@polkadot/types-codec';
23
24
  import type { AnyNumber, ITuple } from '@polkadot/types-codec/types';
24
- import type { AccountId32, H160, H256, Percent } from '@polkadot/types/interfaces/runtime';
25
+ import type { AccountId32, H160, H256, Percent, Permill } from '@polkadot/types/interfaces/runtime';
25
26
  import type {
26
27
  ArgonNotaryAuditErrorVerifyError,
27
28
  ArgonPrimitivesAmountRankAmountRankKey,
29
+ ArgonPrimitivesAmountRankAscendingRankKeyAccountId32,
30
+ ArgonPrimitivesAmountRankAscendingRankKeyU64,
28
31
  ArgonPrimitivesBalanceChangeAccountOrigin,
29
32
  ArgonPrimitivesBitcoinBitcoinBlock,
30
33
  ArgonPrimitivesBitcoinBitcoinCosignScriptPubkey,
@@ -48,6 +51,7 @@ import type {
48
51
  ArgonPrimitivesNotaryNotaryNotebookKeyDetails,
49
52
  ArgonPrimitivesNotaryNotaryNotebookVoteDigestDetails,
50
53
  ArgonPrimitivesNotaryNotaryRecord,
54
+ ArgonPrimitivesPriceIndex,
51
55
  ArgonPrimitivesProvidersBlockSealerInfo,
52
56
  ArgonPrimitivesTickTicker,
53
57
  ArgonPrimitivesTreasuryNetworkPositionQuantities,
@@ -108,9 +112,15 @@ import type {
108
112
  PalletPriceIndexCpiMeasurementBucket,
109
113
  PalletPriceIndexEthereumPriceFrameAccumulator,
110
114
  PalletPriceIndexEthereumPriceIndex,
111
- PalletPriceIndexPriceIndex,
112
115
  PalletProxyAnnouncement,
113
116
  PalletProxyProxyDefinition,
117
+ PalletStabilizerBuysAccountBuys,
118
+ PalletStabilizerBuysAuction,
119
+ PalletStabilizerBuysBuyPayout,
120
+ PalletStabilizerBuysPriceHistoryHourlyPriceReference,
121
+ PalletStabilizerBuysUniswapPurchasePurchasePool,
122
+ PalletStabilizerPoolsPoolConfig,
123
+ PalletStabilizerPoolsPositionCheckpoint,
114
124
  PalletTransactionPaymentReleases,
115
125
  PalletTreasuryBondLot,
116
126
  PalletTreasuryBondLotSummary,
@@ -118,6 +128,7 @@ import type {
118
128
  PalletTreasuryFrameVaultBitcoin,
119
129
  PalletTreasuryFrameVaultCapital,
120
130
  PalletTreasuryPositionsPosition,
131
+ PalletTreasuryRewardReserveBalances,
121
132
  PalletTreasuryVaultBondState,
122
133
  PalletVaultsVaultFrameRevenue,
123
134
  SpConsensusGrandpaAppPublic,
@@ -910,6 +921,15 @@ declare module '@polkadot/api-base/types/storage' {
910
921
  () => Observable<PalletEthereumVerifierSyncCommitteePrepared>,
911
922
  []
912
923
  >;
924
+ /**
925
+ * Number of retained beacon roots sharing an execution anchor. Gloas EMPTY payloads can
926
+ * leave the parent execution hash unchanged across multiple finalized beacon blocks.
927
+ **/
928
+ executionHeaderAnchorReferences: AugmentedQuery<
929
+ ApiType,
930
+ (arg: H256 | string | Uint8Array) => Observable<u32>,
931
+ [H256]
932
+ >;
913
933
  /**
914
934
  * Retained execution-layer header anchors by execution block hash.
915
935
  **/
@@ -1545,7 +1565,7 @@ declare module '@polkadot/api-base/types/storage' {
1545
1565
  /**
1546
1566
  * Stores the active price index
1547
1567
  **/
1548
- current: AugmentedQuery<ApiType, () => Observable<Option<PalletPriceIndexPriceIndex>>, []>;
1568
+ current: AugmentedQuery<ApiType, () => Observable<Option<ArgonPrimitivesPriceIndex>>, []>;
1549
1569
  /**
1550
1570
  * Stores the latest submitted Ethereum pricing.
1551
1571
  **/
@@ -1597,7 +1617,7 @@ declare module '@polkadot/api-base/types/storage' {
1597
1617
  /**
1598
1618
  * Stores the last valid price index
1599
1619
  **/
1600
- lastValid: AugmentedQuery<ApiType, () => Observable<Option<PalletPriceIndexPriceIndex>>, []>;
1620
+ lastValid: AugmentedQuery<ApiType, () => Observable<Option<ArgonPrimitivesPriceIndex>>, []>;
1601
1621
  /**
1602
1622
  * The price index operator account
1603
1623
  **/
@@ -1626,6 +1646,156 @@ declare module '@polkadot/api-base/types/storage' {
1626
1646
  [AccountId32]
1627
1647
  >;
1628
1648
  };
1649
+ stabilizerBuys: {
1650
+ /**
1651
+ * Execution venue eligible for purchase rewards. Unset until governance selects a pool.
1652
+ **/
1653
+ approvedPool: AugmentedQuery<
1654
+ ApiType,
1655
+ () => Observable<Option<PalletStabilizerBuysUniswapPurchasePurchasePool>>,
1656
+ []
1657
+ >;
1658
+ /**
1659
+ * Auction policy and funding keyed by admission frame F; bidding takes place during F+1.
1660
+ **/
1661
+ auctions: AugmentedQuery<
1662
+ ApiType,
1663
+ (arg: u64 | AnyNumber | Uint8Array) => Observable<Option<PalletStabilizerBuysAuction>>,
1664
+ [u64]
1665
+ >;
1666
+ /**
1667
+ * Positive bids ordered by rate ascending, then account ascending. Values are frozen matching
1668
+ * bases in microgons, allowing settlement after the account's principal bucket is gone.
1669
+ **/
1670
+ bidsByAuction: AugmentedQuery<
1671
+ ApiType,
1672
+ (
1673
+ arg1: u64 | AnyNumber | Uint8Array,
1674
+ arg2:
1675
+ | ArgonPrimitivesAmountRankAscendingRankKeyAccountId32
1676
+ | { ascendingRank?: any; orderedId?: any }
1677
+ | string
1678
+ | Uint8Array,
1679
+ ) => Observable<Option<u128>>,
1680
+ [u64, ArgonPrimitivesAmountRankAscendingRankKeyAccountId32]
1681
+ >;
1682
+ /**
1683
+ * Scheduled rewards and the account's single payout queue entry.
1684
+ **/
1685
+ buysByAccount: AugmentedQuery<
1686
+ ApiType,
1687
+ (arg: AccountId32 | string | Uint8Array) => Observable<PalletStabilizerBuysAccountBuys>,
1688
+ [AccountId32]
1689
+ >;
1690
+ /**
1691
+ * Counter for the related counted storage map
1692
+ **/
1693
+ counterForHourlyPriceReferences: AugmentedQuery<ApiType, () => Observable<u32>, []>;
1694
+ /**
1695
+ * Counter for the related counted storage map
1696
+ **/
1697
+ counterForRecentPriceIndices: AugmentedQuery<ApiType, () => Observable<u32>, []>;
1698
+ /**
1699
+ * Hourly references keyed by the bucket-start tick in the same oldest-first order.
1700
+ **/
1701
+ hourlyPriceReferences: AugmentedQuery<
1702
+ ApiType,
1703
+ (
1704
+ arg: U8aFixed | string | Uint8Array,
1705
+ ) => Observable<Option<PalletStabilizerBuysPriceHistoryHourlyPriceReference>>,
1706
+ [U8aFixed]
1707
+ >;
1708
+ /**
1709
+ * Matching fraction for new auctions; existing auctions retain their captured policy.
1710
+ **/
1711
+ matchingRate: AugmentedQuery<ApiType, () => Observable<Permill>, []>;
1712
+ /**
1713
+ * Funded auctions awaiting automatic reward allocation, ordered by maturity tick and frame.
1714
+ * A failed allocation moves only its retry tick; the auction retains its original maturity.
1715
+ **/
1716
+ maturingAuctions: AugmentedQuery<
1717
+ ApiType,
1718
+ (
1719
+ arg:
1720
+ | ArgonPrimitivesAmountRankAscendingRankKeyU64
1721
+ | { ascendingRank?: any; orderedId?: any }
1722
+ | string
1723
+ | Uint8Array,
1724
+ ) => Observable<Option<Null>>,
1725
+ [ArgonPrimitivesAmountRankAscendingRankKeyU64]
1726
+ >;
1727
+ /**
1728
+ * One scheduled visit per account, ordered by tick then account. Purchase buckets and the
1729
+ * reward record retain unpaid funds while this index selects bounded work.
1730
+ **/
1731
+ payoutQueue: AugmentedQuery<
1732
+ ApiType,
1733
+ (
1734
+ arg:
1735
+ | ArgonPrimitivesAmountRankAscendingRankKeyAccountId32
1736
+ | { ascendingRank?: any; orderedId?: any }
1737
+ | string
1738
+ | Uint8Array,
1739
+ ) => Observable<Option<Null>>,
1740
+ [ArgonPrimitivesAmountRankAscendingRankKeyAccountId32]
1741
+ >;
1742
+ /**
1743
+ * One principal bucket per account and admission frame, retained until release succeeds.
1744
+ * Ordered frame bytes let payout visits select the oldest buckets with bounded work.
1745
+ **/
1746
+ purchasesByAccount: AugmentedQuery<
1747
+ ApiType,
1748
+ (
1749
+ arg1: AccountId32 | string | Uint8Array,
1750
+ arg2: U8aFixed | string | Uint8Array,
1751
+ ) => Observable<Option<PalletStabilizerBuysBuyPayout>>,
1752
+ [AccountId32, U8aFixed]
1753
+ >;
1754
+ /**
1755
+ * Exact observations keyed by the oracle tick in big-endian order, for oldest-first pruning.
1756
+ **/
1757
+ recentPriceIndices: AugmentedQuery<
1758
+ ApiType,
1759
+ (arg: U8aFixed | string | Uint8Array) => Observable<Option<ArgonPrimitivesPriceIndex>>,
1760
+ [U8aFixed]
1761
+ >;
1762
+ };
1763
+ stabilizerPools: {
1764
+ /**
1765
+ * First current-tick price index accepted in each frame, including absent pool observations.
1766
+ * This is an oracle opening reference, not an exact historical Ethereum boundary proof.
1767
+ * Later indices cannot revalue it; frames without an observation have no entry. A new opening
1768
+ * reference prunes frames outside the configured window, including across oracle gaps.
1769
+ **/
1770
+ frameStartPriceIndices: AugmentedQuery<
1771
+ ApiType,
1772
+ () => Observable<BTreeMap<u64, ArgonPrimitivesPriceIndex>>,
1773
+ []
1774
+ >;
1775
+ /**
1776
+ * Approved deployments on the Ethereum network authenticated by EthereumVerifier.
1777
+ * Configuration is immutable once registered, preserving checkpoint identity and layout.
1778
+ **/
1779
+ pools: AugmentedQuery<
1780
+ ApiType,
1781
+ (
1782
+ arg1: H160 | string | Uint8Array,
1783
+ arg2: H256 | string | Uint8Array,
1784
+ ) => Observable<Option<PalletStabilizerPoolsPoolConfig>>,
1785
+ [H160, H256]
1786
+ >;
1787
+ /**
1788
+ * Last accepted checkpoint for an NFT. Keep its source-block watermark across re-enrollment.
1789
+ **/
1790
+ positionCheckpoints: AugmentedQuery<
1791
+ ApiType,
1792
+ (
1793
+ arg1: H160 | string | Uint8Array,
1794
+ arg2: U256 | AnyNumber | Uint8Array,
1795
+ ) => Observable<Option<PalletStabilizerPoolsPositionCheckpoint>>,
1796
+ [H160, U256]
1797
+ >;
1798
+ };
1629
1799
  sudo: {
1630
1800
  /**
1631
1801
  * The `AccountId` of the sudo key.
@@ -1918,6 +2088,10 @@ declare module '@polkadot/api-base/types/storage' {
1918
2088
  * The next bond lot id.
1919
2089
  **/
1920
2090
  nextBondLotId: AugmentedQuery<ApiType, () => Observable<u64>, []>;
2091
+ /**
2092
+ * Awarded purchase rewards awaiting issuance. Auctions own their unallocated reservations.
2093
+ **/
2094
+ outstandingPurchaseRewards: AugmentedQuery<ApiType, () => Observable<u128>, []>;
1921
2095
  /**
1922
2096
  * The oldest frame that still has bond lots to retry releasing.
1923
2097
  **/
@@ -1930,6 +2104,14 @@ declare module '@polkadot/api-base/types/storage' {
1930
2104
  (arg: u64 | AnyNumber | Uint8Array) => Observable<Vec<u64>>,
1931
2105
  [u64]
1932
2106
  >;
2107
+ /**
2108
+ * ARGON removed from circulation and available for future issuance as rewards.
2109
+ **/
2110
+ rewardReserves: AugmentedQuery<
2111
+ ApiType,
2112
+ () => Observable<PalletTreasuryRewardReserveBalances>,
2113
+ []
2114
+ >;
1933
2115
  /**
1934
2116
  * Configurable percent of maximum Bitcoin-mintable Argons targeted by the network.
1935
2117
  **/