@percolatorct/sdk 1.0.0-beta.14 → 1.0.0-beta.15
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/index.d.ts +16 -20
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -888,28 +888,24 @@ declare function encodeSetOiImbalanceHardBlock(args: {
|
|
|
888
888
|
* Creates a PositionNft PDA + Token-2022 mint with metadata, then mints 1 NFT to the
|
|
889
889
|
* position owner's ATA. The NFT represents ownership of `user_idx` in the slab.
|
|
890
890
|
*
|
|
891
|
-
*
|
|
891
|
+
* The program creates the ATA internally via CPI when the 11th account (Associated Token
|
|
892
|
+
* Program) is provided. This is required because the NFT mint PDA doesn't exist until the
|
|
893
|
+
* program creates it, so the ATA can't be created in a preceding instruction.
|
|
892
894
|
*
|
|
893
|
-
*
|
|
894
|
-
* 0. [signer, writable] payer
|
|
895
|
-
* 1. [writable] slab
|
|
896
|
-
* 2. [writable] position_nft PDA (created — seeds: ["position_nft", slab, user_idx])
|
|
897
|
-
* 3. [writable] nft_mint PDA (created)
|
|
898
|
-
* 4. [writable] owner_ata (Token-2022 ATA for owner)
|
|
899
|
-
* 5. [signer] owner (must match engine account owner)
|
|
900
|
-
* 6. [] vault_authority PDA
|
|
901
|
-
* 7. [] token_2022_program
|
|
902
|
-
* 8. [] system_program
|
|
903
|
-
* 9. [] rent sysvar
|
|
895
|
+
* Instruction data layout: tag(1) + user_idx(2) = 3 bytes
|
|
904
896
|
*
|
|
905
|
-
*
|
|
906
|
-
*
|
|
907
|
-
*
|
|
908
|
-
*
|
|
909
|
-
*
|
|
910
|
-
*
|
|
911
|
-
*
|
|
912
|
-
*
|
|
897
|
+
* Accounts (11):
|
|
898
|
+
* 0. [signer, writable] payer
|
|
899
|
+
* 1. [writable] slab
|
|
900
|
+
* 2. [writable] position_nft PDA (created — seeds: ["position_nft", slab, user_idx_u16_le])
|
|
901
|
+
* 3. [writable] nft_mint PDA (created — seeds: ["position_nft_mint", slab, user_idx_u16_le])
|
|
902
|
+
* 4. [writable] owner_ata (Token-2022 ATA for nft_mint — created by program if absent)
|
|
903
|
+
* 5. [signer] owner (must match engine account owner)
|
|
904
|
+
* 6. [] vault_authority PDA (seeds: ["vault", slab])
|
|
905
|
+
* 7. [] token_2022_program (TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb)
|
|
906
|
+
* 8. [] system_program
|
|
907
|
+
* 9. [] rent sysvar
|
|
908
|
+
* 10. [] associated_token_program (ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL)
|
|
913
909
|
*/
|
|
914
910
|
interface MintPositionNftArgs {
|
|
915
911
|
userIdx: number;
|
package/dist/index.js
CHANGED
|
@@ -3024,7 +3024,7 @@ import { PublicKey as PublicKey6 } from "@solana/web3.js";
|
|
|
3024
3024
|
// src/solana/static-markets.ts
|
|
3025
3025
|
import { PublicKey as PublicKey5 } from "@solana/web3.js";
|
|
3026
3026
|
var MAINNET_MARKETS = [
|
|
3027
|
-
{ slabAddress: "
|
|
3027
|
+
{ slabAddress: "7psyeWRts4pRX2cyAWD1NH87bR9ugXP7pe6ARgfG79Do", symbol: "SOL-PERP", name: "SOL/USDC Perpetual" }
|
|
3028
3028
|
];
|
|
3029
3029
|
var DEVNET_MARKETS = [
|
|
3030
3030
|
// Populated from prior discoverMarkets() runs on devnet.
|