@bench.games/opportunity-markets 0.3.2 → 0.3.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/browser/index.js +1369 -1037
- package/dist/index.cjs +1347 -1016
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +243 -75
- package/dist/index.d.ts +243 -75
- package/dist/index.js +1369 -1037
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
package/dist/index.cjs
CHANGED
|
@@ -38,9 +38,11 @@ __export(index_exports, {
|
|
|
38
38
|
ARCIUM_SIGNER_ACCOUNT_DISCRIMINATOR: () => ARCIUM_SIGNER_ACCOUNT_DISCRIMINATOR,
|
|
39
39
|
CLAIM_CREATOR_FEES_DISCRIMINATOR: () => CLAIM_CREATOR_FEES_DISCRIMINATOR,
|
|
40
40
|
CLAIM_FEES_DISCRIMINATOR: () => CLAIM_FEES_DISCRIMINATOR,
|
|
41
|
+
CLAIM_REWARDS_DISCRIMINATOR: () => CLAIM_REWARDS_DISCRIMINATOR,
|
|
41
42
|
CLOSE_OPTION_ACCOUNT_DISCRIMINATOR: () => CLOSE_OPTION_ACCOUNT_DISCRIMINATOR,
|
|
42
43
|
CLOSE_STAKE_ACCOUNT_DISCRIMINATOR: () => CLOSE_STAKE_ACCOUNT_DISCRIMINATOR,
|
|
43
44
|
CLOSE_STUCK_STAKE_ACCOUNT_DISCRIMINATOR: () => CLOSE_STUCK_STAKE_ACCOUNT_DISCRIMINATOR,
|
|
45
|
+
CLOSE_UNREVEALED_STAKE_ACCOUNT_DISCRIMINATOR: () => CLOSE_UNREVEALED_STAKE_ACCOUNT_DISCRIMINATOR,
|
|
44
46
|
CREATE_MARKET_DISCRIMINATOR: () => CREATE_MARKET_DISCRIMINATOR,
|
|
45
47
|
END_REVEAL_PERIOD_DISCRIMINATOR: () => END_REVEAL_PERIOD_DISCRIMINATOR,
|
|
46
48
|
FINALIZE_REVEAL_STAKE_DISCRIMINATOR: () => FINALIZE_REVEAL_STAKE_DISCRIMINATOR,
|
|
@@ -121,9 +123,11 @@ __export(index_exports, {
|
|
|
121
123
|
circuitSource: () => circuitSource,
|
|
122
124
|
claimCreatorFees: () => claimCreatorFees,
|
|
123
125
|
claimFees: () => claimFees,
|
|
126
|
+
claimRewards: () => claimRewards,
|
|
124
127
|
closeOptionAccount: () => closeOptionAccount,
|
|
125
128
|
closeStakeAccount: () => closeStakeAccount,
|
|
126
129
|
closeStuckStakeAccount: () => closeStuckStakeAccount,
|
|
130
|
+
closeUnrevealedStakeAccount: () => closeUnrevealedStakeAccount,
|
|
127
131
|
createCipher: () => createCipher,
|
|
128
132
|
createMarket: () => createMarket,
|
|
129
133
|
createPlatformConfig: () => createPlatformConfig,
|
|
@@ -212,6 +216,12 @@ __export(index_exports, {
|
|
|
212
216
|
getClaimFeesInstructionDataCodec: () => getClaimFeesInstructionDataCodec,
|
|
213
217
|
getClaimFeesInstructionDataDecoder: () => getClaimFeesInstructionDataDecoder,
|
|
214
218
|
getClaimFeesInstructionDataEncoder: () => getClaimFeesInstructionDataEncoder,
|
|
219
|
+
getClaimRewardsDiscriminatorBytes: () => getClaimRewardsDiscriminatorBytes,
|
|
220
|
+
getClaimRewardsInstruction: () => getClaimRewardsInstruction,
|
|
221
|
+
getClaimRewardsInstructionAsync: () => getClaimRewardsInstructionAsync,
|
|
222
|
+
getClaimRewardsInstructionDataCodec: () => getClaimRewardsInstructionDataCodec,
|
|
223
|
+
getClaimRewardsInstructionDataDecoder: () => getClaimRewardsInstructionDataDecoder,
|
|
224
|
+
getClaimRewardsInstructionDataEncoder: () => getClaimRewardsInstructionDataEncoder,
|
|
215
225
|
getClockAccountCodec: () => getClockAccountCodec,
|
|
216
226
|
getClockAccountDecoder: () => getClockAccountDecoder,
|
|
217
227
|
getClockAccountEncoder: () => getClockAccountEncoder,
|
|
@@ -233,6 +243,12 @@ __export(index_exports, {
|
|
|
233
243
|
getCloseStuckStakeAccountInstructionDataCodec: () => getCloseStuckStakeAccountInstructionDataCodec,
|
|
234
244
|
getCloseStuckStakeAccountInstructionDataDecoder: () => getCloseStuckStakeAccountInstructionDataDecoder,
|
|
235
245
|
getCloseStuckStakeAccountInstructionDataEncoder: () => getCloseStuckStakeAccountInstructionDataEncoder,
|
|
246
|
+
getCloseUnrevealedStakeAccountDiscriminatorBytes: () => getCloseUnrevealedStakeAccountDiscriminatorBytes,
|
|
247
|
+
getCloseUnrevealedStakeAccountInstruction: () => getCloseUnrevealedStakeAccountInstruction,
|
|
248
|
+
getCloseUnrevealedStakeAccountInstructionAsync: () => getCloseUnrevealedStakeAccountInstructionAsync,
|
|
249
|
+
getCloseUnrevealedStakeAccountInstructionDataCodec: () => getCloseUnrevealedStakeAccountInstructionDataCodec,
|
|
250
|
+
getCloseUnrevealedStakeAccountInstructionDataDecoder: () => getCloseUnrevealedStakeAccountInstructionDataDecoder,
|
|
251
|
+
getCloseUnrevealedStakeAccountInstructionDataEncoder: () => getCloseUnrevealedStakeAccountInstructionDataEncoder,
|
|
236
252
|
getClusterCodec: () => getClusterCodec,
|
|
237
253
|
getClusterDecoder: () => getClusterDecoder,
|
|
238
254
|
getClusterEncoder: () => getClusterEncoder,
|
|
@@ -409,6 +425,9 @@ __export(index_exports, {
|
|
|
409
425
|
getRewardWithdrawnEventCodec: () => getRewardWithdrawnEventCodec,
|
|
410
426
|
getRewardWithdrawnEventDecoder: () => getRewardWithdrawnEventDecoder,
|
|
411
427
|
getRewardWithdrawnEventEncoder: () => getRewardWithdrawnEventEncoder,
|
|
428
|
+
getRewardsClaimedEventCodec: () => getRewardsClaimedEventCodec,
|
|
429
|
+
getRewardsClaimedEventDecoder: () => getRewardsClaimedEventDecoder,
|
|
430
|
+
getRewardsClaimedEventEncoder: () => getRewardsClaimedEventEncoder,
|
|
412
431
|
getSetFeeClaimAuthorityDiscriminatorBytes: () => getSetFeeClaimAuthorityDiscriminatorBytes,
|
|
413
432
|
getSetFeeClaimAuthorityInstruction: () => getSetFeeClaimAuthorityInstruction,
|
|
414
433
|
getSetFeeClaimAuthorityInstructionDataCodec: () => getSetFeeClaimAuthorityInstructionDataCodec,
|
|
@@ -511,9 +530,11 @@ __export(index_exports, {
|
|
|
511
530
|
parseAddRewardInstruction: () => parseAddRewardInstruction,
|
|
512
531
|
parseClaimCreatorFeesInstruction: () => parseClaimCreatorFeesInstruction,
|
|
513
532
|
parseClaimFeesInstruction: () => parseClaimFeesInstruction,
|
|
533
|
+
parseClaimRewardsInstruction: () => parseClaimRewardsInstruction,
|
|
514
534
|
parseCloseOptionAccountInstruction: () => parseCloseOptionAccountInstruction,
|
|
515
535
|
parseCloseStakeAccountInstruction: () => parseCloseStakeAccountInstruction,
|
|
516
536
|
parseCloseStuckStakeAccountInstruction: () => parseCloseStuckStakeAccountInstruction,
|
|
537
|
+
parseCloseUnrevealedStakeAccountInstruction: () => parseCloseUnrevealedStakeAccountInstruction,
|
|
517
538
|
parseCreateMarketInstruction: () => parseCreateMarketInstruction,
|
|
518
539
|
parseEndRevealPeriodInstruction: () => parseEndRevealPeriodInstruction,
|
|
519
540
|
parseFinalizeRevealStakeInstruction: () => parseFinalizeRevealStakeInstruction,
|
|
@@ -690,7 +711,7 @@ async function fetchAllMaybeArciumSignerAccount(rpc, addresses, config) {
|
|
|
690
711
|
}
|
|
691
712
|
|
|
692
713
|
// src/generated/accounts/opportunityMarket.ts
|
|
693
|
-
var
|
|
714
|
+
var import_kit51 = require("@solana/kit");
|
|
694
715
|
|
|
695
716
|
// src/generated/types/activation.ts
|
|
696
717
|
var import_kit3 = require("@solana/kit");
|
|
@@ -1162,7 +1183,6 @@ function getMarketCreatedEventEncoder() {
|
|
|
1162
1183
|
["earlinessMultiplier", (0, import_kit20.getU16Encoder)()],
|
|
1163
1184
|
["marketAuthority", (0, import_kit20.getAddressEncoder)()],
|
|
1164
1185
|
["authorizedReaderPubkey", (0, import_kit20.getArrayEncoder)((0, import_kit20.getU8Encoder)(), { size: 32 })],
|
|
1165
|
-
["allowUnstakingEarly", (0, import_kit20.getBooleanEncoder)()],
|
|
1166
1186
|
["minStakeAmount", (0, import_kit20.getU64Encoder)()],
|
|
1167
1187
|
["feeRates", getFeeRatesEncoder()],
|
|
1168
1188
|
["creatorFeeClaimer", (0, import_kit20.getAddressEncoder)()],
|
|
@@ -1182,7 +1202,6 @@ function getMarketCreatedEventDecoder() {
|
|
|
1182
1202
|
["earlinessMultiplier", (0, import_kit20.getU16Decoder)()],
|
|
1183
1203
|
["marketAuthority", (0, import_kit20.getAddressDecoder)()],
|
|
1184
1204
|
["authorizedReaderPubkey", (0, import_kit20.getArrayDecoder)((0, import_kit20.getU8Decoder)(), { size: 32 })],
|
|
1185
|
-
["allowUnstakingEarly", (0, import_kit20.getBooleanDecoder)()],
|
|
1186
1205
|
["minStakeAmount", (0, import_kit20.getU64Decoder)()],
|
|
1187
1206
|
["feeRates", getFeeRatesDecoder()],
|
|
1188
1207
|
["creatorFeeClaimer", (0, import_kit20.getAddressDecoder)()],
|
|
@@ -1625,7 +1644,6 @@ function getRewardAddedEventEncoder() {
|
|
|
1625
1644
|
["sponsor", (0, import_kit36.getAddressEncoder)()],
|
|
1626
1645
|
["amount", (0, import_kit36.getU64Encoder)()],
|
|
1627
1646
|
["totalRewardAmount", (0, import_kit36.getU64Encoder)()],
|
|
1628
|
-
["locked", (0, import_kit36.getBooleanEncoder)()],
|
|
1629
1647
|
["timestamp", (0, import_kit36.getI64Encoder)()]
|
|
1630
1648
|
]);
|
|
1631
1649
|
}
|
|
@@ -1635,7 +1653,6 @@ function getRewardAddedEventDecoder() {
|
|
|
1635
1653
|
["sponsor", (0, import_kit36.getAddressDecoder)()],
|
|
1636
1654
|
["amount", (0, import_kit36.getU64Decoder)()],
|
|
1637
1655
|
["totalRewardAmount", (0, import_kit36.getU64Decoder)()],
|
|
1638
|
-
["locked", (0, import_kit36.getBooleanDecoder)()],
|
|
1639
1656
|
["timestamp", (0, import_kit36.getI64Decoder)()]
|
|
1640
1657
|
]);
|
|
1641
1658
|
}
|
|
@@ -1646,163 +1663,196 @@ function getRewardAddedEventCodec() {
|
|
|
1646
1663
|
);
|
|
1647
1664
|
}
|
|
1648
1665
|
|
|
1649
|
-
// src/generated/types/
|
|
1666
|
+
// src/generated/types/rewardsClaimedEvent.ts
|
|
1650
1667
|
var import_kit37 = require("@solana/kit");
|
|
1651
|
-
function
|
|
1668
|
+
function getRewardsClaimedEventEncoder() {
|
|
1652
1669
|
return (0, import_kit37.getStructEncoder)([
|
|
1670
|
+
["owner", (0, import_kit37.getAddressEncoder)()],
|
|
1653
1671
|
["market", (0, import_kit37.getAddressEncoder)()],
|
|
1654
|
-
["
|
|
1672
|
+
["stakeAccount", (0, import_kit37.getAddressEncoder)()],
|
|
1673
|
+
["stakeAccountId", (0, import_kit37.getU32Encoder)()],
|
|
1674
|
+
["optionId", (0, import_kit37.getU64Encoder)()],
|
|
1655
1675
|
["rewardAmount", (0, import_kit37.getU64Encoder)()],
|
|
1656
|
-
["
|
|
1676
|
+
["score", (0, import_kit37.getU64Encoder)()],
|
|
1657
1677
|
["timestamp", (0, import_kit37.getI64Encoder)()]
|
|
1658
1678
|
]);
|
|
1659
1679
|
}
|
|
1660
|
-
function
|
|
1680
|
+
function getRewardsClaimedEventDecoder() {
|
|
1661
1681
|
return (0, import_kit37.getStructDecoder)([
|
|
1682
|
+
["owner", (0, import_kit37.getAddressDecoder)()],
|
|
1662
1683
|
["market", (0, import_kit37.getAddressDecoder)()],
|
|
1663
|
-
["
|
|
1684
|
+
["stakeAccount", (0, import_kit37.getAddressDecoder)()],
|
|
1685
|
+
["stakeAccountId", (0, import_kit37.getU32Decoder)()],
|
|
1686
|
+
["optionId", (0, import_kit37.getU64Decoder)()],
|
|
1664
1687
|
["rewardAmount", (0, import_kit37.getU64Decoder)()],
|
|
1665
|
-
["
|
|
1688
|
+
["score", (0, import_kit37.getU64Decoder)()],
|
|
1666
1689
|
["timestamp", (0, import_kit37.getI64Decoder)()]
|
|
1667
1690
|
]);
|
|
1668
1691
|
}
|
|
1669
|
-
function
|
|
1692
|
+
function getRewardsClaimedEventCodec() {
|
|
1670
1693
|
return (0, import_kit37.combineCodec)(
|
|
1671
|
-
|
|
1672
|
-
|
|
1694
|
+
getRewardsClaimedEventEncoder(),
|
|
1695
|
+
getRewardsClaimedEventDecoder()
|
|
1673
1696
|
);
|
|
1674
1697
|
}
|
|
1675
1698
|
|
|
1676
|
-
// src/generated/types/
|
|
1699
|
+
// src/generated/types/rewardWithdrawnEvent.ts
|
|
1677
1700
|
var import_kit38 = require("@solana/kit");
|
|
1678
|
-
function
|
|
1701
|
+
function getRewardWithdrawnEventEncoder() {
|
|
1679
1702
|
return (0, import_kit38.getStructEncoder)([
|
|
1680
|
-
["owner", (0, import_kit38.getAddressEncoder)()],
|
|
1681
1703
|
["market", (0, import_kit38.getAddressEncoder)()],
|
|
1682
|
-
["
|
|
1683
|
-
["stakeAccountId", (0, import_kit38.getU32Encoder)()],
|
|
1684
|
-
["optionId", (0, import_kit38.getU64Encoder)()],
|
|
1704
|
+
["sponsor", (0, import_kit38.getAddressEncoder)()],
|
|
1685
1705
|
["rewardAmount", (0, import_kit38.getU64Encoder)()],
|
|
1686
|
-
["
|
|
1687
|
-
["stakeEndTimestamp", (0, import_kit38.getU64Encoder)()],
|
|
1688
|
-
["stakeAmount", (0, import_kit38.getU64Encoder)()],
|
|
1689
|
-
["score", (0, import_kit38.getU64Encoder)()],
|
|
1706
|
+
["refundTokenAccount", (0, import_kit38.getAddressEncoder)()],
|
|
1690
1707
|
["timestamp", (0, import_kit38.getI64Encoder)()]
|
|
1691
1708
|
]);
|
|
1692
1709
|
}
|
|
1693
|
-
function
|
|
1710
|
+
function getRewardWithdrawnEventDecoder() {
|
|
1694
1711
|
return (0, import_kit38.getStructDecoder)([
|
|
1695
|
-
["owner", (0, import_kit38.getAddressDecoder)()],
|
|
1696
1712
|
["market", (0, import_kit38.getAddressDecoder)()],
|
|
1697
|
-
["
|
|
1698
|
-
["stakeAccountId", (0, import_kit38.getU32Decoder)()],
|
|
1699
|
-
["optionId", (0, import_kit38.getU64Decoder)()],
|
|
1713
|
+
["sponsor", (0, import_kit38.getAddressDecoder)()],
|
|
1700
1714
|
["rewardAmount", (0, import_kit38.getU64Decoder)()],
|
|
1701
|
-
["
|
|
1702
|
-
["stakeEndTimestamp", (0, import_kit38.getU64Decoder)()],
|
|
1703
|
-
["stakeAmount", (0, import_kit38.getU64Decoder)()],
|
|
1704
|
-
["score", (0, import_kit38.getU64Decoder)()],
|
|
1715
|
+
["refundTokenAccount", (0, import_kit38.getAddressDecoder)()],
|
|
1705
1716
|
["timestamp", (0, import_kit38.getI64Decoder)()]
|
|
1706
1717
|
]);
|
|
1707
1718
|
}
|
|
1708
|
-
function
|
|
1719
|
+
function getRewardWithdrawnEventCodec() {
|
|
1709
1720
|
return (0, import_kit38.combineCodec)(
|
|
1710
|
-
|
|
1711
|
-
|
|
1721
|
+
getRewardWithdrawnEventEncoder(),
|
|
1722
|
+
getRewardWithdrawnEventDecoder()
|
|
1712
1723
|
);
|
|
1713
1724
|
}
|
|
1714
1725
|
|
|
1715
|
-
// src/generated/types/
|
|
1726
|
+
// src/generated/types/stakeAccountClosedEvent.ts
|
|
1716
1727
|
var import_kit39 = require("@solana/kit");
|
|
1717
|
-
function
|
|
1728
|
+
function getStakeAccountClosedEventEncoder() {
|
|
1718
1729
|
return (0, import_kit39.getStructEncoder)([
|
|
1719
|
-
["stakeAccount", (0, import_kit39.getAddressEncoder)()],
|
|
1720
1730
|
["owner", (0, import_kit39.getAddressEncoder)()],
|
|
1721
1731
|
["market", (0, import_kit39.getAddressEncoder)()],
|
|
1722
|
-
["
|
|
1732
|
+
["stakeAccount", (0, import_kit39.getAddressEncoder)()],
|
|
1733
|
+
["stakeAccountId", (0, import_kit39.getU32Encoder)()],
|
|
1734
|
+
["optionId", (0, import_kit39.getOptionEncoder)((0, import_kit39.getU64Encoder)())],
|
|
1735
|
+
["stakeAmount", (0, import_kit39.getU64Encoder)()],
|
|
1736
|
+
["feeRefund", (0, import_kit39.getU64Encoder)()],
|
|
1737
|
+
["stakedAtTimestamp", (0, import_kit39.getU64Encoder)()],
|
|
1738
|
+
["stakeEndTimestamp", (0, import_kit39.getU64Encoder)()],
|
|
1739
|
+
["score", (0, import_kit39.getU64Encoder)()],
|
|
1723
1740
|
["timestamp", (0, import_kit39.getI64Encoder)()]
|
|
1724
1741
|
]);
|
|
1725
1742
|
}
|
|
1726
|
-
function
|
|
1743
|
+
function getStakeAccountClosedEventDecoder() {
|
|
1727
1744
|
return (0, import_kit39.getStructDecoder)([
|
|
1728
|
-
["stakeAccount", (0, import_kit39.getAddressDecoder)()],
|
|
1729
1745
|
["owner", (0, import_kit39.getAddressDecoder)()],
|
|
1730
1746
|
["market", (0, import_kit39.getAddressDecoder)()],
|
|
1731
|
-
["
|
|
1747
|
+
["stakeAccount", (0, import_kit39.getAddressDecoder)()],
|
|
1748
|
+
["stakeAccountId", (0, import_kit39.getU32Decoder)()],
|
|
1749
|
+
["optionId", (0, import_kit39.getOptionDecoder)((0, import_kit39.getU64Decoder)())],
|
|
1750
|
+
["stakeAmount", (0, import_kit39.getU64Decoder)()],
|
|
1751
|
+
["feeRefund", (0, import_kit39.getU64Decoder)()],
|
|
1752
|
+
["stakedAtTimestamp", (0, import_kit39.getU64Decoder)()],
|
|
1753
|
+
["stakeEndTimestamp", (0, import_kit39.getU64Decoder)()],
|
|
1754
|
+
["score", (0, import_kit39.getU64Decoder)()],
|
|
1732
1755
|
["timestamp", (0, import_kit39.getI64Decoder)()]
|
|
1733
1756
|
]);
|
|
1734
1757
|
}
|
|
1735
|
-
function
|
|
1758
|
+
function getStakeAccountClosedEventCodec() {
|
|
1736
1759
|
return (0, import_kit39.combineCodec)(
|
|
1760
|
+
getStakeAccountClosedEventEncoder(),
|
|
1761
|
+
getStakeAccountClosedEventDecoder()
|
|
1762
|
+
);
|
|
1763
|
+
}
|
|
1764
|
+
|
|
1765
|
+
// src/generated/types/stakeAccountInitializedEvent.ts
|
|
1766
|
+
var import_kit40 = require("@solana/kit");
|
|
1767
|
+
function getStakeAccountInitializedEventEncoder() {
|
|
1768
|
+
return (0, import_kit40.getStructEncoder)([
|
|
1769
|
+
["stakeAccount", (0, import_kit40.getAddressEncoder)()],
|
|
1770
|
+
["owner", (0, import_kit40.getAddressEncoder)()],
|
|
1771
|
+
["market", (0, import_kit40.getAddressEncoder)()],
|
|
1772
|
+
["accountId", (0, import_kit40.getU32Encoder)()],
|
|
1773
|
+
["timestamp", (0, import_kit40.getI64Encoder)()]
|
|
1774
|
+
]);
|
|
1775
|
+
}
|
|
1776
|
+
function getStakeAccountInitializedEventDecoder() {
|
|
1777
|
+
return (0, import_kit40.getStructDecoder)([
|
|
1778
|
+
["stakeAccount", (0, import_kit40.getAddressDecoder)()],
|
|
1779
|
+
["owner", (0, import_kit40.getAddressDecoder)()],
|
|
1780
|
+
["market", (0, import_kit40.getAddressDecoder)()],
|
|
1781
|
+
["accountId", (0, import_kit40.getU32Decoder)()],
|
|
1782
|
+
["timestamp", (0, import_kit40.getI64Decoder)()]
|
|
1783
|
+
]);
|
|
1784
|
+
}
|
|
1785
|
+
function getStakeAccountInitializedEventCodec() {
|
|
1786
|
+
return (0, import_kit40.combineCodec)(
|
|
1737
1787
|
getStakeAccountInitializedEventEncoder(),
|
|
1738
1788
|
getStakeAccountInitializedEventDecoder()
|
|
1739
1789
|
);
|
|
1740
1790
|
}
|
|
1741
1791
|
|
|
1742
1792
|
// src/generated/types/stakedEvent.ts
|
|
1743
|
-
var
|
|
1793
|
+
var import_kit41 = require("@solana/kit");
|
|
1744
1794
|
function getStakedEventEncoder() {
|
|
1745
|
-
return (0,
|
|
1746
|
-
["user", (0,
|
|
1747
|
-
["market", (0,
|
|
1748
|
-
["stakeAccount", (0,
|
|
1749
|
-
["stakeAccountId", (0,
|
|
1750
|
-
["stakeEncryptedOption", (0,
|
|
1751
|
-
["stakeStateNonce", (0,
|
|
1795
|
+
return (0, import_kit41.getStructEncoder)([
|
|
1796
|
+
["user", (0, import_kit41.getAddressEncoder)()],
|
|
1797
|
+
["market", (0, import_kit41.getAddressEncoder)()],
|
|
1798
|
+
["stakeAccount", (0, import_kit41.getAddressEncoder)()],
|
|
1799
|
+
["stakeAccountId", (0, import_kit41.getU32Encoder)()],
|
|
1800
|
+
["stakeEncryptedOption", (0, import_kit41.getArrayEncoder)((0, import_kit41.getU8Encoder)(), { size: 32 })],
|
|
1801
|
+
["stakeStateNonce", (0, import_kit41.getU128Encoder)()],
|
|
1752
1802
|
[
|
|
1753
1803
|
"stakeEncryptedOptionDisclosure",
|
|
1754
|
-
(0,
|
|
1804
|
+
(0, import_kit41.getArrayEncoder)((0, import_kit41.getU8Encoder)(), { size: 32 })
|
|
1755
1805
|
],
|
|
1756
|
-
["stakeStateDisclosureNonce", (0,
|
|
1757
|
-
["amount", (0,
|
|
1758
|
-
["timestamp", (0,
|
|
1806
|
+
["stakeStateDisclosureNonce", (0, import_kit41.getU128Encoder)()],
|
|
1807
|
+
["amount", (0, import_kit41.getU64Encoder)()],
|
|
1808
|
+
["timestamp", (0, import_kit41.getI64Encoder)()]
|
|
1759
1809
|
]);
|
|
1760
1810
|
}
|
|
1761
1811
|
function getStakedEventDecoder() {
|
|
1762
|
-
return (0,
|
|
1763
|
-
["user", (0,
|
|
1764
|
-
["market", (0,
|
|
1765
|
-
["stakeAccount", (0,
|
|
1766
|
-
["stakeAccountId", (0,
|
|
1767
|
-
["stakeEncryptedOption", (0,
|
|
1768
|
-
["stakeStateNonce", (0,
|
|
1812
|
+
return (0, import_kit41.getStructDecoder)([
|
|
1813
|
+
["user", (0, import_kit41.getAddressDecoder)()],
|
|
1814
|
+
["market", (0, import_kit41.getAddressDecoder)()],
|
|
1815
|
+
["stakeAccount", (0, import_kit41.getAddressDecoder)()],
|
|
1816
|
+
["stakeAccountId", (0, import_kit41.getU32Decoder)()],
|
|
1817
|
+
["stakeEncryptedOption", (0, import_kit41.getArrayDecoder)((0, import_kit41.getU8Decoder)(), { size: 32 })],
|
|
1818
|
+
["stakeStateNonce", (0, import_kit41.getU128Decoder)()],
|
|
1769
1819
|
[
|
|
1770
1820
|
"stakeEncryptedOptionDisclosure",
|
|
1771
|
-
(0,
|
|
1821
|
+
(0, import_kit41.getArrayDecoder)((0, import_kit41.getU8Decoder)(), { size: 32 })
|
|
1772
1822
|
],
|
|
1773
|
-
["stakeStateDisclosureNonce", (0,
|
|
1774
|
-
["amount", (0,
|
|
1775
|
-
["timestamp", (0,
|
|
1823
|
+
["stakeStateDisclosureNonce", (0, import_kit41.getU128Decoder)()],
|
|
1824
|
+
["amount", (0, import_kit41.getU64Decoder)()],
|
|
1825
|
+
["timestamp", (0, import_kit41.getI64Decoder)()]
|
|
1776
1826
|
]);
|
|
1777
1827
|
}
|
|
1778
1828
|
function getStakedEventCodec() {
|
|
1779
|
-
return (0,
|
|
1829
|
+
return (0, import_kit41.combineCodec)(getStakedEventEncoder(), getStakedEventDecoder());
|
|
1780
1830
|
}
|
|
1781
1831
|
|
|
1782
1832
|
// src/generated/types/stakeOutput.ts
|
|
1783
|
-
var
|
|
1833
|
+
var import_kit42 = require("@solana/kit");
|
|
1784
1834
|
function getStakeOutputEncoder() {
|
|
1785
|
-
return (0,
|
|
1835
|
+
return (0, import_kit42.getStructEncoder)([["field0", getStakeOutputStruct0Encoder()]]);
|
|
1786
1836
|
}
|
|
1787
1837
|
function getStakeOutputDecoder() {
|
|
1788
|
-
return (0,
|
|
1838
|
+
return (0, import_kit42.getStructDecoder)([["field0", getStakeOutputStruct0Decoder()]]);
|
|
1789
1839
|
}
|
|
1790
1840
|
function getStakeOutputCodec() {
|
|
1791
|
-
return (0,
|
|
1841
|
+
return (0, import_kit42.combineCodec)(getStakeOutputEncoder(), getStakeOutputDecoder());
|
|
1792
1842
|
}
|
|
1793
1843
|
|
|
1794
1844
|
// src/generated/types/stakeOutputStruct0.ts
|
|
1795
|
-
var
|
|
1845
|
+
var import_kit43 = require("@solana/kit");
|
|
1796
1846
|
function getStakeOutputStruct0Encoder() {
|
|
1797
|
-
return (0,
|
|
1847
|
+
return (0, import_kit43.getStructEncoder)([
|
|
1798
1848
|
[
|
|
1799
1849
|
"field0",
|
|
1800
|
-
(0,
|
|
1801
|
-
["encryptionKey", (0,
|
|
1802
|
-
["nonce", (0,
|
|
1850
|
+
(0, import_kit43.getStructEncoder)([
|
|
1851
|
+
["encryptionKey", (0, import_kit43.getArrayEncoder)((0, import_kit43.getU8Encoder)(), { size: 32 })],
|
|
1852
|
+
["nonce", (0, import_kit43.getU128Encoder)()],
|
|
1803
1853
|
[
|
|
1804
1854
|
"ciphertexts",
|
|
1805
|
-
(0,
|
|
1855
|
+
(0, import_kit43.getArrayEncoder)((0, import_kit43.getArrayEncoder)((0, import_kit43.getU8Encoder)(), { size: 32 }), {
|
|
1806
1856
|
size: 1
|
|
1807
1857
|
})
|
|
1808
1858
|
]
|
|
@@ -1810,12 +1860,12 @@ function getStakeOutputStruct0Encoder() {
|
|
|
1810
1860
|
],
|
|
1811
1861
|
[
|
|
1812
1862
|
"field1",
|
|
1813
|
-
(0,
|
|
1814
|
-
["encryptionKey", (0,
|
|
1815
|
-
["nonce", (0,
|
|
1863
|
+
(0, import_kit43.getStructEncoder)([
|
|
1864
|
+
["encryptionKey", (0, import_kit43.getArrayEncoder)((0, import_kit43.getU8Encoder)(), { size: 32 })],
|
|
1865
|
+
["nonce", (0, import_kit43.getU128Encoder)()],
|
|
1816
1866
|
[
|
|
1817
1867
|
"ciphertexts",
|
|
1818
|
-
(0,
|
|
1868
|
+
(0, import_kit43.getArrayEncoder)((0, import_kit43.getArrayEncoder)((0, import_kit43.getU8Encoder)(), { size: 32 }), {
|
|
1819
1869
|
size: 1
|
|
1820
1870
|
})
|
|
1821
1871
|
]
|
|
@@ -1824,15 +1874,15 @@ function getStakeOutputStruct0Encoder() {
|
|
|
1824
1874
|
]);
|
|
1825
1875
|
}
|
|
1826
1876
|
function getStakeOutputStruct0Decoder() {
|
|
1827
|
-
return (0,
|
|
1877
|
+
return (0, import_kit43.getStructDecoder)([
|
|
1828
1878
|
[
|
|
1829
1879
|
"field0",
|
|
1830
|
-
(0,
|
|
1831
|
-
["encryptionKey", (0,
|
|
1832
|
-
["nonce", (0,
|
|
1880
|
+
(0, import_kit43.getStructDecoder)([
|
|
1881
|
+
["encryptionKey", (0, import_kit43.getArrayDecoder)((0, import_kit43.getU8Decoder)(), { size: 32 })],
|
|
1882
|
+
["nonce", (0, import_kit43.getU128Decoder)()],
|
|
1833
1883
|
[
|
|
1834
1884
|
"ciphertexts",
|
|
1835
|
-
(0,
|
|
1885
|
+
(0, import_kit43.getArrayDecoder)((0, import_kit43.getArrayDecoder)((0, import_kit43.getU8Decoder)(), { size: 32 }), {
|
|
1836
1886
|
size: 1
|
|
1837
1887
|
})
|
|
1838
1888
|
]
|
|
@@ -1840,12 +1890,12 @@ function getStakeOutputStruct0Decoder() {
|
|
|
1840
1890
|
],
|
|
1841
1891
|
[
|
|
1842
1892
|
"field1",
|
|
1843
|
-
(0,
|
|
1844
|
-
["encryptionKey", (0,
|
|
1845
|
-
["nonce", (0,
|
|
1893
|
+
(0, import_kit43.getStructDecoder)([
|
|
1894
|
+
["encryptionKey", (0, import_kit43.getArrayDecoder)((0, import_kit43.getU8Decoder)(), { size: 32 })],
|
|
1895
|
+
["nonce", (0, import_kit43.getU128Decoder)()],
|
|
1846
1896
|
[
|
|
1847
1897
|
"ciphertexts",
|
|
1848
|
-
(0,
|
|
1898
|
+
(0, import_kit43.getArrayDecoder)((0, import_kit43.getArrayDecoder)((0, import_kit43.getU8Decoder)(), { size: 32 }), {
|
|
1849
1899
|
size: 1
|
|
1850
1900
|
})
|
|
1851
1901
|
]
|
|
@@ -1854,189 +1904,189 @@ function getStakeOutputStruct0Decoder() {
|
|
|
1854
1904
|
]);
|
|
1855
1905
|
}
|
|
1856
1906
|
function getStakeOutputStruct0Codec() {
|
|
1857
|
-
return (0,
|
|
1907
|
+
return (0, import_kit43.combineCodec)(
|
|
1858
1908
|
getStakeOutputStruct0Encoder(),
|
|
1859
1909
|
getStakeOutputStruct0Decoder()
|
|
1860
1910
|
);
|
|
1861
1911
|
}
|
|
1862
1912
|
|
|
1863
1913
|
// src/generated/types/stakeRevealedEvent.ts
|
|
1864
|
-
var
|
|
1914
|
+
var import_kit44 = require("@solana/kit");
|
|
1865
1915
|
function getStakeRevealedEventEncoder() {
|
|
1866
|
-
return (0,
|
|
1867
|
-
["user", (0,
|
|
1868
|
-
["market", (0,
|
|
1869
|
-
["stakeAccount", (0,
|
|
1870
|
-
["stakeAccountId", (0,
|
|
1871
|
-
["stakeAmount", (0,
|
|
1872
|
-
["selectedOption", (0,
|
|
1873
|
-
["timestamp", (0,
|
|
1916
|
+
return (0, import_kit44.getStructEncoder)([
|
|
1917
|
+
["user", (0, import_kit44.getAddressEncoder)()],
|
|
1918
|
+
["market", (0, import_kit44.getAddressEncoder)()],
|
|
1919
|
+
["stakeAccount", (0, import_kit44.getAddressEncoder)()],
|
|
1920
|
+
["stakeAccountId", (0, import_kit44.getU32Encoder)()],
|
|
1921
|
+
["stakeAmount", (0, import_kit44.getU64Encoder)()],
|
|
1922
|
+
["selectedOption", (0, import_kit44.getU64Encoder)()],
|
|
1923
|
+
["timestamp", (0, import_kit44.getI64Encoder)()]
|
|
1874
1924
|
]);
|
|
1875
1925
|
}
|
|
1876
1926
|
function getStakeRevealedEventDecoder() {
|
|
1877
|
-
return (0,
|
|
1878
|
-
["user", (0,
|
|
1879
|
-
["market", (0,
|
|
1880
|
-
["stakeAccount", (0,
|
|
1881
|
-
["stakeAccountId", (0,
|
|
1882
|
-
["stakeAmount", (0,
|
|
1883
|
-
["selectedOption", (0,
|
|
1884
|
-
["timestamp", (0,
|
|
1927
|
+
return (0, import_kit44.getStructDecoder)([
|
|
1928
|
+
["user", (0, import_kit44.getAddressDecoder)()],
|
|
1929
|
+
["market", (0, import_kit44.getAddressDecoder)()],
|
|
1930
|
+
["stakeAccount", (0, import_kit44.getAddressDecoder)()],
|
|
1931
|
+
["stakeAccountId", (0, import_kit44.getU32Decoder)()],
|
|
1932
|
+
["stakeAmount", (0, import_kit44.getU64Decoder)()],
|
|
1933
|
+
["selectedOption", (0, import_kit44.getU64Decoder)()],
|
|
1934
|
+
["timestamp", (0, import_kit44.getI64Decoder)()]
|
|
1885
1935
|
]);
|
|
1886
1936
|
}
|
|
1887
1937
|
function getStakeRevealedEventCodec() {
|
|
1888
|
-
return (0,
|
|
1938
|
+
return (0, import_kit44.combineCodec)(
|
|
1889
1939
|
getStakeRevealedEventEncoder(),
|
|
1890
1940
|
getStakeRevealedEventDecoder()
|
|
1891
1941
|
);
|
|
1892
1942
|
}
|
|
1893
1943
|
|
|
1894
1944
|
// src/generated/types/stuckStakeClosedEvent.ts
|
|
1895
|
-
var
|
|
1945
|
+
var import_kit45 = require("@solana/kit");
|
|
1896
1946
|
function getStuckStakeClosedEventEncoder() {
|
|
1897
|
-
return (0,
|
|
1898
|
-
["owner", (0,
|
|
1899
|
-
["market", (0,
|
|
1900
|
-
["stakeAccount", (0,
|
|
1901
|
-
["stakeAccountId", (0,
|
|
1902
|
-
["refundedAmount", (0,
|
|
1903
|
-
["refundedPlatformFee", (0,
|
|
1904
|
-
["refundedRewardPoolFee", (0,
|
|
1905
|
-
["refundedCreatorFee", (0,
|
|
1906
|
-
["timestamp", (0,
|
|
1947
|
+
return (0, import_kit45.getStructEncoder)([
|
|
1948
|
+
["owner", (0, import_kit45.getAddressEncoder)()],
|
|
1949
|
+
["market", (0, import_kit45.getAddressEncoder)()],
|
|
1950
|
+
["stakeAccount", (0, import_kit45.getAddressEncoder)()],
|
|
1951
|
+
["stakeAccountId", (0, import_kit45.getU32Encoder)()],
|
|
1952
|
+
["refundedAmount", (0, import_kit45.getU64Encoder)()],
|
|
1953
|
+
["refundedPlatformFee", (0, import_kit45.getU64Encoder)()],
|
|
1954
|
+
["refundedRewardPoolFee", (0, import_kit45.getU64Encoder)()],
|
|
1955
|
+
["refundedCreatorFee", (0, import_kit45.getU64Encoder)()],
|
|
1956
|
+
["timestamp", (0, import_kit45.getI64Encoder)()]
|
|
1907
1957
|
]);
|
|
1908
1958
|
}
|
|
1909
1959
|
function getStuckStakeClosedEventDecoder() {
|
|
1910
|
-
return (0,
|
|
1911
|
-
["owner", (0,
|
|
1912
|
-
["market", (0,
|
|
1913
|
-
["stakeAccount", (0,
|
|
1914
|
-
["stakeAccountId", (0,
|
|
1915
|
-
["refundedAmount", (0,
|
|
1916
|
-
["refundedPlatformFee", (0,
|
|
1917
|
-
["refundedRewardPoolFee", (0,
|
|
1918
|
-
["refundedCreatorFee", (0,
|
|
1919
|
-
["timestamp", (0,
|
|
1960
|
+
return (0, import_kit45.getStructDecoder)([
|
|
1961
|
+
["owner", (0, import_kit45.getAddressDecoder)()],
|
|
1962
|
+
["market", (0, import_kit45.getAddressDecoder)()],
|
|
1963
|
+
["stakeAccount", (0, import_kit45.getAddressDecoder)()],
|
|
1964
|
+
["stakeAccountId", (0, import_kit45.getU32Decoder)()],
|
|
1965
|
+
["refundedAmount", (0, import_kit45.getU64Decoder)()],
|
|
1966
|
+
["refundedPlatformFee", (0, import_kit45.getU64Decoder)()],
|
|
1967
|
+
["refundedRewardPoolFee", (0, import_kit45.getU64Decoder)()],
|
|
1968
|
+
["refundedCreatorFee", (0, import_kit45.getU64Decoder)()],
|
|
1969
|
+
["timestamp", (0, import_kit45.getI64Decoder)()]
|
|
1920
1970
|
]);
|
|
1921
1971
|
}
|
|
1922
1972
|
function getStuckStakeClosedEventCodec() {
|
|
1923
|
-
return (0,
|
|
1973
|
+
return (0, import_kit45.combineCodec)(
|
|
1924
1974
|
getStuckStakeClosedEventEncoder(),
|
|
1925
1975
|
getStuckStakeClosedEventDecoder()
|
|
1926
1976
|
);
|
|
1927
1977
|
}
|
|
1928
1978
|
|
|
1929
1979
|
// src/generated/types/timestamp.ts
|
|
1930
|
-
var
|
|
1980
|
+
var import_kit46 = require("@solana/kit");
|
|
1931
1981
|
function getTimestampEncoder() {
|
|
1932
|
-
return (0,
|
|
1982
|
+
return (0, import_kit46.getStructEncoder)([["timestamp", (0, import_kit46.getU64Encoder)()]]);
|
|
1933
1983
|
}
|
|
1934
1984
|
function getTimestampDecoder() {
|
|
1935
|
-
return (0,
|
|
1985
|
+
return (0, import_kit46.getStructDecoder)([["timestamp", (0, import_kit46.getU64Decoder)()]]);
|
|
1936
1986
|
}
|
|
1937
1987
|
function getTimestampCodec() {
|
|
1938
|
-
return (0,
|
|
1988
|
+
return (0, import_kit46.combineCodec)(getTimestampEncoder(), getTimestampDecoder());
|
|
1939
1989
|
}
|
|
1940
1990
|
|
|
1941
1991
|
// src/generated/types/unstakedEvent.ts
|
|
1942
|
-
var
|
|
1992
|
+
var import_kit47 = require("@solana/kit");
|
|
1943
1993
|
function getUnstakedEventEncoder() {
|
|
1944
|
-
return (0,
|
|
1945
|
-
["owner", (0,
|
|
1946
|
-
["market", (0,
|
|
1947
|
-
["stakeAccount", (0,
|
|
1948
|
-
["stakeAccountId", (0,
|
|
1949
|
-
["amount", (0,
|
|
1950
|
-
["timestamp", (0,
|
|
1994
|
+
return (0, import_kit47.getStructEncoder)([
|
|
1995
|
+
["owner", (0, import_kit47.getAddressEncoder)()],
|
|
1996
|
+
["market", (0, import_kit47.getAddressEncoder)()],
|
|
1997
|
+
["stakeAccount", (0, import_kit47.getAddressEncoder)()],
|
|
1998
|
+
["stakeAccountId", (0, import_kit47.getU32Encoder)()],
|
|
1999
|
+
["amount", (0, import_kit47.getU64Encoder)()],
|
|
2000
|
+
["timestamp", (0, import_kit47.getI64Encoder)()]
|
|
1951
2001
|
]);
|
|
1952
2002
|
}
|
|
1953
2003
|
function getUnstakedEventDecoder() {
|
|
1954
|
-
return (0,
|
|
1955
|
-
["owner", (0,
|
|
1956
|
-
["market", (0,
|
|
1957
|
-
["stakeAccount", (0,
|
|
1958
|
-
["stakeAccountId", (0,
|
|
1959
|
-
["amount", (0,
|
|
1960
|
-
["timestamp", (0,
|
|
2004
|
+
return (0, import_kit47.getStructDecoder)([
|
|
2005
|
+
["owner", (0, import_kit47.getAddressDecoder)()],
|
|
2006
|
+
["market", (0, import_kit47.getAddressDecoder)()],
|
|
2007
|
+
["stakeAccount", (0, import_kit47.getAddressDecoder)()],
|
|
2008
|
+
["stakeAccountId", (0, import_kit47.getU32Decoder)()],
|
|
2009
|
+
["amount", (0, import_kit47.getU64Decoder)()],
|
|
2010
|
+
["timestamp", (0, import_kit47.getI64Decoder)()]
|
|
1961
2011
|
]);
|
|
1962
2012
|
}
|
|
1963
2013
|
function getUnstakedEventCodec() {
|
|
1964
|
-
return (0,
|
|
2014
|
+
return (0, import_kit47.combineCodec)(getUnstakedEventEncoder(), getUnstakedEventDecoder());
|
|
1965
2015
|
}
|
|
1966
2016
|
|
|
1967
2017
|
// src/generated/types/updateAuthorityChangedEvent.ts
|
|
1968
|
-
var
|
|
2018
|
+
var import_kit48 = require("@solana/kit");
|
|
1969
2019
|
function getUpdateAuthorityChangedEventEncoder() {
|
|
1970
|
-
return (0,
|
|
1971
|
-
["platformConfig", (0,
|
|
1972
|
-
["oldValue", (0,
|
|
1973
|
-
["newValue", (0,
|
|
1974
|
-
["timestamp", (0,
|
|
2020
|
+
return (0, import_kit48.getStructEncoder)([
|
|
2021
|
+
["platformConfig", (0, import_kit48.getAddressEncoder)()],
|
|
2022
|
+
["oldValue", (0, import_kit48.getAddressEncoder)()],
|
|
2023
|
+
["newValue", (0, import_kit48.getAddressEncoder)()],
|
|
2024
|
+
["timestamp", (0, import_kit48.getI64Encoder)()]
|
|
1975
2025
|
]);
|
|
1976
2026
|
}
|
|
1977
2027
|
function getUpdateAuthorityChangedEventDecoder() {
|
|
1978
|
-
return (0,
|
|
1979
|
-
["platformConfig", (0,
|
|
1980
|
-
["oldValue", (0,
|
|
1981
|
-
["newValue", (0,
|
|
1982
|
-
["timestamp", (0,
|
|
2028
|
+
return (0, import_kit48.getStructDecoder)([
|
|
2029
|
+
["platformConfig", (0, import_kit48.getAddressDecoder)()],
|
|
2030
|
+
["oldValue", (0, import_kit48.getAddressDecoder)()],
|
|
2031
|
+
["newValue", (0, import_kit48.getAddressDecoder)()],
|
|
2032
|
+
["timestamp", (0, import_kit48.getI64Decoder)()]
|
|
1983
2033
|
]);
|
|
1984
2034
|
}
|
|
1985
2035
|
function getUpdateAuthorityChangedEventCodec() {
|
|
1986
|
-
return (0,
|
|
2036
|
+
return (0, import_kit48.combineCodec)(
|
|
1987
2037
|
getUpdateAuthorityChangedEventEncoder(),
|
|
1988
2038
|
getUpdateAuthorityChangedEventDecoder()
|
|
1989
2039
|
);
|
|
1990
2040
|
}
|
|
1991
2041
|
|
|
1992
2042
|
// src/generated/types/utilityPubkeys.ts
|
|
1993
|
-
var
|
|
2043
|
+
var import_kit49 = require("@solana/kit");
|
|
1994
2044
|
function getUtilityPubkeysEncoder() {
|
|
1995
|
-
return (0,
|
|
1996
|
-
["x25519Pubkey", (0,
|
|
1997
|
-
["ed25519VerifyingKey", (0,
|
|
1998
|
-
["elgamalPubkey", (0,
|
|
1999
|
-
["pubkeyValidityProof", (0,
|
|
2045
|
+
return (0, import_kit49.getStructEncoder)([
|
|
2046
|
+
["x25519Pubkey", (0, import_kit49.getArrayEncoder)((0, import_kit49.getU8Encoder)(), { size: 32 })],
|
|
2047
|
+
["ed25519VerifyingKey", (0, import_kit49.getArrayEncoder)((0, import_kit49.getU8Encoder)(), { size: 32 })],
|
|
2048
|
+
["elgamalPubkey", (0, import_kit49.getArrayEncoder)((0, import_kit49.getU8Encoder)(), { size: 32 })],
|
|
2049
|
+
["pubkeyValidityProof", (0, import_kit49.getArrayEncoder)((0, import_kit49.getU8Encoder)(), { size: 64 })]
|
|
2000
2050
|
]);
|
|
2001
2051
|
}
|
|
2002
2052
|
function getUtilityPubkeysDecoder() {
|
|
2003
|
-
return (0,
|
|
2004
|
-
["x25519Pubkey", (0,
|
|
2005
|
-
["ed25519VerifyingKey", (0,
|
|
2006
|
-
["elgamalPubkey", (0,
|
|
2007
|
-
["pubkeyValidityProof", (0,
|
|
2053
|
+
return (0, import_kit49.getStructDecoder)([
|
|
2054
|
+
["x25519Pubkey", (0, import_kit49.getArrayDecoder)((0, import_kit49.getU8Decoder)(), { size: 32 })],
|
|
2055
|
+
["ed25519VerifyingKey", (0, import_kit49.getArrayDecoder)((0, import_kit49.getU8Decoder)(), { size: 32 })],
|
|
2056
|
+
["elgamalPubkey", (0, import_kit49.getArrayDecoder)((0, import_kit49.getU8Decoder)(), { size: 32 })],
|
|
2057
|
+
["pubkeyValidityProof", (0, import_kit49.getArrayDecoder)((0, import_kit49.getU8Decoder)(), { size: 64 })]
|
|
2008
2058
|
]);
|
|
2009
2059
|
}
|
|
2010
2060
|
function getUtilityPubkeysCodec() {
|
|
2011
|
-
return (0,
|
|
2061
|
+
return (0, import_kit49.combineCodec)(getUtilityPubkeysEncoder(), getUtilityPubkeysDecoder());
|
|
2012
2062
|
}
|
|
2013
2063
|
|
|
2014
2064
|
// src/generated/types/winningOptionSetEvent.ts
|
|
2015
|
-
var
|
|
2065
|
+
var import_kit50 = require("@solana/kit");
|
|
2016
2066
|
function getWinningOptionSetEventEncoder() {
|
|
2017
|
-
return (0,
|
|
2018
|
-
["market", (0,
|
|
2019
|
-
["marketAuthority", (0,
|
|
2020
|
-
["option", (0,
|
|
2021
|
-
["optionId", (0,
|
|
2022
|
-
["rewardBp", (0,
|
|
2023
|
-
["winningOptionAllocation", (0,
|
|
2024
|
-
["timestamp", (0,
|
|
2067
|
+
return (0, import_kit50.getStructEncoder)([
|
|
2068
|
+
["market", (0, import_kit50.getAddressEncoder)()],
|
|
2069
|
+
["marketAuthority", (0, import_kit50.getAddressEncoder)()],
|
|
2070
|
+
["option", (0, import_kit50.getAddressEncoder)()],
|
|
2071
|
+
["optionId", (0, import_kit50.getU64Encoder)()],
|
|
2072
|
+
["rewardBp", (0, import_kit50.getU16Encoder)()],
|
|
2073
|
+
["winningOptionAllocation", (0, import_kit50.getU16Encoder)()],
|
|
2074
|
+
["timestamp", (0, import_kit50.getI64Encoder)()]
|
|
2025
2075
|
]);
|
|
2026
2076
|
}
|
|
2027
2077
|
function getWinningOptionSetEventDecoder() {
|
|
2028
|
-
return (0,
|
|
2029
|
-
["market", (0,
|
|
2030
|
-
["marketAuthority", (0,
|
|
2031
|
-
["option", (0,
|
|
2032
|
-
["optionId", (0,
|
|
2033
|
-
["rewardBp", (0,
|
|
2034
|
-
["winningOptionAllocation", (0,
|
|
2035
|
-
["timestamp", (0,
|
|
2078
|
+
return (0, import_kit50.getStructDecoder)([
|
|
2079
|
+
["market", (0, import_kit50.getAddressDecoder)()],
|
|
2080
|
+
["marketAuthority", (0, import_kit50.getAddressDecoder)()],
|
|
2081
|
+
["option", (0, import_kit50.getAddressDecoder)()],
|
|
2082
|
+
["optionId", (0, import_kit50.getU64Decoder)()],
|
|
2083
|
+
["rewardBp", (0, import_kit50.getU16Decoder)()],
|
|
2084
|
+
["winningOptionAllocation", (0, import_kit50.getU16Decoder)()],
|
|
2085
|
+
["timestamp", (0, import_kit50.getI64Decoder)()]
|
|
2036
2086
|
]);
|
|
2037
2087
|
}
|
|
2038
2088
|
function getWinningOptionSetEventCodec() {
|
|
2039
|
-
return (0,
|
|
2089
|
+
return (0, import_kit50.combineCodec)(
|
|
2040
2090
|
getWinningOptionSetEventEncoder(),
|
|
2041
2091
|
getWinningOptionSetEventDecoder()
|
|
2042
2092
|
);
|
|
@@ -2054,90 +2104,88 @@ var OPPORTUNITY_MARKET_DISCRIMINATOR = new Uint8Array([
|
|
|
2054
2104
|
224
|
|
2055
2105
|
]);
|
|
2056
2106
|
function getOpportunityMarketDiscriminatorBytes() {
|
|
2057
|
-
return (0,
|
|
2107
|
+
return (0, import_kit51.fixEncoderSize)((0, import_kit51.getBytesEncoder)(), 8).encode(
|
|
2058
2108
|
OPPORTUNITY_MARKET_DISCRIMINATOR
|
|
2059
2109
|
);
|
|
2060
2110
|
}
|
|
2061
2111
|
function getOpportunityMarketEncoder() {
|
|
2062
|
-
return (0,
|
|
2063
|
-
(0,
|
|
2064
|
-
["discriminator", (0,
|
|
2065
|
-
["bump", (0,
|
|
2066
|
-
["creator", (0,
|
|
2067
|
-
["index", (0,
|
|
2068
|
-
["totalOptions", (0,
|
|
2069
|
-
["platform", (0,
|
|
2070
|
-
["stakeEndTimestamp", (0,
|
|
2071
|
-
["resolvedAtTimestamp", (0,
|
|
2072
|
-
["winningOptionAllocation", (0,
|
|
2073
|
-
["winningOptionActiveBp", (0,
|
|
2074
|
-
["rewardAmount", (0,
|
|
2075
|
-
["marketAuthority", (0,
|
|
2076
|
-
["mint", (0,
|
|
2077
|
-
["earlinessCutoffSeconds", (0,
|
|
2078
|
-
["earlinessMultiplier", (0,
|
|
2079
|
-
["
|
|
2080
|
-
["authorizedReaderPubkey", (0, import_kit50.getArrayEncoder)((0, import_kit50.getU8Encoder)(), { size: 32 })],
|
|
2112
|
+
return (0, import_kit51.transformEncoder)(
|
|
2113
|
+
(0, import_kit51.getStructEncoder)([
|
|
2114
|
+
["discriminator", (0, import_kit51.fixEncoderSize)((0, import_kit51.getBytesEncoder)(), 8)],
|
|
2115
|
+
["bump", (0, import_kit51.getU8Encoder)()],
|
|
2116
|
+
["creator", (0, import_kit51.getAddressEncoder)()],
|
|
2117
|
+
["index", (0, import_kit51.getU64Encoder)()],
|
|
2118
|
+
["totalOptions", (0, import_kit51.getU64Encoder)()],
|
|
2119
|
+
["platform", (0, import_kit51.getAddressEncoder)()],
|
|
2120
|
+
["stakeEndTimestamp", (0, import_kit51.getOptionEncoder)((0, import_kit51.getU64Encoder)())],
|
|
2121
|
+
["resolvedAtTimestamp", (0, import_kit51.getOptionEncoder)((0, import_kit51.getU64Encoder)())],
|
|
2122
|
+
["winningOptionAllocation", (0, import_kit51.getU16Encoder)()],
|
|
2123
|
+
["winningOptionActiveBp", (0, import_kit51.getU16Encoder)()],
|
|
2124
|
+
["rewardAmount", (0, import_kit51.getU64Encoder)()],
|
|
2125
|
+
["marketAuthority", (0, import_kit51.getAddressEncoder)()],
|
|
2126
|
+
["mint", (0, import_kit51.getAddressEncoder)()],
|
|
2127
|
+
["earlinessCutoffSeconds", (0, import_kit51.getU64Encoder)()],
|
|
2128
|
+
["earlinessMultiplier", (0, import_kit51.getU16Encoder)()],
|
|
2129
|
+
["authorizedReaderPubkey", (0, import_kit51.getArrayEncoder)((0, import_kit51.getU8Encoder)(), { size: 32 })],
|
|
2081
2130
|
["feeRates", getFeeRatesEncoder()],
|
|
2082
|
-
["collectedPlatformFees", (0,
|
|
2083
|
-
["collectedCreatorFees", (0,
|
|
2084
|
-
["creatorFeeClaimer", (0,
|
|
2085
|
-
["marketResolutionDeadlineSeconds", (0,
|
|
2086
|
-
["revealPeriodSeconds", (0,
|
|
2087
|
-
["revealEnded", (0,
|
|
2088
|
-
["minStakeAmount", (0,
|
|
2131
|
+
["collectedPlatformFees", (0, import_kit51.getU64Encoder)()],
|
|
2132
|
+
["collectedCreatorFees", (0, import_kit51.getU64Encoder)()],
|
|
2133
|
+
["creatorFeeClaimer", (0, import_kit51.getAddressEncoder)()],
|
|
2134
|
+
["marketResolutionDeadlineSeconds", (0, import_kit51.getU64Encoder)()],
|
|
2135
|
+
["revealPeriodSeconds", (0, import_kit51.getU64Encoder)()],
|
|
2136
|
+
["revealEnded", (0, import_kit51.getBooleanEncoder)()],
|
|
2137
|
+
["minStakeAmount", (0, import_kit51.getU64Encoder)()]
|
|
2089
2138
|
]),
|
|
2090
2139
|
(value) => ({ ...value, discriminator: OPPORTUNITY_MARKET_DISCRIMINATOR })
|
|
2091
2140
|
);
|
|
2092
2141
|
}
|
|
2093
2142
|
function getOpportunityMarketDecoder() {
|
|
2094
|
-
return (0,
|
|
2095
|
-
["discriminator", (0,
|
|
2096
|
-
["bump", (0,
|
|
2097
|
-
["creator", (0,
|
|
2098
|
-
["index", (0,
|
|
2099
|
-
["totalOptions", (0,
|
|
2100
|
-
["platform", (0,
|
|
2101
|
-
["stakeEndTimestamp", (0,
|
|
2102
|
-
["resolvedAtTimestamp", (0,
|
|
2103
|
-
["winningOptionAllocation", (0,
|
|
2104
|
-
["winningOptionActiveBp", (0,
|
|
2105
|
-
["rewardAmount", (0,
|
|
2106
|
-
["marketAuthority", (0,
|
|
2107
|
-
["mint", (0,
|
|
2108
|
-
["earlinessCutoffSeconds", (0,
|
|
2109
|
-
["earlinessMultiplier", (0,
|
|
2110
|
-
["
|
|
2111
|
-
["authorizedReaderPubkey", (0, import_kit50.getArrayDecoder)((0, import_kit50.getU8Decoder)(), { size: 32 })],
|
|
2143
|
+
return (0, import_kit51.getStructDecoder)([
|
|
2144
|
+
["discriminator", (0, import_kit51.fixDecoderSize)((0, import_kit51.getBytesDecoder)(), 8)],
|
|
2145
|
+
["bump", (0, import_kit51.getU8Decoder)()],
|
|
2146
|
+
["creator", (0, import_kit51.getAddressDecoder)()],
|
|
2147
|
+
["index", (0, import_kit51.getU64Decoder)()],
|
|
2148
|
+
["totalOptions", (0, import_kit51.getU64Decoder)()],
|
|
2149
|
+
["platform", (0, import_kit51.getAddressDecoder)()],
|
|
2150
|
+
["stakeEndTimestamp", (0, import_kit51.getOptionDecoder)((0, import_kit51.getU64Decoder)())],
|
|
2151
|
+
["resolvedAtTimestamp", (0, import_kit51.getOptionDecoder)((0, import_kit51.getU64Decoder)())],
|
|
2152
|
+
["winningOptionAllocation", (0, import_kit51.getU16Decoder)()],
|
|
2153
|
+
["winningOptionActiveBp", (0, import_kit51.getU16Decoder)()],
|
|
2154
|
+
["rewardAmount", (0, import_kit51.getU64Decoder)()],
|
|
2155
|
+
["marketAuthority", (0, import_kit51.getAddressDecoder)()],
|
|
2156
|
+
["mint", (0, import_kit51.getAddressDecoder)()],
|
|
2157
|
+
["earlinessCutoffSeconds", (0, import_kit51.getU64Decoder)()],
|
|
2158
|
+
["earlinessMultiplier", (0, import_kit51.getU16Decoder)()],
|
|
2159
|
+
["authorizedReaderPubkey", (0, import_kit51.getArrayDecoder)((0, import_kit51.getU8Decoder)(), { size: 32 })],
|
|
2112
2160
|
["feeRates", getFeeRatesDecoder()],
|
|
2113
|
-
["collectedPlatformFees", (0,
|
|
2114
|
-
["collectedCreatorFees", (0,
|
|
2115
|
-
["creatorFeeClaimer", (0,
|
|
2116
|
-
["marketResolutionDeadlineSeconds", (0,
|
|
2117
|
-
["revealPeriodSeconds", (0,
|
|
2118
|
-
["revealEnded", (0,
|
|
2119
|
-
["minStakeAmount", (0,
|
|
2161
|
+
["collectedPlatformFees", (0, import_kit51.getU64Decoder)()],
|
|
2162
|
+
["collectedCreatorFees", (0, import_kit51.getU64Decoder)()],
|
|
2163
|
+
["creatorFeeClaimer", (0, import_kit51.getAddressDecoder)()],
|
|
2164
|
+
["marketResolutionDeadlineSeconds", (0, import_kit51.getU64Decoder)()],
|
|
2165
|
+
["revealPeriodSeconds", (0, import_kit51.getU64Decoder)()],
|
|
2166
|
+
["revealEnded", (0, import_kit51.getBooleanDecoder)()],
|
|
2167
|
+
["minStakeAmount", (0, import_kit51.getU64Decoder)()]
|
|
2120
2168
|
]);
|
|
2121
2169
|
}
|
|
2122
2170
|
function getOpportunityMarketCodec() {
|
|
2123
|
-
return (0,
|
|
2171
|
+
return (0, import_kit51.combineCodec)(
|
|
2124
2172
|
getOpportunityMarketEncoder(),
|
|
2125
2173
|
getOpportunityMarketDecoder()
|
|
2126
2174
|
);
|
|
2127
2175
|
}
|
|
2128
2176
|
function decodeOpportunityMarket(encodedAccount) {
|
|
2129
|
-
return (0,
|
|
2177
|
+
return (0, import_kit51.decodeAccount)(
|
|
2130
2178
|
encodedAccount,
|
|
2131
2179
|
getOpportunityMarketDecoder()
|
|
2132
2180
|
);
|
|
2133
2181
|
}
|
|
2134
2182
|
async function fetchOpportunityMarket(rpc, address3, config) {
|
|
2135
2183
|
const maybeAccount = await fetchMaybeOpportunityMarket(rpc, address3, config);
|
|
2136
|
-
(0,
|
|
2184
|
+
(0, import_kit51.assertAccountExists)(maybeAccount);
|
|
2137
2185
|
return maybeAccount;
|
|
2138
2186
|
}
|
|
2139
2187
|
async function fetchMaybeOpportunityMarket(rpc, address3, config) {
|
|
2140
|
-
const maybeAccount = await (0,
|
|
2188
|
+
const maybeAccount = await (0, import_kit51.fetchEncodedAccount)(rpc, address3, config);
|
|
2141
2189
|
return decodeOpportunityMarket(maybeAccount);
|
|
2142
2190
|
}
|
|
2143
2191
|
async function fetchAllOpportunityMarket(rpc, addresses, config) {
|
|
@@ -2146,18 +2194,18 @@ async function fetchAllOpportunityMarket(rpc, addresses, config) {
|
|
|
2146
2194
|
addresses,
|
|
2147
2195
|
config
|
|
2148
2196
|
);
|
|
2149
|
-
(0,
|
|
2197
|
+
(0, import_kit51.assertAccountsExist)(maybeAccounts);
|
|
2150
2198
|
return maybeAccounts;
|
|
2151
2199
|
}
|
|
2152
2200
|
async function fetchAllMaybeOpportunityMarket(rpc, addresses, config) {
|
|
2153
|
-
const maybeAccounts = await (0,
|
|
2201
|
+
const maybeAccounts = await (0, import_kit51.fetchEncodedAccounts)(rpc, addresses, config);
|
|
2154
2202
|
return maybeAccounts.map(
|
|
2155
2203
|
(maybeAccount) => decodeOpportunityMarket(maybeAccount)
|
|
2156
2204
|
);
|
|
2157
2205
|
}
|
|
2158
2206
|
|
|
2159
2207
|
// src/generated/accounts/opportunityMarketOption.ts
|
|
2160
|
-
var
|
|
2208
|
+
var import_kit52 = require("@solana/kit");
|
|
2161
2209
|
var OPPORTUNITY_MARKET_OPTION_DISCRIMINATOR = new Uint8Array([
|
|
2162
2210
|
220,
|
|
2163
2211
|
236,
|
|
@@ -2169,22 +2217,22 @@ var OPPORTUNITY_MARKET_OPTION_DISCRIMINATOR = new Uint8Array([
|
|
|
2169
2217
|
64
|
|
2170
2218
|
]);
|
|
2171
2219
|
function getOpportunityMarketOptionDiscriminatorBytes() {
|
|
2172
|
-
return (0,
|
|
2220
|
+
return (0, import_kit52.fixEncoderSize)((0, import_kit52.getBytesEncoder)(), 8).encode(
|
|
2173
2221
|
OPPORTUNITY_MARKET_OPTION_DISCRIMINATOR
|
|
2174
2222
|
);
|
|
2175
2223
|
}
|
|
2176
2224
|
function getOpportunityMarketOptionEncoder() {
|
|
2177
|
-
return (0,
|
|
2178
|
-
(0,
|
|
2179
|
-
["discriminator", (0,
|
|
2180
|
-
["bump", (0,
|
|
2181
|
-
["id", (0,
|
|
2182
|
-
["creator", (0,
|
|
2183
|
-
["createdAt", (0,
|
|
2184
|
-
["
|
|
2185
|
-
["totalScore", (0,
|
|
2186
|
-
["rewardBp", (0,
|
|
2187
|
-
["includedInActiveBp", (0,
|
|
2225
|
+
return (0, import_kit52.transformEncoder)(
|
|
2226
|
+
(0, import_kit52.getStructEncoder)([
|
|
2227
|
+
["discriminator", (0, import_kit52.fixEncoderSize)((0, import_kit52.getBytesEncoder)(), 8)],
|
|
2228
|
+
["bump", (0, import_kit52.getU8Encoder)()],
|
|
2229
|
+
["id", (0, import_kit52.getU64Encoder)()],
|
|
2230
|
+
["creator", (0, import_kit52.getAddressEncoder)()],
|
|
2231
|
+
["createdAt", (0, import_kit52.getU64Encoder)()],
|
|
2232
|
+
["unclaimedStake", (0, import_kit52.getU64Encoder)()],
|
|
2233
|
+
["totalScore", (0, import_kit52.getU128Encoder)()],
|
|
2234
|
+
["rewardBp", (0, import_kit52.getU16Encoder)()],
|
|
2235
|
+
["includedInActiveBp", (0, import_kit52.getBooleanEncoder)()]
|
|
2188
2236
|
]),
|
|
2189
2237
|
(value) => ({
|
|
2190
2238
|
...value,
|
|
@@ -2193,26 +2241,26 @@ function getOpportunityMarketOptionEncoder() {
|
|
|
2193
2241
|
);
|
|
2194
2242
|
}
|
|
2195
2243
|
function getOpportunityMarketOptionDecoder() {
|
|
2196
|
-
return (0,
|
|
2197
|
-
["discriminator", (0,
|
|
2198
|
-
["bump", (0,
|
|
2199
|
-
["id", (0,
|
|
2200
|
-
["creator", (0,
|
|
2201
|
-
["createdAt", (0,
|
|
2202
|
-
["
|
|
2203
|
-
["totalScore", (0,
|
|
2204
|
-
["rewardBp", (0,
|
|
2205
|
-
["includedInActiveBp", (0,
|
|
2244
|
+
return (0, import_kit52.getStructDecoder)([
|
|
2245
|
+
["discriminator", (0, import_kit52.fixDecoderSize)((0, import_kit52.getBytesDecoder)(), 8)],
|
|
2246
|
+
["bump", (0, import_kit52.getU8Decoder)()],
|
|
2247
|
+
["id", (0, import_kit52.getU64Decoder)()],
|
|
2248
|
+
["creator", (0, import_kit52.getAddressDecoder)()],
|
|
2249
|
+
["createdAt", (0, import_kit52.getU64Decoder)()],
|
|
2250
|
+
["unclaimedStake", (0, import_kit52.getU64Decoder)()],
|
|
2251
|
+
["totalScore", (0, import_kit52.getU128Decoder)()],
|
|
2252
|
+
["rewardBp", (0, import_kit52.getU16Decoder)()],
|
|
2253
|
+
["includedInActiveBp", (0, import_kit52.getBooleanDecoder)()]
|
|
2206
2254
|
]);
|
|
2207
2255
|
}
|
|
2208
2256
|
function getOpportunityMarketOptionCodec() {
|
|
2209
|
-
return (0,
|
|
2257
|
+
return (0, import_kit52.combineCodec)(
|
|
2210
2258
|
getOpportunityMarketOptionEncoder(),
|
|
2211
2259
|
getOpportunityMarketOptionDecoder()
|
|
2212
2260
|
);
|
|
2213
2261
|
}
|
|
2214
2262
|
function decodeOpportunityMarketOption(encodedAccount) {
|
|
2215
|
-
return (0,
|
|
2263
|
+
return (0, import_kit52.decodeAccount)(
|
|
2216
2264
|
encodedAccount,
|
|
2217
2265
|
getOpportunityMarketOptionDecoder()
|
|
2218
2266
|
);
|
|
@@ -2223,11 +2271,11 @@ async function fetchOpportunityMarketOption(rpc, address3, config) {
|
|
|
2223
2271
|
address3,
|
|
2224
2272
|
config
|
|
2225
2273
|
);
|
|
2226
|
-
(0,
|
|
2274
|
+
(0, import_kit52.assertAccountExists)(maybeAccount);
|
|
2227
2275
|
return maybeAccount;
|
|
2228
2276
|
}
|
|
2229
2277
|
async function fetchMaybeOpportunityMarketOption(rpc, address3, config) {
|
|
2230
|
-
const maybeAccount = await (0,
|
|
2278
|
+
const maybeAccount = await (0, import_kit52.fetchEncodedAccount)(rpc, address3, config);
|
|
2231
2279
|
return decodeOpportunityMarketOption(maybeAccount);
|
|
2232
2280
|
}
|
|
2233
2281
|
async function fetchAllOpportunityMarketOption(rpc, addresses, config) {
|
|
@@ -2236,18 +2284,18 @@ async function fetchAllOpportunityMarketOption(rpc, addresses, config) {
|
|
|
2236
2284
|
addresses,
|
|
2237
2285
|
config
|
|
2238
2286
|
);
|
|
2239
|
-
(0,
|
|
2287
|
+
(0, import_kit52.assertAccountsExist)(maybeAccounts);
|
|
2240
2288
|
return maybeAccounts;
|
|
2241
2289
|
}
|
|
2242
2290
|
async function fetchAllMaybeOpportunityMarketOption(rpc, addresses, config) {
|
|
2243
|
-
const maybeAccounts = await (0,
|
|
2291
|
+
const maybeAccounts = await (0, import_kit52.fetchEncodedAccounts)(rpc, addresses, config);
|
|
2244
2292
|
return maybeAccounts.map(
|
|
2245
2293
|
(maybeAccount) => decodeOpportunityMarketOption(maybeAccount)
|
|
2246
2294
|
);
|
|
2247
2295
|
}
|
|
2248
2296
|
|
|
2249
2297
|
// src/generated/accounts/opportunityMarketSponsor.ts
|
|
2250
|
-
var
|
|
2298
|
+
var import_kit53 = require("@solana/kit");
|
|
2251
2299
|
var OPPORTUNITY_MARKET_SPONSOR_DISCRIMINATOR = new Uint8Array([
|
|
2252
2300
|
207,
|
|
2253
2301
|
139,
|
|
@@ -2259,19 +2307,18 @@ var OPPORTUNITY_MARKET_SPONSOR_DISCRIMINATOR = new Uint8Array([
|
|
|
2259
2307
|
192
|
|
2260
2308
|
]);
|
|
2261
2309
|
function getOpportunityMarketSponsorDiscriminatorBytes() {
|
|
2262
|
-
return (0,
|
|
2310
|
+
return (0, import_kit53.fixEncoderSize)((0, import_kit53.getBytesEncoder)(), 8).encode(
|
|
2263
2311
|
OPPORTUNITY_MARKET_SPONSOR_DISCRIMINATOR
|
|
2264
2312
|
);
|
|
2265
2313
|
}
|
|
2266
2314
|
function getOpportunityMarketSponsorEncoder() {
|
|
2267
|
-
return (0,
|
|
2268
|
-
(0,
|
|
2269
|
-
["discriminator", (0,
|
|
2270
|
-
["bump", (0,
|
|
2271
|
-
["sponsor", (0,
|
|
2272
|
-
["market", (0,
|
|
2273
|
-
["rewardDeposited", (0,
|
|
2274
|
-
["rewardLocked", (0, import_kit52.getBooleanEncoder)()]
|
|
2315
|
+
return (0, import_kit53.transformEncoder)(
|
|
2316
|
+
(0, import_kit53.getStructEncoder)([
|
|
2317
|
+
["discriminator", (0, import_kit53.fixEncoderSize)((0, import_kit53.getBytesEncoder)(), 8)],
|
|
2318
|
+
["bump", (0, import_kit53.getU8Encoder)()],
|
|
2319
|
+
["sponsor", (0, import_kit53.getAddressEncoder)()],
|
|
2320
|
+
["market", (0, import_kit53.getAddressEncoder)()],
|
|
2321
|
+
["rewardDeposited", (0, import_kit53.getU64Encoder)()]
|
|
2275
2322
|
]),
|
|
2276
2323
|
(value) => ({
|
|
2277
2324
|
...value,
|
|
@@ -2280,23 +2327,22 @@ function getOpportunityMarketSponsorEncoder() {
|
|
|
2280
2327
|
);
|
|
2281
2328
|
}
|
|
2282
2329
|
function getOpportunityMarketSponsorDecoder() {
|
|
2283
|
-
return (0,
|
|
2284
|
-
["discriminator", (0,
|
|
2285
|
-
["bump", (0,
|
|
2286
|
-
["sponsor", (0,
|
|
2287
|
-
["market", (0,
|
|
2288
|
-
["rewardDeposited", (0,
|
|
2289
|
-
["rewardLocked", (0, import_kit52.getBooleanDecoder)()]
|
|
2330
|
+
return (0, import_kit53.getStructDecoder)([
|
|
2331
|
+
["discriminator", (0, import_kit53.fixDecoderSize)((0, import_kit53.getBytesDecoder)(), 8)],
|
|
2332
|
+
["bump", (0, import_kit53.getU8Decoder)()],
|
|
2333
|
+
["sponsor", (0, import_kit53.getAddressDecoder)()],
|
|
2334
|
+
["market", (0, import_kit53.getAddressDecoder)()],
|
|
2335
|
+
["rewardDeposited", (0, import_kit53.getU64Decoder)()]
|
|
2290
2336
|
]);
|
|
2291
2337
|
}
|
|
2292
2338
|
function getOpportunityMarketSponsorCodec() {
|
|
2293
|
-
return (0,
|
|
2339
|
+
return (0, import_kit53.combineCodec)(
|
|
2294
2340
|
getOpportunityMarketSponsorEncoder(),
|
|
2295
2341
|
getOpportunityMarketSponsorDecoder()
|
|
2296
2342
|
);
|
|
2297
2343
|
}
|
|
2298
2344
|
function decodeOpportunityMarketSponsor(encodedAccount) {
|
|
2299
|
-
return (0,
|
|
2345
|
+
return (0, import_kit53.decodeAccount)(
|
|
2300
2346
|
encodedAccount,
|
|
2301
2347
|
getOpportunityMarketSponsorDecoder()
|
|
2302
2348
|
);
|
|
@@ -2307,11 +2353,11 @@ async function fetchOpportunityMarketSponsor(rpc, address3, config) {
|
|
|
2307
2353
|
address3,
|
|
2308
2354
|
config
|
|
2309
2355
|
);
|
|
2310
|
-
(0,
|
|
2356
|
+
(0, import_kit53.assertAccountExists)(maybeAccount);
|
|
2311
2357
|
return maybeAccount;
|
|
2312
2358
|
}
|
|
2313
2359
|
async function fetchMaybeOpportunityMarketSponsor(rpc, address3, config) {
|
|
2314
|
-
const maybeAccount = await (0,
|
|
2360
|
+
const maybeAccount = await (0, import_kit53.fetchEncodedAccount)(rpc, address3, config);
|
|
2315
2361
|
return decodeOpportunityMarketSponsor(maybeAccount);
|
|
2316
2362
|
}
|
|
2317
2363
|
async function fetchAllOpportunityMarketSponsor(rpc, addresses, config) {
|
|
@@ -2320,18 +2366,18 @@ async function fetchAllOpportunityMarketSponsor(rpc, addresses, config) {
|
|
|
2320
2366
|
addresses,
|
|
2321
2367
|
config
|
|
2322
2368
|
);
|
|
2323
|
-
(0,
|
|
2369
|
+
(0, import_kit53.assertAccountsExist)(maybeAccounts);
|
|
2324
2370
|
return maybeAccounts;
|
|
2325
2371
|
}
|
|
2326
2372
|
async function fetchAllMaybeOpportunityMarketSponsor(rpc, addresses, config) {
|
|
2327
|
-
const maybeAccounts = await (0,
|
|
2373
|
+
const maybeAccounts = await (0, import_kit53.fetchEncodedAccounts)(rpc, addresses, config);
|
|
2328
2374
|
return maybeAccounts.map(
|
|
2329
2375
|
(maybeAccount) => decodeOpportunityMarketSponsor(maybeAccount)
|
|
2330
2376
|
);
|
|
2331
2377
|
}
|
|
2332
2378
|
|
|
2333
2379
|
// src/generated/accounts/platformConfig.ts
|
|
2334
|
-
var
|
|
2380
|
+
var import_kit54 = require("@solana/kit");
|
|
2335
2381
|
var PLATFORM_CONFIG_DISCRIMINATOR = new Uint8Array([
|
|
2336
2382
|
160,
|
|
2337
2383
|
78,
|
|
@@ -2343,57 +2389,57 @@ var PLATFORM_CONFIG_DISCRIMINATOR = new Uint8Array([
|
|
|
2343
2389
|
160
|
|
2344
2390
|
]);
|
|
2345
2391
|
function getPlatformConfigDiscriminatorBytes() {
|
|
2346
|
-
return (0,
|
|
2392
|
+
return (0, import_kit54.fixEncoderSize)((0, import_kit54.getBytesEncoder)(), 8).encode(
|
|
2347
2393
|
PLATFORM_CONFIG_DISCRIMINATOR
|
|
2348
2394
|
);
|
|
2349
2395
|
}
|
|
2350
2396
|
function getPlatformConfigEncoder() {
|
|
2351
|
-
return (0,
|
|
2352
|
-
(0,
|
|
2353
|
-
["discriminator", (0,
|
|
2354
|
-
["bump", (0,
|
|
2355
|
-
["name", (0,
|
|
2356
|
-
["updateAuthority", (0,
|
|
2357
|
-
["feeClaimAuthority", (0,
|
|
2397
|
+
return (0, import_kit54.transformEncoder)(
|
|
2398
|
+
(0, import_kit54.getStructEncoder)([
|
|
2399
|
+
["discriminator", (0, import_kit54.fixEncoderSize)((0, import_kit54.getBytesEncoder)(), 8)],
|
|
2400
|
+
["bump", (0, import_kit54.getU8Encoder)()],
|
|
2401
|
+
["name", (0, import_kit54.addEncoderSizePrefix)((0, import_kit54.getUtf8Encoder)(), (0, import_kit54.getU32Encoder)())],
|
|
2402
|
+
["updateAuthority", (0, import_kit54.getAddressEncoder)()],
|
|
2403
|
+
["feeClaimAuthority", (0, import_kit54.getAddressEncoder)()],
|
|
2358
2404
|
["feeRates", getFeeRatesEncoder()],
|
|
2359
|
-
["marketResolutionDeadlineSeconds", (0,
|
|
2360
|
-
["minTimeToStakeSeconds", (0,
|
|
2361
|
-
["revealAuthority", (0,
|
|
2362
|
-
["revealPeriodSeconds", (0,
|
|
2405
|
+
["marketResolutionDeadlineSeconds", (0, import_kit54.getU64Encoder)()],
|
|
2406
|
+
["minTimeToStakeSeconds", (0, import_kit54.getU64Encoder)()],
|
|
2407
|
+
["revealAuthority", (0, import_kit54.getAddressEncoder)()],
|
|
2408
|
+
["revealPeriodSeconds", (0, import_kit54.getU64Encoder)()]
|
|
2363
2409
|
]),
|
|
2364
2410
|
(value) => ({ ...value, discriminator: PLATFORM_CONFIG_DISCRIMINATOR })
|
|
2365
2411
|
);
|
|
2366
2412
|
}
|
|
2367
2413
|
function getPlatformConfigDecoder() {
|
|
2368
|
-
return (0,
|
|
2369
|
-
["discriminator", (0,
|
|
2370
|
-
["bump", (0,
|
|
2371
|
-
["name", (0,
|
|
2372
|
-
["updateAuthority", (0,
|
|
2373
|
-
["feeClaimAuthority", (0,
|
|
2414
|
+
return (0, import_kit54.getStructDecoder)([
|
|
2415
|
+
["discriminator", (0, import_kit54.fixDecoderSize)((0, import_kit54.getBytesDecoder)(), 8)],
|
|
2416
|
+
["bump", (0, import_kit54.getU8Decoder)()],
|
|
2417
|
+
["name", (0, import_kit54.addDecoderSizePrefix)((0, import_kit54.getUtf8Decoder)(), (0, import_kit54.getU32Decoder)())],
|
|
2418
|
+
["updateAuthority", (0, import_kit54.getAddressDecoder)()],
|
|
2419
|
+
["feeClaimAuthority", (0, import_kit54.getAddressDecoder)()],
|
|
2374
2420
|
["feeRates", getFeeRatesDecoder()],
|
|
2375
|
-
["marketResolutionDeadlineSeconds", (0,
|
|
2376
|
-
["minTimeToStakeSeconds", (0,
|
|
2377
|
-
["revealAuthority", (0,
|
|
2378
|
-
["revealPeriodSeconds", (0,
|
|
2421
|
+
["marketResolutionDeadlineSeconds", (0, import_kit54.getU64Decoder)()],
|
|
2422
|
+
["minTimeToStakeSeconds", (0, import_kit54.getU64Decoder)()],
|
|
2423
|
+
["revealAuthority", (0, import_kit54.getAddressDecoder)()],
|
|
2424
|
+
["revealPeriodSeconds", (0, import_kit54.getU64Decoder)()]
|
|
2379
2425
|
]);
|
|
2380
2426
|
}
|
|
2381
2427
|
function getPlatformConfigCodec() {
|
|
2382
|
-
return (0,
|
|
2428
|
+
return (0, import_kit54.combineCodec)(getPlatformConfigEncoder(), getPlatformConfigDecoder());
|
|
2383
2429
|
}
|
|
2384
2430
|
function decodePlatformConfig(encodedAccount) {
|
|
2385
|
-
return (0,
|
|
2431
|
+
return (0, import_kit54.decodeAccount)(
|
|
2386
2432
|
encodedAccount,
|
|
2387
2433
|
getPlatformConfigDecoder()
|
|
2388
2434
|
);
|
|
2389
2435
|
}
|
|
2390
2436
|
async function fetchPlatformConfig(rpc, address3, config) {
|
|
2391
2437
|
const maybeAccount = await fetchMaybePlatformConfig(rpc, address3, config);
|
|
2392
|
-
(0,
|
|
2438
|
+
(0, import_kit54.assertAccountExists)(maybeAccount);
|
|
2393
2439
|
return maybeAccount;
|
|
2394
2440
|
}
|
|
2395
2441
|
async function fetchMaybePlatformConfig(rpc, address3, config) {
|
|
2396
|
-
const maybeAccount = await (0,
|
|
2442
|
+
const maybeAccount = await (0, import_kit54.fetchEncodedAccount)(rpc, address3, config);
|
|
2397
2443
|
return decodePlatformConfig(maybeAccount);
|
|
2398
2444
|
}
|
|
2399
2445
|
async function fetchAllPlatformConfig(rpc, addresses, config) {
|
|
@@ -2402,18 +2448,18 @@ async function fetchAllPlatformConfig(rpc, addresses, config) {
|
|
|
2402
2448
|
addresses,
|
|
2403
2449
|
config
|
|
2404
2450
|
);
|
|
2405
|
-
(0,
|
|
2451
|
+
(0, import_kit54.assertAccountsExist)(maybeAccounts);
|
|
2406
2452
|
return maybeAccounts;
|
|
2407
2453
|
}
|
|
2408
2454
|
async function fetchAllMaybePlatformConfig(rpc, addresses, config) {
|
|
2409
|
-
const maybeAccounts = await (0,
|
|
2455
|
+
const maybeAccounts = await (0, import_kit54.fetchEncodedAccounts)(rpc, addresses, config);
|
|
2410
2456
|
return maybeAccounts.map(
|
|
2411
2457
|
(maybeAccount) => decodePlatformConfig(maybeAccount)
|
|
2412
2458
|
);
|
|
2413
2459
|
}
|
|
2414
2460
|
|
|
2415
2461
|
// src/generated/accounts/stakeAccount.ts
|
|
2416
|
-
var
|
|
2462
|
+
var import_kit55 = require("@solana/kit");
|
|
2417
2463
|
var STAKE_ACCOUNT_DISCRIMINATOR = new Uint8Array([
|
|
2418
2464
|
80,
|
|
2419
2465
|
158,
|
|
@@ -2425,99 +2471,101 @@ var STAKE_ACCOUNT_DISCRIMINATOR = new Uint8Array([
|
|
|
2425
2471
|
255
|
|
2426
2472
|
]);
|
|
2427
2473
|
function getStakeAccountDiscriminatorBytes() {
|
|
2428
|
-
return (0,
|
|
2474
|
+
return (0, import_kit55.fixEncoderSize)((0, import_kit55.getBytesEncoder)(), 8).encode(
|
|
2429
2475
|
STAKE_ACCOUNT_DISCRIMINATOR
|
|
2430
2476
|
);
|
|
2431
2477
|
}
|
|
2432
2478
|
function getStakeAccountEncoder() {
|
|
2433
|
-
return (0,
|
|
2434
|
-
(0,
|
|
2435
|
-
["discriminator", (0,
|
|
2436
|
-
["encryptedOption", (0,
|
|
2437
|
-
["stateNonce", (0,
|
|
2438
|
-
["bump", (0,
|
|
2439
|
-
["owner", (0,
|
|
2440
|
-
["market", (0,
|
|
2441
|
-
["userPubkey", (0,
|
|
2479
|
+
return (0, import_kit55.transformEncoder)(
|
|
2480
|
+
(0, import_kit55.getStructEncoder)([
|
|
2481
|
+
["discriminator", (0, import_kit55.fixEncoderSize)((0, import_kit55.getBytesEncoder)(), 8)],
|
|
2482
|
+
["encryptedOption", (0, import_kit55.getArrayEncoder)((0, import_kit55.getU8Encoder)(), { size: 32 })],
|
|
2483
|
+
["stateNonce", (0, import_kit55.getU128Encoder)()],
|
|
2484
|
+
["bump", (0, import_kit55.getU8Encoder)()],
|
|
2485
|
+
["owner", (0, import_kit55.getAddressEncoder)()],
|
|
2486
|
+
["market", (0, import_kit55.getAddressEncoder)()],
|
|
2487
|
+
["userPubkey", (0, import_kit55.getArrayEncoder)((0, import_kit55.getU8Encoder)(), { size: 32 })],
|
|
2442
2488
|
[
|
|
2443
2489
|
"encryptedOptionDisclosure",
|
|
2444
|
-
(0,
|
|
2490
|
+
(0, import_kit55.getArrayEncoder)((0, import_kit55.getU8Encoder)(), { size: 32 })
|
|
2445
2491
|
],
|
|
2446
|
-
["stateNonceDisclosure", (0,
|
|
2447
|
-
["stakedAtTimestamp", (0,
|
|
2448
|
-
["unstakedAtTimestamp", (0,
|
|
2449
|
-
["amount", (0,
|
|
2492
|
+
["stateNonceDisclosure", (0, import_kit55.getU128Encoder)()],
|
|
2493
|
+
["stakedAtTimestamp", (0, import_kit55.getOptionEncoder)((0, import_kit55.getU64Encoder)())],
|
|
2494
|
+
["unstakedAtTimestamp", (0, import_kit55.getOptionEncoder)((0, import_kit55.getU64Encoder)())],
|
|
2495
|
+
["amount", (0, import_kit55.getU64Encoder)()],
|
|
2450
2496
|
["collectedFees", getCollectedFeesEncoder()],
|
|
2451
|
-
["revealedOption", (0,
|
|
2452
|
-
["score", (0,
|
|
2453
|
-
["unstaked", (0,
|
|
2454
|
-
["
|
|
2455
|
-
["
|
|
2456
|
-
["
|
|
2497
|
+
["revealedOption", (0, import_kit55.getOptionEncoder)((0, import_kit55.getU64Encoder)())],
|
|
2498
|
+
["score", (0, import_kit55.getOptionEncoder)((0, import_kit55.getU64Encoder)())],
|
|
2499
|
+
["unstaked", (0, import_kit55.getBooleanEncoder)()],
|
|
2500
|
+
["rewardsClaimed", (0, import_kit55.getBooleanEncoder)()],
|
|
2501
|
+
["id", (0, import_kit55.getU32Encoder)()],
|
|
2502
|
+
["pendingStakeComputation", (0, import_kit55.getOptionEncoder)((0, import_kit55.getAddressEncoder)())],
|
|
2503
|
+
["pendingReveal", (0, import_kit55.getBooleanEncoder)()]
|
|
2457
2504
|
]),
|
|
2458
2505
|
(value) => ({ ...value, discriminator: STAKE_ACCOUNT_DISCRIMINATOR })
|
|
2459
2506
|
);
|
|
2460
2507
|
}
|
|
2461
2508
|
function getStakeAccountDecoder() {
|
|
2462
|
-
return (0,
|
|
2463
|
-
["discriminator", (0,
|
|
2464
|
-
["encryptedOption", (0,
|
|
2465
|
-
["stateNonce", (0,
|
|
2466
|
-
["bump", (0,
|
|
2467
|
-
["owner", (0,
|
|
2468
|
-
["market", (0,
|
|
2469
|
-
["userPubkey", (0,
|
|
2509
|
+
return (0, import_kit55.getStructDecoder)([
|
|
2510
|
+
["discriminator", (0, import_kit55.fixDecoderSize)((0, import_kit55.getBytesDecoder)(), 8)],
|
|
2511
|
+
["encryptedOption", (0, import_kit55.getArrayDecoder)((0, import_kit55.getU8Decoder)(), { size: 32 })],
|
|
2512
|
+
["stateNonce", (0, import_kit55.getU128Decoder)()],
|
|
2513
|
+
["bump", (0, import_kit55.getU8Decoder)()],
|
|
2514
|
+
["owner", (0, import_kit55.getAddressDecoder)()],
|
|
2515
|
+
["market", (0, import_kit55.getAddressDecoder)()],
|
|
2516
|
+
["userPubkey", (0, import_kit55.getArrayDecoder)((0, import_kit55.getU8Decoder)(), { size: 32 })],
|
|
2470
2517
|
[
|
|
2471
2518
|
"encryptedOptionDisclosure",
|
|
2472
|
-
(0,
|
|
2519
|
+
(0, import_kit55.getArrayDecoder)((0, import_kit55.getU8Decoder)(), { size: 32 })
|
|
2473
2520
|
],
|
|
2474
|
-
["stateNonceDisclosure", (0,
|
|
2475
|
-
["stakedAtTimestamp", (0,
|
|
2476
|
-
["unstakedAtTimestamp", (0,
|
|
2477
|
-
["amount", (0,
|
|
2521
|
+
["stateNonceDisclosure", (0, import_kit55.getU128Decoder)()],
|
|
2522
|
+
["stakedAtTimestamp", (0, import_kit55.getOptionDecoder)((0, import_kit55.getU64Decoder)())],
|
|
2523
|
+
["unstakedAtTimestamp", (0, import_kit55.getOptionDecoder)((0, import_kit55.getU64Decoder)())],
|
|
2524
|
+
["amount", (0, import_kit55.getU64Decoder)()],
|
|
2478
2525
|
["collectedFees", getCollectedFeesDecoder()],
|
|
2479
|
-
["revealedOption", (0,
|
|
2480
|
-
["score", (0,
|
|
2481
|
-
["unstaked", (0,
|
|
2482
|
-
["
|
|
2483
|
-
["
|
|
2484
|
-
["
|
|
2526
|
+
["revealedOption", (0, import_kit55.getOptionDecoder)((0, import_kit55.getU64Decoder)())],
|
|
2527
|
+
["score", (0, import_kit55.getOptionDecoder)((0, import_kit55.getU64Decoder)())],
|
|
2528
|
+
["unstaked", (0, import_kit55.getBooleanDecoder)()],
|
|
2529
|
+
["rewardsClaimed", (0, import_kit55.getBooleanDecoder)()],
|
|
2530
|
+
["id", (0, import_kit55.getU32Decoder)()],
|
|
2531
|
+
["pendingStakeComputation", (0, import_kit55.getOptionDecoder)((0, import_kit55.getAddressDecoder)())],
|
|
2532
|
+
["pendingReveal", (0, import_kit55.getBooleanDecoder)()]
|
|
2485
2533
|
]);
|
|
2486
2534
|
}
|
|
2487
2535
|
function getStakeAccountCodec() {
|
|
2488
|
-
return (0,
|
|
2536
|
+
return (0, import_kit55.combineCodec)(getStakeAccountEncoder(), getStakeAccountDecoder());
|
|
2489
2537
|
}
|
|
2490
2538
|
function decodeStakeAccount(encodedAccount) {
|
|
2491
|
-
return (0,
|
|
2539
|
+
return (0, import_kit55.decodeAccount)(
|
|
2492
2540
|
encodedAccount,
|
|
2493
2541
|
getStakeAccountDecoder()
|
|
2494
2542
|
);
|
|
2495
2543
|
}
|
|
2496
2544
|
async function fetchStakeAccount(rpc, address3, config) {
|
|
2497
2545
|
const maybeAccount = await fetchMaybeStakeAccount(rpc, address3, config);
|
|
2498
|
-
(0,
|
|
2546
|
+
(0, import_kit55.assertAccountExists)(maybeAccount);
|
|
2499
2547
|
return maybeAccount;
|
|
2500
2548
|
}
|
|
2501
2549
|
async function fetchMaybeStakeAccount(rpc, address3, config) {
|
|
2502
|
-
const maybeAccount = await (0,
|
|
2550
|
+
const maybeAccount = await (0, import_kit55.fetchEncodedAccount)(rpc, address3, config);
|
|
2503
2551
|
return decodeStakeAccount(maybeAccount);
|
|
2504
2552
|
}
|
|
2505
2553
|
async function fetchAllStakeAccount(rpc, addresses, config) {
|
|
2506
2554
|
const maybeAccounts = await fetchAllMaybeStakeAccount(rpc, addresses, config);
|
|
2507
|
-
(0,
|
|
2555
|
+
(0, import_kit55.assertAccountsExist)(maybeAccounts);
|
|
2508
2556
|
return maybeAccounts;
|
|
2509
2557
|
}
|
|
2510
2558
|
async function fetchAllMaybeStakeAccount(rpc, addresses, config) {
|
|
2511
|
-
const maybeAccounts = await (0,
|
|
2559
|
+
const maybeAccounts = await (0, import_kit55.fetchEncodedAccounts)(rpc, addresses, config);
|
|
2512
2560
|
return maybeAccounts.map((maybeAccount) => decodeStakeAccount(maybeAccount));
|
|
2513
2561
|
}
|
|
2514
2562
|
|
|
2515
2563
|
// src/generated/errors/opportunityMarket.ts
|
|
2516
|
-
var
|
|
2564
|
+
var import_kit57 = require("@solana/kit");
|
|
2517
2565
|
|
|
2518
2566
|
// src/generated/programs/opportunityMarket.ts
|
|
2519
|
-
var
|
|
2520
|
-
var OPPORTUNITY_MARKET_PROGRAM_ADDRESS = "
|
|
2567
|
+
var import_kit56 = require("@solana/kit");
|
|
2568
|
+
var OPPORTUNITY_MARKET_PROGRAM_ADDRESS = "bncqApu6NkUibDwnbfXR5oRPCLiYjwHgVuCdHRTD6rp";
|
|
2521
2569
|
var OpportunityMarketAccount = /* @__PURE__ */ ((OpportunityMarketAccount2) => {
|
|
2522
2570
|
OpportunityMarketAccount2[OpportunityMarketAccount2["AllowedMint"] = 0] = "AllowedMint";
|
|
2523
2571
|
OpportunityMarketAccount2[OpportunityMarketAccount2["ArciumSignerAccount"] = 1] = "ArciumSignerAccount";
|
|
@@ -2530,63 +2578,63 @@ var OpportunityMarketAccount = /* @__PURE__ */ ((OpportunityMarketAccount2) => {
|
|
|
2530
2578
|
})(OpportunityMarketAccount || {});
|
|
2531
2579
|
function identifyOpportunityMarketAccount(account) {
|
|
2532
2580
|
const data = "data" in account ? account.data : account;
|
|
2533
|
-
if ((0,
|
|
2581
|
+
if ((0, import_kit56.containsBytes)(
|
|
2534
2582
|
data,
|
|
2535
|
-
(0,
|
|
2583
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2536
2584
|
new Uint8Array([173, 229, 179, 46, 121, 164, 247, 6])
|
|
2537
2585
|
),
|
|
2538
2586
|
0
|
|
2539
2587
|
)) {
|
|
2540
2588
|
return 0 /* AllowedMint */;
|
|
2541
2589
|
}
|
|
2542
|
-
if ((0,
|
|
2590
|
+
if ((0, import_kit56.containsBytes)(
|
|
2543
2591
|
data,
|
|
2544
|
-
(0,
|
|
2592
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2545
2593
|
new Uint8Array([214, 157, 122, 114, 117, 44, 214, 74])
|
|
2546
2594
|
),
|
|
2547
2595
|
0
|
|
2548
2596
|
)) {
|
|
2549
2597
|
return 1 /* ArciumSignerAccount */;
|
|
2550
2598
|
}
|
|
2551
|
-
if ((0,
|
|
2599
|
+
if ((0, import_kit56.containsBytes)(
|
|
2552
2600
|
data,
|
|
2553
|
-
(0,
|
|
2601
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2554
2602
|
new Uint8Array([207, 103, 169, 160, 157, 215, 97, 224])
|
|
2555
2603
|
),
|
|
2556
2604
|
0
|
|
2557
2605
|
)) {
|
|
2558
2606
|
return 2 /* OpportunityMarket */;
|
|
2559
2607
|
}
|
|
2560
|
-
if ((0,
|
|
2608
|
+
if ((0, import_kit56.containsBytes)(
|
|
2561
2609
|
data,
|
|
2562
|
-
(0,
|
|
2610
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2563
2611
|
new Uint8Array([220, 236, 171, 213, 170, 117, 10, 64])
|
|
2564
2612
|
),
|
|
2565
2613
|
0
|
|
2566
2614
|
)) {
|
|
2567
2615
|
return 3 /* OpportunityMarketOption */;
|
|
2568
2616
|
}
|
|
2569
|
-
if ((0,
|
|
2617
|
+
if ((0, import_kit56.containsBytes)(
|
|
2570
2618
|
data,
|
|
2571
|
-
(0,
|
|
2619
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2572
2620
|
new Uint8Array([207, 139, 192, 91, 37, 190, 2, 192])
|
|
2573
2621
|
),
|
|
2574
2622
|
0
|
|
2575
2623
|
)) {
|
|
2576
2624
|
return 4 /* OpportunityMarketSponsor */;
|
|
2577
2625
|
}
|
|
2578
|
-
if ((0,
|
|
2626
|
+
if ((0, import_kit56.containsBytes)(
|
|
2579
2627
|
data,
|
|
2580
|
-
(0,
|
|
2628
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2581
2629
|
new Uint8Array([160, 78, 128, 0, 248, 83, 230, 160])
|
|
2582
2630
|
),
|
|
2583
2631
|
0
|
|
2584
2632
|
)) {
|
|
2585
2633
|
return 5 /* PlatformConfig */;
|
|
2586
2634
|
}
|
|
2587
|
-
if ((0,
|
|
2635
|
+
if ((0, import_kit56.containsBytes)(
|
|
2588
2636
|
data,
|
|
2589
|
-
(0,
|
|
2637
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2590
2638
|
new Uint8Array([80, 158, 67, 124, 50, 189, 192, 255])
|
|
2591
2639
|
),
|
|
2592
2640
|
0
|
|
@@ -2602,275 +2650,295 @@ var OpportunityMarketInstruction = /* @__PURE__ */ ((OpportunityMarketInstructio
|
|
|
2602
2650
|
OpportunityMarketInstruction2[OpportunityMarketInstruction2["AddReward"] = 1] = "AddReward";
|
|
2603
2651
|
OpportunityMarketInstruction2[OpportunityMarketInstruction2["ClaimCreatorFees"] = 2] = "ClaimCreatorFees";
|
|
2604
2652
|
OpportunityMarketInstruction2[OpportunityMarketInstruction2["ClaimFees"] = 3] = "ClaimFees";
|
|
2605
|
-
OpportunityMarketInstruction2[OpportunityMarketInstruction2["
|
|
2606
|
-
OpportunityMarketInstruction2[OpportunityMarketInstruction2["
|
|
2607
|
-
OpportunityMarketInstruction2[OpportunityMarketInstruction2["
|
|
2608
|
-
OpportunityMarketInstruction2[OpportunityMarketInstruction2["
|
|
2609
|
-
OpportunityMarketInstruction2[OpportunityMarketInstruction2["
|
|
2610
|
-
OpportunityMarketInstruction2[OpportunityMarketInstruction2["
|
|
2611
|
-
OpportunityMarketInstruction2[OpportunityMarketInstruction2["
|
|
2612
|
-
OpportunityMarketInstruction2[OpportunityMarketInstruction2["
|
|
2613
|
-
OpportunityMarketInstruction2[OpportunityMarketInstruction2["
|
|
2614
|
-
OpportunityMarketInstruction2[OpportunityMarketInstruction2["
|
|
2615
|
-
OpportunityMarketInstruction2[OpportunityMarketInstruction2["
|
|
2616
|
-
OpportunityMarketInstruction2[OpportunityMarketInstruction2["
|
|
2617
|
-
OpportunityMarketInstruction2[OpportunityMarketInstruction2["
|
|
2618
|
-
OpportunityMarketInstruction2[OpportunityMarketInstruction2["
|
|
2619
|
-
OpportunityMarketInstruction2[OpportunityMarketInstruction2["
|
|
2620
|
-
OpportunityMarketInstruction2[OpportunityMarketInstruction2["
|
|
2621
|
-
OpportunityMarketInstruction2[OpportunityMarketInstruction2["
|
|
2622
|
-
OpportunityMarketInstruction2[OpportunityMarketInstruction2["
|
|
2623
|
-
OpportunityMarketInstruction2[OpportunityMarketInstruction2["
|
|
2624
|
-
OpportunityMarketInstruction2[OpportunityMarketInstruction2["
|
|
2625
|
-
OpportunityMarketInstruction2[OpportunityMarketInstruction2["
|
|
2626
|
-
OpportunityMarketInstruction2[OpportunityMarketInstruction2["
|
|
2627
|
-
OpportunityMarketInstruction2[OpportunityMarketInstruction2["
|
|
2653
|
+
OpportunityMarketInstruction2[OpportunityMarketInstruction2["ClaimRewards"] = 4] = "ClaimRewards";
|
|
2654
|
+
OpportunityMarketInstruction2[OpportunityMarketInstruction2["CloseOptionAccount"] = 5] = "CloseOptionAccount";
|
|
2655
|
+
OpportunityMarketInstruction2[OpportunityMarketInstruction2["CloseStakeAccount"] = 6] = "CloseStakeAccount";
|
|
2656
|
+
OpportunityMarketInstruction2[OpportunityMarketInstruction2["CloseStuckStakeAccount"] = 7] = "CloseStuckStakeAccount";
|
|
2657
|
+
OpportunityMarketInstruction2[OpportunityMarketInstruction2["CloseUnrevealedStakeAccount"] = 8] = "CloseUnrevealedStakeAccount";
|
|
2658
|
+
OpportunityMarketInstruction2[OpportunityMarketInstruction2["CreateMarket"] = 9] = "CreateMarket";
|
|
2659
|
+
OpportunityMarketInstruction2[OpportunityMarketInstruction2["EndRevealPeriod"] = 10] = "EndRevealPeriod";
|
|
2660
|
+
OpportunityMarketInstruction2[OpportunityMarketInstruction2["FinalizeRevealStake"] = 11] = "FinalizeRevealStake";
|
|
2661
|
+
OpportunityMarketInstruction2[OpportunityMarketInstruction2["InitAllowedMint"] = 12] = "InitAllowedMint";
|
|
2662
|
+
OpportunityMarketInstruction2[OpportunityMarketInstruction2["InitPlatformConfig"] = 13] = "InitPlatformConfig";
|
|
2663
|
+
OpportunityMarketInstruction2[OpportunityMarketInstruction2["InitStakeAccount"] = 14] = "InitStakeAccount";
|
|
2664
|
+
OpportunityMarketInstruction2[OpportunityMarketInstruction2["OpenMarket"] = 15] = "OpenMarket";
|
|
2665
|
+
OpportunityMarketInstruction2[OpportunityMarketInstruction2["ResolveMarket"] = 16] = "ResolveMarket";
|
|
2666
|
+
OpportunityMarketInstruction2[OpportunityMarketInstruction2["RevealStake"] = 17] = "RevealStake";
|
|
2667
|
+
OpportunityMarketInstruction2[OpportunityMarketInstruction2["RevealStakeCallback"] = 18] = "RevealStakeCallback";
|
|
2668
|
+
OpportunityMarketInstruction2[OpportunityMarketInstruction2["RevealStakeCompDef"] = 19] = "RevealStakeCompDef";
|
|
2669
|
+
OpportunityMarketInstruction2[OpportunityMarketInstruction2["SetFeeClaimAuthority"] = 20] = "SetFeeClaimAuthority";
|
|
2670
|
+
OpportunityMarketInstruction2[OpportunityMarketInstruction2["SetUpdateAuthority"] = 21] = "SetUpdateAuthority";
|
|
2671
|
+
OpportunityMarketInstruction2[OpportunityMarketInstruction2["SetWinningOption"] = 22] = "SetWinningOption";
|
|
2672
|
+
OpportunityMarketInstruction2[OpportunityMarketInstruction2["Stake"] = 23] = "Stake";
|
|
2673
|
+
OpportunityMarketInstruction2[OpportunityMarketInstruction2["StakeCallback"] = 24] = "StakeCallback";
|
|
2674
|
+
OpportunityMarketInstruction2[OpportunityMarketInstruction2["StakeCompDef"] = 25] = "StakeCompDef";
|
|
2675
|
+
OpportunityMarketInstruction2[OpportunityMarketInstruction2["Unstake"] = 26] = "Unstake";
|
|
2676
|
+
OpportunityMarketInstruction2[OpportunityMarketInstruction2["UpdatePlatformConfig"] = 27] = "UpdatePlatformConfig";
|
|
2677
|
+
OpportunityMarketInstruction2[OpportunityMarketInstruction2["WithdrawReward"] = 28] = "WithdrawReward";
|
|
2628
2678
|
return OpportunityMarketInstruction2;
|
|
2629
2679
|
})(OpportunityMarketInstruction || {});
|
|
2630
2680
|
function identifyOpportunityMarketInstruction(instruction) {
|
|
2631
2681
|
const data = "data" in instruction ? instruction.data : instruction;
|
|
2632
|
-
if ((0,
|
|
2682
|
+
if ((0, import_kit56.containsBytes)(
|
|
2633
2683
|
data,
|
|
2634
|
-
(0,
|
|
2684
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2635
2685
|
new Uint8Array([76, 189, 93, 144, 50, 229, 250, 116])
|
|
2636
2686
|
),
|
|
2637
2687
|
0
|
|
2638
2688
|
)) {
|
|
2639
2689
|
return 0 /* AddMarketOption */;
|
|
2640
2690
|
}
|
|
2641
|
-
if ((0,
|
|
2691
|
+
if ((0, import_kit56.containsBytes)(
|
|
2642
2692
|
data,
|
|
2643
|
-
(0,
|
|
2693
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2644
2694
|
new Uint8Array([4, 114, 188, 164, 149, 249, 198, 237])
|
|
2645
2695
|
),
|
|
2646
2696
|
0
|
|
2647
2697
|
)) {
|
|
2648
2698
|
return 1 /* AddReward */;
|
|
2649
2699
|
}
|
|
2650
|
-
if ((0,
|
|
2700
|
+
if ((0, import_kit56.containsBytes)(
|
|
2651
2701
|
data,
|
|
2652
|
-
(0,
|
|
2702
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2653
2703
|
new Uint8Array([0, 23, 125, 234, 156, 118, 134, 89])
|
|
2654
2704
|
),
|
|
2655
2705
|
0
|
|
2656
2706
|
)) {
|
|
2657
2707
|
return 2 /* ClaimCreatorFees */;
|
|
2658
2708
|
}
|
|
2659
|
-
if ((0,
|
|
2709
|
+
if ((0, import_kit56.containsBytes)(
|
|
2660
2710
|
data,
|
|
2661
|
-
(0,
|
|
2711
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2662
2712
|
new Uint8Array([82, 251, 233, 156, 12, 52, 184, 202])
|
|
2663
2713
|
),
|
|
2664
2714
|
0
|
|
2665
2715
|
)) {
|
|
2666
2716
|
return 3 /* ClaimFees */;
|
|
2667
2717
|
}
|
|
2668
|
-
if ((0,
|
|
2718
|
+
if ((0, import_kit56.containsBytes)(
|
|
2719
|
+
data,
|
|
2720
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2721
|
+
new Uint8Array([4, 144, 132, 71, 116, 23, 151, 80])
|
|
2722
|
+
),
|
|
2723
|
+
0
|
|
2724
|
+
)) {
|
|
2725
|
+
return 4 /* ClaimRewards */;
|
|
2726
|
+
}
|
|
2727
|
+
if ((0, import_kit56.containsBytes)(
|
|
2669
2728
|
data,
|
|
2670
|
-
(0,
|
|
2729
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2671
2730
|
new Uint8Array([46, 121, 107, 240, 123, 190, 229, 1])
|
|
2672
2731
|
),
|
|
2673
2732
|
0
|
|
2674
2733
|
)) {
|
|
2675
|
-
return
|
|
2734
|
+
return 5 /* CloseOptionAccount */;
|
|
2676
2735
|
}
|
|
2677
|
-
if ((0,
|
|
2736
|
+
if ((0, import_kit56.containsBytes)(
|
|
2678
2737
|
data,
|
|
2679
|
-
(0,
|
|
2738
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2680
2739
|
new Uint8Array([246, 236, 59, 167, 115, 135, 122, 12])
|
|
2681
2740
|
),
|
|
2682
2741
|
0
|
|
2683
2742
|
)) {
|
|
2684
|
-
return
|
|
2743
|
+
return 6 /* CloseStakeAccount */;
|
|
2685
2744
|
}
|
|
2686
|
-
if ((0,
|
|
2745
|
+
if ((0, import_kit56.containsBytes)(
|
|
2687
2746
|
data,
|
|
2688
|
-
(0,
|
|
2747
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2689
2748
|
new Uint8Array([41, 239, 108, 203, 185, 230, 165, 181])
|
|
2690
2749
|
),
|
|
2691
2750
|
0
|
|
2692
2751
|
)) {
|
|
2693
|
-
return
|
|
2752
|
+
return 7 /* CloseStuckStakeAccount */;
|
|
2694
2753
|
}
|
|
2695
|
-
if ((0,
|
|
2754
|
+
if ((0, import_kit56.containsBytes)(
|
|
2696
2755
|
data,
|
|
2697
|
-
(0,
|
|
2756
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2757
|
+
new Uint8Array([171, 229, 236, 216, 122, 118, 188, 103])
|
|
2758
|
+
),
|
|
2759
|
+
0
|
|
2760
|
+
)) {
|
|
2761
|
+
return 8 /* CloseUnrevealedStakeAccount */;
|
|
2762
|
+
}
|
|
2763
|
+
if ((0, import_kit56.containsBytes)(
|
|
2764
|
+
data,
|
|
2765
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2698
2766
|
new Uint8Array([103, 226, 97, 235, 200, 188, 251, 254])
|
|
2699
2767
|
),
|
|
2700
2768
|
0
|
|
2701
2769
|
)) {
|
|
2702
|
-
return
|
|
2770
|
+
return 9 /* CreateMarket */;
|
|
2703
2771
|
}
|
|
2704
|
-
if ((0,
|
|
2772
|
+
if ((0, import_kit56.containsBytes)(
|
|
2705
2773
|
data,
|
|
2706
|
-
(0,
|
|
2774
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2707
2775
|
new Uint8Array([144, 81, 42, 65, 127, 60, 134, 92])
|
|
2708
2776
|
),
|
|
2709
2777
|
0
|
|
2710
2778
|
)) {
|
|
2711
|
-
return
|
|
2779
|
+
return 10 /* EndRevealPeriod */;
|
|
2712
2780
|
}
|
|
2713
|
-
if ((0,
|
|
2781
|
+
if ((0, import_kit56.containsBytes)(
|
|
2714
2782
|
data,
|
|
2715
|
-
(0,
|
|
2783
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2716
2784
|
new Uint8Array([92, 201, 94, 219, 117, 53, 255, 230])
|
|
2717
2785
|
),
|
|
2718
2786
|
0
|
|
2719
2787
|
)) {
|
|
2720
|
-
return
|
|
2788
|
+
return 11 /* FinalizeRevealStake */;
|
|
2721
2789
|
}
|
|
2722
|
-
if ((0,
|
|
2790
|
+
if ((0, import_kit56.containsBytes)(
|
|
2723
2791
|
data,
|
|
2724
|
-
(0,
|
|
2792
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2725
2793
|
new Uint8Array([215, 70, 3, 5, 42, 229, 151, 10])
|
|
2726
2794
|
),
|
|
2727
2795
|
0
|
|
2728
2796
|
)) {
|
|
2729
|
-
return
|
|
2797
|
+
return 12 /* InitAllowedMint */;
|
|
2730
2798
|
}
|
|
2731
|
-
if ((0,
|
|
2799
|
+
if ((0, import_kit56.containsBytes)(
|
|
2732
2800
|
data,
|
|
2733
|
-
(0,
|
|
2801
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2734
2802
|
new Uint8Array([101, 52, 47, 49, 156, 16, 32, 118])
|
|
2735
2803
|
),
|
|
2736
2804
|
0
|
|
2737
2805
|
)) {
|
|
2738
|
-
return
|
|
2806
|
+
return 13 /* InitPlatformConfig */;
|
|
2739
2807
|
}
|
|
2740
|
-
if ((0,
|
|
2808
|
+
if ((0, import_kit56.containsBytes)(
|
|
2741
2809
|
data,
|
|
2742
|
-
(0,
|
|
2810
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2743
2811
|
new Uint8Array([132, 171, 255, 149, 163, 37, 220, 45])
|
|
2744
2812
|
),
|
|
2745
2813
|
0
|
|
2746
2814
|
)) {
|
|
2747
|
-
return
|
|
2815
|
+
return 14 /* InitStakeAccount */;
|
|
2748
2816
|
}
|
|
2749
|
-
if ((0,
|
|
2817
|
+
if ((0, import_kit56.containsBytes)(
|
|
2750
2818
|
data,
|
|
2751
|
-
(0,
|
|
2819
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2752
2820
|
new Uint8Array([116, 19, 123, 75, 217, 244, 69, 44])
|
|
2753
2821
|
),
|
|
2754
2822
|
0
|
|
2755
2823
|
)) {
|
|
2756
|
-
return
|
|
2824
|
+
return 15 /* OpenMarket */;
|
|
2757
2825
|
}
|
|
2758
|
-
if ((0,
|
|
2826
|
+
if ((0, import_kit56.containsBytes)(
|
|
2759
2827
|
data,
|
|
2760
|
-
(0,
|
|
2828
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2761
2829
|
new Uint8Array([155, 23, 80, 173, 46, 74, 23, 239])
|
|
2762
2830
|
),
|
|
2763
2831
|
0
|
|
2764
2832
|
)) {
|
|
2765
|
-
return
|
|
2833
|
+
return 16 /* ResolveMarket */;
|
|
2766
2834
|
}
|
|
2767
|
-
if ((0,
|
|
2835
|
+
if ((0, import_kit56.containsBytes)(
|
|
2768
2836
|
data,
|
|
2769
|
-
(0,
|
|
2837
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2770
2838
|
new Uint8Array([107, 229, 210, 77, 126, 255, 243, 188])
|
|
2771
2839
|
),
|
|
2772
2840
|
0
|
|
2773
2841
|
)) {
|
|
2774
|
-
return
|
|
2842
|
+
return 17 /* RevealStake */;
|
|
2775
2843
|
}
|
|
2776
|
-
if ((0,
|
|
2844
|
+
if ((0, import_kit56.containsBytes)(
|
|
2777
2845
|
data,
|
|
2778
|
-
(0,
|
|
2846
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2779
2847
|
new Uint8Array([79, 19, 120, 162, 232, 39, 206, 116])
|
|
2780
2848
|
),
|
|
2781
2849
|
0
|
|
2782
2850
|
)) {
|
|
2783
|
-
return
|
|
2851
|
+
return 18 /* RevealStakeCallback */;
|
|
2784
2852
|
}
|
|
2785
|
-
if ((0,
|
|
2853
|
+
if ((0, import_kit56.containsBytes)(
|
|
2786
2854
|
data,
|
|
2787
|
-
(0,
|
|
2855
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2788
2856
|
new Uint8Array([197, 20, 216, 132, 43, 99, 64, 0])
|
|
2789
2857
|
),
|
|
2790
2858
|
0
|
|
2791
2859
|
)) {
|
|
2792
|
-
return
|
|
2860
|
+
return 19 /* RevealStakeCompDef */;
|
|
2793
2861
|
}
|
|
2794
|
-
if ((0,
|
|
2862
|
+
if ((0, import_kit56.containsBytes)(
|
|
2795
2863
|
data,
|
|
2796
|
-
(0,
|
|
2864
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2797
2865
|
new Uint8Array([75, 250, 161, 197, 43, 196, 161, 3])
|
|
2798
2866
|
),
|
|
2799
2867
|
0
|
|
2800
2868
|
)) {
|
|
2801
|
-
return
|
|
2869
|
+
return 20 /* SetFeeClaimAuthority */;
|
|
2802
2870
|
}
|
|
2803
|
-
if ((0,
|
|
2871
|
+
if ((0, import_kit56.containsBytes)(
|
|
2804
2872
|
data,
|
|
2805
|
-
(0,
|
|
2873
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2806
2874
|
new Uint8Array([166, 198, 186, 255, 217, 170, 103, 155])
|
|
2807
2875
|
),
|
|
2808
2876
|
0
|
|
2809
2877
|
)) {
|
|
2810
|
-
return
|
|
2878
|
+
return 21 /* SetUpdateAuthority */;
|
|
2811
2879
|
}
|
|
2812
|
-
if ((0,
|
|
2880
|
+
if ((0, import_kit56.containsBytes)(
|
|
2813
2881
|
data,
|
|
2814
|
-
(0,
|
|
2882
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2815
2883
|
new Uint8Array([156, 73, 113, 33, 170, 115, 163, 206])
|
|
2816
2884
|
),
|
|
2817
2885
|
0
|
|
2818
2886
|
)) {
|
|
2819
|
-
return
|
|
2887
|
+
return 22 /* SetWinningOption */;
|
|
2820
2888
|
}
|
|
2821
|
-
if ((0,
|
|
2889
|
+
if ((0, import_kit56.containsBytes)(
|
|
2822
2890
|
data,
|
|
2823
|
-
(0,
|
|
2891
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2824
2892
|
new Uint8Array([206, 176, 202, 18, 200, 209, 179, 108])
|
|
2825
2893
|
),
|
|
2826
2894
|
0
|
|
2827
2895
|
)) {
|
|
2828
|
-
return
|
|
2896
|
+
return 23 /* Stake */;
|
|
2829
2897
|
}
|
|
2830
|
-
if ((0,
|
|
2898
|
+
if ((0, import_kit56.containsBytes)(
|
|
2831
2899
|
data,
|
|
2832
|
-
(0,
|
|
2900
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2833
2901
|
new Uint8Array([40, 220, 36, 47, 6, 116, 132, 89])
|
|
2834
2902
|
),
|
|
2835
2903
|
0
|
|
2836
2904
|
)) {
|
|
2837
|
-
return
|
|
2905
|
+
return 24 /* StakeCallback */;
|
|
2838
2906
|
}
|
|
2839
|
-
if ((0,
|
|
2907
|
+
if ((0, import_kit56.containsBytes)(
|
|
2840
2908
|
data,
|
|
2841
|
-
(0,
|
|
2909
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2842
2910
|
new Uint8Array([156, 5, 60, 126, 142, 149, 1, 130])
|
|
2843
2911
|
),
|
|
2844
2912
|
0
|
|
2845
2913
|
)) {
|
|
2846
|
-
return
|
|
2914
|
+
return 25 /* StakeCompDef */;
|
|
2847
2915
|
}
|
|
2848
|
-
if ((0,
|
|
2916
|
+
if ((0, import_kit56.containsBytes)(
|
|
2849
2917
|
data,
|
|
2850
|
-
(0,
|
|
2918
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2851
2919
|
new Uint8Array([90, 95, 107, 42, 205, 124, 50, 225])
|
|
2852
2920
|
),
|
|
2853
2921
|
0
|
|
2854
2922
|
)) {
|
|
2855
|
-
return
|
|
2923
|
+
return 26 /* Unstake */;
|
|
2856
2924
|
}
|
|
2857
|
-
if ((0,
|
|
2925
|
+
if ((0, import_kit56.containsBytes)(
|
|
2858
2926
|
data,
|
|
2859
|
-
(0,
|
|
2927
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2860
2928
|
new Uint8Array([195, 60, 76, 129, 146, 45, 67, 143])
|
|
2861
2929
|
),
|
|
2862
2930
|
0
|
|
2863
2931
|
)) {
|
|
2864
|
-
return
|
|
2932
|
+
return 27 /* UpdatePlatformConfig */;
|
|
2865
2933
|
}
|
|
2866
|
-
if ((0,
|
|
2934
|
+
if ((0, import_kit56.containsBytes)(
|
|
2867
2935
|
data,
|
|
2868
|
-
(0,
|
|
2936
|
+
(0, import_kit56.fixEncoderSize)((0, import_kit56.getBytesEncoder)(), 8).encode(
|
|
2869
2937
|
new Uint8Array([191, 187, 176, 137, 9, 25, 187, 244])
|
|
2870
2938
|
),
|
|
2871
2939
|
0
|
|
2872
2940
|
)) {
|
|
2873
|
-
return
|
|
2941
|
+
return 28 /* WithdrawReward */;
|
|
2874
2942
|
}
|
|
2875
2943
|
throw new Error(
|
|
2876
2944
|
"The provided instruction could not be identified as a opportunityMarket instruction."
|
|
@@ -2960,7 +3028,7 @@ function getOpportunityMarketErrorMessage(code) {
|
|
|
2960
3028
|
return "Error message not available in production bundles.";
|
|
2961
3029
|
}
|
|
2962
3030
|
function isOpportunityMarketError(error, transactionMessage, code) {
|
|
2963
|
-
return (0,
|
|
3031
|
+
return (0, import_kit57.isProgramError)(
|
|
2964
3032
|
error,
|
|
2965
3033
|
transactionMessage,
|
|
2966
3034
|
OPPORTUNITY_MARKET_PROGRAM_ADDRESS,
|
|
@@ -2969,10 +3037,10 @@ function isOpportunityMarketError(error, transactionMessage, code) {
|
|
|
2969
3037
|
}
|
|
2970
3038
|
|
|
2971
3039
|
// src/generated/instructions/addMarketOption.ts
|
|
2972
|
-
var
|
|
3040
|
+
var import_kit59 = require("@solana/kit");
|
|
2973
3041
|
|
|
2974
3042
|
// src/generated/shared/index.ts
|
|
2975
|
-
var
|
|
3043
|
+
var import_kit58 = require("@solana/kit");
|
|
2976
3044
|
function expectSome(value) {
|
|
2977
3045
|
if (value === null || value === void 0) {
|
|
2978
3046
|
throw new Error("Expected a value but received null or undefined.");
|
|
@@ -2997,19 +3065,19 @@ function getAccountMetaFactory(programAddress, optionalAccountStrategy) {
|
|
|
2997
3065
|
if (optionalAccountStrategy === "omitted") return;
|
|
2998
3066
|
return Object.freeze({
|
|
2999
3067
|
address: programAddress,
|
|
3000
|
-
role:
|
|
3068
|
+
role: import_kit58.AccountRole.READONLY
|
|
3001
3069
|
});
|
|
3002
3070
|
}
|
|
3003
|
-
const writableRole = account.isWritable ?
|
|
3071
|
+
const writableRole = account.isWritable ? import_kit58.AccountRole.WRITABLE : import_kit58.AccountRole.READONLY;
|
|
3004
3072
|
return Object.freeze({
|
|
3005
3073
|
address: expectAddress(account.value),
|
|
3006
|
-
role: isTransactionSigner(account.value) ? (0,
|
|
3074
|
+
role: isTransactionSigner(account.value) ? (0, import_kit58.upgradeRoleToSigner)(writableRole) : writableRole,
|
|
3007
3075
|
...isTransactionSigner(account.value) ? { signer: account.value } : {}
|
|
3008
3076
|
});
|
|
3009
3077
|
};
|
|
3010
3078
|
}
|
|
3011
3079
|
function isTransactionSigner(value) {
|
|
3012
|
-
return !!value && typeof value === "object" && "address" in value && (0,
|
|
3080
|
+
return !!value && typeof value === "object" && "address" in value && (0, import_kit58.isTransactionSigner)(value);
|
|
3013
3081
|
}
|
|
3014
3082
|
|
|
3015
3083
|
// src/generated/instructions/addMarketOption.ts
|
|
@@ -3024,27 +3092,27 @@ var ADD_MARKET_OPTION_DISCRIMINATOR = new Uint8Array([
|
|
|
3024
3092
|
116
|
|
3025
3093
|
]);
|
|
3026
3094
|
function getAddMarketOptionDiscriminatorBytes() {
|
|
3027
|
-
return (0,
|
|
3095
|
+
return (0, import_kit59.fixEncoderSize)((0, import_kit59.getBytesEncoder)(), 8).encode(
|
|
3028
3096
|
ADD_MARKET_OPTION_DISCRIMINATOR
|
|
3029
3097
|
);
|
|
3030
3098
|
}
|
|
3031
3099
|
function getAddMarketOptionInstructionDataEncoder() {
|
|
3032
|
-
return (0,
|
|
3033
|
-
(0,
|
|
3034
|
-
["discriminator", (0,
|
|
3035
|
-
["optionId", (0,
|
|
3100
|
+
return (0, import_kit59.transformEncoder)(
|
|
3101
|
+
(0, import_kit59.getStructEncoder)([
|
|
3102
|
+
["discriminator", (0, import_kit59.fixEncoderSize)((0, import_kit59.getBytesEncoder)(), 8)],
|
|
3103
|
+
["optionId", (0, import_kit59.getU64Encoder)()]
|
|
3036
3104
|
]),
|
|
3037
3105
|
(value) => ({ ...value, discriminator: ADD_MARKET_OPTION_DISCRIMINATOR })
|
|
3038
3106
|
);
|
|
3039
3107
|
}
|
|
3040
3108
|
function getAddMarketOptionInstructionDataDecoder() {
|
|
3041
|
-
return (0,
|
|
3042
|
-
["discriminator", (0,
|
|
3043
|
-
["optionId", (0,
|
|
3109
|
+
return (0, import_kit59.getStructDecoder)([
|
|
3110
|
+
["discriminator", (0, import_kit59.fixDecoderSize)((0, import_kit59.getBytesDecoder)(), 8)],
|
|
3111
|
+
["optionId", (0, import_kit59.getU64Decoder)()]
|
|
3044
3112
|
]);
|
|
3045
3113
|
}
|
|
3046
3114
|
function getAddMarketOptionInstructionDataCodec() {
|
|
3047
|
-
return (0,
|
|
3115
|
+
return (0, import_kit59.combineCodec)(
|
|
3048
3116
|
getAddMarketOptionInstructionDataEncoder(),
|
|
3049
3117
|
getAddMarketOptionInstructionDataDecoder()
|
|
3050
3118
|
);
|
|
@@ -3060,14 +3128,14 @@ async function getAddMarketOptionInstructionAsync(input, config) {
|
|
|
3060
3128
|
const accounts = originalAccounts;
|
|
3061
3129
|
const args = { ...input };
|
|
3062
3130
|
if (!accounts.option.value) {
|
|
3063
|
-
accounts.option.value = await (0,
|
|
3131
|
+
accounts.option.value = await (0, import_kit59.getProgramDerivedAddress)({
|
|
3064
3132
|
programAddress,
|
|
3065
3133
|
seeds: [
|
|
3066
|
-
(0,
|
|
3134
|
+
(0, import_kit59.getBytesEncoder)().encode(
|
|
3067
3135
|
new Uint8Array([111, 112, 116, 105, 111, 110])
|
|
3068
3136
|
),
|
|
3069
|
-
(0,
|
|
3070
|
-
(0,
|
|
3137
|
+
(0, import_kit59.getAddressEncoder)().encode(expectAddress(accounts.market.value)),
|
|
3138
|
+
(0, import_kit59.getU64Encoder)().encode(expectSome(args.optionId))
|
|
3071
3139
|
]
|
|
3072
3140
|
});
|
|
3073
3141
|
}
|
|
@@ -3138,7 +3206,7 @@ function parseAddMarketOptionInstruction(instruction) {
|
|
|
3138
3206
|
}
|
|
3139
3207
|
|
|
3140
3208
|
// src/generated/instructions/addReward.ts
|
|
3141
|
-
var
|
|
3209
|
+
var import_kit60 = require("@solana/kit");
|
|
3142
3210
|
var ADD_REWARD_DISCRIMINATOR = new Uint8Array([
|
|
3143
3211
|
4,
|
|
3144
3212
|
114,
|
|
@@ -3150,27 +3218,25 @@ var ADD_REWARD_DISCRIMINATOR = new Uint8Array([
|
|
|
3150
3218
|
237
|
|
3151
3219
|
]);
|
|
3152
3220
|
function getAddRewardDiscriminatorBytes() {
|
|
3153
|
-
return (0,
|
|
3221
|
+
return (0, import_kit60.fixEncoderSize)((0, import_kit60.getBytesEncoder)(), 8).encode(ADD_REWARD_DISCRIMINATOR);
|
|
3154
3222
|
}
|
|
3155
3223
|
function getAddRewardInstructionDataEncoder() {
|
|
3156
|
-
return (0,
|
|
3157
|
-
(0,
|
|
3158
|
-
["discriminator", (0,
|
|
3159
|
-
["amount", (0,
|
|
3160
|
-
["lock", (0, import_kit59.getBooleanEncoder)()]
|
|
3224
|
+
return (0, import_kit60.transformEncoder)(
|
|
3225
|
+
(0, import_kit60.getStructEncoder)([
|
|
3226
|
+
["discriminator", (0, import_kit60.fixEncoderSize)((0, import_kit60.getBytesEncoder)(), 8)],
|
|
3227
|
+
["amount", (0, import_kit60.getU64Encoder)()]
|
|
3161
3228
|
]),
|
|
3162
3229
|
(value) => ({ ...value, discriminator: ADD_REWARD_DISCRIMINATOR })
|
|
3163
3230
|
);
|
|
3164
3231
|
}
|
|
3165
3232
|
function getAddRewardInstructionDataDecoder() {
|
|
3166
|
-
return (0,
|
|
3167
|
-
["discriminator", (0,
|
|
3168
|
-
["amount", (0,
|
|
3169
|
-
["lock", (0, import_kit59.getBooleanDecoder)()]
|
|
3233
|
+
return (0, import_kit60.getStructDecoder)([
|
|
3234
|
+
["discriminator", (0, import_kit60.fixDecoderSize)((0, import_kit60.getBytesDecoder)(), 8)],
|
|
3235
|
+
["amount", (0, import_kit60.getU64Decoder)()]
|
|
3170
3236
|
]);
|
|
3171
3237
|
}
|
|
3172
3238
|
function getAddRewardInstructionDataCodec() {
|
|
3173
|
-
return (0,
|
|
3239
|
+
return (0, import_kit60.combineCodec)(
|
|
3174
3240
|
getAddRewardInstructionDataEncoder(),
|
|
3175
3241
|
getAddRewardInstructionDataDecoder()
|
|
3176
3242
|
);
|
|
@@ -3193,24 +3259,24 @@ async function getAddRewardInstructionAsync(input, config) {
|
|
|
3193
3259
|
const accounts = originalAccounts;
|
|
3194
3260
|
const args = { ...input };
|
|
3195
3261
|
if (!accounts.sponsorAccount.value) {
|
|
3196
|
-
accounts.sponsorAccount.value = await (0,
|
|
3262
|
+
accounts.sponsorAccount.value = await (0, import_kit60.getProgramDerivedAddress)({
|
|
3197
3263
|
programAddress,
|
|
3198
3264
|
seeds: [
|
|
3199
|
-
(0,
|
|
3265
|
+
(0, import_kit60.getBytesEncoder)().encode(
|
|
3200
3266
|
new Uint8Array([115, 112, 111, 110, 115, 111, 114])
|
|
3201
3267
|
),
|
|
3202
|
-
(0,
|
|
3203
|
-
(0,
|
|
3268
|
+
(0, import_kit60.getAddressEncoder)().encode(expectAddress(accounts.sponsor.value)),
|
|
3269
|
+
(0, import_kit60.getAddressEncoder)().encode(expectAddress(accounts.market.value))
|
|
3204
3270
|
]
|
|
3205
3271
|
});
|
|
3206
3272
|
}
|
|
3207
3273
|
if (!accounts.marketTokenAta.value) {
|
|
3208
|
-
accounts.marketTokenAta.value = await (0,
|
|
3274
|
+
accounts.marketTokenAta.value = await (0, import_kit60.getProgramDerivedAddress)({
|
|
3209
3275
|
programAddress: "ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL",
|
|
3210
3276
|
seeds: [
|
|
3211
|
-
(0,
|
|
3212
|
-
(0,
|
|
3213
|
-
(0,
|
|
3277
|
+
(0, import_kit60.getAddressEncoder)().encode(expectAddress(accounts.market.value)),
|
|
3278
|
+
(0, import_kit60.getAddressEncoder)().encode(expectAddress(accounts.tokenProgram.value)),
|
|
3279
|
+
(0, import_kit60.getAddressEncoder)().encode(expectAddress(accounts.tokenMint.value))
|
|
3214
3280
|
]
|
|
3215
3281
|
});
|
|
3216
3282
|
}
|
|
@@ -3300,7 +3366,7 @@ function parseAddRewardInstruction(instruction) {
|
|
|
3300
3366
|
}
|
|
3301
3367
|
|
|
3302
3368
|
// src/generated/instructions/claimCreatorFees.ts
|
|
3303
|
-
var
|
|
3369
|
+
var import_kit61 = require("@solana/kit");
|
|
3304
3370
|
var CLAIM_CREATOR_FEES_DISCRIMINATOR = new Uint8Array([
|
|
3305
3371
|
0,
|
|
3306
3372
|
23,
|
|
@@ -3312,23 +3378,23 @@ var CLAIM_CREATOR_FEES_DISCRIMINATOR = new Uint8Array([
|
|
|
3312
3378
|
89
|
|
3313
3379
|
]);
|
|
3314
3380
|
function getClaimCreatorFeesDiscriminatorBytes() {
|
|
3315
|
-
return (0,
|
|
3381
|
+
return (0, import_kit61.fixEncoderSize)((0, import_kit61.getBytesEncoder)(), 8).encode(
|
|
3316
3382
|
CLAIM_CREATOR_FEES_DISCRIMINATOR
|
|
3317
3383
|
);
|
|
3318
3384
|
}
|
|
3319
3385
|
function getClaimCreatorFeesInstructionDataEncoder() {
|
|
3320
|
-
return (0,
|
|
3321
|
-
(0,
|
|
3386
|
+
return (0, import_kit61.transformEncoder)(
|
|
3387
|
+
(0, import_kit61.getStructEncoder)([["discriminator", (0, import_kit61.fixEncoderSize)((0, import_kit61.getBytesEncoder)(), 8)]]),
|
|
3322
3388
|
(value) => ({ ...value, discriminator: CLAIM_CREATOR_FEES_DISCRIMINATOR })
|
|
3323
3389
|
);
|
|
3324
3390
|
}
|
|
3325
3391
|
function getClaimCreatorFeesInstructionDataDecoder() {
|
|
3326
|
-
return (0,
|
|
3327
|
-
["discriminator", (0,
|
|
3392
|
+
return (0, import_kit61.getStructDecoder)([
|
|
3393
|
+
["discriminator", (0, import_kit61.fixDecoderSize)((0, import_kit61.getBytesDecoder)(), 8)]
|
|
3328
3394
|
]);
|
|
3329
3395
|
}
|
|
3330
3396
|
function getClaimCreatorFeesInstructionDataCodec() {
|
|
3331
|
-
return (0,
|
|
3397
|
+
return (0, import_kit61.combineCodec)(
|
|
3332
3398
|
getClaimCreatorFeesInstructionDataEncoder(),
|
|
3333
3399
|
getClaimCreatorFeesInstructionDataDecoder()
|
|
3334
3400
|
);
|
|
@@ -3348,12 +3414,12 @@ async function getClaimCreatorFeesInstructionAsync(input, config) {
|
|
|
3348
3414
|
};
|
|
3349
3415
|
const accounts = originalAccounts;
|
|
3350
3416
|
if (!accounts.marketTokenAta.value) {
|
|
3351
|
-
accounts.marketTokenAta.value = await (0,
|
|
3417
|
+
accounts.marketTokenAta.value = await (0, import_kit61.getProgramDerivedAddress)({
|
|
3352
3418
|
programAddress: "ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL",
|
|
3353
3419
|
seeds: [
|
|
3354
|
-
(0,
|
|
3355
|
-
(0,
|
|
3356
|
-
(0,
|
|
3420
|
+
(0, import_kit61.getAddressEncoder)().encode(expectAddress(accounts.market.value)),
|
|
3421
|
+
(0, import_kit61.getAddressEncoder)().encode(expectAddress(accounts.tokenProgram.value)),
|
|
3422
|
+
(0, import_kit61.getAddressEncoder)().encode(expectAddress(accounts.tokenMint.value))
|
|
3357
3423
|
]
|
|
3358
3424
|
});
|
|
3359
3425
|
}
|
|
@@ -3424,7 +3490,7 @@ function parseClaimCreatorFeesInstruction(instruction) {
|
|
|
3424
3490
|
}
|
|
3425
3491
|
|
|
3426
3492
|
// src/generated/instructions/claimFees.ts
|
|
3427
|
-
var
|
|
3493
|
+
var import_kit62 = require("@solana/kit");
|
|
3428
3494
|
var CLAIM_FEES_DISCRIMINATOR = new Uint8Array([
|
|
3429
3495
|
82,
|
|
3430
3496
|
251,
|
|
@@ -3436,21 +3502,21 @@ var CLAIM_FEES_DISCRIMINATOR = new Uint8Array([
|
|
|
3436
3502
|
202
|
|
3437
3503
|
]);
|
|
3438
3504
|
function getClaimFeesDiscriminatorBytes() {
|
|
3439
|
-
return (0,
|
|
3505
|
+
return (0, import_kit62.fixEncoderSize)((0, import_kit62.getBytesEncoder)(), 8).encode(CLAIM_FEES_DISCRIMINATOR);
|
|
3440
3506
|
}
|
|
3441
3507
|
function getClaimFeesInstructionDataEncoder() {
|
|
3442
|
-
return (0,
|
|
3443
|
-
(0,
|
|
3508
|
+
return (0, import_kit62.transformEncoder)(
|
|
3509
|
+
(0, import_kit62.getStructEncoder)([["discriminator", (0, import_kit62.fixEncoderSize)((0, import_kit62.getBytesEncoder)(), 8)]]),
|
|
3444
3510
|
(value) => ({ ...value, discriminator: CLAIM_FEES_DISCRIMINATOR })
|
|
3445
3511
|
);
|
|
3446
3512
|
}
|
|
3447
3513
|
function getClaimFeesInstructionDataDecoder() {
|
|
3448
|
-
return (0,
|
|
3449
|
-
["discriminator", (0,
|
|
3514
|
+
return (0, import_kit62.getStructDecoder)([
|
|
3515
|
+
["discriminator", (0, import_kit62.fixDecoderSize)((0, import_kit62.getBytesDecoder)(), 8)]
|
|
3450
3516
|
]);
|
|
3451
3517
|
}
|
|
3452
3518
|
function getClaimFeesInstructionDataCodec() {
|
|
3453
|
-
return (0,
|
|
3519
|
+
return (0, import_kit62.combineCodec)(
|
|
3454
3520
|
getClaimFeesInstructionDataEncoder(),
|
|
3455
3521
|
getClaimFeesInstructionDataDecoder()
|
|
3456
3522
|
);
|
|
@@ -3471,12 +3537,12 @@ async function getClaimFeesInstructionAsync(input, config) {
|
|
|
3471
3537
|
};
|
|
3472
3538
|
const accounts = originalAccounts;
|
|
3473
3539
|
if (!accounts.marketTokenAta.value) {
|
|
3474
|
-
accounts.marketTokenAta.value = await (0,
|
|
3540
|
+
accounts.marketTokenAta.value = await (0, import_kit62.getProgramDerivedAddress)({
|
|
3475
3541
|
programAddress: "ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL",
|
|
3476
3542
|
seeds: [
|
|
3477
|
-
(0,
|
|
3478
|
-
(0,
|
|
3479
|
-
(0,
|
|
3543
|
+
(0, import_kit62.getAddressEncoder)().encode(expectAddress(accounts.market.value)),
|
|
3544
|
+
(0, import_kit62.getAddressEncoder)().encode(expectAddress(accounts.tokenProgram.value)),
|
|
3545
|
+
(0, import_kit62.getAddressEncoder)().encode(expectAddress(accounts.tokenMint.value))
|
|
3480
3546
|
]
|
|
3481
3547
|
});
|
|
3482
3548
|
}
|
|
@@ -3550,8 +3616,142 @@ function parseClaimFeesInstruction(instruction) {
|
|
|
3550
3616
|
};
|
|
3551
3617
|
}
|
|
3552
3618
|
|
|
3619
|
+
// src/generated/instructions/claimRewards.ts
|
|
3620
|
+
var import_kit63 = require("@solana/kit");
|
|
3621
|
+
var CLAIM_REWARDS_DISCRIMINATOR = new Uint8Array([
|
|
3622
|
+
4,
|
|
3623
|
+
144,
|
|
3624
|
+
132,
|
|
3625
|
+
71,
|
|
3626
|
+
116,
|
|
3627
|
+
23,
|
|
3628
|
+
151,
|
|
3629
|
+
80
|
|
3630
|
+
]);
|
|
3631
|
+
function getClaimRewardsDiscriminatorBytes() {
|
|
3632
|
+
return (0, import_kit63.fixEncoderSize)((0, import_kit63.getBytesEncoder)(), 8).encode(
|
|
3633
|
+
CLAIM_REWARDS_DISCRIMINATOR
|
|
3634
|
+
);
|
|
3635
|
+
}
|
|
3636
|
+
function getClaimRewardsInstructionDataEncoder() {
|
|
3637
|
+
return (0, import_kit63.transformEncoder)(
|
|
3638
|
+
(0, import_kit63.getStructEncoder)([["discriminator", (0, import_kit63.fixEncoderSize)((0, import_kit63.getBytesEncoder)(), 8)]]),
|
|
3639
|
+
(value) => ({ ...value, discriminator: CLAIM_REWARDS_DISCRIMINATOR })
|
|
3640
|
+
);
|
|
3641
|
+
}
|
|
3642
|
+
function getClaimRewardsInstructionDataDecoder() {
|
|
3643
|
+
return (0, import_kit63.getStructDecoder)([
|
|
3644
|
+
["discriminator", (0, import_kit63.fixDecoderSize)((0, import_kit63.getBytesDecoder)(), 8)]
|
|
3645
|
+
]);
|
|
3646
|
+
}
|
|
3647
|
+
function getClaimRewardsInstructionDataCodec() {
|
|
3648
|
+
return (0, import_kit63.combineCodec)(
|
|
3649
|
+
getClaimRewardsInstructionDataEncoder(),
|
|
3650
|
+
getClaimRewardsInstructionDataDecoder()
|
|
3651
|
+
);
|
|
3652
|
+
}
|
|
3653
|
+
async function getClaimRewardsInstructionAsync(input, config) {
|
|
3654
|
+
const programAddress = config?.programAddress ?? OPPORTUNITY_MARKET_PROGRAM_ADDRESS;
|
|
3655
|
+
const originalAccounts = {
|
|
3656
|
+
owner: { value: input.owner ?? null, isWritable: true },
|
|
3657
|
+
market: { value: input.market ?? null, isWritable: true },
|
|
3658
|
+
stakeAccount: { value: input.stakeAccount ?? null, isWritable: true },
|
|
3659
|
+
option: { value: input.option ?? null, isWritable: true },
|
|
3660
|
+
tokenMint: { value: input.tokenMint ?? null, isWritable: false },
|
|
3661
|
+
marketTokenAta: { value: input.marketTokenAta ?? null, isWritable: true },
|
|
3662
|
+
ownerTokenAccount: {
|
|
3663
|
+
value: input.ownerTokenAccount ?? null,
|
|
3664
|
+
isWritable: true
|
|
3665
|
+
},
|
|
3666
|
+
tokenProgram: { value: input.tokenProgram ?? null, isWritable: false }
|
|
3667
|
+
};
|
|
3668
|
+
const accounts = originalAccounts;
|
|
3669
|
+
if (!accounts.marketTokenAta.value) {
|
|
3670
|
+
accounts.marketTokenAta.value = await (0, import_kit63.getProgramDerivedAddress)({
|
|
3671
|
+
programAddress: "ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL",
|
|
3672
|
+
seeds: [
|
|
3673
|
+
(0, import_kit63.getAddressEncoder)().encode(expectAddress(accounts.market.value)),
|
|
3674
|
+
(0, import_kit63.getAddressEncoder)().encode(expectAddress(accounts.tokenProgram.value)),
|
|
3675
|
+
(0, import_kit63.getAddressEncoder)().encode(expectAddress(accounts.tokenMint.value))
|
|
3676
|
+
]
|
|
3677
|
+
});
|
|
3678
|
+
}
|
|
3679
|
+
const getAccountMeta = getAccountMetaFactory(programAddress, "programId");
|
|
3680
|
+
return Object.freeze({
|
|
3681
|
+
accounts: [
|
|
3682
|
+
getAccountMeta(accounts.owner),
|
|
3683
|
+
getAccountMeta(accounts.market),
|
|
3684
|
+
getAccountMeta(accounts.stakeAccount),
|
|
3685
|
+
getAccountMeta(accounts.option),
|
|
3686
|
+
getAccountMeta(accounts.tokenMint),
|
|
3687
|
+
getAccountMeta(accounts.marketTokenAta),
|
|
3688
|
+
getAccountMeta(accounts.ownerTokenAccount),
|
|
3689
|
+
getAccountMeta(accounts.tokenProgram)
|
|
3690
|
+
],
|
|
3691
|
+
data: getClaimRewardsInstructionDataEncoder().encode({}),
|
|
3692
|
+
programAddress
|
|
3693
|
+
});
|
|
3694
|
+
}
|
|
3695
|
+
function getClaimRewardsInstruction(input, config) {
|
|
3696
|
+
const programAddress = config?.programAddress ?? OPPORTUNITY_MARKET_PROGRAM_ADDRESS;
|
|
3697
|
+
const originalAccounts = {
|
|
3698
|
+
owner: { value: input.owner ?? null, isWritable: true },
|
|
3699
|
+
market: { value: input.market ?? null, isWritable: true },
|
|
3700
|
+
stakeAccount: { value: input.stakeAccount ?? null, isWritable: true },
|
|
3701
|
+
option: { value: input.option ?? null, isWritable: true },
|
|
3702
|
+
tokenMint: { value: input.tokenMint ?? null, isWritable: false },
|
|
3703
|
+
marketTokenAta: { value: input.marketTokenAta ?? null, isWritable: true },
|
|
3704
|
+
ownerTokenAccount: {
|
|
3705
|
+
value: input.ownerTokenAccount ?? null,
|
|
3706
|
+
isWritable: true
|
|
3707
|
+
},
|
|
3708
|
+
tokenProgram: { value: input.tokenProgram ?? null, isWritable: false }
|
|
3709
|
+
};
|
|
3710
|
+
const accounts = originalAccounts;
|
|
3711
|
+
const getAccountMeta = getAccountMetaFactory(programAddress, "programId");
|
|
3712
|
+
return Object.freeze({
|
|
3713
|
+
accounts: [
|
|
3714
|
+
getAccountMeta(accounts.owner),
|
|
3715
|
+
getAccountMeta(accounts.market),
|
|
3716
|
+
getAccountMeta(accounts.stakeAccount),
|
|
3717
|
+
getAccountMeta(accounts.option),
|
|
3718
|
+
getAccountMeta(accounts.tokenMint),
|
|
3719
|
+
getAccountMeta(accounts.marketTokenAta),
|
|
3720
|
+
getAccountMeta(accounts.ownerTokenAccount),
|
|
3721
|
+
getAccountMeta(accounts.tokenProgram)
|
|
3722
|
+
],
|
|
3723
|
+
data: getClaimRewardsInstructionDataEncoder().encode({}),
|
|
3724
|
+
programAddress
|
|
3725
|
+
});
|
|
3726
|
+
}
|
|
3727
|
+
function parseClaimRewardsInstruction(instruction) {
|
|
3728
|
+
if (instruction.accounts.length < 8) {
|
|
3729
|
+
throw new Error("Not enough accounts");
|
|
3730
|
+
}
|
|
3731
|
+
let accountIndex = 0;
|
|
3732
|
+
const getNextAccount = () => {
|
|
3733
|
+
const accountMeta = instruction.accounts[accountIndex];
|
|
3734
|
+
accountIndex += 1;
|
|
3735
|
+
return accountMeta;
|
|
3736
|
+
};
|
|
3737
|
+
return {
|
|
3738
|
+
programAddress: instruction.programAddress,
|
|
3739
|
+
accounts: {
|
|
3740
|
+
owner: getNextAccount(),
|
|
3741
|
+
market: getNextAccount(),
|
|
3742
|
+
stakeAccount: getNextAccount(),
|
|
3743
|
+
option: getNextAccount(),
|
|
3744
|
+
tokenMint: getNextAccount(),
|
|
3745
|
+
marketTokenAta: getNextAccount(),
|
|
3746
|
+
ownerTokenAccount: getNextAccount(),
|
|
3747
|
+
tokenProgram: getNextAccount()
|
|
3748
|
+
},
|
|
3749
|
+
data: getClaimRewardsInstructionDataDecoder().decode(instruction.data)
|
|
3750
|
+
};
|
|
3751
|
+
}
|
|
3752
|
+
|
|
3553
3753
|
// src/generated/instructions/closeOptionAccount.ts
|
|
3554
|
-
var
|
|
3754
|
+
var import_kit64 = require("@solana/kit");
|
|
3555
3755
|
var CLOSE_OPTION_ACCOUNT_DISCRIMINATOR = new Uint8Array([
|
|
3556
3756
|
46,
|
|
3557
3757
|
121,
|
|
@@ -3563,27 +3763,27 @@ var CLOSE_OPTION_ACCOUNT_DISCRIMINATOR = new Uint8Array([
|
|
|
3563
3763
|
1
|
|
3564
3764
|
]);
|
|
3565
3765
|
function getCloseOptionAccountDiscriminatorBytes() {
|
|
3566
|
-
return (0,
|
|
3766
|
+
return (0, import_kit64.fixEncoderSize)((0, import_kit64.getBytesEncoder)(), 8).encode(
|
|
3567
3767
|
CLOSE_OPTION_ACCOUNT_DISCRIMINATOR
|
|
3568
3768
|
);
|
|
3569
3769
|
}
|
|
3570
3770
|
function getCloseOptionAccountInstructionDataEncoder() {
|
|
3571
|
-
return (0,
|
|
3572
|
-
(0,
|
|
3573
|
-
["discriminator", (0,
|
|
3574
|
-
["optionId", (0,
|
|
3771
|
+
return (0, import_kit64.transformEncoder)(
|
|
3772
|
+
(0, import_kit64.getStructEncoder)([
|
|
3773
|
+
["discriminator", (0, import_kit64.fixEncoderSize)((0, import_kit64.getBytesEncoder)(), 8)],
|
|
3774
|
+
["optionId", (0, import_kit64.getU64Encoder)()]
|
|
3575
3775
|
]),
|
|
3576
3776
|
(value) => ({ ...value, discriminator: CLOSE_OPTION_ACCOUNT_DISCRIMINATOR })
|
|
3577
3777
|
);
|
|
3578
3778
|
}
|
|
3579
3779
|
function getCloseOptionAccountInstructionDataDecoder() {
|
|
3580
|
-
return (0,
|
|
3581
|
-
["discriminator", (0,
|
|
3582
|
-
["optionId", (0,
|
|
3780
|
+
return (0, import_kit64.getStructDecoder)([
|
|
3781
|
+
["discriminator", (0, import_kit64.fixDecoderSize)((0, import_kit64.getBytesDecoder)(), 8)],
|
|
3782
|
+
["optionId", (0, import_kit64.getU64Decoder)()]
|
|
3583
3783
|
]);
|
|
3584
3784
|
}
|
|
3585
3785
|
function getCloseOptionAccountInstructionDataCodec() {
|
|
3586
|
-
return (0,
|
|
3786
|
+
return (0, import_kit64.combineCodec)(
|
|
3587
3787
|
getCloseOptionAccountInstructionDataEncoder(),
|
|
3588
3788
|
getCloseOptionAccountInstructionDataDecoder()
|
|
3589
3789
|
);
|
|
@@ -3600,14 +3800,14 @@ async function getCloseOptionAccountInstructionAsync(input, config) {
|
|
|
3600
3800
|
const accounts = originalAccounts;
|
|
3601
3801
|
const args = { ...input };
|
|
3602
3802
|
if (!accounts.option.value) {
|
|
3603
|
-
accounts.option.value = await (0,
|
|
3803
|
+
accounts.option.value = await (0, import_kit64.getProgramDerivedAddress)({
|
|
3604
3804
|
programAddress,
|
|
3605
3805
|
seeds: [
|
|
3606
|
-
(0,
|
|
3806
|
+
(0, import_kit64.getBytesEncoder)().encode(
|
|
3607
3807
|
new Uint8Array([111, 112, 116, 105, 111, 110])
|
|
3608
3808
|
),
|
|
3609
|
-
(0,
|
|
3610
|
-
(0,
|
|
3809
|
+
(0, import_kit64.getAddressEncoder)().encode(expectAddress(accounts.market.value)),
|
|
3810
|
+
(0, import_kit64.getU64Encoder)().encode(expectSome(args.optionId))
|
|
3611
3811
|
]
|
|
3612
3812
|
});
|
|
3613
3813
|
}
|
|
@@ -3684,7 +3884,7 @@ function parseCloseOptionAccountInstruction(instruction) {
|
|
|
3684
3884
|
}
|
|
3685
3885
|
|
|
3686
3886
|
// src/generated/instructions/closeStakeAccount.ts
|
|
3687
|
-
var
|
|
3887
|
+
var import_kit65 = require("@solana/kit");
|
|
3688
3888
|
var CLOSE_STAKE_ACCOUNT_DISCRIMINATOR = new Uint8Array([
|
|
3689
3889
|
246,
|
|
3690
3890
|
236,
|
|
@@ -3696,29 +3896,23 @@ var CLOSE_STAKE_ACCOUNT_DISCRIMINATOR = new Uint8Array([
|
|
|
3696
3896
|
12
|
|
3697
3897
|
]);
|
|
3698
3898
|
function getCloseStakeAccountDiscriminatorBytes() {
|
|
3699
|
-
return (0,
|
|
3899
|
+
return (0, import_kit65.fixEncoderSize)((0, import_kit65.getBytesEncoder)(), 8).encode(
|
|
3700
3900
|
CLOSE_STAKE_ACCOUNT_DISCRIMINATOR
|
|
3701
3901
|
);
|
|
3702
3902
|
}
|
|
3703
3903
|
function getCloseStakeAccountInstructionDataEncoder() {
|
|
3704
|
-
return (0,
|
|
3705
|
-
(0,
|
|
3706
|
-
["discriminator", (0, import_kit63.fixEncoderSize)((0, import_kit63.getBytesEncoder)(), 8)],
|
|
3707
|
-
["optionId", (0, import_kit63.getU64Encoder)()],
|
|
3708
|
-
["stakeAccountId", (0, import_kit63.getU32Encoder)()]
|
|
3709
|
-
]),
|
|
3904
|
+
return (0, import_kit65.transformEncoder)(
|
|
3905
|
+
(0, import_kit65.getStructEncoder)([["discriminator", (0, import_kit65.fixEncoderSize)((0, import_kit65.getBytesEncoder)(), 8)]]),
|
|
3710
3906
|
(value) => ({ ...value, discriminator: CLOSE_STAKE_ACCOUNT_DISCRIMINATOR })
|
|
3711
3907
|
);
|
|
3712
3908
|
}
|
|
3713
3909
|
function getCloseStakeAccountInstructionDataDecoder() {
|
|
3714
|
-
return (0,
|
|
3715
|
-
["discriminator", (0,
|
|
3716
|
-
["optionId", (0, import_kit63.getU64Decoder)()],
|
|
3717
|
-
["stakeAccountId", (0, import_kit63.getU32Decoder)()]
|
|
3910
|
+
return (0, import_kit65.getStructDecoder)([
|
|
3911
|
+
["discriminator", (0, import_kit65.fixDecoderSize)((0, import_kit65.getBytesDecoder)(), 8)]
|
|
3718
3912
|
]);
|
|
3719
3913
|
}
|
|
3720
3914
|
function getCloseStakeAccountInstructionDataCodec() {
|
|
3721
|
-
return (0,
|
|
3915
|
+
return (0, import_kit65.combineCodec)(
|
|
3722
3916
|
getCloseStakeAccountInstructionDataEncoder(),
|
|
3723
3917
|
getCloseStakeAccountInstructionDataDecoder()
|
|
3724
3918
|
);
|
|
@@ -3740,53 +3934,13 @@ async function getCloseStakeAccountInstructionAsync(input, config) {
|
|
|
3740
3934
|
systemProgram: { value: input.systemProgram ?? null, isWritable: false }
|
|
3741
3935
|
};
|
|
3742
3936
|
const accounts = originalAccounts;
|
|
3743
|
-
const args = { ...input };
|
|
3744
|
-
if (!accounts.stakeAccount.value) {
|
|
3745
|
-
accounts.stakeAccount.value = await (0, import_kit63.getProgramDerivedAddress)({
|
|
3746
|
-
programAddress,
|
|
3747
|
-
seeds: [
|
|
3748
|
-
(0, import_kit63.getBytesEncoder)().encode(
|
|
3749
|
-
new Uint8Array([
|
|
3750
|
-
115,
|
|
3751
|
-
116,
|
|
3752
|
-
97,
|
|
3753
|
-
107,
|
|
3754
|
-
101,
|
|
3755
|
-
95,
|
|
3756
|
-
97,
|
|
3757
|
-
99,
|
|
3758
|
-
99,
|
|
3759
|
-
111,
|
|
3760
|
-
117,
|
|
3761
|
-
110,
|
|
3762
|
-
116
|
|
3763
|
-
])
|
|
3764
|
-
),
|
|
3765
|
-
(0, import_kit63.getAddressEncoder)().encode(expectAddress(accounts.owner.value)),
|
|
3766
|
-
(0, import_kit63.getAddressEncoder)().encode(expectAddress(accounts.market.value)),
|
|
3767
|
-
(0, import_kit63.getU32Encoder)().encode(expectSome(args.stakeAccountId))
|
|
3768
|
-
]
|
|
3769
|
-
});
|
|
3770
|
-
}
|
|
3771
|
-
if (!accounts.option.value) {
|
|
3772
|
-
accounts.option.value = await (0, import_kit63.getProgramDerivedAddress)({
|
|
3773
|
-
programAddress,
|
|
3774
|
-
seeds: [
|
|
3775
|
-
(0, import_kit63.getBytesEncoder)().encode(
|
|
3776
|
-
new Uint8Array([111, 112, 116, 105, 111, 110])
|
|
3777
|
-
),
|
|
3778
|
-
(0, import_kit63.getAddressEncoder)().encode(expectAddress(accounts.market.value)),
|
|
3779
|
-
(0, import_kit63.getU64Encoder)().encode(expectSome(args.optionId))
|
|
3780
|
-
]
|
|
3781
|
-
});
|
|
3782
|
-
}
|
|
3783
3937
|
if (!accounts.marketTokenAta.value) {
|
|
3784
|
-
accounts.marketTokenAta.value = await (0,
|
|
3938
|
+
accounts.marketTokenAta.value = await (0, import_kit65.getProgramDerivedAddress)({
|
|
3785
3939
|
programAddress: "ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL",
|
|
3786
3940
|
seeds: [
|
|
3787
|
-
(0,
|
|
3788
|
-
(0,
|
|
3789
|
-
(0,
|
|
3941
|
+
(0, import_kit65.getAddressEncoder)().encode(expectAddress(accounts.market.value)),
|
|
3942
|
+
(0, import_kit65.getAddressEncoder)().encode(expectAddress(accounts.tokenProgram.value)),
|
|
3943
|
+
(0, import_kit65.getAddressEncoder)().encode(expectAddress(accounts.tokenMint.value))
|
|
3790
3944
|
]
|
|
3791
3945
|
});
|
|
3792
3946
|
}
|
|
@@ -3806,9 +3960,7 @@ async function getCloseStakeAccountInstructionAsync(input, config) {
|
|
|
3806
3960
|
getAccountMeta(accounts.tokenProgram),
|
|
3807
3961
|
getAccountMeta(accounts.systemProgram)
|
|
3808
3962
|
],
|
|
3809
|
-
data: getCloseStakeAccountInstructionDataEncoder().encode(
|
|
3810
|
-
args
|
|
3811
|
-
),
|
|
3963
|
+
data: getCloseStakeAccountInstructionDataEncoder().encode({}),
|
|
3812
3964
|
programAddress
|
|
3813
3965
|
});
|
|
3814
3966
|
}
|
|
@@ -3829,7 +3981,6 @@ function getCloseStakeAccountInstruction(input, config) {
|
|
|
3829
3981
|
systemProgram: { value: input.systemProgram ?? null, isWritable: false }
|
|
3830
3982
|
};
|
|
3831
3983
|
const accounts = originalAccounts;
|
|
3832
|
-
const args = { ...input };
|
|
3833
3984
|
if (!accounts.systemProgram.value) {
|
|
3834
3985
|
accounts.systemProgram.value = "11111111111111111111111111111111";
|
|
3835
3986
|
}
|
|
@@ -3846,9 +3997,7 @@ function getCloseStakeAccountInstruction(input, config) {
|
|
|
3846
3997
|
getAccountMeta(accounts.tokenProgram),
|
|
3847
3998
|
getAccountMeta(accounts.systemProgram)
|
|
3848
3999
|
],
|
|
3849
|
-
data: getCloseStakeAccountInstructionDataEncoder().encode(
|
|
3850
|
-
args
|
|
3851
|
-
),
|
|
4000
|
+
data: getCloseStakeAccountInstructionDataEncoder().encode({}),
|
|
3852
4001
|
programAddress
|
|
3853
4002
|
});
|
|
3854
4003
|
}
|
|
@@ -3880,7 +4029,7 @@ function parseCloseStakeAccountInstruction(instruction) {
|
|
|
3880
4029
|
}
|
|
3881
4030
|
|
|
3882
4031
|
// src/generated/instructions/closeStuckStakeAccount.ts
|
|
3883
|
-
var
|
|
4032
|
+
var import_kit66 = require("@solana/kit");
|
|
3884
4033
|
var CLOSE_STUCK_STAKE_ACCOUNT_DISCRIMINATOR = new Uint8Array([
|
|
3885
4034
|
41,
|
|
3886
4035
|
239,
|
|
@@ -3892,15 +4041,15 @@ var CLOSE_STUCK_STAKE_ACCOUNT_DISCRIMINATOR = new Uint8Array([
|
|
|
3892
4041
|
181
|
|
3893
4042
|
]);
|
|
3894
4043
|
function getCloseStuckStakeAccountDiscriminatorBytes() {
|
|
3895
|
-
return (0,
|
|
4044
|
+
return (0, import_kit66.fixEncoderSize)((0, import_kit66.getBytesEncoder)(), 8).encode(
|
|
3896
4045
|
CLOSE_STUCK_STAKE_ACCOUNT_DISCRIMINATOR
|
|
3897
4046
|
);
|
|
3898
4047
|
}
|
|
3899
4048
|
function getCloseStuckStakeAccountInstructionDataEncoder() {
|
|
3900
|
-
return (0,
|
|
3901
|
-
(0,
|
|
3902
|
-
["discriminator", (0,
|
|
3903
|
-
["stakeAccountId", (0,
|
|
4049
|
+
return (0, import_kit66.transformEncoder)(
|
|
4050
|
+
(0, import_kit66.getStructEncoder)([
|
|
4051
|
+
["discriminator", (0, import_kit66.fixEncoderSize)((0, import_kit66.getBytesEncoder)(), 8)],
|
|
4052
|
+
["stakeAccountId", (0, import_kit66.getU32Encoder)()]
|
|
3904
4053
|
]),
|
|
3905
4054
|
(value) => ({
|
|
3906
4055
|
...value,
|
|
@@ -3909,13 +4058,13 @@ function getCloseStuckStakeAccountInstructionDataEncoder() {
|
|
|
3909
4058
|
);
|
|
3910
4059
|
}
|
|
3911
4060
|
function getCloseStuckStakeAccountInstructionDataDecoder() {
|
|
3912
|
-
return (0,
|
|
3913
|
-
["discriminator", (0,
|
|
3914
|
-
["stakeAccountId", (0,
|
|
4061
|
+
return (0, import_kit66.getStructDecoder)([
|
|
4062
|
+
["discriminator", (0, import_kit66.fixDecoderSize)((0, import_kit66.getBytesDecoder)(), 8)],
|
|
4063
|
+
["stakeAccountId", (0, import_kit66.getU32Decoder)()]
|
|
3915
4064
|
]);
|
|
3916
4065
|
}
|
|
3917
4066
|
function getCloseStuckStakeAccountInstructionDataCodec() {
|
|
3918
|
-
return (0,
|
|
4067
|
+
return (0, import_kit66.combineCodec)(
|
|
3919
4068
|
getCloseStuckStakeAccountInstructionDataEncoder(),
|
|
3920
4069
|
getCloseStuckStakeAccountInstructionDataDecoder()
|
|
3921
4070
|
);
|
|
@@ -3938,10 +4087,10 @@ async function getCloseStuckStakeAccountInstructionAsync(input, config) {
|
|
|
3938
4087
|
const accounts = originalAccounts;
|
|
3939
4088
|
const args = { ...input };
|
|
3940
4089
|
if (!accounts.stakeAccount.value) {
|
|
3941
|
-
accounts.stakeAccount.value = await (0,
|
|
4090
|
+
accounts.stakeAccount.value = await (0, import_kit66.getProgramDerivedAddress)({
|
|
3942
4091
|
programAddress,
|
|
3943
4092
|
seeds: [
|
|
3944
|
-
(0,
|
|
4093
|
+
(0, import_kit66.getBytesEncoder)().encode(
|
|
3945
4094
|
new Uint8Array([
|
|
3946
4095
|
115,
|
|
3947
4096
|
116,
|
|
@@ -3958,19 +4107,19 @@ async function getCloseStuckStakeAccountInstructionAsync(input, config) {
|
|
|
3958
4107
|
116
|
|
3959
4108
|
])
|
|
3960
4109
|
),
|
|
3961
|
-
(0,
|
|
3962
|
-
(0,
|
|
3963
|
-
(0,
|
|
4110
|
+
(0, import_kit66.getAddressEncoder)().encode(expectAddress(accounts.signer.value)),
|
|
4111
|
+
(0, import_kit66.getAddressEncoder)().encode(expectAddress(accounts.market.value)),
|
|
4112
|
+
(0, import_kit66.getU32Encoder)().encode(expectSome(args.stakeAccountId))
|
|
3964
4113
|
]
|
|
3965
4114
|
});
|
|
3966
4115
|
}
|
|
3967
4116
|
if (!accounts.marketTokenAta.value) {
|
|
3968
|
-
accounts.marketTokenAta.value = await (0,
|
|
4117
|
+
accounts.marketTokenAta.value = await (0, import_kit66.getProgramDerivedAddress)({
|
|
3969
4118
|
programAddress: "ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL",
|
|
3970
4119
|
seeds: [
|
|
3971
|
-
(0,
|
|
3972
|
-
(0,
|
|
3973
|
-
(0,
|
|
4120
|
+
(0, import_kit66.getAddressEncoder)().encode(expectAddress(accounts.market.value)),
|
|
4121
|
+
(0, import_kit66.getAddressEncoder)().encode(expectAddress(accounts.tokenProgram.value)),
|
|
4122
|
+
(0, import_kit66.getAddressEncoder)().encode(expectAddress(accounts.tokenMint.value))
|
|
3974
4123
|
]
|
|
3975
4124
|
});
|
|
3976
4125
|
}
|
|
@@ -4061,8 +4210,153 @@ function parseCloseStuckStakeAccountInstruction(instruction) {
|
|
|
4061
4210
|
};
|
|
4062
4211
|
}
|
|
4063
4212
|
|
|
4213
|
+
// src/generated/instructions/closeUnrevealedStakeAccount.ts
|
|
4214
|
+
var import_kit67 = require("@solana/kit");
|
|
4215
|
+
var CLOSE_UNREVEALED_STAKE_ACCOUNT_DISCRIMINATOR = new Uint8Array([
|
|
4216
|
+
171,
|
|
4217
|
+
229,
|
|
4218
|
+
236,
|
|
4219
|
+
216,
|
|
4220
|
+
122,
|
|
4221
|
+
118,
|
|
4222
|
+
188,
|
|
4223
|
+
103
|
|
4224
|
+
]);
|
|
4225
|
+
function getCloseUnrevealedStakeAccountDiscriminatorBytes() {
|
|
4226
|
+
return (0, import_kit67.fixEncoderSize)((0, import_kit67.getBytesEncoder)(), 8).encode(
|
|
4227
|
+
CLOSE_UNREVEALED_STAKE_ACCOUNT_DISCRIMINATOR
|
|
4228
|
+
);
|
|
4229
|
+
}
|
|
4230
|
+
function getCloseUnrevealedStakeAccountInstructionDataEncoder() {
|
|
4231
|
+
return (0, import_kit67.transformEncoder)(
|
|
4232
|
+
(0, import_kit67.getStructEncoder)([["discriminator", (0, import_kit67.fixEncoderSize)((0, import_kit67.getBytesEncoder)(), 8)]]),
|
|
4233
|
+
(value) => ({
|
|
4234
|
+
...value,
|
|
4235
|
+
discriminator: CLOSE_UNREVEALED_STAKE_ACCOUNT_DISCRIMINATOR
|
|
4236
|
+
})
|
|
4237
|
+
);
|
|
4238
|
+
}
|
|
4239
|
+
function getCloseUnrevealedStakeAccountInstructionDataDecoder() {
|
|
4240
|
+
return (0, import_kit67.getStructDecoder)([
|
|
4241
|
+
["discriminator", (0, import_kit67.fixDecoderSize)((0, import_kit67.getBytesDecoder)(), 8)]
|
|
4242
|
+
]);
|
|
4243
|
+
}
|
|
4244
|
+
function getCloseUnrevealedStakeAccountInstructionDataCodec() {
|
|
4245
|
+
return (0, import_kit67.combineCodec)(
|
|
4246
|
+
getCloseUnrevealedStakeAccountInstructionDataEncoder(),
|
|
4247
|
+
getCloseUnrevealedStakeAccountInstructionDataDecoder()
|
|
4248
|
+
);
|
|
4249
|
+
}
|
|
4250
|
+
async function getCloseUnrevealedStakeAccountInstructionAsync(input, config) {
|
|
4251
|
+
const programAddress = config?.programAddress ?? OPPORTUNITY_MARKET_PROGRAM_ADDRESS;
|
|
4252
|
+
const originalAccounts = {
|
|
4253
|
+
owner: { value: input.owner ?? null, isWritable: true },
|
|
4254
|
+
market: { value: input.market ?? null, isWritable: true },
|
|
4255
|
+
stakeAccount: { value: input.stakeAccount ?? null, isWritable: true },
|
|
4256
|
+
tokenMint: { value: input.tokenMint ?? null, isWritable: false },
|
|
4257
|
+
marketTokenAta: { value: input.marketTokenAta ?? null, isWritable: true },
|
|
4258
|
+
ownerTokenAccount: {
|
|
4259
|
+
value: input.ownerTokenAccount ?? null,
|
|
4260
|
+
isWritable: true
|
|
4261
|
+
},
|
|
4262
|
+
tokenProgram: { value: input.tokenProgram ?? null, isWritable: false },
|
|
4263
|
+
systemProgram: { value: input.systemProgram ?? null, isWritable: false }
|
|
4264
|
+
};
|
|
4265
|
+
const accounts = originalAccounts;
|
|
4266
|
+
if (!accounts.marketTokenAta.value) {
|
|
4267
|
+
accounts.marketTokenAta.value = await (0, import_kit67.getProgramDerivedAddress)({
|
|
4268
|
+
programAddress: "ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL",
|
|
4269
|
+
seeds: [
|
|
4270
|
+
(0, import_kit67.getAddressEncoder)().encode(expectAddress(accounts.market.value)),
|
|
4271
|
+
(0, import_kit67.getAddressEncoder)().encode(expectAddress(accounts.tokenProgram.value)),
|
|
4272
|
+
(0, import_kit67.getAddressEncoder)().encode(expectAddress(accounts.tokenMint.value))
|
|
4273
|
+
]
|
|
4274
|
+
});
|
|
4275
|
+
}
|
|
4276
|
+
if (!accounts.systemProgram.value) {
|
|
4277
|
+
accounts.systemProgram.value = "11111111111111111111111111111111";
|
|
4278
|
+
}
|
|
4279
|
+
const getAccountMeta = getAccountMetaFactory(programAddress, "programId");
|
|
4280
|
+
return Object.freeze({
|
|
4281
|
+
accounts: [
|
|
4282
|
+
getAccountMeta(accounts.owner),
|
|
4283
|
+
getAccountMeta(accounts.market),
|
|
4284
|
+
getAccountMeta(accounts.stakeAccount),
|
|
4285
|
+
getAccountMeta(accounts.tokenMint),
|
|
4286
|
+
getAccountMeta(accounts.marketTokenAta),
|
|
4287
|
+
getAccountMeta(accounts.ownerTokenAccount),
|
|
4288
|
+
getAccountMeta(accounts.tokenProgram),
|
|
4289
|
+
getAccountMeta(accounts.systemProgram)
|
|
4290
|
+
],
|
|
4291
|
+
data: getCloseUnrevealedStakeAccountInstructionDataEncoder().encode({}),
|
|
4292
|
+
programAddress
|
|
4293
|
+
});
|
|
4294
|
+
}
|
|
4295
|
+
function getCloseUnrevealedStakeAccountInstruction(input, config) {
|
|
4296
|
+
const programAddress = config?.programAddress ?? OPPORTUNITY_MARKET_PROGRAM_ADDRESS;
|
|
4297
|
+
const originalAccounts = {
|
|
4298
|
+
owner: { value: input.owner ?? null, isWritable: true },
|
|
4299
|
+
market: { value: input.market ?? null, isWritable: true },
|
|
4300
|
+
stakeAccount: { value: input.stakeAccount ?? null, isWritable: true },
|
|
4301
|
+
tokenMint: { value: input.tokenMint ?? null, isWritable: false },
|
|
4302
|
+
marketTokenAta: { value: input.marketTokenAta ?? null, isWritable: true },
|
|
4303
|
+
ownerTokenAccount: {
|
|
4304
|
+
value: input.ownerTokenAccount ?? null,
|
|
4305
|
+
isWritable: true
|
|
4306
|
+
},
|
|
4307
|
+
tokenProgram: { value: input.tokenProgram ?? null, isWritable: false },
|
|
4308
|
+
systemProgram: { value: input.systemProgram ?? null, isWritable: false }
|
|
4309
|
+
};
|
|
4310
|
+
const accounts = originalAccounts;
|
|
4311
|
+
if (!accounts.systemProgram.value) {
|
|
4312
|
+
accounts.systemProgram.value = "11111111111111111111111111111111";
|
|
4313
|
+
}
|
|
4314
|
+
const getAccountMeta = getAccountMetaFactory(programAddress, "programId");
|
|
4315
|
+
return Object.freeze({
|
|
4316
|
+
accounts: [
|
|
4317
|
+
getAccountMeta(accounts.owner),
|
|
4318
|
+
getAccountMeta(accounts.market),
|
|
4319
|
+
getAccountMeta(accounts.stakeAccount),
|
|
4320
|
+
getAccountMeta(accounts.tokenMint),
|
|
4321
|
+
getAccountMeta(accounts.marketTokenAta),
|
|
4322
|
+
getAccountMeta(accounts.ownerTokenAccount),
|
|
4323
|
+
getAccountMeta(accounts.tokenProgram),
|
|
4324
|
+
getAccountMeta(accounts.systemProgram)
|
|
4325
|
+
],
|
|
4326
|
+
data: getCloseUnrevealedStakeAccountInstructionDataEncoder().encode({}),
|
|
4327
|
+
programAddress
|
|
4328
|
+
});
|
|
4329
|
+
}
|
|
4330
|
+
function parseCloseUnrevealedStakeAccountInstruction(instruction) {
|
|
4331
|
+
if (instruction.accounts.length < 8) {
|
|
4332
|
+
throw new Error("Not enough accounts");
|
|
4333
|
+
}
|
|
4334
|
+
let accountIndex = 0;
|
|
4335
|
+
const getNextAccount = () => {
|
|
4336
|
+
const accountMeta = instruction.accounts[accountIndex];
|
|
4337
|
+
accountIndex += 1;
|
|
4338
|
+
return accountMeta;
|
|
4339
|
+
};
|
|
4340
|
+
return {
|
|
4341
|
+
programAddress: instruction.programAddress,
|
|
4342
|
+
accounts: {
|
|
4343
|
+
owner: getNextAccount(),
|
|
4344
|
+
market: getNextAccount(),
|
|
4345
|
+
stakeAccount: getNextAccount(),
|
|
4346
|
+
tokenMint: getNextAccount(),
|
|
4347
|
+
marketTokenAta: getNextAccount(),
|
|
4348
|
+
ownerTokenAccount: getNextAccount(),
|
|
4349
|
+
tokenProgram: getNextAccount(),
|
|
4350
|
+
systemProgram: getNextAccount()
|
|
4351
|
+
},
|
|
4352
|
+
data: getCloseUnrevealedStakeAccountInstructionDataDecoder().decode(
|
|
4353
|
+
instruction.data
|
|
4354
|
+
)
|
|
4355
|
+
};
|
|
4356
|
+
}
|
|
4357
|
+
|
|
4064
4358
|
// src/generated/instructions/createMarket.ts
|
|
4065
|
-
var
|
|
4359
|
+
var import_kit68 = require("@solana/kit");
|
|
4066
4360
|
var CREATE_MARKET_DISCRIMINATOR = new Uint8Array([
|
|
4067
4361
|
103,
|
|
4068
4362
|
226,
|
|
@@ -4074,41 +4368,39 @@ var CREATE_MARKET_DISCRIMINATOR = new Uint8Array([
|
|
|
4074
4368
|
254
|
|
4075
4369
|
]);
|
|
4076
4370
|
function getCreateMarketDiscriminatorBytes() {
|
|
4077
|
-
return (0,
|
|
4371
|
+
return (0, import_kit68.fixEncoderSize)((0, import_kit68.getBytesEncoder)(), 8).encode(
|
|
4078
4372
|
CREATE_MARKET_DISCRIMINATOR
|
|
4079
4373
|
);
|
|
4080
4374
|
}
|
|
4081
4375
|
function getCreateMarketInstructionDataEncoder() {
|
|
4082
|
-
return (0,
|
|
4083
|
-
(0,
|
|
4084
|
-
["discriminator", (0,
|
|
4085
|
-
["marketIndex", (0,
|
|
4086
|
-
["marketAuthority", (0,
|
|
4087
|
-
["
|
|
4088
|
-
["
|
|
4089
|
-
["
|
|
4090
|
-
["
|
|
4091
|
-
["
|
|
4092
|
-
["creatorFeeClaimer", (0, import_kit65.getAddressEncoder)()]
|
|
4376
|
+
return (0, import_kit68.transformEncoder)(
|
|
4377
|
+
(0, import_kit68.getStructEncoder)([
|
|
4378
|
+
["discriminator", (0, import_kit68.fixEncoderSize)((0, import_kit68.getBytesEncoder)(), 8)],
|
|
4379
|
+
["marketIndex", (0, import_kit68.getU64Encoder)()],
|
|
4380
|
+
["marketAuthority", (0, import_kit68.getAddressEncoder)()],
|
|
4381
|
+
["authorizedReaderPubkey", (0, import_kit68.getArrayEncoder)((0, import_kit68.getU8Encoder)(), { size: 32 })],
|
|
4382
|
+
["earlinessCutoffSeconds", (0, import_kit68.getU64Encoder)()],
|
|
4383
|
+
["earlinessMultiplier", (0, import_kit68.getU16Encoder)()],
|
|
4384
|
+
["minStakeAmount", (0, import_kit68.getU64Encoder)()],
|
|
4385
|
+
["creatorFeeClaimer", (0, import_kit68.getAddressEncoder)()]
|
|
4093
4386
|
]),
|
|
4094
4387
|
(value) => ({ ...value, discriminator: CREATE_MARKET_DISCRIMINATOR })
|
|
4095
4388
|
);
|
|
4096
4389
|
}
|
|
4097
4390
|
function getCreateMarketInstructionDataDecoder() {
|
|
4098
|
-
return (0,
|
|
4099
|
-
["discriminator", (0,
|
|
4100
|
-
["marketIndex", (0,
|
|
4101
|
-
["marketAuthority", (0,
|
|
4102
|
-
["
|
|
4103
|
-
["
|
|
4104
|
-
["
|
|
4105
|
-
["
|
|
4106
|
-
["
|
|
4107
|
-
["creatorFeeClaimer", (0, import_kit65.getAddressDecoder)()]
|
|
4391
|
+
return (0, import_kit68.getStructDecoder)([
|
|
4392
|
+
["discriminator", (0, import_kit68.fixDecoderSize)((0, import_kit68.getBytesDecoder)(), 8)],
|
|
4393
|
+
["marketIndex", (0, import_kit68.getU64Decoder)()],
|
|
4394
|
+
["marketAuthority", (0, import_kit68.getAddressDecoder)()],
|
|
4395
|
+
["authorizedReaderPubkey", (0, import_kit68.getArrayDecoder)((0, import_kit68.getU8Decoder)(), { size: 32 })],
|
|
4396
|
+
["earlinessCutoffSeconds", (0, import_kit68.getU64Decoder)()],
|
|
4397
|
+
["earlinessMultiplier", (0, import_kit68.getU16Decoder)()],
|
|
4398
|
+
["minStakeAmount", (0, import_kit68.getU64Decoder)()],
|
|
4399
|
+
["creatorFeeClaimer", (0, import_kit68.getAddressDecoder)()]
|
|
4108
4400
|
]);
|
|
4109
4401
|
}
|
|
4110
4402
|
function getCreateMarketInstructionDataCodec() {
|
|
4111
|
-
return (0,
|
|
4403
|
+
return (0, import_kit68.combineCodec)(
|
|
4112
4404
|
getCreateMarketInstructionDataEncoder(),
|
|
4113
4405
|
getCreateMarketInstructionDataDecoder()
|
|
4114
4406
|
);
|
|
@@ -4132,10 +4424,10 @@ async function getCreateMarketInstructionAsync(input, config) {
|
|
|
4132
4424
|
const accounts = originalAccounts;
|
|
4133
4425
|
const args = { ...input };
|
|
4134
4426
|
if (!accounts.market.value) {
|
|
4135
|
-
accounts.market.value = await (0,
|
|
4427
|
+
accounts.market.value = await (0, import_kit68.getProgramDerivedAddress)({
|
|
4136
4428
|
programAddress,
|
|
4137
4429
|
seeds: [
|
|
4138
|
-
(0,
|
|
4430
|
+
(0, import_kit68.getBytesEncoder)().encode(
|
|
4139
4431
|
new Uint8Array([
|
|
4140
4432
|
111,
|
|
4141
4433
|
112,
|
|
@@ -4157,29 +4449,29 @@ async function getCreateMarketInstructionAsync(input, config) {
|
|
|
4157
4449
|
116
|
|
4158
4450
|
])
|
|
4159
4451
|
),
|
|
4160
|
-
(0,
|
|
4452
|
+
(0, import_kit68.getAddressEncoder)().encode(
|
|
4161
4453
|
expectAddress(accounts.platformConfig.value)
|
|
4162
4454
|
),
|
|
4163
|
-
(0,
|
|
4164
|
-
(0,
|
|
4455
|
+
(0, import_kit68.getAddressEncoder)().encode(expectAddress(accounts.creator.value)),
|
|
4456
|
+
(0, import_kit68.getU64Encoder)().encode(expectSome(args.marketIndex))
|
|
4165
4457
|
]
|
|
4166
4458
|
});
|
|
4167
4459
|
}
|
|
4168
4460
|
if (!accounts.marketTokenAta.value) {
|
|
4169
|
-
accounts.marketTokenAta.value = await (0,
|
|
4461
|
+
accounts.marketTokenAta.value = await (0, import_kit68.getProgramDerivedAddress)({
|
|
4170
4462
|
programAddress: "ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL",
|
|
4171
4463
|
seeds: [
|
|
4172
|
-
(0,
|
|
4173
|
-
(0,
|
|
4174
|
-
(0,
|
|
4464
|
+
(0, import_kit68.getAddressEncoder)().encode(expectAddress(accounts.market.value)),
|
|
4465
|
+
(0, import_kit68.getAddressEncoder)().encode(expectAddress(accounts.tokenProgram.value)),
|
|
4466
|
+
(0, import_kit68.getAddressEncoder)().encode(expectAddress(accounts.tokenMint.value))
|
|
4175
4467
|
]
|
|
4176
4468
|
});
|
|
4177
4469
|
}
|
|
4178
4470
|
if (!accounts.allowedMint.value) {
|
|
4179
|
-
accounts.allowedMint.value = await (0,
|
|
4471
|
+
accounts.allowedMint.value = await (0, import_kit68.getProgramDerivedAddress)({
|
|
4180
4472
|
programAddress,
|
|
4181
4473
|
seeds: [
|
|
4182
|
-
(0,
|
|
4474
|
+
(0, import_kit68.getBytesEncoder)().encode(
|
|
4183
4475
|
new Uint8Array([
|
|
4184
4476
|
97,
|
|
4185
4477
|
108,
|
|
@@ -4195,10 +4487,10 @@ async function getCreateMarketInstructionAsync(input, config) {
|
|
|
4195
4487
|
116
|
|
4196
4488
|
])
|
|
4197
4489
|
),
|
|
4198
|
-
(0,
|
|
4490
|
+
(0, import_kit68.getAddressEncoder)().encode(
|
|
4199
4491
|
expectAddress(accounts.platformConfig.value)
|
|
4200
4492
|
),
|
|
4201
|
-
(0,
|
|
4493
|
+
(0, import_kit68.getAddressEncoder)().encode(expectAddress(accounts.tokenMint.value))
|
|
4202
4494
|
]
|
|
4203
4495
|
});
|
|
4204
4496
|
}
|
|
@@ -4298,7 +4590,7 @@ function parseCreateMarketInstruction(instruction) {
|
|
|
4298
4590
|
}
|
|
4299
4591
|
|
|
4300
4592
|
// src/generated/instructions/endRevealPeriod.ts
|
|
4301
|
-
var
|
|
4593
|
+
var import_kit69 = require("@solana/kit");
|
|
4302
4594
|
var END_REVEAL_PERIOD_DISCRIMINATOR = new Uint8Array([
|
|
4303
4595
|
144,
|
|
4304
4596
|
81,
|
|
@@ -4310,23 +4602,23 @@ var END_REVEAL_PERIOD_DISCRIMINATOR = new Uint8Array([
|
|
|
4310
4602
|
92
|
|
4311
4603
|
]);
|
|
4312
4604
|
function getEndRevealPeriodDiscriminatorBytes() {
|
|
4313
|
-
return (0,
|
|
4605
|
+
return (0, import_kit69.fixEncoderSize)((0, import_kit69.getBytesEncoder)(), 8).encode(
|
|
4314
4606
|
END_REVEAL_PERIOD_DISCRIMINATOR
|
|
4315
4607
|
);
|
|
4316
4608
|
}
|
|
4317
4609
|
function getEndRevealPeriodInstructionDataEncoder() {
|
|
4318
|
-
return (0,
|
|
4319
|
-
(0,
|
|
4610
|
+
return (0, import_kit69.transformEncoder)(
|
|
4611
|
+
(0, import_kit69.getStructEncoder)([["discriminator", (0, import_kit69.fixEncoderSize)((0, import_kit69.getBytesEncoder)(), 8)]]),
|
|
4320
4612
|
(value) => ({ ...value, discriminator: END_REVEAL_PERIOD_DISCRIMINATOR })
|
|
4321
4613
|
);
|
|
4322
4614
|
}
|
|
4323
4615
|
function getEndRevealPeriodInstructionDataDecoder() {
|
|
4324
|
-
return (0,
|
|
4325
|
-
["discriminator", (0,
|
|
4616
|
+
return (0, import_kit69.getStructDecoder)([
|
|
4617
|
+
["discriminator", (0, import_kit69.fixDecoderSize)((0, import_kit69.getBytesDecoder)(), 8)]
|
|
4326
4618
|
]);
|
|
4327
4619
|
}
|
|
4328
4620
|
function getEndRevealPeriodInstructionDataCodec() {
|
|
4329
|
-
return (0,
|
|
4621
|
+
return (0, import_kit69.combineCodec)(
|
|
4330
4622
|
getEndRevealPeriodInstructionDataEncoder(),
|
|
4331
4623
|
getEndRevealPeriodInstructionDataDecoder()
|
|
4332
4624
|
);
|
|
@@ -4372,7 +4664,7 @@ function parseEndRevealPeriodInstruction(instruction) {
|
|
|
4372
4664
|
}
|
|
4373
4665
|
|
|
4374
4666
|
// src/generated/instructions/finalizeRevealStake.ts
|
|
4375
|
-
var
|
|
4667
|
+
var import_kit70 = require("@solana/kit");
|
|
4376
4668
|
var FINALIZE_REVEAL_STAKE_DISCRIMINATOR = new Uint8Array([
|
|
4377
4669
|
92,
|
|
4378
4670
|
201,
|
|
@@ -4384,16 +4676,16 @@ var FINALIZE_REVEAL_STAKE_DISCRIMINATOR = new Uint8Array([
|
|
|
4384
4676
|
230
|
|
4385
4677
|
]);
|
|
4386
4678
|
function getFinalizeRevealStakeDiscriminatorBytes() {
|
|
4387
|
-
return (0,
|
|
4679
|
+
return (0, import_kit70.fixEncoderSize)((0, import_kit70.getBytesEncoder)(), 8).encode(
|
|
4388
4680
|
FINALIZE_REVEAL_STAKE_DISCRIMINATOR
|
|
4389
4681
|
);
|
|
4390
4682
|
}
|
|
4391
4683
|
function getFinalizeRevealStakeInstructionDataEncoder() {
|
|
4392
|
-
return (0,
|
|
4393
|
-
(0,
|
|
4394
|
-
["discriminator", (0,
|
|
4395
|
-
["optionId", (0,
|
|
4396
|
-
["stakeAccountId", (0,
|
|
4684
|
+
return (0, import_kit70.transformEncoder)(
|
|
4685
|
+
(0, import_kit70.getStructEncoder)([
|
|
4686
|
+
["discriminator", (0, import_kit70.fixEncoderSize)((0, import_kit70.getBytesEncoder)(), 8)],
|
|
4687
|
+
["optionId", (0, import_kit70.getU64Encoder)()],
|
|
4688
|
+
["stakeAccountId", (0, import_kit70.getU32Encoder)()]
|
|
4397
4689
|
]),
|
|
4398
4690
|
(value) => ({
|
|
4399
4691
|
...value,
|
|
@@ -4402,14 +4694,14 @@ function getFinalizeRevealStakeInstructionDataEncoder() {
|
|
|
4402
4694
|
);
|
|
4403
4695
|
}
|
|
4404
4696
|
function getFinalizeRevealStakeInstructionDataDecoder() {
|
|
4405
|
-
return (0,
|
|
4406
|
-
["discriminator", (0,
|
|
4407
|
-
["optionId", (0,
|
|
4408
|
-
["stakeAccountId", (0,
|
|
4697
|
+
return (0, import_kit70.getStructDecoder)([
|
|
4698
|
+
["discriminator", (0, import_kit70.fixDecoderSize)((0, import_kit70.getBytesDecoder)(), 8)],
|
|
4699
|
+
["optionId", (0, import_kit70.getU64Decoder)()],
|
|
4700
|
+
["stakeAccountId", (0, import_kit70.getU32Decoder)()]
|
|
4409
4701
|
]);
|
|
4410
4702
|
}
|
|
4411
4703
|
function getFinalizeRevealStakeInstructionDataCodec() {
|
|
4412
|
-
return (0,
|
|
4704
|
+
return (0, import_kit70.combineCodec)(
|
|
4413
4705
|
getFinalizeRevealStakeInstructionDataEncoder(),
|
|
4414
4706
|
getFinalizeRevealStakeInstructionDataDecoder()
|
|
4415
4707
|
);
|
|
@@ -4427,10 +4719,10 @@ async function getFinalizeRevealStakeInstructionAsync(input, config) {
|
|
|
4427
4719
|
const accounts = originalAccounts;
|
|
4428
4720
|
const args = { ...input };
|
|
4429
4721
|
if (!accounts.stakeAccount.value) {
|
|
4430
|
-
accounts.stakeAccount.value = await (0,
|
|
4722
|
+
accounts.stakeAccount.value = await (0, import_kit70.getProgramDerivedAddress)({
|
|
4431
4723
|
programAddress,
|
|
4432
4724
|
seeds: [
|
|
4433
|
-
(0,
|
|
4725
|
+
(0, import_kit70.getBytesEncoder)().encode(
|
|
4434
4726
|
new Uint8Array([
|
|
4435
4727
|
115,
|
|
4436
4728
|
116,
|
|
@@ -4447,21 +4739,21 @@ async function getFinalizeRevealStakeInstructionAsync(input, config) {
|
|
|
4447
4739
|
116
|
|
4448
4740
|
])
|
|
4449
4741
|
),
|
|
4450
|
-
(0,
|
|
4451
|
-
(0,
|
|
4452
|
-
(0,
|
|
4742
|
+
(0, import_kit70.getAddressEncoder)().encode(expectAddress(accounts.owner.value)),
|
|
4743
|
+
(0, import_kit70.getAddressEncoder)().encode(expectAddress(accounts.market.value)),
|
|
4744
|
+
(0, import_kit70.getU32Encoder)().encode(expectSome(args.stakeAccountId))
|
|
4453
4745
|
]
|
|
4454
4746
|
});
|
|
4455
4747
|
}
|
|
4456
4748
|
if (!accounts.option.value) {
|
|
4457
|
-
accounts.option.value = await (0,
|
|
4749
|
+
accounts.option.value = await (0, import_kit70.getProgramDerivedAddress)({
|
|
4458
4750
|
programAddress,
|
|
4459
4751
|
seeds: [
|
|
4460
|
-
(0,
|
|
4752
|
+
(0, import_kit70.getBytesEncoder)().encode(
|
|
4461
4753
|
new Uint8Array([111, 112, 116, 105, 111, 110])
|
|
4462
4754
|
),
|
|
4463
|
-
(0,
|
|
4464
|
-
(0,
|
|
4755
|
+
(0, import_kit70.getAddressEncoder)().encode(expectAddress(accounts.market.value)),
|
|
4756
|
+
(0, import_kit70.getU64Encoder)().encode(expectSome(args.optionId))
|
|
4465
4757
|
]
|
|
4466
4758
|
});
|
|
4467
4759
|
}
|
|
@@ -4542,7 +4834,7 @@ function parseFinalizeRevealStakeInstruction(instruction) {
|
|
|
4542
4834
|
}
|
|
4543
4835
|
|
|
4544
4836
|
// src/generated/instructions/initAllowedMint.ts
|
|
4545
|
-
var
|
|
4837
|
+
var import_kit71 = require("@solana/kit");
|
|
4546
4838
|
var INIT_ALLOWED_MINT_DISCRIMINATOR = new Uint8Array([
|
|
4547
4839
|
215,
|
|
4548
4840
|
70,
|
|
@@ -4554,23 +4846,23 @@ var INIT_ALLOWED_MINT_DISCRIMINATOR = new Uint8Array([
|
|
|
4554
4846
|
10
|
|
4555
4847
|
]);
|
|
4556
4848
|
function getInitAllowedMintDiscriminatorBytes() {
|
|
4557
|
-
return (0,
|
|
4849
|
+
return (0, import_kit71.fixEncoderSize)((0, import_kit71.getBytesEncoder)(), 8).encode(
|
|
4558
4850
|
INIT_ALLOWED_MINT_DISCRIMINATOR
|
|
4559
4851
|
);
|
|
4560
4852
|
}
|
|
4561
4853
|
function getInitAllowedMintInstructionDataEncoder() {
|
|
4562
|
-
return (0,
|
|
4563
|
-
(0,
|
|
4854
|
+
return (0, import_kit71.transformEncoder)(
|
|
4855
|
+
(0, import_kit71.getStructEncoder)([["discriminator", (0, import_kit71.fixEncoderSize)((0, import_kit71.getBytesEncoder)(), 8)]]),
|
|
4564
4856
|
(value) => ({ ...value, discriminator: INIT_ALLOWED_MINT_DISCRIMINATOR })
|
|
4565
4857
|
);
|
|
4566
4858
|
}
|
|
4567
4859
|
function getInitAllowedMintInstructionDataDecoder() {
|
|
4568
|
-
return (0,
|
|
4569
|
-
["discriminator", (0,
|
|
4860
|
+
return (0, import_kit71.getStructDecoder)([
|
|
4861
|
+
["discriminator", (0, import_kit71.fixDecoderSize)((0, import_kit71.getBytesDecoder)(), 8)]
|
|
4570
4862
|
]);
|
|
4571
4863
|
}
|
|
4572
4864
|
function getInitAllowedMintInstructionDataCodec() {
|
|
4573
|
-
return (0,
|
|
4865
|
+
return (0, import_kit71.combineCodec)(
|
|
4574
4866
|
getInitAllowedMintInstructionDataEncoder(),
|
|
4575
4867
|
getInitAllowedMintInstructionDataDecoder()
|
|
4576
4868
|
);
|
|
@@ -4586,10 +4878,10 @@ async function getInitAllowedMintInstructionAsync(input, config) {
|
|
|
4586
4878
|
};
|
|
4587
4879
|
const accounts = originalAccounts;
|
|
4588
4880
|
if (!accounts.allowedMint.value) {
|
|
4589
|
-
accounts.allowedMint.value = await (0,
|
|
4881
|
+
accounts.allowedMint.value = await (0, import_kit71.getProgramDerivedAddress)({
|
|
4590
4882
|
programAddress,
|
|
4591
4883
|
seeds: [
|
|
4592
|
-
(0,
|
|
4884
|
+
(0, import_kit71.getBytesEncoder)().encode(
|
|
4593
4885
|
new Uint8Array([
|
|
4594
4886
|
97,
|
|
4595
4887
|
108,
|
|
@@ -4605,10 +4897,10 @@ async function getInitAllowedMintInstructionAsync(input, config) {
|
|
|
4605
4897
|
116
|
|
4606
4898
|
])
|
|
4607
4899
|
),
|
|
4608
|
-
(0,
|
|
4900
|
+
(0, import_kit71.getAddressEncoder)().encode(
|
|
4609
4901
|
expectAddress(accounts.platformConfig.value)
|
|
4610
4902
|
),
|
|
4611
|
-
(0,
|
|
4903
|
+
(0, import_kit71.getAddressEncoder)().encode(expectAddress(accounts.tokenMint.value))
|
|
4612
4904
|
]
|
|
4613
4905
|
});
|
|
4614
4906
|
}
|
|
@@ -4678,7 +4970,7 @@ function parseInitAllowedMintInstruction(instruction) {
|
|
|
4678
4970
|
}
|
|
4679
4971
|
|
|
4680
4972
|
// src/generated/instructions/initPlatformConfig.ts
|
|
4681
|
-
var
|
|
4973
|
+
var import_kit72 = require("@solana/kit");
|
|
4682
4974
|
var INIT_PLATFORM_CONFIG_DISCRIMINATOR = new Uint8Array([
|
|
4683
4975
|
101,
|
|
4684
4976
|
52,
|
|
@@ -4690,43 +4982,43 @@ var INIT_PLATFORM_CONFIG_DISCRIMINATOR = new Uint8Array([
|
|
|
4690
4982
|
118
|
|
4691
4983
|
]);
|
|
4692
4984
|
function getInitPlatformConfigDiscriminatorBytes() {
|
|
4693
|
-
return (0,
|
|
4985
|
+
return (0, import_kit72.fixEncoderSize)((0, import_kit72.getBytesEncoder)(), 8).encode(
|
|
4694
4986
|
INIT_PLATFORM_CONFIG_DISCRIMINATOR
|
|
4695
4987
|
);
|
|
4696
4988
|
}
|
|
4697
4989
|
function getInitPlatformConfigInstructionDataEncoder() {
|
|
4698
|
-
return (0,
|
|
4699
|
-
(0,
|
|
4700
|
-
["discriminator", (0,
|
|
4701
|
-
["name", (0,
|
|
4702
|
-
["platformFeeBp", (0,
|
|
4703
|
-
["rewardPoolFeeBp", (0,
|
|
4704
|
-
["creatorFeeBp", (0,
|
|
4705
|
-
["feeClaimAuthority", (0,
|
|
4706
|
-
["revealAuthority", (0,
|
|
4707
|
-
["minTimeToStakeSeconds", (0,
|
|
4708
|
-
["revealPeriodSeconds", (0,
|
|
4709
|
-
["marketResolutionDeadlineSeconds", (0,
|
|
4990
|
+
return (0, import_kit72.transformEncoder)(
|
|
4991
|
+
(0, import_kit72.getStructEncoder)([
|
|
4992
|
+
["discriminator", (0, import_kit72.fixEncoderSize)((0, import_kit72.getBytesEncoder)(), 8)],
|
|
4993
|
+
["name", (0, import_kit72.addEncoderSizePrefix)((0, import_kit72.getUtf8Encoder)(), (0, import_kit72.getU32Encoder)())],
|
|
4994
|
+
["platformFeeBp", (0, import_kit72.getU16Encoder)()],
|
|
4995
|
+
["rewardPoolFeeBp", (0, import_kit72.getU16Encoder)()],
|
|
4996
|
+
["creatorFeeBp", (0, import_kit72.getU16Encoder)()],
|
|
4997
|
+
["feeClaimAuthority", (0, import_kit72.getAddressEncoder)()],
|
|
4998
|
+
["revealAuthority", (0, import_kit72.getAddressEncoder)()],
|
|
4999
|
+
["minTimeToStakeSeconds", (0, import_kit72.getU64Encoder)()],
|
|
5000
|
+
["revealPeriodSeconds", (0, import_kit72.getU64Encoder)()],
|
|
5001
|
+
["marketResolutionDeadlineSeconds", (0, import_kit72.getU64Encoder)()]
|
|
4710
5002
|
]),
|
|
4711
5003
|
(value) => ({ ...value, discriminator: INIT_PLATFORM_CONFIG_DISCRIMINATOR })
|
|
4712
5004
|
);
|
|
4713
5005
|
}
|
|
4714
5006
|
function getInitPlatformConfigInstructionDataDecoder() {
|
|
4715
|
-
return (0,
|
|
4716
|
-
["discriminator", (0,
|
|
4717
|
-
["name", (0,
|
|
4718
|
-
["platformFeeBp", (0,
|
|
4719
|
-
["rewardPoolFeeBp", (0,
|
|
4720
|
-
["creatorFeeBp", (0,
|
|
4721
|
-
["feeClaimAuthority", (0,
|
|
4722
|
-
["revealAuthority", (0,
|
|
4723
|
-
["minTimeToStakeSeconds", (0,
|
|
4724
|
-
["revealPeriodSeconds", (0,
|
|
4725
|
-
["marketResolutionDeadlineSeconds", (0,
|
|
5007
|
+
return (0, import_kit72.getStructDecoder)([
|
|
5008
|
+
["discriminator", (0, import_kit72.fixDecoderSize)((0, import_kit72.getBytesDecoder)(), 8)],
|
|
5009
|
+
["name", (0, import_kit72.addDecoderSizePrefix)((0, import_kit72.getUtf8Decoder)(), (0, import_kit72.getU32Decoder)())],
|
|
5010
|
+
["platformFeeBp", (0, import_kit72.getU16Decoder)()],
|
|
5011
|
+
["rewardPoolFeeBp", (0, import_kit72.getU16Decoder)()],
|
|
5012
|
+
["creatorFeeBp", (0, import_kit72.getU16Decoder)()],
|
|
5013
|
+
["feeClaimAuthority", (0, import_kit72.getAddressDecoder)()],
|
|
5014
|
+
["revealAuthority", (0, import_kit72.getAddressDecoder)()],
|
|
5015
|
+
["minTimeToStakeSeconds", (0, import_kit72.getU64Decoder)()],
|
|
5016
|
+
["revealPeriodSeconds", (0, import_kit72.getU64Decoder)()],
|
|
5017
|
+
["marketResolutionDeadlineSeconds", (0, import_kit72.getU64Decoder)()]
|
|
4726
5018
|
]);
|
|
4727
5019
|
}
|
|
4728
5020
|
function getInitPlatformConfigInstructionDataCodec() {
|
|
4729
|
-
return (0,
|
|
5021
|
+
return (0, import_kit72.combineCodec)(
|
|
4730
5022
|
getInitPlatformConfigInstructionDataEncoder(),
|
|
4731
5023
|
getInitPlatformConfigInstructionDataDecoder()
|
|
4732
5024
|
);
|
|
@@ -4741,10 +5033,10 @@ async function getInitPlatformConfigInstructionAsync(input, config) {
|
|
|
4741
5033
|
const accounts = originalAccounts;
|
|
4742
5034
|
const args = { ...input };
|
|
4743
5035
|
if (!accounts.platformConfig.value) {
|
|
4744
|
-
accounts.platformConfig.value = await (0,
|
|
5036
|
+
accounts.platformConfig.value = await (0, import_kit72.getProgramDerivedAddress)({
|
|
4745
5037
|
programAddress,
|
|
4746
5038
|
seeds: [
|
|
4747
|
-
(0,
|
|
5039
|
+
(0, import_kit72.getBytesEncoder)().encode(
|
|
4748
5040
|
new Uint8Array([
|
|
4749
5041
|
112,
|
|
4750
5042
|
108,
|
|
@@ -4763,8 +5055,8 @@ async function getInitPlatformConfigInstructionAsync(input, config) {
|
|
|
4763
5055
|
103
|
|
4764
5056
|
])
|
|
4765
5057
|
),
|
|
4766
|
-
(0,
|
|
4767
|
-
(0,
|
|
5058
|
+
(0, import_kit72.getAddressEncoder)().encode(expectAddress(accounts.payer.value)),
|
|
5059
|
+
(0, import_kit72.getUtf8Encoder)().encode(expectSome(args.name))
|
|
4768
5060
|
]
|
|
4769
5061
|
});
|
|
4770
5062
|
}
|
|
@@ -4833,7 +5125,7 @@ function parseInitPlatformConfigInstruction(instruction) {
|
|
|
4833
5125
|
}
|
|
4834
5126
|
|
|
4835
5127
|
// src/generated/instructions/initStakeAccount.ts
|
|
4836
|
-
var
|
|
5128
|
+
var import_kit73 = require("@solana/kit");
|
|
4837
5129
|
var INIT_STAKE_ACCOUNT_DISCRIMINATOR = new Uint8Array([
|
|
4838
5130
|
132,
|
|
4839
5131
|
171,
|
|
@@ -4845,27 +5137,27 @@ var INIT_STAKE_ACCOUNT_DISCRIMINATOR = new Uint8Array([
|
|
|
4845
5137
|
45
|
|
4846
5138
|
]);
|
|
4847
5139
|
function getInitStakeAccountDiscriminatorBytes() {
|
|
4848
|
-
return (0,
|
|
5140
|
+
return (0, import_kit73.fixEncoderSize)((0, import_kit73.getBytesEncoder)(), 8).encode(
|
|
4849
5141
|
INIT_STAKE_ACCOUNT_DISCRIMINATOR
|
|
4850
5142
|
);
|
|
4851
5143
|
}
|
|
4852
5144
|
function getInitStakeAccountInstructionDataEncoder() {
|
|
4853
|
-
return (0,
|
|
4854
|
-
(0,
|
|
4855
|
-
["discriminator", (0,
|
|
4856
|
-
["stakeAccountId", (0,
|
|
5145
|
+
return (0, import_kit73.transformEncoder)(
|
|
5146
|
+
(0, import_kit73.getStructEncoder)([
|
|
5147
|
+
["discriminator", (0, import_kit73.fixEncoderSize)((0, import_kit73.getBytesEncoder)(), 8)],
|
|
5148
|
+
["stakeAccountId", (0, import_kit73.getU32Encoder)()]
|
|
4857
5149
|
]),
|
|
4858
5150
|
(value) => ({ ...value, discriminator: INIT_STAKE_ACCOUNT_DISCRIMINATOR })
|
|
4859
5151
|
);
|
|
4860
5152
|
}
|
|
4861
5153
|
function getInitStakeAccountInstructionDataDecoder() {
|
|
4862
|
-
return (0,
|
|
4863
|
-
["discriminator", (0,
|
|
4864
|
-
["stakeAccountId", (0,
|
|
5154
|
+
return (0, import_kit73.getStructDecoder)([
|
|
5155
|
+
["discriminator", (0, import_kit73.fixDecoderSize)((0, import_kit73.getBytesDecoder)(), 8)],
|
|
5156
|
+
["stakeAccountId", (0, import_kit73.getU32Decoder)()]
|
|
4865
5157
|
]);
|
|
4866
5158
|
}
|
|
4867
5159
|
function getInitStakeAccountInstructionDataCodec() {
|
|
4868
|
-
return (0,
|
|
5160
|
+
return (0, import_kit73.combineCodec)(
|
|
4869
5161
|
getInitStakeAccountInstructionDataEncoder(),
|
|
4870
5162
|
getInitStakeAccountInstructionDataDecoder()
|
|
4871
5163
|
);
|
|
@@ -4882,10 +5174,10 @@ async function getInitStakeAccountInstructionAsync(input, config) {
|
|
|
4882
5174
|
const accounts = originalAccounts;
|
|
4883
5175
|
const args = { ...input };
|
|
4884
5176
|
if (!accounts.stakeAccount.value) {
|
|
4885
|
-
accounts.stakeAccount.value = await (0,
|
|
5177
|
+
accounts.stakeAccount.value = await (0, import_kit73.getProgramDerivedAddress)({
|
|
4886
5178
|
programAddress,
|
|
4887
5179
|
seeds: [
|
|
4888
|
-
(0,
|
|
5180
|
+
(0, import_kit73.getBytesEncoder)().encode(
|
|
4889
5181
|
new Uint8Array([
|
|
4890
5182
|
115,
|
|
4891
5183
|
116,
|
|
@@ -4902,9 +5194,9 @@ async function getInitStakeAccountInstructionAsync(input, config) {
|
|
|
4902
5194
|
116
|
|
4903
5195
|
])
|
|
4904
5196
|
),
|
|
4905
|
-
(0,
|
|
4906
|
-
(0,
|
|
4907
|
-
(0,
|
|
5197
|
+
(0, import_kit73.getAddressEncoder)().encode(expectAddress(accounts.owner.value)),
|
|
5198
|
+
(0, import_kit73.getAddressEncoder)().encode(expectAddress(accounts.market.value)),
|
|
5199
|
+
(0, import_kit73.getU32Encoder)().encode(expectSome(args.stakeAccountId))
|
|
4908
5200
|
]
|
|
4909
5201
|
});
|
|
4910
5202
|
}
|
|
@@ -4979,7 +5271,7 @@ function parseInitStakeAccountInstruction(instruction) {
|
|
|
4979
5271
|
}
|
|
4980
5272
|
|
|
4981
5273
|
// src/generated/instructions/openMarket.ts
|
|
4982
|
-
var
|
|
5274
|
+
var import_kit74 = require("@solana/kit");
|
|
4983
5275
|
var OPEN_MARKET_DISCRIMINATOR = new Uint8Array([
|
|
4984
5276
|
116,
|
|
4985
5277
|
19,
|
|
@@ -4991,25 +5283,25 @@ var OPEN_MARKET_DISCRIMINATOR = new Uint8Array([
|
|
|
4991
5283
|
44
|
|
4992
5284
|
]);
|
|
4993
5285
|
function getOpenMarketDiscriminatorBytes() {
|
|
4994
|
-
return (0,
|
|
5286
|
+
return (0, import_kit74.fixEncoderSize)((0, import_kit74.getBytesEncoder)(), 8).encode(OPEN_MARKET_DISCRIMINATOR);
|
|
4995
5287
|
}
|
|
4996
5288
|
function getOpenMarketInstructionDataEncoder() {
|
|
4997
|
-
return (0,
|
|
4998
|
-
(0,
|
|
4999
|
-
["discriminator", (0,
|
|
5000
|
-
["timeToStake", (0,
|
|
5289
|
+
return (0, import_kit74.transformEncoder)(
|
|
5290
|
+
(0, import_kit74.getStructEncoder)([
|
|
5291
|
+
["discriminator", (0, import_kit74.fixEncoderSize)((0, import_kit74.getBytesEncoder)(), 8)],
|
|
5292
|
+
["timeToStake", (0, import_kit74.getU64Encoder)()]
|
|
5001
5293
|
]),
|
|
5002
5294
|
(value) => ({ ...value, discriminator: OPEN_MARKET_DISCRIMINATOR })
|
|
5003
5295
|
);
|
|
5004
5296
|
}
|
|
5005
5297
|
function getOpenMarketInstructionDataDecoder() {
|
|
5006
|
-
return (0,
|
|
5007
|
-
["discriminator", (0,
|
|
5008
|
-
["timeToStake", (0,
|
|
5298
|
+
return (0, import_kit74.getStructDecoder)([
|
|
5299
|
+
["discriminator", (0, import_kit74.fixDecoderSize)((0, import_kit74.getBytesDecoder)(), 8)],
|
|
5300
|
+
["timeToStake", (0, import_kit74.getU64Decoder)()]
|
|
5009
5301
|
]);
|
|
5010
5302
|
}
|
|
5011
5303
|
function getOpenMarketInstructionDataCodec() {
|
|
5012
|
-
return (0,
|
|
5304
|
+
return (0, import_kit74.combineCodec)(
|
|
5013
5305
|
getOpenMarketInstructionDataEncoder(),
|
|
5014
5306
|
getOpenMarketInstructionDataDecoder()
|
|
5015
5307
|
);
|
|
@@ -5061,7 +5353,7 @@ function parseOpenMarketInstruction(instruction) {
|
|
|
5061
5353
|
}
|
|
5062
5354
|
|
|
5063
5355
|
// src/generated/instructions/resolveMarket.ts
|
|
5064
|
-
var
|
|
5356
|
+
var import_kit75 = require("@solana/kit");
|
|
5065
5357
|
var RESOLVE_MARKET_DISCRIMINATOR = new Uint8Array([
|
|
5066
5358
|
155,
|
|
5067
5359
|
23,
|
|
@@ -5073,23 +5365,23 @@ var RESOLVE_MARKET_DISCRIMINATOR = new Uint8Array([
|
|
|
5073
5365
|
239
|
|
5074
5366
|
]);
|
|
5075
5367
|
function getResolveMarketDiscriminatorBytes() {
|
|
5076
|
-
return (0,
|
|
5368
|
+
return (0, import_kit75.fixEncoderSize)((0, import_kit75.getBytesEncoder)(), 8).encode(
|
|
5077
5369
|
RESOLVE_MARKET_DISCRIMINATOR
|
|
5078
5370
|
);
|
|
5079
5371
|
}
|
|
5080
5372
|
function getResolveMarketInstructionDataEncoder() {
|
|
5081
|
-
return (0,
|
|
5082
|
-
(0,
|
|
5373
|
+
return (0, import_kit75.transformEncoder)(
|
|
5374
|
+
(0, import_kit75.getStructEncoder)([["discriminator", (0, import_kit75.fixEncoderSize)((0, import_kit75.getBytesEncoder)(), 8)]]),
|
|
5083
5375
|
(value) => ({ ...value, discriminator: RESOLVE_MARKET_DISCRIMINATOR })
|
|
5084
5376
|
);
|
|
5085
5377
|
}
|
|
5086
5378
|
function getResolveMarketInstructionDataDecoder() {
|
|
5087
|
-
return (0,
|
|
5088
|
-
["discriminator", (0,
|
|
5379
|
+
return (0, import_kit75.getStructDecoder)([
|
|
5380
|
+
["discriminator", (0, import_kit75.fixDecoderSize)((0, import_kit75.getBytesDecoder)(), 8)]
|
|
5089
5381
|
]);
|
|
5090
5382
|
}
|
|
5091
5383
|
function getResolveMarketInstructionDataCodec() {
|
|
5092
|
-
return (0,
|
|
5384
|
+
return (0, import_kit75.combineCodec)(
|
|
5093
5385
|
getResolveMarketInstructionDataEncoder(),
|
|
5094
5386
|
getResolveMarketInstructionDataDecoder()
|
|
5095
5387
|
);
|
|
@@ -5132,7 +5424,7 @@ function parseResolveMarketInstruction(instruction) {
|
|
|
5132
5424
|
}
|
|
5133
5425
|
|
|
5134
5426
|
// src/generated/instructions/revealStake.ts
|
|
5135
|
-
var
|
|
5427
|
+
var import_kit76 = require("@solana/kit");
|
|
5136
5428
|
var REVEAL_STAKE_DISCRIMINATOR = new Uint8Array([
|
|
5137
5429
|
107,
|
|
5138
5430
|
229,
|
|
@@ -5144,29 +5436,29 @@ var REVEAL_STAKE_DISCRIMINATOR = new Uint8Array([
|
|
|
5144
5436
|
188
|
|
5145
5437
|
]);
|
|
5146
5438
|
function getRevealStakeDiscriminatorBytes() {
|
|
5147
|
-
return (0,
|
|
5439
|
+
return (0, import_kit76.fixEncoderSize)((0, import_kit76.getBytesEncoder)(), 8).encode(
|
|
5148
5440
|
REVEAL_STAKE_DISCRIMINATOR
|
|
5149
5441
|
);
|
|
5150
5442
|
}
|
|
5151
5443
|
function getRevealStakeInstructionDataEncoder() {
|
|
5152
|
-
return (0,
|
|
5153
|
-
(0,
|
|
5154
|
-
["discriminator", (0,
|
|
5155
|
-
["computationOffset", (0,
|
|
5156
|
-
["stakeAccountId", (0,
|
|
5444
|
+
return (0, import_kit76.transformEncoder)(
|
|
5445
|
+
(0, import_kit76.getStructEncoder)([
|
|
5446
|
+
["discriminator", (0, import_kit76.fixEncoderSize)((0, import_kit76.getBytesEncoder)(), 8)],
|
|
5447
|
+
["computationOffset", (0, import_kit76.getU64Encoder)()],
|
|
5448
|
+
["stakeAccountId", (0, import_kit76.getU32Encoder)()]
|
|
5157
5449
|
]),
|
|
5158
5450
|
(value) => ({ ...value, discriminator: REVEAL_STAKE_DISCRIMINATOR })
|
|
5159
5451
|
);
|
|
5160
5452
|
}
|
|
5161
5453
|
function getRevealStakeInstructionDataDecoder() {
|
|
5162
|
-
return (0,
|
|
5163
|
-
["discriminator", (0,
|
|
5164
|
-
["computationOffset", (0,
|
|
5165
|
-
["stakeAccountId", (0,
|
|
5454
|
+
return (0, import_kit76.getStructDecoder)([
|
|
5455
|
+
["discriminator", (0, import_kit76.fixDecoderSize)((0, import_kit76.getBytesDecoder)(), 8)],
|
|
5456
|
+
["computationOffset", (0, import_kit76.getU64Decoder)()],
|
|
5457
|
+
["stakeAccountId", (0, import_kit76.getU32Decoder)()]
|
|
5166
5458
|
]);
|
|
5167
5459
|
}
|
|
5168
5460
|
function getRevealStakeInstructionDataCodec() {
|
|
5169
|
-
return (0,
|
|
5461
|
+
return (0, import_kit76.combineCodec)(
|
|
5170
5462
|
getRevealStakeInstructionDataEncoder(),
|
|
5171
5463
|
getRevealStakeInstructionDataDecoder()
|
|
5172
5464
|
);
|
|
@@ -5196,10 +5488,10 @@ async function getRevealStakeInstructionAsync(input, config) {
|
|
|
5196
5488
|
const accounts = originalAccounts;
|
|
5197
5489
|
const args = { ...input };
|
|
5198
5490
|
if (!accounts.stakeAccount.value) {
|
|
5199
|
-
accounts.stakeAccount.value = await (0,
|
|
5491
|
+
accounts.stakeAccount.value = await (0, import_kit76.getProgramDerivedAddress)({
|
|
5200
5492
|
programAddress,
|
|
5201
5493
|
seeds: [
|
|
5202
|
-
(0,
|
|
5494
|
+
(0, import_kit76.getBytesEncoder)().encode(
|
|
5203
5495
|
new Uint8Array([
|
|
5204
5496
|
115,
|
|
5205
5497
|
116,
|
|
@@ -5216,17 +5508,17 @@ async function getRevealStakeInstructionAsync(input, config) {
|
|
|
5216
5508
|
116
|
|
5217
5509
|
])
|
|
5218
5510
|
),
|
|
5219
|
-
(0,
|
|
5220
|
-
(0,
|
|
5221
|
-
(0,
|
|
5511
|
+
(0, import_kit76.getAddressEncoder)().encode(expectAddress(accounts.owner.value)),
|
|
5512
|
+
(0, import_kit76.getAddressEncoder)().encode(expectAddress(accounts.market.value)),
|
|
5513
|
+
(0, import_kit76.getU32Encoder)().encode(expectSome(args.stakeAccountId))
|
|
5222
5514
|
]
|
|
5223
5515
|
});
|
|
5224
5516
|
}
|
|
5225
5517
|
if (!accounts.signPdaAccount.value) {
|
|
5226
|
-
accounts.signPdaAccount.value = await (0,
|
|
5518
|
+
accounts.signPdaAccount.value = await (0, import_kit76.getProgramDerivedAddress)({
|
|
5227
5519
|
programAddress,
|
|
5228
5520
|
seeds: [
|
|
5229
|
-
(0,
|
|
5521
|
+
(0, import_kit76.getBytesEncoder)().encode(
|
|
5230
5522
|
new Uint8Array([
|
|
5231
5523
|
65,
|
|
5232
5524
|
114,
|
|
@@ -5384,7 +5676,7 @@ function parseRevealStakeInstruction(instruction) {
|
|
|
5384
5676
|
}
|
|
5385
5677
|
|
|
5386
5678
|
// src/generated/instructions/revealStakeCallback.ts
|
|
5387
|
-
var
|
|
5679
|
+
var import_kit77 = require("@solana/kit");
|
|
5388
5680
|
var REVEAL_STAKE_CALLBACK_DISCRIMINATOR = new Uint8Array([
|
|
5389
5681
|
79,
|
|
5390
5682
|
19,
|
|
@@ -5396,34 +5688,34 @@ var REVEAL_STAKE_CALLBACK_DISCRIMINATOR = new Uint8Array([
|
|
|
5396
5688
|
116
|
|
5397
5689
|
]);
|
|
5398
5690
|
function getRevealStakeCallbackDiscriminatorBytes() {
|
|
5399
|
-
return (0,
|
|
5691
|
+
return (0, import_kit77.fixEncoderSize)((0, import_kit77.getBytesEncoder)(), 8).encode(
|
|
5400
5692
|
REVEAL_STAKE_CALLBACK_DISCRIMINATOR
|
|
5401
5693
|
);
|
|
5402
5694
|
}
|
|
5403
5695
|
function getRevealStakeCallbackInstructionDataEncoder() {
|
|
5404
|
-
return (0,
|
|
5405
|
-
(0,
|
|
5406
|
-
["discriminator", (0,
|
|
5696
|
+
return (0, import_kit77.transformEncoder)(
|
|
5697
|
+
(0, import_kit77.getStructEncoder)([
|
|
5698
|
+
["discriminator", (0, import_kit77.fixEncoderSize)((0, import_kit77.getBytesEncoder)(), 8)],
|
|
5407
5699
|
[
|
|
5408
5700
|
"output",
|
|
5409
|
-
(0,
|
|
5701
|
+
(0, import_kit77.getDiscriminatedUnionEncoder)([
|
|
5410
5702
|
[
|
|
5411
5703
|
"Success",
|
|
5412
|
-
(0,
|
|
5704
|
+
(0, import_kit77.getStructEncoder)([
|
|
5413
5705
|
[
|
|
5414
5706
|
"fields",
|
|
5415
|
-
(0,
|
|
5707
|
+
(0, import_kit77.getTupleEncoder)([
|
|
5416
5708
|
getRevealStakeOutputEncoder(),
|
|
5417
|
-
(0,
|
|
5709
|
+
(0, import_kit77.getArrayEncoder)((0, import_kit77.getU8Encoder)(), { size: 64 })
|
|
5418
5710
|
])
|
|
5419
5711
|
]
|
|
5420
5712
|
])
|
|
5421
5713
|
],
|
|
5422
|
-
["Failure", (0,
|
|
5714
|
+
["Failure", (0, import_kit77.getUnitEncoder)()],
|
|
5423
5715
|
[
|
|
5424
5716
|
"MarkerForIdlBuildDoNotUseThis",
|
|
5425
|
-
(0,
|
|
5426
|
-
["fields", (0,
|
|
5717
|
+
(0, import_kit77.getStructEncoder)([
|
|
5718
|
+
["fields", (0, import_kit77.getTupleEncoder)([getRevealStakeOutputEncoder()])]
|
|
5427
5719
|
])
|
|
5428
5720
|
]
|
|
5429
5721
|
])
|
|
@@ -5436,28 +5728,28 @@ function getRevealStakeCallbackInstructionDataEncoder() {
|
|
|
5436
5728
|
);
|
|
5437
5729
|
}
|
|
5438
5730
|
function getRevealStakeCallbackInstructionDataDecoder() {
|
|
5439
|
-
return (0,
|
|
5440
|
-
["discriminator", (0,
|
|
5731
|
+
return (0, import_kit77.getStructDecoder)([
|
|
5732
|
+
["discriminator", (0, import_kit77.fixDecoderSize)((0, import_kit77.getBytesDecoder)(), 8)],
|
|
5441
5733
|
[
|
|
5442
5734
|
"output",
|
|
5443
|
-
(0,
|
|
5735
|
+
(0, import_kit77.getDiscriminatedUnionDecoder)([
|
|
5444
5736
|
[
|
|
5445
5737
|
"Success",
|
|
5446
|
-
(0,
|
|
5738
|
+
(0, import_kit77.getStructDecoder)([
|
|
5447
5739
|
[
|
|
5448
5740
|
"fields",
|
|
5449
|
-
(0,
|
|
5741
|
+
(0, import_kit77.getTupleDecoder)([
|
|
5450
5742
|
getRevealStakeOutputDecoder(),
|
|
5451
|
-
(0,
|
|
5743
|
+
(0, import_kit77.getArrayDecoder)((0, import_kit77.getU8Decoder)(), { size: 64 })
|
|
5452
5744
|
])
|
|
5453
5745
|
]
|
|
5454
5746
|
])
|
|
5455
5747
|
],
|
|
5456
|
-
["Failure", (0,
|
|
5748
|
+
["Failure", (0, import_kit77.getUnitDecoder)()],
|
|
5457
5749
|
[
|
|
5458
5750
|
"MarkerForIdlBuildDoNotUseThis",
|
|
5459
|
-
(0,
|
|
5460
|
-
["fields", (0,
|
|
5751
|
+
(0, import_kit77.getStructDecoder)([
|
|
5752
|
+
["fields", (0, import_kit77.getTupleDecoder)([getRevealStakeOutputDecoder()])]
|
|
5461
5753
|
])
|
|
5462
5754
|
]
|
|
5463
5755
|
])
|
|
@@ -5465,7 +5757,7 @@ function getRevealStakeCallbackInstructionDataDecoder() {
|
|
|
5465
5757
|
]);
|
|
5466
5758
|
}
|
|
5467
5759
|
function getRevealStakeCallbackInstructionDataCodec() {
|
|
5468
|
-
return (0,
|
|
5760
|
+
return (0, import_kit77.combineCodec)(
|
|
5469
5761
|
getRevealStakeCallbackInstructionDataEncoder(),
|
|
5470
5762
|
getRevealStakeCallbackInstructionDataDecoder()
|
|
5471
5763
|
);
|
|
@@ -5540,7 +5832,7 @@ function parseRevealStakeCallbackInstruction(instruction) {
|
|
|
5540
5832
|
}
|
|
5541
5833
|
|
|
5542
5834
|
// src/generated/instructions/revealStakeCompDef.ts
|
|
5543
|
-
var
|
|
5835
|
+
var import_kit78 = require("@solana/kit");
|
|
5544
5836
|
var REVEAL_STAKE_COMP_DEF_DISCRIMINATOR = new Uint8Array([
|
|
5545
5837
|
197,
|
|
5546
5838
|
20,
|
|
@@ -5552,13 +5844,13 @@ var REVEAL_STAKE_COMP_DEF_DISCRIMINATOR = new Uint8Array([
|
|
|
5552
5844
|
0
|
|
5553
5845
|
]);
|
|
5554
5846
|
function getRevealStakeCompDefDiscriminatorBytes() {
|
|
5555
|
-
return (0,
|
|
5847
|
+
return (0, import_kit78.fixEncoderSize)((0, import_kit78.getBytesEncoder)(), 8).encode(
|
|
5556
5848
|
REVEAL_STAKE_COMP_DEF_DISCRIMINATOR
|
|
5557
5849
|
);
|
|
5558
5850
|
}
|
|
5559
5851
|
function getRevealStakeCompDefInstructionDataEncoder() {
|
|
5560
|
-
return (0,
|
|
5561
|
-
(0,
|
|
5852
|
+
return (0, import_kit78.transformEncoder)(
|
|
5853
|
+
(0, import_kit78.getStructEncoder)([["discriminator", (0, import_kit78.fixEncoderSize)((0, import_kit78.getBytesEncoder)(), 8)]]),
|
|
5562
5854
|
(value) => ({
|
|
5563
5855
|
...value,
|
|
5564
5856
|
discriminator: REVEAL_STAKE_COMP_DEF_DISCRIMINATOR
|
|
@@ -5566,12 +5858,12 @@ function getRevealStakeCompDefInstructionDataEncoder() {
|
|
|
5566
5858
|
);
|
|
5567
5859
|
}
|
|
5568
5860
|
function getRevealStakeCompDefInstructionDataDecoder() {
|
|
5569
|
-
return (0,
|
|
5570
|
-
["discriminator", (0,
|
|
5861
|
+
return (0, import_kit78.getStructDecoder)([
|
|
5862
|
+
["discriminator", (0, import_kit78.fixDecoderSize)((0, import_kit78.getBytesDecoder)(), 8)]
|
|
5571
5863
|
]);
|
|
5572
5864
|
}
|
|
5573
5865
|
function getRevealStakeCompDefInstructionDataCodec() {
|
|
5574
|
-
return (0,
|
|
5866
|
+
return (0, import_kit78.combineCodec)(
|
|
5575
5867
|
getRevealStakeCompDefInstructionDataEncoder(),
|
|
5576
5868
|
getRevealStakeCompDefInstructionDataDecoder()
|
|
5577
5869
|
);
|
|
@@ -5643,7 +5935,7 @@ function parseRevealStakeCompDefInstruction(instruction) {
|
|
|
5643
5935
|
}
|
|
5644
5936
|
|
|
5645
5937
|
// src/generated/instructions/setFeeClaimAuthority.ts
|
|
5646
|
-
var
|
|
5938
|
+
var import_kit79 = require("@solana/kit");
|
|
5647
5939
|
var SET_FEE_CLAIM_AUTHORITY_DISCRIMINATOR = new Uint8Array([
|
|
5648
5940
|
75,
|
|
5649
5941
|
250,
|
|
@@ -5655,13 +5947,13 @@ var SET_FEE_CLAIM_AUTHORITY_DISCRIMINATOR = new Uint8Array([
|
|
|
5655
5947
|
3
|
|
5656
5948
|
]);
|
|
5657
5949
|
function getSetFeeClaimAuthorityDiscriminatorBytes() {
|
|
5658
|
-
return (0,
|
|
5950
|
+
return (0, import_kit79.fixEncoderSize)((0, import_kit79.getBytesEncoder)(), 8).encode(
|
|
5659
5951
|
SET_FEE_CLAIM_AUTHORITY_DISCRIMINATOR
|
|
5660
5952
|
);
|
|
5661
5953
|
}
|
|
5662
5954
|
function getSetFeeClaimAuthorityInstructionDataEncoder() {
|
|
5663
|
-
return (0,
|
|
5664
|
-
(0,
|
|
5955
|
+
return (0, import_kit79.transformEncoder)(
|
|
5956
|
+
(0, import_kit79.getStructEncoder)([["discriminator", (0, import_kit79.fixEncoderSize)((0, import_kit79.getBytesEncoder)(), 8)]]),
|
|
5665
5957
|
(value) => ({
|
|
5666
5958
|
...value,
|
|
5667
5959
|
discriminator: SET_FEE_CLAIM_AUTHORITY_DISCRIMINATOR
|
|
@@ -5669,12 +5961,12 @@ function getSetFeeClaimAuthorityInstructionDataEncoder() {
|
|
|
5669
5961
|
);
|
|
5670
5962
|
}
|
|
5671
5963
|
function getSetFeeClaimAuthorityInstructionDataDecoder() {
|
|
5672
|
-
return (0,
|
|
5673
|
-
["discriminator", (0,
|
|
5964
|
+
return (0, import_kit79.getStructDecoder)([
|
|
5965
|
+
["discriminator", (0, import_kit79.fixDecoderSize)((0, import_kit79.getBytesDecoder)(), 8)]
|
|
5674
5966
|
]);
|
|
5675
5967
|
}
|
|
5676
5968
|
function getSetFeeClaimAuthorityInstructionDataCodec() {
|
|
5677
|
-
return (0,
|
|
5969
|
+
return (0, import_kit79.combineCodec)(
|
|
5678
5970
|
getSetFeeClaimAuthorityInstructionDataEncoder(),
|
|
5679
5971
|
getSetFeeClaimAuthorityInstructionDataDecoder()
|
|
5680
5972
|
);
|
|
@@ -5728,7 +6020,7 @@ function parseSetFeeClaimAuthorityInstruction(instruction) {
|
|
|
5728
6020
|
}
|
|
5729
6021
|
|
|
5730
6022
|
// src/generated/instructions/setUpdateAuthority.ts
|
|
5731
|
-
var
|
|
6023
|
+
var import_kit80 = require("@solana/kit");
|
|
5732
6024
|
var SET_UPDATE_AUTHORITY_DISCRIMINATOR = new Uint8Array([
|
|
5733
6025
|
166,
|
|
5734
6026
|
198,
|
|
@@ -5740,23 +6032,23 @@ var SET_UPDATE_AUTHORITY_DISCRIMINATOR = new Uint8Array([
|
|
|
5740
6032
|
155
|
|
5741
6033
|
]);
|
|
5742
6034
|
function getSetUpdateAuthorityDiscriminatorBytes() {
|
|
5743
|
-
return (0,
|
|
6035
|
+
return (0, import_kit80.fixEncoderSize)((0, import_kit80.getBytesEncoder)(), 8).encode(
|
|
5744
6036
|
SET_UPDATE_AUTHORITY_DISCRIMINATOR
|
|
5745
6037
|
);
|
|
5746
6038
|
}
|
|
5747
6039
|
function getSetUpdateAuthorityInstructionDataEncoder() {
|
|
5748
|
-
return (0,
|
|
5749
|
-
(0,
|
|
6040
|
+
return (0, import_kit80.transformEncoder)(
|
|
6041
|
+
(0, import_kit80.getStructEncoder)([["discriminator", (0, import_kit80.fixEncoderSize)((0, import_kit80.getBytesEncoder)(), 8)]]),
|
|
5750
6042
|
(value) => ({ ...value, discriminator: SET_UPDATE_AUTHORITY_DISCRIMINATOR })
|
|
5751
6043
|
);
|
|
5752
6044
|
}
|
|
5753
6045
|
function getSetUpdateAuthorityInstructionDataDecoder() {
|
|
5754
|
-
return (0,
|
|
5755
|
-
["discriminator", (0,
|
|
6046
|
+
return (0, import_kit80.getStructDecoder)([
|
|
6047
|
+
["discriminator", (0, import_kit80.fixDecoderSize)((0, import_kit80.getBytesDecoder)(), 8)]
|
|
5756
6048
|
]);
|
|
5757
6049
|
}
|
|
5758
6050
|
function getSetUpdateAuthorityInstructionDataCodec() {
|
|
5759
|
-
return (0,
|
|
6051
|
+
return (0, import_kit80.combineCodec)(
|
|
5760
6052
|
getSetUpdateAuthorityInstructionDataEncoder(),
|
|
5761
6053
|
getSetUpdateAuthorityInstructionDataDecoder()
|
|
5762
6054
|
);
|
|
@@ -5807,7 +6099,7 @@ function parseSetUpdateAuthorityInstruction(instruction) {
|
|
|
5807
6099
|
}
|
|
5808
6100
|
|
|
5809
6101
|
// src/generated/instructions/setWinningOption.ts
|
|
5810
|
-
var
|
|
6102
|
+
var import_kit81 = require("@solana/kit");
|
|
5811
6103
|
var SET_WINNING_OPTION_DISCRIMINATOR = new Uint8Array([
|
|
5812
6104
|
156,
|
|
5813
6105
|
73,
|
|
@@ -5819,29 +6111,29 @@ var SET_WINNING_OPTION_DISCRIMINATOR = new Uint8Array([
|
|
|
5819
6111
|
206
|
|
5820
6112
|
]);
|
|
5821
6113
|
function getSetWinningOptionDiscriminatorBytes() {
|
|
5822
|
-
return (0,
|
|
6114
|
+
return (0, import_kit81.fixEncoderSize)((0, import_kit81.getBytesEncoder)(), 8).encode(
|
|
5823
6115
|
SET_WINNING_OPTION_DISCRIMINATOR
|
|
5824
6116
|
);
|
|
5825
6117
|
}
|
|
5826
6118
|
function getSetWinningOptionInstructionDataEncoder() {
|
|
5827
|
-
return (0,
|
|
5828
|
-
(0,
|
|
5829
|
-
["discriminator", (0,
|
|
5830
|
-
["optionId", (0,
|
|
5831
|
-
["rewardBp", (0,
|
|
6119
|
+
return (0, import_kit81.transformEncoder)(
|
|
6120
|
+
(0, import_kit81.getStructEncoder)([
|
|
6121
|
+
["discriminator", (0, import_kit81.fixEncoderSize)((0, import_kit81.getBytesEncoder)(), 8)],
|
|
6122
|
+
["optionId", (0, import_kit81.getU64Encoder)()],
|
|
6123
|
+
["rewardBp", (0, import_kit81.getU16Encoder)()]
|
|
5832
6124
|
]),
|
|
5833
6125
|
(value) => ({ ...value, discriminator: SET_WINNING_OPTION_DISCRIMINATOR })
|
|
5834
6126
|
);
|
|
5835
6127
|
}
|
|
5836
6128
|
function getSetWinningOptionInstructionDataDecoder() {
|
|
5837
|
-
return (0,
|
|
5838
|
-
["discriminator", (0,
|
|
5839
|
-
["optionId", (0,
|
|
5840
|
-
["rewardBp", (0,
|
|
6129
|
+
return (0, import_kit81.getStructDecoder)([
|
|
6130
|
+
["discriminator", (0, import_kit81.fixDecoderSize)((0, import_kit81.getBytesDecoder)(), 8)],
|
|
6131
|
+
["optionId", (0, import_kit81.getU64Decoder)()],
|
|
6132
|
+
["rewardBp", (0, import_kit81.getU16Decoder)()]
|
|
5841
6133
|
]);
|
|
5842
6134
|
}
|
|
5843
6135
|
function getSetWinningOptionInstructionDataCodec() {
|
|
5844
|
-
return (0,
|
|
6136
|
+
return (0, import_kit81.combineCodec)(
|
|
5845
6137
|
getSetWinningOptionInstructionDataEncoder(),
|
|
5846
6138
|
getSetWinningOptionInstructionDataDecoder()
|
|
5847
6139
|
);
|
|
@@ -5859,14 +6151,14 @@ async function getSetWinningOptionInstructionAsync(input, config) {
|
|
|
5859
6151
|
const accounts = originalAccounts;
|
|
5860
6152
|
const args = { ...input };
|
|
5861
6153
|
if (!accounts.option.value) {
|
|
5862
|
-
accounts.option.value = await (0,
|
|
6154
|
+
accounts.option.value = await (0, import_kit81.getProgramDerivedAddress)({
|
|
5863
6155
|
programAddress,
|
|
5864
6156
|
seeds: [
|
|
5865
|
-
(0,
|
|
6157
|
+
(0, import_kit81.getBytesEncoder)().encode(
|
|
5866
6158
|
new Uint8Array([111, 112, 116, 105, 111, 110])
|
|
5867
6159
|
),
|
|
5868
|
-
(0,
|
|
5869
|
-
(0,
|
|
6160
|
+
(0, import_kit81.getAddressEncoder)().encode(expectAddress(accounts.market.value)),
|
|
6161
|
+
(0, import_kit81.getU64Encoder)().encode(expectSome(args.optionId))
|
|
5870
6162
|
]
|
|
5871
6163
|
});
|
|
5872
6164
|
}
|
|
@@ -5930,7 +6222,7 @@ function parseSetWinningOptionInstruction(instruction) {
|
|
|
5930
6222
|
}
|
|
5931
6223
|
|
|
5932
6224
|
// src/generated/instructions/stake.ts
|
|
5933
|
-
var
|
|
6225
|
+
var import_kit82 = require("@solana/kit");
|
|
5934
6226
|
var STAKE_DISCRIMINATOR = new Uint8Array([
|
|
5935
6227
|
206,
|
|
5936
6228
|
176,
|
|
@@ -5942,42 +6234,42 @@ var STAKE_DISCRIMINATOR = new Uint8Array([
|
|
|
5942
6234
|
108
|
|
5943
6235
|
]);
|
|
5944
6236
|
function getStakeDiscriminatorBytes() {
|
|
5945
|
-
return (0,
|
|
6237
|
+
return (0, import_kit82.fixEncoderSize)((0, import_kit82.getBytesEncoder)(), 8).encode(STAKE_DISCRIMINATOR);
|
|
5946
6238
|
}
|
|
5947
6239
|
function getStakeInstructionDataEncoder() {
|
|
5948
|
-
return (0,
|
|
5949
|
-
(0,
|
|
5950
|
-
["discriminator", (0,
|
|
5951
|
-
["computationOffset", (0,
|
|
5952
|
-
["stakeAccountId", (0,
|
|
5953
|
-
["amount", (0,
|
|
6240
|
+
return (0, import_kit82.transformEncoder)(
|
|
6241
|
+
(0, import_kit82.getStructEncoder)([
|
|
6242
|
+
["discriminator", (0, import_kit82.fixEncoderSize)((0, import_kit82.getBytesEncoder)(), 8)],
|
|
6243
|
+
["computationOffset", (0, import_kit82.getU64Encoder)()],
|
|
6244
|
+
["stakeAccountId", (0, import_kit82.getU32Encoder)()],
|
|
6245
|
+
["amount", (0, import_kit82.getU64Encoder)()],
|
|
5954
6246
|
[
|
|
5955
6247
|
"selectedOptionCiphertext",
|
|
5956
|
-
(0,
|
|
6248
|
+
(0, import_kit82.getArrayEncoder)((0, import_kit82.getU8Encoder)(), { size: 32 })
|
|
5957
6249
|
],
|
|
5958
|
-
["inputNonce", (0,
|
|
5959
|
-
["authorizedReaderNonce", (0,
|
|
5960
|
-
["userPubkey", (0,
|
|
5961
|
-
["stateNonce", (0,
|
|
6250
|
+
["inputNonce", (0, import_kit82.getU128Encoder)()],
|
|
6251
|
+
["authorizedReaderNonce", (0, import_kit82.getU128Encoder)()],
|
|
6252
|
+
["userPubkey", (0, import_kit82.getArrayEncoder)((0, import_kit82.getU8Encoder)(), { size: 32 })],
|
|
6253
|
+
["stateNonce", (0, import_kit82.getU128Encoder)()]
|
|
5962
6254
|
]),
|
|
5963
6255
|
(value) => ({ ...value, discriminator: STAKE_DISCRIMINATOR })
|
|
5964
6256
|
);
|
|
5965
6257
|
}
|
|
5966
6258
|
function getStakeInstructionDataDecoder() {
|
|
5967
|
-
return (0,
|
|
5968
|
-
["discriminator", (0,
|
|
5969
|
-
["computationOffset", (0,
|
|
5970
|
-
["stakeAccountId", (0,
|
|
5971
|
-
["amount", (0,
|
|
5972
|
-
["selectedOptionCiphertext", (0,
|
|
5973
|
-
["inputNonce", (0,
|
|
5974
|
-
["authorizedReaderNonce", (0,
|
|
5975
|
-
["userPubkey", (0,
|
|
5976
|
-
["stateNonce", (0,
|
|
6259
|
+
return (0, import_kit82.getStructDecoder)([
|
|
6260
|
+
["discriminator", (0, import_kit82.fixDecoderSize)((0, import_kit82.getBytesDecoder)(), 8)],
|
|
6261
|
+
["computationOffset", (0, import_kit82.getU64Decoder)()],
|
|
6262
|
+
["stakeAccountId", (0, import_kit82.getU32Decoder)()],
|
|
6263
|
+
["amount", (0, import_kit82.getU64Decoder)()],
|
|
6264
|
+
["selectedOptionCiphertext", (0, import_kit82.getArrayDecoder)((0, import_kit82.getU8Decoder)(), { size: 32 })],
|
|
6265
|
+
["inputNonce", (0, import_kit82.getU128Decoder)()],
|
|
6266
|
+
["authorizedReaderNonce", (0, import_kit82.getU128Decoder)()],
|
|
6267
|
+
["userPubkey", (0, import_kit82.getArrayDecoder)((0, import_kit82.getU8Decoder)(), { size: 32 })],
|
|
6268
|
+
["stateNonce", (0, import_kit82.getU128Decoder)()]
|
|
5977
6269
|
]);
|
|
5978
6270
|
}
|
|
5979
6271
|
function getStakeInstructionDataCodec() {
|
|
5980
|
-
return (0,
|
|
6272
|
+
return (0, import_kit82.combineCodec)(
|
|
5981
6273
|
getStakeInstructionDataEncoder(),
|
|
5982
6274
|
getStakeInstructionDataDecoder()
|
|
5983
6275
|
);
|
|
@@ -6014,20 +6306,20 @@ async function getStakeInstructionAsync(input, config) {
|
|
|
6014
6306
|
const accounts = originalAccounts;
|
|
6015
6307
|
const args = { ...input };
|
|
6016
6308
|
if (!accounts.marketTokenAta.value) {
|
|
6017
|
-
accounts.marketTokenAta.value = await (0,
|
|
6309
|
+
accounts.marketTokenAta.value = await (0, import_kit82.getProgramDerivedAddress)({
|
|
6018
6310
|
programAddress: "ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL",
|
|
6019
6311
|
seeds: [
|
|
6020
|
-
(0,
|
|
6021
|
-
(0,
|
|
6022
|
-
(0,
|
|
6312
|
+
(0, import_kit82.getAddressEncoder)().encode(expectAddress(accounts.market.value)),
|
|
6313
|
+
(0, import_kit82.getAddressEncoder)().encode(expectAddress(accounts.tokenProgram.value)),
|
|
6314
|
+
(0, import_kit82.getAddressEncoder)().encode(expectAddress(accounts.tokenMint.value))
|
|
6023
6315
|
]
|
|
6024
6316
|
});
|
|
6025
6317
|
}
|
|
6026
6318
|
if (!accounts.signPdaAccount.value) {
|
|
6027
|
-
accounts.signPdaAccount.value = await (0,
|
|
6319
|
+
accounts.signPdaAccount.value = await (0, import_kit82.getProgramDerivedAddress)({
|
|
6028
6320
|
programAddress,
|
|
6029
6321
|
seeds: [
|
|
6030
|
-
(0,
|
|
6322
|
+
(0, import_kit82.getBytesEncoder)().encode(
|
|
6031
6323
|
new Uint8Array([
|
|
6032
6324
|
65,
|
|
6033
6325
|
114,
|
|
@@ -6204,7 +6496,7 @@ function parseStakeInstruction(instruction) {
|
|
|
6204
6496
|
}
|
|
6205
6497
|
|
|
6206
6498
|
// src/generated/instructions/stakeCallback.ts
|
|
6207
|
-
var
|
|
6499
|
+
var import_kit83 = require("@solana/kit");
|
|
6208
6500
|
var STAKE_CALLBACK_DISCRIMINATOR = new Uint8Array([
|
|
6209
6501
|
40,
|
|
6210
6502
|
220,
|
|
@@ -6216,34 +6508,34 @@ var STAKE_CALLBACK_DISCRIMINATOR = new Uint8Array([
|
|
|
6216
6508
|
89
|
|
6217
6509
|
]);
|
|
6218
6510
|
function getStakeCallbackDiscriminatorBytes() {
|
|
6219
|
-
return (0,
|
|
6511
|
+
return (0, import_kit83.fixEncoderSize)((0, import_kit83.getBytesEncoder)(), 8).encode(
|
|
6220
6512
|
STAKE_CALLBACK_DISCRIMINATOR
|
|
6221
6513
|
);
|
|
6222
6514
|
}
|
|
6223
6515
|
function getStakeCallbackInstructionDataEncoder() {
|
|
6224
|
-
return (0,
|
|
6225
|
-
(0,
|
|
6226
|
-
["discriminator", (0,
|
|
6516
|
+
return (0, import_kit83.transformEncoder)(
|
|
6517
|
+
(0, import_kit83.getStructEncoder)([
|
|
6518
|
+
["discriminator", (0, import_kit83.fixEncoderSize)((0, import_kit83.getBytesEncoder)(), 8)],
|
|
6227
6519
|
[
|
|
6228
6520
|
"output",
|
|
6229
|
-
(0,
|
|
6521
|
+
(0, import_kit83.getDiscriminatedUnionEncoder)([
|
|
6230
6522
|
[
|
|
6231
6523
|
"Success",
|
|
6232
|
-
(0,
|
|
6524
|
+
(0, import_kit83.getStructEncoder)([
|
|
6233
6525
|
[
|
|
6234
6526
|
"fields",
|
|
6235
|
-
(0,
|
|
6527
|
+
(0, import_kit83.getTupleEncoder)([
|
|
6236
6528
|
getStakeOutputEncoder(),
|
|
6237
|
-
(0,
|
|
6529
|
+
(0, import_kit83.getArrayEncoder)((0, import_kit83.getU8Encoder)(), { size: 64 })
|
|
6238
6530
|
])
|
|
6239
6531
|
]
|
|
6240
6532
|
])
|
|
6241
6533
|
],
|
|
6242
|
-
["Failure", (0,
|
|
6534
|
+
["Failure", (0, import_kit83.getUnitEncoder)()],
|
|
6243
6535
|
[
|
|
6244
6536
|
"MarkerForIdlBuildDoNotUseThis",
|
|
6245
|
-
(0,
|
|
6246
|
-
["fields", (0,
|
|
6537
|
+
(0, import_kit83.getStructEncoder)([
|
|
6538
|
+
["fields", (0, import_kit83.getTupleEncoder)([getStakeOutputEncoder()])]
|
|
6247
6539
|
])
|
|
6248
6540
|
]
|
|
6249
6541
|
])
|
|
@@ -6253,28 +6545,28 @@ function getStakeCallbackInstructionDataEncoder() {
|
|
|
6253
6545
|
);
|
|
6254
6546
|
}
|
|
6255
6547
|
function getStakeCallbackInstructionDataDecoder() {
|
|
6256
|
-
return (0,
|
|
6257
|
-
["discriminator", (0,
|
|
6548
|
+
return (0, import_kit83.getStructDecoder)([
|
|
6549
|
+
["discriminator", (0, import_kit83.fixDecoderSize)((0, import_kit83.getBytesDecoder)(), 8)],
|
|
6258
6550
|
[
|
|
6259
6551
|
"output",
|
|
6260
|
-
(0,
|
|
6552
|
+
(0, import_kit83.getDiscriminatedUnionDecoder)([
|
|
6261
6553
|
[
|
|
6262
6554
|
"Success",
|
|
6263
|
-
(0,
|
|
6555
|
+
(0, import_kit83.getStructDecoder)([
|
|
6264
6556
|
[
|
|
6265
6557
|
"fields",
|
|
6266
|
-
(0,
|
|
6558
|
+
(0, import_kit83.getTupleDecoder)([
|
|
6267
6559
|
getStakeOutputDecoder(),
|
|
6268
|
-
(0,
|
|
6560
|
+
(0, import_kit83.getArrayDecoder)((0, import_kit83.getU8Decoder)(), { size: 64 })
|
|
6269
6561
|
])
|
|
6270
6562
|
]
|
|
6271
6563
|
])
|
|
6272
6564
|
],
|
|
6273
|
-
["Failure", (0,
|
|
6565
|
+
["Failure", (0, import_kit83.getUnitDecoder)()],
|
|
6274
6566
|
[
|
|
6275
6567
|
"MarkerForIdlBuildDoNotUseThis",
|
|
6276
|
-
(0,
|
|
6277
|
-
["fields", (0,
|
|
6568
|
+
(0, import_kit83.getStructDecoder)([
|
|
6569
|
+
["fields", (0, import_kit83.getTupleDecoder)([getStakeOutputDecoder()])]
|
|
6278
6570
|
])
|
|
6279
6571
|
]
|
|
6280
6572
|
])
|
|
@@ -6282,7 +6574,7 @@ function getStakeCallbackInstructionDataDecoder() {
|
|
|
6282
6574
|
]);
|
|
6283
6575
|
}
|
|
6284
6576
|
function getStakeCallbackInstructionDataCodec() {
|
|
6285
|
-
return (0,
|
|
6577
|
+
return (0, import_kit83.combineCodec)(
|
|
6286
6578
|
getStakeCallbackInstructionDataEncoder(),
|
|
6287
6579
|
getStakeCallbackInstructionDataDecoder()
|
|
6288
6580
|
);
|
|
@@ -6358,7 +6650,7 @@ function parseStakeCallbackInstruction(instruction) {
|
|
|
6358
6650
|
}
|
|
6359
6651
|
|
|
6360
6652
|
// src/generated/instructions/stakeCompDef.ts
|
|
6361
|
-
var
|
|
6653
|
+
var import_kit84 = require("@solana/kit");
|
|
6362
6654
|
var STAKE_COMP_DEF_DISCRIMINATOR = new Uint8Array([
|
|
6363
6655
|
156,
|
|
6364
6656
|
5,
|
|
@@ -6370,23 +6662,23 @@ var STAKE_COMP_DEF_DISCRIMINATOR = new Uint8Array([
|
|
|
6370
6662
|
130
|
|
6371
6663
|
]);
|
|
6372
6664
|
function getStakeCompDefDiscriminatorBytes() {
|
|
6373
|
-
return (0,
|
|
6665
|
+
return (0, import_kit84.fixEncoderSize)((0, import_kit84.getBytesEncoder)(), 8).encode(
|
|
6374
6666
|
STAKE_COMP_DEF_DISCRIMINATOR
|
|
6375
6667
|
);
|
|
6376
6668
|
}
|
|
6377
6669
|
function getStakeCompDefInstructionDataEncoder() {
|
|
6378
|
-
return (0,
|
|
6379
|
-
(0,
|
|
6670
|
+
return (0, import_kit84.transformEncoder)(
|
|
6671
|
+
(0, import_kit84.getStructEncoder)([["discriminator", (0, import_kit84.fixEncoderSize)((0, import_kit84.getBytesEncoder)(), 8)]]),
|
|
6380
6672
|
(value) => ({ ...value, discriminator: STAKE_COMP_DEF_DISCRIMINATOR })
|
|
6381
6673
|
);
|
|
6382
6674
|
}
|
|
6383
6675
|
function getStakeCompDefInstructionDataDecoder() {
|
|
6384
|
-
return (0,
|
|
6385
|
-
["discriminator", (0,
|
|
6676
|
+
return (0, import_kit84.getStructDecoder)([
|
|
6677
|
+
["discriminator", (0, import_kit84.fixDecoderSize)((0, import_kit84.getBytesDecoder)(), 8)]
|
|
6386
6678
|
]);
|
|
6387
6679
|
}
|
|
6388
6680
|
function getStakeCompDefInstructionDataCodec() {
|
|
6389
|
-
return (0,
|
|
6681
|
+
return (0, import_kit84.combineCodec)(
|
|
6390
6682
|
getStakeCompDefInstructionDataEncoder(),
|
|
6391
6683
|
getStakeCompDefInstructionDataDecoder()
|
|
6392
6684
|
);
|
|
@@ -6456,7 +6748,7 @@ function parseStakeCompDefInstruction(instruction) {
|
|
|
6456
6748
|
}
|
|
6457
6749
|
|
|
6458
6750
|
// src/generated/instructions/unstake.ts
|
|
6459
|
-
var
|
|
6751
|
+
var import_kit85 = require("@solana/kit");
|
|
6460
6752
|
var UNSTAKE_DISCRIMINATOR = new Uint8Array([
|
|
6461
6753
|
90,
|
|
6462
6754
|
95,
|
|
@@ -6468,25 +6760,25 @@ var UNSTAKE_DISCRIMINATOR = new Uint8Array([
|
|
|
6468
6760
|
225
|
|
6469
6761
|
]);
|
|
6470
6762
|
function getUnstakeDiscriminatorBytes() {
|
|
6471
|
-
return (0,
|
|
6763
|
+
return (0, import_kit85.fixEncoderSize)((0, import_kit85.getBytesEncoder)(), 8).encode(UNSTAKE_DISCRIMINATOR);
|
|
6472
6764
|
}
|
|
6473
6765
|
function getUnstakeInstructionDataEncoder() {
|
|
6474
|
-
return (0,
|
|
6475
|
-
(0,
|
|
6476
|
-
["discriminator", (0,
|
|
6477
|
-
["stakeAccountId", (0,
|
|
6766
|
+
return (0, import_kit85.transformEncoder)(
|
|
6767
|
+
(0, import_kit85.getStructEncoder)([
|
|
6768
|
+
["discriminator", (0, import_kit85.fixEncoderSize)((0, import_kit85.getBytesEncoder)(), 8)],
|
|
6769
|
+
["stakeAccountId", (0, import_kit85.getU32Encoder)()]
|
|
6478
6770
|
]),
|
|
6479
6771
|
(value) => ({ ...value, discriminator: UNSTAKE_DISCRIMINATOR })
|
|
6480
6772
|
);
|
|
6481
6773
|
}
|
|
6482
6774
|
function getUnstakeInstructionDataDecoder() {
|
|
6483
|
-
return (0,
|
|
6484
|
-
["discriminator", (0,
|
|
6485
|
-
["stakeAccountId", (0,
|
|
6775
|
+
return (0, import_kit85.getStructDecoder)([
|
|
6776
|
+
["discriminator", (0, import_kit85.fixDecoderSize)((0, import_kit85.getBytesDecoder)(), 8)],
|
|
6777
|
+
["stakeAccountId", (0, import_kit85.getU32Decoder)()]
|
|
6486
6778
|
]);
|
|
6487
6779
|
}
|
|
6488
6780
|
function getUnstakeInstructionDataCodec() {
|
|
6489
|
-
return (0,
|
|
6781
|
+
return (0, import_kit85.combineCodec)(
|
|
6490
6782
|
getUnstakeInstructionDataEncoder(),
|
|
6491
6783
|
getUnstakeInstructionDataDecoder()
|
|
6492
6784
|
);
|
|
@@ -6510,10 +6802,10 @@ async function getUnstakeInstructionAsync(input, config) {
|
|
|
6510
6802
|
const accounts = originalAccounts;
|
|
6511
6803
|
const args = { ...input };
|
|
6512
6804
|
if (!accounts.stakeAccount.value) {
|
|
6513
|
-
accounts.stakeAccount.value = await (0,
|
|
6805
|
+
accounts.stakeAccount.value = await (0, import_kit85.getProgramDerivedAddress)({
|
|
6514
6806
|
programAddress,
|
|
6515
6807
|
seeds: [
|
|
6516
|
-
(0,
|
|
6808
|
+
(0, import_kit85.getBytesEncoder)().encode(
|
|
6517
6809
|
new Uint8Array([
|
|
6518
6810
|
115,
|
|
6519
6811
|
116,
|
|
@@ -6530,19 +6822,19 @@ async function getUnstakeInstructionAsync(input, config) {
|
|
|
6530
6822
|
116
|
|
6531
6823
|
])
|
|
6532
6824
|
),
|
|
6533
|
-
(0,
|
|
6534
|
-
(0,
|
|
6535
|
-
(0,
|
|
6825
|
+
(0, import_kit85.getAddressEncoder)().encode(expectAddress(accounts.owner.value)),
|
|
6826
|
+
(0, import_kit85.getAddressEncoder)().encode(expectAddress(accounts.market.value)),
|
|
6827
|
+
(0, import_kit85.getU32Encoder)().encode(expectSome(args.stakeAccountId))
|
|
6536
6828
|
]
|
|
6537
6829
|
});
|
|
6538
6830
|
}
|
|
6539
6831
|
if (!accounts.marketTokenAta.value) {
|
|
6540
|
-
accounts.marketTokenAta.value = await (0,
|
|
6832
|
+
accounts.marketTokenAta.value = await (0, import_kit85.getProgramDerivedAddress)({
|
|
6541
6833
|
programAddress: "ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL",
|
|
6542
6834
|
seeds: [
|
|
6543
|
-
(0,
|
|
6544
|
-
(0,
|
|
6545
|
-
(0,
|
|
6835
|
+
(0, import_kit85.getAddressEncoder)().encode(expectAddress(accounts.market.value)),
|
|
6836
|
+
(0, import_kit85.getAddressEncoder)().encode(expectAddress(accounts.tokenProgram.value)),
|
|
6837
|
+
(0, import_kit85.getAddressEncoder)().encode(expectAddress(accounts.tokenMint.value))
|
|
6546
6838
|
]
|
|
6547
6839
|
});
|
|
6548
6840
|
}
|
|
@@ -6636,7 +6928,7 @@ function parseUnstakeInstruction(instruction) {
|
|
|
6636
6928
|
}
|
|
6637
6929
|
|
|
6638
6930
|
// src/generated/instructions/updatePlatformConfig.ts
|
|
6639
|
-
var
|
|
6931
|
+
var import_kit86 = require("@solana/kit");
|
|
6640
6932
|
var UPDATE_PLATFORM_CONFIG_DISCRIMINATOR = new Uint8Array([
|
|
6641
6933
|
195,
|
|
6642
6934
|
60,
|
|
@@ -6648,21 +6940,21 @@ var UPDATE_PLATFORM_CONFIG_DISCRIMINATOR = new Uint8Array([
|
|
|
6648
6940
|
143
|
|
6649
6941
|
]);
|
|
6650
6942
|
function getUpdatePlatformConfigDiscriminatorBytes() {
|
|
6651
|
-
return (0,
|
|
6943
|
+
return (0, import_kit86.fixEncoderSize)((0, import_kit86.getBytesEncoder)(), 8).encode(
|
|
6652
6944
|
UPDATE_PLATFORM_CONFIG_DISCRIMINATOR
|
|
6653
6945
|
);
|
|
6654
6946
|
}
|
|
6655
6947
|
function getUpdatePlatformConfigInstructionDataEncoder() {
|
|
6656
|
-
return (0,
|
|
6657
|
-
(0,
|
|
6658
|
-
["discriminator", (0,
|
|
6659
|
-
["platformFeeBp", (0,
|
|
6660
|
-
["rewardPoolFeeBp", (0,
|
|
6661
|
-
["creatorFeeBp", (0,
|
|
6662
|
-
["revealAuthority", (0,
|
|
6663
|
-
["minTimeToStakeSeconds", (0,
|
|
6664
|
-
["revealPeriodSeconds", (0,
|
|
6665
|
-
["marketResolutionDeadlineSeconds", (0,
|
|
6948
|
+
return (0, import_kit86.transformEncoder)(
|
|
6949
|
+
(0, import_kit86.getStructEncoder)([
|
|
6950
|
+
["discriminator", (0, import_kit86.fixEncoderSize)((0, import_kit86.getBytesEncoder)(), 8)],
|
|
6951
|
+
["platformFeeBp", (0, import_kit86.getU16Encoder)()],
|
|
6952
|
+
["rewardPoolFeeBp", (0, import_kit86.getU16Encoder)()],
|
|
6953
|
+
["creatorFeeBp", (0, import_kit86.getU16Encoder)()],
|
|
6954
|
+
["revealAuthority", (0, import_kit86.getAddressEncoder)()],
|
|
6955
|
+
["minTimeToStakeSeconds", (0, import_kit86.getU64Encoder)()],
|
|
6956
|
+
["revealPeriodSeconds", (0, import_kit86.getU64Encoder)()],
|
|
6957
|
+
["marketResolutionDeadlineSeconds", (0, import_kit86.getU64Encoder)()]
|
|
6666
6958
|
]),
|
|
6667
6959
|
(value) => ({
|
|
6668
6960
|
...value,
|
|
@@ -6671,19 +6963,19 @@ function getUpdatePlatformConfigInstructionDataEncoder() {
|
|
|
6671
6963
|
);
|
|
6672
6964
|
}
|
|
6673
6965
|
function getUpdatePlatformConfigInstructionDataDecoder() {
|
|
6674
|
-
return (0,
|
|
6675
|
-
["discriminator", (0,
|
|
6676
|
-
["platformFeeBp", (0,
|
|
6677
|
-
["rewardPoolFeeBp", (0,
|
|
6678
|
-
["creatorFeeBp", (0,
|
|
6679
|
-
["revealAuthority", (0,
|
|
6680
|
-
["minTimeToStakeSeconds", (0,
|
|
6681
|
-
["revealPeriodSeconds", (0,
|
|
6682
|
-
["marketResolutionDeadlineSeconds", (0,
|
|
6966
|
+
return (0, import_kit86.getStructDecoder)([
|
|
6967
|
+
["discriminator", (0, import_kit86.fixDecoderSize)((0, import_kit86.getBytesDecoder)(), 8)],
|
|
6968
|
+
["platformFeeBp", (0, import_kit86.getU16Decoder)()],
|
|
6969
|
+
["rewardPoolFeeBp", (0, import_kit86.getU16Decoder)()],
|
|
6970
|
+
["creatorFeeBp", (0, import_kit86.getU16Decoder)()],
|
|
6971
|
+
["revealAuthority", (0, import_kit86.getAddressDecoder)()],
|
|
6972
|
+
["minTimeToStakeSeconds", (0, import_kit86.getU64Decoder)()],
|
|
6973
|
+
["revealPeriodSeconds", (0, import_kit86.getU64Decoder)()],
|
|
6974
|
+
["marketResolutionDeadlineSeconds", (0, import_kit86.getU64Decoder)()]
|
|
6683
6975
|
]);
|
|
6684
6976
|
}
|
|
6685
6977
|
function getUpdatePlatformConfigInstructionDataCodec() {
|
|
6686
|
-
return (0,
|
|
6978
|
+
return (0, import_kit86.combineCodec)(
|
|
6687
6979
|
getUpdatePlatformConfigInstructionDataEncoder(),
|
|
6688
6980
|
getUpdatePlatformConfigInstructionDataDecoder()
|
|
6689
6981
|
);
|
|
@@ -6734,7 +7026,7 @@ function parseUpdatePlatformConfigInstruction(instruction) {
|
|
|
6734
7026
|
}
|
|
6735
7027
|
|
|
6736
7028
|
// src/generated/instructions/withdrawReward.ts
|
|
6737
|
-
var
|
|
7029
|
+
var import_kit87 = require("@solana/kit");
|
|
6738
7030
|
var WITHDRAW_REWARD_DISCRIMINATOR = new Uint8Array([
|
|
6739
7031
|
191,
|
|
6740
7032
|
187,
|
|
@@ -6746,23 +7038,23 @@ var WITHDRAW_REWARD_DISCRIMINATOR = new Uint8Array([
|
|
|
6746
7038
|
244
|
|
6747
7039
|
]);
|
|
6748
7040
|
function getWithdrawRewardDiscriminatorBytes() {
|
|
6749
|
-
return (0,
|
|
7041
|
+
return (0, import_kit87.fixEncoderSize)((0, import_kit87.getBytesEncoder)(), 8).encode(
|
|
6750
7042
|
WITHDRAW_REWARD_DISCRIMINATOR
|
|
6751
7043
|
);
|
|
6752
7044
|
}
|
|
6753
7045
|
function getWithdrawRewardInstructionDataEncoder() {
|
|
6754
|
-
return (0,
|
|
6755
|
-
(0,
|
|
7046
|
+
return (0, import_kit87.transformEncoder)(
|
|
7047
|
+
(0, import_kit87.getStructEncoder)([["discriminator", (0, import_kit87.fixEncoderSize)((0, import_kit87.getBytesEncoder)(), 8)]]),
|
|
6756
7048
|
(value) => ({ ...value, discriminator: WITHDRAW_REWARD_DISCRIMINATOR })
|
|
6757
7049
|
);
|
|
6758
7050
|
}
|
|
6759
7051
|
function getWithdrawRewardInstructionDataDecoder() {
|
|
6760
|
-
return (0,
|
|
6761
|
-
["discriminator", (0,
|
|
7052
|
+
return (0, import_kit87.getStructDecoder)([
|
|
7053
|
+
["discriminator", (0, import_kit87.fixDecoderSize)((0, import_kit87.getBytesDecoder)(), 8)]
|
|
6762
7054
|
]);
|
|
6763
7055
|
}
|
|
6764
7056
|
function getWithdrawRewardInstructionDataCodec() {
|
|
6765
|
-
return (0,
|
|
7057
|
+
return (0, import_kit87.combineCodec)(
|
|
6766
7058
|
getWithdrawRewardInstructionDataEncoder(),
|
|
6767
7059
|
getWithdrawRewardInstructionDataDecoder()
|
|
6768
7060
|
);
|
|
@@ -6783,24 +7075,24 @@ async function getWithdrawRewardInstructionAsync(input, config) {
|
|
|
6783
7075
|
};
|
|
6784
7076
|
const accounts = originalAccounts;
|
|
6785
7077
|
if (!accounts.sponsorAccount.value) {
|
|
6786
|
-
accounts.sponsorAccount.value = await (0,
|
|
7078
|
+
accounts.sponsorAccount.value = await (0, import_kit87.getProgramDerivedAddress)({
|
|
6787
7079
|
programAddress,
|
|
6788
7080
|
seeds: [
|
|
6789
|
-
(0,
|
|
7081
|
+
(0, import_kit87.getBytesEncoder)().encode(
|
|
6790
7082
|
new Uint8Array([115, 112, 111, 110, 115, 111, 114])
|
|
6791
7083
|
),
|
|
6792
|
-
(0,
|
|
6793
|
-
(0,
|
|
7084
|
+
(0, import_kit87.getAddressEncoder)().encode(expectAddress(accounts.sponsor.value)),
|
|
7085
|
+
(0, import_kit87.getAddressEncoder)().encode(expectAddress(accounts.market.value))
|
|
6794
7086
|
]
|
|
6795
7087
|
});
|
|
6796
7088
|
}
|
|
6797
7089
|
if (!accounts.marketTokenAta.value) {
|
|
6798
|
-
accounts.marketTokenAta.value = await (0,
|
|
7090
|
+
accounts.marketTokenAta.value = await (0, import_kit87.getProgramDerivedAddress)({
|
|
6799
7091
|
programAddress: "ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL",
|
|
6800
7092
|
seeds: [
|
|
6801
|
-
(0,
|
|
6802
|
-
(0,
|
|
6803
|
-
(0,
|
|
7093
|
+
(0, import_kit87.getAddressEncoder)().encode(expectAddress(accounts.market.value)),
|
|
7094
|
+
(0, import_kit87.getAddressEncoder)().encode(expectAddress(accounts.tokenProgram.value)),
|
|
7095
|
+
(0, import_kit87.getAddressEncoder)().encode(expectAddress(accounts.tokenMint.value))
|
|
6804
7096
|
]
|
|
6805
7097
|
});
|
|
6806
7098
|
}
|
|
@@ -6906,7 +7198,7 @@ async function createMarket(input) {
|
|
|
6906
7198
|
}
|
|
6907
7199
|
|
|
6908
7200
|
// src/instructions/initCompDef.ts
|
|
6909
|
-
var
|
|
7201
|
+
var import_kit88 = require("@solana/kit");
|
|
6910
7202
|
var import_client = require("@arcium-hq/client");
|
|
6911
7203
|
var import_web3 = require("@solana/web3.js");
|
|
6912
7204
|
var import_bn = require("bn.js");
|
|
@@ -6915,13 +7207,13 @@ var ALL_COMP_DEF_CIRCUITS = [
|
|
|
6915
7207
|
"reveal_stake"
|
|
6916
7208
|
];
|
|
6917
7209
|
function toAddress(pubkey) {
|
|
6918
|
-
return (0,
|
|
7210
|
+
return (0, import_kit88.address)(pubkey.toBase58());
|
|
6919
7211
|
}
|
|
6920
7212
|
async function getMxeAccount(rpc, programId = OPPORTUNITY_MARKET_PROGRAM_ADDRESS) {
|
|
6921
7213
|
const programIdLegacy = new import_web3.PublicKey(programId);
|
|
6922
7214
|
const mxeAddress = toAddress((0, import_client.getMXEAccAddress)(programIdLegacy));
|
|
6923
|
-
const encoded = await (0,
|
|
6924
|
-
(0,
|
|
7215
|
+
const encoded = await (0, import_kit88.fetchEncodedAccount)(rpc, mxeAddress);
|
|
7216
|
+
(0, import_kit88.assertAccountExists)(encoded);
|
|
6925
7217
|
const data = getMXEAccountDecoder().decode(encoded.data.slice(8));
|
|
6926
7218
|
return { address: mxeAddress, data };
|
|
6927
7219
|
}
|
|
@@ -6961,12 +7253,12 @@ async function getInitCompDefInstruction(rpc, payer, circuitName, config = {}) {
|
|
|
6961
7253
|
}
|
|
6962
7254
|
|
|
6963
7255
|
// src/arcium/computeAccounts.ts
|
|
6964
|
-
var
|
|
7256
|
+
var import_kit89 = require("@solana/kit");
|
|
6965
7257
|
var import_client2 = require("@arcium-hq/client");
|
|
6966
7258
|
var import_web32 = require("@solana/web3.js");
|
|
6967
7259
|
var import_bn2 = __toESM(require("bn.js"), 1);
|
|
6968
7260
|
function toAddress2(pubkey) {
|
|
6969
|
-
return (0,
|
|
7261
|
+
return (0, import_kit89.address)(pubkey.toBase58());
|
|
6970
7262
|
}
|
|
6971
7263
|
function getComputeAccounts(ixName, config) {
|
|
6972
7264
|
const programId = config.programId ?? OPPORTUNITY_MARKET_PROGRAM_ADDRESS;
|
|
@@ -7171,6 +7463,15 @@ async function initAllowedMint(input) {
|
|
|
7171
7463
|
);
|
|
7172
7464
|
}
|
|
7173
7465
|
|
|
7466
|
+
// src/instructions/claimRewards.ts
|
|
7467
|
+
async function claimRewards(input) {
|
|
7468
|
+
const { programAddress, ...params } = input;
|
|
7469
|
+
return getClaimRewardsInstructionAsync(
|
|
7470
|
+
params,
|
|
7471
|
+
programAddress ? { programAddress } : void 0
|
|
7472
|
+
);
|
|
7473
|
+
}
|
|
7474
|
+
|
|
7174
7475
|
// src/instructions/closeStakeAccount.ts
|
|
7175
7476
|
async function closeStakeAccount(input) {
|
|
7176
7477
|
const { programAddress, ...params } = input;
|
|
@@ -7180,6 +7481,15 @@ async function closeStakeAccount(input) {
|
|
|
7180
7481
|
);
|
|
7181
7482
|
}
|
|
7182
7483
|
|
|
7484
|
+
// src/instructions/closeUnrevealedStakeAccount.ts
|
|
7485
|
+
async function closeUnrevealedStakeAccount(input) {
|
|
7486
|
+
const { programAddress, ...params } = input;
|
|
7487
|
+
return getCloseUnrevealedStakeAccountInstructionAsync(
|
|
7488
|
+
params,
|
|
7489
|
+
programAddress ? { programAddress } : void 0
|
|
7490
|
+
);
|
|
7491
|
+
}
|
|
7492
|
+
|
|
7183
7493
|
// src/instructions/closeStuckStakeAccount.ts
|
|
7184
7494
|
async function closeStuckStakeAccount(input) {
|
|
7185
7495
|
const { programAddress, ...params } = input;
|
|
@@ -7217,15 +7527,15 @@ async function finalizeRevealStake(input) {
|
|
|
7217
7527
|
}
|
|
7218
7528
|
|
|
7219
7529
|
// src/accounts/platformConfig.ts
|
|
7220
|
-
var
|
|
7530
|
+
var import_kit90 = require("@solana/kit");
|
|
7221
7531
|
var PLATFORM_CONFIG_SEED = "platform_config";
|
|
7222
7532
|
async function getPlatformConfigAddress(authority, name, programId = OPPORTUNITY_MARKET_PROGRAM_ADDRESS) {
|
|
7223
|
-
return (0,
|
|
7533
|
+
return (0, import_kit90.getProgramDerivedAddress)({
|
|
7224
7534
|
programAddress: programId,
|
|
7225
7535
|
seeds: [
|
|
7226
7536
|
PLATFORM_CONFIG_SEED,
|
|
7227
|
-
(0,
|
|
7228
|
-
(0,
|
|
7537
|
+
(0, import_kit90.getAddressEncoder)().encode(authority),
|
|
7538
|
+
(0, import_kit90.getUtf8Encoder)().encode(name)
|
|
7229
7539
|
]
|
|
7230
7540
|
});
|
|
7231
7541
|
}
|
|
@@ -7360,51 +7670,51 @@ function setFeeClaimAuthority(input) {
|
|
|
7360
7670
|
}
|
|
7361
7671
|
|
|
7362
7672
|
// src/accounts/allowedMint.ts
|
|
7363
|
-
var
|
|
7673
|
+
var import_kit91 = require("@solana/kit");
|
|
7364
7674
|
var ALLOWED_MINT_SEED = "allowed_mint";
|
|
7365
7675
|
async function getAllowedMintAddress(platformConfig, mint, programId = OPPORTUNITY_MARKET_PROGRAM_ADDRESS) {
|
|
7366
|
-
const enc = (0,
|
|
7367
|
-
return (0,
|
|
7676
|
+
const enc = (0, import_kit91.getAddressEncoder)();
|
|
7677
|
+
return (0, import_kit91.getProgramDerivedAddress)({
|
|
7368
7678
|
programAddress: programId,
|
|
7369
7679
|
seeds: [ALLOWED_MINT_SEED, enc.encode(platformConfig), enc.encode(mint)]
|
|
7370
7680
|
});
|
|
7371
7681
|
}
|
|
7372
7682
|
|
|
7373
7683
|
// src/accounts/opportunityMarket.ts
|
|
7374
|
-
var
|
|
7684
|
+
var import_kit92 = require("@solana/kit");
|
|
7375
7685
|
var OPPORTUNITY_MARKET_SEED = "opportunity_market";
|
|
7376
7686
|
async function getOpportunityMarketAddress(platformConfig, creator, marketIndex, programId = OPPORTUNITY_MARKET_PROGRAM_ADDRESS) {
|
|
7377
|
-
return (0,
|
|
7687
|
+
return (0, import_kit92.getProgramDerivedAddress)({
|
|
7378
7688
|
programAddress: programId,
|
|
7379
7689
|
seeds: [
|
|
7380
7690
|
OPPORTUNITY_MARKET_SEED,
|
|
7381
|
-
(0,
|
|
7382
|
-
(0,
|
|
7383
|
-
(0,
|
|
7691
|
+
(0, import_kit92.getAddressEncoder)().encode(platformConfig),
|
|
7692
|
+
(0, import_kit92.getAddressEncoder)().encode(creator),
|
|
7693
|
+
(0, import_kit92.getU64Encoder)().encode(BigInt(marketIndex))
|
|
7384
7694
|
]
|
|
7385
7695
|
});
|
|
7386
7696
|
}
|
|
7387
7697
|
|
|
7388
7698
|
// src/accounts/opportunityMarketOption.ts
|
|
7389
|
-
var
|
|
7699
|
+
var import_kit93 = require("@solana/kit");
|
|
7390
7700
|
var OPPORTUNITY_MARKET_OPTION_SEED = "option";
|
|
7391
7701
|
async function getOpportunityMarketOptionAddress(market, optionId, programId = OPPORTUNITY_MARKET_PROGRAM_ADDRESS) {
|
|
7392
|
-
return (0,
|
|
7702
|
+
return (0, import_kit93.getProgramDerivedAddress)({
|
|
7393
7703
|
programAddress: programId,
|
|
7394
7704
|
seeds: [
|
|
7395
7705
|
OPPORTUNITY_MARKET_OPTION_SEED,
|
|
7396
|
-
(0,
|
|
7397
|
-
(0,
|
|
7706
|
+
(0, import_kit93.getAddressEncoder)().encode(market),
|
|
7707
|
+
(0, import_kit93.getU64Encoder)().encode(optionId)
|
|
7398
7708
|
]
|
|
7399
7709
|
});
|
|
7400
7710
|
}
|
|
7401
7711
|
|
|
7402
7712
|
// src/accounts/opportunityMarketSponsor.ts
|
|
7403
|
-
var
|
|
7713
|
+
var import_kit94 = require("@solana/kit");
|
|
7404
7714
|
var SPONSOR_SEED = "sponsor";
|
|
7405
7715
|
async function getOpportunityMarketSponsorAddress(sponsor, market, programId = OPPORTUNITY_MARKET_PROGRAM_ADDRESS) {
|
|
7406
|
-
const addressEncoder = (0,
|
|
7407
|
-
return (0,
|
|
7716
|
+
const addressEncoder = (0, import_kit94.getAddressEncoder)();
|
|
7717
|
+
return (0, import_kit94.getProgramDerivedAddress)({
|
|
7408
7718
|
programAddress: programId,
|
|
7409
7719
|
seeds: [
|
|
7410
7720
|
SPONSOR_SEED,
|
|
@@ -7415,13 +7725,13 @@ async function getOpportunityMarketSponsorAddress(sponsor, market, programId = O
|
|
|
7415
7725
|
}
|
|
7416
7726
|
|
|
7417
7727
|
// src/accounts/stakeAccount.ts
|
|
7418
|
-
var
|
|
7728
|
+
var import_kit95 = require("@solana/kit");
|
|
7419
7729
|
var STAKE_ACCOUNT_SEED = "stake_account";
|
|
7420
7730
|
async function getStakeAccountAddress(owner, market, stakeAccountId, programId = OPPORTUNITY_MARKET_PROGRAM_ADDRESS) {
|
|
7421
|
-
const addressEncoder = (0,
|
|
7731
|
+
const addressEncoder = (0, import_kit95.getAddressEncoder)();
|
|
7422
7732
|
const idBytes = new Uint8Array(4);
|
|
7423
7733
|
new DataView(idBytes.buffer).setUint32(0, stakeAccountId, true);
|
|
7424
|
-
return (0,
|
|
7734
|
+
return (0, import_kit95.getProgramDerivedAddress)({
|
|
7425
7735
|
programAddress: programId,
|
|
7426
7736
|
seeds: [
|
|
7427
7737
|
STAKE_ACCOUNT_SEED,
|
|
@@ -7466,9 +7776,11 @@ function nonceToBytes(nonce) {
|
|
|
7466
7776
|
ARCIUM_SIGNER_ACCOUNT_DISCRIMINATOR,
|
|
7467
7777
|
CLAIM_CREATOR_FEES_DISCRIMINATOR,
|
|
7468
7778
|
CLAIM_FEES_DISCRIMINATOR,
|
|
7779
|
+
CLAIM_REWARDS_DISCRIMINATOR,
|
|
7469
7780
|
CLOSE_OPTION_ACCOUNT_DISCRIMINATOR,
|
|
7470
7781
|
CLOSE_STAKE_ACCOUNT_DISCRIMINATOR,
|
|
7471
7782
|
CLOSE_STUCK_STAKE_ACCOUNT_DISCRIMINATOR,
|
|
7783
|
+
CLOSE_UNREVEALED_STAKE_ACCOUNT_DISCRIMINATOR,
|
|
7472
7784
|
CREATE_MARKET_DISCRIMINATOR,
|
|
7473
7785
|
END_REVEAL_PERIOD_DISCRIMINATOR,
|
|
7474
7786
|
FINALIZE_REVEAL_STAKE_DISCRIMINATOR,
|
|
@@ -7549,9 +7861,11 @@ function nonceToBytes(nonce) {
|
|
|
7549
7861
|
circuitSource,
|
|
7550
7862
|
claimCreatorFees,
|
|
7551
7863
|
claimFees,
|
|
7864
|
+
claimRewards,
|
|
7552
7865
|
closeOptionAccount,
|
|
7553
7866
|
closeStakeAccount,
|
|
7554
7867
|
closeStuckStakeAccount,
|
|
7868
|
+
closeUnrevealedStakeAccount,
|
|
7555
7869
|
createCipher,
|
|
7556
7870
|
createMarket,
|
|
7557
7871
|
createPlatformConfig,
|
|
@@ -7640,6 +7954,12 @@ function nonceToBytes(nonce) {
|
|
|
7640
7954
|
getClaimFeesInstructionDataCodec,
|
|
7641
7955
|
getClaimFeesInstructionDataDecoder,
|
|
7642
7956
|
getClaimFeesInstructionDataEncoder,
|
|
7957
|
+
getClaimRewardsDiscriminatorBytes,
|
|
7958
|
+
getClaimRewardsInstruction,
|
|
7959
|
+
getClaimRewardsInstructionAsync,
|
|
7960
|
+
getClaimRewardsInstructionDataCodec,
|
|
7961
|
+
getClaimRewardsInstructionDataDecoder,
|
|
7962
|
+
getClaimRewardsInstructionDataEncoder,
|
|
7643
7963
|
getClockAccountCodec,
|
|
7644
7964
|
getClockAccountDecoder,
|
|
7645
7965
|
getClockAccountEncoder,
|
|
@@ -7661,6 +7981,12 @@ function nonceToBytes(nonce) {
|
|
|
7661
7981
|
getCloseStuckStakeAccountInstructionDataCodec,
|
|
7662
7982
|
getCloseStuckStakeAccountInstructionDataDecoder,
|
|
7663
7983
|
getCloseStuckStakeAccountInstructionDataEncoder,
|
|
7984
|
+
getCloseUnrevealedStakeAccountDiscriminatorBytes,
|
|
7985
|
+
getCloseUnrevealedStakeAccountInstruction,
|
|
7986
|
+
getCloseUnrevealedStakeAccountInstructionAsync,
|
|
7987
|
+
getCloseUnrevealedStakeAccountInstructionDataCodec,
|
|
7988
|
+
getCloseUnrevealedStakeAccountInstructionDataDecoder,
|
|
7989
|
+
getCloseUnrevealedStakeAccountInstructionDataEncoder,
|
|
7664
7990
|
getClusterCodec,
|
|
7665
7991
|
getClusterDecoder,
|
|
7666
7992
|
getClusterEncoder,
|
|
@@ -7837,6 +8163,9 @@ function nonceToBytes(nonce) {
|
|
|
7837
8163
|
getRewardWithdrawnEventCodec,
|
|
7838
8164
|
getRewardWithdrawnEventDecoder,
|
|
7839
8165
|
getRewardWithdrawnEventEncoder,
|
|
8166
|
+
getRewardsClaimedEventCodec,
|
|
8167
|
+
getRewardsClaimedEventDecoder,
|
|
8168
|
+
getRewardsClaimedEventEncoder,
|
|
7840
8169
|
getSetFeeClaimAuthorityDiscriminatorBytes,
|
|
7841
8170
|
getSetFeeClaimAuthorityInstruction,
|
|
7842
8171
|
getSetFeeClaimAuthorityInstructionDataCodec,
|
|
@@ -7939,9 +8268,11 @@ function nonceToBytes(nonce) {
|
|
|
7939
8268
|
parseAddRewardInstruction,
|
|
7940
8269
|
parseClaimCreatorFeesInstruction,
|
|
7941
8270
|
parseClaimFeesInstruction,
|
|
8271
|
+
parseClaimRewardsInstruction,
|
|
7942
8272
|
parseCloseOptionAccountInstruction,
|
|
7943
8273
|
parseCloseStakeAccountInstruction,
|
|
7944
8274
|
parseCloseStuckStakeAccountInstruction,
|
|
8275
|
+
parseCloseUnrevealedStakeAccountInstruction,
|
|
7945
8276
|
parseCreateMarketInstruction,
|
|
7946
8277
|
parseEndRevealPeriodInstruction,
|
|
7947
8278
|
parseFinalizeRevealStakeInstruction,
|