@macalinao/clients-mpl-bubblegum 0.3.1 → 0.3.2
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/generated/accounts/index.d.ts +2 -1
- package/dist/generated/accounts/treeConfig.d.ts +22 -7
- package/dist/generated/accounts/treeConfig.d.ts.map +1 -1
- package/dist/generated/accounts/treeConfig.js +7 -0
- package/dist/generated/accounts/treeConfig.js.map +1 -1
- package/dist/generated/accounts/voucher.d.ts +14 -7
- package/dist/generated/accounts/voucher.d.ts.map +1 -1
- package/dist/generated/accounts/voucher.js +7 -0
- package/dist/generated/accounts/voucher.js.map +1 -1
- package/dist/generated/errors/bubblegum.d.ts +0 -1
- package/dist/generated/errors/bubblegum.d.ts.map +1 -1
- package/dist/generated/errors/bubblegum.js +66 -59
- package/dist/generated/errors/bubblegum.js.map +1 -1
- package/dist/generated/errors/index.d.ts +2 -1
- package/dist/generated/index.d.ts +8 -1
- package/dist/generated/instructions/burn.d.ts +141 -17
- package/dist/generated/instructions/burn.d.ts.map +1 -1
- package/dist/generated/instructions/burn.js +23 -0
- package/dist/generated/instructions/burn.js.map +1 -1
- package/dist/generated/instructions/burnV2.d.ts +179 -31
- package/dist/generated/instructions/burnV2.d.ts.map +1 -1
- package/dist/generated/instructions/burnV2.js +21 -0
- package/dist/generated/instructions/burnV2.js.map +1 -1
- package/dist/generated/instructions/cancelRedeem.d.ts +99 -13
- package/dist/generated/instructions/cancelRedeem.d.ts.map +1 -1
- package/dist/generated/instructions/cancelRedeem.js +19 -0
- package/dist/generated/instructions/cancelRedeem.js.map +1 -1
- package/dist/generated/instructions/closeTreeV2.d.ts +85 -19
- package/dist/generated/instructions/closeTreeV2.d.ts.map +1 -1
- package/dist/generated/instructions/closeTreeV2.js +21 -0
- package/dist/generated/instructions/closeTreeV2.js.map +1 -1
- package/dist/generated/instructions/collectV2.d.ts +20 -7
- package/dist/generated/instructions/collectV2.d.ts.map +1 -1
- package/dist/generated/instructions/collectV2.js +10 -0
- package/dist/generated/instructions/collectV2.js.map +1 -1
- package/dist/generated/instructions/compress.d.ts +119 -9
- package/dist/generated/instructions/compress.d.ts.map +1 -1
- package/dist/generated/instructions/compress.js +21 -0
- package/dist/generated/instructions/compress.js.map +1 -1
- package/dist/generated/instructions/createTree.d.ts +117 -11
- package/dist/generated/instructions/createTree.d.ts.map +1 -1
- package/dist/generated/instructions/createTree.js +23 -0
- package/dist/generated/instructions/createTree.js.map +1 -1
- package/dist/generated/instructions/createTreeV2.d.ts +109 -14
- package/dist/generated/instructions/createTreeV2.d.ts.map +1 -1
- package/dist/generated/instructions/createTreeV2.js +23 -0
- package/dist/generated/instructions/createTreeV2.js.map +1 -1
- package/dist/generated/instructions/decompressV1.d.ts +106 -11
- package/dist/generated/instructions/decompressV1.d.ts.map +1 -1
- package/dist/generated/instructions/decompressV1.js +25 -0
- package/dist/generated/instructions/decompressV1.js.map +1 -1
- package/dist/generated/instructions/delegate.d.ts +140 -17
- package/dist/generated/instructions/delegate.d.ts.map +1 -1
- package/dist/generated/instructions/delegate.js +19 -0
- package/dist/generated/instructions/delegate.js.map +1 -1
- package/dist/generated/instructions/delegateAndFreezeV2.d.ts +171 -27
- package/dist/generated/instructions/delegateAndFreezeV2.d.ts.map +1 -1
- package/dist/generated/instructions/delegateAndFreezeV2.js +17 -0
- package/dist/generated/instructions/delegateAndFreezeV2.js.map +1 -1
- package/dist/generated/instructions/delegateV2.d.ts +169 -27
- package/dist/generated/instructions/delegateV2.d.ts.map +1 -1
- package/dist/generated/instructions/delegateV2.js +15 -0
- package/dist/generated/instructions/delegateV2.js.map +1 -1
- package/dist/generated/instructions/freezeV2.d.ts +174 -28
- package/dist/generated/instructions/freezeV2.d.ts.map +1 -1
- package/dist/generated/instructions/freezeV2.js +23 -0
- package/dist/generated/instructions/freezeV2.js.map +1 -1
- package/dist/generated/instructions/index.d.ts +2 -1
- package/dist/generated/instructions/mintToCollectionV1.d.ts +171 -20
- package/dist/generated/instructions/mintToCollectionV1.d.ts.map +1 -1
- package/dist/generated/instructions/mintToCollectionV1.js +23 -0
- package/dist/generated/instructions/mintToCollectionV1.js.map +1 -1
- package/dist/generated/instructions/mintV1.d.ts +109 -11
- package/dist/generated/instructions/mintV1.d.ts.map +1 -1
- package/dist/generated/instructions/mintV1.js +21 -0
- package/dist/generated/instructions/mintV1.js.map +1 -1
- package/dist/generated/instructions/mintV2.d.ts +163 -17
- package/dist/generated/instructions/mintV2.d.ts.map +1 -1
- package/dist/generated/instructions/mintV2.js +45 -0
- package/dist/generated/instructions/mintV2.js.map +1 -1
- package/dist/generated/instructions/redeem.d.ts +153 -17
- package/dist/generated/instructions/redeem.d.ts.map +1 -1
- package/dist/generated/instructions/redeem.js +23 -0
- package/dist/generated/instructions/redeem.js.map +1 -1
- package/dist/generated/instructions/setAndVerifyCollection.d.ts +222 -38
- package/dist/generated/instructions/setAndVerifyCollection.d.ts.map +1 -1
- package/dist/generated/instructions/setAndVerifyCollection.js +21 -0
- package/dist/generated/instructions/setAndVerifyCollection.js.map +1 -1
- package/dist/generated/instructions/setCollectionV2.d.ts +186 -39
- package/dist/generated/instructions/setCollectionV2.d.ts.map +1 -1
- package/dist/generated/instructions/setCollectionV2.js +21 -0
- package/dist/generated/instructions/setCollectionV2.js.map +1 -1
- package/dist/generated/instructions/setDecompressableState.d.ts +40 -9
- package/dist/generated/instructions/setDecompressableState.d.ts.map +1 -1
- package/dist/generated/instructions/setDecompressableState.js +13 -0
- package/dist/generated/instructions/setDecompressableState.js.map +1 -1
- package/dist/generated/instructions/setDecompressibleState.d.ts +41 -9
- package/dist/generated/instructions/setDecompressibleState.d.ts.map +1 -1
- package/dist/generated/instructions/setDecompressibleState.js +14 -0
- package/dist/generated/instructions/setDecompressibleState.js.map +1 -1
- package/dist/generated/instructions/setNonTransferableV2.d.ts +166 -31
- package/dist/generated/instructions/setNonTransferableV2.d.ts.map +1 -1
- package/dist/generated/instructions/setNonTransferableV2.js +23 -0
- package/dist/generated/instructions/setNonTransferableV2.js.map +1 -1
- package/dist/generated/instructions/setTreeDelegate.d.ts +65 -9
- package/dist/generated/instructions/setTreeDelegate.d.ts.map +1 -1
- package/dist/generated/instructions/setTreeDelegate.js +21 -0
- package/dist/generated/instructions/setTreeDelegate.js.map +1 -1
- package/dist/generated/instructions/thawAndRevokeV2.d.ts +158 -24
- package/dist/generated/instructions/thawAndRevokeV2.d.ts.map +1 -1
- package/dist/generated/instructions/thawAndRevokeV2.js +17 -0
- package/dist/generated/instructions/thawAndRevokeV2.js.map +1 -1
- package/dist/generated/instructions/thawV2.d.ts +166 -28
- package/dist/generated/instructions/thawV2.d.ts.map +1 -1
- package/dist/generated/instructions/thawV2.js +15 -0
- package/dist/generated/instructions/thawV2.js.map +1 -1
- package/dist/generated/instructions/transfer.d.ts +140 -17
- package/dist/generated/instructions/transfer.d.ts.map +1 -1
- package/dist/generated/instructions/transfer.js +19 -0
- package/dist/generated/instructions/transfer.js.map +1 -1
- package/dist/generated/instructions/transferV2.d.ts +167 -31
- package/dist/generated/instructions/transferV2.d.ts.map +1 -1
- package/dist/generated/instructions/transferV2.js +21 -0
- package/dist/generated/instructions/transferV2.js.map +1 -1
- package/dist/generated/instructions/unverifyCollection.d.ts +215 -38
- package/dist/generated/instructions/unverifyCollection.d.ts.map +1 -1
- package/dist/generated/instructions/unverifyCollection.js +19 -0
- package/dist/generated/instructions/unverifyCollection.js.map +1 -1
- package/dist/generated/instructions/unverifyCreator.d.ts +161 -17
- package/dist/generated/instructions/unverifyCreator.d.ts.map +1 -1
- package/dist/generated/instructions/unverifyCreator.js +19 -0
- package/dist/generated/instructions/unverifyCreator.js.map +1 -1
- package/dist/generated/instructions/unverifyCreatorV2.d.ts +143 -21
- package/dist/generated/instructions/unverifyCreatorV2.d.ts.map +1 -1
- package/dist/generated/instructions/unverifyCreatorV2.js +19 -0
- package/dist/generated/instructions/unverifyCreatorV2.js.map +1 -1
- package/dist/generated/instructions/updateAssetDataV2.d.ts +180 -28
- package/dist/generated/instructions/updateAssetDataV2.d.ts.map +1 -1
- package/dist/generated/instructions/updateAssetDataV2.js +21 -0
- package/dist/generated/instructions/updateAssetDataV2.js.map +1 -1
- package/dist/generated/instructions/updateMetadata.d.ts +183 -28
- package/dist/generated/instructions/updateMetadata.d.ts.map +1 -1
- package/dist/generated/instructions/updateMetadata.js +21 -0
- package/dist/generated/instructions/updateMetadata.js.map +1 -1
- package/dist/generated/instructions/updateMetadataV2.d.ts +162 -27
- package/dist/generated/instructions/updateMetadataV2.d.ts.map +1 -1
- package/dist/generated/instructions/updateMetadataV2.js +19 -0
- package/dist/generated/instructions/updateMetadataV2.js.map +1 -1
- package/dist/generated/instructions/verifyCollection.d.ts +215 -38
- package/dist/generated/instructions/verifyCollection.d.ts.map +1 -1
- package/dist/generated/instructions/verifyCollection.js +19 -0
- package/dist/generated/instructions/verifyCollection.js.map +1 -1
- package/dist/generated/instructions/verifyCreator.d.ts +161 -17
- package/dist/generated/instructions/verifyCreator.d.ts.map +1 -1
- package/dist/generated/instructions/verifyCreator.js +19 -0
- package/dist/generated/instructions/verifyCreator.js.map +1 -1
- package/dist/generated/instructions/verifyCreatorV2.d.ts +143 -21
- package/dist/generated/instructions/verifyCreatorV2.d.ts.map +1 -1
- package/dist/generated/instructions/verifyCreatorV2.js +19 -0
- package/dist/generated/instructions/verifyCreatorV2.js.map +1 -1
- package/dist/generated/pdas/assetId.d.ts +2 -3
- package/dist/generated/pdas/assetId.d.ts.map +1 -1
- package/dist/generated/pdas/assetId.js +7 -0
- package/dist/generated/pdas/assetId.js.map +1 -1
- package/dist/generated/pdas/bubblegumSigner.d.ts +0 -1
- package/dist/generated/pdas/bubblegumSigner.d.ts.map +1 -1
- package/dist/generated/pdas/bubblegumSigner.js +7 -0
- package/dist/generated/pdas/bubblegumSigner.js.map +1 -1
- package/dist/generated/pdas/index.d.ts +2 -1
- package/dist/generated/pdas/masterEdition.d.ts +2 -3
- package/dist/generated/pdas/masterEdition.d.ts.map +1 -1
- package/dist/generated/pdas/masterEdition.js +7 -0
- package/dist/generated/pdas/masterEdition.js.map +1 -1
- package/dist/generated/pdas/metadata.d.ts +2 -3
- package/dist/generated/pdas/metadata.d.ts.map +1 -1
- package/dist/generated/pdas/metadata.js +7 -0
- package/dist/generated/pdas/metadata.js.map +1 -1
- package/dist/generated/pdas/mintAuthority.d.ts +2 -3
- package/dist/generated/pdas/mintAuthority.d.ts.map +1 -1
- package/dist/generated/pdas/mintAuthority.js +7 -0
- package/dist/generated/pdas/mintAuthority.js.map +1 -1
- package/dist/generated/pdas/treeConfig.d.ts +2 -3
- package/dist/generated/pdas/treeConfig.d.ts.map +1 -1
- package/dist/generated/pdas/treeConfig.js +7 -0
- package/dist/generated/pdas/treeConfig.js.map +1 -1
- package/dist/generated/pdas/voucher.d.ts +2 -3
- package/dist/generated/pdas/voucher.d.ts.map +1 -1
- package/dist/generated/pdas/voucher.js +7 -0
- package/dist/generated/pdas/voucher.js.map +1 -1
- package/dist/generated/programs/bubblegum.d.ts +17 -12
- package/dist/generated/programs/bubblegum.d.ts.map +1 -1
- package/dist/generated/programs/bubblegum.js +11 -1
- package/dist/generated/programs/bubblegum.js.map +1 -1
- package/dist/generated/programs/index.d.ts +2 -1
- package/dist/generated/programs/mplTokenMetadata.d.ts +8 -8
- package/dist/generated/programs/mplTokenMetadata.d.ts.map +1 -1
- package/dist/generated/programs/mplTokenMetadata.js +7 -0
- package/dist/generated/programs/mplTokenMetadata.js.map +1 -1
- package/dist/generated/types/assetDataSchema.d.ts +4 -1
- package/dist/generated/types/assetDataSchema.d.ts.map +1 -1
- package/dist/generated/types/assetDataSchema.js +11 -0
- package/dist/generated/types/assetDataSchema.js.map +1 -1
- package/dist/generated/types/bubblegumEventType.d.ts +4 -1
- package/dist/generated/types/bubblegumEventType.d.ts.map +1 -1
- package/dist/generated/types/bubblegumEventType.js +11 -0
- package/dist/generated/types/bubblegumEventType.js.map +1 -1
- package/dist/generated/types/collection.d.ts +9 -3
- package/dist/generated/types/collection.d.ts.map +1 -1
- package/dist/generated/types/collection.js +7 -0
- package/dist/generated/types/collection.js.map +1 -1
- package/dist/generated/types/creator.d.ts +9 -7
- package/dist/generated/types/creator.d.ts.map +1 -1
- package/dist/generated/types/creator.js +7 -0
- package/dist/generated/types/creator.js.map +1 -1
- package/dist/generated/types/decompressibleState.d.ts +5 -1
- package/dist/generated/types/decompressibleState.d.ts.map +1 -1
- package/dist/generated/types/decompressibleState.js +12 -0
- package/dist/generated/types/decompressibleState.js.map +1 -1
- package/dist/generated/types/index.d.ts +2 -1
- package/dist/generated/types/instructionName.d.ts +4 -1
- package/dist/generated/types/instructionName.d.ts.map +1 -1
- package/dist/generated/types/instructionName.js +11 -0
- package/dist/generated/types/instructionName.js.map +1 -1
- package/dist/generated/types/leafSchema.d.ts +51 -13
- package/dist/generated/types/leafSchema.d.ts.map +1 -1
- package/dist/generated/types/leafSchema.js +7 -0
- package/dist/generated/types/leafSchema.js.map +1 -1
- package/dist/generated/types/metadataArgs.d.ts +19 -7
- package/dist/generated/types/metadataArgs.d.ts.map +1 -1
- package/dist/generated/types/metadataArgs.js +7 -0
- package/dist/generated/types/metadataArgs.js.map +1 -1
- package/dist/generated/types/metadataArgsV2.d.ts +14 -7
- package/dist/generated/types/metadataArgsV2.d.ts.map +1 -1
- package/dist/generated/types/metadataArgsV2.js +7 -0
- package/dist/generated/types/metadataArgsV2.js.map +1 -1
- package/dist/generated/types/tokenProgramVersion.d.ts +1 -1
- package/dist/generated/types/tokenProgramVersion.d.ts.map +1 -1
- package/dist/generated/types/tokenProgramVersion.js +8 -0
- package/dist/generated/types/tokenProgramVersion.js.map +1 -1
- package/dist/generated/types/tokenStandard.d.ts +5 -1
- package/dist/generated/types/tokenStandard.d.ts.map +1 -1
- package/dist/generated/types/tokenStandard.js +12 -0
- package/dist/generated/types/tokenStandard.js.map +1 -1
- package/dist/generated/types/updateArgs.d.ts +26 -7
- package/dist/generated/types/updateArgs.d.ts.map +1 -1
- package/dist/generated/types/updateArgs.js +7 -0
- package/dist/generated/types/updateArgs.js.map +1 -1
- package/dist/generated/types/useMethod.d.ts +1 -1
- package/dist/generated/types/useMethod.d.ts.map +1 -1
- package/dist/generated/types/useMethod.js +8 -0
- package/dist/generated/types/useMethod.js.map +1 -1
- package/dist/generated/types/uses.d.ts +16 -5
- package/dist/generated/types/uses.d.ts.map +1 -1
- package/dist/generated/types/uses.js +7 -0
- package/dist/generated/types/uses.js.map +1 -1
- package/dist/generated/types/version.d.ts +5 -1
- package/dist/generated/types/version.d.ts.map +1 -1
- package/dist/generated/types/version.js +12 -0
- package/dist/generated/types/version.js.map +1 -1
- package/dist/index.d.ts +1 -0
- package/package.json +6 -6
- package/src/generated/accounts/treeConfig.ts +36 -27
- package/src/generated/accounts/voucher.ts +30 -23
- package/src/generated/errors/bubblegum.ts +121 -154
- package/src/generated/instructions/burn.ts +157 -35
- package/src/generated/instructions/burnV2.ts +197 -52
- package/src/generated/instructions/cancelRedeem.ts +116 -32
- package/src/generated/instructions/closeTreeV2.ts +96 -35
- package/src/generated/instructions/collectV2.ts +34 -23
- package/src/generated/instructions/compress.ts +136 -30
- package/src/generated/instructions/createTree.ts +137 -33
- package/src/generated/instructions/createTreeV2.ts +128 -36
- package/src/generated/instructions/decompressV1.ts +124 -31
- package/src/generated/instructions/delegate.ts +159 -38
- package/src/generated/instructions/delegateAndFreezeV2.ts +191 -51
- package/src/generated/instructions/delegateV2.ts +189 -51
- package/src/generated/instructions/freezeV2.ts +193 -49
- package/src/generated/instructions/mintToCollectionV1.ts +186 -37
- package/src/generated/instructions/mintV1.ts +127 -31
- package/src/generated/instructions/mintV2.ts +184 -45
- package/src/generated/instructions/redeem.ts +172 -38
- package/src/generated/instructions/setAndVerifyCollection.ts +236 -54
- package/src/generated/instructions/setCollectionV2.ts +202 -58
- package/src/generated/instructions/setDecompressableState.ts +59 -31
- package/src/generated/instructions/setDecompressibleState.ts +60 -31
- package/src/generated/instructions/setNonTransferableV2.ts +184 -52
- package/src/generated/instructions/setTreeDelegate.ts +82 -28
- package/src/generated/instructions/thawAndRevokeV2.ts +179 -48
- package/src/generated/instructions/thawV2.ts +185 -49
- package/src/generated/instructions/transfer.ts +156 -35
- package/src/generated/instructions/transferV2.ts +185 -52
- package/src/generated/instructions/unverifyCollection.ts +229 -54
- package/src/generated/instructions/unverifyCreator.ts +181 -39
- package/src/generated/instructions/unverifyCreatorV2.ts +164 -46
- package/src/generated/instructions/updateAssetDataV2.ts +200 -50
- package/src/generated/instructions/updateMetadata.ts +200 -52
- package/src/generated/instructions/updateMetadataV2.ts +183 -54
- package/src/generated/instructions/verifyCollection.ts +229 -54
- package/src/generated/instructions/verifyCreator.ts +181 -39
- package/src/generated/instructions/verifyCreatorV2.ts +164 -46
- package/src/generated/pdas/assetId.ts +4 -3
- package/src/generated/pdas/bubblegumSigner.ts +6 -2
- package/src/generated/pdas/masterEdition.ts +4 -3
- package/src/generated/pdas/metadata.ts +4 -3
- package/src/generated/pdas/mintAuthority.ts +8 -4
- package/src/generated/pdas/treeConfig.ts +8 -4
- package/src/generated/pdas/voucher.ts +4 -3
- package/src/generated/programs/bubblegum.ts +146 -144
- package/src/generated/programs/mplTokenMetadata.ts +5 -10
- package/src/generated/types/assetDataSchema.ts +14 -8
- package/src/generated/types/bubblegumEventType.ts +13 -7
- package/src/generated/types/collection.ts +13 -8
- package/src/generated/types/creator.ts +11 -10
- package/src/generated/types/decompressibleState.ts +14 -7
- package/src/generated/types/instructionName.ts +46 -40
- package/src/generated/types/leafSchema.ts +59 -22
- package/src/generated/types/metadataArgs.ts +35 -27
- package/src/generated/types/metadataArgsV2.ts +23 -20
- package/src/generated/types/tokenProgramVersion.ts +10 -7
- package/src/generated/types/tokenStandard.ts +16 -9
- package/src/generated/types/updateArgs.ts +36 -15
- package/src/generated/types/useMethod.ts +11 -8
- package/src/generated/types/uses.ts +24 -11
- package/src/generated/types/version.ts +14 -7
|
@@ -6,20 +6,21 @@
|
|
|
6
6
|
* @see https://github.com/codama-idl/codama
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
|
-
import type { Address, ProgramDerivedAddress } from "@solana/kit";
|
|
10
9
|
import {
|
|
11
10
|
getAddressEncoder,
|
|
12
11
|
getProgramDerivedAddress,
|
|
13
12
|
getU64Encoder,
|
|
14
13
|
getUtf8Encoder,
|
|
14
|
+
type Address,
|
|
15
|
+
type ProgramDerivedAddress,
|
|
15
16
|
} from "@solana/kit";
|
|
16
17
|
|
|
17
|
-
export
|
|
18
|
+
export type AssetIdSeeds = {
|
|
18
19
|
/** The address of the merkle tree account */
|
|
19
20
|
merkleTree: Address;
|
|
20
21
|
/** The nonce (leaf index) of the leaf */
|
|
21
22
|
nonce: number | bigint;
|
|
22
|
-
}
|
|
23
|
+
};
|
|
23
24
|
|
|
24
25
|
/** Deterministic asset id for a compressed NFT leaf */
|
|
25
26
|
export async function findAssetIdPda(
|
|
@@ -6,8 +6,12 @@
|
|
|
6
6
|
* @see https://github.com/codama-idl/codama
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
|
-
import
|
|
10
|
-
|
|
9
|
+
import {
|
|
10
|
+
getProgramDerivedAddress,
|
|
11
|
+
getUtf8Encoder,
|
|
12
|
+
type Address,
|
|
13
|
+
type ProgramDerivedAddress,
|
|
14
|
+
} from "@solana/kit";
|
|
11
15
|
|
|
12
16
|
/** PDA used by Bubblegum to sign Token Metadata collection CPIs */
|
|
13
17
|
export async function findBubblegumSignerPda(
|
|
@@ -6,17 +6,18 @@
|
|
|
6
6
|
* @see https://github.com/codama-idl/codama
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
|
-
import type { Address, ProgramDerivedAddress } from "@solana/kit";
|
|
10
9
|
import {
|
|
11
10
|
getAddressEncoder,
|
|
12
11
|
getProgramDerivedAddress,
|
|
13
12
|
getUtf8Encoder,
|
|
13
|
+
type Address,
|
|
14
|
+
type ProgramDerivedAddress,
|
|
14
15
|
} from "@solana/kit";
|
|
15
16
|
|
|
16
|
-
export
|
|
17
|
+
export type MasterEditionSeeds = {
|
|
17
18
|
programId: Address;
|
|
18
19
|
mint: Address;
|
|
19
|
-
}
|
|
20
|
+
};
|
|
20
21
|
|
|
21
22
|
/** Master edition account for a mint */
|
|
22
23
|
export async function findMasterEditionPda(
|
|
@@ -6,17 +6,18 @@
|
|
|
6
6
|
* @see https://github.com/codama-idl/codama
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
|
-
import type { Address, ProgramDerivedAddress } from "@solana/kit";
|
|
10
9
|
import {
|
|
11
10
|
getAddressEncoder,
|
|
12
11
|
getProgramDerivedAddress,
|
|
13
12
|
getUtf8Encoder,
|
|
13
|
+
type Address,
|
|
14
|
+
type ProgramDerivedAddress,
|
|
14
15
|
} from "@solana/kit";
|
|
15
16
|
|
|
16
|
-
export
|
|
17
|
+
export type MetadataSeeds = {
|
|
17
18
|
programId: Address;
|
|
18
19
|
mint: Address;
|
|
19
|
-
}
|
|
20
|
+
};
|
|
20
21
|
|
|
21
22
|
/** Token Metadata account for a mint */
|
|
22
23
|
export async function findMetadataPda(
|
|
@@ -6,13 +6,17 @@
|
|
|
6
6
|
* @see https://github.com/codama-idl/codama
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
|
-
import
|
|
10
|
-
|
|
9
|
+
import {
|
|
10
|
+
getAddressEncoder,
|
|
11
|
+
getProgramDerivedAddress,
|
|
12
|
+
type Address,
|
|
13
|
+
type ProgramDerivedAddress,
|
|
14
|
+
} from "@solana/kit";
|
|
11
15
|
|
|
12
|
-
export
|
|
16
|
+
export type MintAuthoritySeeds = {
|
|
13
17
|
/** The address of the decompressed mint account */
|
|
14
18
|
mint: Address;
|
|
15
|
-
}
|
|
19
|
+
};
|
|
16
20
|
|
|
17
21
|
/** Mint authority PDA for a decompressed NFT mint */
|
|
18
22
|
export async function findMintAuthorityPda(
|
|
@@ -6,13 +6,17 @@
|
|
|
6
6
|
* @see https://github.com/codama-idl/codama
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
|
-
import
|
|
10
|
-
|
|
9
|
+
import {
|
|
10
|
+
getAddressEncoder,
|
|
11
|
+
getProgramDerivedAddress,
|
|
12
|
+
type Address,
|
|
13
|
+
type ProgramDerivedAddress,
|
|
14
|
+
} from "@solana/kit";
|
|
11
15
|
|
|
12
|
-
export
|
|
16
|
+
export type TreeConfigSeeds = {
|
|
13
17
|
/** The address of the merkle tree account */
|
|
14
18
|
merkleTree: Address;
|
|
15
|
-
}
|
|
19
|
+
};
|
|
16
20
|
|
|
17
21
|
/** Tree authority / config PDA that manages a concurrent merkle tree */
|
|
18
22
|
export async function findTreeConfigPda(
|
|
@@ -6,20 +6,21 @@
|
|
|
6
6
|
* @see https://github.com/codama-idl/codama
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
|
-
import type { Address, ProgramDerivedAddress } from "@solana/kit";
|
|
10
9
|
import {
|
|
11
10
|
getAddressEncoder,
|
|
12
11
|
getProgramDerivedAddress,
|
|
13
12
|
getU64Encoder,
|
|
14
13
|
getUtf8Encoder,
|
|
14
|
+
type Address,
|
|
15
|
+
type ProgramDerivedAddress,
|
|
15
16
|
} from "@solana/kit";
|
|
16
17
|
|
|
17
|
-
export
|
|
18
|
+
export type VoucherSeeds = {
|
|
18
19
|
/** The address of the merkle tree account */
|
|
19
20
|
merkleTree: Address;
|
|
20
21
|
/** The nonce (leaf index) of the redeemed leaf */
|
|
21
22
|
nonce: number | bigint;
|
|
22
|
-
}
|
|
23
|
+
};
|
|
23
24
|
|
|
24
25
|
/** Redemption voucher PDA created when a leaf is redeemed */
|
|
25
26
|
export async function findVoucherPda(
|
|
@@ -6,102 +6,6 @@
|
|
|
6
6
|
* @see https://github.com/codama-idl/codama
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
|
-
import type {
|
|
10
|
-
Address,
|
|
11
|
-
ClientWithPayer,
|
|
12
|
-
ClientWithRpc,
|
|
13
|
-
ClientWithTransactionPlanning,
|
|
14
|
-
ClientWithTransactionSending,
|
|
15
|
-
GetAccountInfoApi,
|
|
16
|
-
GetMultipleAccountsApi,
|
|
17
|
-
Instruction,
|
|
18
|
-
InstructionWithData,
|
|
19
|
-
ReadonlyUint8Array,
|
|
20
|
-
} from "@solana/kit";
|
|
21
|
-
import type {
|
|
22
|
-
SelfFetchFunctions,
|
|
23
|
-
SelfPlanAndSendFunctions,
|
|
24
|
-
} from "@solana/program-client-core";
|
|
25
|
-
import type {
|
|
26
|
-
TreeConfig,
|
|
27
|
-
TreeConfigArgs,
|
|
28
|
-
Voucher,
|
|
29
|
-
VoucherArgs,
|
|
30
|
-
} from "../accounts/index.js";
|
|
31
|
-
import type {
|
|
32
|
-
BurnAsyncInput,
|
|
33
|
-
BurnV2AsyncInput,
|
|
34
|
-
CancelRedeemAsyncInput,
|
|
35
|
-
CloseTreeV2AsyncInput,
|
|
36
|
-
CollectV2Input,
|
|
37
|
-
CompressAsyncInput,
|
|
38
|
-
CreateTreeAsyncInput,
|
|
39
|
-
CreateTreeV2AsyncInput,
|
|
40
|
-
DecompressV1AsyncInput,
|
|
41
|
-
DelegateAndFreezeV2AsyncInput,
|
|
42
|
-
DelegateAsyncInput,
|
|
43
|
-
DelegateV2AsyncInput,
|
|
44
|
-
FreezeV2AsyncInput,
|
|
45
|
-
MintToCollectionV1AsyncInput,
|
|
46
|
-
MintV1AsyncInput,
|
|
47
|
-
MintV2AsyncInput,
|
|
48
|
-
ParsedBurnInstruction,
|
|
49
|
-
ParsedBurnV2Instruction,
|
|
50
|
-
ParsedCancelRedeemInstruction,
|
|
51
|
-
ParsedCloseTreeV2Instruction,
|
|
52
|
-
ParsedCollectV2Instruction,
|
|
53
|
-
ParsedCompressInstruction,
|
|
54
|
-
ParsedCreateTreeInstruction,
|
|
55
|
-
ParsedCreateTreeV2Instruction,
|
|
56
|
-
ParsedDecompressV1Instruction,
|
|
57
|
-
ParsedDelegateAndFreezeV2Instruction,
|
|
58
|
-
ParsedDelegateInstruction,
|
|
59
|
-
ParsedDelegateV2Instruction,
|
|
60
|
-
ParsedFreezeV2Instruction,
|
|
61
|
-
ParsedMintToCollectionV1Instruction,
|
|
62
|
-
ParsedMintV1Instruction,
|
|
63
|
-
ParsedMintV2Instruction,
|
|
64
|
-
ParsedRedeemInstruction,
|
|
65
|
-
ParsedSetAndVerifyCollectionInstruction,
|
|
66
|
-
ParsedSetCollectionV2Instruction,
|
|
67
|
-
ParsedSetDecompressableStateInstruction,
|
|
68
|
-
ParsedSetDecompressibleStateInstruction,
|
|
69
|
-
ParsedSetNonTransferableV2Instruction,
|
|
70
|
-
ParsedSetTreeDelegateInstruction,
|
|
71
|
-
ParsedThawAndRevokeV2Instruction,
|
|
72
|
-
ParsedThawV2Instruction,
|
|
73
|
-
ParsedTransferInstruction,
|
|
74
|
-
ParsedTransferV2Instruction,
|
|
75
|
-
ParsedUnverifyCollectionInstruction,
|
|
76
|
-
ParsedUnverifyCreatorInstruction,
|
|
77
|
-
ParsedUnverifyCreatorV2Instruction,
|
|
78
|
-
ParsedUpdateAssetDataV2Instruction,
|
|
79
|
-
ParsedUpdateMetadataInstruction,
|
|
80
|
-
ParsedUpdateMetadataV2Instruction,
|
|
81
|
-
ParsedVerifyCollectionInstruction,
|
|
82
|
-
ParsedVerifyCreatorInstruction,
|
|
83
|
-
ParsedVerifyCreatorV2Instruction,
|
|
84
|
-
RedeemAsyncInput,
|
|
85
|
-
SetAndVerifyCollectionAsyncInput,
|
|
86
|
-
SetCollectionV2AsyncInput,
|
|
87
|
-
SetDecompressableStateInput,
|
|
88
|
-
SetDecompressibleStateInput,
|
|
89
|
-
SetNonTransferableV2AsyncInput,
|
|
90
|
-
SetTreeDelegateAsyncInput,
|
|
91
|
-
ThawAndRevokeV2AsyncInput,
|
|
92
|
-
ThawV2AsyncInput,
|
|
93
|
-
TransferAsyncInput,
|
|
94
|
-
TransferV2AsyncInput,
|
|
95
|
-
UnverifyCollectionAsyncInput,
|
|
96
|
-
UnverifyCreatorAsyncInput,
|
|
97
|
-
UnverifyCreatorV2AsyncInput,
|
|
98
|
-
UpdateAssetDataV2AsyncInput,
|
|
99
|
-
UpdateMetadataAsyncInput,
|
|
100
|
-
UpdateMetadataV2AsyncInput,
|
|
101
|
-
VerifyCollectionAsyncInput,
|
|
102
|
-
VerifyCreatorAsyncInput,
|
|
103
|
-
VerifyCreatorV2AsyncInput,
|
|
104
|
-
} from "../instructions/index.js";
|
|
105
9
|
import {
|
|
106
10
|
assertIsInstructionWithAccounts,
|
|
107
11
|
containsBytes,
|
|
@@ -112,12 +16,32 @@ import {
|
|
|
112
16
|
SOLANA_ERROR__PROGRAM_CLIENTS__FAILED_TO_IDENTIFY_INSTRUCTION,
|
|
113
17
|
SOLANA_ERROR__PROGRAM_CLIENTS__UNRECOGNIZED_INSTRUCTION_TYPE,
|
|
114
18
|
SolanaError,
|
|
19
|
+
type Address,
|
|
20
|
+
type ClientWithPayer,
|
|
21
|
+
type ClientWithRpc,
|
|
22
|
+
type ClientWithTransactionPlanning,
|
|
23
|
+
type ClientWithTransactionSending,
|
|
24
|
+
type ExtendedClient,
|
|
25
|
+
type GetAccountInfoApi,
|
|
26
|
+
type GetMultipleAccountsApi,
|
|
27
|
+
type Instruction,
|
|
28
|
+
type InstructionWithData,
|
|
29
|
+
type ReadonlyUint8Array,
|
|
115
30
|
} from "@solana/kit";
|
|
116
31
|
import {
|
|
117
32
|
addSelfFetchFunctions,
|
|
118
33
|
addSelfPlanAndSendFunctions,
|
|
34
|
+
type SelfFetchFunctions,
|
|
35
|
+
type SelfPlanAndSendFunctions,
|
|
119
36
|
} from "@solana/program-client-core";
|
|
120
|
-
import {
|
|
37
|
+
import {
|
|
38
|
+
getTreeConfigCodec,
|
|
39
|
+
getVoucherCodec,
|
|
40
|
+
type TreeConfig,
|
|
41
|
+
type TreeConfigArgs,
|
|
42
|
+
type Voucher,
|
|
43
|
+
type VoucherArgs,
|
|
44
|
+
} from "../accounts/index.js";
|
|
121
45
|
import {
|
|
122
46
|
getBurnInstructionAsync,
|
|
123
47
|
getBurnV2InstructionAsync,
|
|
@@ -191,6 +115,78 @@ import {
|
|
|
191
115
|
parseVerifyCollectionInstruction,
|
|
192
116
|
parseVerifyCreatorInstruction,
|
|
193
117
|
parseVerifyCreatorV2Instruction,
|
|
118
|
+
type BurnAsyncInput,
|
|
119
|
+
type BurnV2AsyncInput,
|
|
120
|
+
type CancelRedeemAsyncInput,
|
|
121
|
+
type CloseTreeV2AsyncInput,
|
|
122
|
+
type CollectV2Input,
|
|
123
|
+
type CompressAsyncInput,
|
|
124
|
+
type CreateTreeAsyncInput,
|
|
125
|
+
type CreateTreeV2AsyncInput,
|
|
126
|
+
type DecompressV1AsyncInput,
|
|
127
|
+
type DelegateAndFreezeV2AsyncInput,
|
|
128
|
+
type DelegateAsyncInput,
|
|
129
|
+
type DelegateV2AsyncInput,
|
|
130
|
+
type FreezeV2AsyncInput,
|
|
131
|
+
type MintToCollectionV1AsyncInput,
|
|
132
|
+
type MintV1AsyncInput,
|
|
133
|
+
type MintV2AsyncInput,
|
|
134
|
+
type ParsedBurnInstruction,
|
|
135
|
+
type ParsedBurnV2Instruction,
|
|
136
|
+
type ParsedCancelRedeemInstruction,
|
|
137
|
+
type ParsedCloseTreeV2Instruction,
|
|
138
|
+
type ParsedCollectV2Instruction,
|
|
139
|
+
type ParsedCompressInstruction,
|
|
140
|
+
type ParsedCreateTreeInstruction,
|
|
141
|
+
type ParsedCreateTreeV2Instruction,
|
|
142
|
+
type ParsedDecompressV1Instruction,
|
|
143
|
+
type ParsedDelegateAndFreezeV2Instruction,
|
|
144
|
+
type ParsedDelegateInstruction,
|
|
145
|
+
type ParsedDelegateV2Instruction,
|
|
146
|
+
type ParsedFreezeV2Instruction,
|
|
147
|
+
type ParsedMintToCollectionV1Instruction,
|
|
148
|
+
type ParsedMintV1Instruction,
|
|
149
|
+
type ParsedMintV2Instruction,
|
|
150
|
+
type ParsedRedeemInstruction,
|
|
151
|
+
type ParsedSetAndVerifyCollectionInstruction,
|
|
152
|
+
type ParsedSetCollectionV2Instruction,
|
|
153
|
+
type ParsedSetDecompressableStateInstruction,
|
|
154
|
+
type ParsedSetDecompressibleStateInstruction,
|
|
155
|
+
type ParsedSetNonTransferableV2Instruction,
|
|
156
|
+
type ParsedSetTreeDelegateInstruction,
|
|
157
|
+
type ParsedThawAndRevokeV2Instruction,
|
|
158
|
+
type ParsedThawV2Instruction,
|
|
159
|
+
type ParsedTransferInstruction,
|
|
160
|
+
type ParsedTransferV2Instruction,
|
|
161
|
+
type ParsedUnverifyCollectionInstruction,
|
|
162
|
+
type ParsedUnverifyCreatorInstruction,
|
|
163
|
+
type ParsedUnverifyCreatorV2Instruction,
|
|
164
|
+
type ParsedUpdateAssetDataV2Instruction,
|
|
165
|
+
type ParsedUpdateMetadataInstruction,
|
|
166
|
+
type ParsedUpdateMetadataV2Instruction,
|
|
167
|
+
type ParsedVerifyCollectionInstruction,
|
|
168
|
+
type ParsedVerifyCreatorInstruction,
|
|
169
|
+
type ParsedVerifyCreatorV2Instruction,
|
|
170
|
+
type RedeemAsyncInput,
|
|
171
|
+
type SetAndVerifyCollectionAsyncInput,
|
|
172
|
+
type SetCollectionV2AsyncInput,
|
|
173
|
+
type SetDecompressableStateInput,
|
|
174
|
+
type SetDecompressibleStateInput,
|
|
175
|
+
type SetNonTransferableV2AsyncInput,
|
|
176
|
+
type SetTreeDelegateAsyncInput,
|
|
177
|
+
type ThawAndRevokeV2AsyncInput,
|
|
178
|
+
type ThawV2AsyncInput,
|
|
179
|
+
type TransferAsyncInput,
|
|
180
|
+
type TransferV2AsyncInput,
|
|
181
|
+
type UnverifyCollectionAsyncInput,
|
|
182
|
+
type UnverifyCreatorAsyncInput,
|
|
183
|
+
type UnverifyCreatorV2AsyncInput,
|
|
184
|
+
type UpdateAssetDataV2AsyncInput,
|
|
185
|
+
type UpdateMetadataAsyncInput,
|
|
186
|
+
type UpdateMetadataV2AsyncInput,
|
|
187
|
+
type VerifyCollectionAsyncInput,
|
|
188
|
+
type VerifyCreatorAsyncInput,
|
|
189
|
+
type VerifyCreatorV2AsyncInput,
|
|
194
190
|
} from "../instructions/index.js";
|
|
195
191
|
import {
|
|
196
192
|
findAssetIdPda,
|
|
@@ -204,8 +200,8 @@ export const BUBBLEGUM_PROGRAM_ADDRESS =
|
|
|
204
200
|
"BGUMAp9Gq7iTEuizy4pqaxsTyUCBK68MDfK752saRPUY" as Address<"BGUMAp9Gq7iTEuizy4pqaxsTyUCBK68MDfK752saRPUY">;
|
|
205
201
|
|
|
206
202
|
export enum BubblegumAccount {
|
|
207
|
-
TreeConfig
|
|
208
|
-
Voucher
|
|
203
|
+
TreeConfig,
|
|
204
|
+
Voucher,
|
|
209
205
|
}
|
|
210
206
|
|
|
211
207
|
export function identifyBubblegumAccount(
|
|
@@ -241,42 +237,42 @@ export function identifyBubblegumAccount(
|
|
|
241
237
|
}
|
|
242
238
|
|
|
243
239
|
export enum BubblegumInstruction {
|
|
244
|
-
Burn
|
|
245
|
-
BurnV2
|
|
246
|
-
CancelRedeem
|
|
247
|
-
CloseTreeV2
|
|
248
|
-
CollectV2
|
|
249
|
-
Compress
|
|
250
|
-
CreateTree
|
|
251
|
-
CreateTreeV2
|
|
252
|
-
DecompressV1
|
|
253
|
-
Delegate
|
|
254
|
-
DelegateAndFreezeV2
|
|
255
|
-
DelegateV2
|
|
256
|
-
FreezeV2
|
|
257
|
-
MintToCollectionV1
|
|
258
|
-
MintV1
|
|
259
|
-
MintV2
|
|
260
|
-
Redeem
|
|
261
|
-
SetAndVerifyCollection
|
|
262
|
-
SetCollectionV2
|
|
263
|
-
SetDecompressableState
|
|
264
|
-
SetDecompressibleState
|
|
265
|
-
SetNonTransferableV2
|
|
266
|
-
SetTreeDelegate
|
|
267
|
-
ThawAndRevokeV2
|
|
268
|
-
ThawV2
|
|
269
|
-
Transfer
|
|
270
|
-
TransferV2
|
|
271
|
-
UnverifyCollection
|
|
272
|
-
UnverifyCreator
|
|
273
|
-
UnverifyCreatorV2
|
|
274
|
-
UpdateAssetDataV2
|
|
275
|
-
UpdateMetadata
|
|
276
|
-
UpdateMetadataV2
|
|
277
|
-
VerifyCollection
|
|
278
|
-
VerifyCreator
|
|
279
|
-
VerifyCreatorV2
|
|
240
|
+
Burn,
|
|
241
|
+
BurnV2,
|
|
242
|
+
CancelRedeem,
|
|
243
|
+
CloseTreeV2,
|
|
244
|
+
CollectV2,
|
|
245
|
+
Compress,
|
|
246
|
+
CreateTree,
|
|
247
|
+
CreateTreeV2,
|
|
248
|
+
DecompressV1,
|
|
249
|
+
Delegate,
|
|
250
|
+
DelegateAndFreezeV2,
|
|
251
|
+
DelegateV2,
|
|
252
|
+
FreezeV2,
|
|
253
|
+
MintToCollectionV1,
|
|
254
|
+
MintV1,
|
|
255
|
+
MintV2,
|
|
256
|
+
Redeem,
|
|
257
|
+
SetAndVerifyCollection,
|
|
258
|
+
SetCollectionV2,
|
|
259
|
+
SetDecompressableState,
|
|
260
|
+
SetDecompressibleState,
|
|
261
|
+
SetNonTransferableV2,
|
|
262
|
+
SetTreeDelegate,
|
|
263
|
+
ThawAndRevokeV2,
|
|
264
|
+
ThawV2,
|
|
265
|
+
Transfer,
|
|
266
|
+
TransferV2,
|
|
267
|
+
UnverifyCollection,
|
|
268
|
+
UnverifyCreator,
|
|
269
|
+
UnverifyCreatorV2,
|
|
270
|
+
UpdateAssetDataV2,
|
|
271
|
+
UpdateMetadata,
|
|
272
|
+
UpdateMetadataV2,
|
|
273
|
+
VerifyCollection,
|
|
274
|
+
VerifyCreator,
|
|
275
|
+
VerifyCreatorV2,
|
|
280
276
|
}
|
|
281
277
|
|
|
282
278
|
export function identifyBubblegumInstruction(
|
|
@@ -1065,20 +1061,23 @@ export function parseBubblegumInstruction<TProgram extends string>(
|
|
|
1065
1061
|
}
|
|
1066
1062
|
}
|
|
1067
1063
|
|
|
1068
|
-
export
|
|
1064
|
+
export type BubblegumPlugin = {
|
|
1069
1065
|
accounts: BubblegumPluginAccounts;
|
|
1070
1066
|
instructions: BubblegumPluginInstructions;
|
|
1071
1067
|
pdas: BubblegumPluginPdas;
|
|
1072
|
-
|
|
1068
|
+
identifyAccount: typeof identifyBubblegumAccount;
|
|
1069
|
+
identifyInstruction: typeof identifyBubblegumInstruction;
|
|
1070
|
+
parseInstruction: typeof parseBubblegumInstruction;
|
|
1071
|
+
};
|
|
1073
1072
|
|
|
1074
|
-
export
|
|
1073
|
+
export type BubblegumPluginAccounts = {
|
|
1075
1074
|
treeConfig: ReturnType<typeof getTreeConfigCodec> &
|
|
1076
1075
|
SelfFetchFunctions<TreeConfigArgs, TreeConfig>;
|
|
1077
1076
|
voucher: ReturnType<typeof getVoucherCodec> &
|
|
1078
1077
|
SelfFetchFunctions<VoucherArgs, Voucher>;
|
|
1079
|
-
}
|
|
1078
|
+
};
|
|
1080
1079
|
|
|
1081
|
-
export
|
|
1080
|
+
export type BubblegumPluginInstructions = {
|
|
1082
1081
|
burn: (
|
|
1083
1082
|
input: BurnAsyncInput,
|
|
1084
1083
|
) => ReturnType<typeof getBurnInstructionAsync> & SelfPlanAndSendFunctions;
|
|
@@ -1216,15 +1215,15 @@ export interface BubblegumPluginInstructions {
|
|
|
1216
1215
|
input: MakeOptional<VerifyCreatorV2AsyncInput, "payer">,
|
|
1217
1216
|
) => ReturnType<typeof getVerifyCreatorV2InstructionAsync> &
|
|
1218
1217
|
SelfPlanAndSendFunctions;
|
|
1219
|
-
}
|
|
1218
|
+
};
|
|
1220
1219
|
|
|
1221
|
-
export
|
|
1220
|
+
export type BubblegumPluginPdas = {
|
|
1222
1221
|
treeConfig: typeof findTreeConfigPda;
|
|
1223
1222
|
voucher: typeof findVoucherPda;
|
|
1224
1223
|
assetId: typeof findAssetIdPda;
|
|
1225
1224
|
bubblegumSigner: typeof findBubblegumSignerPda;
|
|
1226
1225
|
mintAuthority: typeof findMintAuthorityPda;
|
|
1227
|
-
}
|
|
1226
|
+
};
|
|
1228
1227
|
|
|
1229
1228
|
export type BubblegumPluginRequirements = ClientWithRpc<
|
|
1230
1229
|
GetAccountInfoApi & GetMultipleAccountsApi
|
|
@@ -1236,7 +1235,7 @@ export type BubblegumPluginRequirements = ClientWithRpc<
|
|
|
1236
1235
|
export function bubblegumProgram() {
|
|
1237
1236
|
return <T extends BubblegumPluginRequirements>(
|
|
1238
1237
|
client: T,
|
|
1239
|
-
):
|
|
1238
|
+
): ExtendedClient<T, { bubblegum: BubblegumPlugin }> => {
|
|
1240
1239
|
return extendClient(client, {
|
|
1241
1240
|
bubblegum: <BubblegumPlugin>{
|
|
1242
1241
|
accounts: {
|
|
@@ -1501,6 +1500,9 @@ export function bubblegumProgram() {
|
|
|
1501
1500
|
bubblegumSigner: findBubblegumSignerPda,
|
|
1502
1501
|
mintAuthority: findMintAuthorityPda,
|
|
1503
1502
|
},
|
|
1503
|
+
identifyAccount: identifyBubblegumAccount,
|
|
1504
|
+
identifyInstruction: identifyBubblegumInstruction,
|
|
1505
|
+
parseInstruction: parseBubblegumInstruction,
|
|
1504
1506
|
},
|
|
1505
1507
|
});
|
|
1506
1508
|
};
|
|
@@ -6,30 +6,25 @@
|
|
|
6
6
|
* @see https://github.com/codama-idl/codama
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
|
-
import type
|
|
10
|
-
import { extendClient } from "@solana/kit";
|
|
9
|
+
import { extendClient, type Address, type ExtendedClient } from "@solana/kit";
|
|
11
10
|
import { findMasterEditionPda, findMetadataPda } from "../pdas/index.js";
|
|
12
11
|
|
|
13
12
|
export const MPL_TOKEN_METADATA_PROGRAM_ADDRESS =
|
|
14
13
|
"metaqbxxUerdq28cj1RbAWkYQm3ybzjb6a8bt518x1s" as Address<"metaqbxxUerdq28cj1RbAWkYQm3ybzjb6a8bt518x1s">;
|
|
15
14
|
|
|
16
|
-
export
|
|
17
|
-
pdas: MplTokenMetadataPluginPdas;
|
|
18
|
-
}
|
|
15
|
+
export type MplTokenMetadataPlugin = { pdas: MplTokenMetadataPluginPdas };
|
|
19
16
|
|
|
20
|
-
export
|
|
17
|
+
export type MplTokenMetadataPluginPdas = {
|
|
21
18
|
metadata: typeof findMetadataPda;
|
|
22
19
|
masterEdition: typeof findMasterEditionPda;
|
|
23
|
-
}
|
|
20
|
+
};
|
|
24
21
|
|
|
25
22
|
export type MplTokenMetadataPluginRequirements = object;
|
|
26
23
|
|
|
27
24
|
export function mplTokenMetadataProgram() {
|
|
28
25
|
return <T extends MplTokenMetadataPluginRequirements>(
|
|
29
26
|
client: T,
|
|
30
|
-
):
|
|
31
|
-
mplTokenMetadata: MplTokenMetadataPlugin;
|
|
32
|
-
} => {
|
|
27
|
+
): ExtendedClient<T, { mplTokenMetadata: MplTokenMetadataPlugin }> => {
|
|
33
28
|
return extendClient(client, {
|
|
34
29
|
mplTokenMetadata: <MplTokenMetadataPlugin>{
|
|
35
30
|
pdas: {
|
|
@@ -6,17 +6,23 @@
|
|
|
6
6
|
* @see https://github.com/codama-idl/codama
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
|
-
import
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
9
|
+
import {
|
|
10
|
+
combineCodec,
|
|
11
|
+
getEnumDecoder,
|
|
12
|
+
getEnumEncoder,
|
|
13
|
+
type FixedSizeCodec,
|
|
14
|
+
type FixedSizeDecoder,
|
|
15
|
+
type FixedSizeEncoder,
|
|
13
16
|
} from "@solana/kit";
|
|
14
|
-
import { combineCodec, getEnumDecoder, getEnumEncoder } from "@solana/kit";
|
|
15
17
|
|
|
18
|
+
/**
|
|
19
|
+
* Format of the optional off-chain `assetData` blob attached to a
|
|
20
|
+
* `LeafSchema` V2 asset. Reserved for future use.
|
|
21
|
+
*/
|
|
16
22
|
export enum AssetDataSchema {
|
|
17
|
-
Binary
|
|
18
|
-
Json
|
|
19
|
-
MsgPack
|
|
23
|
+
Binary,
|
|
24
|
+
Json,
|
|
25
|
+
MsgPack,
|
|
20
26
|
}
|
|
21
27
|
|
|
22
28
|
export type AssetDataSchemaArgs = AssetDataSchema;
|
|
@@ -6,16 +6,22 @@
|
|
|
6
6
|
* @see https://github.com/codama-idl/codama
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
|
-
import
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
9
|
+
import {
|
|
10
|
+
combineCodec,
|
|
11
|
+
getEnumDecoder,
|
|
12
|
+
getEnumEncoder,
|
|
13
|
+
type FixedSizeCodec,
|
|
14
|
+
type FixedSizeDecoder,
|
|
15
|
+
type FixedSizeEncoder,
|
|
13
16
|
} from "@solana/kit";
|
|
14
|
-
import { combineCodec, getEnumDecoder, getEnumEncoder } from "@solana/kit";
|
|
15
17
|
|
|
18
|
+
/**
|
|
19
|
+
* Discriminator for events Bubblegum logs via the noop program, read
|
|
20
|
+
* back by off-chain indexers to reconstruct tree state.
|
|
21
|
+
*/
|
|
16
22
|
export enum BubblegumEventType {
|
|
17
|
-
Uninitialized
|
|
18
|
-
LeafSchemaEvent
|
|
23
|
+
Uninitialized,
|
|
24
|
+
LeafSchemaEvent,
|
|
19
25
|
}
|
|
20
26
|
|
|
21
27
|
export type BubblegumEventTypeArgs = BubblegumEventType;
|
|
@@ -6,12 +6,6 @@
|
|
|
6
6
|
* @see https://github.com/codama-idl/codama
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
|
-
import type {
|
|
10
|
-
Address,
|
|
11
|
-
FixedSizeCodec,
|
|
12
|
-
FixedSizeDecoder,
|
|
13
|
-
FixedSizeEncoder,
|
|
14
|
-
} from "@solana/kit";
|
|
15
9
|
import {
|
|
16
10
|
combineCodec,
|
|
17
11
|
getAddressDecoder,
|
|
@@ -20,12 +14,23 @@ import {
|
|
|
20
14
|
getBooleanEncoder,
|
|
21
15
|
getStructDecoder,
|
|
22
16
|
getStructEncoder,
|
|
17
|
+
type Address,
|
|
18
|
+
type FixedSizeCodec,
|
|
19
|
+
type FixedSizeDecoder,
|
|
20
|
+
type FixedSizeEncoder,
|
|
23
21
|
} from "@solana/kit";
|
|
24
22
|
|
|
25
|
-
|
|
23
|
+
/**
|
|
24
|
+
* A collection reference on a V1 leaf's metadata, with its own
|
|
25
|
+
* verified flag independent of the collection's on-chain verification
|
|
26
|
+
* state.
|
|
27
|
+
*/
|
|
28
|
+
export type Collection = {
|
|
29
|
+
/** Whether the collection has been verified via `verifyCollection` / `setAndVerifyCollection`. */
|
|
26
30
|
verified: boolean;
|
|
31
|
+
/** Mint of the collection NFT. */
|
|
27
32
|
key: Address;
|
|
28
|
-
}
|
|
33
|
+
};
|
|
29
34
|
|
|
30
35
|
export type CollectionArgs = Collection;
|
|
31
36
|
|