@solana/token-acl-gate-sdk 0.2.0 → 0.3.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/dist/src/index.js +267 -75
- package/dist/src/index.js.map +1 -1
- package/dist/src/index.mjs +248 -75
- package/dist/src/index.mjs.map +1 -1
- package/dist/types/generated/accounts/listConfig.d.ts +2 -1
- package/dist/types/generated/accounts/listConfig.d.ts.map +1 -1
- package/dist/types/generated/accounts/walletEntry.d.ts +2 -1
- package/dist/types/generated/accounts/walletEntry.d.ts.map +1 -1
- package/dist/types/generated/instructions/addWallet.d.ts +1 -12
- package/dist/types/generated/instructions/addWallet.d.ts.map +1 -1
- package/dist/types/generated/instructions/canFreezePermissionless.d.ts +52 -0
- package/dist/types/generated/instructions/canFreezePermissionless.d.ts.map +1 -0
- package/dist/types/generated/instructions/canThawPermissionless.d.ts +57 -0
- package/dist/types/generated/instructions/canThawPermissionless.d.ts.map +1 -0
- package/dist/types/generated/instructions/createList.d.ts +1 -12
- package/dist/types/generated/instructions/createList.d.ts.map +1 -1
- package/dist/types/generated/instructions/deleteList.d.ts +1 -1
- package/dist/types/generated/instructions/deleteList.d.ts.map +1 -1
- package/dist/types/generated/instructions/index.d.ts +3 -0
- package/dist/types/generated/instructions/index.d.ts.map +1 -1
- package/dist/types/generated/instructions/removeWallet.d.ts +1 -1
- package/dist/types/generated/instructions/removeWallet.d.ts.map +1 -1
- package/dist/types/generated/instructions/setupExtraMetas.d.ts +6 -2
- package/dist/types/generated/instructions/setupExtraMetas.d.ts.map +1 -1
- package/dist/types/generated/instructions/setupFreezeExtraMetas.d.ts +52 -0
- package/dist/types/generated/instructions/setupFreezeExtraMetas.d.ts.map +1 -0
- package/dist/types/generated/programs/tokenAclGateProgram.d.ts +12 -3
- package/dist/types/generated/programs/tokenAclGateProgram.d.ts.map +1 -1
- package/dist/types/generated/types/mode.d.ts +1 -1
- package/dist/types/generated/types/mode.d.ts.map +1 -1
- package/package.json +2 -2
package/dist/src/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/generated/pdas/listConfig.ts","../../src/generated/pdas/walletEntry.ts","../../src/generated/accounts/listConfig.ts","../../src/generated/accounts/walletEntry.ts","../../src/generated/programs/tokenAclGateProgram.ts","../../src/generated/shared/index.ts","../../src/generated/instructions/addWallet.ts","../../src/generated/types/mode.ts","../../src/generated/instructions/createList.ts","../../src/generated/instructions/deleteList.ts","../../src/generated/instructions/removeWallet.ts","../../src/generated/instructions/setupExtraMetas.ts"],"names":["getProgramDerivedAddress","getUtf8Encoder","getAddressEncoder","getU8Encoder","transformEncoder","getStructEncoder","getU64Encoder","getStructDecoder","getU8Decoder","getAddressDecoder","getU64Decoder","combineCodec","decodeAccount","assertAccountExists","fetchEncodedAccount","assertAccountsExist","fetchEncodedAccounts","TokenAclGateProgramAccount","containsBytes","TokenAclGateProgramInstruction","AccountRole","upgradeRoleToSigner","kitIsTransactionSigner","Mode","getEnumEncoder","getEnumDecoder"],"mappings":";;;;;AAqBA,eAAsB,iBAAA,CACpB,KAAA,EACA,MAAA,GAAmD,EAAC,EACpB;AAChC,EAAA,MAAM;AAAA,IACJ,cAAA,GAAiB;AAAA,GACnB,GAAI,MAAA;AACJ,EAAA,OAAO,MAAMA,4BAAA,CAAyB;AAAA,IACpC,cAAA;AAAA,IACA,KAAA,EAAO;AAAA,MACLC,kBAAA,EAAe,CAAE,MAAA,CAAO,aAAa,CAAA;AAAA,MACrCC,qBAAA,EAAkB,CAAE,MAAA,CAAO,KAAA,CAAM,SAAS,CAAA;AAAA,MAC1CA,qBAAA,EAAkB,CAAE,MAAA,CAAO,KAAA,CAAM,IAAI;AAAA;AACvC,GACD,CAAA;AACH;ACfA,eAAsB,kBAAA,CACpB,KAAA,EACA,MAAA,GAAmD,EAAC,EACpB;AAChC,EAAA,MAAM;AAAA,IACJ,cAAA,GAAiB;AAAA,GACnB,GAAI,MAAA;AACJ,EAAA,OAAO,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CAId,WAAA,EAG2D;AAC3D,EAAA,IAAI,WAAA,CAAY,QAAA,CAAS,MAAA,GAAS,CAAA,EAAG;AAEnC,IAAA,MAAM,IAAI,MAAM,qBAAqB,CAAA;AAAA,EACvC;AACA,EAAA,IAAI,YAAA,GAAe,CAAA;AACnB,EAAA,MAAM,iBAAiB,MAAM;AAC3B,IAAA,MAAM,WAAA,GAAe,WAAA,CAAY,QAAA,CAA2B,YAAY,CAAA;AACxE,IAAA,YAAA,IAAgB,CAAA;AAChB,IAAA,OAAO,WAAA;AAAA,EACT,CAAA;AACA,EAAA,OAAO;AAAA,IACL,gBAAgB,WAAA,CAAY,cAAA;AAAA,IAC5B,QAAA,EAAU;AAAA,MACR,WAAW,cAAA,EAAe;AAAA,MAC1B,OAAO,cAAA,EAAe;AAAA,MACtB,oBAAoB,cAAA,EAAe;AAAA,MACnC,MAAM,cAAA,EAAe;AAAA,MACrB,YAAY,cAAA,EAAe;AAAA,MAC3B,eAAe,cAAA;AAAe,KAChC;AAAA,IACA,IAAA,EAAM,wCAAA,EAAyC,CAAE,MAAA,CAAO,YAAY,IAAI;AAAA,GAC1E;AACF","file":"index.js","sourcesContent":["/**\n * This code was AUTOGENERATED using the Codama library.\n * Please DO NOT EDIT THIS FILE, instead use visitors\n * to add features, then rerun Codama to update it.\n *\n * @see https://github.com/codama-idl/codama\n */\n\nimport {\n getAddressEncoder,\n getProgramDerivedAddress,\n getUtf8Encoder,\n type Address,\n type ProgramDerivedAddress,\n} from '@solana/kit';\n\nexport type ListConfigSeeds = {\n authority: Address;\n seed: Address;\n};\n\nexport async function findListConfigPda(\n seeds: ListConfigSeeds,\n config: { programAddress?: Address | undefined } = {}\n): Promise<ProgramDerivedAddress> {\n const {\n programAddress = 'GATEzzqxhJnsWF6vHRsgtixxSB8PaQdcqGEVTEHWiULz' as Address<'GATEzzqxhJnsWF6vHRsgtixxSB8PaQdcqGEVTEHWiULz'>,\n } = config;\n return await getProgramDerivedAddress({\n programAddress,\n seeds: [\n getUtf8Encoder().encode('list_config'),\n getAddressEncoder().encode(seeds.authority),\n getAddressEncoder().encode(seeds.seed),\n ],\n });\n}\n","/**\n * This code was AUTOGENERATED using the Codama library.\n * Please DO NOT EDIT THIS FILE, instead use visitors\n * to add features, then rerun Codama to update it.\n *\n * @see https://github.com/codama-idl/codama\n */\n\nimport {\n getAddressEncoder,\n getProgramDerivedAddress,\n getUtf8Encoder,\n type Address,\n type ProgramDerivedAddress,\n} from '@solana/kit';\n\nexport type WalletEntrySeeds = {\n listConfig: Address;\n wallet: Address;\n};\n\nexport async function findWalletEntryPda(\n seeds: WalletEntrySeeds,\n config: { programAddress?: Address | undefined } = {}\n): Promise<ProgramDerivedAddress> {\n const {\n programAddress = 'GATEzzqxhJnsWF6vHRsgtixxSB8PaQdcqGEVTEHWiULz' as Address<'GATEzzqxhJnsWF6vHRsgtixxSB8PaQdcqGEVTEHWiULz'>,\n } = config;\n return await getProgramDerivedAddress({\n programAddress,\n seeds: [\n getUtf8Encoder().encode('wallet_entry'),\n getAddressEncoder().encode(seeds.listConfig),\n getAddressEncoder().encode(seeds.wallet),\n ],\n });\n}\n","/**\n * This code was AUTOGENERATED using the Codama library.\n * Please DO NOT EDIT THIS FILE, instead use visitors\n * to add features, then rerun Codama to update it.\n *\n * @see https://github.com/codama-idl/codama\n */\n\nimport {\n assertAccountExists,\n assertAccountsExist,\n combineCodec,\n decodeAccount,\n fetchEncodedAccount,\n fetchEncodedAccounts,\n getAddressDecoder,\n getAddressEncoder,\n getStructDecoder,\n getStructEncoder,\n getU64Decoder,\n getU64Encoder,\n getU8Decoder,\n getU8Encoder,\n transformEncoder,\n type Account,\n type Address,\n type EncodedAccount,\n type FetchAccountConfig,\n type FetchAccountsConfig,\n type FixedSizeCodec,\n type FixedSizeDecoder,\n type FixedSizeEncoder,\n type MaybeAccount,\n type MaybeEncodedAccount,\n} from '@solana/kit';\nimport { findListConfigPda, ListConfigSeeds } from '../pdas';\n\nexport const LIST_CONFIG_DISCRIMINATOR = 1;\n\nexport function getListConfigDiscriminatorBytes() {\n return getU8Encoder().encode(LIST_CONFIG_DISCRIMINATOR);\n}\n\nexport type ListConfig = {\n discriminator: number;\n authority: Address;\n seed: Address;\n mode: number;\n walletsCount: bigint;\n};\n\nexport type ListConfigArgs = {\n authority: Address;\n seed: Address;\n mode: number;\n walletsCount: number | bigint;\n};\n\nexport function getListConfigEncoder(): FixedSizeEncoder<ListConfigArgs> {\n return transformEncoder(\n getStructEncoder([\n ['discriminator', getU8Encoder()],\n ['authority', getAddressEncoder()],\n ['seed', getAddressEncoder()],\n ['mode', getU8Encoder()],\n ['walletsCount', getU64Encoder()],\n ]),\n (value) => ({ ...value, discriminator: LIST_CONFIG_DISCRIMINATOR })\n );\n}\n\nexport function getListConfigDecoder(): FixedSizeDecoder<ListConfig> {\n return getStructDecoder([\n ['discriminator', getU8Decoder()],\n ['authority', getAddressDecoder()],\n ['seed', getAddressDecoder()],\n ['mode', getU8Decoder()],\n ['walletsCount', getU64Decoder()],\n ]);\n}\n\nexport function getListConfigCodec(): FixedSizeCodec<\n ListConfigArgs,\n ListConfig\n> {\n return combineCodec(getListConfigEncoder(), getListConfigDecoder());\n}\n\nexport function decodeListConfig<TAddress extends string = string>(\n encodedAccount: EncodedAccount<TAddress>\n): Account<ListConfig, TAddress>;\nexport function decodeListConfig<TAddress extends string = string>(\n encodedAccount: MaybeEncodedAccount<TAddress>\n): MaybeAccount<ListConfig, TAddress>;\nexport function decodeListConfig<TAddress extends string = string>(\n encodedAccount: EncodedAccount<TAddress> | MaybeEncodedAccount<TAddress>\n): Account<ListConfig, TAddress> | MaybeAccount<ListConfig, TAddress> {\n return decodeAccount(\n encodedAccount as MaybeEncodedAccount<TAddress>,\n getListConfigDecoder()\n );\n}\n\nexport async function fetchListConfig<TAddress extends string = string>(\n rpc: Parameters<typeof fetchEncodedAccount>[0],\n address: Address<TAddress>,\n config?: FetchAccountConfig\n): Promise<Account<ListConfig, TAddress>> {\n const maybeAccount = await fetchMaybeListConfig(rpc, address, config);\n assertAccountExists(maybeAccount);\n return maybeAccount;\n}\n\nexport async function fetchMaybeListConfig<TAddress extends string = string>(\n rpc: Parameters<typeof fetchEncodedAccount>[0],\n address: Address<TAddress>,\n config?: FetchAccountConfig\n): Promise<MaybeAccount<ListConfig, TAddress>> {\n const maybeAccount = await fetchEncodedAccount(rpc, address, config);\n return decodeListConfig(maybeAccount);\n}\n\nexport async function fetchAllListConfig(\n rpc: Parameters<typeof fetchEncodedAccounts>[0],\n addresses: Array<Address>,\n config?: FetchAccountsConfig\n): Promise<Account<ListConfig>[]> {\n const maybeAccounts = await fetchAllMaybeListConfig(rpc, addresses, config);\n assertAccountsExist(maybeAccounts);\n return maybeAccounts;\n}\n\nexport async function fetchAllMaybeListConfig(\n rpc: Parameters<typeof fetchEncodedAccounts>[0],\n addresses: Array<Address>,\n config?: FetchAccountsConfig\n): Promise<MaybeAccount<ListConfig>[]> {\n const maybeAccounts = await fetchEncodedAccounts(rpc, addresses, config);\n return maybeAccounts.map((maybeAccount) => decodeListConfig(maybeAccount));\n}\n\nexport function getListConfigSize(): number {\n return 74;\n}\n\nexport async function fetchListConfigFromSeeds(\n rpc: Parameters<typeof fetchEncodedAccount>[0],\n seeds: ListConfigSeeds,\n config: FetchAccountConfig & { programAddress?: Address } = {}\n): Promise<Account<ListConfig>> {\n const maybeAccount = await fetchMaybeListConfigFromSeeds(rpc, seeds, config);\n assertAccountExists(maybeAccount);\n return maybeAccount;\n}\n\nexport async function fetchMaybeListConfigFromSeeds(\n rpc: Parameters<typeof fetchEncodedAccount>[0],\n seeds: ListConfigSeeds,\n config: FetchAccountConfig & { programAddress?: Address } = {}\n): Promise<MaybeAccount<ListConfig>> {\n const { programAddress, ...fetchConfig } = config;\n const [address] = await findListConfigPda(seeds, { programAddress });\n return await fetchMaybeListConfig(rpc, address, fetchConfig);\n}\n","/**\n * This code was AUTOGENERATED using the Codama library.\n * Please DO NOT EDIT THIS FILE, instead use visitors\n * to add features, then rerun Codama to update it.\n *\n * @see https://github.com/codama-idl/codama\n */\n\nimport {\n assertAccountExists,\n assertAccountsExist,\n combineCodec,\n decodeAccount,\n fetchEncodedAccount,\n fetchEncodedAccounts,\n getAddressDecoder,\n getAddressEncoder,\n getStructDecoder,\n getStructEncoder,\n getU8Decoder,\n getU8Encoder,\n transformEncoder,\n type Account,\n type Address,\n type EncodedAccount,\n type FetchAccountConfig,\n type FetchAccountsConfig,\n type FixedSizeCodec,\n type FixedSizeDecoder,\n type FixedSizeEncoder,\n type MaybeAccount,\n type MaybeEncodedAccount,\n} from '@solana/kit';\nimport { findWalletEntryPda, WalletEntrySeeds } from '../pdas';\n\nexport const WALLET_ENTRY_DISCRIMINATOR = 2;\n\nexport function getWalletEntryDiscriminatorBytes() {\n return getU8Encoder().encode(WALLET_ENTRY_DISCRIMINATOR);\n}\n\nexport type WalletEntry = {\n discriminator: number;\n walletAddress: Address;\n listConfig: Address;\n};\n\nexport type WalletEntryArgs = { walletAddress: Address; listConfig: Address };\n\nexport function getWalletEntryEncoder(): FixedSizeEncoder<WalletEntryArgs> {\n return transformEncoder(\n getStructEncoder([\n ['discriminator', getU8Encoder()],\n ['walletAddress', getAddressEncoder()],\n ['listConfig', getAddressEncoder()],\n ]),\n (value) => ({ ...value, discriminator: WALLET_ENTRY_DISCRIMINATOR })\n );\n}\n\nexport function getWalletEntryDecoder(): FixedSizeDecoder<WalletEntry> {\n return getStructDecoder([\n ['discriminator', getU8Decoder()],\n ['walletAddress', getAddressDecoder()],\n ['listConfig', getAddressDecoder()],\n ]);\n}\n\nexport function getWalletEntryCodec(): FixedSizeCodec<\n WalletEntryArgs,\n WalletEntry\n> {\n return combineCodec(getWalletEntryEncoder(), getWalletEntryDecoder());\n}\n\nexport function decodeWalletEntry<TAddress extends string = string>(\n encodedAccount: EncodedAccount<TAddress>\n): Account<WalletEntry, TAddress>;\nexport function decodeWalletEntry<TAddress extends string = string>(\n encodedAccount: MaybeEncodedAccount<TAddress>\n): MaybeAccount<WalletEntry, TAddress>;\nexport function decodeWalletEntry<TAddress extends string = string>(\n encodedAccount: EncodedAccount<TAddress> | MaybeEncodedAccount<TAddress>\n): Account<WalletEntry, TAddress> | MaybeAccount<WalletEntry, TAddress> {\n return decodeAccount(\n encodedAccount as MaybeEncodedAccount<TAddress>,\n getWalletEntryDecoder()\n );\n}\n\nexport async function fetchWalletEntry<TAddress extends string = string>(\n rpc: Parameters<typeof fetchEncodedAccount>[0],\n address: Address<TAddress>,\n config?: FetchAccountConfig\n): Promise<Account<WalletEntry, TAddress>> {\n const maybeAccount = await fetchMaybeWalletEntry(rpc, address, config);\n assertAccountExists(maybeAccount);\n return maybeAccount;\n}\n\nexport async function fetchMaybeWalletEntry<TAddress extends string = string>(\n rpc: Parameters<typeof fetchEncodedAccount>[0],\n address: Address<TAddress>,\n config?: FetchAccountConfig\n): Promise<MaybeAccount<WalletEntry, TAddress>> {\n const maybeAccount = await fetchEncodedAccount(rpc, address, config);\n return decodeWalletEntry(maybeAccount);\n}\n\nexport async function fetchAllWalletEntry(\n rpc: Parameters<typeof fetchEncodedAccounts>[0],\n addresses: Array<Address>,\n config?: FetchAccountsConfig\n): Promise<Account<WalletEntry>[]> {\n const maybeAccounts = await fetchAllMaybeWalletEntry(rpc, addresses, config);\n assertAccountsExist(maybeAccounts);\n return maybeAccounts;\n}\n\nexport async function fetchAllMaybeWalletEntry(\n rpc: Parameters<typeof fetchEncodedAccounts>[0],\n addresses: Array<Address>,\n config?: FetchAccountsConfig\n): Promise<MaybeAccount<WalletEntry>[]> {\n const maybeAccounts = await fetchEncodedAccounts(rpc, addresses, config);\n return maybeAccounts.map((maybeAccount) => decodeWalletEntry(maybeAccount));\n}\n\nexport function getWalletEntrySize(): number {\n return 65;\n}\n\nexport async function fetchWalletEntryFromSeeds(\n rpc: Parameters<typeof fetchEncodedAccount>[0],\n seeds: WalletEntrySeeds,\n config: FetchAccountConfig & { programAddress?: Address } = {}\n): Promise<Account<WalletEntry>> {\n const maybeAccount = await fetchMaybeWalletEntryFromSeeds(rpc, seeds, config);\n assertAccountExists(maybeAccount);\n return maybeAccount;\n}\n\nexport async function fetchMaybeWalletEntryFromSeeds(\n rpc: Parameters<typeof fetchEncodedAccount>[0],\n seeds: WalletEntrySeeds,\n config: FetchAccountConfig & { programAddress?: Address } = {}\n): Promise<MaybeAccount<WalletEntry>> {\n const { programAddress, ...fetchConfig } = config;\n const [address] = await findWalletEntryPda(seeds, { programAddress });\n return await fetchMaybeWalletEntry(rpc, address, fetchConfig);\n}\n","/**\n * This code was AUTOGENERATED using the Codama library.\n * Please DO NOT EDIT THIS FILE, instead use visitors\n * to add features, then rerun Codama to update it.\n *\n * @see https://github.com/codama-idl/codama\n */\n\nimport {\n containsBytes,\n getU8Encoder,\n type Address,\n type ReadonlyUint8Array,\n} from '@solana/kit';\nimport {\n type ParsedAddWalletInstruction,\n type ParsedCreateListInstruction,\n type ParsedDeleteListInstruction,\n type ParsedRemoveWalletInstruction,\n type ParsedSetupExtraMetasInstruction,\n} from '../instructions';\n\nexport const TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS =\n 'GATEzzqxhJnsWF6vHRsgtixxSB8PaQdcqGEVTEHWiULz' as Address<'GATEzzqxhJnsWF6vHRsgtixxSB8PaQdcqGEVTEHWiULz'>;\n\nexport enum TokenAclGateProgramAccount {\n ListConfig,\n WalletEntry,\n}\n\nexport function identifyTokenAclGateProgramAccount(\n account: { data: ReadonlyUint8Array } | ReadonlyUint8Array\n): TokenAclGateProgramAccount {\n const data = 'data' in account ? account.data : account;\n if (containsBytes(data, getU8Encoder().encode(1), 0)) {\n return TokenAclGateProgramAccount.ListConfig;\n }\n if (containsBytes(data, getU8Encoder().encode(2), 0)) {\n return TokenAclGateProgramAccount.WalletEntry;\n }\n throw new Error(\n 'The provided account could not be identified as a token-acl-gate-program account.'\n );\n}\n\nexport enum TokenAclGateProgramInstruction {\n CreateList,\n AddWallet,\n RemoveWallet,\n SetupExtraMetas,\n DeleteList,\n}\n\nexport function identifyTokenAclGateProgramInstruction(\n instruction: { data: ReadonlyUint8Array } | ReadonlyUint8Array\n): TokenAclGateProgramInstruction {\n const data = 'data' in instruction ? instruction.data : instruction;\n if (containsBytes(data, getU8Encoder().encode(1), 0)) {\n return TokenAclGateProgramInstruction.CreateList;\n }\n if (containsBytes(data, getU8Encoder().encode(2), 0)) {\n return TokenAclGateProgramInstruction.AddWallet;\n }\n if (containsBytes(data, getU8Encoder().encode(3), 0)) {\n return TokenAclGateProgramInstruction.RemoveWallet;\n }\n if (containsBytes(data, getU8Encoder().encode(4), 0)) {\n return TokenAclGateProgramInstruction.SetupExtraMetas;\n }\n if (containsBytes(data, getU8Encoder().encode(5), 0)) {\n return TokenAclGateProgramInstruction.DeleteList;\n }\n throw new Error(\n 'The provided instruction could not be identified as a token-acl-gate-program instruction.'\n );\n}\n\nexport type ParsedTokenAclGateProgramInstruction<\n TProgram extends string = 'GATEzzqxhJnsWF6vHRsgtixxSB8PaQdcqGEVTEHWiULz',\n> =\n | ({\n instructionType: TokenAclGateProgramInstruction.CreateList;\n } & ParsedCreateListInstruction<TProgram>)\n | ({\n instructionType: TokenAclGateProgramInstruction.AddWallet;\n } & ParsedAddWalletInstruction<TProgram>)\n | ({\n instructionType: TokenAclGateProgramInstruction.RemoveWallet;\n } & ParsedRemoveWalletInstruction<TProgram>)\n | ({\n instructionType: TokenAclGateProgramInstruction.SetupExtraMetas;\n } & ParsedSetupExtraMetasInstruction<TProgram>)\n | ({\n instructionType: TokenAclGateProgramInstruction.DeleteList;\n } & ParsedDeleteListInstruction<TProgram>);\n","/**\n * This code was AUTOGENERATED using the Codama library.\n * Please DO NOT EDIT THIS FILE, instead use visitors\n * to add features, then rerun Codama to update it.\n *\n * @see https://github.com/codama-idl/codama\n */\n\nimport {\n AccountRole,\n isProgramDerivedAddress,\n isTransactionSigner as kitIsTransactionSigner,\n type AccountMeta,\n type AccountSignerMeta,\n type Address,\n type ProgramDerivedAddress,\n type TransactionSigner,\n upgradeRoleToSigner,\n} from '@solana/kit';\n\n/**\n * Asserts that the given value is not null or undefined.\n * @internal\n */\nexport function expectSome<T>(value: T | null | undefined): T {\n if (value === null || value === undefined) {\n throw new Error('Expected a value but received null or undefined.');\n }\n return value;\n}\n\n/**\n * Asserts that the given value is a PublicKey.\n * @internal\n */\nexport function expectAddress<T extends string = string>(\n value:\n | Address<T>\n | ProgramDerivedAddress<T>\n | TransactionSigner<T>\n | null\n | undefined\n): Address<T> {\n if (!value) {\n throw new Error('Expected a Address.');\n }\n if (typeof value === 'object' && 'address' in value) {\n return value.address;\n }\n if (Array.isArray(value)) {\n return value[0] as Address<T>;\n }\n return value as Address<T>;\n}\n\n/**\n * Asserts that the given value is a PDA.\n * @internal\n */\nexport function expectProgramDerivedAddress<T extends string = string>(\n value:\n | Address<T>\n | ProgramDerivedAddress<T>\n | TransactionSigner<T>\n | null\n | undefined\n): ProgramDerivedAddress<T> {\n if (!value || !Array.isArray(value) || !isProgramDerivedAddress(value)) {\n throw new Error('Expected a ProgramDerivedAddress.');\n }\n return value;\n}\n\n/**\n * Asserts that the given value is a TransactionSigner.\n * @internal\n */\nexport function expectTransactionSigner<T extends string = string>(\n value:\n | Address<T>\n | ProgramDerivedAddress<T>\n | TransactionSigner<T>\n | null\n | undefined\n): TransactionSigner<T> {\n if (!value || !isTransactionSigner(value)) {\n throw new Error('Expected a TransactionSigner.');\n }\n return value;\n}\n\n/**\n * Defines an instruction account to resolve.\n * @internal\n */\nexport type ResolvedAccount<\n T extends string = string,\n U extends\n | Address<T>\n | ProgramDerivedAddress<T>\n | TransactionSigner<T>\n | null =\n | Address<T>\n | ProgramDerivedAddress<T>\n | TransactionSigner<T>\n | null,\n> = {\n isWritable: boolean;\n value: U;\n};\n\n/**\n * Defines an instruction that stores additional bytes on-chain.\n * @internal\n */\nexport type InstructionWithByteDelta = {\n byteDelta: number;\n};\n\n/**\n * Get account metas and signers from resolved accounts.\n * @internal\n */\nexport function getAccountMetaFactory(\n programAddress: Address,\n optionalAccountStrategy: 'omitted' | 'programId'\n) {\n return (\n account: ResolvedAccount\n ): AccountMeta | AccountSignerMeta | undefined => {\n if (!account.value) {\n if (optionalAccountStrategy === 'omitted') return;\n return Object.freeze({\n address: programAddress,\n role: AccountRole.READONLY,\n });\n }\n\n const writableRole = account.isWritable\n ? AccountRole.WRITABLE\n : AccountRole.READONLY;\n return Object.freeze({\n address: expectAddress(account.value),\n role: isTransactionSigner(account.value)\n ? upgradeRoleToSigner(writableRole)\n : writableRole,\n ...(isTransactionSigner(account.value) ? { signer: account.value } : {}),\n });\n };\n}\n\nexport function isTransactionSigner<TAddress extends string = string>(\n value:\n | Address<TAddress>\n | ProgramDerivedAddress<TAddress>\n | TransactionSigner<TAddress>\n): value is TransactionSigner<TAddress> {\n return (\n !!value &&\n typeof value === 'object' &&\n 'address' in value &&\n kitIsTransactionSigner(value)\n );\n}\n","/**\n * This code was AUTOGENERATED using the Codama library.\n * Please DO NOT EDIT THIS FILE, instead use visitors\n * to add features, then rerun Codama to update it.\n *\n * @see https://github.com/codama-idl/codama\n */\n\nimport {\n combineCodec,\n getStructDecoder,\n getStructEncoder,\n getU8Decoder,\n getU8Encoder,\n transformEncoder,\n type AccountMeta,\n type AccountSignerMeta,\n type Address,\n type FixedSizeCodec,\n type FixedSizeDecoder,\n type FixedSizeEncoder,\n type Instruction,\n type InstructionWithAccounts,\n type InstructionWithData,\n type ReadonlyAccount,\n type ReadonlySignerAccount,\n type ReadonlyUint8Array,\n type TransactionSigner,\n type WritableAccount,\n type WritableSignerAccount,\n} from '@solana/kit';\nimport { findWalletEntryPda } from '../pdas';\nimport { TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS } from '../programs';\nimport {\n expectAddress,\n getAccountMetaFactory,\n type ResolvedAccount,\n} from '../shared';\n\nexport const ADD_WALLET_DISCRIMINATOR = 2;\n\nexport function getAddWalletDiscriminatorBytes() {\n return getU8Encoder().encode(ADD_WALLET_DISCRIMINATOR);\n}\n\nexport type AddWalletInstruction<\n TProgram extends string = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n TAccountAuthority extends string | AccountMeta<string> = string,\n TAccountPayer extends string | AccountMeta<string> = string,\n TAccountListConfig extends string | AccountMeta<string> = string,\n TAccountWallet extends string | AccountMeta<string> = string,\n TAccountWalletEntry extends string | AccountMeta<string> = string,\n TAccountSystemProgram extends\n | string\n | AccountMeta<string> = '11111111111111111111111111111111',\n TRemainingAccounts extends readonly AccountMeta<string>[] = [],\n> = Instruction<TProgram> &\n InstructionWithData<ReadonlyUint8Array> &\n InstructionWithAccounts<\n [\n TAccountAuthority extends string\n ? ReadonlySignerAccount<TAccountAuthority> &\n AccountSignerMeta<TAccountAuthority>\n : TAccountAuthority,\n TAccountPayer extends string\n ? WritableSignerAccount<TAccountPayer> &\n AccountSignerMeta<TAccountPayer>\n : TAccountPayer,\n TAccountListConfig extends string\n ? WritableAccount<TAccountListConfig>\n : TAccountListConfig,\n TAccountWallet extends string\n ? ReadonlyAccount<TAccountWallet>\n : TAccountWallet,\n TAccountWalletEntry extends string\n ? WritableAccount<TAccountWalletEntry>\n : TAccountWalletEntry,\n TAccountSystemProgram extends string\n ? ReadonlyAccount<TAccountSystemProgram>\n : TAccountSystemProgram,\n ...TRemainingAccounts,\n ]\n >;\n\nexport type AddWalletInstructionData = { discriminator: number };\n\nexport type AddWalletInstructionDataArgs = {};\n\nexport function getAddWalletInstructionDataEncoder(): FixedSizeEncoder<AddWalletInstructionDataArgs> {\n return transformEncoder(\n getStructEncoder([['discriminator', getU8Encoder()]]),\n (value) => ({ ...value, discriminator: ADD_WALLET_DISCRIMINATOR })\n );\n}\n\nexport function getAddWalletInstructionDataDecoder(): FixedSizeDecoder<AddWalletInstructionData> {\n return getStructDecoder([['discriminator', getU8Decoder()]]);\n}\n\nexport function getAddWalletInstructionDataCodec(): FixedSizeCodec<\n AddWalletInstructionDataArgs,\n AddWalletInstructionData\n> {\n return combineCodec(\n getAddWalletInstructionDataEncoder(),\n getAddWalletInstructionDataDecoder()\n );\n}\n\nexport type AddWalletAsyncInput<\n TAccountAuthority extends string = string,\n TAccountPayer extends string = string,\n TAccountListConfig extends string = string,\n TAccountWallet extends string = string,\n TAccountWalletEntry extends string = string,\n TAccountSystemProgram extends string = string,\n> = {\n authority: TransactionSigner<TAccountAuthority>;\n payer: TransactionSigner<TAccountPayer>;\n listConfig: Address<TAccountListConfig>;\n wallet: Address<TAccountWallet>;\n walletEntry?: Address<TAccountWalletEntry>;\n systemProgram?: Address<TAccountSystemProgram>;\n};\n\nexport async function getAddWalletInstructionAsync<\n TAccountAuthority extends string,\n TAccountPayer extends string,\n TAccountListConfig extends string,\n TAccountWallet extends string,\n TAccountWalletEntry extends string,\n TAccountSystemProgram extends string,\n TProgramAddress extends\n Address = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n>(\n input: AddWalletAsyncInput<\n TAccountAuthority,\n TAccountPayer,\n TAccountListConfig,\n TAccountWallet,\n TAccountWalletEntry,\n TAccountSystemProgram\n >,\n config?: { programAddress?: TProgramAddress }\n): Promise<\n AddWalletInstruction<\n TProgramAddress,\n TAccountAuthority,\n TAccountPayer,\n TAccountListConfig,\n TAccountWallet,\n TAccountWalletEntry,\n TAccountSystemProgram\n >\n> {\n // Program address.\n const programAddress =\n config?.programAddress ?? TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS;\n\n // Original accounts.\n const originalAccounts = {\n authority: { value: input.authority ?? null, isWritable: false },\n payer: { value: input.payer ?? null, isWritable: true },\n listConfig: { value: input.listConfig ?? null, isWritable: true },\n wallet: { value: input.wallet ?? null, isWritable: false },\n walletEntry: { value: input.walletEntry ?? null, isWritable: true },\n systemProgram: { value: input.systemProgram ?? null, isWritable: false },\n };\n const accounts = originalAccounts as Record<\n keyof typeof originalAccounts,\n ResolvedAccount\n >;\n\n // Resolve default values.\n if (!accounts.walletEntry.value) {\n accounts.walletEntry.value = await findWalletEntryPda({\n listConfig: expectAddress(accounts.listConfig.value),\n wallet: expectAddress(accounts.wallet.value),\n });\n }\n if (!accounts.systemProgram.value) {\n accounts.systemProgram.value =\n '11111111111111111111111111111111' as Address<'11111111111111111111111111111111'>;\n }\n\n const getAccountMeta = getAccountMetaFactory(programAddress, 'programId');\n return Object.freeze({\n accounts: [\n getAccountMeta(accounts.authority),\n getAccountMeta(accounts.payer),\n getAccountMeta(accounts.listConfig),\n getAccountMeta(accounts.wallet),\n getAccountMeta(accounts.walletEntry),\n getAccountMeta(accounts.systemProgram),\n ],\n data: getAddWalletInstructionDataEncoder().encode({}),\n programAddress,\n } as AddWalletInstruction<\n TProgramAddress,\n TAccountAuthority,\n TAccountPayer,\n TAccountListConfig,\n TAccountWallet,\n TAccountWalletEntry,\n TAccountSystemProgram\n >);\n}\n\nexport type AddWalletInput<\n TAccountAuthority extends string = string,\n TAccountPayer extends string = string,\n TAccountListConfig extends string = string,\n TAccountWallet extends string = string,\n TAccountWalletEntry extends string = string,\n TAccountSystemProgram extends string = string,\n> = {\n authority: TransactionSigner<TAccountAuthority>;\n payer: TransactionSigner<TAccountPayer>;\n listConfig: Address<TAccountListConfig>;\n wallet: Address<TAccountWallet>;\n walletEntry: Address<TAccountWalletEntry>;\n systemProgram?: Address<TAccountSystemProgram>;\n};\n\nexport function getAddWalletInstruction<\n TAccountAuthority extends string,\n TAccountPayer extends string,\n TAccountListConfig extends string,\n TAccountWallet extends string,\n TAccountWalletEntry extends string,\n TAccountSystemProgram extends string,\n TProgramAddress extends\n Address = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n>(\n input: AddWalletInput<\n TAccountAuthority,\n TAccountPayer,\n TAccountListConfig,\n TAccountWallet,\n TAccountWalletEntry,\n TAccountSystemProgram\n >,\n config?: { programAddress?: TProgramAddress }\n): AddWalletInstruction<\n TProgramAddress,\n TAccountAuthority,\n TAccountPayer,\n TAccountListConfig,\n TAccountWallet,\n TAccountWalletEntry,\n TAccountSystemProgram\n> {\n // Program address.\n const programAddress =\n config?.programAddress ?? TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS;\n\n // Original accounts.\n const originalAccounts = {\n authority: { value: input.authority ?? null, isWritable: false },\n payer: { value: input.payer ?? null, isWritable: true },\n listConfig: { value: input.listConfig ?? null, isWritable: true },\n wallet: { value: input.wallet ?? null, isWritable: false },\n walletEntry: { value: input.walletEntry ?? null, isWritable: true },\n systemProgram: { value: input.systemProgram ?? null, isWritable: false },\n };\n const accounts = originalAccounts as Record<\n keyof typeof originalAccounts,\n ResolvedAccount\n >;\n\n // Resolve default values.\n if (!accounts.systemProgram.value) {\n accounts.systemProgram.value =\n '11111111111111111111111111111111' as Address<'11111111111111111111111111111111'>;\n }\n\n const getAccountMeta = getAccountMetaFactory(programAddress, 'programId');\n return Object.freeze({\n accounts: [\n getAccountMeta(accounts.authority),\n getAccountMeta(accounts.payer),\n getAccountMeta(accounts.listConfig),\n getAccountMeta(accounts.wallet),\n getAccountMeta(accounts.walletEntry),\n getAccountMeta(accounts.systemProgram),\n ],\n data: getAddWalletInstructionDataEncoder().encode({}),\n programAddress,\n } as AddWalletInstruction<\n TProgramAddress,\n TAccountAuthority,\n TAccountPayer,\n TAccountListConfig,\n TAccountWallet,\n TAccountWalletEntry,\n TAccountSystemProgram\n >);\n}\n\nexport type ParsedAddWalletInstruction<\n TProgram extends string = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n TAccountMetas extends readonly AccountMeta[] = readonly AccountMeta[],\n> = {\n programAddress: Address<TProgram>;\n accounts: {\n authority: TAccountMetas[0];\n payer: TAccountMetas[1];\n listConfig: TAccountMetas[2];\n wallet: TAccountMetas[3];\n walletEntry: TAccountMetas[4];\n systemProgram: TAccountMetas[5];\n };\n data: AddWalletInstructionData;\n};\n\nexport function parseAddWalletInstruction<\n TProgram extends string,\n TAccountMetas extends readonly AccountMeta[],\n>(\n instruction: Instruction<TProgram> &\n InstructionWithAccounts<TAccountMetas> &\n InstructionWithData<ReadonlyUint8Array>\n): ParsedAddWalletInstruction<TProgram, TAccountMetas> {\n if (instruction.accounts.length < 6) {\n // TODO: Coded error.\n throw new Error('Not enough accounts');\n }\n let accountIndex = 0;\n const getNextAccount = () => {\n const accountMeta = (instruction.accounts as TAccountMetas)[accountIndex]!;\n accountIndex += 1;\n return accountMeta;\n };\n return {\n programAddress: instruction.programAddress,\n accounts: {\n authority: getNextAccount(),\n payer: getNextAccount(),\n listConfig: getNextAccount(),\n wallet: getNextAccount(),\n walletEntry: getNextAccount(),\n systemProgram: getNextAccount(),\n },\n data: getAddWalletInstructionDataDecoder().decode(instruction.data),\n };\n}\n","/**\n * This code was AUTOGENERATED using the Codama library.\n * Please DO NOT EDIT THIS FILE, instead use visitors\n * to add features, then rerun Codama to update it.\n *\n * @see https://github.com/codama-idl/codama\n */\n\nimport {\n combineCodec,\n getEnumDecoder,\n getEnumEncoder,\n type FixedSizeCodec,\n type FixedSizeDecoder,\n type FixedSizeEncoder,\n} from '@solana/kit';\n\nexport enum Mode {\n Allow,\n AllowAllEoas,\n Block,\n}\n\nexport type ModeArgs = Mode;\n\nexport function getModeEncoder(): FixedSizeEncoder<ModeArgs> {\n return getEnumEncoder(Mode);\n}\n\nexport function getModeDecoder(): FixedSizeDecoder<Mode> {\n return getEnumDecoder(Mode);\n}\n\nexport function getModeCodec(): FixedSizeCodec<ModeArgs, Mode> {\n return combineCodec(getModeEncoder(), getModeDecoder());\n}\n","/**\n * This code was AUTOGENERATED using the Codama library.\n * Please DO NOT EDIT THIS FILE, instead use visitors\n * to add features, then rerun Codama to update it.\n *\n * @see https://github.com/codama-idl/codama\n */\n\nimport {\n combineCodec,\n getAddressDecoder,\n getAddressEncoder,\n getStructDecoder,\n getStructEncoder,\n getU8Decoder,\n getU8Encoder,\n transformEncoder,\n type AccountMeta,\n type AccountSignerMeta,\n type Address,\n type FixedSizeCodec,\n type FixedSizeDecoder,\n type FixedSizeEncoder,\n type Instruction,\n type InstructionWithAccounts,\n type InstructionWithData,\n type ReadonlyAccount,\n type ReadonlySignerAccount,\n type ReadonlyUint8Array,\n type TransactionSigner,\n type WritableAccount,\n type WritableSignerAccount,\n} from '@solana/kit';\nimport { findListConfigPda } from '../pdas';\nimport { TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS } from '../programs';\nimport {\n expectAddress,\n expectSome,\n getAccountMetaFactory,\n type ResolvedAccount,\n} from '../shared';\nimport {\n getModeDecoder,\n getModeEncoder,\n type Mode,\n type ModeArgs,\n} from '../types';\n\nexport const CREATE_LIST_DISCRIMINATOR = 1;\n\nexport function getCreateListDiscriminatorBytes() {\n return getU8Encoder().encode(CREATE_LIST_DISCRIMINATOR);\n}\n\nexport type CreateListInstruction<\n TProgram extends string = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n TAccountAuthority extends string | AccountMeta<string> = string,\n TAccountPayer extends string | AccountMeta<string> = string,\n TAccountListConfig extends string | AccountMeta<string> = string,\n TAccountSystemProgram extends\n | string\n | AccountMeta<string> = '11111111111111111111111111111111',\n TRemainingAccounts extends readonly AccountMeta<string>[] = [],\n> = Instruction<TProgram> &\n InstructionWithData<ReadonlyUint8Array> &\n InstructionWithAccounts<\n [\n TAccountAuthority extends string\n ? ReadonlySignerAccount<TAccountAuthority> &\n AccountSignerMeta<TAccountAuthority>\n : TAccountAuthority,\n TAccountPayer extends string\n ? WritableSignerAccount<TAccountPayer> &\n AccountSignerMeta<TAccountPayer>\n : TAccountPayer,\n TAccountListConfig extends string\n ? WritableAccount<TAccountListConfig>\n : TAccountListConfig,\n TAccountSystemProgram extends string\n ? ReadonlyAccount<TAccountSystemProgram>\n : TAccountSystemProgram,\n ...TRemainingAccounts,\n ]\n >;\n\nexport type CreateListInstructionData = {\n discriminator: number;\n mode: Mode;\n seed: Address;\n};\n\nexport type CreateListInstructionDataArgs = { mode: ModeArgs; seed: Address };\n\nexport function getCreateListInstructionDataEncoder(): FixedSizeEncoder<CreateListInstructionDataArgs> {\n return transformEncoder(\n getStructEncoder([\n ['discriminator', getU8Encoder()],\n ['mode', getModeEncoder()],\n ['seed', getAddressEncoder()],\n ]),\n (value) => ({ ...value, discriminator: CREATE_LIST_DISCRIMINATOR })\n );\n}\n\nexport function getCreateListInstructionDataDecoder(): FixedSizeDecoder<CreateListInstructionData> {\n return getStructDecoder([\n ['discriminator', getU8Decoder()],\n ['mode', getModeDecoder()],\n ['seed', getAddressDecoder()],\n ]);\n}\n\nexport function getCreateListInstructionDataCodec(): FixedSizeCodec<\n CreateListInstructionDataArgs,\n CreateListInstructionData\n> {\n return combineCodec(\n getCreateListInstructionDataEncoder(),\n getCreateListInstructionDataDecoder()\n );\n}\n\nexport type CreateListAsyncInput<\n TAccountAuthority extends string = string,\n TAccountPayer extends string = string,\n TAccountListConfig extends string = string,\n TAccountSystemProgram extends string = string,\n> = {\n authority: TransactionSigner<TAccountAuthority>;\n payer: TransactionSigner<TAccountPayer>;\n listConfig?: Address<TAccountListConfig>;\n systemProgram?: Address<TAccountSystemProgram>;\n mode: CreateListInstructionDataArgs['mode'];\n seed: CreateListInstructionDataArgs['seed'];\n};\n\nexport async function getCreateListInstructionAsync<\n TAccountAuthority extends string,\n TAccountPayer extends string,\n TAccountListConfig extends string,\n TAccountSystemProgram extends string,\n TProgramAddress extends\n Address = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n>(\n input: CreateListAsyncInput<\n TAccountAuthority,\n TAccountPayer,\n TAccountListConfig,\n TAccountSystemProgram\n >,\n config?: { programAddress?: TProgramAddress }\n): Promise<\n CreateListInstruction<\n TProgramAddress,\n TAccountAuthority,\n TAccountPayer,\n TAccountListConfig,\n TAccountSystemProgram\n >\n> {\n // Program address.\n const programAddress =\n config?.programAddress ?? TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS;\n\n // Original accounts.\n const originalAccounts = {\n authority: { value: input.authority ?? null, isWritable: false },\n payer: { value: input.payer ?? null, isWritable: true },\n listConfig: { value: input.listConfig ?? null, isWritable: true },\n systemProgram: { value: input.systemProgram ?? null, isWritable: false },\n };\n const accounts = originalAccounts as Record<\n keyof typeof originalAccounts,\n ResolvedAccount\n >;\n\n // Original args.\n const args = { ...input };\n\n // Resolve default values.\n if (!accounts.listConfig.value) {\n accounts.listConfig.value = await findListConfigPda({\n authority: expectAddress(accounts.authority.value),\n seed: expectSome(args.seed),\n });\n }\n if (!accounts.systemProgram.value) {\n accounts.systemProgram.value =\n '11111111111111111111111111111111' as Address<'11111111111111111111111111111111'>;\n }\n\n const getAccountMeta = getAccountMetaFactory(programAddress, 'programId');\n return Object.freeze({\n accounts: [\n getAccountMeta(accounts.authority),\n getAccountMeta(accounts.payer),\n getAccountMeta(accounts.listConfig),\n getAccountMeta(accounts.systemProgram),\n ],\n data: getCreateListInstructionDataEncoder().encode(\n args as CreateListInstructionDataArgs\n ),\n programAddress,\n } as CreateListInstruction<\n TProgramAddress,\n TAccountAuthority,\n TAccountPayer,\n TAccountListConfig,\n TAccountSystemProgram\n >);\n}\n\nexport type CreateListInput<\n TAccountAuthority extends string = string,\n TAccountPayer extends string = string,\n TAccountListConfig extends string = string,\n TAccountSystemProgram extends string = string,\n> = {\n authority: TransactionSigner<TAccountAuthority>;\n payer: TransactionSigner<TAccountPayer>;\n listConfig: Address<TAccountListConfig>;\n systemProgram?: Address<TAccountSystemProgram>;\n mode: CreateListInstructionDataArgs['mode'];\n seed: CreateListInstructionDataArgs['seed'];\n};\n\nexport function getCreateListInstruction<\n TAccountAuthority extends string,\n TAccountPayer extends string,\n TAccountListConfig extends string,\n TAccountSystemProgram extends string,\n TProgramAddress extends\n Address = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n>(\n input: CreateListInput<\n TAccountAuthority,\n TAccountPayer,\n TAccountListConfig,\n TAccountSystemProgram\n >,\n config?: { programAddress?: TProgramAddress }\n): CreateListInstruction<\n TProgramAddress,\n TAccountAuthority,\n TAccountPayer,\n TAccountListConfig,\n TAccountSystemProgram\n> {\n // Program address.\n const programAddress =\n config?.programAddress ?? TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS;\n\n // Original accounts.\n const originalAccounts = {\n authority: { value: input.authority ?? null, isWritable: false },\n payer: { value: input.payer ?? null, isWritable: true },\n listConfig: { value: input.listConfig ?? null, isWritable: true },\n systemProgram: { value: input.systemProgram ?? null, isWritable: false },\n };\n const accounts = originalAccounts as Record<\n keyof typeof originalAccounts,\n ResolvedAccount\n >;\n\n // Original args.\n const args = { ...input };\n\n // Resolve default values.\n if (!accounts.systemProgram.value) {\n accounts.systemProgram.value =\n '11111111111111111111111111111111' as Address<'11111111111111111111111111111111'>;\n }\n\n const getAccountMeta = getAccountMetaFactory(programAddress, 'programId');\n return Object.freeze({\n accounts: [\n getAccountMeta(accounts.authority),\n getAccountMeta(accounts.payer),\n getAccountMeta(accounts.listConfig),\n getAccountMeta(accounts.systemProgram),\n ],\n data: getCreateListInstructionDataEncoder().encode(\n args as CreateListInstructionDataArgs\n ),\n programAddress,\n } as CreateListInstruction<\n TProgramAddress,\n TAccountAuthority,\n TAccountPayer,\n TAccountListConfig,\n TAccountSystemProgram\n >);\n}\n\nexport type ParsedCreateListInstruction<\n TProgram extends string = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n TAccountMetas extends readonly AccountMeta[] = readonly AccountMeta[],\n> = {\n programAddress: Address<TProgram>;\n accounts: {\n authority: TAccountMetas[0];\n payer: TAccountMetas[1];\n listConfig: TAccountMetas[2];\n systemProgram: TAccountMetas[3];\n };\n data: CreateListInstructionData;\n};\n\nexport function parseCreateListInstruction<\n TProgram extends string,\n TAccountMetas extends readonly AccountMeta[],\n>(\n instruction: Instruction<TProgram> &\n InstructionWithAccounts<TAccountMetas> &\n InstructionWithData<ReadonlyUint8Array>\n): ParsedCreateListInstruction<TProgram, TAccountMetas> {\n if (instruction.accounts.length < 4) {\n // TODO: Coded error.\n throw new Error('Not enough accounts');\n }\n let accountIndex = 0;\n const getNextAccount = () => {\n const accountMeta = (instruction.accounts as TAccountMetas)[accountIndex]!;\n accountIndex += 1;\n return accountMeta;\n };\n return {\n programAddress: instruction.programAddress,\n accounts: {\n authority: getNextAccount(),\n payer: getNextAccount(),\n listConfig: getNextAccount(),\n systemProgram: getNextAccount(),\n },\n data: getCreateListInstructionDataDecoder().decode(instruction.data),\n };\n}\n","/**\n * This code was AUTOGENERATED using the Codama library.\n * Please DO NOT EDIT THIS FILE, instead use visitors\n * to add features, then rerun Codama to update it.\n *\n * @see https://github.com/codama-idl/codama\n */\n\nimport {\n combineCodec,\n getStructDecoder,\n getStructEncoder,\n getU8Decoder,\n getU8Encoder,\n transformEncoder,\n type AccountMeta,\n type AccountSignerMeta,\n type Address,\n type FixedSizeCodec,\n type FixedSizeDecoder,\n type FixedSizeEncoder,\n type Instruction,\n type InstructionWithAccounts,\n type InstructionWithData,\n type ReadonlyUint8Array,\n type TransactionSigner,\n type WritableAccount,\n type WritableSignerAccount,\n} from '@solana/kit';\nimport { TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS } from '../programs';\nimport { getAccountMetaFactory, type ResolvedAccount } from '../shared';\n\nexport const DELETE_LIST_DISCRIMINATOR = 5;\n\nexport function getDeleteListDiscriminatorBytes() {\n return getU8Encoder().encode(DELETE_LIST_DISCRIMINATOR);\n}\n\nexport type DeleteListInstruction<\n TProgram extends string = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n TAccountAuthority extends string | AccountMeta<string> = string,\n TAccountListConfig extends string | AccountMeta<string> = string,\n TRemainingAccounts extends readonly AccountMeta<string>[] = [],\n> = Instruction<TProgram> &\n InstructionWithData<ReadonlyUint8Array> &\n InstructionWithAccounts<\n [\n TAccountAuthority extends string\n ? WritableSignerAccount<TAccountAuthority> &\n AccountSignerMeta<TAccountAuthority>\n : TAccountAuthority,\n TAccountListConfig extends string\n ? WritableAccount<TAccountListConfig>\n : TAccountListConfig,\n ...TRemainingAccounts,\n ]\n >;\n\nexport type DeleteListInstructionData = { discriminator: number };\n\nexport type DeleteListInstructionDataArgs = {};\n\nexport function getDeleteListInstructionDataEncoder(): FixedSizeEncoder<DeleteListInstructionDataArgs> {\n return transformEncoder(\n getStructEncoder([['discriminator', getU8Encoder()]]),\n (value) => ({ ...value, discriminator: DELETE_LIST_DISCRIMINATOR })\n );\n}\n\nexport function getDeleteListInstructionDataDecoder(): FixedSizeDecoder<DeleteListInstructionData> {\n return getStructDecoder([['discriminator', getU8Decoder()]]);\n}\n\nexport function getDeleteListInstructionDataCodec(): FixedSizeCodec<\n DeleteListInstructionDataArgs,\n DeleteListInstructionData\n> {\n return combineCodec(\n getDeleteListInstructionDataEncoder(),\n getDeleteListInstructionDataDecoder()\n );\n}\n\nexport type DeleteListInput<\n TAccountAuthority extends string = string,\n TAccountListConfig extends string = string,\n> = {\n authority: TransactionSigner<TAccountAuthority>;\n listConfig: Address<TAccountListConfig>;\n};\n\nexport function getDeleteListInstruction<\n TAccountAuthority extends string,\n TAccountListConfig extends string,\n TProgramAddress extends\n Address = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n>(\n input: DeleteListInput<TAccountAuthority, TAccountListConfig>,\n config?: { programAddress?: TProgramAddress }\n): DeleteListInstruction<\n TProgramAddress,\n TAccountAuthority,\n TAccountListConfig\n> {\n // Program address.\n const programAddress =\n config?.programAddress ?? TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS;\n\n // Original accounts.\n const originalAccounts = {\n authority: { value: input.authority ?? null, isWritable: true },\n listConfig: { value: input.listConfig ?? null, isWritable: true },\n };\n const accounts = originalAccounts as Record<\n keyof typeof originalAccounts,\n ResolvedAccount\n >;\n\n const getAccountMeta = getAccountMetaFactory(programAddress, 'programId');\n return Object.freeze({\n accounts: [\n getAccountMeta(accounts.authority),\n getAccountMeta(accounts.listConfig),\n ],\n data: getDeleteListInstructionDataEncoder().encode({}),\n programAddress,\n } as DeleteListInstruction<\n TProgramAddress,\n TAccountAuthority,\n TAccountListConfig\n >);\n}\n\nexport type ParsedDeleteListInstruction<\n TProgram extends string = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n TAccountMetas extends readonly AccountMeta[] = readonly AccountMeta[],\n> = {\n programAddress: Address<TProgram>;\n accounts: {\n authority: TAccountMetas[0];\n listConfig: TAccountMetas[1];\n };\n data: DeleteListInstructionData;\n};\n\nexport function parseDeleteListInstruction<\n TProgram extends string,\n TAccountMetas extends readonly AccountMeta[],\n>(\n instruction: Instruction<TProgram> &\n InstructionWithAccounts<TAccountMetas> &\n InstructionWithData<ReadonlyUint8Array>\n): ParsedDeleteListInstruction<TProgram, TAccountMetas> {\n if (instruction.accounts.length < 2) {\n // TODO: Coded error.\n throw new Error('Not enough accounts');\n }\n let accountIndex = 0;\n const getNextAccount = () => {\n const accountMeta = (instruction.accounts as TAccountMetas)[accountIndex]!;\n accountIndex += 1;\n return accountMeta;\n };\n return {\n programAddress: instruction.programAddress,\n accounts: { authority: getNextAccount(), listConfig: getNextAccount() },\n data: getDeleteListInstructionDataDecoder().decode(instruction.data),\n };\n}\n","/**\n * This code was AUTOGENERATED using the Codama library.\n * Please DO NOT EDIT THIS FILE, instead use visitors\n * to add features, then rerun Codama to update it.\n *\n * @see https://github.com/codama-idl/codama\n */\n\nimport {\n combineCodec,\n getStructDecoder,\n getStructEncoder,\n getU8Decoder,\n getU8Encoder,\n transformEncoder,\n type AccountMeta,\n type AccountSignerMeta,\n type Address,\n type FixedSizeCodec,\n type FixedSizeDecoder,\n type FixedSizeEncoder,\n type Instruction,\n type InstructionWithAccounts,\n type InstructionWithData,\n type ReadonlyUint8Array,\n type TransactionSigner,\n type WritableAccount,\n type WritableSignerAccount,\n} from '@solana/kit';\nimport { TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS } from '../programs';\nimport { getAccountMetaFactory, type ResolvedAccount } from '../shared';\n\nexport const REMOVE_WALLET_DISCRIMINATOR = 3;\n\nexport function getRemoveWalletDiscriminatorBytes() {\n return getU8Encoder().encode(REMOVE_WALLET_DISCRIMINATOR);\n}\n\nexport type RemoveWalletInstruction<\n TProgram extends string = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n TAccountAuthority extends string | AccountMeta<string> = string,\n TAccountListConfig extends string | AccountMeta<string> = string,\n TAccountWalletEntry extends string | AccountMeta<string> = string,\n TRemainingAccounts extends readonly AccountMeta<string>[] = [],\n> = Instruction<TProgram> &\n InstructionWithData<ReadonlyUint8Array> &\n InstructionWithAccounts<\n [\n TAccountAuthority extends string\n ? WritableSignerAccount<TAccountAuthority> &\n AccountSignerMeta<TAccountAuthority>\n : TAccountAuthority,\n TAccountListConfig extends string\n ? WritableAccount<TAccountListConfig>\n : TAccountListConfig,\n TAccountWalletEntry extends string\n ? WritableAccount<TAccountWalletEntry>\n : TAccountWalletEntry,\n ...TRemainingAccounts,\n ]\n >;\n\nexport type RemoveWalletInstructionData = { discriminator: number };\n\nexport type RemoveWalletInstructionDataArgs = {};\n\nexport function getRemoveWalletInstructionDataEncoder(): FixedSizeEncoder<RemoveWalletInstructionDataArgs> {\n return transformEncoder(\n getStructEncoder([['discriminator', getU8Encoder()]]),\n (value) => ({ ...value, discriminator: REMOVE_WALLET_DISCRIMINATOR })\n );\n}\n\nexport function getRemoveWalletInstructionDataDecoder(): FixedSizeDecoder<RemoveWalletInstructionData> {\n return getStructDecoder([['discriminator', getU8Decoder()]]);\n}\n\nexport function getRemoveWalletInstructionDataCodec(): FixedSizeCodec<\n RemoveWalletInstructionDataArgs,\n RemoveWalletInstructionData\n> {\n return combineCodec(\n getRemoveWalletInstructionDataEncoder(),\n getRemoveWalletInstructionDataDecoder()\n );\n}\n\nexport type RemoveWalletInput<\n TAccountAuthority extends string = string,\n TAccountListConfig extends string = string,\n TAccountWalletEntry extends string = string,\n> = {\n authority: TransactionSigner<TAccountAuthority>;\n listConfig: Address<TAccountListConfig>;\n walletEntry: Address<TAccountWalletEntry>;\n};\n\nexport function getRemoveWalletInstruction<\n TAccountAuthority extends string,\n TAccountListConfig extends string,\n TAccountWalletEntry extends string,\n TProgramAddress extends\n Address = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n>(\n input: RemoveWalletInput<\n TAccountAuthority,\n TAccountListConfig,\n TAccountWalletEntry\n >,\n config?: { programAddress?: TProgramAddress }\n): RemoveWalletInstruction<\n TProgramAddress,\n TAccountAuthority,\n TAccountListConfig,\n TAccountWalletEntry\n> {\n // Program address.\n const programAddress =\n config?.programAddress ?? TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS;\n\n // Original accounts.\n const originalAccounts = {\n authority: { value: input.authority ?? null, isWritable: true },\n listConfig: { value: input.listConfig ?? null, isWritable: true },\n walletEntry: { value: input.walletEntry ?? null, isWritable: true },\n };\n const accounts = originalAccounts as Record<\n keyof typeof originalAccounts,\n ResolvedAccount\n >;\n\n const getAccountMeta = getAccountMetaFactory(programAddress, 'programId');\n return Object.freeze({\n accounts: [\n getAccountMeta(accounts.authority),\n getAccountMeta(accounts.listConfig),\n getAccountMeta(accounts.walletEntry),\n ],\n data: getRemoveWalletInstructionDataEncoder().encode({}),\n programAddress,\n } as RemoveWalletInstruction<\n TProgramAddress,\n TAccountAuthority,\n TAccountListConfig,\n TAccountWalletEntry\n >);\n}\n\nexport type ParsedRemoveWalletInstruction<\n TProgram extends string = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n TAccountMetas extends readonly AccountMeta[] = readonly AccountMeta[],\n> = {\n programAddress: Address<TProgram>;\n accounts: {\n authority: TAccountMetas[0];\n listConfig: TAccountMetas[1];\n walletEntry: TAccountMetas[2];\n };\n data: RemoveWalletInstructionData;\n};\n\nexport function parseRemoveWalletInstruction<\n TProgram extends string,\n TAccountMetas extends readonly AccountMeta[],\n>(\n instruction: Instruction<TProgram> &\n InstructionWithAccounts<TAccountMetas> &\n InstructionWithData<ReadonlyUint8Array>\n): ParsedRemoveWalletInstruction<TProgram, TAccountMetas> {\n if (instruction.accounts.length < 3) {\n // TODO: Coded error.\n throw new Error('Not enough accounts');\n }\n let accountIndex = 0;\n const getNextAccount = () => {\n const accountMeta = (instruction.accounts as TAccountMetas)[accountIndex]!;\n accountIndex += 1;\n return accountMeta;\n };\n return {\n programAddress: instruction.programAddress,\n accounts: {\n authority: getNextAccount(),\n listConfig: getNextAccount(),\n walletEntry: getNextAccount(),\n },\n data: getRemoveWalletInstructionDataDecoder().decode(instruction.data),\n };\n}\n","/**\n * This code was AUTOGENERATED using the Codama library.\n * Please DO NOT EDIT THIS FILE, instead use visitors\n * to add features, then rerun Codama to update it.\n *\n * @see https://github.com/codama-idl/codama\n */\n\nimport {\n AccountRole,\n combineCodec,\n getStructDecoder,\n getStructEncoder,\n getU8Decoder,\n getU8Encoder,\n transformEncoder,\n type AccountMeta,\n type AccountSignerMeta,\n type Address,\n type FixedSizeCodec,\n type FixedSizeDecoder,\n type FixedSizeEncoder,\n type Instruction,\n type InstructionWithAccounts,\n type InstructionWithData,\n type ReadonlyAccount,\n type ReadonlySignerAccount,\n type ReadonlyUint8Array,\n type TransactionSigner,\n type WritableAccount,\n type WritableSignerAccount,\n} from '@solana/kit';\nimport { TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS } from '../programs';\nimport { getAccountMetaFactory, type ResolvedAccount } from '../shared';\n\nexport const SETUP_EXTRA_METAS_DISCRIMINATOR = 4;\n\nexport function getSetupExtraMetasDiscriminatorBytes() {\n return getU8Encoder().encode(SETUP_EXTRA_METAS_DISCRIMINATOR);\n}\n\nexport type SetupExtraMetasInstruction<\n TProgram extends string = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n TAccountAuthority extends string | AccountMeta<string> = string,\n TAccountPayer extends string | AccountMeta<string> = string,\n TAccountTokenAclMintConfig extends string | AccountMeta<string> = string,\n TAccountMint extends string | AccountMeta<string> = string,\n TAccountExtraMetas extends string | AccountMeta<string> = string,\n TAccountSystemProgram extends\n | string\n | AccountMeta<string> = '11111111111111111111111111111111',\n TRemainingAccounts extends readonly AccountMeta<string>[] = [],\n> = Instruction<TProgram> &\n InstructionWithData<ReadonlyUint8Array> &\n InstructionWithAccounts<\n [\n TAccountAuthority extends string\n ? ReadonlySignerAccount<TAccountAuthority> &\n AccountSignerMeta<TAccountAuthority>\n : TAccountAuthority,\n TAccountPayer extends string\n ? WritableSignerAccount<TAccountPayer> &\n AccountSignerMeta<TAccountPayer>\n : TAccountPayer,\n TAccountTokenAclMintConfig extends string\n ? ReadonlyAccount<TAccountTokenAclMintConfig>\n : TAccountTokenAclMintConfig,\n TAccountMint extends string\n ? ReadonlyAccount<TAccountMint>\n : TAccountMint,\n TAccountExtraMetas extends string\n ? WritableAccount<TAccountExtraMetas>\n : TAccountExtraMetas,\n TAccountSystemProgram extends string\n ? ReadonlyAccount<TAccountSystemProgram>\n : TAccountSystemProgram,\n ...TRemainingAccounts,\n ]\n >;\n\nexport type SetupExtraMetasInstructionData = { discriminator: number };\n\nexport type SetupExtraMetasInstructionDataArgs = {};\n\nexport function getSetupExtraMetasInstructionDataEncoder(): FixedSizeEncoder<SetupExtraMetasInstructionDataArgs> {\n return transformEncoder(\n getStructEncoder([['discriminator', getU8Encoder()]]),\n (value) => ({ ...value, discriminator: SETUP_EXTRA_METAS_DISCRIMINATOR })\n );\n}\n\nexport function getSetupExtraMetasInstructionDataDecoder(): FixedSizeDecoder<SetupExtraMetasInstructionData> {\n return getStructDecoder([['discriminator', getU8Decoder()]]);\n}\n\nexport function getSetupExtraMetasInstructionDataCodec(): FixedSizeCodec<\n SetupExtraMetasInstructionDataArgs,\n SetupExtraMetasInstructionData\n> {\n return combineCodec(\n getSetupExtraMetasInstructionDataEncoder(),\n getSetupExtraMetasInstructionDataDecoder()\n );\n}\n\nexport type SetupExtraMetasInput<\n TAccountAuthority extends string = string,\n TAccountPayer extends string = string,\n TAccountTokenAclMintConfig extends string = string,\n TAccountMint extends string = string,\n TAccountExtraMetas extends string = string,\n TAccountSystemProgram extends string = string,\n> = {\n authority: TransactionSigner<TAccountAuthority>;\n payer: TransactionSigner<TAccountPayer>;\n tokenAclMintConfig: Address<TAccountTokenAclMintConfig>;\n mint: Address<TAccountMint>;\n extraMetas: Address<TAccountExtraMetas>;\n systemProgram?: Address<TAccountSystemProgram>;\n lists: Array<Address>;\n};\n\nexport function getSetupExtraMetasInstruction<\n TAccountAuthority extends string,\n TAccountPayer extends string,\n TAccountTokenAclMintConfig extends string,\n TAccountMint extends string,\n TAccountExtraMetas extends string,\n TAccountSystemProgram extends string,\n TProgramAddress extends\n Address = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n>(\n input: SetupExtraMetasInput<\n TAccountAuthority,\n TAccountPayer,\n TAccountTokenAclMintConfig,\n TAccountMint,\n TAccountExtraMetas,\n TAccountSystemProgram\n >,\n config?: { programAddress?: TProgramAddress }\n): SetupExtraMetasInstruction<\n TProgramAddress,\n TAccountAuthority,\n TAccountPayer,\n TAccountTokenAclMintConfig,\n TAccountMint,\n TAccountExtraMetas,\n TAccountSystemProgram\n> {\n // Program address.\n const programAddress =\n config?.programAddress ?? TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS;\n\n // Original accounts.\n const originalAccounts = {\n authority: { value: input.authority ?? null, isWritable: false },\n payer: { value: input.payer ?? null, isWritable: true },\n tokenAclMintConfig: {\n value: input.tokenAclMintConfig ?? null,\n isWritable: false,\n },\n mint: { value: input.mint ?? null, isWritable: false },\n extraMetas: { value: input.extraMetas ?? null, isWritable: true },\n systemProgram: { value: input.systemProgram ?? null, isWritable: false },\n };\n const accounts = originalAccounts as Record<\n keyof typeof originalAccounts,\n ResolvedAccount\n >;\n\n // Original args.\n const args = { ...input };\n\n // Resolve default values.\n if (!accounts.systemProgram.value) {\n accounts.systemProgram.value =\n '11111111111111111111111111111111' as Address<'11111111111111111111111111111111'>;\n }\n\n // Remaining accounts.\n const remainingAccounts: AccountMeta[] = args.lists.map((address) => ({\n address,\n role: AccountRole.READONLY,\n }));\n\n const getAccountMeta = getAccountMetaFactory(programAddress, 'programId');\n return Object.freeze({\n accounts: [\n getAccountMeta(accounts.authority),\n getAccountMeta(accounts.payer),\n getAccountMeta(accounts.tokenAclMintConfig),\n getAccountMeta(accounts.mint),\n getAccountMeta(accounts.extraMetas),\n getAccountMeta(accounts.systemProgram),\n ...remainingAccounts,\n ],\n data: getSetupExtraMetasInstructionDataEncoder().encode({}),\n programAddress,\n } as SetupExtraMetasInstruction<\n TProgramAddress,\n TAccountAuthority,\n TAccountPayer,\n TAccountTokenAclMintConfig,\n TAccountMint,\n TAccountExtraMetas,\n TAccountSystemProgram\n >);\n}\n\nexport type ParsedSetupExtraMetasInstruction<\n TProgram extends string = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n TAccountMetas extends readonly AccountMeta[] = readonly AccountMeta[],\n> = {\n programAddress: Address<TProgram>;\n accounts: {\n authority: TAccountMetas[0];\n payer: TAccountMetas[1];\n tokenAclMintConfig: TAccountMetas[2];\n mint: TAccountMetas[3];\n extraMetas: TAccountMetas[4];\n systemProgram: TAccountMetas[5];\n };\n data: SetupExtraMetasInstructionData;\n};\n\nexport function parseSetupExtraMetasInstruction<\n TProgram extends string,\n TAccountMetas extends readonly AccountMeta[],\n>(\n instruction: Instruction<TProgram> &\n InstructionWithAccounts<TAccountMetas> &\n InstructionWithData<ReadonlyUint8Array>\n): ParsedSetupExtraMetasInstruction<TProgram, TAccountMetas> {\n if (instruction.accounts.length < 6) {\n // TODO: Coded error.\n throw new Error('Not enough accounts');\n }\n let accountIndex = 0;\n const getNextAccount = () => {\n const accountMeta = (instruction.accounts as TAccountMetas)[accountIndex]!;\n accountIndex += 1;\n return accountMeta;\n };\n return {\n programAddress: instruction.programAddress,\n accounts: {\n authority: getNextAccount(),\n payer: getNextAccount(),\n tokenAclMintConfig: getNextAccount(),\n mint: getNextAccount(),\n extraMetas: getNextAccount(),\n systemProgram: getNextAccount(),\n },\n data: getSetupExtraMetasInstructionDataDecoder().decode(instruction.data),\n };\n}\n"]}
|
|
1
|
+
{"version":3,"sources":["../../src/generated/pdas/listConfig.ts","../../src/generated/pdas/walletEntry.ts","../../src/generated/accounts/listConfig.ts","../../src/generated/accounts/walletEntry.ts","../../src/generated/programs/tokenAclGateProgram.ts","../../src/generated/shared/index.ts","../../src/generated/instructions/addWallet.ts","../../src/generated/instructions/canFreezePermissionless.ts","../../src/generated/instructions/canThawPermissionless.ts","../../src/generated/types/mode.ts","../../src/generated/instructions/createList.ts","../../src/generated/instructions/deleteList.ts","../../src/generated/instructions/removeWallet.ts","../../src/generated/instructions/setupExtraMetas.ts","../../src/generated/instructions/setupFreezeExtraMetas.ts"],"names":["getProgramDerivedAddress","getUtf8Encoder","getAddressEncoder","getU8Encoder","transformEncoder","getStructEncoder","getU64Encoder","getStructDecoder","getU8Decoder","getAddressDecoder","getU64Decoder","combineCodec","decodeAccount","assertAccountExists","fetchEncodedAccount","assertAccountsExist","fetchEncodedAccounts","TokenAclGateProgramAccount","containsBytes","TokenAclGateProgramInstruction","AccountRole","upgradeRoleToSigner","kitIsTransactionSigner","Mode","getEnumEncoder","getEnumDecoder"],"mappings":";;;;;AAqBA,eAAsB,iBAAA,CACpB,KAAA,EACA,MAAA,GAAmD,EAAC,EACpB;AAChC,EAAA,MAAM;AAAA,IACJ,cAAA,GAAiB;AAAA,GACnB,GAAI,MAAA;AACJ,EAAA,OAAO,MAAMA,4BAAA,CAAyB;AAAA,IACpC,cAAA;AAAA,IACA,KAAA,EAAO;AAAA,MACLC,kBAAA,EAAe,CAAE,MAAA,CAAO,aAAa,CAAA;AAAA,MACrCC,qBAAA,EAAkB,CAAE,MAAA,CAAO,KAAA,CAAM,SAAS,CAAA;AAAA,MAC1CA,qBAAA,EAAkB,CAAE,MAAA,CAAO,KAAA,CAAM,IAAI;AAAA;AACvC,GACD,CAAA;AACH;ACfA,eAAsB,kBAAA,CACpB,KAAA,EACA,MAAA,GAAmD,EAAC,EACpB;AAChC,EAAA,MAAM;AAAA,IACJ,cAAA,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;AACd,GACF;AACF","file":"index.js","sourcesContent":["/**\n * This code was AUTOGENERATED using the Codama library.\n * Please DO NOT EDIT THIS FILE, instead use visitors\n * to add features, then rerun Codama to update it.\n *\n * @see https://github.com/codama-idl/codama\n */\n\nimport {\n getAddressEncoder,\n getProgramDerivedAddress,\n getUtf8Encoder,\n type Address,\n type ProgramDerivedAddress,\n} from '@solana/kit';\n\nexport type ListConfigSeeds = {\n authority: Address;\n seed: Address;\n};\n\nexport async function findListConfigPda(\n seeds: ListConfigSeeds,\n config: { programAddress?: Address | undefined } = {}\n): Promise<ProgramDerivedAddress> {\n const {\n programAddress = 'GATEzzqxhJnsWF6vHRsgtixxSB8PaQdcqGEVTEHWiULz' as Address<'GATEzzqxhJnsWF6vHRsgtixxSB8PaQdcqGEVTEHWiULz'>,\n } = config;\n return await getProgramDerivedAddress({\n programAddress,\n seeds: [\n getUtf8Encoder().encode('list_config'),\n getAddressEncoder().encode(seeds.authority),\n getAddressEncoder().encode(seeds.seed),\n ],\n });\n}\n","/**\n * This code was AUTOGENERATED using the Codama library.\n * Please DO NOT EDIT THIS FILE, instead use visitors\n * to add features, then rerun Codama to update it.\n *\n * @see https://github.com/codama-idl/codama\n */\n\nimport {\n getAddressEncoder,\n getProgramDerivedAddress,\n getUtf8Encoder,\n type Address,\n type ProgramDerivedAddress,\n} from '@solana/kit';\n\nexport type WalletEntrySeeds = {\n listConfig: Address;\n wallet: Address;\n};\n\nexport async function findWalletEntryPda(\n seeds: WalletEntrySeeds,\n config: { programAddress?: Address | undefined } = {}\n): Promise<ProgramDerivedAddress> {\n const {\n programAddress = 'GATEzzqxhJnsWF6vHRsgtixxSB8PaQdcqGEVTEHWiULz' as Address<'GATEzzqxhJnsWF6vHRsgtixxSB8PaQdcqGEVTEHWiULz'>,\n } = config;\n return await getProgramDerivedAddress({\n programAddress,\n seeds: [\n getUtf8Encoder().encode('wallet_entry'),\n getAddressEncoder().encode(seeds.listConfig),\n getAddressEncoder().encode(seeds.wallet),\n ],\n });\n}\n","/**\n * This code was AUTOGENERATED using the Codama library.\n * Please DO NOT EDIT THIS FILE, instead use visitors\n * to add features, then rerun Codama to update it.\n *\n * @see https://github.com/codama-idl/codama\n */\n\nimport {\n assertAccountExists,\n assertAccountsExist,\n combineCodec,\n decodeAccount,\n fetchEncodedAccount,\n fetchEncodedAccounts,\n getAddressDecoder,\n getAddressEncoder,\n getStructDecoder,\n getStructEncoder,\n getU64Decoder,\n getU64Encoder,\n getU8Decoder,\n getU8Encoder,\n transformEncoder,\n type Account,\n type Address,\n type EncodedAccount,\n type FetchAccountConfig,\n type FetchAccountsConfig,\n type FixedSizeCodec,\n type FixedSizeDecoder,\n type FixedSizeEncoder,\n type MaybeAccount,\n type MaybeEncodedAccount,\n} from '@solana/kit';\nimport { findListConfigPda, ListConfigSeeds } from '../pdas';\n\nexport const LIST_CONFIG_DISCRIMINATOR = 1;\n\nexport function getListConfigDiscriminatorBytes() {\n return getU8Encoder().encode(LIST_CONFIG_DISCRIMINATOR);\n}\n\nexport type ListConfig = {\n discriminator: number;\n authority: Address;\n seed: Address;\n mode: number;\n walletsCount: bigint;\n};\n\nexport type ListConfigArgs = {\n discriminator?: number;\n authority: Address;\n seed: Address;\n mode: number;\n walletsCount: number | bigint;\n};\n\nexport function getListConfigEncoder(): FixedSizeEncoder<ListConfigArgs> {\n return transformEncoder(\n getStructEncoder([\n ['discriminator', getU8Encoder()],\n ['authority', getAddressEncoder()],\n ['seed', getAddressEncoder()],\n ['mode', getU8Encoder()],\n ['walletsCount', getU64Encoder()],\n ]),\n (value) => ({\n ...value,\n discriminator: value.discriminator ?? LIST_CONFIG_DISCRIMINATOR,\n })\n );\n}\n\nexport function getListConfigDecoder(): FixedSizeDecoder<ListConfig> {\n return getStructDecoder([\n ['discriminator', getU8Decoder()],\n ['authority', getAddressDecoder()],\n ['seed', getAddressDecoder()],\n ['mode', getU8Decoder()],\n ['walletsCount', getU64Decoder()],\n ]);\n}\n\nexport function getListConfigCodec(): FixedSizeCodec<\n ListConfigArgs,\n ListConfig\n> {\n return combineCodec(getListConfigEncoder(), getListConfigDecoder());\n}\n\nexport function decodeListConfig<TAddress extends string = string>(\n encodedAccount: EncodedAccount<TAddress>\n): Account<ListConfig, TAddress>;\nexport function decodeListConfig<TAddress extends string = string>(\n encodedAccount: MaybeEncodedAccount<TAddress>\n): MaybeAccount<ListConfig, TAddress>;\nexport function decodeListConfig<TAddress extends string = string>(\n encodedAccount: EncodedAccount<TAddress> | MaybeEncodedAccount<TAddress>\n): Account<ListConfig, TAddress> | MaybeAccount<ListConfig, TAddress> {\n return decodeAccount(\n encodedAccount as MaybeEncodedAccount<TAddress>,\n getListConfigDecoder()\n );\n}\n\nexport async function fetchListConfig<TAddress extends string = string>(\n rpc: Parameters<typeof fetchEncodedAccount>[0],\n address: Address<TAddress>,\n config?: FetchAccountConfig\n): Promise<Account<ListConfig, TAddress>> {\n const maybeAccount = await fetchMaybeListConfig(rpc, address, config);\n assertAccountExists(maybeAccount);\n return maybeAccount;\n}\n\nexport async function fetchMaybeListConfig<TAddress extends string = string>(\n rpc: Parameters<typeof fetchEncodedAccount>[0],\n address: Address<TAddress>,\n config?: FetchAccountConfig\n): Promise<MaybeAccount<ListConfig, TAddress>> {\n const maybeAccount = await fetchEncodedAccount(rpc, address, config);\n return decodeListConfig(maybeAccount);\n}\n\nexport async function fetchAllListConfig(\n rpc: Parameters<typeof fetchEncodedAccounts>[0],\n addresses: Array<Address>,\n config?: FetchAccountsConfig\n): Promise<Account<ListConfig>[]> {\n const maybeAccounts = await fetchAllMaybeListConfig(rpc, addresses, config);\n assertAccountsExist(maybeAccounts);\n return maybeAccounts;\n}\n\nexport async function fetchAllMaybeListConfig(\n rpc: Parameters<typeof fetchEncodedAccounts>[0],\n addresses: Array<Address>,\n config?: FetchAccountsConfig\n): Promise<MaybeAccount<ListConfig>[]> {\n const maybeAccounts = await fetchEncodedAccounts(rpc, addresses, config);\n return maybeAccounts.map((maybeAccount) => decodeListConfig(maybeAccount));\n}\n\nexport function getListConfigSize(): number {\n return 74;\n}\n\nexport async function fetchListConfigFromSeeds(\n rpc: Parameters<typeof fetchEncodedAccount>[0],\n seeds: ListConfigSeeds,\n config: FetchAccountConfig & { programAddress?: Address } = {}\n): Promise<Account<ListConfig>> {\n const maybeAccount = await fetchMaybeListConfigFromSeeds(rpc, seeds, config);\n assertAccountExists(maybeAccount);\n return maybeAccount;\n}\n\nexport async function fetchMaybeListConfigFromSeeds(\n rpc: Parameters<typeof fetchEncodedAccount>[0],\n seeds: ListConfigSeeds,\n config: FetchAccountConfig & { programAddress?: Address } = {}\n): Promise<MaybeAccount<ListConfig>> {\n const { programAddress, ...fetchConfig } = config;\n const [address] = await findListConfigPda(seeds, { programAddress });\n return await fetchMaybeListConfig(rpc, address, fetchConfig);\n}\n","/**\n * This code was AUTOGENERATED using the Codama library.\n * Please DO NOT EDIT THIS FILE, instead use visitors\n * to add features, then rerun Codama to update it.\n *\n * @see https://github.com/codama-idl/codama\n */\n\nimport {\n assertAccountExists,\n assertAccountsExist,\n combineCodec,\n decodeAccount,\n fetchEncodedAccount,\n fetchEncodedAccounts,\n getAddressDecoder,\n getAddressEncoder,\n getStructDecoder,\n getStructEncoder,\n getU8Decoder,\n getU8Encoder,\n transformEncoder,\n type Account,\n type Address,\n type EncodedAccount,\n type FetchAccountConfig,\n type FetchAccountsConfig,\n type FixedSizeCodec,\n type FixedSizeDecoder,\n type FixedSizeEncoder,\n type MaybeAccount,\n type MaybeEncodedAccount,\n} from '@solana/kit';\nimport { findWalletEntryPda, WalletEntrySeeds } from '../pdas';\n\nexport const WALLET_ENTRY_DISCRIMINATOR = 2;\n\nexport function getWalletEntryDiscriminatorBytes() {\n return getU8Encoder().encode(WALLET_ENTRY_DISCRIMINATOR);\n}\n\nexport type WalletEntry = {\n discriminator: number;\n walletAddress: Address;\n listConfig: Address;\n};\n\nexport type WalletEntryArgs = {\n discriminator?: number;\n walletAddress: Address;\n listConfig: Address;\n};\n\nexport function getWalletEntryEncoder(): FixedSizeEncoder<WalletEntryArgs> {\n return transformEncoder(\n getStructEncoder([\n ['discriminator', getU8Encoder()],\n ['walletAddress', getAddressEncoder()],\n ['listConfig', getAddressEncoder()],\n ]),\n (value) => ({\n ...value,\n discriminator: value.discriminator ?? WALLET_ENTRY_DISCRIMINATOR,\n })\n );\n}\n\nexport function getWalletEntryDecoder(): FixedSizeDecoder<WalletEntry> {\n return getStructDecoder([\n ['discriminator', getU8Decoder()],\n ['walletAddress', getAddressDecoder()],\n ['listConfig', getAddressDecoder()],\n ]);\n}\n\nexport function getWalletEntryCodec(): FixedSizeCodec<\n WalletEntryArgs,\n WalletEntry\n> {\n return combineCodec(getWalletEntryEncoder(), getWalletEntryDecoder());\n}\n\nexport function decodeWalletEntry<TAddress extends string = string>(\n encodedAccount: EncodedAccount<TAddress>\n): Account<WalletEntry, TAddress>;\nexport function decodeWalletEntry<TAddress extends string = string>(\n encodedAccount: MaybeEncodedAccount<TAddress>\n): MaybeAccount<WalletEntry, TAddress>;\nexport function decodeWalletEntry<TAddress extends string = string>(\n encodedAccount: EncodedAccount<TAddress> | MaybeEncodedAccount<TAddress>\n): Account<WalletEntry, TAddress> | MaybeAccount<WalletEntry, TAddress> {\n return decodeAccount(\n encodedAccount as MaybeEncodedAccount<TAddress>,\n getWalletEntryDecoder()\n );\n}\n\nexport async function fetchWalletEntry<TAddress extends string = string>(\n rpc: Parameters<typeof fetchEncodedAccount>[0],\n address: Address<TAddress>,\n config?: FetchAccountConfig\n): Promise<Account<WalletEntry, TAddress>> {\n const maybeAccount = await fetchMaybeWalletEntry(rpc, address, config);\n assertAccountExists(maybeAccount);\n return maybeAccount;\n}\n\nexport async function fetchMaybeWalletEntry<TAddress extends string = string>(\n rpc: Parameters<typeof fetchEncodedAccount>[0],\n address: Address<TAddress>,\n config?: FetchAccountConfig\n): Promise<MaybeAccount<WalletEntry, TAddress>> {\n const maybeAccount = await fetchEncodedAccount(rpc, address, config);\n return decodeWalletEntry(maybeAccount);\n}\n\nexport async function fetchAllWalletEntry(\n rpc: Parameters<typeof fetchEncodedAccounts>[0],\n addresses: Array<Address>,\n config?: FetchAccountsConfig\n): Promise<Account<WalletEntry>[]> {\n const maybeAccounts = await fetchAllMaybeWalletEntry(rpc, addresses, config);\n assertAccountsExist(maybeAccounts);\n return maybeAccounts;\n}\n\nexport async function fetchAllMaybeWalletEntry(\n rpc: Parameters<typeof fetchEncodedAccounts>[0],\n addresses: Array<Address>,\n config?: FetchAccountsConfig\n): Promise<MaybeAccount<WalletEntry>[]> {\n const maybeAccounts = await fetchEncodedAccounts(rpc, addresses, config);\n return maybeAccounts.map((maybeAccount) => decodeWalletEntry(maybeAccount));\n}\n\nexport function getWalletEntrySize(): number {\n return 65;\n}\n\nexport async function fetchWalletEntryFromSeeds(\n rpc: Parameters<typeof fetchEncodedAccount>[0],\n seeds: WalletEntrySeeds,\n config: FetchAccountConfig & { programAddress?: Address } = {}\n): Promise<Account<WalletEntry>> {\n const maybeAccount = await fetchMaybeWalletEntryFromSeeds(rpc, seeds, config);\n assertAccountExists(maybeAccount);\n return maybeAccount;\n}\n\nexport async function fetchMaybeWalletEntryFromSeeds(\n rpc: Parameters<typeof fetchEncodedAccount>[0],\n seeds: WalletEntrySeeds,\n config: FetchAccountConfig & { programAddress?: Address } = {}\n): Promise<MaybeAccount<WalletEntry>> {\n const { programAddress, ...fetchConfig } = config;\n const [address] = await findWalletEntryPda(seeds, { programAddress });\n return await fetchMaybeWalletEntry(rpc, address, fetchConfig);\n}\n","/**\n * This code was AUTOGENERATED using the Codama library.\n * Please DO NOT EDIT THIS FILE, instead use visitors\n * to add features, then rerun Codama to update it.\n *\n * @see https://github.com/codama-idl/codama\n */\n\nimport {\n containsBytes,\n getU8Encoder,\n type Address,\n type ReadonlyUint8Array,\n} from '@solana/kit';\nimport {\n type ParsedAddWalletInstruction,\n type ParsedCanFreezePermissionlessInstruction,\n type ParsedCanThawPermissionlessInstruction,\n type ParsedCreateListInstruction,\n type ParsedDeleteListInstruction,\n type ParsedRemoveWalletInstruction,\n type ParsedSetupExtraMetasInstruction,\n type ParsedSetupFreezeExtraMetasInstruction,\n} from '../instructions';\n\nexport const TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS =\n 'GATEzzqxhJnsWF6vHRsgtixxSB8PaQdcqGEVTEHWiULz' as Address<'GATEzzqxhJnsWF6vHRsgtixxSB8PaQdcqGEVTEHWiULz'>;\n\nexport enum TokenAclGateProgramAccount {\n ListConfig,\n WalletEntry,\n}\n\nexport function identifyTokenAclGateProgramAccount(\n account: { data: ReadonlyUint8Array } | ReadonlyUint8Array\n): TokenAclGateProgramAccount {\n const data = 'data' in account ? account.data : account;\n if (containsBytes(data, getU8Encoder().encode(1), 0)) {\n return TokenAclGateProgramAccount.ListConfig;\n }\n if (containsBytes(data, getU8Encoder().encode(2), 0)) {\n return TokenAclGateProgramAccount.WalletEntry;\n }\n throw new Error(\n 'The provided account could not be identified as a tokenAclGateProgram account.'\n );\n}\n\nexport enum TokenAclGateProgramInstruction {\n CreateList,\n AddWallet,\n RemoveWallet,\n SetupExtraMetas,\n DeleteList,\n SetupFreezeExtraMetas,\n CanThawPermissionless,\n CanFreezePermissionless,\n}\n\nexport function identifyTokenAclGateProgramInstruction(\n instruction: { data: ReadonlyUint8Array } | ReadonlyUint8Array\n): TokenAclGateProgramInstruction {\n const data = 'data' in instruction ? instruction.data : instruction;\n if (containsBytes(data, getU8Encoder().encode(1), 0)) {\n return TokenAclGateProgramInstruction.CreateList;\n }\n if (containsBytes(data, getU8Encoder().encode(2), 0)) {\n return TokenAclGateProgramInstruction.AddWallet;\n }\n if (containsBytes(data, getU8Encoder().encode(3), 0)) {\n return TokenAclGateProgramInstruction.RemoveWallet;\n }\n if (containsBytes(data, getU8Encoder().encode(4), 0)) {\n return TokenAclGateProgramInstruction.SetupExtraMetas;\n }\n if (containsBytes(data, getU8Encoder().encode(5), 0)) {\n return TokenAclGateProgramInstruction.DeleteList;\n }\n if (containsBytes(data, getU8Encoder().encode(6), 0)) {\n return TokenAclGateProgramInstruction.SetupFreezeExtraMetas;\n }\n if (containsBytes(data, getU8Encoder().encode(8), 0)) {\n return TokenAclGateProgramInstruction.CanThawPermissionless;\n }\n if (containsBytes(data, getU8Encoder().encode(214), 0)) {\n return TokenAclGateProgramInstruction.CanFreezePermissionless;\n }\n throw new Error(\n 'The provided instruction could not be identified as a tokenAclGateProgram instruction.'\n );\n}\n\nexport type ParsedTokenAclGateProgramInstruction<\n TProgram extends string = 'GATEzzqxhJnsWF6vHRsgtixxSB8PaQdcqGEVTEHWiULz',\n> =\n | ({\n instructionType: TokenAclGateProgramInstruction.CreateList;\n } & ParsedCreateListInstruction<TProgram>)\n | ({\n instructionType: TokenAclGateProgramInstruction.AddWallet;\n } & ParsedAddWalletInstruction<TProgram>)\n | ({\n instructionType: TokenAclGateProgramInstruction.RemoveWallet;\n } & ParsedRemoveWalletInstruction<TProgram>)\n | ({\n instructionType: TokenAclGateProgramInstruction.SetupExtraMetas;\n } & ParsedSetupExtraMetasInstruction<TProgram>)\n | ({\n instructionType: TokenAclGateProgramInstruction.DeleteList;\n } & ParsedDeleteListInstruction<TProgram>)\n | ({\n instructionType: TokenAclGateProgramInstruction.SetupFreezeExtraMetas;\n } & ParsedSetupFreezeExtraMetasInstruction<TProgram>)\n | ({\n instructionType: TokenAclGateProgramInstruction.CanThawPermissionless;\n } & ParsedCanThawPermissionlessInstruction<TProgram>)\n | ({\n instructionType: TokenAclGateProgramInstruction.CanFreezePermissionless;\n } & ParsedCanFreezePermissionlessInstruction<TProgram>);\n","/**\n * This code was AUTOGENERATED using the Codama library.\n * Please DO NOT EDIT THIS FILE, instead use visitors\n * to add features, then rerun Codama to update it.\n *\n * @see https://github.com/codama-idl/codama\n */\n\nimport {\n AccountRole,\n isProgramDerivedAddress,\n isTransactionSigner as kitIsTransactionSigner,\n type AccountMeta,\n type AccountSignerMeta,\n type Address,\n type ProgramDerivedAddress,\n type TransactionSigner,\n upgradeRoleToSigner,\n} from '@solana/kit';\n\n/**\n * Asserts that the given value is not null or undefined.\n * @internal\n */\nexport function expectSome<T>(value: T | null | undefined): T {\n if (value === null || value === undefined) {\n throw new Error('Expected a value but received null or undefined.');\n }\n return value;\n}\n\n/**\n * Asserts that the given value is a PublicKey.\n * @internal\n */\nexport function expectAddress<T extends string = string>(\n value:\n | Address<T>\n | ProgramDerivedAddress<T>\n | TransactionSigner<T>\n | null\n | undefined\n): Address<T> {\n if (!value) {\n throw new Error('Expected a Address.');\n }\n if (typeof value === 'object' && 'address' in value) {\n return value.address;\n }\n if (Array.isArray(value)) {\n return value[0] as Address<T>;\n }\n return value as Address<T>;\n}\n\n/**\n * Asserts that the given value is a PDA.\n * @internal\n */\nexport function expectProgramDerivedAddress<T extends string = string>(\n value:\n | Address<T>\n | ProgramDerivedAddress<T>\n | TransactionSigner<T>\n | null\n | undefined\n): ProgramDerivedAddress<T> {\n if (!value || !Array.isArray(value) || !isProgramDerivedAddress(value)) {\n throw new Error('Expected a ProgramDerivedAddress.');\n }\n return value;\n}\n\n/**\n * Asserts that the given value is a TransactionSigner.\n * @internal\n */\nexport function expectTransactionSigner<T extends string = string>(\n value:\n | Address<T>\n | ProgramDerivedAddress<T>\n | TransactionSigner<T>\n | null\n | undefined\n): TransactionSigner<T> {\n if (!value || !isTransactionSigner(value)) {\n throw new Error('Expected a TransactionSigner.');\n }\n return value;\n}\n\n/**\n * Defines an instruction account to resolve.\n * @internal\n */\nexport type ResolvedAccount<\n T extends string = string,\n U extends\n | Address<T>\n | ProgramDerivedAddress<T>\n | TransactionSigner<T>\n | null =\n | Address<T>\n | ProgramDerivedAddress<T>\n | TransactionSigner<T>\n | null,\n> = {\n isWritable: boolean;\n value: U;\n};\n\n/**\n * Defines an instruction that stores additional bytes on-chain.\n * @internal\n */\nexport type InstructionWithByteDelta = {\n byteDelta: number;\n};\n\n/**\n * Get account metas and signers from resolved accounts.\n * @internal\n */\nexport function getAccountMetaFactory(\n programAddress: Address,\n optionalAccountStrategy: 'omitted' | 'programId'\n) {\n return (\n account: ResolvedAccount\n ): AccountMeta | AccountSignerMeta | undefined => {\n if (!account.value) {\n if (optionalAccountStrategy === 'omitted') return;\n return Object.freeze({\n address: programAddress,\n role: AccountRole.READONLY,\n });\n }\n\n const writableRole = account.isWritable\n ? AccountRole.WRITABLE\n : AccountRole.READONLY;\n return Object.freeze({\n address: expectAddress(account.value),\n role: isTransactionSigner(account.value)\n ? upgradeRoleToSigner(writableRole)\n : writableRole,\n ...(isTransactionSigner(account.value) ? { signer: account.value } : {}),\n });\n };\n}\n\nexport function isTransactionSigner<TAddress extends string = string>(\n value:\n | Address<TAddress>\n | ProgramDerivedAddress<TAddress>\n | TransactionSigner<TAddress>\n): value is TransactionSigner<TAddress> {\n return (\n !!value &&\n typeof value === 'object' &&\n 'address' in value &&\n kitIsTransactionSigner(value)\n );\n}\n","/**\n * This code was AUTOGENERATED using the Codama library.\n * Please DO NOT EDIT THIS FILE, instead use visitors\n * to add features, then rerun Codama to update it.\n *\n * @see https://github.com/codama-idl/codama\n */\n\nimport {\n combineCodec,\n getStructDecoder,\n getStructEncoder,\n getU8Decoder,\n getU8Encoder,\n transformEncoder,\n type AccountMeta,\n type AccountSignerMeta,\n type Address,\n type FixedSizeCodec,\n type FixedSizeDecoder,\n type FixedSizeEncoder,\n type Instruction,\n type InstructionWithAccounts,\n type InstructionWithData,\n type ReadonlyAccount,\n type ReadonlySignerAccount,\n type ReadonlyUint8Array,\n type TransactionSigner,\n type WritableAccount,\n type WritableSignerAccount,\n} from '@solana/kit';\nimport { TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS } from '../programs';\nimport { getAccountMetaFactory, type ResolvedAccount } from '../shared';\n\nexport const ADD_WALLET_DISCRIMINATOR = 2;\n\nexport function getAddWalletDiscriminatorBytes() {\n return getU8Encoder().encode(ADD_WALLET_DISCRIMINATOR);\n}\n\nexport type AddWalletInstruction<\n TProgram extends string = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n TAccountAuthority extends string | AccountMeta<string> = string,\n TAccountPayer extends string | AccountMeta<string> = string,\n TAccountListConfig extends string | AccountMeta<string> = string,\n TAccountWallet extends string | AccountMeta<string> = string,\n TAccountWalletEntry extends string | AccountMeta<string> = string,\n TAccountSystemProgram extends\n | string\n | AccountMeta<string> = '11111111111111111111111111111111',\n TRemainingAccounts extends readonly AccountMeta<string>[] = [],\n> = Instruction<TProgram> &\n InstructionWithData<ReadonlyUint8Array> &\n InstructionWithAccounts<\n [\n TAccountAuthority extends string\n ? ReadonlySignerAccount<TAccountAuthority> &\n AccountSignerMeta<TAccountAuthority>\n : TAccountAuthority,\n TAccountPayer extends string\n ? WritableSignerAccount<TAccountPayer> &\n AccountSignerMeta<TAccountPayer>\n : TAccountPayer,\n TAccountListConfig extends string\n ? WritableAccount<TAccountListConfig>\n : TAccountListConfig,\n TAccountWallet extends string\n ? ReadonlyAccount<TAccountWallet>\n : TAccountWallet,\n TAccountWalletEntry extends string\n ? WritableAccount<TAccountWalletEntry>\n : TAccountWalletEntry,\n TAccountSystemProgram extends string\n ? ReadonlyAccount<TAccountSystemProgram>\n : TAccountSystemProgram,\n ...TRemainingAccounts,\n ]\n >;\n\nexport type AddWalletInstructionData = { discriminator: number };\n\nexport type AddWalletInstructionDataArgs = {};\n\nexport function getAddWalletInstructionDataEncoder(): FixedSizeEncoder<AddWalletInstructionDataArgs> {\n return transformEncoder(\n getStructEncoder([['discriminator', getU8Encoder()]]),\n (value) => ({ ...value, discriminator: ADD_WALLET_DISCRIMINATOR })\n );\n}\n\nexport function getAddWalletInstructionDataDecoder(): FixedSizeDecoder<AddWalletInstructionData> {\n return getStructDecoder([['discriminator', getU8Decoder()]]);\n}\n\nexport function getAddWalletInstructionDataCodec(): FixedSizeCodec<\n AddWalletInstructionDataArgs,\n AddWalletInstructionData\n> {\n return combineCodec(\n getAddWalletInstructionDataEncoder(),\n getAddWalletInstructionDataDecoder()\n );\n}\n\nexport type AddWalletInput<\n TAccountAuthority extends string = string,\n TAccountPayer extends string = string,\n TAccountListConfig extends string = string,\n TAccountWallet extends string = string,\n TAccountWalletEntry extends string = string,\n TAccountSystemProgram extends string = string,\n> = {\n authority: TransactionSigner<TAccountAuthority>;\n payer: TransactionSigner<TAccountPayer>;\n listConfig: Address<TAccountListConfig>;\n wallet: Address<TAccountWallet>;\n walletEntry: Address<TAccountWalletEntry>;\n systemProgram?: Address<TAccountSystemProgram>;\n};\n\nexport function getAddWalletInstruction<\n TAccountAuthority extends string,\n TAccountPayer extends string,\n TAccountListConfig extends string,\n TAccountWallet extends string,\n TAccountWalletEntry extends string,\n TAccountSystemProgram extends string,\n TProgramAddress extends\n Address = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n>(\n input: AddWalletInput<\n TAccountAuthority,\n TAccountPayer,\n TAccountListConfig,\n TAccountWallet,\n TAccountWalletEntry,\n TAccountSystemProgram\n >,\n config?: { programAddress?: TProgramAddress }\n): AddWalletInstruction<\n TProgramAddress,\n TAccountAuthority,\n TAccountPayer,\n TAccountListConfig,\n TAccountWallet,\n TAccountWalletEntry,\n TAccountSystemProgram\n> {\n // Program address.\n const programAddress =\n config?.programAddress ?? TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS;\n\n // Original accounts.\n const originalAccounts = {\n authority: { value: input.authority ?? null, isWritable: false },\n payer: { value: input.payer ?? null, isWritable: true },\n listConfig: { value: input.listConfig ?? null, isWritable: true },\n wallet: { value: input.wallet ?? null, isWritable: false },\n walletEntry: { value: input.walletEntry ?? null, isWritable: true },\n systemProgram: { value: input.systemProgram ?? null, isWritable: false },\n };\n const accounts = originalAccounts as Record<\n keyof typeof originalAccounts,\n ResolvedAccount\n >;\n\n // Resolve default values.\n if (!accounts.systemProgram.value) {\n accounts.systemProgram.value =\n '11111111111111111111111111111111' as Address<'11111111111111111111111111111111'>;\n }\n\n const getAccountMeta = getAccountMetaFactory(programAddress, 'programId');\n return Object.freeze({\n accounts: [\n getAccountMeta(accounts.authority),\n getAccountMeta(accounts.payer),\n getAccountMeta(accounts.listConfig),\n getAccountMeta(accounts.wallet),\n getAccountMeta(accounts.walletEntry),\n getAccountMeta(accounts.systemProgram),\n ],\n data: getAddWalletInstructionDataEncoder().encode({}),\n programAddress,\n } as AddWalletInstruction<\n TProgramAddress,\n TAccountAuthority,\n TAccountPayer,\n TAccountListConfig,\n TAccountWallet,\n TAccountWalletEntry,\n TAccountSystemProgram\n >);\n}\n\nexport type ParsedAddWalletInstruction<\n TProgram extends string = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n TAccountMetas extends readonly AccountMeta[] = readonly AccountMeta[],\n> = {\n programAddress: Address<TProgram>;\n accounts: {\n authority: TAccountMetas[0];\n payer: TAccountMetas[1];\n listConfig: TAccountMetas[2];\n wallet: TAccountMetas[3];\n walletEntry: TAccountMetas[4];\n systemProgram: TAccountMetas[5];\n };\n data: AddWalletInstructionData;\n};\n\nexport function parseAddWalletInstruction<\n TProgram extends string,\n TAccountMetas extends readonly AccountMeta[],\n>(\n instruction: Instruction<TProgram> &\n InstructionWithAccounts<TAccountMetas> &\n InstructionWithData<ReadonlyUint8Array>\n): ParsedAddWalletInstruction<TProgram, TAccountMetas> {\n if (instruction.accounts.length < 6) {\n // TODO: Coded error.\n throw new Error('Not enough accounts');\n }\n let accountIndex = 0;\n const getNextAccount = () => {\n const accountMeta = (instruction.accounts as TAccountMetas)[accountIndex]!;\n accountIndex += 1;\n return accountMeta;\n };\n return {\n programAddress: instruction.programAddress,\n accounts: {\n authority: getNextAccount(),\n payer: getNextAccount(),\n listConfig: getNextAccount(),\n wallet: getNextAccount(),\n walletEntry: getNextAccount(),\n systemProgram: getNextAccount(),\n },\n data: getAddWalletInstructionDataDecoder().decode(instruction.data),\n };\n}\n","/**\n * This code was AUTOGENERATED using the Codama library.\n * Please DO NOT EDIT THIS FILE, instead use visitors\n * to add features, then rerun Codama to update it.\n *\n * @see https://github.com/codama-idl/codama\n */\n\nimport {\n combineCodec,\n getStructDecoder,\n getStructEncoder,\n getU8Decoder,\n getU8Encoder,\n transformEncoder,\n type AccountMeta,\n type AccountSignerMeta,\n type Address,\n type FixedSizeCodec,\n type FixedSizeDecoder,\n type FixedSizeEncoder,\n type Instruction,\n type InstructionWithAccounts,\n type InstructionWithData,\n type ReadonlyAccount,\n type ReadonlySignerAccount,\n type ReadonlyUint8Array,\n type TransactionSigner,\n} from '@solana/kit';\nimport { TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS } from '../programs';\nimport { getAccountMetaFactory, type ResolvedAccount } from '../shared';\n\nexport const CAN_FREEZE_PERMISSIONLESS_DISCRIMINATOR = 214;\n\nexport function getCanFreezePermissionlessDiscriminatorBytes() {\n return getU8Encoder().encode(CAN_FREEZE_PERMISSIONLESS_DISCRIMINATOR);\n}\n\nexport type CanFreezePermissionlessInstruction<\n TProgram extends string = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n TAccountAuthority extends string | AccountMeta<string> = string,\n TAccountTokenAccount extends string | AccountMeta<string> = string,\n TAccountMint extends string | AccountMeta<string> = string,\n TAccountOwner extends string | AccountMeta<string> = string,\n TAccountFlagAccount extends string | AccountMeta<string> = string,\n TAccountExtraMetas extends string | AccountMeta<string> = string,\n TRemainingAccounts extends readonly AccountMeta<string>[] = [],\n> = Instruction<TProgram> &\n InstructionWithData<ReadonlyUint8Array> &\n InstructionWithAccounts<\n [\n TAccountAuthority extends string\n ? ReadonlySignerAccount<TAccountAuthority> &\n AccountSignerMeta<TAccountAuthority>\n : TAccountAuthority,\n TAccountTokenAccount extends string\n ? ReadonlyAccount<TAccountTokenAccount>\n : TAccountTokenAccount,\n TAccountMint extends string\n ? ReadonlyAccount<TAccountMint>\n : TAccountMint,\n TAccountOwner extends string\n ? ReadonlyAccount<TAccountOwner>\n : TAccountOwner,\n TAccountFlagAccount extends string\n ? ReadonlyAccount<TAccountFlagAccount>\n : TAccountFlagAccount,\n TAccountExtraMetas extends string\n ? ReadonlyAccount<TAccountExtraMetas>\n : TAccountExtraMetas,\n ...TRemainingAccounts,\n ]\n >;\n\nexport type CanFreezePermissionlessInstructionData = { discriminator: number };\n\nexport type CanFreezePermissionlessInstructionDataArgs = {};\n\nexport function getCanFreezePermissionlessInstructionDataEncoder(): FixedSizeEncoder<CanFreezePermissionlessInstructionDataArgs> {\n return transformEncoder(\n getStructEncoder([['discriminator', getU8Encoder()]]),\n (value) => ({\n ...value,\n discriminator: CAN_FREEZE_PERMISSIONLESS_DISCRIMINATOR,\n })\n );\n}\n\nexport function getCanFreezePermissionlessInstructionDataDecoder(): FixedSizeDecoder<CanFreezePermissionlessInstructionData> {\n return getStructDecoder([['discriminator', getU8Decoder()]]);\n}\n\nexport function getCanFreezePermissionlessInstructionDataCodec(): FixedSizeCodec<\n CanFreezePermissionlessInstructionDataArgs,\n CanFreezePermissionlessInstructionData\n> {\n return combineCodec(\n getCanFreezePermissionlessInstructionDataEncoder(),\n getCanFreezePermissionlessInstructionDataDecoder()\n );\n}\n\nexport type CanFreezePermissionlessInput<\n TAccountAuthority extends string = string,\n TAccountTokenAccount extends string = string,\n TAccountMint extends string = string,\n TAccountOwner extends string = string,\n TAccountFlagAccount extends string = string,\n TAccountExtraMetas extends string = string,\n> = {\n authority: TransactionSigner<TAccountAuthority>;\n tokenAccount: Address<TAccountTokenAccount>;\n mint: Address<TAccountMint>;\n owner: Address<TAccountOwner>;\n flagAccount: Address<TAccountFlagAccount>;\n extraMetas: Address<TAccountExtraMetas>;\n};\n\nexport function getCanFreezePermissionlessInstruction<\n TAccountAuthority extends string,\n TAccountTokenAccount extends string,\n TAccountMint extends string,\n TAccountOwner extends string,\n TAccountFlagAccount extends string,\n TAccountExtraMetas extends string,\n TProgramAddress extends\n Address = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n>(\n input: CanFreezePermissionlessInput<\n TAccountAuthority,\n TAccountTokenAccount,\n TAccountMint,\n TAccountOwner,\n TAccountFlagAccount,\n TAccountExtraMetas\n >,\n config?: { programAddress?: TProgramAddress }\n): CanFreezePermissionlessInstruction<\n TProgramAddress,\n TAccountAuthority,\n TAccountTokenAccount,\n TAccountMint,\n TAccountOwner,\n TAccountFlagAccount,\n TAccountExtraMetas\n> {\n // Program address.\n const programAddress =\n config?.programAddress ?? TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS;\n\n // Original accounts.\n const originalAccounts = {\n authority: { value: input.authority ?? null, isWritable: false },\n tokenAccount: { value: input.tokenAccount ?? null, isWritable: false },\n mint: { value: input.mint ?? null, isWritable: false },\n owner: { value: input.owner ?? null, isWritable: false },\n flagAccount: { value: input.flagAccount ?? null, isWritable: false },\n extraMetas: { value: input.extraMetas ?? null, isWritable: false },\n };\n const accounts = originalAccounts as Record<\n keyof typeof originalAccounts,\n ResolvedAccount\n >;\n\n const getAccountMeta = getAccountMetaFactory(programAddress, 'programId');\n return Object.freeze({\n accounts: [\n getAccountMeta(accounts.authority),\n getAccountMeta(accounts.tokenAccount),\n getAccountMeta(accounts.mint),\n getAccountMeta(accounts.owner),\n getAccountMeta(accounts.flagAccount),\n getAccountMeta(accounts.extraMetas),\n ],\n data: getCanFreezePermissionlessInstructionDataEncoder().encode({}),\n programAddress,\n } as CanFreezePermissionlessInstruction<\n TProgramAddress,\n TAccountAuthority,\n TAccountTokenAccount,\n TAccountMint,\n TAccountOwner,\n TAccountFlagAccount,\n TAccountExtraMetas\n >);\n}\n\nexport type ParsedCanFreezePermissionlessInstruction<\n TProgram extends string = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n TAccountMetas extends readonly AccountMeta[] = readonly AccountMeta[],\n> = {\n programAddress: Address<TProgram>;\n accounts: {\n authority: TAccountMetas[0];\n tokenAccount: TAccountMetas[1];\n mint: TAccountMetas[2];\n owner: TAccountMetas[3];\n flagAccount: TAccountMetas[4];\n extraMetas: TAccountMetas[5];\n };\n data: CanFreezePermissionlessInstructionData;\n};\n\nexport function parseCanFreezePermissionlessInstruction<\n TProgram extends string,\n TAccountMetas extends readonly AccountMeta[],\n>(\n instruction: Instruction<TProgram> &\n InstructionWithAccounts<TAccountMetas> &\n InstructionWithData<ReadonlyUint8Array>\n): ParsedCanFreezePermissionlessInstruction<TProgram, TAccountMetas> {\n if (instruction.accounts.length < 6) {\n // TODO: Coded error.\n throw new Error('Not enough accounts');\n }\n let accountIndex = 0;\n const getNextAccount = () => {\n const accountMeta = (instruction.accounts as TAccountMetas)[accountIndex]!;\n accountIndex += 1;\n return accountMeta;\n };\n return {\n programAddress: instruction.programAddress,\n accounts: {\n authority: getNextAccount(),\n tokenAccount: getNextAccount(),\n mint: getNextAccount(),\n owner: getNextAccount(),\n flagAccount: getNextAccount(),\n extraMetas: getNextAccount(),\n },\n data: getCanFreezePermissionlessInstructionDataDecoder().decode(\n instruction.data\n ),\n };\n}\n","/**\n * This code was AUTOGENERATED using the Codama library.\n * Please DO NOT EDIT THIS FILE, instead use visitors\n * to add features, then rerun Codama to update it.\n *\n * @see https://github.com/codama-idl/codama\n */\n\nimport {\n AccountRole,\n combineCodec,\n getStructDecoder,\n getStructEncoder,\n getU8Decoder,\n getU8Encoder,\n transformEncoder,\n type AccountMeta,\n type AccountSignerMeta,\n type Address,\n type FixedSizeCodec,\n type FixedSizeDecoder,\n type FixedSizeEncoder,\n type Instruction,\n type InstructionWithAccounts,\n type InstructionWithData,\n type ReadonlyAccount,\n type ReadonlySignerAccount,\n type ReadonlyUint8Array,\n type TransactionSigner,\n} from '@solana/kit';\nimport { TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS } from '../programs';\nimport { getAccountMetaFactory, type ResolvedAccount } from '../shared';\n\nexport const CAN_THAW_PERMISSIONLESS_DISCRIMINATOR = 8;\n\nexport function getCanThawPermissionlessDiscriminatorBytes() {\n return getU8Encoder().encode(CAN_THAW_PERMISSIONLESS_DISCRIMINATOR);\n}\n\nexport type CanThawPermissionlessInstruction<\n TProgram extends string = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n TAccountAuthority extends string | AccountMeta<string> = string,\n TAccountTokenAccount extends string | AccountMeta<string> = string,\n TAccountMint extends string | AccountMeta<string> = string,\n TAccountOwner extends string | AccountMeta<string> = string,\n TAccountFlagAccount extends string | AccountMeta<string> = string,\n TAccountExtraMetas extends string | AccountMeta<string> = string,\n TRemainingAccounts extends readonly AccountMeta<string>[] = [],\n> = Instruction<TProgram> &\n InstructionWithData<ReadonlyUint8Array> &\n InstructionWithAccounts<\n [\n TAccountAuthority extends string\n ? ReadonlySignerAccount<TAccountAuthority> &\n AccountSignerMeta<TAccountAuthority>\n : TAccountAuthority,\n TAccountTokenAccount extends string\n ? ReadonlyAccount<TAccountTokenAccount>\n : TAccountTokenAccount,\n TAccountMint extends string\n ? ReadonlyAccount<TAccountMint>\n : TAccountMint,\n TAccountOwner extends string\n ? ReadonlyAccount<TAccountOwner>\n : TAccountOwner,\n TAccountFlagAccount extends string\n ? ReadonlyAccount<TAccountFlagAccount>\n : TAccountFlagAccount,\n TAccountExtraMetas extends string\n ? ReadonlyAccount<TAccountExtraMetas>\n : TAccountExtraMetas,\n ...TRemainingAccounts,\n ]\n >;\n\nexport type CanThawPermissionlessInstructionData = { discriminator: number };\n\nexport type CanThawPermissionlessInstructionDataArgs = {};\n\nexport function getCanThawPermissionlessInstructionDataEncoder(): FixedSizeEncoder<CanThawPermissionlessInstructionDataArgs> {\n return transformEncoder(\n getStructEncoder([['discriminator', getU8Encoder()]]),\n (value) => ({\n ...value,\n discriminator: CAN_THAW_PERMISSIONLESS_DISCRIMINATOR,\n })\n );\n}\n\nexport function getCanThawPermissionlessInstructionDataDecoder(): FixedSizeDecoder<CanThawPermissionlessInstructionData> {\n return getStructDecoder([['discriminator', getU8Decoder()]]);\n}\n\nexport function getCanThawPermissionlessInstructionDataCodec(): FixedSizeCodec<\n CanThawPermissionlessInstructionDataArgs,\n CanThawPermissionlessInstructionData\n> {\n return combineCodec(\n getCanThawPermissionlessInstructionDataEncoder(),\n getCanThawPermissionlessInstructionDataDecoder()\n );\n}\n\nexport type CanThawPermissionlessInstructionExtraArgs = {\n /** Pairs of (ListConfig, WalletEntry) accounts. Must be passed as a flattened array. */\n addresses: Array<Address>;\n};\n\nexport type CanThawPermissionlessInput<\n TAccountAuthority extends string = string,\n TAccountTokenAccount extends string = string,\n TAccountMint extends string = string,\n TAccountOwner extends string = string,\n TAccountFlagAccount extends string = string,\n TAccountExtraMetas extends string = string,\n> = {\n authority: TransactionSigner<TAccountAuthority>;\n tokenAccount: Address<TAccountTokenAccount>;\n mint: Address<TAccountMint>;\n owner: Address<TAccountOwner>;\n flagAccount: Address<TAccountFlagAccount>;\n extraMetas: Address<TAccountExtraMetas>;\n addresses: CanThawPermissionlessInstructionExtraArgs['addresses'];\n};\n\nexport function getCanThawPermissionlessInstruction<\n TAccountAuthority extends string,\n TAccountTokenAccount extends string,\n TAccountMint extends string,\n TAccountOwner extends string,\n TAccountFlagAccount extends string,\n TAccountExtraMetas extends string,\n TProgramAddress extends\n Address = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n>(\n input: CanThawPermissionlessInput<\n TAccountAuthority,\n TAccountTokenAccount,\n TAccountMint,\n TAccountOwner,\n TAccountFlagAccount,\n TAccountExtraMetas\n >,\n config?: { programAddress?: TProgramAddress }\n): CanThawPermissionlessInstruction<\n TProgramAddress,\n TAccountAuthority,\n TAccountTokenAccount,\n TAccountMint,\n TAccountOwner,\n TAccountFlagAccount,\n TAccountExtraMetas\n> {\n // Program address.\n const programAddress =\n config?.programAddress ?? TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS;\n\n // Original accounts.\n const originalAccounts = {\n authority: { value: input.authority ?? null, isWritable: false },\n tokenAccount: { value: input.tokenAccount ?? null, isWritable: false },\n mint: { value: input.mint ?? null, isWritable: false },\n owner: { value: input.owner ?? null, isWritable: false },\n flagAccount: { value: input.flagAccount ?? null, isWritable: false },\n extraMetas: { value: input.extraMetas ?? null, isWritable: false },\n };\n const accounts = originalAccounts as Record<\n keyof typeof originalAccounts,\n ResolvedAccount\n >;\n\n // Original args.\n const args = { ...input };\n\n // Remaining accounts.\n const remainingAccounts: AccountMeta[] = args.addresses.map((address) => ({\n address,\n role: AccountRole.READONLY,\n }));\n\n const getAccountMeta = getAccountMetaFactory(programAddress, 'programId');\n return Object.freeze({\n accounts: [\n getAccountMeta(accounts.authority),\n getAccountMeta(accounts.tokenAccount),\n getAccountMeta(accounts.mint),\n getAccountMeta(accounts.owner),\n getAccountMeta(accounts.flagAccount),\n getAccountMeta(accounts.extraMetas),\n ...remainingAccounts,\n ],\n data: getCanThawPermissionlessInstructionDataEncoder().encode({}),\n programAddress,\n } as CanThawPermissionlessInstruction<\n TProgramAddress,\n TAccountAuthority,\n TAccountTokenAccount,\n TAccountMint,\n TAccountOwner,\n TAccountFlagAccount,\n TAccountExtraMetas\n >);\n}\n\nexport type ParsedCanThawPermissionlessInstruction<\n TProgram extends string = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n TAccountMetas extends readonly AccountMeta[] = readonly AccountMeta[],\n> = {\n programAddress: Address<TProgram>;\n accounts: {\n authority: TAccountMetas[0];\n tokenAccount: TAccountMetas[1];\n mint: TAccountMetas[2];\n owner: TAccountMetas[3];\n flagAccount: TAccountMetas[4];\n extraMetas: TAccountMetas[5];\n };\n data: CanThawPermissionlessInstructionData;\n};\n\nexport function parseCanThawPermissionlessInstruction<\n TProgram extends string,\n TAccountMetas extends readonly AccountMeta[],\n>(\n instruction: Instruction<TProgram> &\n InstructionWithAccounts<TAccountMetas> &\n InstructionWithData<ReadonlyUint8Array>\n): ParsedCanThawPermissionlessInstruction<TProgram, TAccountMetas> {\n if (instruction.accounts.length < 6) {\n // TODO: Coded error.\n throw new Error('Not enough accounts');\n }\n let accountIndex = 0;\n const getNextAccount = () => {\n const accountMeta = (instruction.accounts as TAccountMetas)[accountIndex]!;\n accountIndex += 1;\n return accountMeta;\n };\n return {\n programAddress: instruction.programAddress,\n accounts: {\n authority: getNextAccount(),\n tokenAccount: getNextAccount(),\n mint: getNextAccount(),\n owner: getNextAccount(),\n flagAccount: getNextAccount(),\n extraMetas: getNextAccount(),\n },\n data: getCanThawPermissionlessInstructionDataDecoder().decode(\n instruction.data\n ),\n };\n}\n","/**\n * This code was AUTOGENERATED using the Codama library.\n * Please DO NOT EDIT THIS FILE, instead use visitors\n * to add features, then rerun Codama to update it.\n *\n * @see https://github.com/codama-idl/codama\n */\n\nimport {\n combineCodec,\n getEnumDecoder,\n getEnumEncoder,\n type FixedSizeCodec,\n type FixedSizeDecoder,\n type FixedSizeEncoder,\n} from '@solana/kit';\n\nexport enum Mode {\n Allow,\n Unused,\n Block,\n}\n\nexport type ModeArgs = Mode;\n\nexport function getModeEncoder(): FixedSizeEncoder<ModeArgs> {\n return getEnumEncoder(Mode);\n}\n\nexport function getModeDecoder(): FixedSizeDecoder<Mode> {\n return getEnumDecoder(Mode);\n}\n\nexport function getModeCodec(): FixedSizeCodec<ModeArgs, Mode> {\n return combineCodec(getModeEncoder(), getModeDecoder());\n}\n","/**\n * This code was AUTOGENERATED using the Codama library.\n * Please DO NOT EDIT THIS FILE, instead use visitors\n * to add features, then rerun Codama to update it.\n *\n * @see https://github.com/codama-idl/codama\n */\n\nimport {\n combineCodec,\n getAddressDecoder,\n getAddressEncoder,\n getStructDecoder,\n getStructEncoder,\n getU8Decoder,\n getU8Encoder,\n transformEncoder,\n type AccountMeta,\n type AccountSignerMeta,\n type Address,\n type FixedSizeCodec,\n type FixedSizeDecoder,\n type FixedSizeEncoder,\n type Instruction,\n type InstructionWithAccounts,\n type InstructionWithData,\n type ReadonlyAccount,\n type ReadonlySignerAccount,\n type ReadonlyUint8Array,\n type TransactionSigner,\n type WritableAccount,\n type WritableSignerAccount,\n} from '@solana/kit';\nimport { TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS } from '../programs';\nimport { getAccountMetaFactory, type ResolvedAccount } from '../shared';\nimport {\n getModeDecoder,\n getModeEncoder,\n type Mode,\n type ModeArgs,\n} from '../types';\n\nexport const CREATE_LIST_DISCRIMINATOR = 1;\n\nexport function getCreateListDiscriminatorBytes() {\n return getU8Encoder().encode(CREATE_LIST_DISCRIMINATOR);\n}\n\nexport type CreateListInstruction<\n TProgram extends string = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n TAccountAuthority extends string | AccountMeta<string> = string,\n TAccountPayer extends string | AccountMeta<string> = string,\n TAccountListConfig extends string | AccountMeta<string> = string,\n TAccountSystemProgram extends\n | string\n | AccountMeta<string> = '11111111111111111111111111111111',\n TRemainingAccounts extends readonly AccountMeta<string>[] = [],\n> = Instruction<TProgram> &\n InstructionWithData<ReadonlyUint8Array> &\n InstructionWithAccounts<\n [\n TAccountAuthority extends string\n ? ReadonlySignerAccount<TAccountAuthority> &\n AccountSignerMeta<TAccountAuthority>\n : TAccountAuthority,\n TAccountPayer extends string\n ? WritableSignerAccount<TAccountPayer> &\n AccountSignerMeta<TAccountPayer>\n : TAccountPayer,\n TAccountListConfig extends string\n ? WritableAccount<TAccountListConfig>\n : TAccountListConfig,\n TAccountSystemProgram extends string\n ? ReadonlyAccount<TAccountSystemProgram>\n : TAccountSystemProgram,\n ...TRemainingAccounts,\n ]\n >;\n\nexport type CreateListInstructionData = {\n discriminator: number;\n mode: Mode;\n seed: Address;\n};\n\nexport type CreateListInstructionDataArgs = { mode: ModeArgs; seed: Address };\n\nexport function getCreateListInstructionDataEncoder(): FixedSizeEncoder<CreateListInstructionDataArgs> {\n return transformEncoder(\n getStructEncoder([\n ['discriminator', getU8Encoder()],\n ['mode', getModeEncoder()],\n ['seed', getAddressEncoder()],\n ]),\n (value) => ({ ...value, discriminator: CREATE_LIST_DISCRIMINATOR })\n );\n}\n\nexport function getCreateListInstructionDataDecoder(): FixedSizeDecoder<CreateListInstructionData> {\n return getStructDecoder([\n ['discriminator', getU8Decoder()],\n ['mode', getModeDecoder()],\n ['seed', getAddressDecoder()],\n ]);\n}\n\nexport function getCreateListInstructionDataCodec(): FixedSizeCodec<\n CreateListInstructionDataArgs,\n CreateListInstructionData\n> {\n return combineCodec(\n getCreateListInstructionDataEncoder(),\n getCreateListInstructionDataDecoder()\n );\n}\n\nexport type CreateListInput<\n TAccountAuthority extends string = string,\n TAccountPayer extends string = string,\n TAccountListConfig extends string = string,\n TAccountSystemProgram extends string = string,\n> = {\n authority: TransactionSigner<TAccountAuthority>;\n payer: TransactionSigner<TAccountPayer>;\n listConfig: Address<TAccountListConfig>;\n systemProgram?: Address<TAccountSystemProgram>;\n mode: CreateListInstructionDataArgs['mode'];\n seed: CreateListInstructionDataArgs['seed'];\n};\n\nexport function getCreateListInstruction<\n TAccountAuthority extends string,\n TAccountPayer extends string,\n TAccountListConfig extends string,\n TAccountSystemProgram extends string,\n TProgramAddress extends\n Address = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n>(\n input: CreateListInput<\n TAccountAuthority,\n TAccountPayer,\n TAccountListConfig,\n TAccountSystemProgram\n >,\n config?: { programAddress?: TProgramAddress }\n): CreateListInstruction<\n TProgramAddress,\n TAccountAuthority,\n TAccountPayer,\n TAccountListConfig,\n TAccountSystemProgram\n> {\n // Program address.\n const programAddress =\n config?.programAddress ?? TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS;\n\n // Original accounts.\n const originalAccounts = {\n authority: { value: input.authority ?? null, isWritable: false },\n payer: { value: input.payer ?? null, isWritable: true },\n listConfig: { value: input.listConfig ?? null, isWritable: true },\n systemProgram: { value: input.systemProgram ?? null, isWritable: false },\n };\n const accounts = originalAccounts as Record<\n keyof typeof originalAccounts,\n ResolvedAccount\n >;\n\n // Original args.\n const args = { ...input };\n\n // Resolve default values.\n if (!accounts.systemProgram.value) {\n accounts.systemProgram.value =\n '11111111111111111111111111111111' as Address<'11111111111111111111111111111111'>;\n }\n\n const getAccountMeta = getAccountMetaFactory(programAddress, 'programId');\n return Object.freeze({\n accounts: [\n getAccountMeta(accounts.authority),\n getAccountMeta(accounts.payer),\n getAccountMeta(accounts.listConfig),\n getAccountMeta(accounts.systemProgram),\n ],\n data: getCreateListInstructionDataEncoder().encode(\n args as CreateListInstructionDataArgs\n ),\n programAddress,\n } as CreateListInstruction<\n TProgramAddress,\n TAccountAuthority,\n TAccountPayer,\n TAccountListConfig,\n TAccountSystemProgram\n >);\n}\n\nexport type ParsedCreateListInstruction<\n TProgram extends string = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n TAccountMetas extends readonly AccountMeta[] = readonly AccountMeta[],\n> = {\n programAddress: Address<TProgram>;\n accounts: {\n authority: TAccountMetas[0];\n payer: TAccountMetas[1];\n listConfig: TAccountMetas[2];\n systemProgram: TAccountMetas[3];\n };\n data: CreateListInstructionData;\n};\n\nexport function parseCreateListInstruction<\n TProgram extends string,\n TAccountMetas extends readonly AccountMeta[],\n>(\n instruction: Instruction<TProgram> &\n InstructionWithAccounts<TAccountMetas> &\n InstructionWithData<ReadonlyUint8Array>\n): ParsedCreateListInstruction<TProgram, TAccountMetas> {\n if (instruction.accounts.length < 4) {\n // TODO: Coded error.\n throw new Error('Not enough accounts');\n }\n let accountIndex = 0;\n const getNextAccount = () => {\n const accountMeta = (instruction.accounts as TAccountMetas)[accountIndex]!;\n accountIndex += 1;\n return accountMeta;\n };\n return {\n programAddress: instruction.programAddress,\n accounts: {\n authority: getNextAccount(),\n payer: getNextAccount(),\n listConfig: getNextAccount(),\n systemProgram: getNextAccount(),\n },\n data: getCreateListInstructionDataDecoder().decode(instruction.data),\n };\n}\n","/**\n * This code was AUTOGENERATED using the Codama library.\n * Please DO NOT EDIT THIS FILE, instead use visitors\n * to add features, then rerun Codama to update it.\n *\n * @see https://github.com/codama-idl/codama\n */\n\nimport {\n combineCodec,\n getStructDecoder,\n getStructEncoder,\n getU8Decoder,\n getU8Encoder,\n transformEncoder,\n type AccountMeta,\n type AccountSignerMeta,\n type Address,\n type FixedSizeCodec,\n type FixedSizeDecoder,\n type FixedSizeEncoder,\n type Instruction,\n type InstructionWithAccounts,\n type InstructionWithData,\n type ReadonlyUint8Array,\n type TransactionSigner,\n type WritableAccount,\n type WritableSignerAccount,\n} from '@solana/kit';\nimport { TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS } from '../programs';\nimport { getAccountMetaFactory, type ResolvedAccount } from '../shared';\n\nexport const DELETE_LIST_DISCRIMINATOR = 5;\n\nexport function getDeleteListDiscriminatorBytes() {\n return getU8Encoder().encode(DELETE_LIST_DISCRIMINATOR);\n}\n\nexport type DeleteListInstruction<\n TProgram extends string = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n TAccountAuthority extends string | AccountMeta<string> = string,\n TAccountListConfig extends string | AccountMeta<string> = string,\n TRemainingAccounts extends readonly AccountMeta<string>[] = [],\n> = Instruction<TProgram> &\n InstructionWithData<ReadonlyUint8Array> &\n InstructionWithAccounts<\n [\n TAccountAuthority extends string\n ? WritableSignerAccount<TAccountAuthority> &\n AccountSignerMeta<TAccountAuthority>\n : TAccountAuthority,\n TAccountListConfig extends string\n ? WritableAccount<TAccountListConfig>\n : TAccountListConfig,\n ...TRemainingAccounts,\n ]\n >;\n\nexport type DeleteListInstructionData = { discriminator: number };\n\nexport type DeleteListInstructionDataArgs = {};\n\nexport function getDeleteListInstructionDataEncoder(): FixedSizeEncoder<DeleteListInstructionDataArgs> {\n return transformEncoder(\n getStructEncoder([['discriminator', getU8Encoder()]]),\n (value) => ({ ...value, discriminator: DELETE_LIST_DISCRIMINATOR })\n );\n}\n\nexport function getDeleteListInstructionDataDecoder(): FixedSizeDecoder<DeleteListInstructionData> {\n return getStructDecoder([['discriminator', getU8Decoder()]]);\n}\n\nexport function getDeleteListInstructionDataCodec(): FixedSizeCodec<\n DeleteListInstructionDataArgs,\n DeleteListInstructionData\n> {\n return combineCodec(\n getDeleteListInstructionDataEncoder(),\n getDeleteListInstructionDataDecoder()\n );\n}\n\nexport type DeleteListInput<\n TAccountAuthority extends string = string,\n TAccountListConfig extends string = string,\n> = {\n authority: TransactionSigner<TAccountAuthority>;\n listConfig: Address<TAccountListConfig>;\n};\n\nexport function getDeleteListInstruction<\n TAccountAuthority extends string,\n TAccountListConfig extends string,\n TProgramAddress extends\n Address = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n>(\n input: DeleteListInput<TAccountAuthority, TAccountListConfig>,\n config?: { programAddress?: TProgramAddress }\n): DeleteListInstruction<\n TProgramAddress,\n TAccountAuthority,\n TAccountListConfig\n> {\n // Program address.\n const programAddress =\n config?.programAddress ?? TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS;\n\n // Original accounts.\n const originalAccounts = {\n authority: { value: input.authority ?? null, isWritable: true },\n listConfig: { value: input.listConfig ?? null, isWritable: true },\n };\n const accounts = originalAccounts as Record<\n keyof typeof originalAccounts,\n ResolvedAccount\n >;\n\n const getAccountMeta = getAccountMetaFactory(programAddress, 'programId');\n return Object.freeze({\n accounts: [\n getAccountMeta(accounts.authority),\n getAccountMeta(accounts.listConfig),\n ],\n data: getDeleteListInstructionDataEncoder().encode({}),\n programAddress,\n } as DeleteListInstruction<\n TProgramAddress,\n TAccountAuthority,\n TAccountListConfig\n >);\n}\n\nexport type ParsedDeleteListInstruction<\n TProgram extends string = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n TAccountMetas extends readonly AccountMeta[] = readonly AccountMeta[],\n> = {\n programAddress: Address<TProgram>;\n accounts: {\n authority: TAccountMetas[0];\n listConfig: TAccountMetas[1];\n };\n data: DeleteListInstructionData;\n};\n\nexport function parseDeleteListInstruction<\n TProgram extends string,\n TAccountMetas extends readonly AccountMeta[],\n>(\n instruction: Instruction<TProgram> &\n InstructionWithAccounts<TAccountMetas> &\n InstructionWithData<ReadonlyUint8Array>\n): ParsedDeleteListInstruction<TProgram, TAccountMetas> {\n if (instruction.accounts.length < 2) {\n // TODO: Coded error.\n throw new Error('Not enough accounts');\n }\n let accountIndex = 0;\n const getNextAccount = () => {\n const accountMeta = (instruction.accounts as TAccountMetas)[accountIndex]!;\n accountIndex += 1;\n return accountMeta;\n };\n return {\n programAddress: instruction.programAddress,\n accounts: { authority: getNextAccount(), listConfig: getNextAccount() },\n data: getDeleteListInstructionDataDecoder().decode(instruction.data),\n };\n}\n","/**\n * This code was AUTOGENERATED using the Codama library.\n * Please DO NOT EDIT THIS FILE, instead use visitors\n * to add features, then rerun Codama to update it.\n *\n * @see https://github.com/codama-idl/codama\n */\n\nimport {\n combineCodec,\n getStructDecoder,\n getStructEncoder,\n getU8Decoder,\n getU8Encoder,\n transformEncoder,\n type AccountMeta,\n type AccountSignerMeta,\n type Address,\n type FixedSizeCodec,\n type FixedSizeDecoder,\n type FixedSizeEncoder,\n type Instruction,\n type InstructionWithAccounts,\n type InstructionWithData,\n type ReadonlyUint8Array,\n type TransactionSigner,\n type WritableAccount,\n type WritableSignerAccount,\n} from '@solana/kit';\nimport { TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS } from '../programs';\nimport { getAccountMetaFactory, type ResolvedAccount } from '../shared';\n\nexport const REMOVE_WALLET_DISCRIMINATOR = 3;\n\nexport function getRemoveWalletDiscriminatorBytes() {\n return getU8Encoder().encode(REMOVE_WALLET_DISCRIMINATOR);\n}\n\nexport type RemoveWalletInstruction<\n TProgram extends string = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n TAccountAuthority extends string | AccountMeta<string> = string,\n TAccountListConfig extends string | AccountMeta<string> = string,\n TAccountWalletEntry extends string | AccountMeta<string> = string,\n TRemainingAccounts extends readonly AccountMeta<string>[] = [],\n> = Instruction<TProgram> &\n InstructionWithData<ReadonlyUint8Array> &\n InstructionWithAccounts<\n [\n TAccountAuthority extends string\n ? WritableSignerAccount<TAccountAuthority> &\n AccountSignerMeta<TAccountAuthority>\n : TAccountAuthority,\n TAccountListConfig extends string\n ? WritableAccount<TAccountListConfig>\n : TAccountListConfig,\n TAccountWalletEntry extends string\n ? WritableAccount<TAccountWalletEntry>\n : TAccountWalletEntry,\n ...TRemainingAccounts,\n ]\n >;\n\nexport type RemoveWalletInstructionData = { discriminator: number };\n\nexport type RemoveWalletInstructionDataArgs = {};\n\nexport function getRemoveWalletInstructionDataEncoder(): FixedSizeEncoder<RemoveWalletInstructionDataArgs> {\n return transformEncoder(\n getStructEncoder([['discriminator', getU8Encoder()]]),\n (value) => ({ ...value, discriminator: REMOVE_WALLET_DISCRIMINATOR })\n );\n}\n\nexport function getRemoveWalletInstructionDataDecoder(): FixedSizeDecoder<RemoveWalletInstructionData> {\n return getStructDecoder([['discriminator', getU8Decoder()]]);\n}\n\nexport function getRemoveWalletInstructionDataCodec(): FixedSizeCodec<\n RemoveWalletInstructionDataArgs,\n RemoveWalletInstructionData\n> {\n return combineCodec(\n getRemoveWalletInstructionDataEncoder(),\n getRemoveWalletInstructionDataDecoder()\n );\n}\n\nexport type RemoveWalletInput<\n TAccountAuthority extends string = string,\n TAccountListConfig extends string = string,\n TAccountWalletEntry extends string = string,\n> = {\n authority: TransactionSigner<TAccountAuthority>;\n listConfig: Address<TAccountListConfig>;\n walletEntry: Address<TAccountWalletEntry>;\n};\n\nexport function getRemoveWalletInstruction<\n TAccountAuthority extends string,\n TAccountListConfig extends string,\n TAccountWalletEntry extends string,\n TProgramAddress extends\n Address = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n>(\n input: RemoveWalletInput<\n TAccountAuthority,\n TAccountListConfig,\n TAccountWalletEntry\n >,\n config?: { programAddress?: TProgramAddress }\n): RemoveWalletInstruction<\n TProgramAddress,\n TAccountAuthority,\n TAccountListConfig,\n TAccountWalletEntry\n> {\n // Program address.\n const programAddress =\n config?.programAddress ?? TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS;\n\n // Original accounts.\n const originalAccounts = {\n authority: { value: input.authority ?? null, isWritable: true },\n listConfig: { value: input.listConfig ?? null, isWritable: true },\n walletEntry: { value: input.walletEntry ?? null, isWritable: true },\n };\n const accounts = originalAccounts as Record<\n keyof typeof originalAccounts,\n ResolvedAccount\n >;\n\n const getAccountMeta = getAccountMetaFactory(programAddress, 'programId');\n return Object.freeze({\n accounts: [\n getAccountMeta(accounts.authority),\n getAccountMeta(accounts.listConfig),\n getAccountMeta(accounts.walletEntry),\n ],\n data: getRemoveWalletInstructionDataEncoder().encode({}),\n programAddress,\n } as RemoveWalletInstruction<\n TProgramAddress,\n TAccountAuthority,\n TAccountListConfig,\n TAccountWalletEntry\n >);\n}\n\nexport type ParsedRemoveWalletInstruction<\n TProgram extends string = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n TAccountMetas extends readonly AccountMeta[] = readonly AccountMeta[],\n> = {\n programAddress: Address<TProgram>;\n accounts: {\n authority: TAccountMetas[0];\n listConfig: TAccountMetas[1];\n walletEntry: TAccountMetas[2];\n };\n data: RemoveWalletInstructionData;\n};\n\nexport function parseRemoveWalletInstruction<\n TProgram extends string,\n TAccountMetas extends readonly AccountMeta[],\n>(\n instruction: Instruction<TProgram> &\n InstructionWithAccounts<TAccountMetas> &\n InstructionWithData<ReadonlyUint8Array>\n): ParsedRemoveWalletInstruction<TProgram, TAccountMetas> {\n if (instruction.accounts.length < 3) {\n // TODO: Coded error.\n throw new Error('Not enough accounts');\n }\n let accountIndex = 0;\n const getNextAccount = () => {\n const accountMeta = (instruction.accounts as TAccountMetas)[accountIndex]!;\n accountIndex += 1;\n return accountMeta;\n };\n return {\n programAddress: instruction.programAddress,\n accounts: {\n authority: getNextAccount(),\n listConfig: getNextAccount(),\n walletEntry: getNextAccount(),\n },\n data: getRemoveWalletInstructionDataDecoder().decode(instruction.data),\n };\n}\n","/**\n * This code was AUTOGENERATED using the Codama library.\n * Please DO NOT EDIT THIS FILE, instead use visitors\n * to add features, then rerun Codama to update it.\n *\n * @see https://github.com/codama-idl/codama\n */\n\nimport {\n AccountRole,\n combineCodec,\n getStructDecoder,\n getStructEncoder,\n getU8Decoder,\n getU8Encoder,\n transformEncoder,\n type AccountMeta,\n type AccountSignerMeta,\n type Address,\n type FixedSizeCodec,\n type FixedSizeDecoder,\n type FixedSizeEncoder,\n type Instruction,\n type InstructionWithAccounts,\n type InstructionWithData,\n type ReadonlyAccount,\n type ReadonlySignerAccount,\n type ReadonlyUint8Array,\n type TransactionSigner,\n type WritableAccount,\n type WritableSignerAccount,\n} from '@solana/kit';\nimport { TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS } from '../programs';\nimport { getAccountMetaFactory, type ResolvedAccount } from '../shared';\n\nexport const SETUP_EXTRA_METAS_DISCRIMINATOR = 4;\n\nexport function getSetupExtraMetasDiscriminatorBytes() {\n return getU8Encoder().encode(SETUP_EXTRA_METAS_DISCRIMINATOR);\n}\n\nexport type SetupExtraMetasInstruction<\n TProgram extends string = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n TAccountAuthority extends string | AccountMeta<string> = string,\n TAccountPayer extends string | AccountMeta<string> = string,\n TAccountTokenAclMintConfig extends string | AccountMeta<string> = string,\n TAccountMint extends string | AccountMeta<string> = string,\n TAccountExtraMetas extends string | AccountMeta<string> = string,\n TAccountSystemProgram extends\n | string\n | AccountMeta<string> = '11111111111111111111111111111111',\n TRemainingAccounts extends readonly AccountMeta<string>[] = [],\n> = Instruction<TProgram> &\n InstructionWithData<ReadonlyUint8Array> &\n InstructionWithAccounts<\n [\n TAccountAuthority extends string\n ? ReadonlySignerAccount<TAccountAuthority> &\n AccountSignerMeta<TAccountAuthority>\n : TAccountAuthority,\n TAccountPayer extends string\n ? WritableSignerAccount<TAccountPayer> &\n AccountSignerMeta<TAccountPayer>\n : TAccountPayer,\n TAccountTokenAclMintConfig extends string\n ? ReadonlyAccount<TAccountTokenAclMintConfig>\n : TAccountTokenAclMintConfig,\n TAccountMint extends string\n ? ReadonlyAccount<TAccountMint>\n : TAccountMint,\n TAccountExtraMetas extends string\n ? WritableAccount<TAccountExtraMetas>\n : TAccountExtraMetas,\n TAccountSystemProgram extends string\n ? ReadonlyAccount<TAccountSystemProgram>\n : TAccountSystemProgram,\n ...TRemainingAccounts,\n ]\n >;\n\nexport type SetupExtraMetasInstructionData = { discriminator: number };\n\nexport type SetupExtraMetasInstructionDataArgs = {};\n\nexport function getSetupExtraMetasInstructionDataEncoder(): FixedSizeEncoder<SetupExtraMetasInstructionDataArgs> {\n return transformEncoder(\n getStructEncoder([['discriminator', getU8Encoder()]]),\n (value) => ({ ...value, discriminator: SETUP_EXTRA_METAS_DISCRIMINATOR })\n );\n}\n\nexport function getSetupExtraMetasInstructionDataDecoder(): FixedSizeDecoder<SetupExtraMetasInstructionData> {\n return getStructDecoder([['discriminator', getU8Decoder()]]);\n}\n\nexport function getSetupExtraMetasInstructionDataCodec(): FixedSizeCodec<\n SetupExtraMetasInstructionDataArgs,\n SetupExtraMetasInstructionData\n> {\n return combineCodec(\n getSetupExtraMetasInstructionDataEncoder(),\n getSetupExtraMetasInstructionDataDecoder()\n );\n}\n\nexport type SetupExtraMetasInstructionExtraArgs = {\n /** Up to 5 ListConfig accounts owned by this program */\n addresses: Array<Address>;\n};\n\nexport type SetupExtraMetasInput<\n TAccountAuthority extends string = string,\n TAccountPayer extends string = string,\n TAccountTokenAclMintConfig extends string = string,\n TAccountMint extends string = string,\n TAccountExtraMetas extends string = string,\n TAccountSystemProgram extends string = string,\n> = {\n authority: TransactionSigner<TAccountAuthority>;\n payer: TransactionSigner<TAccountPayer>;\n tokenAclMintConfig: Address<TAccountTokenAclMintConfig>;\n mint: Address<TAccountMint>;\n extraMetas: Address<TAccountExtraMetas>;\n systemProgram?: Address<TAccountSystemProgram>;\n addresses: SetupExtraMetasInstructionExtraArgs['addresses'];\n};\n\nexport function getSetupExtraMetasInstruction<\n TAccountAuthority extends string,\n TAccountPayer extends string,\n TAccountTokenAclMintConfig extends string,\n TAccountMint extends string,\n TAccountExtraMetas extends string,\n TAccountSystemProgram extends string,\n TProgramAddress extends\n Address = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n>(\n input: SetupExtraMetasInput<\n TAccountAuthority,\n TAccountPayer,\n TAccountTokenAclMintConfig,\n TAccountMint,\n TAccountExtraMetas,\n TAccountSystemProgram\n >,\n config?: { programAddress?: TProgramAddress }\n): SetupExtraMetasInstruction<\n TProgramAddress,\n TAccountAuthority,\n TAccountPayer,\n TAccountTokenAclMintConfig,\n TAccountMint,\n TAccountExtraMetas,\n TAccountSystemProgram\n> {\n // Program address.\n const programAddress =\n config?.programAddress ?? TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS;\n\n // Original accounts.\n const originalAccounts = {\n authority: { value: input.authority ?? null, isWritable: false },\n payer: { value: input.payer ?? null, isWritable: true },\n tokenAclMintConfig: {\n value: input.tokenAclMintConfig ?? null,\n isWritable: false,\n },\n mint: { value: input.mint ?? null, isWritable: false },\n extraMetas: { value: input.extraMetas ?? null, isWritable: true },\n systemProgram: { value: input.systemProgram ?? null, isWritable: false },\n };\n const accounts = originalAccounts as Record<\n keyof typeof originalAccounts,\n ResolvedAccount\n >;\n\n // Original args.\n const args = { ...input };\n\n // Resolve default values.\n if (!accounts.systemProgram.value) {\n accounts.systemProgram.value =\n '11111111111111111111111111111111' as Address<'11111111111111111111111111111111'>;\n }\n\n // Remaining accounts.\n const remainingAccounts: AccountMeta[] = args.addresses.map((address) => ({\n address,\n role: AccountRole.READONLY,\n }));\n\n const getAccountMeta = getAccountMetaFactory(programAddress, 'programId');\n return Object.freeze({\n accounts: [\n getAccountMeta(accounts.authority),\n getAccountMeta(accounts.payer),\n getAccountMeta(accounts.tokenAclMintConfig),\n getAccountMeta(accounts.mint),\n getAccountMeta(accounts.extraMetas),\n getAccountMeta(accounts.systemProgram),\n ...remainingAccounts,\n ],\n data: getSetupExtraMetasInstructionDataEncoder().encode({}),\n programAddress,\n } as SetupExtraMetasInstruction<\n TProgramAddress,\n TAccountAuthority,\n TAccountPayer,\n TAccountTokenAclMintConfig,\n TAccountMint,\n TAccountExtraMetas,\n TAccountSystemProgram\n >);\n}\n\nexport type ParsedSetupExtraMetasInstruction<\n TProgram extends string = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n TAccountMetas extends readonly AccountMeta[] = readonly AccountMeta[],\n> = {\n programAddress: Address<TProgram>;\n accounts: {\n authority: TAccountMetas[0];\n payer: TAccountMetas[1];\n tokenAclMintConfig: TAccountMetas[2];\n mint: TAccountMetas[3];\n extraMetas: TAccountMetas[4];\n systemProgram: TAccountMetas[5];\n };\n data: SetupExtraMetasInstructionData;\n};\n\nexport function parseSetupExtraMetasInstruction<\n TProgram extends string,\n TAccountMetas extends readonly AccountMeta[],\n>(\n instruction: Instruction<TProgram> &\n InstructionWithAccounts<TAccountMetas> &\n InstructionWithData<ReadonlyUint8Array>\n): ParsedSetupExtraMetasInstruction<TProgram, TAccountMetas> {\n if (instruction.accounts.length < 6) {\n // TODO: Coded error.\n throw new Error('Not enough accounts');\n }\n let accountIndex = 0;\n const getNextAccount = () => {\n const accountMeta = (instruction.accounts as TAccountMetas)[accountIndex]!;\n accountIndex += 1;\n return accountMeta;\n };\n return {\n programAddress: instruction.programAddress,\n accounts: {\n authority: getNextAccount(),\n payer: getNextAccount(),\n tokenAclMintConfig: getNextAccount(),\n mint: getNextAccount(),\n extraMetas: getNextAccount(),\n systemProgram: getNextAccount(),\n },\n data: getSetupExtraMetasInstructionDataDecoder().decode(instruction.data),\n };\n}\n","/**\n * This code was AUTOGENERATED using the Codama library.\n * Please DO NOT EDIT THIS FILE, instead use visitors\n * to add features, then rerun Codama to update it.\n *\n * @see https://github.com/codama-idl/codama\n */\n\nimport {\n combineCodec,\n getStructDecoder,\n getStructEncoder,\n getU8Decoder,\n getU8Encoder,\n transformEncoder,\n type AccountMeta,\n type AccountSignerMeta,\n type Address,\n type FixedSizeCodec,\n type FixedSizeDecoder,\n type FixedSizeEncoder,\n type Instruction,\n type InstructionWithAccounts,\n type InstructionWithData,\n type ReadonlyAccount,\n type ReadonlySignerAccount,\n type ReadonlyUint8Array,\n type TransactionSigner,\n type WritableAccount,\n type WritableSignerAccount,\n} from '@solana/kit';\nimport { TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS } from '../programs';\nimport { getAccountMetaFactory, type ResolvedAccount } from '../shared';\n\nexport const SETUP_FREEZE_EXTRA_METAS_DISCRIMINATOR = 6;\n\nexport function getSetupFreezeExtraMetasDiscriminatorBytes() {\n return getU8Encoder().encode(SETUP_FREEZE_EXTRA_METAS_DISCRIMINATOR);\n}\n\nexport type SetupFreezeExtraMetasInstruction<\n TProgram extends string = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n TAccountAuthority extends string | AccountMeta<string> = string,\n TAccountPayer extends string | AccountMeta<string> = string,\n TAccountTokenAclMintConfig extends string | AccountMeta<string> = string,\n TAccountMint extends string | AccountMeta<string> = string,\n TAccountExtraMetas extends string | AccountMeta<string> = string,\n TAccountSystemProgram extends\n | string\n | AccountMeta<string> = '11111111111111111111111111111111',\n TRemainingAccounts extends readonly AccountMeta<string>[] = [],\n> = Instruction<TProgram> &\n InstructionWithData<ReadonlyUint8Array> &\n InstructionWithAccounts<\n [\n TAccountAuthority extends string\n ? ReadonlySignerAccount<TAccountAuthority> &\n AccountSignerMeta<TAccountAuthority>\n : TAccountAuthority,\n TAccountPayer extends string\n ? WritableSignerAccount<TAccountPayer> &\n AccountSignerMeta<TAccountPayer>\n : TAccountPayer,\n TAccountTokenAclMintConfig extends string\n ? ReadonlyAccount<TAccountTokenAclMintConfig>\n : TAccountTokenAclMintConfig,\n TAccountMint extends string\n ? ReadonlyAccount<TAccountMint>\n : TAccountMint,\n TAccountExtraMetas extends string\n ? WritableAccount<TAccountExtraMetas>\n : TAccountExtraMetas,\n TAccountSystemProgram extends string\n ? ReadonlyAccount<TAccountSystemProgram>\n : TAccountSystemProgram,\n ...TRemainingAccounts,\n ]\n >;\n\nexport type SetupFreezeExtraMetasInstructionData = { discriminator: number };\n\nexport type SetupFreezeExtraMetasInstructionDataArgs = {};\n\nexport function getSetupFreezeExtraMetasInstructionDataEncoder(): FixedSizeEncoder<SetupFreezeExtraMetasInstructionDataArgs> {\n return transformEncoder(\n getStructEncoder([['discriminator', getU8Encoder()]]),\n (value) => ({\n ...value,\n discriminator: SETUP_FREEZE_EXTRA_METAS_DISCRIMINATOR,\n })\n );\n}\n\nexport function getSetupFreezeExtraMetasInstructionDataDecoder(): FixedSizeDecoder<SetupFreezeExtraMetasInstructionData> {\n return getStructDecoder([['discriminator', getU8Decoder()]]);\n}\n\nexport function getSetupFreezeExtraMetasInstructionDataCodec(): FixedSizeCodec<\n SetupFreezeExtraMetasInstructionDataArgs,\n SetupFreezeExtraMetasInstructionData\n> {\n return combineCodec(\n getSetupFreezeExtraMetasInstructionDataEncoder(),\n getSetupFreezeExtraMetasInstructionDataDecoder()\n );\n}\n\nexport type SetupFreezeExtraMetasInput<\n TAccountAuthority extends string = string,\n TAccountPayer extends string = string,\n TAccountTokenAclMintConfig extends string = string,\n TAccountMint extends string = string,\n TAccountExtraMetas extends string = string,\n TAccountSystemProgram extends string = string,\n> = {\n authority: TransactionSigner<TAccountAuthority>;\n payer: TransactionSigner<TAccountPayer>;\n tokenAclMintConfig: Address<TAccountTokenAclMintConfig>;\n mint: Address<TAccountMint>;\n extraMetas: Address<TAccountExtraMetas>;\n systemProgram?: Address<TAccountSystemProgram>;\n};\n\nexport function getSetupFreezeExtraMetasInstruction<\n TAccountAuthority extends string,\n TAccountPayer extends string,\n TAccountTokenAclMintConfig extends string,\n TAccountMint extends string,\n TAccountExtraMetas extends string,\n TAccountSystemProgram extends string,\n TProgramAddress extends\n Address = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n>(\n input: SetupFreezeExtraMetasInput<\n TAccountAuthority,\n TAccountPayer,\n TAccountTokenAclMintConfig,\n TAccountMint,\n TAccountExtraMetas,\n TAccountSystemProgram\n >,\n config?: { programAddress?: TProgramAddress }\n): SetupFreezeExtraMetasInstruction<\n TProgramAddress,\n TAccountAuthority,\n TAccountPayer,\n TAccountTokenAclMintConfig,\n TAccountMint,\n TAccountExtraMetas,\n TAccountSystemProgram\n> {\n // Program address.\n const programAddress =\n config?.programAddress ?? TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS;\n\n // Original accounts.\n const originalAccounts = {\n authority: { value: input.authority ?? null, isWritable: false },\n payer: { value: input.payer ?? null, isWritable: true },\n tokenAclMintConfig: {\n value: input.tokenAclMintConfig ?? null,\n isWritable: false,\n },\n mint: { value: input.mint ?? null, isWritable: false },\n extraMetas: { value: input.extraMetas ?? null, isWritable: true },\n systemProgram: { value: input.systemProgram ?? null, isWritable: false },\n };\n const accounts = originalAccounts as Record<\n keyof typeof originalAccounts,\n ResolvedAccount\n >;\n\n // Resolve default values.\n if (!accounts.systemProgram.value) {\n accounts.systemProgram.value =\n '11111111111111111111111111111111' as Address<'11111111111111111111111111111111'>;\n }\n\n const getAccountMeta = getAccountMetaFactory(programAddress, 'programId');\n return Object.freeze({\n accounts: [\n getAccountMeta(accounts.authority),\n getAccountMeta(accounts.payer),\n getAccountMeta(accounts.tokenAclMintConfig),\n getAccountMeta(accounts.mint),\n getAccountMeta(accounts.extraMetas),\n getAccountMeta(accounts.systemProgram),\n ],\n data: getSetupFreezeExtraMetasInstructionDataEncoder().encode({}),\n programAddress,\n } as SetupFreezeExtraMetasInstruction<\n TProgramAddress,\n TAccountAuthority,\n TAccountPayer,\n TAccountTokenAclMintConfig,\n TAccountMint,\n TAccountExtraMetas,\n TAccountSystemProgram\n >);\n}\n\nexport type ParsedSetupFreezeExtraMetasInstruction<\n TProgram extends string = typeof TOKEN_ACL_GATE_PROGRAM_PROGRAM_ADDRESS,\n TAccountMetas extends readonly AccountMeta[] = readonly AccountMeta[],\n> = {\n programAddress: Address<TProgram>;\n accounts: {\n authority: TAccountMetas[0];\n payer: TAccountMetas[1];\n tokenAclMintConfig: TAccountMetas[2];\n mint: TAccountMetas[3];\n extraMetas: TAccountMetas[4];\n systemProgram: TAccountMetas[5];\n };\n data: SetupFreezeExtraMetasInstructionData;\n};\n\nexport function parseSetupFreezeExtraMetasInstruction<\n TProgram extends string,\n TAccountMetas extends readonly AccountMeta[],\n>(\n instruction: Instruction<TProgram> &\n InstructionWithAccounts<TAccountMetas> &\n InstructionWithData<ReadonlyUint8Array>\n): ParsedSetupFreezeExtraMetasInstruction<TProgram, TAccountMetas> {\n if (instruction.accounts.length < 6) {\n // TODO: Coded error.\n throw new Error('Not enough accounts');\n }\n let accountIndex = 0;\n const getNextAccount = () => {\n const accountMeta = (instruction.accounts as TAccountMetas)[accountIndex]!;\n accountIndex += 1;\n return accountMeta;\n };\n return {\n programAddress: instruction.programAddress,\n accounts: {\n authority: getNextAccount(),\n payer: getNextAccount(),\n tokenAclMintConfig: getNextAccount(),\n mint: getNextAccount(),\n extraMetas: getNextAccount(),\n systemProgram: getNextAccount(),\n },\n data: getSetupFreezeExtraMetasInstructionDataDecoder().decode(\n instruction.data\n ),\n };\n}\n"]}
|