@lightprotocol/stateless.js 0.21.0 → 0.22.1-alpha.0
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/README.md +10 -10
- package/dist/cjs/browser/actions/compress.d.ts +2 -2
- package/dist/cjs/browser/actions/create-account.d.ts +3 -3
- package/dist/cjs/browser/actions/transfer.d.ts +1 -2
- package/dist/cjs/browser/compressible/action.d.ts +77 -0
- package/dist/cjs/browser/compressible/index.d.ts +13 -0
- package/dist/cjs/browser/compressible/instruction.d.ts +177 -0
- package/dist/cjs/browser/compressible/layout.d.ts +47 -0
- package/dist/cjs/browser/compressible/types.d.ts +112 -0
- package/dist/cjs/browser/compressible/utils.d.ts +16 -0
- package/dist/cjs/browser/constants.d.ts +31 -6
- package/dist/cjs/browser/index.cjs +1 -1
- package/dist/cjs/browser/index.cjs.map +1 -1
- package/dist/cjs/browser/index.d.ts +1 -2
- package/dist/cjs/browser/programs/index.d.ts +0 -1
- package/dist/cjs/browser/{idl.d.ts → programs/system/idl.d.ts} +5 -27
- package/dist/cjs/browser/programs/system/index.d.ts +5 -0
- package/dist/cjs/{node/programs → browser/programs/system}/layout.d.ts +10 -1
- package/dist/cjs/browser/programs/system/pack.d.ts +143 -0
- package/dist/cjs/browser/programs/{system.d.ts → system/program.d.ts} +13 -28
- package/dist/cjs/browser/programs/system/select-compressed-accounts.d.ts +10 -0
- package/dist/cjs/browser/rpc-interface.d.ts +1593 -51
- package/dist/cjs/browser/rpc.d.ts +31 -37
- package/dist/cjs/browser/state/compressed-account.d.ts +140 -6
- package/dist/cjs/browser/state/types.d.ts +265 -26
- package/dist/cjs/browser/test-helpers/test-rpc/get-compressed-accounts.d.ts +1 -10
- package/dist/cjs/browser/test-helpers/test-rpc/get-compressed-token-accounts.d.ts +2 -2
- package/dist/cjs/browser/test-helpers/test-rpc/test-rpc.d.ts +20 -40
- package/dist/cjs/browser/utils/address.d.ts +13 -0
- package/dist/cjs/browser/utils/calculate-compute-unit-price.d.ts +1 -1
- package/dist/cjs/browser/utils/conversion.d.ts +3 -0
- package/dist/cjs/browser/utils/get-state-tree-infos.d.ts +16 -9
- package/dist/cjs/browser/utils/index.d.ts +2 -2
- package/dist/cjs/browser/utils/packed-accounts.d.ts +161 -0
- package/dist/cjs/browser/utils/send-and-confirm.d.ts +1 -1
- package/dist/cjs/browser/utils/validation.d.ts +2 -2
- package/dist/cjs/node/actions/compress.d.ts +2 -2
- package/dist/cjs/node/actions/create-account.d.ts +3 -3
- package/dist/cjs/node/actions/transfer.d.ts +1 -2
- package/dist/cjs/node/compressible/action.d.ts +77 -0
- package/dist/cjs/node/compressible/index.d.ts +13 -0
- package/dist/cjs/node/compressible/instruction.d.ts +177 -0
- package/dist/cjs/node/compressible/layout.d.ts +47 -0
- package/dist/cjs/node/compressible/types.d.ts +112 -0
- package/dist/cjs/node/compressible/utils.d.ts +16 -0
- package/dist/cjs/node/constants.d.ts +31 -6
- package/dist/cjs/node/index.cjs +1 -1
- package/dist/cjs/node/index.cjs.map +1 -1
- package/dist/cjs/node/index.d.ts +1 -2
- package/dist/cjs/node/programs/index.d.ts +0 -1
- package/dist/cjs/node/{idl.d.ts → programs/system/idl.d.ts} +5 -27
- package/dist/cjs/node/programs/system/index.d.ts +5 -0
- package/dist/cjs/{browser/programs → node/programs/system}/layout.d.ts +10 -1
- package/dist/cjs/node/programs/system/pack.d.ts +143 -0
- package/dist/cjs/node/programs/{system.d.ts → system/program.d.ts} +13 -28
- package/dist/cjs/node/programs/system/select-compressed-accounts.d.ts +10 -0
- package/dist/cjs/node/rpc-interface.d.ts +1593 -51
- package/dist/cjs/node/rpc.d.ts +31 -37
- package/dist/cjs/node/state/compressed-account.d.ts +140 -6
- package/dist/cjs/node/state/types.d.ts +265 -26
- package/dist/cjs/node/test-helpers/test-rpc/get-compressed-accounts.d.ts +1 -10
- package/dist/cjs/node/test-helpers/test-rpc/get-compressed-token-accounts.d.ts +2 -2
- package/dist/cjs/node/test-helpers/test-rpc/test-rpc.d.ts +20 -40
- package/dist/cjs/node/utils/address.d.ts +13 -0
- package/dist/cjs/node/utils/calculate-compute-unit-price.d.ts +1 -1
- package/dist/cjs/node/utils/conversion.d.ts +3 -0
- package/dist/cjs/node/utils/get-state-tree-infos.d.ts +16 -9
- package/dist/cjs/node/utils/index.d.ts +2 -2
- package/dist/cjs/node/utils/packed-accounts.d.ts +161 -0
- package/dist/cjs/node/utils/send-and-confirm.d.ts +1 -1
- package/dist/cjs/node/utils/validation.d.ts +2 -2
- package/dist/types/index.d.ts +3391 -864
- package/package.json +13 -6
- package/dist/cjs/browser/instruction/index.d.ts +0 -1
- package/dist/cjs/browser/instruction/pack-compressed-accounts.d.ts +0 -49
- package/dist/cjs/node/instruction/index.d.ts +0 -1
- package/dist/cjs/node/instruction/pack-compressed-accounts.d.ts +0 -49
package/README.md
CHANGED
|
@@ -32,18 +32,18 @@ For a more detailed documentation on usage, please check [the respective section
|
|
|
32
32
|
|
|
33
33
|
For example implementations, including web and Node, refer to the respective repositories:
|
|
34
34
|
|
|
35
|
-
-
|
|
35
|
+
- [Web application example implementation](https://github.com/Lightprotocol/example-web-client)
|
|
36
36
|
|
|
37
|
-
-
|
|
37
|
+
- [Node server example implementation](https://github.com/Lightprotocol/example-nodejs-client)
|
|
38
38
|
|
|
39
39
|
## Troubleshooting
|
|
40
40
|
|
|
41
41
|
Have a question or a problem?
|
|
42
42
|
Feel free to ask in the [Light](https://discord.gg/CYvjBgzRFP) and [Helius](https://discord.gg/Uzzf6a7zKr) developer Discord servers. Please, include the following information:
|
|
43
43
|
|
|
44
|
-
-
|
|
45
|
-
-
|
|
46
|
-
-
|
|
44
|
+
- A detailed description or context of the issue or what you are trying to achieve.
|
|
45
|
+
- A code example that we can use to test and debug (if possible). Use [CodeSandbox](https://codesandbox.io/p/sandbox/vanilla-ts) or any other live environment provider.
|
|
46
|
+
- A description or context of any errors you are encountering with stacktraces if available.
|
|
47
47
|
|
|
48
48
|
### Source Maps
|
|
49
49
|
|
|
@@ -57,14 +57,14 @@ We provide `index.js.map` for debugging. Exclude in production:
|
|
|
57
57
|
|
|
58
58
|
Light and ZK Compression are open source protocols and very much welcome contributions. If you have a contribution, do not hesitate to send a PR to the respective repository or discuss in the linked developer Discord servers.
|
|
59
59
|
|
|
60
|
-
-
|
|
61
|
-
|
|
62
|
-
-
|
|
60
|
+
- 🐞 For bugs or feature requests, please open an
|
|
61
|
+
[issue](https://github.com/lightprotocol/light-protocol/issues/new).
|
|
62
|
+
- 🔒 For security vulnerabilities, please follow the [security policy](https://github.com/Lightprotocol/light-protocol/blob/main/SECURITY.md).
|
|
63
63
|
|
|
64
64
|
## Additional Resources
|
|
65
65
|
|
|
66
|
-
-
|
|
67
|
-
-
|
|
66
|
+
- [Light Protocol Repository](https://github.com/Lightprotocol/light-protocol)
|
|
67
|
+
- [ZK Compression Official Documentation](https://www.zkcompression.com/)
|
|
68
68
|
|
|
69
69
|
## Disclaimer
|
|
70
70
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { ConfirmOptions, PublicKey, Signer, TransactionSignature } from '@solana/web3.js';
|
|
2
2
|
import { Rpc } from '../rpc';
|
|
3
3
|
import BN from 'bn.js';
|
|
4
|
-
import {
|
|
4
|
+
import { TreeInfo } from '../state';
|
|
5
5
|
/**
|
|
6
6
|
* Compress lamports to a solana address
|
|
7
7
|
*
|
|
@@ -15,4 +15,4 @@ import { StateTreeInfo } from '../state';
|
|
|
15
15
|
*
|
|
16
16
|
* @return Transaction signature
|
|
17
17
|
*/
|
|
18
|
-
export declare function compress(rpc: Rpc, payer: Signer, lamports: number | BN, toAddress: PublicKey, outputStateTreeInfo?:
|
|
18
|
+
export declare function compress(rpc: Rpc, payer: Signer, lamports: number | BN, toAddress: PublicKey, outputStateTreeInfo?: TreeInfo, confirmOptions?: ConfirmOptions): Promise<TransactionSignature>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ConfirmOptions, PublicKey, Signer, TransactionSignature } from '@solana/web3.js';
|
|
2
2
|
import { Rpc } from '../rpc';
|
|
3
|
-
import { AddressTreeInfo,
|
|
3
|
+
import { AddressTreeInfo, TreeInfo } from '../state';
|
|
4
4
|
import BN from 'bn.js';
|
|
5
5
|
/**
|
|
6
6
|
* Create compressed account with address
|
|
@@ -17,7 +17,7 @@ import BN from 'bn.js';
|
|
|
17
17
|
*
|
|
18
18
|
* @return Transaction signature
|
|
19
19
|
*/
|
|
20
|
-
export declare function createAccount(rpc: Rpc, payer: Signer, seeds: Uint8Array[], programId: PublicKey, addressTreeInfo?: AddressTreeInfo, outputStateTreeInfo?:
|
|
20
|
+
export declare function createAccount(rpc: Rpc, payer: Signer, seeds: Uint8Array[], programId: PublicKey, addressTreeInfo?: AddressTreeInfo, outputStateTreeInfo?: TreeInfo, confirmOptions?: ConfirmOptions): Promise<TransactionSignature>;
|
|
21
21
|
/**
|
|
22
22
|
* Create compressed account with address and lamports
|
|
23
23
|
*
|
|
@@ -35,4 +35,4 @@ export declare function createAccount(rpc: Rpc, payer: Signer, seeds: Uint8Array
|
|
|
35
35
|
*
|
|
36
36
|
* @return Transaction signature
|
|
37
37
|
*/
|
|
38
|
-
export declare function createAccountWithLamports(rpc: Rpc, payer: Signer, seeds: Uint8Array[], lamports: number | BN, programId: PublicKey, addressTreeInfo?: AddressTreeInfo, outputStateTreeInfo?:
|
|
38
|
+
export declare function createAccountWithLamports(rpc: Rpc, payer: Signer, seeds: Uint8Array[], lamports: number | BN, programId: PublicKey, addressTreeInfo?: AddressTreeInfo, outputStateTreeInfo?: TreeInfo, confirmOptions?: ConfirmOptions): Promise<TransactionSignature>;
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { ConfirmOptions, PublicKey, Signer, TransactionSignature } from '@solana/web3.js';
|
|
2
2
|
import BN from 'bn.js';
|
|
3
3
|
import { Rpc } from '../rpc';
|
|
4
|
-
import { StateTreeInfo } from '../state';
|
|
5
4
|
/**
|
|
6
5
|
* Transfer compressed lamports from one owner to another
|
|
7
6
|
*
|
|
@@ -14,4 +13,4 @@ import { StateTreeInfo } from '../state';
|
|
|
14
13
|
*
|
|
15
14
|
* @return Signature of the confirmed transaction
|
|
16
15
|
*/
|
|
17
|
-
export declare function transfer(rpc: Rpc, payer: Signer, lamports: number | BN, owner: Signer, toAddress: PublicKey,
|
|
16
|
+
export declare function transfer(rpc: Rpc, payer: Signer, lamports: number | BN, owner: Signer, toAddress: PublicKey, confirmOptions?: ConfirmOptions): Promise<TransactionSignature>;
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
import { ConfirmOptions, PublicKey, Signer, TransactionSignature, AccountMeta } from '@solana/web3.js';
|
|
2
|
+
import { Rpc } from '../rpc';
|
|
3
|
+
import { ValidityProof } from '../state/types';
|
|
4
|
+
import { CompressedAccountMeta } from '../state/compressed-account';
|
|
5
|
+
import { CompressedAccountData } from './types';
|
|
6
|
+
/**
|
|
7
|
+
* Initialize a compression config for a compressible program
|
|
8
|
+
*
|
|
9
|
+
* @param rpc RPC connection to use
|
|
10
|
+
* @param payer Fee payer
|
|
11
|
+
* @param programId Program ID for the compressible program
|
|
12
|
+
* @param authority Program upgrade authority
|
|
13
|
+
* @param compressionDelay Compression delay (in slots)
|
|
14
|
+
* @param rentRecipient Rent recipient public key
|
|
15
|
+
* @param addressSpace Array of address space public keys
|
|
16
|
+
* @param configBump Optional config bump (defaults to 0)
|
|
17
|
+
* @param discriminator Optional custom discriminator (defaults to standard)
|
|
18
|
+
* @param confirmOptions Options for confirming the transaction
|
|
19
|
+
*
|
|
20
|
+
* @return Signature of the confirmed transaction
|
|
21
|
+
*/
|
|
22
|
+
export declare function initializeCompressionConfig(rpc: Rpc, payer: Signer, programId: PublicKey, authority: Signer, compressionDelay: number, rentRecipient: PublicKey, addressSpace: PublicKey[], configBump?: number | null, discriminator?: Uint8Array | number[], confirmOptions?: ConfirmOptions): Promise<TransactionSignature>;
|
|
23
|
+
/**
|
|
24
|
+
* Update a compression config for a compressible program
|
|
25
|
+
*
|
|
26
|
+
* @param rpc RPC connection to use
|
|
27
|
+
* @param payer Fee payer
|
|
28
|
+
* @param programId Program ID for the compressible program
|
|
29
|
+
* @param authority Current config authority
|
|
30
|
+
* @param newCompressionDelay Optional new compression delay
|
|
31
|
+
* @param newRentRecipient Optional new rent recipient
|
|
32
|
+
* @param newAddressSpace Optional new address space array
|
|
33
|
+
* @param newUpdateAuthority Optional new update authority
|
|
34
|
+
* @param discriminator Optional custom discriminator (defaults to standard)
|
|
35
|
+
* @param confirmOptions Options for confirming the transaction
|
|
36
|
+
*
|
|
37
|
+
* @return Signature of the confirmed transaction
|
|
38
|
+
*/
|
|
39
|
+
export declare function updateCompressionConfig(rpc: Rpc, payer: Signer, programId: PublicKey, authority: Signer, newCompressionDelay?: number | null, newRentRecipient?: PublicKey | null, newAddressSpace?: PublicKey[] | null, newUpdateAuthority?: PublicKey | null, discriminator?: Uint8Array | number[], confirmOptions?: ConfirmOptions): Promise<TransactionSignature>;
|
|
40
|
+
/**
|
|
41
|
+
* Compress a generic compressible account
|
|
42
|
+
*
|
|
43
|
+
* @param rpc RPC connection to use
|
|
44
|
+
* @param payer Fee payer and signer
|
|
45
|
+
* @param programId Program ID for the compressible program
|
|
46
|
+
* @param pdaToCompress PDA to compress
|
|
47
|
+
* @param rentRecipient Rent recipient public key
|
|
48
|
+
* @param compressedAccountMeta Compressed account metadata
|
|
49
|
+
* @param validityProof Validity proof for compression
|
|
50
|
+
* @param systemAccounts Additional system accounts (trees, queues, etc.)
|
|
51
|
+
* @param discriminator Custom instruction discriminator (8 bytes)
|
|
52
|
+
* @param confirmOptions Options for confirming the transaction
|
|
53
|
+
*
|
|
54
|
+
* @return Signature of the confirmed transaction
|
|
55
|
+
*/
|
|
56
|
+
export declare function compressAccount(rpc: Rpc, payer: Signer, programId: PublicKey, pdaToCompress: PublicKey, rentRecipient: PublicKey, compressedAccountMeta: CompressedAccountMeta, validityProof: ValidityProof, systemAccounts: AccountMeta[], discriminator: Uint8Array | number[], confirmOptions?: ConfirmOptions): Promise<TransactionSignature>;
|
|
57
|
+
/**
|
|
58
|
+
* Decompress one or more compressed accounts idempotently
|
|
59
|
+
*
|
|
60
|
+
* @param rpc RPC connection to use
|
|
61
|
+
* @param payer Fee payer
|
|
62
|
+
* @param programId Program ID for the compressible program
|
|
63
|
+
* @param feePayer Fee payer (can be same as payer)
|
|
64
|
+
* @param rentPayer Rent payer
|
|
65
|
+
* @param solanaAccounts Array of PDA accounts to decompress
|
|
66
|
+
* @param compressedAccountsData Array of compressed account data
|
|
67
|
+
* @param bumps Array of PDA bumps
|
|
68
|
+
* @param validityProof Validity proof for decompression
|
|
69
|
+
* @param systemAccounts Additional system accounts (trees, queues, etc.)
|
|
70
|
+
* @param dataSchema Borsh schema for account data serialization
|
|
71
|
+
* @param discriminator Optional custom discriminator (defaults to standard)
|
|
72
|
+
* @param confirmOptions Options for confirming the transaction
|
|
73
|
+
*
|
|
74
|
+
* @return Signature of the confirmed transaction
|
|
75
|
+
*/
|
|
76
|
+
export declare function decompressAccountsIdempotent<T = any>(rpc: Rpc, payer: Signer, programId: PublicKey, feePayer: Signer, rentPayer: Signer, solanaAccounts: PublicKey[], compressedAccountsData: CompressedAccountData<T>[], bumps: number[], validityProof: ValidityProof, systemAccounts: AccountMeta[], dataSchema: any, // borsh.Layout<T>
|
|
77
|
+
discriminator?: Uint8Array | number[], confirmOptions?: ConfirmOptions): Promise<TransactionSignature>;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export { COMPRESSIBLE_DISCRIMINATORS, DecompressMultipleAccountsIdempotentData, UpdateCompressionConfigData, GenericCompressAccountInstruction, } from './types';
|
|
2
|
+
export { UpdateCompressionConfigSchema, ValidityProofSchema, PackedStateTreeInfoSchema, CompressedAccountMetaSchema, GenericCompressAccountInstructionSchema, createCompressedAccountDataSchema, createDecompressMultipleAccountsIdempotentDataSchema, serializeInstructionData, } from './layout';
|
|
3
|
+
export { createInitializeCompressionConfigInstruction, createUpdateCompressionConfigInstruction, createCompressAccountInstruction, createDecompressAccountsIdempotentInstruction, CompressibleInstruction, } from './instruction';
|
|
4
|
+
export { initializeCompressionConfig, updateCompressionConfig, compressAccount, decompressAccountsIdempotent, } from './action';
|
|
5
|
+
export { deriveCompressionConfigAddress, getProgramDataAccount, checkProgramUpdateAuthority, } from './utils';
|
|
6
|
+
export { serializeInitializeCompressionConfigData } from './layout';
|
|
7
|
+
import { CompressedAccount } from '../state/compressed-account';
|
|
8
|
+
import { CompressedAccountData } from './types';
|
|
9
|
+
/**
|
|
10
|
+
* Convert a compressed account to the format expected by instruction builders
|
|
11
|
+
*/
|
|
12
|
+
export declare function createCompressedAccountData<T>(compressedAccount: CompressedAccount, data: T, seeds: Uint8Array[], outputStateTreeIndex: number): CompressedAccountData<T>;
|
|
13
|
+
export { CompressibleInstruction as compressibleInstruction } from './instruction';
|
|
@@ -0,0 +1,177 @@
|
|
|
1
|
+
import { PublicKey, TransactionInstruction, AccountMeta } from '@solana/web3.js';
|
|
2
|
+
import { CompressedAccountData } from './types';
|
|
3
|
+
import { CompressedAccount } from '../state/compressed-account';
|
|
4
|
+
/**
|
|
5
|
+
* Create an instruction to initialize a compression config.
|
|
6
|
+
*
|
|
7
|
+
* @param programId Program ID for the compressible program
|
|
8
|
+
* @param discriminator Instruction discriminator (8 bytes)
|
|
9
|
+
* @param payer Fee payer
|
|
10
|
+
* @param authority Program upgrade authority
|
|
11
|
+
* @param compressionDelay Compression delay (in slots)
|
|
12
|
+
* @param rentRecipient Rent recipient public key
|
|
13
|
+
* @param addressSpace Array of address space public keys
|
|
14
|
+
* @param configBump Optional config bump (defaults to 0)
|
|
15
|
+
* @returns TransactionInstruction
|
|
16
|
+
*/
|
|
17
|
+
export declare function createInitializeCompressionConfigInstruction(programId: PublicKey, discriminator: Uint8Array | number[], payer: PublicKey, authority: PublicKey, compressionDelay: number, rentRecipient: PublicKey, addressSpace: PublicKey[], configBump?: number | null): TransactionInstruction;
|
|
18
|
+
/**
|
|
19
|
+
* Create an instruction to update a compression config.
|
|
20
|
+
*
|
|
21
|
+
* @param programId Program ID for the compressible program
|
|
22
|
+
* @param discriminator Instruction discriminator (8 bytes)
|
|
23
|
+
* @param authority Current config authority
|
|
24
|
+
* @param newCompressionDelay Optional new compression delay
|
|
25
|
+
* @param newRentRecipient Optional new rent recipient
|
|
26
|
+
* @param newAddressSpace Optional new address space array
|
|
27
|
+
* @param newUpdateAuthority Optional new update authority
|
|
28
|
+
* @returns TransactionInstruction
|
|
29
|
+
*/
|
|
30
|
+
export declare function createUpdateCompressionConfigInstruction(programId: PublicKey, discriminator: Uint8Array | number[], authority: PublicKey, newCompressionDelay?: number | null, newRentRecipient?: PublicKey | null, newAddressSpace?: PublicKey[] | null, newUpdateAuthority?: PublicKey | null): TransactionInstruction;
|
|
31
|
+
/**
|
|
32
|
+
* Create an instruction to compress a generic compressible account.
|
|
33
|
+
*
|
|
34
|
+
* @param programId Program ID for the compressible program
|
|
35
|
+
* @param discriminator Instruction discriminator (8 bytes)
|
|
36
|
+
* @param payer Fee payer
|
|
37
|
+
* @param pdaToCompress PDA to compress
|
|
38
|
+
* @param rentRecipient Rent recipient public key
|
|
39
|
+
* @param compressedAccountMeta Compressed account metadata
|
|
40
|
+
* @param validityProof Validity proof for compression
|
|
41
|
+
* @param systemAccounts Additional system accounts (optional)
|
|
42
|
+
* @returns TransactionInstruction
|
|
43
|
+
*/
|
|
44
|
+
export declare function createCompressAccountInstruction(programId: PublicKey, discriminator: Uint8Array | number[], payer: PublicKey, pdaToCompress: PublicKey, rentRecipient: PublicKey, compressedAccountMeta: import('../state/compressed-account').CompressedAccountMeta, validityProof: import('../state/types').ValidityProof, systemAccounts?: AccountMeta[]): TransactionInstruction;
|
|
45
|
+
/**
|
|
46
|
+
* Create an instruction to decompress one or more compressed accounts idempotently.
|
|
47
|
+
*
|
|
48
|
+
* @param programId Program ID for the compressible program
|
|
49
|
+
* @param discriminator Instruction discriminator (8 bytes)
|
|
50
|
+
* @param feePayer Fee payer
|
|
51
|
+
* @param rentPayer Rent payer
|
|
52
|
+
* @param solanaAccounts Array of PDA accounts to decompress
|
|
53
|
+
* @param compressedAccountsData Array of compressed account data
|
|
54
|
+
* @param bumps Array of PDA bumps
|
|
55
|
+
* @param validityProof Validity proof for decompression
|
|
56
|
+
* @param systemAccounts Additional system accounts (optional)
|
|
57
|
+
* @param coder Borsh schema for account data
|
|
58
|
+
* @returns TransactionInstruction
|
|
59
|
+
*/
|
|
60
|
+
export declare function createDecompressAccountsIdempotentInstruction<T = any>(programId: PublicKey, discriminator: Uint8Array | number[], feePayer: PublicKey, rentPayer: PublicKey, solanaAccounts: PublicKey[], compressedAccountsData: import('./types').CompressedAccountData<T>[], bumps: number[], validityProof: import('../state/types').ValidityProof, systemAccounts: AccountMeta[] | undefined, coder: (data: any) => Buffer): TransactionInstruction;
|
|
61
|
+
/**
|
|
62
|
+
* Instruction builders for compressible accounts, following Solana SDK patterns.
|
|
63
|
+
*/
|
|
64
|
+
export declare class CompressibleInstruction {
|
|
65
|
+
/**
|
|
66
|
+
* Create an instruction to initialize a compression config.
|
|
67
|
+
*
|
|
68
|
+
* @param programId Program ID for the compressible program
|
|
69
|
+
* @param discriminator Instruction discriminator (8 bytes)
|
|
70
|
+
* @param payer Fee payer
|
|
71
|
+
* @param authority Program upgrade authority
|
|
72
|
+
* @param compressionDelay Compression delay (in slots)
|
|
73
|
+
* @param rentRecipient Rent recipient public key
|
|
74
|
+
* @param addressSpace Array of address space public keys
|
|
75
|
+
* @param configBump Optional config bump (defaults to 0)
|
|
76
|
+
* @returns TransactionInstruction
|
|
77
|
+
*/
|
|
78
|
+
static initializeCompressionConfig(programId: PublicKey, discriminator: Uint8Array | number[], payer: PublicKey, authority: PublicKey, compressionDelay: number, rentRecipient: PublicKey, addressSpace: PublicKey[], configBump?: number | null): TransactionInstruction;
|
|
79
|
+
/**
|
|
80
|
+
* Create an instruction to update a compression config.
|
|
81
|
+
*
|
|
82
|
+
* @param programId Program ID for the compressible program
|
|
83
|
+
* @param discriminator Instruction discriminator (8 bytes)
|
|
84
|
+
* @param authority Current config authority
|
|
85
|
+
* @param newCompressionDelay Optional new compression delay
|
|
86
|
+
* @param newRentRecipient Optional new rent recipient
|
|
87
|
+
* @param newAddressSpace Optional new address space array
|
|
88
|
+
* @param newUpdateAuthority Optional new update authority
|
|
89
|
+
* @returns TransactionInstruction
|
|
90
|
+
*/
|
|
91
|
+
static updateCompressionConfig(programId: PublicKey, discriminator: Uint8Array | number[], authority: PublicKey, newCompressionDelay?: number | null, newRentRecipient?: PublicKey | null, newAddressSpace?: PublicKey[] | null, newUpdateAuthority?: PublicKey | null): TransactionInstruction;
|
|
92
|
+
/**
|
|
93
|
+
* Create an instruction to compress a generic compressible account.
|
|
94
|
+
*
|
|
95
|
+
* @param programId Program ID for the compressible program
|
|
96
|
+
* @param discriminator Instruction discriminator (8 bytes)
|
|
97
|
+
* @param payer Fee payer
|
|
98
|
+
* @param pdaToCompress PDA to compress
|
|
99
|
+
* @param rentRecipient Rent recipient public key
|
|
100
|
+
* @param compressedAccountMeta Compressed account metadata
|
|
101
|
+
* @param validityProof Validity proof for compression
|
|
102
|
+
* @param systemAccounts Additional system accounts (optional)
|
|
103
|
+
* @returns TransactionInstruction
|
|
104
|
+
*/
|
|
105
|
+
static compressAccount(programId: PublicKey, discriminator: Uint8Array | number[], payer: PublicKey, pdaToCompress: PublicKey, rentRecipient: PublicKey, compressedAccountMeta: import('../state/compressed-account').CompressedAccountMeta, validityProof: import('../state/types').ValidityProof, systemAccounts?: AccountMeta[]): TransactionInstruction;
|
|
106
|
+
/**
|
|
107
|
+
* Create an instruction to decompress one or more compressed accounts idempotently.
|
|
108
|
+
*
|
|
109
|
+
* @param programId Program ID for the compressible program
|
|
110
|
+
* @param discriminator Instruction discriminator (8 bytes)
|
|
111
|
+
* @param feePayer Fee payer
|
|
112
|
+
* @param rentPayer Rent payer
|
|
113
|
+
* @param solanaAccounts Array of PDA accounts to decompress
|
|
114
|
+
* @param compressedAccountsData Array of compressed account data
|
|
115
|
+
* @param bumps Array of PDA bumps
|
|
116
|
+
* @param validityProof Validity proof for decompression
|
|
117
|
+
* @param systemAccounts Additional system accounts (optional)
|
|
118
|
+
* @param dataSchema Borsh schema for account data
|
|
119
|
+
* @returns TransactionInstruction
|
|
120
|
+
*/
|
|
121
|
+
static decompressAccountsIdempotent<T = any>(programId: PublicKey, discriminator: Uint8Array | number[], feePayer: PublicKey, rentPayer: PublicKey, solanaAccounts: PublicKey[], compressedAccountsData: import('./types').CompressedAccountData<T>[], bumps: number[], validityProof: import('../state/types').ValidityProof, systemAccounts?: AccountMeta[], dataSchema?: any): TransactionInstruction;
|
|
122
|
+
/**
|
|
123
|
+
* Standard instruction discriminators for compressible instructions
|
|
124
|
+
*/
|
|
125
|
+
static readonly DISCRIMINATORS: {
|
|
126
|
+
readonly INITIALIZE_COMPRESSION_CONFIG: readonly [133, 228, 12, 169, 56, 76, 222, 61];
|
|
127
|
+
readonly UPDATE_COMPRESSION_CONFIG: readonly [135, 215, 243, 81, 163, 146, 33, 70];
|
|
128
|
+
readonly DECOMPRESS_ACCOUNTS_IDEMPOTENT: readonly [114, 67, 61, 123, 234, 31, 1, 112];
|
|
129
|
+
};
|
|
130
|
+
/**
|
|
131
|
+
* Derive the compression config PDA address
|
|
132
|
+
*
|
|
133
|
+
* @param programId Program ID for the compressible program
|
|
134
|
+
* @param configIndex Config index (defaults to 0)
|
|
135
|
+
* @returns [PDA address, bump seed]
|
|
136
|
+
*/
|
|
137
|
+
static deriveCompressionConfigAddress(programId: PublicKey, configIndex?: number): [PublicKey, number];
|
|
138
|
+
/**
|
|
139
|
+
* Get the program data account address and its raw data for a given program
|
|
140
|
+
*
|
|
141
|
+
* @param programId Program ID
|
|
142
|
+
* @param connection Solana connection
|
|
143
|
+
* @returns Program data address and account info
|
|
144
|
+
*/
|
|
145
|
+
static getProgramDataAccount(programId: PublicKey, connection: import('@solana/web3.js').Connection): Promise<{
|
|
146
|
+
programDataAddress: PublicKey;
|
|
147
|
+
programDataAccountInfo: import('@solana/web3.js').AccountInfo<Buffer>;
|
|
148
|
+
}>;
|
|
149
|
+
/**
|
|
150
|
+
* Check that the provided authority matches the program's upgrade authority
|
|
151
|
+
*
|
|
152
|
+
* @param programDataAccountInfo Program data account info
|
|
153
|
+
* @param providedAuthority Authority to validate
|
|
154
|
+
* @throws Error if authority doesn't match
|
|
155
|
+
*/
|
|
156
|
+
static checkProgramUpdateAuthority(programDataAccountInfo: import('@solana/web3.js').AccountInfo<Buffer>, providedAuthority: PublicKey): void;
|
|
157
|
+
/**
|
|
158
|
+
* Serialize instruction data for initializeCompressionConfig using Borsh
|
|
159
|
+
*
|
|
160
|
+
* @param compressionDelay Compression delay (in slots)
|
|
161
|
+
* @param rentRecipient Rent recipient public key
|
|
162
|
+
* @param addressSpace Array of address space public keys
|
|
163
|
+
* @param configBump Optional config bump
|
|
164
|
+
* @returns Serialized instruction data with discriminator
|
|
165
|
+
*/
|
|
166
|
+
static serializeInitializeCompressionConfigData(compressionDelay: number, rentRecipient: PublicKey, addressSpace: PublicKey[], configBump: number | null): Buffer;
|
|
167
|
+
/**
|
|
168
|
+
* Convert a compressed account to the format expected by instruction builders
|
|
169
|
+
*
|
|
170
|
+
* @param compressedAccount Compressed account from state
|
|
171
|
+
* @param data Program-specific account data
|
|
172
|
+
* @param seeds PDA seeds (without bump)
|
|
173
|
+
* @param outputStateTreeIndex Output state tree index
|
|
174
|
+
* @returns Compressed account data for instructions
|
|
175
|
+
*/
|
|
176
|
+
static createCompressedAccountData<T>(compressedAccount: CompressedAccount, data: T, seeds: Uint8Array[], outputStateTreeIndex: number): CompressedAccountData<T>;
|
|
177
|
+
}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import * as borsh from '@coral-xyz/borsh';
|
|
2
|
+
import { ValidityProof } from '../state/types';
|
|
3
|
+
import { PackedStateTreeInfo, CompressedAccountMeta } from '../state/compressed-account';
|
|
4
|
+
import { CompressionConfigIxData, UpdateCompressionConfigData, GenericCompressAccountInstruction, CompressedAccountData, DecompressMultipleAccountsIdempotentData } from './types';
|
|
5
|
+
/**
|
|
6
|
+
* Borsh schema for initializeCompressionConfig instruction data
|
|
7
|
+
* Note: This is also available from '@lightprotocol/stateless.js' main exports
|
|
8
|
+
*/
|
|
9
|
+
export declare const InitializeCompressionConfigSchema: borsh.Layout<CompressionConfigIxData>;
|
|
10
|
+
/**
|
|
11
|
+
* Borsh schema for updateCompressionConfig instruction data
|
|
12
|
+
*/
|
|
13
|
+
export declare const UpdateCompressionConfigSchema: borsh.Layout<UpdateCompressionConfigData>;
|
|
14
|
+
/**
|
|
15
|
+
* Borsh schema for ValidityProof
|
|
16
|
+
*/
|
|
17
|
+
export declare const ValidityProofSchema: borsh.Layout<ValidityProof>;
|
|
18
|
+
/**
|
|
19
|
+
* Borsh schema for PackedStateTreeInfo
|
|
20
|
+
*/
|
|
21
|
+
export declare const PackedStateTreeInfoSchema: borsh.Layout<PackedStateTreeInfo>;
|
|
22
|
+
/**
|
|
23
|
+
* Borsh schema for CompressedAccountMeta
|
|
24
|
+
*/
|
|
25
|
+
export declare const CompressedAccountMetaSchema: borsh.Layout<CompressedAccountMeta>;
|
|
26
|
+
/**
|
|
27
|
+
* Borsh schema for GenericCompressAccountInstruction
|
|
28
|
+
*/
|
|
29
|
+
export declare const GenericCompressAccountInstructionSchema: borsh.Layout<GenericCompressAccountInstruction>;
|
|
30
|
+
/**
|
|
31
|
+
* Helper function to create borsh schema for CompressedAccountData
|
|
32
|
+
* This is generic to work with any data type T
|
|
33
|
+
*/
|
|
34
|
+
export declare function createCompressedAccountDataSchema<T>(dataSchema: borsh.Layout<T>): borsh.Layout<CompressedAccountData<T>>;
|
|
35
|
+
/**
|
|
36
|
+
* Helper function to create borsh schema for DecompressMultipleAccountsIdempotentData
|
|
37
|
+
* This is generic to work with any data type T
|
|
38
|
+
*/
|
|
39
|
+
export declare function createDecompressMultipleAccountsIdempotentDataSchema<T>(dataSchema: borsh.Layout<T>): borsh.Layout<DecompressMultipleAccountsIdempotentData<T>>;
|
|
40
|
+
/**
|
|
41
|
+
* Serialize instruction data with custom discriminator
|
|
42
|
+
*/
|
|
43
|
+
export declare function serializeInstructionData<T>(schema: borsh.Layout<T>, data: T, discriminator: Uint8Array | number[]): Buffer;
|
|
44
|
+
/**
|
|
45
|
+
* Serialize instruction data for initializeCompressionConfig using Borsh
|
|
46
|
+
*/
|
|
47
|
+
export declare function serializeInitializeCompressionConfigData(compressionDelay: number, rentRecipient: import('@solana/web3.js').PublicKey, addressSpace: import('@solana/web3.js').PublicKey[], configBump: number | null): Buffer;
|
|
@@ -0,0 +1,112 @@
|
|
|
1
|
+
import { PublicKey, AccountMeta } from '@solana/web3.js';
|
|
2
|
+
import { ValidityProof } from '../state/types';
|
|
3
|
+
import { CompressedAccountMeta } from '../state/compressed-account';
|
|
4
|
+
/**
|
|
5
|
+
* Standard instruction discriminators for compressible instructions
|
|
6
|
+
* These match the Rust implementation discriminators
|
|
7
|
+
*/
|
|
8
|
+
export declare const COMPRESSIBLE_DISCRIMINATORS: {
|
|
9
|
+
readonly INITIALIZE_COMPRESSION_CONFIG: readonly [133, 228, 12, 169, 56, 76, 222, 61];
|
|
10
|
+
readonly UPDATE_COMPRESSION_CONFIG: readonly [135, 215, 243, 81, 163, 146, 33, 70];
|
|
11
|
+
readonly DECOMPRESS_ACCOUNTS_IDEMPOTENT: readonly [114, 67, 61, 123, 234, 31, 1, 112];
|
|
12
|
+
};
|
|
13
|
+
/**
|
|
14
|
+
* Generic compressed account data structure for decompress operations
|
|
15
|
+
* This is generic over the account variant type, allowing programs to use their specific enums
|
|
16
|
+
*/
|
|
17
|
+
export type CompressedAccountData<T = any> = {
|
|
18
|
+
/** The compressed account metadata containing tree info, address, and output index */
|
|
19
|
+
meta: CompressedAccountMeta;
|
|
20
|
+
/** Program-specific account variant enum */
|
|
21
|
+
data: T;
|
|
22
|
+
/** PDA seeds (without bump) used to derive the PDA address */
|
|
23
|
+
seeds: Uint8Array[];
|
|
24
|
+
};
|
|
25
|
+
/**
|
|
26
|
+
* Instruction data structure for decompress_accounts_idempotent
|
|
27
|
+
* This matches the exact format expected by Anchor programs
|
|
28
|
+
*/
|
|
29
|
+
export type DecompressMultipleAccountsIdempotentData<T = any> = {
|
|
30
|
+
proof: ValidityProof;
|
|
31
|
+
compressedAccounts: CompressedAccountData<T>[];
|
|
32
|
+
bumps: number[];
|
|
33
|
+
systemAccountsOffset: number;
|
|
34
|
+
};
|
|
35
|
+
/**
|
|
36
|
+
* Instruction data for update compression config
|
|
37
|
+
*/
|
|
38
|
+
export type UpdateCompressionConfigData = {
|
|
39
|
+
newCompressionDelay: number | null;
|
|
40
|
+
newRentRecipient: PublicKey | null;
|
|
41
|
+
newAddressSpace: PublicKey[] | null;
|
|
42
|
+
newUpdateAuthority: PublicKey | null;
|
|
43
|
+
};
|
|
44
|
+
/**
|
|
45
|
+
* Generic instruction data for compress account
|
|
46
|
+
* This matches the expected format for compress account instructions
|
|
47
|
+
*/
|
|
48
|
+
export type GenericCompressAccountInstruction = {
|
|
49
|
+
proof: ValidityProof;
|
|
50
|
+
compressedAccountMeta: CompressedAccountMeta;
|
|
51
|
+
};
|
|
52
|
+
/**
|
|
53
|
+
* Existing CompressionConfigIxData type (re-exported for compatibility)
|
|
54
|
+
*/
|
|
55
|
+
export type CompressionConfigIxData = {
|
|
56
|
+
compressionDelay: number;
|
|
57
|
+
rentRecipient: PublicKey;
|
|
58
|
+
addressSpace: PublicKey[];
|
|
59
|
+
configBump: number | null;
|
|
60
|
+
};
|
|
61
|
+
/**
|
|
62
|
+
* Common instruction builder parameters
|
|
63
|
+
*/
|
|
64
|
+
export type InstructionBuilderParams = {
|
|
65
|
+
programId: PublicKey;
|
|
66
|
+
discriminator: Uint8Array | number[];
|
|
67
|
+
};
|
|
68
|
+
/**
|
|
69
|
+
* Initialize compression config instruction parameters
|
|
70
|
+
*/
|
|
71
|
+
export type InitializeCompressionConfigParams = InstructionBuilderParams & {
|
|
72
|
+
payer: PublicKey;
|
|
73
|
+
authority: PublicKey;
|
|
74
|
+
compressionDelay: number;
|
|
75
|
+
rentRecipient: PublicKey;
|
|
76
|
+
addressSpace: PublicKey[];
|
|
77
|
+
configBump?: number | null;
|
|
78
|
+
};
|
|
79
|
+
/**
|
|
80
|
+
* Update compression config instruction parameters
|
|
81
|
+
*/
|
|
82
|
+
export type UpdateCompressionConfigParams = InstructionBuilderParams & {
|
|
83
|
+
authority: PublicKey;
|
|
84
|
+
newCompressionDelay?: number | null;
|
|
85
|
+
newRentRecipient?: PublicKey | null;
|
|
86
|
+
newAddressSpace?: PublicKey[] | null;
|
|
87
|
+
newUpdateAuthority?: PublicKey | null;
|
|
88
|
+
};
|
|
89
|
+
/**
|
|
90
|
+
* Compress account instruction parameters
|
|
91
|
+
*/
|
|
92
|
+
export type CompressAccountParams = InstructionBuilderParams & {
|
|
93
|
+
payer: PublicKey;
|
|
94
|
+
pdaToCompress: PublicKey;
|
|
95
|
+
rentRecipient: PublicKey;
|
|
96
|
+
compressedAccountMeta: CompressedAccountMeta;
|
|
97
|
+
validityProof: ValidityProof;
|
|
98
|
+
systemAccounts?: AccountMeta[];
|
|
99
|
+
};
|
|
100
|
+
/**
|
|
101
|
+
* Decompress accounts idempotent instruction parameters
|
|
102
|
+
*/
|
|
103
|
+
export type DecompressAccountsIdempotentParams<T = any> = InstructionBuilderParams & {
|
|
104
|
+
feePayer: PublicKey;
|
|
105
|
+
rentPayer: PublicKey;
|
|
106
|
+
solanaAccounts: PublicKey[];
|
|
107
|
+
compressedAccountsData: CompressedAccountData<T>[];
|
|
108
|
+
bumps: number[];
|
|
109
|
+
validityProof: ValidityProof;
|
|
110
|
+
systemAccounts?: AccountMeta[];
|
|
111
|
+
dataSchema?: any;
|
|
112
|
+
};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { Connection, PublicKey, AccountInfo } from '@solana/web3.js';
|
|
2
|
+
/**
|
|
3
|
+
* Derive the compression config PDA address
|
|
4
|
+
*/
|
|
5
|
+
export declare function deriveCompressionConfigAddress(programId: PublicKey, configIndex?: number): [PublicKey, number];
|
|
6
|
+
/**
|
|
7
|
+
* Get the program data account address and its raw data for a given program.
|
|
8
|
+
*/
|
|
9
|
+
export declare function getProgramDataAccount(programId: PublicKey, connection: Connection): Promise<{
|
|
10
|
+
programDataAddress: PublicKey;
|
|
11
|
+
programDataAccountInfo: AccountInfo<Buffer>;
|
|
12
|
+
}>;
|
|
13
|
+
/**
|
|
14
|
+
* Check that the provided authority matches the program's upgrade authority.
|
|
15
|
+
*/
|
|
16
|
+
export declare function checkProgramUpdateAuthority(programDataAccountInfo: AccountInfo<Buffer>, providedAuthority: PublicKey): void;
|
|
@@ -1,15 +1,36 @@
|
|
|
1
1
|
import BN from 'bn.js';
|
|
2
2
|
import { Buffer } from 'buffer';
|
|
3
3
|
import { ConfirmOptions, PublicKey } from '@solana/web3.js';
|
|
4
|
-
import {
|
|
4
|
+
import { TreeInfo, TreeType } from './state/types';
|
|
5
|
+
export declare enum VERSION {
|
|
6
|
+
V1 = "V1",
|
|
7
|
+
V2 = "V2"
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
/**
|
|
11
|
+
* @internal
|
|
12
|
+
* Feature flags. Only use if you know what you are doing.
|
|
13
|
+
*/
|
|
14
|
+
export declare const featureFlags: {
|
|
15
|
+
version: VERSION;
|
|
16
|
+
isV2: () => boolean;
|
|
17
|
+
};
|
|
18
|
+
/**
|
|
19
|
+
* Returns the correct endpoint name for the current API version. E.g.
|
|
20
|
+
* versionedEndpoint('getCompressedAccount') -> 'getCompressedAccount' (V1)
|
|
21
|
+
* or 'getCompressedAccountV2' (V2)
|
|
22
|
+
*/
|
|
23
|
+
export declare const versionedEndpoint: (base: string) => string;
|
|
5
24
|
export declare const FIELD_SIZE: BN;
|
|
6
25
|
export declare const HIGHEST_ADDRESS_PLUS_ONE: BN;
|
|
7
26
|
export declare const COMPUTE_BUDGET_PATTERN: number[];
|
|
8
|
-
export declare const INVOKE_DISCRIMINATOR: Buffer
|
|
9
|
-
export declare const INVOKE_CPI_DISCRIMINATOR: Buffer
|
|
10
|
-
export declare const
|
|
27
|
+
export declare const INVOKE_DISCRIMINATOR: Buffer<ArrayBuffer>;
|
|
28
|
+
export declare const INVOKE_CPI_DISCRIMINATOR: Buffer<ArrayBuffer>;
|
|
29
|
+
export declare const INVOKE_CPI_WITH_READ_ONLY_DISCRIMINATOR: Buffer<ArrayBuffer>;
|
|
30
|
+
export declare const INVOKE_CPI_WITH_ACCOUNT_INFO_DISCRIMINATOR: Buffer<ArrayBuffer>;
|
|
31
|
+
export declare const INSERT_INTO_QUEUES_DISCRIMINATOR: Buffer<ArrayBuffer>;
|
|
11
32
|
export declare const noopProgram = "noopb9bkMVfRPU8AsbpTUg8AQkHtKwMYZiFUjNRtMmV";
|
|
12
|
-
export declare const
|
|
33
|
+
export declare const lightSystemProgram = "SySTEM1eSU2p4BGQfQpimFEWWSC1XDFeun3Nqzz3rT7";
|
|
13
34
|
export declare const accountCompressionProgram = "compr6CUsB5m2jS4Y3831ztGSTnDpnKJTKS95d64XVq";
|
|
14
35
|
export declare const getRegisteredProgramPda: () => PublicKey;
|
|
15
36
|
export declare const getAccountCompressionAuthority: () => PublicKey;
|
|
@@ -39,7 +60,7 @@ export declare const isLocalTest: (url: string) => boolean;
|
|
|
39
60
|
/**
|
|
40
61
|
* @internal
|
|
41
62
|
*/
|
|
42
|
-
export declare const
|
|
63
|
+
export declare const localTestActiveStateTreeInfos: () => TreeInfo[];
|
|
43
64
|
export declare const getDefaultAddressTreeInfo: () => {
|
|
44
65
|
tree: PublicKey;
|
|
45
66
|
queue: PublicKey;
|
|
@@ -77,9 +98,13 @@ export declare const cpiContextPubkey = "cpi1uHzrEhBG733DoEJNgHCyRS3XmmyVNZx5fon
|
|
|
77
98
|
export declare const merkletreePubkey = "smt1NamzXdq4AMqS2fS2F1i5KTYPZRhoHgWx38d8WsT";
|
|
78
99
|
export declare const addressTree = "amt1Ayt45jfbdw5YSo7iz6WZxUmnZsQTYXy82hVwyC2";
|
|
79
100
|
export declare const addressQueue = "aq1S9z4reTSQAdgWHGD2zDaS39sjGrAxbR31vxJ2F4F";
|
|
101
|
+
export declare const addressTreeV2: PublicKey;
|
|
80
102
|
export declare const merkleTree2Pubkey = "smt2rJAFdyJJupwMKAqTNAJwvjhmiZ4JYGZmbVRw1Ho";
|
|
81
103
|
export declare const nullifierQueue2Pubkey = "nfq2hgS7NYemXsFaFUCe3EMXSDSfnZnAe27jC6aPP1X";
|
|
82
104
|
export declare const cpiContext2Pubkey = "cpi2cdhkH5roePvcudTgUL8ppEBfTay1desGh8G8QxK";
|
|
105
|
+
export declare const batchMerkleTree = "HLKs5NJ8FXkJg8BrzJt56adFYYuwg5etzDtBbQYTsixu";
|
|
106
|
+
export declare const batchQueue = "6L7SzhYB3anwEQ9cphpJ1U7Scwj57bx2xueReg7R9cKU";
|
|
107
|
+
export declare const batchCpiContext = "7Hp52chxaew8bW1ApR4fck2bh6Y8qA1pu3qwH6N9zaLj";
|
|
83
108
|
export declare const confirmConfig: ConfirmOptions;
|
|
84
109
|
export declare const DEFAULT_MERKLE_TREE_HEIGHT = 26;
|
|
85
110
|
export declare const DEFAULT_MERKLE_TREE_ROOTS = 2800;
|