@argonprotocol/mainchain 1.5.2-dev.862caf8c → 1.5.2-dev.96d18bee

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 (36) hide show
  1. package/browser/artifacts/contracts/ArgonBuyAndTransfer.sol/ArgonBuyAndTransfer.json +185 -51
  2. package/browser/artifacts/contracts/ArgonToken.sol/ArgonToken.json +2 -2
  3. package/browser/artifacts/contracts/ArgonotToken.sol/ArgonotToken.json +2 -2
  4. package/browser/artifacts/contracts/MintingGateway.sol/MintingGateway.json +61 -23
  5. package/browser/artifacts/contracts/ProxyArtifacts.sol/ProxyAdmin.json +1 -1
  6. package/browser/artifacts/contracts/ProxyArtifacts.sol/TransparentUpgradeableProxy.json +1 -1
  7. package/browser/artifacts/contracts/StabilizationPoolHook.sol/StabilizationPoolHook.json +6 -6
  8. package/browser/artifacts/contracts/StabilizationPoolSubscriber.sol/StabilizationPoolSubscriber.json +2 -2
  9. package/browser/artifacts/contracts/UniswapV4PriceQuoter.sol/UniswapV4PriceQuoter.json +1 -1
  10. package/browser/index.d.ts +1619 -534
  11. package/browser/index.js +399 -139
  12. package/browser/index.js.map +1 -1
  13. package/lib/artifacts/contracts/ArgonBuyAndTransfer.sol/ArgonBuyAndTransfer.json +185 -51
  14. package/lib/artifacts/contracts/ArgonToken.sol/ArgonToken.json +2 -2
  15. package/lib/artifacts/contracts/ArgonotToken.sol/ArgonotToken.json +2 -2
  16. package/lib/artifacts/contracts/MintingGateway.sol/MintingGateway.json +61 -23
  17. package/lib/artifacts/contracts/ProxyArtifacts.sol/ProxyAdmin.json +1 -1
  18. package/lib/artifacts/contracts/ProxyArtifacts.sol/TransparentUpgradeableProxy.json +1 -1
  19. package/lib/artifacts/contracts/StabilizationPoolHook.sol/StabilizationPoolHook.json +6 -6
  20. package/lib/artifacts/contracts/StabilizationPoolSubscriber.sol/StabilizationPoolSubscriber.json +2 -2
  21. package/lib/artifacts/contracts/UniswapV4PriceQuoter.sol/UniswapV4PriceQuoter.json +1 -1
  22. package/lib/index.cjs +399 -138
  23. package/lib/index.cjs.map +1 -1
  24. package/lib/index.d.cts +1619 -534
  25. package/lib/index.d.ts +1619 -534
  26. package/lib/index.js +403 -142
  27. package/lib/index.js.map +1 -1
  28. package/package.json +2 -2
  29. package/src/interfaces/augment-api-consts.ts +44 -13
  30. package/src/interfaces/augment-api-errors.ts +140 -8
  31. package/src/interfaces/augment-api-events.ts +172 -56
  32. package/src/interfaces/augment-api-query.ts +247 -90
  33. package/src/interfaces/augment-api-tx.ts +175 -94
  34. package/src/interfaces/lookup.ts +604 -330
  35. package/src/interfaces/registry.ts +46 -10
  36. package/src/interfaces/types-lookup.ts +668 -342
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@argonprotocol/mainchain",
3
- "version": "1.5.2-dev.862caf8c",
3
+ "version": "1.5.2-dev.96d18bee",
4
4
  "description": "A client for accessing the Argon mainchain apis.",
5
5
  "repository": {
6
6
  "type": "git",
@@ -69,7 +69,7 @@
69
69
  },
70
70
  "devDependencies": {
71
71
  "@argonprotocol/ethereum-contracts": "workspace:*",
72
- "@argonprotocol/testing": "1.5.2-dev.862caf8c",
72
+ "@argonprotocol/testing": "1.5.2-dev.96d18bee",
73
73
  "@polkadot/typegen": "^17.0.1",
74
74
  "@substrate/ss58-registry": "^1.51.0",
75
75
  "@types/node": "^20",
@@ -51,14 +51,26 @@ declare module '@polkadot/api-base/types/consts' {
51
51
  maxReserves: u32 & AugmentedConst<ApiType>;
52
52
  };
53
53
  bitcoinFissions: {
54
+ /**
55
+ * Fissions per Liquid covered by repayment benchmarks and checked by try-state.
56
+ **/
57
+ maxExpectedFissionsPerLiquid: u32 & AugmentedConst<ApiType>;
54
58
  /**
55
59
  * Maximum number of active Fissions that may allocate satoshis from one Lock.
56
60
  **/
57
61
  maxFissionsPerLock: u32 & AugmentedConst<ApiType>;
62
+ /**
63
+ * Maximum older frame records pruned in one block after gateway sync catches up.
64
+ **/
65
+ maxRValueHistoryPrunesPerBlock: u32 & AugmentedConst<ApiType>;
58
66
  /**
59
67
  * Minimum percentage change required to ratchet a Fission.
60
68
  **/
61
69
  minimumRatchetPercent: Percent & AugmentedConst<ApiType>;
70
+ /**
71
+ * Number of recent frame high-water marks retained after their source interval has synced.
72
+ **/
73
+ rValueHistoryFrames: u32 & AugmentedConst<ApiType>;
62
74
  };
63
75
  bitcoinLocks: {
64
76
  /**
@@ -442,6 +454,11 @@ declare module '@polkadot/api-base/types/consts' {
442
454
  * Minimum vault securitization required to become operational.
443
455
  **/
444
456
  operationalMinimumVaultSecuritization: u128 & AugmentedConst<ApiType>;
457
+ /**
458
+ * Required operational registration signing contract. Clients must require version 2
459
+ * before signing; older clients must upgrade rather than reuse ownership-only proofs.
460
+ **/
461
+ registrationProofVersion: u8 & AugmentedConst<ApiType>;
445
462
  };
446
463
  ownership: {
447
464
  /**
@@ -548,13 +565,18 @@ declare module '@polkadot/api-base/types/consts' {
548
565
  **/
549
566
  auctionInclusionPercent: Percent & AugmentedConst<ApiType>;
550
567
  /**
551
- * In the open bucket, allow USDC observations up to ten ticks before the purchase.
568
+ * Additional burn-funded reward before applying the purchase's auction result.
552
569
  **/
553
- maxCurrentHourPriceAgeTicks: u64 & AugmentedConst<ApiType>;
570
+ liquidRepaymentRewardPercent: Percent & AugmentedConst<ApiType>;
554
571
  /**
555
- * Maximum hourly reference buckets retained; configure 720.
572
+ * Maximum account/frame purchase buckets visited in one account payout.
573
+ * This bounds work, without limiting the number of purchases an account can hold.
574
+ **/
575
+ maxFramesPerPayout: u32 & AugmentedConst<ApiType>;
576
+ /**
577
+ * Maximum Liquid repayments attempted across all account payouts in one block.
556
578
  **/
557
- maxHourlyPriceReferences: u32 & AugmentedConst<ApiType>;
579
+ maxLiquidRepaysPerBlock: u32 & AugmentedConst<ApiType>;
558
580
  /**
559
581
  * Maximum work in each automatic stage per block: ranked bid decisions, then account
560
582
  * payout attempts. Failures and empty-auction completion consume work; excess stays
@@ -567,22 +589,21 @@ declare module '@polkadot/api-base/types/consts' {
567
589
  **/
568
590
  maxPositiveBids: u8 & AugmentedConst<ApiType>;
569
591
  /**
570
- * Maximum mature principal buckets released in one account payout visit.
571
- * This bounds work, without limiting the number of purchases an account can hold.
592
+ * Maximum observation age at purchase time; also bounds historical lookup reads.
572
593
  **/
573
- maxPrincipalPayouts: u32 & AugmentedConst<ApiType>;
594
+ maxPriceAgeTicks: u64 & AugmentedConst<ApiType>;
574
595
  /**
575
- * Most recent tick observations retained for exact ARGON targets; configure 360.
596
+ * Maximum obsolete price entries removed per block after gateway sync advances.
576
597
  **/
577
- maxRecentPriceTicks: u32 & AugmentedConst<ApiType>;
598
+ maxPriceHistoryPrunesPerBlock: u32 & AugmentedConst<ApiType>;
578
599
  /**
579
- * Tick width of each older reference bucket; configure 60.
600
+ * Maximum frame visits per repayment attempt; a partial frame visit also reads one tick.
580
601
  **/
581
- priceHistoryBucketTicks: u64 & AugmentedConst<ApiType>;
602
+ maxPriceWindowSteps: u32 & AugmentedConst<ApiType>;
582
603
  /**
583
- * Ticks after bidding close, configured for 30 elapsed days on the network.
604
+ * Total mining-frame hold from admission, including the bidding window.
584
605
  **/
585
- rewardMaturityTicks: u64 & AugmentedConst<ApiType>;
606
+ purchaseHoldFrames: u64 & AugmentedConst<ApiType>;
586
607
  };
587
608
  stabilizerPools: {
588
609
  /**
@@ -680,6 +701,16 @@ declare module '@polkadot/api-base/types/consts' {
680
701
  * The maximum percent of ownership-token circulation that can be bonded.
681
702
  **/
682
703
  maxArgonotBondedPercentOfCirculation: Percent & AugmentedConst<ApiType>;
704
+ /**
705
+ * Maximum accounts whose queued bond collateral is attempted in one block.
706
+ **/
707
+ maxBondCollateralSettlementsPerBlock: u32 & AugmentedConst<ApiType>;
708
+ /**
709
+ * Owner bond/stake lot count assumed by scan benchmarks and checked by try_state.
710
+ * Includes lots awaiting release. Purchases remain unrestricted and scans are not
711
+ * truncated.
712
+ **/
713
+ maxExpectedBondLotsPerAccount: u32 & AugmentedConst<ApiType>;
683
714
  /**
684
715
  * The maximum number of bond lots whose release delay may mature in a single frame.
685
716
  **/
@@ -10,6 +10,96 @@ export type __AugmentedError<ApiType extends ApiTypes> = AugmentedError<ApiType>
10
10
 
11
11
  declare module '@polkadot/api-base/types/errors' {
12
12
  interface AugmentedErrors<ApiType extends ApiTypes> {
13
+ accountSecurity: {
14
+ /**
15
+ * Initial enrollment cannot overwrite an existing policy.
16
+ **/
17
+ AlreadyRegistered: AugmentedError<ApiType>;
18
+ /**
19
+ * The main account or a required policy/recovery/acceptance signature is missing.
20
+ **/
21
+ ApprovalRequired: AugmentedError<ApiType>;
22
+ /**
23
+ * Nested depth, call count, or a native multisig's signatory count exceeds its limit.
24
+ **/
25
+ CallLimitExceeded: AugmentedError<ApiType>;
26
+ /**
27
+ * Authorization nonces cannot wrap or be reused.
28
+ **/
29
+ CounterExhausted: AugmentedError<ApiType>;
30
+ /**
31
+ * One account supplied more than one proof.
32
+ **/
33
+ DuplicateApproval: AugmentedError<ApiType>;
34
+ /**
35
+ * Linking would discard a participant's policy or backup authority.
36
+ **/
37
+ IncompatibleAccountProtection: AugmentedError<ApiType>;
38
+ /**
39
+ * Only recovery-origin management may be submitted through native wrappers.
40
+ **/
41
+ IndirectAuthorization: AugmentedError<ApiType>;
42
+ /**
43
+ * The approval expired or exceeds the allowed future lifetime.
44
+ **/
45
+ InvalidExpiry: AugmentedError<ApiType>;
46
+ /**
47
+ * The supplied nonce is not the group's next unused authorization nonce.
48
+ **/
49
+ InvalidNonce: AugmentedError<ApiType>;
50
+ /**
51
+ * A threshold is invalid or signers are empty, duplicated or not sorted.
52
+ **/
53
+ InvalidPolicy: AugmentedError<ApiType>;
54
+ /**
55
+ * A proxy origin or transfer destination could not be resolved to an account.
56
+ **/
57
+ InvalidProxy: AugmentedError<ApiType>;
58
+ /**
59
+ * A proof does not verify against its account and the exact canonical call payload.
60
+ **/
61
+ InvalidSignature: AugmentedError<ApiType>;
62
+ /**
63
+ * Native wallet signing context could not be constructed for this security call.
64
+ **/
65
+ InvalidSigningPayload: AugmentedError<ApiType>;
66
+ /**
67
+ * Signing roles overlap the protected group or recovery overlaps a policy signer.
68
+ **/
69
+ KeysNotIndependent: AugmentedError<ApiType>;
70
+ /**
71
+ * Only a group's default account may manage its configuration.
72
+ **/
73
+ NotDefaultAccount: AugmentedError<ApiType>;
74
+ /**
75
+ * The default account has not enrolled protection.
76
+ **/
77
+ NotRegistered: AugmentedError<ApiType>;
78
+ /**
79
+ * A delayed replacement is already pending; cancel it before proposing another.
80
+ **/
81
+ PolicyUpdatePending: AugmentedError<ApiType>;
82
+ /**
83
+ * The current tick has not reached the pending replacement's execution tick.
84
+ **/
85
+ RecoveryDelayActive: AugmentedError<ApiType>;
86
+ /**
87
+ * The account group or current policy differs from the signed authorization.
88
+ **/
89
+ StalePolicy: AugmentedError<ApiType>;
90
+ /**
91
+ * Adding the configured delay to the current tick would overflow.
92
+ **/
93
+ TickOverflow: AugmentedError<ApiType>;
94
+ /**
95
+ * No pending replacement exists with this proposal's consumed authorization nonce.
96
+ **/
97
+ UnknownPolicyUpdate: AugmentedError<ApiType>;
98
+ /**
99
+ * Pre-dispatch state cannot safely authorize the nested call combination.
100
+ **/
101
+ UnsupportedComposition: AugmentedError<ApiType>;
102
+ };
13
103
  balances: {
14
104
  /**
15
105
  * Beneficiary account must pre-exist.
@@ -105,6 +195,22 @@ declare module '@polkadot/api-base/types/errors' {
105
195
  * The fee coupon is invalid, expired, or already consumed.
106
196
  **/
107
197
  InvalidFeeCoupon: AugmentedError<ApiType>;
198
+ /**
199
+ * Zero is reserved for the absence of a Liquid and cannot identify a new allocation.
200
+ **/
201
+ InvalidLiquidId: AugmentedError<ApiType>;
202
+ /**
203
+ * Fissions can join an existing Liquid only during its original creation tick.
204
+ **/
205
+ LiquidCreationWindowClosed: AugmentedError<ApiType>;
206
+ /**
207
+ * This owner has no active Fissions in the selected Liquid.
208
+ **/
209
+ LiquidNotFound: AugmentedError<ApiType>;
210
+ /**
211
+ * This owner's Liquid has unsettled repayment purchases, so it cannot close or ratchet.
212
+ **/
213
+ LiquidRepaymentPending: AugmentedError<ApiType>;
108
214
  /**
109
215
  * The requested source Lock does not exist.
110
216
  **/
@@ -141,6 +247,18 @@ declare module '@polkadot/api-base/types/errors' {
141
247
  * The Fission's ratchet counter cannot be incremented.
142
248
  **/
143
249
  RatchetNumberOverflow: AugmentedError<ApiType>;
250
+ /**
251
+ * The actual burn exceeds the remaining purchase budget.
252
+ **/
253
+ RepaymentBudgetExceeded: AugmentedError<ApiType>;
254
+ /**
255
+ * The repayment requests more satoshis than the Fission currently allocates.
256
+ **/
257
+ RepaymentExceedsFission: AugmentedError<ApiType>;
258
+ /**
259
+ * A repayment must return at least one satoshi to its source Lock.
260
+ **/
261
+ RepaymentHasNoSatoshis: AugmentedError<ApiType>;
144
262
  /**
145
263
  * The Vault could not upgrade the guarantee assigned to this Fission.
146
264
  **/
@@ -613,7 +731,7 @@ declare module '@polkadot/api-base/types/errors' {
613
731
  **/
614
732
  InvalidTransferCollateralUpdate: AugmentedError<ApiType>;
615
733
  /**
616
- * The transfer-out amount must be nonzero.
734
+ * The transfer-out amount is below the selected currency's minimum account balance.
617
735
  **/
618
736
  InvalidTransferOutAmount: AugmentedError<ApiType>;
619
737
  /**
@@ -809,7 +927,7 @@ declare module '@polkadot/api-base/types/errors' {
809
927
  InvalidBackfillHeaderRoot: AugmentedError<ApiType>;
810
928
  InvalidExecutionHeaderProof: AugmentedError<ApiType>;
811
929
  /**
812
- * The gap between finalized headers is larger than the retained historical window.
930
+ * Reserved error index; finalized updates are now bounded by authenticated committees.
813
931
  **/
814
932
  InvalidFinalizedHeaderGap: AugmentedError<ApiType>;
815
933
  InvalidForkSchedule: AugmentedError<ApiType>;
@@ -912,7 +1030,7 @@ declare module '@polkadot/api-base/types/errors' {
912
1030
  **/
913
1031
  BidAlreadyRevealed: AugmentedError<ApiType>;
914
1032
  /**
915
- * The mining bid cannot be reduced
1033
+ * Paid bids cannot decrease; public-only replacements must exceed the standing maximum.
916
1034
  **/
917
1035
  BidCannotBeReduced: AugmentedError<ApiType>;
918
1036
  /**
@@ -928,7 +1046,7 @@ declare module '@polkadot/api-base/types/errors' {
928
1046
  **/
929
1047
  CannotRegisterOverlappingSessions: AugmentedError<ApiType>;
930
1048
  /**
931
- * The miner already has a pending bid awaiting settlement.
1049
+ * The miner already has a submission awaiting clearing or maximum disclosure.
932
1050
  **/
933
1051
  DuplicateBidCommitment: AugmentedError<ApiType>;
934
1052
  /**
@@ -959,6 +1077,10 @@ declare module '@polkadot/api-base/types/errors' {
959
1077
  * The miner has no pending bid with a committed maximum to reveal.
960
1078
  **/
961
1079
  MissingBidCommitment: AugmentedError<ApiType>;
1080
+ /**
1081
+ * The miner has no settled bid with a standing maximum in the upcoming auction.
1082
+ **/
1083
+ MissingStandingBid: AugmentedError<ApiType>;
962
1084
  /**
963
1085
  * Mining slot bidding currently requires a prior operational-account upgrade.
964
1086
  **/
@@ -975,6 +1097,10 @@ declare module '@polkadot/api-base/types/errors' {
975
1097
  * This block has reached the maximum number of pending bid submissions.
976
1098
  **/
977
1099
  TooManyBidCommitments: AugmentedError<ApiType>;
1100
+ /**
1101
+ * The disclosure queue already contains every commitment allowed in the reveal window.
1102
+ **/
1103
+ TooManyBidReveals: AugmentedError<ApiType>;
978
1104
  /**
979
1105
  * The cohort registration overflowed
980
1106
  **/
@@ -1180,6 +1306,11 @@ declare module '@polkadot/api-base/types/errors' {
1180
1306
  * alphanumeric.
1181
1307
  **/
1182
1308
  InvalidName: AugmentedError<ApiType>;
1309
+ /**
1310
+ * The operational signature does not authorize this registration on this chain.
1311
+ * Clients using ownership-only proofs must upgrade to registration proof version 2.
1312
+ **/
1313
+ InvalidRegistrationProof: AugmentedError<ApiType>;
1183
1314
  /**
1184
1315
  * The caller is not one of the accounts included in the registration.
1185
1316
  **/
@@ -1349,7 +1480,7 @@ declare module '@polkadot/api-base/types/errors' {
1349
1480
  **/
1350
1481
  AuctionNotFound: AugmentedError<ApiType>;
1351
1482
  /**
1352
- * An auction scheduled for allocation lacks its reservation or maturity anchor.
1483
+ * Allocation was requested before the auction's Treasury budget was finalized.
1353
1484
  **/
1354
1485
  AuctionNotReady: AugmentedError<ApiType>;
1355
1486
  /**
@@ -1373,7 +1504,8 @@ declare module '@polkadot/api-base/types/errors' {
1373
1504
  **/
1374
1505
  EntryNotFound: AugmentedError<ApiType>;
1375
1506
  /**
1376
- * The scheduled account has no mature principal or committed reward to pay.
1507
+ * A repayment hold has not matured, its price window is incomplete, or its auction
1508
+ * result is not available yet.
1377
1509
  **/
1378
1510
  PayoutNotReady: AugmentedError<ApiType>;
1379
1511
  };
@@ -1483,8 +1615,8 @@ declare module '@polkadot/api-base/types/errors' {
1483
1615
  ticks: {};
1484
1616
  treasury: {
1485
1617
  /**
1486
- * Liquidating this bond lot would take the account below its crosschain-encumbered
1487
- * treasury backing.
1618
+ * A reservation or liquidation would leave Treasury backing uncovered, or queued
1619
+ * settlement exceeds the account's remaining encumbrance.
1488
1620
  **/
1489
1621
  ActiveBondAmountBelowEncumberedBacking: AugmentedError<ApiType>;
1490
1622
  /**