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OAAAvqB,CACA","sources":["webpack://_N_E/../../node_modules/@solana/web3.js/lib/index.browser.esm.js"],"sourcesContent":["import { Buffer } from 'buffer';\nimport { ed25519 } from '@noble/curves/ed25519';\nimport BN from 'bn.js';\nimport bs58 from 'bs58';\nimport { sha256 } from '@noble/hashes/sha256';\nimport { serialize, deserialize, deserializeUnchecked } from 'borsh';\nimport * as BufferLayout from '@solana/buffer-layout';\nimport { blob } from '@solana/buffer-layout';\nimport { toBigIntLE, toBufferLE } from 'bigint-buffer';\nimport { coerce, instance, string, tuple, literal, unknown, type, number, array, nullable, optional, boolean, record, union, create, any, assert as assert$1 } from 'superstruct';\nimport RpcClient from 'jayson/lib/client/browser';\nimport RpcWebSocketCommonClient from 'rpc-websockets/dist/lib/client';\nimport createRpc from 'rpc-websockets/dist/lib/client/websocket.browser';\nimport { keccak_256 } from '@noble/hashes/sha3';\nimport { secp256k1 } from '@noble/curves/secp256k1';\n\n/**\n * A 64 byte secret key, the first 32 bytes of which is the\n * private scalar and the last 32 bytes is the public key.\n * Read more: https://blog.mozilla.org/warner/2011/11/29/ed25519-keys/\n */\n\n/**\n * Ed25519 Keypair\n */\n\nconst generatePrivateKey = ed25519.utils.randomPrivateKey;\nconst generateKeypair = () => {\n const privateScalar = ed25519.utils.randomPrivateKey();\n const publicKey = getPublicKey(privateScalar);\n const secretKey = new Uint8Array(64);\n secretKey.set(privateScalar);\n secretKey.set(publicKey, 32);\n return {\n publicKey,\n secretKey\n };\n};\nconst getPublicKey = ed25519.getPublicKey;\nfunction isOnCurve(publicKey) {\n try {\n ed25519.ExtendedPoint.fromHex(publicKey);\n return true;\n } catch {\n return false;\n }\n}\nconst sign = (message, secretKey) => ed25519.sign(message, secretKey.slice(0, 32));\nconst verify = ed25519.verify;\n\nconst toBuffer = arr => {\n if (Buffer.isBuffer(arr)) {\n return arr;\n } else if (arr instanceof Uint8Array) {\n return Buffer.from(arr.buffer, arr.byteOffset, arr.byteLength);\n } else {\n return Buffer.from(arr);\n }\n};\n\n// Class wrapping a plain object\nclass Struct {\n constructor(properties) {\n Object.assign(this, properties);\n }\n encode() {\n return Buffer.from(serialize(SOLANA_SCHEMA, this));\n }\n static decode(data) {\n return deserialize(SOLANA_SCHEMA, this, data);\n }\n static decodeUnchecked(data) {\n return deserializeUnchecked(SOLANA_SCHEMA, this, data);\n }\n}\n\n// Class representing a Rust-compatible enum, since enums are only strings or\n// numbers in pure JS\nclass Enum extends Struct {\n constructor(properties) {\n super(properties);\n this.enum = '';\n if (Object.keys(properties).length !== 1) {\n throw new Error('Enum can only take single value');\n }\n Object.keys(properties).map(key => {\n this.enum = key;\n });\n }\n}\nconst SOLANA_SCHEMA = new Map();\n\nvar _class;\nlet _Symbol$toStringTag;\n\n/**\n * Maximum length of derived pubkey seed\n */\nconst MAX_SEED_LENGTH = 32;\n\n/**\n * Size of public key in bytes\n */\nconst PUBLIC_KEY_LENGTH = 32;\n\n/**\n * Value to be converted into public key\n */\n\n/**\n * JSON object representation of PublicKey class\n */\n\nfunction isPublicKeyData(value) {\n return value._bn !== undefined;\n}\n\n// local counter used by PublicKey.unique()\nlet uniquePublicKeyCounter = 1;\n\n/**\n * A public key\n */\n_Symbol$toStringTag = Symbol.toStringTag;\nclass PublicKey extends Struct {\n /**\n * Create a new PublicKey object\n * @param value ed25519 public key as buffer or base-58 encoded string\n */\n constructor(value) {\n super({});\n /** @internal */\n this._bn = void 0;\n if (isPublicKeyData(value)) {\n this._bn = value._bn;\n } else {\n if (typeof value === 'string') {\n // assume base 58 encoding by default\n const decoded = bs58.decode(value);\n if (decoded.length != PUBLIC_KEY_LENGTH) {\n throw new Error(`Invalid public key input`);\n }\n this._bn = new BN(decoded);\n } else {\n this._bn = new BN(value);\n }\n if (this._bn.byteLength() > PUBLIC_KEY_LENGTH) {\n throw new Error(`Invalid public key input`);\n }\n }\n }\n\n /**\n * Returns a unique PublicKey for tests and benchmarks using a counter\n */\n static unique() {\n const key = new PublicKey(uniquePublicKeyCounter);\n uniquePublicKeyCounter += 1;\n return new PublicKey(key.toBuffer());\n }\n\n /**\n * Default public key value. The base58-encoded string representation is all ones (as seen below)\n * The underlying BN number is 32 bytes that are all zeros\n */\n\n /**\n * Checks if two publicKeys are equal\n */\n equals(publicKey) {\n return this._bn.eq(publicKey._bn);\n }\n\n /**\n * Return the base-58 representation of the public key\n */\n toBase58() {\n return bs58.encode(this.toBytes());\n }\n toJSON() {\n return this.toBase58();\n }\n\n /**\n * Return the byte array representation of the public key in big endian\n */\n toBytes() {\n const buf = this.toBuffer();\n return new Uint8Array(buf.buffer, buf.byteOffset, buf.byteLength);\n }\n\n /**\n * Return the Buffer representation of the public key in big endian\n */\n toBuffer() {\n const b = this._bn.toArrayLike(Buffer);\n if (b.length === PUBLIC_KEY_LENGTH) {\n return b;\n }\n const zeroPad = Buffer.alloc(32);\n b.copy(zeroPad, 32 - b.length);\n return zeroPad;\n }\n get [_Symbol$toStringTag]() {\n return `PublicKey(${this.toString()})`;\n }\n\n /**\n * Return the base-58 representation of the public key\n */\n toString() {\n return this.toBase58();\n }\n\n /**\n * Derive a public key from another key, a seed, and a program ID.\n * The program ID will also serve as the owner of the public key, giving\n * it permission to write data to the account.\n */\n /* eslint-disable require-await */\n static async createWithSeed(fromPublicKey, seed, programId) {\n const buffer = Buffer.concat([fromPublicKey.toBuffer(), Buffer.from(seed), programId.toBuffer()]);\n const publicKeyBytes = sha256(buffer);\n return new PublicKey(publicKeyBytes);\n }\n\n /**\n * Derive a program address from seeds and a program ID.\n */\n /* eslint-disable require-await */\n static createProgramAddressSync(seeds, programId) {\n let buffer = Buffer.alloc(0);\n seeds.forEach(function (seed) {\n if (seed.length > MAX_SEED_LENGTH) {\n throw new TypeError(`Max seed length exceeded`);\n }\n buffer = Buffer.concat([buffer, toBuffer(seed)]);\n });\n buffer = Buffer.concat([buffer, programId.toBuffer(), Buffer.from('ProgramDerivedAddress')]);\n const publicKeyBytes = sha256(buffer);\n if (isOnCurve(publicKeyBytes)) {\n throw new Error(`Invalid seeds, address must fall off the curve`);\n }\n return new PublicKey(publicKeyBytes);\n }\n\n /**\n * Async version of createProgramAddressSync\n * For backwards compatibility\n *\n * @deprecated Use {@link createProgramAddressSync} instead\n */\n /* eslint-disable require-await */\n static async createProgramAddress(seeds, programId) {\n return this.createProgramAddressSync(seeds, programId);\n }\n\n /**\n * Find a valid program address\n *\n * Valid program addresses must fall off the ed25519 curve. This function\n * iterates a nonce until it finds one that when combined with the seeds\n * results in a valid program address.\n */\n static findProgramAddressSync(seeds, programId) {\n let nonce = 255;\n let address;\n while (nonce != 0) {\n try {\n const seedsWithNonce = seeds.concat(Buffer.from([nonce]));\n address = this.createProgramAddressSync(seedsWithNonce, programId);\n } catch (err) {\n if (err instanceof TypeError) {\n throw err;\n }\n nonce--;\n continue;\n }\n return [address, nonce];\n }\n throw new Error(`Unable to find a viable program address nonce`);\n }\n\n /**\n * Async version of findProgramAddressSync\n * For backwards compatibility\n *\n * @deprecated Use {@link findProgramAddressSync} instead\n */\n static async findProgramAddress(seeds, programId) {\n return this.findProgramAddressSync(seeds, programId);\n }\n\n /**\n * Check that a pubkey is on the ed25519 curve.\n */\n static isOnCurve(pubkeyData) {\n const pubkey = new PublicKey(pubkeyData);\n return isOnCurve(pubkey.toBytes());\n }\n}\n_class = PublicKey;\nPublicKey.default = new _class('11111111111111111111111111111111');\nSOLANA_SCHEMA.set(PublicKey, {\n kind: 'struct',\n fields: [['_bn', 'u256']]\n});\n\n/**\n * An account key pair (public and secret keys).\n *\n * @deprecated since v1.10.0, please use {@link Keypair} instead.\n */\nclass Account {\n /**\n * Create a new Account object\n *\n * If the secretKey parameter is not provided a new key pair is randomly\n * created for the account\n *\n * @param secretKey Secret key for the account\n */\n constructor(secretKey) {\n /** @internal */\n this._publicKey = void 0;\n /** @internal */\n this._secretKey = void 0;\n if (secretKey) {\n const secretKeyBuffer = toBuffer(secretKey);\n if (secretKey.length !== 64) {\n throw new Error('bad secret key size');\n }\n this._publicKey = secretKeyBuffer.slice(32, 64);\n this._secretKey = secretKeyBuffer.slice(0, 32);\n } else {\n this._secretKey = toBuffer(generatePrivateKey());\n this._publicKey = toBuffer(getPublicKey(this._secretKey));\n }\n }\n\n /**\n * The public key for this account\n */\n get publicKey() {\n return new PublicKey(this._publicKey);\n }\n\n /**\n * The **unencrypted** secret key for this account. The first 32 bytes\n * is the private scalar and the last 32 bytes is the public key.\n * Read more: https://blog.mozilla.org/warner/2011/11/29/ed25519-keys/\n */\n get secretKey() {\n return Buffer.concat([this._secretKey, this._publicKey], 64);\n }\n}\n\nconst BPF_LOADER_DEPRECATED_PROGRAM_ID = new PublicKey('BPFLoader1111111111111111111111111111111111');\n\n/**\n * Maximum over-the-wire size of a Transaction\n *\n * 1280 is IPv6 minimum MTU\n * 40 bytes is the size of the IPv6 header\n * 8 bytes is the size of the fragment header\n */\nconst PACKET_DATA_SIZE = 1280 - 40 - 8;\nconst VERSION_PREFIX_MASK = 0x7f;\nconst SIGNATURE_LENGTH_IN_BYTES = 64;\n\nclass TransactionExpiredBlockheightExceededError extends Error {\n constructor(signature) {\n super(`Signature ${signature} has expired: block height exceeded.`);\n this.signature = void 0;\n this.signature = signature;\n }\n}\nObject.defineProperty(TransactionExpiredBlockheightExceededError.prototype, 'name', {\n value: 'TransactionExpiredBlockheightExceededError'\n});\nclass TransactionExpiredTimeoutError extends Error {\n constructor(signature, timeoutSeconds) {\n super(`Transaction was not confirmed in ${timeoutSeconds.toFixed(2)} seconds. It is ` + 'unknown if it succeeded or failed. Check signature ' + `${signature} using the Solana Explorer or CLI tools.`);\n this.signature = void 0;\n this.signature = signature;\n }\n}\nObject.defineProperty(TransactionExpiredTimeoutError.prototype, 'name', {\n value: 'TransactionExpiredTimeoutError'\n});\nclass TransactionExpiredNonceInvalidError extends Error {\n constructor(signature) {\n super(`Signature ${signature} has expired: the nonce is no longer valid.`);\n this.signature = void 0;\n this.signature = signature;\n }\n}\nObject.defineProperty(TransactionExpiredNonceInvalidError.prototype, 'name', {\n value: 'TransactionExpiredNonceInvalidError'\n});\n\nclass MessageAccountKeys {\n constructor(staticAccountKeys, accountKeysFromLookups) {\n this.staticAccountKeys = void 0;\n this.accountKeysFromLookups = void 0;\n this.staticAccountKeys = staticAccountKeys;\n this.accountKeysFromLookups = accountKeysFromLookups;\n }\n keySegments() {\n const keySegments = [this.staticAccountKeys];\n if (this.accountKeysFromLookups) {\n keySegments.push(this.accountKeysFromLookups.writable);\n keySegments.push(this.accountKeysFromLookups.readonly);\n }\n return keySegments;\n }\n get(index) {\n for (const keySegment of this.keySegments()) {\n if (index < keySegment.length) {\n return keySegment[index];\n } else {\n index -= keySegment.length;\n }\n }\n return;\n }\n get length() {\n return this.keySegments().flat().length;\n }\n compileInstructions(instructions) {\n // Bail early if any account indexes would overflow a u8\n const U8_MAX = 255;\n if (this.length > U8_MAX + 1) {\n throw new Error('Account index overflow encountered during compilation');\n }\n const keyIndexMap = new Map();\n this.keySegments().flat().forEach((key, index) => {\n keyIndexMap.set(key.toBase58(), index);\n });\n const findKeyIndex = key => {\n const keyIndex = keyIndexMap.get(key.toBase58());\n if (keyIndex === undefined) throw new Error('Encountered an unknown instruction account key during compilation');\n return keyIndex;\n };\n return instructions.map(instruction => {\n return {\n programIdIndex: findKeyIndex(instruction.programId),\n accountKeyIndexes: instruction.keys.map(meta => findKeyIndex(meta.pubkey)),\n data: instruction.data\n };\n });\n }\n}\n\n/**\n * Layout for a public key\n */\nconst publicKey = (property = 'publicKey') => {\n return BufferLayout.blob(32, property);\n};\n\n/**\n * Layout for a signature\n */\nconst signature = (property = 'signature') => {\n return BufferLayout.blob(64, property);\n};\n/**\n * Layout for a Rust String type\n */\nconst rustString = (property = 'string') => {\n const rsl = BufferLayout.struct([BufferLayout.u32('length'), BufferLayout.u32('lengthPadding'), BufferLayout.blob(BufferLayout.offset(BufferLayout.u32(), -8), 'chars')], property);\n const _decode = rsl.decode.bind(rsl);\n const _encode = rsl.encode.bind(rsl);\n const rslShim = rsl;\n rslShim.decode = (b, offset) => {\n const data = _decode(b, offset);\n return data['chars'].toString();\n };\n rslShim.encode = (str, b, offset) => {\n const data = {\n chars: Buffer.from(str, 'utf8')\n };\n return _encode(data, b, offset);\n };\n rslShim.alloc = str => {\n return BufferLayout.u32().span + BufferLayout.u32().span + Buffer.from(str, 'utf8').length;\n };\n return rslShim;\n};\n\n/**\n * Layout for an Authorized object\n */\nconst authorized = (property = 'authorized') => {\n return BufferLayout.struct([publicKey('staker'), publicKey('withdrawer')], property);\n};\n\n/**\n * Layout for a Lockup object\n */\nconst lockup = (property = 'lockup') => {\n return BufferLayout.struct([BufferLayout.ns64('unixTimestamp'), BufferLayout.ns64('epoch'), publicKey('custodian')], property);\n};\n\n/**\n * Layout for a VoteInit object\n */\nconst voteInit = (property = 'voteInit') => {\n return BufferLayout.struct([publicKey('nodePubkey'), publicKey('authorizedVoter'), publicKey('authorizedWithdrawer'), BufferLayout.u8('commission')], property);\n};\n\n/**\n * Layout for a VoteAuthorizeWithSeedArgs object\n */\nconst voteAuthorizeWithSeedArgs = (property = 'voteAuthorizeWithSeedArgs') => {\n return BufferLayout.struct([BufferLayout.u32('voteAuthorizationType'), publicKey('currentAuthorityDerivedKeyOwnerPubkey'), rustString('currentAuthorityDerivedKeySeed'), publicKey('newAuthorized')], property);\n};\nfunction getAlloc(type, fields) {\n const getItemAlloc = item => {\n if (item.span >= 0) {\n return item.span;\n } else if (typeof item.alloc === 'function') {\n return item.alloc(fields[item.property]);\n } else if ('count' in item && 'elementLayout' in item) {\n const field = fields[item.property];\n if (Array.isArray(field)) {\n return field.length * getItemAlloc(item.elementLayout);\n }\n } else if ('fields' in item) {\n // This is a `Structure` whose size needs to be recursively measured.\n return getAlloc({\n layout: item\n }, fields[item.property]);\n }\n // Couldn't determine allocated size of layout\n return 0;\n };\n let alloc = 0;\n type.layout.fields.forEach(item => {\n alloc += getItemAlloc(item);\n });\n return alloc;\n}\n\nfunction decodeLength(bytes) {\n let len = 0;\n let size = 0;\n for (;;) {\n let elem = bytes.shift();\n len |= (elem & 0x7f) << size * 7;\n size += 1;\n if ((elem & 0x80) === 0) {\n break;\n }\n }\n return len;\n}\nfunction encodeLength(bytes, len) {\n let rem_len = len;\n for (;;) {\n let elem = rem_len & 0x7f;\n rem_len >>= 7;\n if (rem_len == 0) {\n bytes.push(elem);\n break;\n } else {\n elem |= 0x80;\n bytes.push(elem);\n }\n }\n}\n\nfunction assert (condition, message) {\n if (!condition) {\n throw new Error(message || 'Assertion failed');\n }\n}\n\nclass CompiledKeys {\n constructor(payer, keyMetaMap) {\n this.payer = void 0;\n this.keyMetaMap = void 0;\n this.payer = payer;\n this.keyMetaMap = keyMetaMap;\n }\n static compile(instructions, payer) {\n const keyMetaMap = new Map();\n const getOrInsertDefault = pubkey => {\n const address = pubkey.toBase58();\n let keyMeta = keyMetaMap.get(address);\n if (keyMeta === undefined) {\n keyMeta = {\n isSigner: false,\n isWritable: false,\n isInvoked: false\n };\n keyMetaMap.set(address, keyMeta);\n }\n return keyMeta;\n };\n const payerKeyMeta = getOrInsertDefault(payer);\n payerKeyMeta.isSigner = true;\n payerKeyMeta.isWritable = true;\n for (const ix of instructions) {\n getOrInsertDefault(ix.programId).isInvoked = true;\n for (const accountMeta of ix.keys) {\n const keyMeta = getOrInsertDefault(accountMeta.pubkey);\n keyMeta.isSigner ||= accountMeta.isSigner;\n keyMeta.isWritable ||= accountMeta.isWritable;\n }\n }\n return new CompiledKeys(payer, keyMetaMap);\n }\n getMessageComponents() {\n const mapEntries = [...this.keyMetaMap.entries()];\n assert(mapEntries.length <= 256, 'Max static account keys length exceeded');\n const writableSigners = mapEntries.filter(([, meta]) => meta.isSigner && meta.isWritable);\n const readonlySigners = mapEntries.filter(([, meta]) => meta.isSigner && !meta.isWritable);\n const writableNonSigners = mapEntries.filter(([, meta]) => !meta.isSigner && meta.isWritable);\n const readonlyNonSigners = mapEntries.filter(([, meta]) => !meta.isSigner && !meta.isWritable);\n const header = {\n numRequiredSignatures: writableSigners.length + readonlySigners.length,\n numReadonlySignedAccounts: readonlySigners.length,\n numReadonlyUnsignedAccounts: readonlyNonSigners.length\n };\n\n // sanity checks\n {\n assert(writableSigners.length > 0, 'Expected at least one writable signer key');\n const [payerAddress] = writableSigners[0];\n assert(payerAddress === this.payer.toBase58(), 'Expected first writable signer key to be the fee payer');\n }\n const staticAccountKeys = [...writableSigners.map(([address]) => new PublicKey(address)), ...readonlySigners.map(([address]) => new PublicKey(address)), ...writableNonSigners.map(([address]) => new PublicKey(address)), ...readonlyNonSigners.map(([address]) => new PublicKey(address))];\n return [header, staticAccountKeys];\n }\n extractTableLookup(lookupTable) {\n const [writableIndexes, drainedWritableKeys] = this.drainKeysFoundInLookupTable(lookupTable.state.addresses, keyMeta => !keyMeta.isSigner && !keyMeta.isInvoked && keyMeta.isWritable);\n const [readonlyIndexes, drainedReadonlyKeys] = this.drainKeysFoundInLookupTable(lookupTable.state.addresses, keyMeta => !keyMeta.isSigner && !keyMeta.isInvoked && !keyMeta.isWritable);\n\n // Don't extract lookup if no keys were found\n if (writableIndexes.length === 0 && readonlyIndexes.length === 0) {\n return;\n }\n return [{\n accountKey: lookupTable.key,\n writableIndexes,\n readonlyIndexes\n }, {\n writable: drainedWritableKeys,\n readonly: drainedReadonlyKeys\n }];\n }\n\n /** @internal */\n drainKeysFoundInLookupTable(lookupTableEntries, keyMetaFilter) {\n const lookupTableIndexes = new Array();\n const drainedKeys = new Array();\n for (const [address, keyMeta] of this.keyMetaMap.entries()) {\n if (keyMetaFilter(keyMeta)) {\n const key = new PublicKey(address);\n const lookupTableIndex = lookupTableEntries.findIndex(entry => entry.equals(key));\n if (lookupTableIndex >= 0) {\n assert(lookupTableIndex < 256, 'Max lookup table index exceeded');\n lookupTableIndexes.push(lookupTableIndex);\n drainedKeys.push(key);\n this.keyMetaMap.delete(address);\n }\n }\n }\n return [lookupTableIndexes, drainedKeys];\n }\n}\n\nconst END_OF_BUFFER_ERROR_MESSAGE = 'Reached end of buffer unexpectedly';\n\n/**\n * Delegates to `Array#shift`, but throws if the array is zero-length.\n */\nfunction guardedShift(byteArray) {\n if (byteArray.length === 0) {\n throw new Error(END_OF_BUFFER_ERROR_MESSAGE);\n }\n return byteArray.shift();\n}\n\n/**\n * Delegates to `Array#splice`, but throws if the section being spliced out extends past the end of\n * the array.\n */\nfunction guardedSplice(byteArray, ...args) {\n const [start] = args;\n if (args.length === 2 // Implies that `deleteCount` was supplied\n ? start + (args[1] ?? 0) > byteArray.length : start >= byteArray.length) {\n throw new Error(END_OF_BUFFER_ERROR_MESSAGE);\n }\n return byteArray.splice(...args);\n}\n\n/**\n * An instruction to execute by a program\n *\n * @property {number} programIdIndex\n * @property {number[]} accounts\n * @property {string} data\n */\n\n/**\n * Message constructor arguments\n */\n\n/**\n * List of instructions to be processed atomically\n */\nclass Message {\n constructor(args) {\n this.header = void 0;\n this.accountKeys = void 0;\n this.recentBlockhash = void 0;\n this.instructions = void 0;\n this.indexToProgramIds = new Map();\n this.header = args.header;\n this.accountKeys = args.accountKeys.map(account => new PublicKey(account));\n this.recentBlockhash = args.recentBlockhash;\n this.instructions = args.instructions;\n this.instructions.forEach(ix => this.indexToProgramIds.set(ix.programIdIndex, this.accountKeys[ix.programIdIndex]));\n }\n get version() {\n return 'legacy';\n }\n get staticAccountKeys() {\n return this.accountKeys;\n }\n get compiledInstructions() {\n return this.instructions.map(ix => ({\n programIdIndex: ix.programIdIndex,\n accountKeyIndexes: ix.accounts,\n data: bs58.decode(ix.data)\n }));\n }\n get addressTableLookups() {\n return [];\n }\n getAccountKeys() {\n return new MessageAccountKeys(this.staticAccountKeys);\n }\n static compile(args) {\n const compiledKeys = CompiledKeys.compile(args.instructions, args.payerKey);\n const [header, staticAccountKeys] = compiledKeys.getMessageComponents();\n const accountKeys = new MessageAccountKeys(staticAccountKeys);\n const instructions = accountKeys.compileInstructions(args.instructions).map(ix => ({\n programIdIndex: ix.programIdIndex,\n accounts: ix.accountKeyIndexes,\n data: bs58.encode(ix.data)\n }));\n return new Message({\n header,\n accountKeys: staticAccountKeys,\n recentBlockhash: args.recentBlockhash,\n instructions\n });\n }\n isAccountSigner(index) {\n return index < this.header.numRequiredSignatures;\n }\n isAccountWritable(index) {\n const numSignedAccounts = this.header.numRequiredSignatures;\n if (index >= this.header.numRequiredSignatures) {\n const unsignedAccountIndex = index - numSignedAccounts;\n const numUnsignedAccounts = this.accountKeys.length - numSignedAccounts;\n const numWritableUnsignedAccounts = numUnsignedAccounts - this.header.numReadonlyUnsignedAccounts;\n return unsignedAccountIndex < numWritableUnsignedAccounts;\n } else {\n const numWritableSignedAccounts = numSignedAccounts - this.header.numReadonlySignedAccounts;\n return index < numWritableSignedAccounts;\n }\n }\n isProgramId(index) {\n return this.indexToProgramIds.has(index);\n }\n programIds() {\n return [...this.indexToProgramIds.values()];\n }\n nonProgramIds() {\n return this.accountKeys.filter((_, index) => !this.isProgramId(index));\n }\n serialize() {\n const numKeys = this.accountKeys.length;\n let keyCount = [];\n encodeLength(keyCount, numKeys);\n const instructions = this.instructions.map(instruction => {\n const {\n accounts,\n programIdIndex\n } = instruction;\n const data = Array.from(bs58.decode(instruction.data));\n let keyIndicesCount = [];\n encodeLength(keyIndicesCount, accounts.length);\n let dataCount = [];\n encodeLength(dataCount, data.length);\n return {\n programIdIndex,\n keyIndicesCount: Buffer.from(keyIndicesCount),\n keyIndices: accounts,\n dataLength: Buffer.from(dataCount),\n data\n };\n });\n let instructionCount = [];\n encodeLength(instructionCount, instructions.length);\n let instructionBuffer = Buffer.alloc(PACKET_DATA_SIZE);\n Buffer.from(instructionCount).copy(instructionBuffer);\n let instructionBufferLength = instructionCount.length;\n instructions.forEach(instruction => {\n const instructionLayout = BufferLayout.struct([BufferLayout.u8('programIdIndex'), BufferLayout.blob(instruction.keyIndicesCount.length, 'keyIndicesCount'), BufferLayout.seq(BufferLayout.u8('keyIndex'), instruction.keyIndices.length, 'keyIndices'), BufferLayout.blob(instruction.dataLength.length, 'dataLength'), BufferLayout.seq(BufferLayout.u8('userdatum'), instruction.data.length, 'data')]);\n const length = instructionLayout.encode(instruction, instructionBuffer, instructionBufferLength);\n instructionBufferLength += length;\n });\n instructionBuffer = instructionBuffer.slice(0, instructionBufferLength);\n const signDataLayout = BufferLayout.struct([BufferLayout.blob(1, 'numRequiredSignatures'), BufferLayout.blob(1, 'numReadonlySignedAccounts'), BufferLayout.blob(1, 'numReadonlyUnsignedAccounts'), BufferLayout.blob(keyCount.length, 'keyCount'), BufferLayout.seq(publicKey('key'), numKeys, 'keys'), publicKey('recentBlockhash')]);\n const transaction = {\n numRequiredSignatures: Buffer.from([this.header.numRequiredSignatures]),\n numReadonlySignedAccounts: Buffer.from([this.header.numReadonlySignedAccounts]),\n numReadonlyUnsignedAccounts: Buffer.from([this.header.numReadonlyUnsignedAccounts]),\n keyCount: Buffer.from(keyCount),\n keys: this.accountKeys.map(key => toBuffer(key.toBytes())),\n recentBlockhash: bs58.decode(this.recentBlockhash)\n };\n let signData = Buffer.alloc(2048);\n const length = signDataLayout.encode(transaction, signData);\n instructionBuffer.copy(signData, length);\n return signData.slice(0, length + instructionBuffer.length);\n }\n\n /**\n * Decode a compiled message into a Message object.\n */\n static from(buffer) {\n // Slice up wire data\n let byteArray = [...buffer];\n const numRequiredSignatures = guardedShift(byteArray);\n if (numRequiredSignatures !== (numRequiredSignatures & VERSION_PREFIX_MASK)) {\n throw new Error('Versioned messages must be deserialized with VersionedMessage.deserialize()');\n }\n const numReadonlySignedAccounts = guardedShift(byteArray);\n const numReadonlyUnsignedAccounts = guardedShift(byteArray);\n const accountCount = decodeLength(byteArray);\n let accountKeys = [];\n for (let i = 0; i < accountCount; i++) {\n const account = guardedSplice(byteArray, 0, PUBLIC_KEY_LENGTH);\n accountKeys.push(new PublicKey(Buffer.from(account)));\n }\n const recentBlockhash = guardedSplice(byteArray, 0, PUBLIC_KEY_LENGTH);\n const instructionCount = decodeLength(byteArray);\n let instructions = [];\n for (let i = 0; i < instructionCount; i++) {\n const programIdIndex = guardedShift(byteArray);\n const accountCount = decodeLength(byteArray);\n const accounts = guardedSplice(byteArray, 0, accountCount);\n const dataLength = decodeLength(byteArray);\n const dataSlice = guardedSplice(byteArray, 0, dataLength);\n const data = bs58.encode(Buffer.from(dataSlice));\n instructions.push({\n programIdIndex,\n accounts,\n data\n });\n }\n const messageArgs = {\n header: {\n numRequiredSignatures,\n numReadonlySignedAccounts,\n numReadonlyUnsignedAccounts\n },\n recentBlockhash: bs58.encode(Buffer.from(recentBlockhash)),\n accountKeys,\n instructions\n };\n return new Message(messageArgs);\n }\n}\n\n/**\n * Message constructor arguments\n */\n\nclass MessageV0 {\n constructor(args) {\n this.header = void 0;\n this.staticAccountKeys = void 0;\n this.recentBlockhash = void 0;\n this.compiledInstructions = void 0;\n this.addressTableLookups = void 0;\n this.header = args.header;\n this.staticAccountKeys = args.staticAccountKeys;\n this.recentBlockhash = args.recentBlockhash;\n this.compiledInstructions = args.compiledInstructions;\n this.addressTableLookups = args.addressTableLookups;\n }\n get version() {\n return 0;\n }\n get numAccountKeysFromLookups() {\n let count = 0;\n for (const lookup of this.addressTableLookups) {\n count += lookup.readonlyIndexes.length + lookup.writableIndexes.length;\n }\n return count;\n }\n getAccountKeys(args) {\n let accountKeysFromLookups;\n if (args && 'accountKeysFromLookups' in args && args.accountKeysFromLookups) {\n if (this.numAccountKeysFromLookups != args.accountKeysFromLookups.writable.length + args.accountKeysFromLookups.readonly.length) {\n throw new Error('Failed to get account keys because of a mismatch in the number of account keys from lookups');\n }\n accountKeysFromLookups = args.accountKeysFromLookups;\n } else if (args && 'addressLookupTableAccounts' in args && args.addressLookupTableAccounts) {\n accountKeysFromLookups = this.resolveAddressTableLookups(args.addressLookupTableAccounts);\n } else if (this.addressTableLookups.length > 0) {\n throw new Error('Failed to get account keys because address table lookups were not resolved');\n }\n return new MessageAccountKeys(this.staticAccountKeys, accountKeysFromLookups);\n }\n isAccountSigner(index) {\n return index < this.header.numRequiredSignatures;\n }\n isAccountWritable(index) {\n const numSignedAccounts = this.header.numRequiredSignatures;\n const numStaticAccountKeys = this.staticAccountKeys.length;\n if (index >= numStaticAccountKeys) {\n const lookupAccountKeysIndex = index - numStaticAccountKeys;\n const numWritableLookupAccountKeys = this.addressTableLookups.reduce((count, lookup) => count + lookup.writableIndexes.length, 0);\n return lookupAccountKeysIndex < numWritableLookupAccountKeys;\n } else if (index >= this.header.numRequiredSignatures) {\n const unsignedAccountIndex = index - numSignedAccounts;\n const numUnsignedAccounts = numStaticAccountKeys - numSignedAccounts;\n const numWritableUnsignedAccounts = numUnsignedAccounts - this.header.numReadonlyUnsignedAccounts;\n return unsignedAccountIndex < numWritableUnsignedAccounts;\n } else {\n const numWritableSignedAccounts = numSignedAccounts - this.header.numReadonlySignedAccounts;\n return index < numWritableSignedAccounts;\n }\n }\n resolveAddressTableLookups(addressLookupTableAccounts) {\n const accountKeysFromLookups = {\n writable: [],\n readonly: []\n };\n for (const tableLookup of this.addressTableLookups) {\n const tableAccount = addressLookupTableAccounts.find(account => account.key.equals(tableLookup.accountKey));\n if (!tableAccount) {\n throw new Error(`Failed to find address lookup table account for table key ${tableLookup.accountKey.toBase58()}`);\n }\n for (const index of tableLookup.writableIndexes) {\n if (index < tableAccount.state.addresses.length) {\n accountKeysFromLookups.writable.push(tableAccount.state.addresses[index]);\n } else {\n throw new Error(`Failed to find address for index ${index} in address lookup table ${tableLookup.accountKey.toBase58()}`);\n }\n }\n for (const index of tableLookup.readonlyIndexes) {\n if (index < tableAccount.state.addresses.length) {\n accountKeysFromLookups.readonly.push(tableAccount.state.addresses[index]);\n } else {\n throw new Error(`Failed to find address for index ${index} in address lookup table ${tableLookup.accountKey.toBase58()}`);\n }\n }\n }\n return accountKeysFromLookups;\n }\n static compile(args) {\n const compiledKeys = CompiledKeys.compile(args.instructions, args.payerKey);\n const addressTableLookups = new Array();\n const accountKeysFromLookups = {\n writable: new Array(),\n readonly: new Array()\n };\n const lookupTableAccounts = args.addressLookupTableAccounts || [];\n for (const lookupTable of lookupTableAccounts) {\n const extractResult = compiledKeys.extractTableLookup(lookupTable);\n if (extractResult !== undefined) {\n const [addressTableLookup, {\n writable,\n readonly\n }] = extractResult;\n addressTableLookups.push(addressTableLookup);\n accountKeysFromLookups.writable.push(...writable);\n accountKeysFromLookups.readonly.push(...readonly);\n }\n }\n const [header, staticAccountKeys] = compiledKeys.getMessageComponents();\n const accountKeys = new MessageAccountKeys(staticAccountKeys, accountKeysFromLookups);\n const compiledInstructions = accountKeys.compileInstructions(args.instructions);\n return new MessageV0({\n header,\n staticAccountKeys,\n recentBlockhash: args.recentBlockhash,\n compiledInstructions,\n addressTableLookups\n });\n }\n serialize() {\n const encodedStaticAccountKeysLength = Array();\n encodeLength(encodedStaticAccountKeysLength, this.staticAccountKeys.length);\n const serializedInstructions = this.serializeInstructions();\n const encodedInstructionsLength = Array();\n encodeLength(encodedInstructionsLength, this.compiledInstructions.length);\n const serializedAddressTableLookups = this.serializeAddressTableLookups();\n const encodedAddressTableLookupsLength = Array();\n encodeLength(encodedAddressTableLookupsLength, this.addressTableLookups.length);\n const messageLayout = BufferLayout.struct([BufferLayout.u8('prefix'), BufferLayout.struct([BufferLayout.u8('numRequiredSignatures'), BufferLayout.u8('numReadonlySignedAccounts'), BufferLayout.u8('numReadonlyUnsignedAccounts')], 'header'), BufferLayout.blob(encodedStaticAccountKeysLength.length, 'staticAccountKeysLength'), BufferLayout.seq(publicKey(), this.staticAccountKeys.length, 'staticAccountKeys'), publicKey('recentBlockhash'), BufferLayout.blob(encodedInstructionsLength.length, 'instructionsLength'), BufferLayout.blob(serializedInstructions.length, 'serializedInstructions'), BufferLayout.blob(encodedAddressTableLookupsLength.length, 'addressTableLookupsLength'), BufferLayout.blob(serializedAddressTableLookups.length, 'serializedAddressTableLookups')]);\n const serializedMessage = new Uint8Array(PACKET_DATA_SIZE);\n const MESSAGE_VERSION_0_PREFIX = 1 << 7;\n const serializedMessageLength = messageLayout.encode({\n prefix: MESSAGE_VERSION_0_PREFIX,\n header: this.header,\n staticAccountKeysLength: new Uint8Array(encodedStaticAccountKeysLength),\n staticAccountKeys: this.staticAccountKeys.map(key => key.toBytes()),\n recentBlockhash: bs58.decode(this.recentBlockhash),\n instructionsLength: new Uint8Array(encodedInstructionsLength),\n serializedInstructions,\n addressTableLookupsLength: new Uint8Array(encodedAddressTableLookupsLength),\n serializedAddressTableLookups\n }, serializedMessage);\n return serializedMessage.slice(0, serializedMessageLength);\n }\n serializeInstructions() {\n let serializedLength = 0;\n const serializedInstructions = new Uint8Array(PACKET_DATA_SIZE);\n for (const instruction of this.compiledInstructions) {\n const encodedAccountKeyIndexesLength = Array();\n encodeLength(encodedAccountKeyIndexesLength, instruction.accountKeyIndexes.length);\n const encodedDataLength = Array();\n encodeLength(encodedDataLength, instruction.data.length);\n const instructionLayout = BufferLayout.struct([BufferLayout.u8('programIdIndex'), BufferLayout.blob(encodedAccountKeyIndexesLength.length, 'encodedAccountKeyIndexesLength'), BufferLayout.seq(BufferLayout.u8(), instruction.accountKeyIndexes.length, 'accountKeyIndexes'), BufferLayout.blob(encodedDataLength.length, 'encodedDataLength'), BufferLayout.blob(instruction.data.length, 'data')]);\n serializedLength += instructionLayout.encode({\n programIdIndex: instruction.programIdIndex,\n encodedAccountKeyIndexesLength: new Uint8Array(encodedAccountKeyIndexesLength),\n accountKeyIndexes: instruction.accountKeyIndexes,\n encodedDataLength: new Uint8Array(encodedDataLength),\n data: instruction.data\n }, serializedInstructions, serializedLength);\n }\n return serializedInstructions.slice(0, serializedLength);\n }\n serializeAddressTableLookups() {\n let serializedLength = 0;\n const serializedAddressTableLookups = new Uint8Array(PACKET_DATA_SIZE);\n for (const lookup of this.addressTableLookups) {\n const encodedWritableIndexesLength = Array();\n encodeLength(encodedWritableIndexesLength, lookup.writableIndexes.length);\n const encodedReadonlyIndexesLength = Array();\n encodeLength(encodedReadonlyIndexesLength, lookup.readonlyIndexes.length);\n const addressTableLookupLayout = BufferLayout.struct([publicKey('accountKey'), BufferLayout.blob(encodedWritableIndexesLength.length, 'encodedWritableIndexesLength'), BufferLayout.seq(BufferLayout.u8(), lookup.writableIndexes.length, 'writableIndexes'), BufferLayout.blob(encodedReadonlyIndexesLength.length, 'encodedReadonlyIndexesLength'), BufferLayout.seq(BufferLayout.u8(), lookup.readonlyIndexes.length, 'readonlyIndexes')]);\n serializedLength += addressTableLookupLayout.encode({\n accountKey: lookup.accountKey.toBytes(),\n encodedWritableIndexesLength: new Uint8Array(encodedWritableIndexesLength),\n writableIndexes: lookup.writableIndexes,\n encodedReadonlyIndexesLength: new Uint8Array(encodedReadonlyIndexesLength),\n readonlyIndexes: lookup.readonlyIndexes\n }, serializedAddressTableLookups, serializedLength);\n }\n return serializedAddressTableLookups.slice(0, serializedLength);\n }\n static deserialize(serializedMessage) {\n let byteArray = [...serializedMessage];\n const prefix = guardedShift(byteArray);\n const maskedPrefix = prefix & VERSION_PREFIX_MASK;\n assert(prefix !== maskedPrefix, `Expected versioned message but received legacy message`);\n const version = maskedPrefix;\n assert(version === 0, `Expected versioned message with version 0 but found version ${version}`);\n const header = {\n numRequiredSignatures: guardedShift(byteArray),\n numReadonlySignedAccounts: guardedShift(byteArray),\n numReadonlyUnsignedAccounts: guardedShift(byteArray)\n };\n const staticAccountKeys = [];\n const staticAccountKeysLength = decodeLength(byteArray);\n for (let i = 0; i < staticAccountKeysLength; i++) {\n staticAccountKeys.push(new PublicKey(guardedSplice(byteArray, 0, PUBLIC_KEY_LENGTH)));\n }\n const recentBlockhash = bs58.encode(guardedSplice(byteArray, 0, PUBLIC_KEY_LENGTH));\n const instructionCount = decodeLength(byteArray);\n const compiledInstructions = [];\n for (let i = 0; i < instructionCount; i++) {\n const programIdIndex = guardedShift(byteArray);\n const accountKeyIndexesLength = decodeLength(byteArray);\n const accountKeyIndexes = guardedSplice(byteArray, 0, accountKeyIndexesLength);\n const dataLength = decodeLength(byteArray);\n const data = new Uint8Array(guardedSplice(byteArray, 0, dataLength));\n compiledInstructions.push({\n programIdIndex,\n accountKeyIndexes,\n data\n });\n }\n const addressTableLookupsCount = decodeLength(byteArray);\n const addressTableLookups = [];\n for (let i = 0; i < addressTableLookupsCount; i++) {\n const accountKey = new PublicKey(guardedSplice(byteArray, 0, PUBLIC_KEY_LENGTH));\n const writableIndexesLength = decodeLength(byteArray);\n const writableIndexes = guardedSplice(byteArray, 0, writableIndexesLength);\n const readonlyIndexesLength = decodeLength(byteArray);\n const readonlyIndexes = guardedSplice(byteArray, 0, readonlyIndexesLength);\n addressTableLookups.push({\n accountKey,\n writableIndexes,\n readonlyIndexes\n });\n }\n return new MessageV0({\n header,\n staticAccountKeys,\n recentBlockhash,\n compiledInstructions,\n addressTableLookups\n });\n }\n}\n\n// eslint-disable-next-line no-redeclare\nconst VersionedMessage = {\n deserializeMessageVersion(serializedMessage) {\n const prefix = serializedMessage[0];\n const maskedPrefix = prefix & VERSION_PREFIX_MASK;\n\n // if the highest bit of the prefix is not set, the message is not versioned\n if (maskedPrefix === prefix) {\n return 'legacy';\n }\n\n // the lower 7 bits of the prefix indicate the message version\n return maskedPrefix;\n },\n deserialize: serializedMessage => {\n const version = VersionedMessage.deserializeMessageVersion(serializedMessage);\n if (version === 'legacy') {\n return Message.from(serializedMessage);\n }\n if (version === 0) {\n return MessageV0.deserialize(serializedMessage);\n } else {\n throw new Error(`Transaction message version ${version} deserialization is not supported`);\n }\n }\n};\n\n/** @internal */\n\n/**\n * Transaction signature as base-58 encoded string\n */\n\nlet TransactionStatus = /*#__PURE__*/function (TransactionStatus) {\n TransactionStatus[TransactionStatus[\"BLOCKHEIGHT_EXCEEDED\"] = 0] = \"BLOCKHEIGHT_EXCEEDED\";\n TransactionStatus[TransactionStatus[\"PROCESSED\"] = 1] = \"PROCESSED\";\n TransactionStatus[TransactionStatus[\"TIMED_OUT\"] = 2] = \"TIMED_OUT\";\n TransactionStatus[TransactionStatus[\"NONCE_INVALID\"] = 3] = \"NONCE_INVALID\";\n return TransactionStatus;\n}({});\n\n/**\n * Default (empty) signature\n */\nconst DEFAULT_SIGNATURE = Buffer.alloc(SIGNATURE_LENGTH_IN_BYTES).fill(0);\n\n/**\n * Account metadata used to define instructions\n */\n\n/**\n * List of TransactionInstruction object fields that may be initialized at construction\n */\n\n/**\n * Configuration object for Transaction.serialize()\n */\n\n/**\n * @internal\n */\n\n/**\n * Transaction Instruction class\n */\nclass TransactionInstruction {\n constructor(opts) {\n /**\n * Public keys to include in this transaction\n * Boolean represents whether this pubkey needs to sign the transaction\n */\n this.keys = void 0;\n /**\n * Program Id to execute\n */\n this.programId = void 0;\n /**\n * Program input\n */\n this.data = Buffer.alloc(0);\n this.programId = opts.programId;\n this.keys = opts.keys;\n if (opts.data) {\n this.data = opts.data;\n }\n }\n\n /**\n * @internal\n */\n toJSON() {\n return {\n keys: this.keys.map(({\n pubkey,\n isSigner,\n isWritable\n }) => ({\n pubkey: pubkey.toJSON(),\n isSigner,\n isWritable\n })),\n programId: this.programId.toJSON(),\n data: [...this.data]\n };\n }\n}\n\n/**\n * Pair of signature and corresponding public key\n */\n\n/**\n * List of Transaction object fields that may be initialized at construction\n */\n\n// For backward compatibility; an unfortunate consequence of being\n// forced to over-export types by the documentation generator.\n// See https://github.com/solana-labs/solana/pull/25820\n\n/**\n * Blockhash-based transactions have a lifetime that are defined by\n * the blockhash they include. Any transaction whose blockhash is\n * too old will be rejected.\n */\n\n/**\n * Use these options to construct a durable nonce transaction.\n */\n\n/**\n * Nonce information to be used to build an offline Transaction.\n */\n\n/**\n * @internal\n */\n\n/**\n * Transaction class\n */\nclass Transaction {\n /**\n * The first (payer) Transaction signature\n *\n * @returns {Buffer | null} Buffer of payer's signature\n */\n get signature() {\n if (this.signatures.length > 0) {\n return this.signatures[0].signature;\n }\n return null;\n }\n\n /**\n * The transaction fee payer\n */\n\n // Construct a transaction with a blockhash and lastValidBlockHeight\n\n // Construct a transaction using a durable nonce\n\n /**\n * @deprecated `TransactionCtorFields` has been deprecated and will be removed in a future version.\n * Please supply a `TransactionBlockhashCtor` instead.\n */\n\n /**\n * Construct an empty Transaction\n */\n constructor(opts) {\n /**\n * Signatures for the transaction. Typically created by invoking the\n * `sign()` method\n */\n this.signatures = [];\n this.feePayer = void 0;\n /**\n * The instructions to atomically execute\n */\n this.instructions = [];\n /**\n * A recent transaction id. Must be populated by the caller\n */\n this.recentBlockhash = void 0;\n /**\n * the last block chain can advance to before tx is declared expired\n * */\n this.lastValidBlockHeight = void 0;\n /**\n * Optional Nonce information. If populated, transaction will use a durable\n * Nonce hash instead of a recentBlockhash. Must be populated by the caller\n */\n this.nonceInfo = void 0;\n /**\n * If this is a nonce transaction this represents the minimum slot from which\n * to evaluate if the nonce has advanced when attempting to confirm the\n * transaction. This protects against a case where the transaction confirmation\n * logic loads the nonce account from an old slot and assumes the mismatch in\n * nonce value implies that the nonce has been advanced.\n */\n this.minNonceContextSlot = void 0;\n /**\n * @internal\n */\n this._message = void 0;\n /**\n * @internal\n */\n this._json = void 0;\n if (!opts) {\n return;\n }\n if (opts.feePayer) {\n this.feePayer = opts.feePayer;\n }\n if (opts.signatures) {\n this.signatures = opts.signatures;\n }\n if (Object.prototype.hasOwnProperty.call(opts, 'nonceInfo')) {\n const {\n minContextSlot,\n nonceInfo\n } = opts;\n this.minNonceContextSlot = minContextSlot;\n this.nonceInfo = nonceInfo;\n } else if (Object.prototype.hasOwnProperty.call(opts, 'lastValidBlockHeight')) {\n const {\n blockhash,\n lastValidBlockHeight\n } = opts;\n this.recentBlockhash = blockhash;\n this.lastValidBlockHeight = lastValidBlockHeight;\n } else {\n const {\n recentBlockhash,\n nonceInfo\n } = opts;\n if (nonceInfo) {\n this.nonceInfo = nonceInfo;\n }\n this.recentBlockhash = recentBlockhash;\n }\n }\n\n /**\n * @internal\n */\n toJSON() {\n return {\n recentBlockhash: this.recentBlockhash || null,\n feePayer: this.feePayer ? this.feePayer.toJSON() : null,\n nonceInfo: this.nonceInfo ? {\n nonce: this.nonceInfo.nonce,\n nonceInstruction: this.nonceInfo.nonceInstruction.toJSON()\n } : null,\n instructions: this.instructions.map(instruction => instruction.toJSON()),\n signers: this.signatures.map(({\n publicKey\n }) => {\n return publicKey.toJSON();\n })\n };\n }\n\n /**\n * Add one or more instructions to this Transaction\n *\n * @param {Array< Transaction | TransactionInstruction | TransactionInstructionCtorFields >} items - Instructions to add to the Transaction\n */\n add(...items) {\n if (items.length === 0) {\n throw new Error('No instructions');\n }\n items.forEach(item => {\n if ('instructions' in item) {\n this.instructions = this.instructions.concat(item.instructions);\n } else if ('data' in item && 'programId' in item && 'keys' in item) {\n this.instructions.push(item);\n } else {\n this.instructions.push(new TransactionInstruction(item));\n }\n });\n return this;\n }\n\n /**\n * Compile transaction data\n */\n compileMessage() {\n if (this._message && JSON.stringify(this.toJSON()) === JSON.stringify(this._json)) {\n return this._message;\n }\n let recentBlockhash;\n let instructions;\n if (this.nonceInfo) {\n recentBlockhash = this.nonceInfo.nonce;\n if (this.instructions[0] != this.nonceInfo.nonceInstruction) {\n instructions = [this.nonceInfo.nonceInstruction, ...this.instructions];\n } else {\n instructions = this.instructions;\n }\n } else {\n recentBlockhash = this.recentBlockhash;\n instructions = this.instructions;\n }\n if (!recentBlockhash) {\n throw new Error('Transaction recentBlockhash required');\n }\n if (instructions.length < 1) {\n console.warn('No instructions provided');\n }\n let feePayer;\n if (this.feePayer) {\n feePayer = this.feePayer;\n } else if (this.signatures.length > 0 && this.signatures[0].publicKey) {\n // Use implicit fee payer\n feePayer = this.signatures[0].publicKey;\n } else {\n throw new Error('Transaction fee payer required');\n }\n for (let i = 0; i < instructions.length; i++) {\n if (instructions[i].programId === undefined) {\n throw new Error(`Transaction instruction index ${i} has undefined program id`);\n }\n }\n const programIds = [];\n const accountMetas = [];\n instructions.forEach(instruction => {\n instruction.keys.forEach(accountMeta => {\n accountMetas.push({\n ...accountMeta\n });\n });\n const programId = instruction.programId.toString();\n if (!programIds.includes(programId)) {\n programIds.push(programId);\n }\n });\n\n // Append programID account metas\n programIds.forEach(programId => {\n accountMetas.push({\n pubkey: new PublicKey(programId),\n isSigner: false,\n isWritable: false\n });\n });\n\n // Cull duplicate account metas\n const uniqueMetas = [];\n accountMetas.forEach(accountMeta => {\n const pubkeyString = accountMeta.pubkey.toString();\n const uniqueIndex = uniqueMetas.findIndex(x => {\n return x.pubkey.toString() === pubkeyString;\n });\n if (uniqueIndex > -1) {\n uniqueMetas[uniqueIndex].isWritable = uniqueMetas[uniqueIndex].isWritable || accountMeta.isWritable;\n uniqueMetas[uniqueIndex].isSigner = uniqueMetas[uniqueIndex].isSigner || accountMeta.isSigner;\n } else {\n uniqueMetas.push(accountMeta);\n }\n });\n\n // Sort. Prioritizing first by signer, then by writable\n uniqueMetas.sort(function (x, y) {\n if (x.isSigner !== y.isSigner) {\n // Signers always come before non-signers\n return x.isSigner ? -1 : 1;\n }\n if (x.isWritable !== y.isWritable) {\n // Writable accounts always come before read-only accounts\n return x.isWritable ? -1 : 1;\n }\n // Otherwise, sort by pubkey, stringwise.\n const options = {\n localeMatcher: 'best fit',\n usage: 'sort',\n sensitivity: 'variant',\n ignorePunctuation: false,\n numeric: false,\n caseFirst: 'lower'\n };\n return x.pubkey.toBase58().localeCompare(y.pubkey.toBase58(), 'en', options);\n });\n\n // Move fee payer to the front\n const feePayerIndex = uniqueMetas.findIndex(x => {\n return x.pubkey.equals(feePayer);\n });\n if (feePayerIndex > -1) {\n const [payerMeta] = uniqueMetas.splice(feePayerIndex, 1);\n payerMeta.isSigner = true;\n payerMeta.isWritable = true;\n uniqueMetas.unshift(payerMeta);\n } else {\n uniqueMetas.unshift({\n pubkey: feePayer,\n isSigner: true,\n isWritable: true\n });\n }\n\n // Disallow unknown signers\n for (const signature of this.signatures) {\n const uniqueIndex = uniqueMetas.findIndex(x => {\n return x.pubkey.equals(signature.publicKey);\n });\n if (uniqueIndex > -1) {\n if (!uniqueMetas[uniqueIndex].isSigner) {\n uniqueMetas[uniqueIndex].isSigner = true;\n console.warn('Transaction references a signature that is unnecessary, ' + 'only the fee payer and instruction signer accounts should sign a transaction. ' + 'This behavior is deprecated and will throw an error in the next major version release.');\n }\n } else {\n throw new Error(`unknown signer: ${signature.publicKey.toString()}`);\n }\n }\n let numRequiredSignatures = 0;\n let numReadonlySignedAccounts = 0;\n let numReadonlyUnsignedAccounts = 0;\n\n // Split out signing from non-signing keys and count header values\n const signedKeys = [];\n const unsignedKeys = [];\n uniqueMetas.forEach(({\n pubkey,\n isSigner,\n isWritable\n }) => {\n if (isSigner) {\n signedKeys.push(pubkey.toString());\n numRequiredSignatures += 1;\n if (!isWritable) {\n numReadonlySignedAccounts += 1;\n }\n } else {\n unsignedKeys.push(pubkey.toString());\n if (!isWritable) {\n numReadonlyUnsignedAccounts += 1;\n }\n }\n });\n const accountKeys = signedKeys.concat(unsignedKeys);\n const compiledInstructions = instructions.map(instruction => {\n const {\n data,\n programId\n } = instruction;\n return {\n programIdIndex: accountKeys.indexOf(programId.toString()),\n accounts: instruction.keys.map(meta => accountKeys.indexOf(meta.pubkey.toString())),\n data: bs58.encode(data)\n };\n });\n compiledInstructions.forEach(instruction => {\n assert(instruction.programIdIndex >= 0);\n instruction.accounts.forEach(keyIndex => assert(keyIndex >= 0));\n });\n return new Message({\n header: {\n numRequiredSignatures,\n numReadonlySignedAccounts,\n numReadonlyUnsignedAccounts\n },\n accountKeys,\n recentBlockhash,\n instructions: compiledInstructions\n });\n }\n\n /**\n * @internal\n */\n _compile() {\n const message = this.compileMessage();\n const signedKeys = message.accountKeys.slice(0, message.header.numRequiredSignatures);\n if (this.signatures.length === signedKeys.length) {\n const valid = this.signatures.every((pair, index) => {\n return signedKeys[index].equals(pair.publicKey);\n });\n if (valid) return message;\n }\n this.signatures = signedKeys.map(publicKey => ({\n signature: null,\n publicKey\n }));\n return message;\n }\n\n /**\n * Get a buffer of the Transaction data that need to be covered by signatures\n */\n serializeMessage() {\n return this._compile().serialize();\n }\n\n /**\n * Get the estimated fee associated with a transaction\n *\n * @param {Connection} connection Connection to RPC Endpoint.\n *\n * @returns {Promise} The estimated fee for the transaction\n */\n async getEstimatedFee(connection) {\n return (await connection.getFeeForMessage(this.compileMessage())).value;\n }\n\n /**\n * Specify the public keys which will be used to sign the Transaction.\n * The first signer will be used as the transaction fee payer account.\n *\n * Signatures can be added with either `partialSign` or `addSignature`\n *\n * @deprecated Deprecated since v0.84.0. Only the fee payer needs to be\n * specified and it can be set in the Transaction constructor or with the\n * `feePayer` property.\n */\n setSigners(...signers) {\n if (signers.length === 0) {\n throw new Error('No signers');\n }\n const seen = new Set();\n this.signatures = signers.filter(publicKey => {\n const key = publicKey.toString();\n if (seen.has(key)) {\n return false;\n } else {\n seen.add(key);\n return true;\n }\n }).map(publicKey => ({\n signature: null,\n publicKey\n }));\n }\n\n /**\n * Sign the Transaction with the specified signers. Multiple signatures may\n * be applied to a Transaction. The first signature is considered \"primary\"\n * and is used identify and confirm transactions.\n *\n * If the Transaction `feePayer` is not set, the first signer will be used\n * as the transaction fee payer account.\n *\n * Transaction fields should not be modified after the first call to `sign`,\n * as doing so may invalidate the signature and cause the Transaction to be\n * rejected.\n *\n * The Transaction must be assigned a valid `recentBlockhash` before invoking this method\n *\n * @param {Array} signers Array of signers that will sign the transaction\n */\n sign(...signers) {\n if (signers.length === 0) {\n throw new Error('No signers');\n }\n\n // Dedupe signers\n const seen = new Set();\n const uniqueSigners = [];\n for (const signer of signers) {\n const key = signer.publicKey.toString();\n if (seen.has(key)) {\n continue;\n } else {\n seen.add(key);\n uniqueSigners.push(signer);\n }\n }\n this.signatures = uniqueSigners.map(signer => ({\n signature: null,\n publicKey: signer.publicKey\n }));\n const message = this._compile();\n this._partialSign(message, ...uniqueSigners);\n }\n\n /**\n * Partially sign a transaction with the specified accounts. All accounts must\n * correspond to either the fee payer or a signer account in the transaction\n * instructions.\n *\n * All the caveats from the `sign` method apply to `partialSign`\n *\n * @param {Array} signers Array of signers that will sign the transaction\n */\n partialSign(...signers) {\n if (signers.length === 0) {\n throw new Error('No signers');\n }\n\n // Dedupe signers\n const seen = new Set();\n const uniqueSigners = [];\n for (const signer of signers) {\n const key = signer.publicKey.toString();\n if (seen.has(key)) {\n continue;\n } else {\n seen.add(key);\n uniqueSigners.push(signer);\n }\n }\n const message = this._compile();\n this._partialSign(message, ...uniqueSigners);\n }\n\n /**\n * @internal\n */\n _partialSign(message, ...signers) {\n const signData = message.serialize();\n signers.forEach(signer => {\n const signature = sign(signData, signer.secretKey);\n this._addSignature(signer.publicKey, toBuffer(signature));\n });\n }\n\n /**\n * Add an externally created signature to a transaction. The public key\n * must correspond to either the fee payer or a signer account in the transaction\n * instructions.\n *\n * @param {PublicKey} pubkey Public key that will be added to the transaction.\n * @param {Buffer} signature An externally created signature to add to the transaction.\n */\n addSignature(pubkey, signature) {\n this._compile(); // Ensure signatures array is populated\n this._addSignature(pubkey, signature);\n }\n\n /**\n * @internal\n */\n _addSignature(pubkey, signature) {\n assert(signature.length === 64);\n const index = this.signatures.findIndex(sigpair => pubkey.equals(sigpair.publicKey));\n if (index < 0) {\n throw new Error(`unknown signer: ${pubkey.toString()}`);\n }\n this.signatures[index].signature = Buffer.from(signature);\n }\n\n /**\n * Verify signatures of a Transaction\n * Optional parameter specifies if we're expecting a fully signed Transaction or a partially signed one.\n * If no boolean is provided, we expect a fully signed Transaction by default.\n *\n * @param {boolean} [requireAllSignatures=true] Require a fully signed Transaction\n */\n verifySignatures(requireAllSignatures = true) {\n const signatureErrors = this._getMessageSignednessErrors(this.serializeMessage(), requireAllSignatures);\n return !signatureErrors;\n }\n\n /**\n * @internal\n */\n _getMessageSignednessErrors(message, requireAllSignatures) {\n const errors = {};\n for (const {\n signature,\n publicKey\n } of this.signatures) {\n if (signature === null) {\n if (requireAllSignatures) {\n (errors.missing ||= []).push(publicKey);\n }\n } else {\n if (!verify(signature, message, publicKey.toBytes())) {\n (errors.invalid ||= []).push(publicKey);\n }\n }\n }\n return errors.invalid || errors.missing ? errors : undefined;\n }\n\n /**\n * Serialize the Transaction in the wire format.\n *\n * @param {Buffer} [config] Config of transaction.\n *\n * @returns {Buffer} Signature of transaction in wire format.\n */\n serialize(config) {\n const {\n requireAllSignatures,\n verifySignatures\n } = Object.assign({\n requireAllSignatures: true,\n verifySignatures: true\n }, config);\n const signData = this.serializeMessage();\n if (verifySignatures) {\n const sigErrors = this._getMessageSignednessErrors(signData, requireAllSignatures);\n if (sigErrors) {\n let errorMessage = 'Signature verification failed.';\n if (sigErrors.invalid) {\n errorMessage += `\\nInvalid signature for public key${sigErrors.invalid.length === 1 ? '' : '(s)'} [\\`${sigErrors.invalid.map(p => p.toBase58()).join('`, `')}\\`].`;\n }\n if (sigErrors.missing) {\n errorMessage += `\\nMissing signature for public key${sigErrors.missing.length === 1 ? '' : '(s)'} [\\`${sigErrors.missing.map(p => p.toBase58()).join('`, `')}\\`].`;\n }\n throw new Error(errorMessage);\n }\n }\n return this._serialize(signData);\n }\n\n /**\n * @internal\n */\n _serialize(signData) {\n const {\n signatures\n } = this;\n const signatureCount = [];\n encodeLength(signatureCount, signatures.length);\n const transactionLength = signatureCount.length + signatures.length * 64 + signData.length;\n const wireTransaction = Buffer.alloc(transactionLength);\n assert(signatures.length < 256);\n Buffer.from(signatureCount).copy(wireTransaction, 0);\n signatures.forEach(({\n signature\n }, index) => {\n if (signature !== null) {\n assert(signature.length === 64, `signature has invalid length`);\n Buffer.from(signature).copy(wireTransaction, signatureCount.length + index * 64);\n }\n });\n signData.copy(wireTransaction, signatureCount.length + signatures.length * 64);\n assert(wireTransaction.length <= PACKET_DATA_SIZE, `Transaction too large: ${wireTransaction.length} > ${PACKET_DATA_SIZE}`);\n return wireTransaction;\n }\n\n /**\n * Deprecated method\n * @internal\n */\n get keys() {\n assert(this.instructions.length === 1);\n return this.instructions[0].keys.map(keyObj => keyObj.pubkey);\n }\n\n /**\n * Deprecated method\n * @internal\n */\n get programId() {\n assert(this.instructions.length === 1);\n return this.instructions[0].programId;\n }\n\n /**\n * Deprecated method\n * @internal\n */\n get data() {\n assert(this.instructions.length === 1);\n return this.instructions[0].data;\n }\n\n /**\n * Parse a wire transaction into a Transaction object.\n *\n * @param {Buffer | Uint8Array | Array} buffer Signature of wire Transaction\n *\n * @returns {Transaction} Transaction associated with the signature\n */\n static from(buffer) {\n // Slice up wire data\n let byteArray = [...buffer];\n const signatureCount = decodeLength(byteArray);\n let signatures = [];\n for (let i = 0; i < signatureCount; i++) {\n const signature = guardedSplice(byteArray, 0, SIGNATURE_LENGTH_IN_BYTES);\n signatures.push(bs58.encode(Buffer.from(signature)));\n }\n return Transaction.populate(Message.from(byteArray), signatures);\n }\n\n /**\n * Populate Transaction object from message and signatures\n *\n * @param {Message} message Message of transaction\n * @param {Array} signatures List of signatures to assign to the transaction\n *\n * @returns {Transaction} The populated Transaction\n */\n static populate(message, signatures = []) {\n const transaction = new Transaction();\n transaction.recentBlockhash = message.recentBlockhash;\n if (message.header.numRequiredSignatures > 0) {\n transaction.feePayer = message.accountKeys[0];\n }\n signatures.forEach((signature, index) => {\n const sigPubkeyPair = {\n signature: signature == bs58.encode(DEFAULT_SIGNATURE) ? null : bs58.decode(signature),\n publicKey: message.accountKeys[index]\n };\n transaction.signatures.push(sigPubkeyPair);\n });\n message.instructions.forEach(instruction => {\n const keys = instruction.accounts.map(account => {\n const pubkey = message.accountKeys[account];\n return {\n pubkey,\n isSigner: transaction.signatures.some(keyObj => keyObj.publicKey.toString() === pubkey.toString()) || message.isAccountSigner(account),\n isWritable: message.isAccountWritable(account)\n };\n });\n transaction.instructions.push(new TransactionInstruction({\n keys,\n programId: message.accountKeys[instruction.programIdIndex],\n data: bs58.decode(instruction.data)\n }));\n });\n transaction._message = message;\n transaction._json = transaction.toJSON();\n return transaction;\n }\n}\n\nclass TransactionMessage {\n constructor(args) {\n this.payerKey = void 0;\n this.instructions = void 0;\n this.recentBlockhash = void 0;\n this.payerKey = args.payerKey;\n this.instructions = args.instructions;\n this.recentBlockhash = args.recentBlockhash;\n }\n static decompile(message, args) {\n const {\n header,\n compiledInstructions,\n recentBlockhash\n } = message;\n const {\n numRequiredSignatures,\n numReadonlySignedAccounts,\n numReadonlyUnsignedAccounts\n } = header;\n const numWritableSignedAccounts = numRequiredSignatures - numReadonlySignedAccounts;\n assert(numWritableSignedAccounts > 0, 'Message header is invalid');\n const numWritableUnsignedAccounts = message.staticAccountKeys.length - numRequiredSignatures - numReadonlyUnsignedAccounts;\n assert(numWritableUnsignedAccounts >= 0, 'Message header is invalid');\n const accountKeys = message.getAccountKeys(args);\n const payerKey = accountKeys.get(0);\n if (payerKey === undefined) {\n throw new Error('Failed to decompile message because no account keys were found');\n }\n const instructions = [];\n for (const compiledIx of compiledInstructions) {\n const keys = [];\n for (const keyIndex of compiledIx.accountKeyIndexes) {\n const pubkey = accountKeys.get(keyIndex);\n if (pubkey === undefined) {\n throw new Error(`Failed to find key for account key index ${keyIndex}`);\n }\n const isSigner = keyIndex < numRequiredSignatures;\n let isWritable;\n if (isSigner) {\n isWritable = keyIndex < numWritableSignedAccounts;\n } else if (keyIndex < accountKeys.staticAccountKeys.length) {\n isWritable = keyIndex - numRequiredSignatures < numWritableUnsignedAccounts;\n } else {\n isWritable = keyIndex - accountKeys.staticAccountKeys.length <\n // accountKeysFromLookups cannot be undefined because we already found a pubkey for this index above\n accountKeys.accountKeysFromLookups.writable.length;\n }\n keys.push({\n pubkey,\n isSigner: keyIndex < header.numRequiredSignatures,\n isWritable\n });\n }\n const programId = accountKeys.get(compiledIx.programIdIndex);\n if (programId === undefined) {\n throw new Error(`Failed to find program id for program id index ${compiledIx.programIdIndex}`);\n }\n instructions.push(new TransactionInstruction({\n programId,\n data: toBuffer(compiledIx.data),\n keys\n }));\n }\n return new TransactionMessage({\n payerKey,\n instructions,\n recentBlockhash\n });\n }\n compileToLegacyMessage() {\n return Message.compile({\n payerKey: this.payerKey,\n recentBlockhash: this.recentBlockhash,\n instructions: this.instructions\n });\n }\n compileToV0Message(addressLookupTableAccounts) {\n return MessageV0.compile({\n payerKey: this.payerKey,\n recentBlockhash: this.recentBlockhash,\n instructions: this.instructions,\n addressLookupTableAccounts\n });\n }\n}\n\n/**\n * Versioned transaction class\n */\nclass VersionedTransaction {\n get version() {\n return this.message.version;\n }\n constructor(message, signatures) {\n this.signatures = void 0;\n this.message = void 0;\n if (signatures !== undefined) {\n assert(signatures.length === message.header.numRequiredSignatures, 'Expected signatures length to be equal to the number of required signatures');\n this.signatures = signatures;\n } else {\n const defaultSignatures = [];\n for (let i = 0; i < message.header.numRequiredSignatures; i++) {\n defaultSignatures.push(new Uint8Array(SIGNATURE_LENGTH_IN_BYTES));\n }\n this.signatures = defaultSignatures;\n }\n this.message = message;\n }\n serialize() {\n const serializedMessage = this.message.serialize();\n const encodedSignaturesLength = Array();\n encodeLength(encodedSignaturesLength, this.signatures.length);\n const transactionLayout = BufferLayout.struct([BufferLayout.blob(encodedSignaturesLength.length, 'encodedSignaturesLength'), BufferLayout.seq(signature(), this.signatures.length, 'signatures'), BufferLayout.blob(serializedMessage.length, 'serializedMessage')]);\n const serializedTransaction = new Uint8Array(2048);\n const serializedTransactionLength = transactionLayout.encode({\n encodedSignaturesLength: new Uint8Array(encodedSignaturesLength),\n signatures: this.signatures,\n serializedMessage\n }, serializedTransaction);\n return serializedTransaction.slice(0, serializedTransactionLength);\n }\n static deserialize(serializedTransaction) {\n let byteArray = [...serializedTransaction];\n const signatures = [];\n const signaturesLength = decodeLength(byteArray);\n for (let i = 0; i < signaturesLength; i++) {\n signatures.push(new Uint8Array(guardedSplice(byteArray, 0, SIGNATURE_LENGTH_IN_BYTES)));\n }\n const message = VersionedMessage.deserialize(new Uint8Array(byteArray));\n return new VersionedTransaction(message, signatures);\n }\n sign(signers) {\n const messageData = this.message.serialize();\n const signerPubkeys = this.message.staticAccountKeys.slice(0, this.message.header.numRequiredSignatures);\n for (const signer of signers) {\n const signerIndex = signerPubkeys.findIndex(pubkey => pubkey.equals(signer.publicKey));\n assert(signerIndex >= 0, `Cannot sign with non signer key ${signer.publicKey.toBase58()}`);\n this.signatures[signerIndex] = sign(messageData, signer.secretKey);\n }\n }\n addSignature(publicKey, signature) {\n assert(signature.byteLength === 64, 'Signature must be 64 bytes long');\n const signerPubkeys = this.message.staticAccountKeys.slice(0, this.message.header.numRequiredSignatures);\n const signerIndex = signerPubkeys.findIndex(pubkey => pubkey.equals(publicKey));\n assert(signerIndex >= 0, `Can not add signature; \\`${publicKey.toBase58()}\\` is not required to sign this transaction`);\n this.signatures[signerIndex] = signature;\n }\n}\n\n// TODO: These constants should be removed in favor of reading them out of a\n// Syscall account\n\n/**\n * @internal\n */\nconst NUM_TICKS_PER_SECOND = 160;\n\n/**\n * @internal\n */\nconst DEFAULT_TICKS_PER_SLOT = 64;\n\n/**\n * @internal\n */\nconst NUM_SLOTS_PER_SECOND = NUM_TICKS_PER_SECOND / DEFAULT_TICKS_PER_SLOT;\n\n/**\n * @internal\n */\nconst MS_PER_SLOT = 1000 / NUM_SLOTS_PER_SECOND;\n\nconst SYSVAR_CLOCK_PUBKEY = new PublicKey('SysvarC1ock11111111111111111111111111111111');\nconst SYSVAR_EPOCH_SCHEDULE_PUBKEY = new PublicKey('SysvarEpochSchedu1e111111111111111111111111');\nconst SYSVAR_INSTRUCTIONS_PUBKEY = new PublicKey('Sysvar1nstructions1111111111111111111111111');\nconst SYSVAR_RECENT_BLOCKHASHES_PUBKEY = new PublicKey('SysvarRecentB1ockHashes11111111111111111111');\nconst SYSVAR_RENT_PUBKEY = new PublicKey('SysvarRent111111111111111111111111111111111');\nconst SYSVAR_REWARDS_PUBKEY = new PublicKey('SysvarRewards111111111111111111111111111111');\nconst SYSVAR_SLOT_HASHES_PUBKEY = new PublicKey('SysvarS1otHashes111111111111111111111111111');\nconst SYSVAR_SLOT_HISTORY_PUBKEY = new PublicKey('SysvarS1otHistory11111111111111111111111111');\nconst SYSVAR_STAKE_HISTORY_PUBKEY = new PublicKey('SysvarStakeHistory1111111111111111111111111');\n\n/**\n * Sign, send and confirm a transaction.\n *\n * If `commitment` option is not specified, defaults to 'max' commitment.\n *\n * @param {Connection} connection\n * @param {Transaction} transaction\n * @param {Array} signers\n * @param {ConfirmOptions} [options]\n * @returns {Promise}\n */\nasync function sendAndConfirmTransaction(connection, transaction, signers, options) {\n const sendOptions = options && {\n skipPreflight: options.skipPreflight,\n preflightCommitment: options.preflightCommitment || options.commitment,\n maxRetries: options.maxRetries,\n minContextSlot: options.minContextSlot\n };\n const signature = await connection.sendTransaction(transaction, signers, sendOptions);\n let status;\n if (transaction.recentBlockhash != null && transaction.lastValidBlockHeight != null) {\n status = (await connection.confirmTransaction({\n abortSignal: options?.abortSignal,\n signature: signature,\n blockhash: transaction.recentBlockhash,\n lastValidBlockHeight: transaction.lastValidBlockHeight\n }, options && options.commitment)).value;\n } else if (transaction.minNonceContextSlot != null && transaction.nonceInfo != null) {\n const {\n nonceInstruction\n } = transaction.nonceInfo;\n const nonceAccountPubkey = nonceInstruction.keys[0].pubkey;\n status = (await connection.confirmTransaction({\n abortSignal: options?.abortSignal,\n minContextSlot: transaction.minNonceContextSlot,\n nonceAccountPubkey,\n nonceValue: transaction.nonceInfo.nonce,\n signature\n }, options && options.commitment)).value;\n } else {\n if (options?.abortSignal != null) {\n console.warn('sendAndConfirmTransaction(): A transaction with a deprecated confirmation strategy was ' + 'supplied along with an `abortSignal`. Only transactions having `lastValidBlockHeight` ' + 'or a combination of `nonceInfo` and `minNonceContextSlot` are abortable.');\n }\n status = (await connection.confirmTransaction(signature, options && options.commitment)).value;\n }\n if (status.err) {\n throw new Error(`Transaction ${signature} failed (${JSON.stringify(status)})`);\n }\n return signature;\n}\n\n// zzz\nfunction sleep(ms) {\n return new Promise(resolve => setTimeout(resolve, ms));\n}\n\n/**\n * @internal\n */\n\n/**\n * Populate a buffer of instruction data using an InstructionType\n * @internal\n */\nfunction encodeData(type, fields) {\n const allocLength = type.layout.span >= 0 ? type.layout.span : getAlloc(type, fields);\n const data = Buffer.alloc(allocLength);\n const layoutFields = Object.assign({\n instruction: type.index\n }, fields);\n type.layout.encode(layoutFields, data);\n return data;\n}\n\n/**\n * Decode instruction data buffer using an InstructionType\n * @internal\n */\nfunction decodeData$1(type, buffer) {\n let data;\n try {\n data = type.layout.decode(buffer);\n } catch (err) {\n throw new Error('invalid instruction; ' + err);\n }\n if (data.instruction !== type.index) {\n throw new Error(`invalid instruction; instruction index mismatch ${data.instruction} != ${type.index}`);\n }\n return data;\n}\n\n/**\n * https://github.com/solana-labs/solana/blob/90bedd7e067b5b8f3ddbb45da00a4e9cabb22c62/sdk/src/fee_calculator.rs#L7-L11\n *\n * @internal\n */\nconst FeeCalculatorLayout = BufferLayout.nu64('lamportsPerSignature');\n\n/**\n * Calculator for transaction fees.\n *\n * @deprecated Deprecated since Solana v1.8.0.\n */\n\n/**\n * See https://github.com/solana-labs/solana/blob/0ea2843ec9cdc517572b8e62c959f41b55cf4453/sdk/src/nonce_state.rs#L29-L32\n *\n * @internal\n */\nconst NonceAccountLayout = BufferLayout.struct([BufferLayout.u32('version'), BufferLayout.u32('state'), publicKey('authorizedPubkey'), publicKey('nonce'), BufferLayout.struct([FeeCalculatorLayout], 'feeCalculator')]);\nconst NONCE_ACCOUNT_LENGTH = NonceAccountLayout.span;\n\n/**\n * A durable nonce is a 32 byte value encoded as a base58 string.\n */\n\n/**\n * NonceAccount class\n */\nclass NonceAccount {\n /**\n * @internal\n */\n constructor(args) {\n this.authorizedPubkey = void 0;\n this.nonce = void 0;\n this.feeCalculator = void 0;\n this.authorizedPubkey = args.authorizedPubkey;\n this.nonce = args.nonce;\n this.feeCalculator = args.feeCalculator;\n }\n\n /**\n * Deserialize NonceAccount from the account data.\n *\n * @param buffer account data\n * @return NonceAccount\n */\n static fromAccountData(buffer) {\n const nonceAccount = NonceAccountLayout.decode(toBuffer(buffer), 0);\n return new NonceAccount({\n authorizedPubkey: new PublicKey(nonceAccount.authorizedPubkey),\n nonce: new PublicKey(nonceAccount.nonce).toString(),\n feeCalculator: nonceAccount.feeCalculator\n });\n }\n}\n\nconst encodeDecode = layout => {\n const decode = layout.decode.bind(layout);\n const encode = layout.encode.bind(layout);\n return {\n decode,\n encode\n };\n};\nconst bigInt = length => property => {\n const layout = blob(length, property);\n const {\n encode,\n decode\n } = encodeDecode(layout);\n const bigIntLayout = layout;\n bigIntLayout.decode = (buffer, offset) => {\n const src = decode(buffer, offset);\n return toBigIntLE(Buffer.from(src));\n };\n bigIntLayout.encode = (bigInt, buffer, offset) => {\n const src = toBufferLE(bigInt, length);\n return encode(src, buffer, offset);\n };\n return bigIntLayout;\n};\nconst u64 = bigInt(8);\n\n/**\n * Create account system transaction params\n */\n\n/**\n * Transfer system transaction params\n */\n\n/**\n * Assign system transaction params\n */\n\n/**\n * Create account with seed system transaction params\n */\n\n/**\n * Create nonce account system transaction params\n */\n\n/**\n * Create nonce account with seed system transaction params\n */\n\n/**\n * Initialize nonce account system instruction params\n */\n\n/**\n * Advance nonce account system instruction params\n */\n\n/**\n * Withdraw nonce account system transaction params\n */\n\n/**\n * Authorize nonce account system transaction params\n */\n\n/**\n * Allocate account system transaction params\n */\n\n/**\n * Allocate account with seed system transaction params\n */\n\n/**\n * Assign account with seed system transaction params\n */\n\n/**\n * Transfer with seed system transaction params\n */\n\n/** Decoded transfer system transaction instruction */\n\n/** Decoded transferWithSeed system transaction instruction */\n\n/**\n * System Instruction class\n */\nclass SystemInstruction {\n /**\n * @internal\n */\n constructor() {}\n\n /**\n * Decode a system instruction and retrieve the instruction type.\n */\n static decodeInstructionType(instruction) {\n this.checkProgramId(instruction.programId);\n const instructionTypeLayout = BufferLayout.u32('instruction');\n const typeIndex = instructionTypeLayout.decode(instruction.data);\n let type;\n for (const [ixType, layout] of Object.entries(SYSTEM_INSTRUCTION_LAYOUTS)) {\n if (layout.index == typeIndex) {\n type = ixType;\n break;\n }\n }\n if (!type) {\n throw new Error('Instruction type incorrect; not a SystemInstruction');\n }\n return type;\n }\n\n /**\n * Decode a create account system instruction and retrieve the instruction params.\n */\n static decodeCreateAccount(instruction) {\n this.checkProgramId(instruction.programId);\n this.checkKeyLength(instruction.keys, 2);\n const {\n lamports,\n space,\n programId\n } = decodeData$1(SYSTEM_INSTRUCTION_LAYOUTS.Create, instruction.data);\n return {\n fromPubkey: instruction.keys[0].pubkey,\n newAccountPubkey: instruction.keys[1].pubkey,\n lamports,\n space,\n programId: new PublicKey(programId)\n };\n }\n\n /**\n * Decode a transfer system instruction and retrieve the instruction params.\n */\n static decodeTransfer(instruction) {\n this.checkProgramId(instruction.programId);\n this.checkKeyLength(instruction.keys, 2);\n const {\n lamports\n } = decodeData$1(SYSTEM_INSTRUCTION_LAYOUTS.Transfer, instruction.data);\n return {\n fromPubkey: instruction.keys[0].pubkey,\n toPubkey: instruction.keys[1].pubkey,\n lamports\n };\n }\n\n /**\n * Decode a transfer with seed system instruction and retrieve the instruction params.\n */\n static decodeTransferWithSeed(instruction) {\n this.checkProgramId(instruction.programId);\n this.checkKeyLength(instruction.keys, 3);\n const {\n lamports,\n seed,\n programId\n } = decodeData$1(SYSTEM_INSTRUCTION_LAYOUTS.TransferWithSeed, instruction.data);\n return {\n fromPubkey: instruction.keys[0].pubkey,\n basePubkey: instruction.keys[1].pubkey,\n toPubkey: instruction.keys[2].pubkey,\n lamports,\n seed,\n programId: new PublicKey(programId)\n };\n }\n\n /**\n * Decode an allocate system instruction and retrieve the instruction params.\n */\n static decodeAllocate(instruction) {\n this.checkProgramId(instruction.programId);\n this.checkKeyLength(instruction.keys, 1);\n const {\n space\n } = decodeData$1(SYSTEM_INSTRUCTION_LAYOUTS.Allocate, instruction.data);\n return {\n accountPubkey: instruction.keys[0].pubkey,\n space\n };\n }\n\n /**\n * Decode an allocate with seed system instruction and retrieve the instruction params.\n */\n static decodeAllocateWithSeed(instruction) {\n this.checkProgramId(instruction.programId);\n this.checkKeyLength(instruction.keys, 1);\n const {\n base,\n seed,\n space,\n programId\n } = decodeData$1(SYSTEM_INSTRUCTION_LAYOUTS.AllocateWithSeed, instruction.data);\n return {\n accountPubkey: instruction.keys[0].pubkey,\n basePubkey: new PublicKey(base),\n seed,\n space,\n programId: new PublicKey(programId)\n };\n }\n\n /**\n * Decode an assign system instruction and retrieve the instruction params.\n */\n static decodeAssign(instruction) {\n this.checkProgramId(instruction.programId);\n this.checkKeyLength(instruction.keys, 1);\n const {\n programId\n } = decodeData$1(SYSTEM_INSTRUCTION_LAYOUTS.Assign, instruction.data);\n return {\n accountPubkey: instruction.keys[0].pubkey,\n programId: new PublicKey(programId)\n };\n }\n\n /**\n * Decode an assign with seed system instruction and retrieve the instruction params.\n */\n static decodeAssignWithSeed(instruction) {\n this.checkProgramId(instruction.programId);\n this.checkKeyLength(instruction.keys, 1);\n const {\n base,\n seed,\n programId\n } = decodeData$1(SYSTEM_INSTRUCTION_LAYOUTS.AssignWithSeed, instruction.data);\n return {\n accountPubkey: instruction.keys[0].pubkey,\n basePubkey: new PublicKey(base),\n seed,\n programId: new PublicKey(programId)\n };\n }\n\n /**\n * Decode a create account with seed system instruction and retrieve the instruction params.\n */\n static decodeCreateWithSeed(instruction) {\n this.checkProgramId(instruction.programId);\n this.checkKeyLength(instruction.keys, 2);\n const {\n base,\n seed,\n lamports,\n space,\n programId\n } = decodeData$1(SYSTEM_INSTRUCTION_LAYOUTS.CreateWithSeed, instruction.data);\n return {\n fromPubkey: instruction.keys[0].pubkey,\n newAccountPubkey: instruction.keys[1].pubkey,\n basePubkey: new PublicKey(base),\n seed,\n lamports,\n space,\n programId: new PublicKey(programId)\n };\n }\n\n /**\n * Decode a nonce initialize system instruction and retrieve the instruction params.\n */\n static decodeNonceInitialize(instruction) {\n this.checkProgramId(instruction.programId);\n this.checkKeyLength(instruction.keys, 3);\n const {\n authorized\n } = decodeData$1(SYSTEM_INSTRUCTION_LAYOUTS.InitializeNonceAccount, instruction.data);\n return {\n noncePubkey: instruction.keys[0].pubkey,\n authorizedPubkey: new PublicKey(authorized)\n };\n }\n\n /**\n * Decode a nonce advance system instruction and retrieve the instruction params.\n */\n static decodeNonceAdvance(instruction) {\n this.checkProgramId(instruction.programId);\n this.checkKeyLength(instruction.keys, 3);\n decodeData$1(SYSTEM_INSTRUCTION_LAYOUTS.AdvanceNonceAccount, instruction.data);\n return {\n noncePubkey: instruction.keys[0].pubkey,\n authorizedPubkey: instruction.keys[2].pubkey\n };\n }\n\n /**\n * Decode a nonce withdraw system instruction and retrieve the instruction params.\n */\n static decodeNonceWithdraw(instruction) {\n this.checkProgramId(instruction.programId);\n this.checkKeyLength(instruction.keys, 5);\n const {\n lamports\n } = decodeData$1(SYSTEM_INSTRUCTION_LAYOUTS.WithdrawNonceAccount, instruction.data);\n return {\n noncePubkey: instruction.keys[0].pubkey,\n toPubkey: instruction.keys[1].pubkey,\n authorizedPubkey: instruction.keys[4].pubkey,\n lamports\n };\n }\n\n /**\n * Decode a nonce authorize system instruction and retrieve the instruction params.\n */\n static decodeNonceAuthorize(instruction) {\n this.checkProgramId(instruction.programId);\n this.checkKeyLength(instruction.keys, 2);\n const {\n authorized\n } = decodeData$1(SYSTEM_INSTRUCTION_LAYOUTS.AuthorizeNonceAccount, instruction.data);\n return {\n noncePubkey: instruction.keys[0].pubkey,\n authorizedPubkey: instruction.keys[1].pubkey,\n newAuthorizedPubkey: new PublicKey(authorized)\n };\n }\n\n /**\n * @internal\n */\n static checkProgramId(programId) {\n if (!programId.equals(SystemProgram.programId)) {\n throw new Error('invalid instruction; programId is not SystemProgram');\n }\n }\n\n /**\n * @internal\n */\n static checkKeyLength(keys, expectedLength) {\n if (keys.length < expectedLength) {\n throw new Error(`invalid instruction; found ${keys.length} keys, expected at least ${expectedLength}`);\n }\n }\n}\n\n/**\n * An enumeration of valid SystemInstructionType's\n */\n\n/**\n * An enumeration of valid system InstructionType's\n * @internal\n */\nconst SYSTEM_INSTRUCTION_LAYOUTS = Object.freeze({\n Create: {\n index: 0,\n layout: BufferLayout.struct([BufferLayout.u32('instruction'), BufferLayout.ns64('lamports'), BufferLayout.ns64('space'), publicKey('programId')])\n },\n Assign: {\n index: 1,\n layout: BufferLayout.struct([BufferLayout.u32('instruction'), publicKey('programId')])\n },\n Transfer: {\n index: 2,\n layout: BufferLayout.struct([BufferLayout.u32('instruction'), u64('lamports')])\n },\n CreateWithSeed: {\n index: 3,\n layout: BufferLayout.struct([BufferLayout.u32('instruction'), publicKey('base'), rustString('seed'), BufferLayout.ns64('lamports'), BufferLayout.ns64('space'), publicKey('programId')])\n },\n AdvanceNonceAccount: {\n index: 4,\n layout: BufferLayout.struct([BufferLayout.u32('instruction')])\n },\n WithdrawNonceAccount: {\n index: 5,\n layout: BufferLayout.struct([BufferLayout.u32('instruction'), BufferLayout.ns64('lamports')])\n },\n InitializeNonceAccount: {\n index: 6,\n layout: BufferLayout.struct([BufferLayout.u32('instruction'), publicKey('authorized')])\n },\n AuthorizeNonceAccount: {\n index: 7,\n layout: BufferLayout.struct([BufferLayout.u32('instruction'), publicKey('authorized')])\n },\n Allocate: {\n index: 8,\n layout: BufferLayout.struct([BufferLayout.u32('instruction'), BufferLayout.ns64('space')])\n },\n AllocateWithSeed: {\n index: 9,\n layout: BufferLayout.struct([BufferLayout.u32('instruction'), publicKey('base'), rustString('seed'), BufferLayout.ns64('space'), publicKey('programId')])\n },\n AssignWithSeed: {\n index: 10,\n layout: BufferLayout.struct([BufferLayout.u32('instruction'), publicKey('base'), rustString('seed'), publicKey('programId')])\n },\n TransferWithSeed: {\n index: 11,\n layout: BufferLayout.struct([BufferLayout.u32('instruction'), u64('lamports'), rustString('seed'), publicKey('programId')])\n },\n UpgradeNonceAccount: {\n index: 12,\n layout: BufferLayout.struct([BufferLayout.u32('instruction')])\n }\n});\n\n/**\n * Factory class for transactions to interact with the System program\n */\nclass SystemProgram {\n /**\n * @internal\n */\n constructor() {}\n\n /**\n * Public key that identifies the System program\n */\n\n /**\n * Generate a transaction instruction that creates a new account\n */\n static createAccount(params) {\n const type = SYSTEM_INSTRUCTION_LAYOUTS.Create;\n const data = encodeData(type, {\n lamports: params.lamports,\n space: params.space,\n programId: toBuffer(params.programId.toBuffer())\n });\n return new TransactionInstruction({\n keys: [{\n pubkey: params.fromPubkey,\n isSigner: true,\n isWritable: true\n }, {\n pubkey: params.newAccountPubkey,\n isSigner: true,\n isWritable: true\n }],\n programId: this.programId,\n data\n });\n }\n\n /**\n * Generate a transaction instruction that transfers lamports from one account to another\n */\n static transfer(params) {\n let data;\n let keys;\n if ('basePubkey' in params) {\n const type = SYSTEM_INSTRUCTION_LAYOUTS.TransferWithSeed;\n data = encodeData(type, {\n lamports: BigInt(params.lamports),\n seed: params.seed,\n programId: toBuffer(params.programId.toBuffer())\n });\n keys = [{\n pubkey: params.fromPubkey,\n isSigner: false,\n isWritable: true\n }, {\n pubkey: params.basePubkey,\n isSigner: true,\n isWritable: false\n }, {\n pubkey: params.toPubkey,\n isSigner: false,\n isWritable: true\n }];\n } else {\n const type = SYSTEM_INSTRUCTION_LAYOUTS.Transfer;\n data = encodeData(type, {\n lamports: BigInt(params.lamports)\n });\n keys = [{\n pubkey: params.fromPubkey,\n isSigner: true,\n isWritable: true\n }, {\n pubkey: params.toPubkey,\n isSigner: false,\n isWritable: true\n }];\n }\n return new TransactionInstruction({\n keys,\n programId: this.programId,\n data\n });\n }\n\n /**\n * Generate a transaction instruction that assigns an account to a program\n */\n static assign(params) {\n let data;\n let keys;\n if ('basePubkey' in params) {\n const type = SYSTEM_INSTRUCTION_LAYOUTS.AssignWithSeed;\n data = encodeData(type, {\n base: toBuffer(params.basePubkey.toBuffer()),\n seed: params.seed,\n programId: toBuffer(params.programId.toBuffer())\n });\n keys = [{\n pubkey: params.accountPubkey,\n isSigner: false,\n isWritable: true\n }, {\n pubkey: params.basePubkey,\n isSigner: true,\n isWritable: false\n }];\n } else {\n const type = SYSTEM_INSTRUCTION_LAYOUTS.Assign;\n data = encodeData(type, {\n programId: toBuffer(params.programId.toBuffer())\n });\n keys = [{\n pubkey: params.accountPubkey,\n isSigner: true,\n isWritable: true\n }];\n }\n return new TransactionInstruction({\n keys,\n programId: this.programId,\n data\n });\n }\n\n /**\n * Generate a transaction instruction that creates a new account at\n * an address generated with `from`, a seed, and programId\n */\n static createAccountWithSeed(params) {\n const type = SYSTEM_INSTRUCTION_LAYOUTS.CreateWithSeed;\n const data = encodeData(type, {\n base: toBuffer(params.basePubkey.toBuffer()),\n seed: params.seed,\n lamports: params.lamports,\n space: params.space,\n programId: toBuffer(params.programId.toBuffer())\n });\n let keys = [{\n pubkey: params.fromPubkey,\n isSigner: true,\n isWritable: true\n }, {\n pubkey: params.newAccountPubkey,\n isSigner: false,\n isWritable: true\n }];\n if (params.basePubkey != params.fromPubkey) {\n keys.push({\n pubkey: params.basePubkey,\n isSigner: true,\n isWritable: false\n });\n }\n return new TransactionInstruction({\n keys,\n programId: this.programId,\n data\n });\n }\n\n /**\n * Generate a transaction that creates a new Nonce account\n */\n static createNonceAccount(params) {\n const transaction = new Transaction();\n if ('basePubkey' in params && 'seed' in params) {\n transaction.add(SystemProgram.createAccountWithSeed({\n fromPubkey: params.fromPubkey,\n newAccountPubkey: params.noncePubkey,\n basePubkey: params.basePubkey,\n seed: params.seed,\n lamports: params.lamports,\n space: NONCE_ACCOUNT_LENGTH,\n programId: this.programId\n }));\n } else {\n transaction.add(SystemProgram.createAccount({\n fromPubkey: params.fromPubkey,\n newAccountPubkey: params.noncePubkey,\n lamports: params.lamports,\n space: NONCE_ACCOUNT_LENGTH,\n programId: this.programId\n }));\n }\n const initParams = {\n noncePubkey: params.noncePubkey,\n authorizedPubkey: params.authorizedPubkey\n };\n transaction.add(this.nonceInitialize(initParams));\n return transaction;\n }\n\n /**\n * Generate an instruction to initialize a Nonce account\n */\n static nonceInitialize(params) {\n const type = SYSTEM_INSTRUCTION_LAYOUTS.InitializeNonceAccount;\n const data = encodeData(type, {\n authorized: toBuffer(params.authorizedPubkey.toBuffer())\n });\n const instructionData = {\n keys: [{\n pubkey: params.noncePubkey,\n isSigner: false,\n isWritable: true\n }, {\n pubkey: SYSVAR_RECENT_BLOCKHASHES_PUBKEY,\n isSigner: false,\n isWritable: false\n }, {\n pubkey: SYSVAR_RENT_PUBKEY,\n isSigner: false,\n isWritable: false\n }],\n programId: this.programId,\n data\n };\n return new TransactionInstruction(instructionData);\n }\n\n /**\n * Generate an instruction to advance the nonce in a Nonce account\n */\n static nonceAdvance(params) {\n const type = SYSTEM_INSTRUCTION_LAYOUTS.AdvanceNonceAccount;\n const data = encodeData(type);\n const instructionData = {\n keys: [{\n pubkey: params.noncePubkey,\n isSigner: false,\n isWritable: true\n }, {\n pubkey: SYSVAR_RECENT_BLOCKHASHES_PUBKEY,\n isSigner: false,\n isWritable: false\n }, {\n pubkey: params.authorizedPubkey,\n isSigner: true,\n isWritable: false\n }],\n programId: this.programId,\n data\n };\n return new TransactionInstruction(instructionData);\n }\n\n /**\n * Generate a transaction instruction that withdraws lamports from a Nonce account\n */\n static nonceWithdraw(params) {\n const type = SYSTEM_INSTRUCTION_LAYOUTS.WithdrawNonceAccount;\n const data = encodeData(type, {\n lamports: params.lamports\n });\n return new TransactionInstruction({\n keys: [{\n pubkey: params.noncePubkey,\n isSigner: false,\n isWritable: true\n }, {\n pubkey: params.toPubkey,\n isSigner: false,\n isWritable: true\n }, {\n pubkey: SYSVAR_RECENT_BLOCKHASHES_PUBKEY,\n isSigner: false,\n isWritable: false\n }, {\n pubkey: SYSVAR_RENT_PUBKEY,\n isSigner: false,\n isWritable: false\n }, {\n pubkey: params.authorizedPubkey,\n isSigner: true,\n isWritable: false\n }],\n programId: this.programId,\n data\n });\n }\n\n /**\n * Generate a transaction instruction that authorizes a new PublicKey as the authority\n * on a Nonce account.\n */\n static nonceAuthorize(params) {\n const type = SYSTEM_INSTRUCTION_LAYOUTS.AuthorizeNonceAccount;\n const data = encodeData(type, {\n authorized: toBuffer(params.newAuthorizedPubkey.toBuffer())\n });\n return new TransactionInstruction({\n keys: [{\n pubkey: params.noncePubkey,\n isSigner: false,\n isWritable: true\n }, {\n pubkey: params.authorizedPubkey,\n isSigner: true,\n isWritable: false\n }],\n programId: this.programId,\n data\n });\n }\n\n /**\n * Generate a transaction instruction that allocates space in an account without funding\n */\n static allocate(params) {\n let data;\n let keys;\n if ('basePubkey' in params) {\n const type = SYSTEM_INSTRUCTION_LAYOUTS.AllocateWithSeed;\n data = encodeData(type, {\n base: toBuffer(params.basePubkey.toBuffer()),\n seed: params.seed,\n space: params.space,\n programId: toBuffer(params.programId.toBuffer())\n });\n keys = [{\n pubkey: params.accountPubkey,\n isSigner: false,\n isWritable: true\n }, {\n pubkey: params.basePubkey,\n isSigner: true,\n isWritable: false\n }];\n } else {\n const type = SYSTEM_INSTRUCTION_LAYOUTS.Allocate;\n data = encodeData(type, {\n space: params.space\n });\n keys = [{\n pubkey: params.accountPubkey,\n isSigner: true,\n isWritable: true\n }];\n }\n return new TransactionInstruction({\n keys,\n programId: this.programId,\n data\n });\n }\n}\nSystemProgram.programId = new PublicKey('11111111111111111111111111111111');\n\n// Keep program chunks under PACKET_DATA_SIZE, leaving enough room for the\n// rest of the Transaction fields\n//\n// TODO: replace 300 with a proper constant for the size of the other\n// Transaction fields\nconst CHUNK_SIZE = PACKET_DATA_SIZE - 300;\n\n/**\n * Program loader interface\n */\nclass Loader {\n /**\n * @internal\n */\n constructor() {}\n\n /**\n * Amount of program data placed in each load Transaction\n */\n\n /**\n * Minimum number of signatures required to load a program not including\n * retries\n *\n * Can be used to calculate transaction fees\n */\n static getMinNumSignatures(dataLength) {\n return 2 * (\n // Every transaction requires two signatures (payer + program)\n Math.ceil(dataLength / Loader.chunkSize) + 1 +\n // Add one for Create transaction\n 1) // Add one for Finalize transaction\n ;\n }\n\n /**\n * Loads a generic program\n *\n * @param connection The connection to use\n * @param payer System account that pays to load the program\n * @param program Account to load the program into\n * @param programId Public key that identifies the loader\n * @param data Program octets\n * @return true if program was loaded successfully, false if program was already loaded\n */\n static async load(connection, payer, program, programId, data) {\n {\n const balanceNeeded = await connection.getMinimumBalanceForRentExemption(data.length);\n\n // Fetch program account info to check if it has already been created\n const programInfo = await connection.getAccountInfo(program.publicKey, 'confirmed');\n let transaction = null;\n if (programInfo !== null) {\n if (programInfo.executable) {\n console.error('Program load failed, account is already executable');\n return false;\n }\n if (programInfo.data.length !== data.length) {\n transaction = transaction || new Transaction();\n transaction.add(SystemProgram.allocate({\n accountPubkey: program.publicKey,\n space: data.length\n }));\n }\n if (!programInfo.owner.equals(programId)) {\n transaction = transaction || new Transaction();\n transaction.add(SystemProgram.assign({\n accountPubkey: program.publicKey,\n programId\n }));\n }\n if (programInfo.lamports < balanceNeeded) {\n transaction = transaction || new Transaction();\n transaction.add(SystemProgram.transfer({\n fromPubkey: payer.publicKey,\n toPubkey: program.publicKey,\n lamports: balanceNeeded - programInfo.lamports\n }));\n }\n } else {\n transaction = new Transaction().add(SystemProgram.createAccount({\n fromPubkey: payer.publicKey,\n newAccountPubkey: program.publicKey,\n lamports: balanceNeeded > 0 ? balanceNeeded : 1,\n space: data.length,\n programId\n }));\n }\n\n // If the account is already created correctly, skip this step\n // and proceed directly to loading instructions\n if (transaction !== null) {\n await sendAndConfirmTransaction(connection, transaction, [payer, program], {\n commitment: 'confirmed'\n });\n }\n }\n const dataLayout = BufferLayout.struct([BufferLayout.u32('instruction'), BufferLayout.u32('offset'), BufferLayout.u32('bytesLength'), BufferLayout.u32('bytesLengthPadding'), BufferLayout.seq(BufferLayout.u8('byte'), BufferLayout.offset(BufferLayout.u32(), -8), 'bytes')]);\n const chunkSize = Loader.chunkSize;\n let offset = 0;\n let array = data;\n let transactions = [];\n while (array.length > 0) {\n const bytes = array.slice(0, chunkSize);\n const data = Buffer.alloc(chunkSize + 16);\n dataLayout.encode({\n instruction: 0,\n // Load instruction\n offset,\n bytes: bytes,\n bytesLength: 0,\n bytesLengthPadding: 0\n }, data);\n const transaction = new Transaction().add({\n keys: [{\n pubkey: program.publicKey,\n isSigner: true,\n isWritable: true\n }],\n programId,\n data\n });\n transactions.push(sendAndConfirmTransaction(connection, transaction, [payer, program], {\n commitment: 'confirmed'\n }));\n\n // Delay between sends in an attempt to reduce rate limit errors\n if (connection._rpcEndpoint.includes('solana.com')) {\n const REQUESTS_PER_SECOND = 4;\n await sleep(1000 / REQUESTS_PER_SECOND);\n }\n offset += chunkSize;\n array = array.slice(chunkSize);\n }\n await Promise.all(transactions);\n\n // Finalize the account loaded with program data for execution\n {\n const dataLayout = BufferLayout.struct([BufferLayout.u32('instruction')]);\n const data = Buffer.alloc(dataLayout.span);\n dataLayout.encode({\n instruction: 1 // Finalize instruction\n }, data);\n const transaction = new Transaction().add({\n keys: [{\n pubkey: program.publicKey,\n isSigner: true,\n isWritable: true\n }, {\n pubkey: SYSVAR_RENT_PUBKEY,\n isSigner: false,\n isWritable: false\n }],\n programId,\n data\n });\n const deployCommitment = 'processed';\n const finalizeSignature = await connection.sendTransaction(transaction, [payer, program], {\n preflightCommitment: deployCommitment\n });\n const {\n context,\n value\n } = await connection.confirmTransaction({\n signature: finalizeSignature,\n lastValidBlockHeight: transaction.lastValidBlockHeight,\n blockhash: transaction.recentBlockhash\n }, deployCommitment);\n if (value.err) {\n throw new Error(`Transaction ${finalizeSignature} failed (${JSON.stringify(value)})`);\n }\n // We prevent programs from being usable until the slot after their deployment.\n // See https://github.com/solana-labs/solana/pull/29654\n while (true // eslint-disable-line no-constant-condition\n ) {\n try {\n const currentSlot = await connection.getSlot({\n commitment: deployCommitment\n });\n if (currentSlot > context.slot) {\n break;\n }\n } catch {\n /* empty */\n }\n await new Promise(resolve => setTimeout(resolve, Math.round(MS_PER_SLOT / 2)));\n }\n }\n\n // success\n return true;\n }\n}\nLoader.chunkSize = CHUNK_SIZE;\n\n/**\n * @deprecated Deprecated since Solana v1.17.20.\n */\nconst BPF_LOADER_PROGRAM_ID = new PublicKey('BPFLoader2111111111111111111111111111111111');\n\n/**\n * Factory class for transactions to interact with a program loader\n *\n * @deprecated Deprecated since Solana v1.17.20.\n */\nclass BpfLoader {\n /**\n * Minimum number of signatures required to load a program not including\n * retries\n *\n * Can be used to calculate transaction fees\n */\n static getMinNumSignatures(dataLength) {\n return Loader.getMinNumSignatures(dataLength);\n }\n\n /**\n * Load a SBF program\n *\n * @param connection The connection to use\n * @param payer Account that will pay program loading fees\n * @param program Account to load the program into\n * @param elf The entire ELF containing the SBF program\n * @param loaderProgramId The program id of the BPF loader to use\n * @return true if program was loaded successfully, false if program was already loaded\n */\n static load(connection, payer, program, elf, loaderProgramId) {\n return Loader.load(connection, payer, program, loaderProgramId, elf);\n }\n}\n\nfunction getDefaultExportFromCjs (x) {\n\treturn x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x;\n}\n\nvar objToString = Object.prototype.toString;\nvar objKeys = Object.keys || function(obj) {\n\t\tvar keys = [];\n\t\tfor (var name in obj) {\n\t\t\tkeys.push(name);\n\t\t}\n\t\treturn keys;\n\t};\n\nfunction stringify(val, isArrayProp) {\n\tvar i, max, str, keys, key, propVal, toStr;\n\tif (val === true) {\n\t\treturn \"true\";\n\t}\n\tif (val === false) {\n\t\treturn \"false\";\n\t}\n\tswitch (typeof val) {\n\t\tcase \"object\":\n\t\t\tif (val === null) {\n\t\t\t\treturn null;\n\t\t\t} else if (val.toJSON && typeof val.toJSON === \"function\") {\n\t\t\t\treturn stringify(val.toJSON(), isArrayProp);\n\t\t\t} else {\n\t\t\t\ttoStr = objToString.call(val);\n\t\t\t\tif (toStr === \"[object Array]\") {\n\t\t\t\t\tstr = '[';\n\t\t\t\t\tmax = val.length - 1;\n\t\t\t\t\tfor(i = 0; i < max; i++) {\n\t\t\t\t\t\tstr += stringify(val[i], true) + ',';\n\t\t\t\t\t}\n\t\t\t\t\tif (max > -1) {\n\t\t\t\t\t\tstr += stringify(val[i], true);\n\t\t\t\t\t}\n\t\t\t\t\treturn str + ']';\n\t\t\t\t} else if (toStr === \"[object Object]\") {\n\t\t\t\t\t// only object is left\n\t\t\t\t\tkeys = objKeys(val).sort();\n\t\t\t\t\tmax = keys.length;\n\t\t\t\t\tstr = \"\";\n\t\t\t\t\ti = 0;\n\t\t\t\t\twhile (i < max) {\n\t\t\t\t\t\tkey = keys[i];\n\t\t\t\t\t\tpropVal = stringify(val[key], false);\n\t\t\t\t\t\tif (propVal !== undefined) {\n\t\t\t\t\t\t\tif (str) {\n\t\t\t\t\t\t\t\tstr += ',';\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tstr += JSON.stringify(key) + ':' + propVal;\n\t\t\t\t\t\t}\n\t\t\t\t\t\ti++;\n\t\t\t\t\t}\n\t\t\t\t\treturn '{' + str + '}';\n\t\t\t\t} else {\n\t\t\t\t\treturn JSON.stringify(val);\n\t\t\t\t}\n\t\t\t}\n\t\tcase \"function\":\n\t\tcase \"undefined\":\n\t\t\treturn isArrayProp ? null : undefined;\n\t\tcase \"string\":\n\t\t\treturn JSON.stringify(val);\n\t\tdefault:\n\t\t\treturn isFinite(val) ? val : null;\n\t}\n}\n\nvar fastStableStringify = function(val) {\n\tvar returnVal = stringify(val, false);\n\tif (returnVal !== undefined) {\n\t\treturn ''+ returnVal;\n\t}\n};\n\nvar fastStableStringify$1 = /*@__PURE__*/getDefaultExportFromCjs(fastStableStringify);\n\nconst MINIMUM_SLOT_PER_EPOCH = 32;\n\n// Returns the number of trailing zeros in the binary representation of self.\nfunction trailingZeros(n) {\n let trailingZeros = 0;\n while (n > 1) {\n n /= 2;\n trailingZeros++;\n }\n return trailingZeros;\n}\n\n// Returns the smallest power of two greater than or equal to n\nfunction nextPowerOfTwo(n) {\n if (n === 0) return 1;\n n--;\n n |= n >> 1;\n n |= n >> 2;\n n |= n >> 4;\n n |= n >> 8;\n n |= n >> 16;\n n |= n >> 32;\n return n + 1;\n}\n\n/**\n * Epoch schedule\n * (see https://docs.solana.com/terminology#epoch)\n * Can be retrieved with the {@link Connection.getEpochSchedule} method\n */\nclass EpochSchedule {\n constructor(slotsPerEpoch, leaderScheduleSlotOffset, warmup, firstNormalEpoch, firstNormalSlot) {\n /** The maximum number of slots in each epoch */\n this.slotsPerEpoch = void 0;\n /** The number of slots before beginning of an epoch to calculate a leader schedule for that epoch */\n this.leaderScheduleSlotOffset = void 0;\n /** Indicates whether epochs start short and grow */\n this.warmup = void 0;\n /** The first epoch with `slotsPerEpoch` slots */\n this.firstNormalEpoch = void 0;\n /** The first slot of `firstNormalEpoch` */\n this.firstNormalSlot = void 0;\n this.slotsPerEpoch = slotsPerEpoch;\n this.leaderScheduleSlotOffset = leaderScheduleSlotOffset;\n this.warmup = warmup;\n this.firstNormalEpoch = firstNormalEpoch;\n this.firstNormalSlot = firstNormalSlot;\n }\n getEpoch(slot) {\n return this.getEpochAndSlotIndex(slot)[0];\n }\n getEpochAndSlotIndex(slot) {\n if (slot < this.firstNormalSlot) {\n const epoch = trailingZeros(nextPowerOfTwo(slot + MINIMUM_SLOT_PER_EPOCH + 1)) - trailingZeros(MINIMUM_SLOT_PER_EPOCH) - 1;\n const epochLen = this.getSlotsInEpoch(epoch);\n const slotIndex = slot - (epochLen - MINIMUM_SLOT_PER_EPOCH);\n return [epoch, slotIndex];\n } else {\n const normalSlotIndex = slot - this.firstNormalSlot;\n const normalEpochIndex = Math.floor(normalSlotIndex / this.slotsPerEpoch);\n const epoch = this.firstNormalEpoch + normalEpochIndex;\n const slotIndex = normalSlotIndex % this.slotsPerEpoch;\n return [epoch, slotIndex];\n }\n }\n getFirstSlotInEpoch(epoch) {\n if (epoch <= this.firstNormalEpoch) {\n return (Math.pow(2, epoch) - 1) * MINIMUM_SLOT_PER_EPOCH;\n } else {\n return (epoch - this.firstNormalEpoch) * this.slotsPerEpoch + this.firstNormalSlot;\n }\n }\n getLastSlotInEpoch(epoch) {\n return this.getFirstSlotInEpoch(epoch) + this.getSlotsInEpoch(epoch) - 1;\n }\n getSlotsInEpoch(epoch) {\n if (epoch < this.firstNormalEpoch) {\n return Math.pow(2, epoch + trailingZeros(MINIMUM_SLOT_PER_EPOCH));\n } else {\n return this.slotsPerEpoch;\n }\n }\n}\n\nclass SendTransactionError extends Error {\n constructor(message, logs) {\n super(message);\n this.logs = void 0;\n this.logs = logs;\n }\n}\n\n// Keep in sync with client/src/rpc_custom_errors.rs\n// Typescript `enums` thwart tree-shaking. See https://bargsten.org/jsts/enums/\nconst SolanaJSONRPCErrorCode = {\n JSON_RPC_SERVER_ERROR_BLOCK_CLEANED_UP: -32001,\n JSON_RPC_SERVER_ERROR_SEND_TRANSACTION_PREFLIGHT_FAILURE: -32002,\n JSON_RPC_SERVER_ERROR_TRANSACTION_SIGNATURE_VERIFICATION_FAILURE: -32003,\n JSON_RPC_SERVER_ERROR_BLOCK_NOT_AVAILABLE: -32004,\n JSON_RPC_SERVER_ERROR_NODE_UNHEALTHY: -32005,\n JSON_RPC_SERVER_ERROR_TRANSACTION_PRECOMPILE_VERIFICATION_FAILURE: -32006,\n JSON_RPC_SERVER_ERROR_SLOT_SKIPPED: -32007,\n JSON_RPC_SERVER_ERROR_NO_SNAPSHOT: -32008,\n JSON_RPC_SERVER_ERROR_LONG_TERM_STORAGE_SLOT_SKIPPED: -32009,\n JSON_RPC_SERVER_ERROR_KEY_EXCLUDED_FROM_SECONDARY_INDEX: -32010,\n JSON_RPC_SERVER_ERROR_TRANSACTION_HISTORY_NOT_AVAILABLE: -32011,\n JSON_RPC_SCAN_ERROR: -32012,\n JSON_RPC_SERVER_ERROR_TRANSACTION_SIGNATURE_LEN_MISMATCH: -32013,\n JSON_RPC_SERVER_ERROR_BLOCK_STATUS_NOT_AVAILABLE_YET: -32014,\n JSON_RPC_SERVER_ERROR_UNSUPPORTED_TRANSACTION_VERSION: -32015,\n JSON_RPC_SERVER_ERROR_MIN_CONTEXT_SLOT_NOT_REACHED: -32016\n};\nclass SolanaJSONRPCError extends Error {\n constructor({\n code,\n message,\n data\n }, customMessage) {\n super(customMessage != null ? `${customMessage}: ${message}` : message);\n this.code = void 0;\n this.data = void 0;\n this.code = code;\n this.data = data;\n this.name = 'SolanaJSONRPCError';\n }\n}\n\nvar fetchImpl = globalThis.fetch;\n\nclass RpcWebSocketClient extends RpcWebSocketCommonClient {\n constructor(address, options, generate_request_id) {\n const webSocketFactory = url => {\n const rpc = createRpc(url, {\n autoconnect: true,\n max_reconnects: 5,\n reconnect: true,\n reconnect_interval: 1000,\n ...options\n });\n if ('socket' in rpc) {\n this.underlyingSocket = rpc.socket;\n } else {\n this.underlyingSocket = rpc;\n }\n return rpc;\n };\n super(webSocketFactory, address, options, generate_request_id);\n this.underlyingSocket = void 0;\n }\n call(...args) {\n const readyState = this.underlyingSocket?.readyState;\n if (readyState === 1 /* WebSocket.OPEN */) {\n return super.call(...args);\n }\n return Promise.reject(new Error('Tried to call a JSON-RPC method `' + args[0] + '` but the socket was not `CONNECTING` or `OPEN` (`readyState` was ' + readyState + ')'));\n }\n notify(...args) {\n const readyState = this.underlyingSocket?.readyState;\n if (readyState === 1 /* WebSocket.OPEN */) {\n return super.notify(...args);\n }\n return Promise.reject(new Error('Tried to send a JSON-RPC notification `' + args[0] + '` but the socket was not `CONNECTING` or `OPEN` (`readyState` was ' + readyState + ')'));\n }\n}\n\n/**\n * @internal\n */\n\n/**\n * Decode account data buffer using an AccountType\n * @internal\n */\nfunction decodeData(type, data) {\n let decoded;\n try {\n decoded = type.layout.decode(data);\n } catch (err) {\n throw new Error('invalid instruction; ' + err);\n }\n if (decoded.typeIndex !== type.index) {\n throw new Error(`invalid account data; account type mismatch ${decoded.typeIndex} != ${type.index}`);\n }\n return decoded;\n}\n\n/// The serialized size of lookup table metadata\nconst LOOKUP_TABLE_META_SIZE = 56;\nclass AddressLookupTableAccount {\n constructor(args) {\n this.key = void 0;\n this.state = void 0;\n this.key = args.key;\n this.state = args.state;\n }\n isActive() {\n const U64_MAX = BigInt('0xffffffffffffffff');\n return this.state.deactivationSlot === U64_MAX;\n }\n static deserialize(accountData) {\n const meta = decodeData(LookupTableMetaLayout, accountData);\n const serializedAddressesLen = accountData.length - LOOKUP_TABLE_META_SIZE;\n assert(serializedAddressesLen >= 0, 'lookup table is invalid');\n assert(serializedAddressesLen % 32 === 0, 'lookup table is invalid');\n const numSerializedAddresses = serializedAddressesLen / 32;\n const {\n addresses\n } = BufferLayout.struct([BufferLayout.seq(publicKey(), numSerializedAddresses, 'addresses')]).decode(accountData.slice(LOOKUP_TABLE_META_SIZE));\n return {\n deactivationSlot: meta.deactivationSlot,\n lastExtendedSlot: meta.lastExtendedSlot,\n lastExtendedSlotStartIndex: meta.lastExtendedStartIndex,\n authority: meta.authority.length !== 0 ? new PublicKey(meta.authority[0]) : undefined,\n addresses: addresses.map(address => new PublicKey(address))\n };\n }\n}\nconst LookupTableMetaLayout = {\n index: 1,\n layout: BufferLayout.struct([BufferLayout.u32('typeIndex'), u64('deactivationSlot'), BufferLayout.nu64('lastExtendedSlot'), BufferLayout.u8('lastExtendedStartIndex'), BufferLayout.u8(),\n // option\n BufferLayout.seq(publicKey(), BufferLayout.offset(BufferLayout.u8(), -1), 'authority')])\n};\n\nconst URL_RE = /^[^:]+:\\/\\/([^:[]+|\\[[^\\]]+\\])(:\\d+)?(.*)/i;\nfunction makeWebsocketUrl(endpoint) {\n const matches = endpoint.match(URL_RE);\n if (matches == null) {\n throw TypeError(`Failed to validate endpoint URL \\`${endpoint}\\``);\n }\n const [_,\n // eslint-disable-line @typescript-eslint/no-unused-vars\n hostish, portWithColon, rest] = matches;\n const protocol = endpoint.startsWith('https:') ? 'wss:' : 'ws:';\n const startPort = portWithColon == null ? null : parseInt(portWithColon.slice(1), 10);\n const websocketPort =\n // Only shift the port by +1 as a convention for ws(s) only if given endpoint\n // is explicitly specifying the endpoint port (HTTP-based RPC), assuming\n // we're directly trying to connect to solana-validator's ws listening port.\n // When the endpoint omits the port, we're connecting to the protocol\n // default ports: http(80) or https(443) and it's assumed we're behind a reverse\n // proxy which manages WebSocket upgrade and backend port redirection.\n startPort == null ? '' : `:${startPort + 1}`;\n return `${protocol}//${hostish}${websocketPort}${rest}`;\n}\n\nconst PublicKeyFromString = coerce(instance(PublicKey), string(), value => new PublicKey(value));\nconst RawAccountDataResult = tuple([string(), literal('base64')]);\nconst BufferFromRawAccountData = coerce(instance(Buffer), RawAccountDataResult, value => Buffer.from(value[0], 'base64'));\n\n/**\n * Attempt to use a recent blockhash for up to 30 seconds\n * @internal\n */\nconst BLOCKHASH_CACHE_TIMEOUT_MS = 30 * 1000;\n\n/**\n * HACK.\n * Copied from rpc-websockets/dist/lib/client.\n * Otherwise, `yarn build` fails with:\n * https://gist.github.com/steveluscher/c057eca81d479ef705cdb53162f9971d\n */\n\n/** @internal */\n/** @internal */\n/** @internal */\n/** @internal */\n\n/** @internal */\n/**\n * @internal\n * Every subscription contains the args used to open the subscription with\n * the server, and a list of callers interested in notifications.\n */\n\n/**\n * @internal\n * A subscription may be in various states of connectedness. Only when it is\n * fully connected will it have a server subscription id associated with it.\n * This id can be returned to the server to unsubscribe the client entirely.\n */\n\n/**\n * A type that encapsulates a subscription's RPC method\n * names and notification (callback) signature.\n */\n\n/**\n * @internal\n * Utility type that keeps tagged unions intact while omitting properties.\n */\n\n/**\n * @internal\n * This type represents a single subscribable 'topic.' It's made up of:\n *\n * - The args used to open the subscription with the server,\n * - The state of the subscription, in terms of its connectedness, and\n * - The set of callbacks to call when the server publishes notifications\n *\n * This record gets indexed by `SubscriptionConfigHash` and is used to\n * set up subscriptions, fan out notifications, and track subscription state.\n */\n\n/**\n * @internal\n */\n\n/**\n * Extra contextual information for RPC responses\n */\n\n/**\n * Options for sending transactions\n */\n\n/**\n * Options for confirming transactions\n */\n\n/**\n * Options for getConfirmedSignaturesForAddress2\n */\n\n/**\n * Options for getSignaturesForAddress\n */\n\n/**\n * RPC Response with extra contextual information\n */\n\n/**\n * A strategy for confirming transactions that uses the last valid\n * block height for a given blockhash to check for transaction expiration.\n */\n\n/**\n * A strategy for confirming durable nonce transactions.\n */\n\n/**\n * Properties shared by all transaction confirmation strategies\n */\n\n/**\n * This type represents all transaction confirmation strategies\n */\n\n/* @internal */\nfunction assertEndpointUrl(putativeUrl) {\n if (/^https?:/.test(putativeUrl) === false) {\n throw new TypeError('Endpoint URL must start with `http:` or `https:`.');\n }\n return putativeUrl;\n}\n\n/** @internal */\nfunction extractCommitmentFromConfig(commitmentOrConfig) {\n let commitment;\n let config;\n if (typeof commitmentOrConfig === 'string') {\n commitment = commitmentOrConfig;\n } else if (commitmentOrConfig) {\n const {\n commitment: specifiedCommitment,\n ...specifiedConfig\n } = commitmentOrConfig;\n commitment = specifiedCommitment;\n config = specifiedConfig;\n }\n return {\n commitment,\n config\n };\n}\n\n/**\n * @internal\n */\nfunction createRpcResult(result) {\n return union([type({\n jsonrpc: literal('2.0'),\n id: string(),\n result\n }), type({\n jsonrpc: literal('2.0'),\n id: string(),\n error: type({\n code: unknown(),\n message: string(),\n data: optional(any())\n })\n })]);\n}\nconst UnknownRpcResult = createRpcResult(unknown());\n\n/**\n * @internal\n */\nfunction jsonRpcResult(schema) {\n return coerce(createRpcResult(schema), UnknownRpcResult, value => {\n if ('error' in value) {\n return value;\n } else {\n return {\n ...value,\n result: create(value.result, schema)\n };\n }\n });\n}\n\n/**\n * @internal\n */\nfunction jsonRpcResultAndContext(value) {\n return jsonRpcResult(type({\n context: type({\n slot: number()\n }),\n value\n }));\n}\n\n/**\n * @internal\n */\nfunction notificationResultAndContext(value) {\n return type({\n context: type({\n slot: number()\n }),\n value\n });\n}\n\n/**\n * @internal\n */\nfunction versionedMessageFromResponse(version, response) {\n if (version === 0) {\n return new MessageV0({\n header: response.header,\n staticAccountKeys: response.accountKeys.map(accountKey => new PublicKey(accountKey)),\n recentBlockhash: response.recentBlockhash,\n compiledInstructions: response.instructions.map(ix => ({\n programIdIndex: ix.programIdIndex,\n accountKeyIndexes: ix.accounts,\n data: bs58.decode(ix.data)\n })),\n addressTableLookups: response.addressTableLookups\n });\n } else {\n return new Message(response);\n }\n}\n\n/**\n * The level of commitment desired when querying state\n *
\n *   'processed': Query the most recent block which has reached 1 confirmation by the connected node\n *   'confirmed': Query the most recent block which has reached 1 confirmation by the cluster\n *   'finalized': Query the most recent block which has been finalized by the cluster\n * 
\n */\n\n// Deprecated as of v1.5.5\n\n/**\n * A subset of Commitment levels, which are at least optimistically confirmed\n *
\n *   'confirmed': Query the most recent block which has reached 1 confirmation by the cluster\n *   'finalized': Query the most recent block which has been finalized by the cluster\n * 
\n */\n\n/**\n * Filter for largest accounts query\n *
\n *   'circulating':    Return the largest accounts that are part of the circulating supply\n *   'nonCirculating': Return the largest accounts that are not part of the circulating supply\n * 
\n */\n\n/**\n * Configuration object for changing `getAccountInfo` query behavior\n */\n\n/**\n * Configuration object for changing `getBalance` query behavior\n */\n\n/**\n * Configuration object for changing `getBlock` query behavior\n */\n\n/**\n * Configuration object for changing `getBlock` query behavior\n */\n\n/**\n * Configuration object for changing `getStakeMinimumDelegation` query behavior\n */\n\n/**\n * Configuration object for changing `getBlockHeight` query behavior\n */\n\n/**\n * Configuration object for changing `getEpochInfo` query behavior\n */\n\n/**\n * Configuration object for changing `getInflationReward` query behavior\n */\n\n/**\n * Configuration object for changing `getLatestBlockhash` query behavior\n */\n\n/**\n * Configuration object for changing `isBlockhashValid` query behavior\n */\n\n/**\n * Configuration object for changing `getSlot` query behavior\n */\n\n/**\n * Configuration object for changing `getSlotLeader` query behavior\n */\n\n/**\n * Configuration object for changing `getTransaction` query behavior\n */\n\n/**\n * Configuration object for changing `getTransaction` query behavior\n */\n\n/**\n * Configuration object for changing `getLargestAccounts` query behavior\n */\n\n/**\n * Configuration object for changing `getSupply` request behavior\n */\n\n/**\n * Configuration object for changing query behavior\n */\n\n/**\n * Information describing a cluster node\n */\n\n/**\n * Information describing a vote account\n */\n\n/**\n * A collection of cluster vote accounts\n */\n\n/**\n * Network Inflation\n * (see https://docs.solana.com/implemented-proposals/ed_overview)\n */\n\nconst GetInflationGovernorResult = type({\n foundation: number(),\n foundationTerm: number(),\n initial: number(),\n taper: number(),\n terminal: number()\n});\n\n/**\n * The inflation reward for an epoch\n */\n\n/**\n * Expected JSON RPC response for the \"getInflationReward\" message\n */\nconst GetInflationRewardResult = jsonRpcResult(array(nullable(type({\n epoch: number(),\n effectiveSlot: number(),\n amount: number(),\n postBalance: number(),\n commission: optional(nullable(number()))\n}))));\n\n/**\n * Configuration object for changing `getRecentPrioritizationFees` query behavior\n */\n\n/**\n * Expected JSON RPC response for the \"getRecentPrioritizationFees\" message\n */\nconst GetRecentPrioritizationFeesResult = array(type({\n slot: number(),\n prioritizationFee: number()\n}));\n/**\n * Expected JSON RPC response for the \"getInflationRate\" message\n */\nconst GetInflationRateResult = type({\n total: number(),\n validator: number(),\n foundation: number(),\n epoch: number()\n});\n\n/**\n * Information about the current epoch\n */\n\nconst GetEpochInfoResult = type({\n epoch: number(),\n slotIndex: number(),\n slotsInEpoch: number(),\n absoluteSlot: number(),\n blockHeight: optional(number()),\n transactionCount: optional(number())\n});\nconst GetEpochScheduleResult = type({\n slotsPerEpoch: number(),\n leaderScheduleSlotOffset: number(),\n warmup: boolean(),\n firstNormalEpoch: number(),\n firstNormalSlot: number()\n});\n\n/**\n * Leader schedule\n * (see https://docs.solana.com/terminology#leader-schedule)\n */\n\nconst GetLeaderScheduleResult = record(string(), array(number()));\n\n/**\n * Transaction error or null\n */\nconst TransactionErrorResult = nullable(union([type({}), string()]));\n\n/**\n * Signature status for a transaction\n */\nconst SignatureStatusResult = type({\n err: TransactionErrorResult\n});\n\n/**\n * Transaction signature received notification\n */\nconst SignatureReceivedResult = literal('receivedSignature');\n\n/**\n * Version info for a node\n */\n\nconst VersionResult = type({\n 'solana-core': string(),\n 'feature-set': optional(number())\n});\nconst SimulatedTransactionResponseStruct = jsonRpcResultAndContext(type({\n err: nullable(union([type({}), string()])),\n logs: nullable(array(string())),\n accounts: optional(nullable(array(nullable(type({\n executable: boolean(),\n owner: string(),\n lamports: number(),\n data: array(string()),\n rentEpoch: optional(number())\n }))))),\n unitsConsumed: optional(number()),\n returnData: optional(nullable(type({\n programId: string(),\n data: tuple([string(), literal('base64')])\n })))\n}));\n\n/**\n * Metadata for a parsed confirmed transaction on the ledger\n *\n * @deprecated Deprecated since Solana v1.8.0. Please use {@link ParsedTransactionMeta} instead.\n */\n\n/**\n * Collection of addresses loaded by a transaction using address table lookups\n */\n\n/**\n * Metadata for a parsed transaction on the ledger\n */\n\n/**\n * Metadata for a confirmed transaction on the ledger\n */\n\n/**\n * A processed transaction from the RPC API\n */\n\n/**\n * A processed transaction from the RPC API\n */\n\n/**\n * A processed transaction message from the RPC API\n */\n\n/**\n * A confirmed transaction on the ledger\n *\n * @deprecated Deprecated since Solana v1.8.0.\n */\n\n/**\n * A partially decoded transaction instruction\n */\n\n/**\n * A parsed transaction message account\n */\n\n/**\n * A parsed transaction instruction\n */\n\n/**\n * A parsed address table lookup\n */\n\n/**\n * A parsed transaction message\n */\n\n/**\n * A parsed transaction\n */\n\n/**\n * A parsed and confirmed transaction on the ledger\n *\n * @deprecated Deprecated since Solana v1.8.0. Please use {@link ParsedTransactionWithMeta} instead.\n */\n\n/**\n * A parsed transaction on the ledger with meta\n */\n\n/**\n * A processed block fetched from the RPC API\n */\n\n/**\n * A processed block fetched from the RPC API where the `transactionDetails` mode is `accounts`\n */\n\n/**\n * A processed block fetched from the RPC API where the `transactionDetails` mode is `none`\n */\n\n/**\n * A block with parsed transactions\n */\n\n/**\n * A block with parsed transactions where the `transactionDetails` mode is `accounts`\n */\n\n/**\n * A block with parsed transactions where the `transactionDetails` mode is `none`\n */\n\n/**\n * A processed block fetched from the RPC API\n */\n\n/**\n * A processed block fetched from the RPC API where the `transactionDetails` mode is `accounts`\n */\n\n/**\n * A processed block fetched from the RPC API where the `transactionDetails` mode is `none`\n */\n\n/**\n * A confirmed block on the ledger\n *\n * @deprecated Deprecated since Solana v1.8.0.\n */\n\n/**\n * A Block on the ledger with signatures only\n */\n\n/**\n * recent block production information\n */\n\n/**\n * Expected JSON RPC response for the \"getBlockProduction\" message\n */\nconst BlockProductionResponseStruct = jsonRpcResultAndContext(type({\n byIdentity: record(string(), array(number())),\n range: type({\n firstSlot: number(),\n lastSlot: number()\n })\n}));\n\n/**\n * A performance sample\n */\n\nfunction createRpcClient(url, httpHeaders, customFetch, fetchMiddleware, disableRetryOnRateLimit, httpAgent) {\n const fetch = customFetch ? customFetch : fetchImpl;\n let agent;\n {\n if (httpAgent != null) {\n console.warn('You have supplied an `httpAgent` when creating a `Connection` in a browser environment.' + 'It has been ignored; `httpAgent` is only used in Node environments.');\n }\n }\n let fetchWithMiddleware;\n if (fetchMiddleware) {\n fetchWithMiddleware = async (info, init) => {\n const modifiedFetchArgs = await new Promise((resolve, reject) => {\n try {\n fetchMiddleware(info, init, (modifiedInfo, modifiedInit) => resolve([modifiedInfo, modifiedInit]));\n } catch (error) {\n reject(error);\n }\n });\n return await fetch(...modifiedFetchArgs);\n };\n }\n const clientBrowser = new RpcClient(async (request, callback) => {\n const options = {\n method: 'POST',\n body: request,\n agent,\n headers: Object.assign({\n 'Content-Type': 'application/json'\n }, httpHeaders || {}, COMMON_HTTP_HEADERS)\n };\n try {\n let too_many_requests_retries = 5;\n let res;\n let waitTime = 500;\n for (;;) {\n if (fetchWithMiddleware) {\n res = await fetchWithMiddleware(url, options);\n } else {\n res = await fetch(url, options);\n }\n if (res.status !== 429 /* Too many requests */) {\n break;\n }\n if (disableRetryOnRateLimit === true) {\n break;\n }\n too_many_requests_retries -= 1;\n if (too_many_requests_retries === 0) {\n break;\n }\n console.error(`Server responded with ${res.status} ${res.statusText}. Retrying after ${waitTime}ms delay...`);\n await sleep(waitTime);\n waitTime *= 2;\n }\n const text = await res.text();\n if (res.ok) {\n callback(null, text);\n } else {\n callback(new Error(`${res.status} ${res.statusText}: ${text}`));\n }\n } catch (err) {\n if (err instanceof Error) callback(err);\n }\n }, {});\n return clientBrowser;\n}\nfunction createRpcRequest(client) {\n return (method, args) => {\n return new Promise((resolve, reject) => {\n client.request(method, args, (err, response) => {\n if (err) {\n reject(err);\n return;\n }\n resolve(response);\n });\n });\n };\n}\nfunction createRpcBatchRequest(client) {\n return requests => {\n return new Promise((resolve, reject) => {\n // Do nothing if requests is empty\n if (requests.length === 0) resolve([]);\n const batch = requests.map(params => {\n return client.request(params.methodName, params.args);\n });\n client.request(batch, (err, response) => {\n if (err) {\n reject(err);\n return;\n }\n resolve(response);\n });\n });\n };\n}\n\n/**\n * Expected JSON RPC response for the \"getInflationGovernor\" message\n */\nconst GetInflationGovernorRpcResult = jsonRpcResult(GetInflationGovernorResult);\n\n/**\n * Expected JSON RPC response for the \"getInflationRate\" message\n */\nconst GetInflationRateRpcResult = jsonRpcResult(GetInflationRateResult);\n\n/**\n * Expected JSON RPC response for the \"getRecentPrioritizationFees\" message\n */\nconst GetRecentPrioritizationFeesRpcResult = jsonRpcResult(GetRecentPrioritizationFeesResult);\n\n/**\n * Expected JSON RPC response for the \"getEpochInfo\" message\n */\nconst GetEpochInfoRpcResult = jsonRpcResult(GetEpochInfoResult);\n\n/**\n * Expected JSON RPC response for the \"getEpochSchedule\" message\n */\nconst GetEpochScheduleRpcResult = jsonRpcResult(GetEpochScheduleResult);\n\n/**\n * Expected JSON RPC response for the \"getLeaderSchedule\" message\n */\nconst GetLeaderScheduleRpcResult = jsonRpcResult(GetLeaderScheduleResult);\n\n/**\n * Expected JSON RPC response for the \"minimumLedgerSlot\" and \"getFirstAvailableBlock\" messages\n */\nconst SlotRpcResult = jsonRpcResult(number());\n\n/**\n * Supply\n */\n\n/**\n * Expected JSON RPC response for the \"getSupply\" message\n */\nconst GetSupplyRpcResult = jsonRpcResultAndContext(type({\n total: number(),\n circulating: number(),\n nonCirculating: number(),\n nonCirculatingAccounts: array(PublicKeyFromString)\n}));\n\n/**\n * Token amount object which returns a token amount in different formats\n * for various client use cases.\n */\n\n/**\n * Expected JSON RPC structure for token amounts\n */\nconst TokenAmountResult = type({\n amount: string(),\n uiAmount: nullable(number()),\n decimals: number(),\n uiAmountString: optional(string())\n});\n\n/**\n * Token address and balance.\n */\n\n/**\n * Expected JSON RPC response for the \"getTokenLargestAccounts\" message\n */\nconst GetTokenLargestAccountsResult = jsonRpcResultAndContext(array(type({\n address: PublicKeyFromString,\n amount: string(),\n uiAmount: nullable(number()),\n decimals: number(),\n uiAmountString: optional(string())\n})));\n\n/**\n * Expected JSON RPC response for the \"getTokenAccountsByOwner\" message\n */\nconst GetTokenAccountsByOwner = jsonRpcResultAndContext(array(type({\n pubkey: PublicKeyFromString,\n account: type({\n executable: boolean(),\n owner: PublicKeyFromString,\n lamports: number(),\n data: BufferFromRawAccountData,\n rentEpoch: number()\n })\n})));\nconst ParsedAccountDataResult = type({\n program: string(),\n parsed: unknown(),\n space: number()\n});\n\n/**\n * Expected JSON RPC response for the \"getTokenAccountsByOwner\" message with parsed data\n */\nconst GetParsedTokenAccountsByOwner = jsonRpcResultAndContext(array(type({\n pubkey: PublicKeyFromString,\n account: type({\n executable: boolean(),\n owner: PublicKeyFromString,\n lamports: number(),\n data: ParsedAccountDataResult,\n rentEpoch: number()\n })\n})));\n\n/**\n * Pair of an account address and its balance\n */\n\n/**\n * Expected JSON RPC response for the \"getLargestAccounts\" message\n */\nconst GetLargestAccountsRpcResult = jsonRpcResultAndContext(array(type({\n lamports: number(),\n address: PublicKeyFromString\n})));\n\n/**\n * @internal\n */\nconst AccountInfoResult = type({\n executable: boolean(),\n owner: PublicKeyFromString,\n lamports: number(),\n data: BufferFromRawAccountData,\n rentEpoch: number()\n});\n\n/**\n * @internal\n */\nconst KeyedAccountInfoResult = type({\n pubkey: PublicKeyFromString,\n account: AccountInfoResult\n});\nconst ParsedOrRawAccountData = coerce(union([instance(Buffer), ParsedAccountDataResult]), union([RawAccountDataResult, ParsedAccountDataResult]), value => {\n if (Array.isArray(value)) {\n return create(value, BufferFromRawAccountData);\n } else {\n return value;\n }\n});\n\n/**\n * @internal\n */\nconst ParsedAccountInfoResult = type({\n executable: boolean(),\n owner: PublicKeyFromString,\n lamports: number(),\n data: ParsedOrRawAccountData,\n rentEpoch: number()\n});\nconst KeyedParsedAccountInfoResult = type({\n pubkey: PublicKeyFromString,\n account: ParsedAccountInfoResult\n});\n\n/**\n * @internal\n */\nconst StakeActivationResult = type({\n state: union([literal('active'), literal('inactive'), literal('activating'), literal('deactivating')]),\n active: number(),\n inactive: number()\n});\n\n/**\n * Expected JSON RPC response for the \"getConfirmedSignaturesForAddress2\" message\n */\n\nconst GetConfirmedSignaturesForAddress2RpcResult = jsonRpcResult(array(type({\n signature: string(),\n slot: number(),\n err: TransactionErrorResult,\n memo: nullable(string()),\n blockTime: optional(nullable(number()))\n})));\n\n/**\n * Expected JSON RPC response for the \"getSignaturesForAddress\" message\n */\nconst GetSignaturesForAddressRpcResult = jsonRpcResult(array(type({\n signature: string(),\n slot: number(),\n err: TransactionErrorResult,\n memo: nullable(string()),\n blockTime: optional(nullable(number()))\n})));\n\n/***\n * Expected JSON RPC response for the \"accountNotification\" message\n */\nconst AccountNotificationResult = type({\n subscription: number(),\n result: notificationResultAndContext(AccountInfoResult)\n});\n\n/**\n * @internal\n */\nconst ProgramAccountInfoResult = type({\n pubkey: PublicKeyFromString,\n account: AccountInfoResult\n});\n\n/***\n * Expected JSON RPC response for the \"programNotification\" message\n */\nconst ProgramAccountNotificationResult = type({\n subscription: number(),\n result: notificationResultAndContext(ProgramAccountInfoResult)\n});\n\n/**\n * @internal\n */\nconst SlotInfoResult = type({\n parent: number(),\n slot: number(),\n root: number()\n});\n\n/**\n * Expected JSON RPC response for the \"slotNotification\" message\n */\nconst SlotNotificationResult = type({\n subscription: number(),\n result: SlotInfoResult\n});\n\n/**\n * Slot updates which can be used for tracking the live progress of a cluster.\n * - `\"firstShredReceived\"`: connected node received the first shred of a block.\n * Indicates that a new block that is being produced.\n * - `\"completed\"`: connected node has received all shreds of a block. Indicates\n * a block was recently produced.\n * - `\"optimisticConfirmation\"`: block was optimistically confirmed by the\n * cluster. It is not guaranteed that an optimistic confirmation notification\n * will be sent for every finalized blocks.\n * - `\"root\"`: the connected node rooted this block.\n * - `\"createdBank\"`: the connected node has started validating this block.\n * - `\"frozen\"`: the connected node has validated this block.\n * - `\"dead\"`: the connected node failed to validate this block.\n */\n\n/**\n * @internal\n */\nconst SlotUpdateResult = union([type({\n type: union([literal('firstShredReceived'), literal('completed'), literal('optimisticConfirmation'), literal('root')]),\n slot: number(),\n timestamp: number()\n}), type({\n type: literal('createdBank'),\n parent: number(),\n slot: number(),\n timestamp: number()\n}), type({\n type: literal('frozen'),\n slot: number(),\n timestamp: number(),\n stats: type({\n numTransactionEntries: number(),\n numSuccessfulTransactions: number(),\n numFailedTransactions: number(),\n maxTransactionsPerEntry: number()\n })\n}), type({\n type: literal('dead'),\n slot: number(),\n timestamp: number(),\n err: string()\n})]);\n\n/**\n * Expected JSON RPC response for the \"slotsUpdatesNotification\" message\n */\nconst SlotUpdateNotificationResult = type({\n subscription: number(),\n result: SlotUpdateResult\n});\n\n/**\n * Expected JSON RPC response for the \"signatureNotification\" message\n */\nconst SignatureNotificationResult = type({\n subscription: number(),\n result: notificationResultAndContext(union([SignatureStatusResult, SignatureReceivedResult]))\n});\n\n/**\n * Expected JSON RPC response for the \"rootNotification\" message\n */\nconst RootNotificationResult = type({\n subscription: number(),\n result: number()\n});\nconst ContactInfoResult = type({\n pubkey: string(),\n gossip: nullable(string()),\n tpu: nullable(string()),\n rpc: nullable(string()),\n version: nullable(string())\n});\nconst VoteAccountInfoResult = type({\n votePubkey: string(),\n nodePubkey: string(),\n activatedStake: number(),\n epochVoteAccount: boolean(),\n epochCredits: array(tuple([number(), number(), number()])),\n commission: number(),\n lastVote: number(),\n rootSlot: nullable(number())\n});\n\n/**\n * Expected JSON RPC response for the \"getVoteAccounts\" message\n */\nconst GetVoteAccounts = jsonRpcResult(type({\n current: array(VoteAccountInfoResult),\n delinquent: array(VoteAccountInfoResult)\n}));\nconst ConfirmationStatus = union([literal('processed'), literal('confirmed'), literal('finalized')]);\nconst SignatureStatusResponse = type({\n slot: number(),\n confirmations: nullable(number()),\n err: TransactionErrorResult,\n confirmationStatus: optional(ConfirmationStatus)\n});\n\n/**\n * Expected JSON RPC response for the \"getSignatureStatuses\" message\n */\nconst GetSignatureStatusesRpcResult = jsonRpcResultAndContext(array(nullable(SignatureStatusResponse)));\n\n/**\n * Expected JSON RPC response for the \"getMinimumBalanceForRentExemption\" message\n */\nconst GetMinimumBalanceForRentExemptionRpcResult = jsonRpcResult(number());\nconst AddressTableLookupStruct = type({\n accountKey: PublicKeyFromString,\n writableIndexes: array(number()),\n readonlyIndexes: array(number())\n});\nconst ConfirmedTransactionResult = type({\n signatures: array(string()),\n message: type({\n accountKeys: array(string()),\n header: type({\n numRequiredSignatures: number(),\n numReadonlySignedAccounts: number(),\n numReadonlyUnsignedAccounts: number()\n }),\n instructions: array(type({\n accounts: array(number()),\n data: string(),\n programIdIndex: number()\n })),\n recentBlockhash: string(),\n addressTableLookups: optional(array(AddressTableLookupStruct))\n })\n});\nconst AnnotatedAccountKey = type({\n pubkey: PublicKeyFromString,\n signer: boolean(),\n writable: boolean(),\n source: optional(union([literal('transaction'), literal('lookupTable')]))\n});\nconst ConfirmedTransactionAccountsModeResult = type({\n accountKeys: array(AnnotatedAccountKey),\n signatures: array(string())\n});\nconst ParsedInstructionResult = type({\n parsed: unknown(),\n program: string(),\n programId: PublicKeyFromString\n});\nconst RawInstructionResult = type({\n accounts: array(PublicKeyFromString),\n data: string(),\n programId: PublicKeyFromString\n});\nconst InstructionResult = union([RawInstructionResult, ParsedInstructionResult]);\nconst UnknownInstructionResult = union([type({\n parsed: unknown(),\n program: string(),\n programId: string()\n}), type({\n accounts: array(string()),\n data: string(),\n programId: string()\n})]);\nconst ParsedOrRawInstruction = coerce(InstructionResult, UnknownInstructionResult, value => {\n if ('accounts' in value) {\n return create(value, RawInstructionResult);\n } else {\n return create(value, ParsedInstructionResult);\n }\n});\n\n/**\n * @internal\n */\nconst ParsedConfirmedTransactionResult = type({\n signatures: array(string()),\n message: type({\n accountKeys: array(AnnotatedAccountKey),\n instructions: array(ParsedOrRawInstruction),\n recentBlockhash: string(),\n addressTableLookups: optional(nullable(array(AddressTableLookupStruct)))\n })\n});\nconst TokenBalanceResult = type({\n accountIndex: number(),\n mint: string(),\n owner: optional(string()),\n uiTokenAmount: TokenAmountResult\n});\nconst LoadedAddressesResult = type({\n writable: array(PublicKeyFromString),\n readonly: array(PublicKeyFromString)\n});\n\n/**\n * @internal\n */\nconst ConfirmedTransactionMetaResult = type({\n err: TransactionErrorResult,\n fee: number(),\n innerInstructions: optional(nullable(array(type({\n index: number(),\n instructions: array(type({\n accounts: array(number()),\n data: string(),\n programIdIndex: number()\n }))\n })))),\n preBalances: array(number()),\n postBalances: array(number()),\n logMessages: optional(nullable(array(string()))),\n preTokenBalances: optional(nullable(array(TokenBalanceResult))),\n postTokenBalances: optional(nullable(array(TokenBalanceResult))),\n loadedAddresses: optional(LoadedAddressesResult),\n computeUnitsConsumed: optional(number())\n});\n\n/**\n * @internal\n */\nconst ParsedConfirmedTransactionMetaResult = type({\n err: TransactionErrorResult,\n fee: number(),\n innerInstructions: optional(nullable(array(type({\n index: number(),\n instructions: array(ParsedOrRawInstruction)\n })))),\n preBalances: array(number()),\n postBalances: array(number()),\n logMessages: optional(nullable(array(string()))),\n preTokenBalances: optional(nullable(array(TokenBalanceResult))),\n postTokenBalances: optional(nullable(array(TokenBalanceResult))),\n loadedAddresses: optional(LoadedAddressesResult),\n computeUnitsConsumed: optional(number())\n});\nconst TransactionVersionStruct = union([literal(0), literal('legacy')]);\n\n/** @internal */\nconst RewardsResult = type({\n pubkey: string(),\n lamports: number(),\n postBalance: nullable(number()),\n rewardType: nullable(string()),\n commission: optional(nullable(number()))\n});\n\n/**\n * Expected JSON RPC response for the \"getBlock\" message\n */\nconst GetBlockRpcResult = jsonRpcResult(nullable(type({\n blockhash: string(),\n previousBlockhash: string(),\n parentSlot: number(),\n transactions: array(type({\n transaction: ConfirmedTransactionResult,\n meta: nullable(ConfirmedTransactionMetaResult),\n version: optional(TransactionVersionStruct)\n })),\n rewards: optional(array(RewardsResult)),\n blockTime: nullable(number()),\n blockHeight: nullable(number())\n})));\n\n/**\n * Expected JSON RPC response for the \"getBlock\" message when `transactionDetails` is `none`\n */\nconst GetNoneModeBlockRpcResult = jsonRpcResult(nullable(type({\n blockhash: string(),\n previousBlockhash: string(),\n parentSlot: number(),\n rewards: optional(array(RewardsResult)),\n blockTime: nullable(number()),\n blockHeight: nullable(number())\n})));\n\n/**\n * Expected JSON RPC response for the \"getBlock\" message when `transactionDetails` is `accounts`\n */\nconst GetAccountsModeBlockRpcResult = jsonRpcResult(nullable(type({\n blockhash: string(),\n previousBlockhash: string(),\n parentSlot: number(),\n transactions: array(type({\n transaction: ConfirmedTransactionAccountsModeResult,\n meta: nullable(ConfirmedTransactionMetaResult),\n version: optional(TransactionVersionStruct)\n })),\n rewards: optional(array(RewardsResult)),\n blockTime: nullable(number()),\n blockHeight: nullable(number())\n})));\n\n/**\n * Expected parsed JSON RPC response for the \"getBlock\" message\n */\nconst GetParsedBlockRpcResult = jsonRpcResult(nullable(type({\n blockhash: string(),\n previousBlockhash: string(),\n parentSlot: number(),\n transactions: array(type({\n transaction: ParsedConfirmedTransactionResult,\n meta: nullable(ParsedConfirmedTransactionMetaResult),\n version: optional(TransactionVersionStruct)\n })),\n rewards: optional(array(RewardsResult)),\n blockTime: nullable(number()),\n blockHeight: nullable(number())\n})));\n\n/**\n * Expected parsed JSON RPC response for the \"getBlock\" message when `transactionDetails` is `accounts`\n */\nconst GetParsedAccountsModeBlockRpcResult = jsonRpcResult(nullable(type({\n blockhash: string(),\n previousBlockhash: string(),\n parentSlot: number(),\n transactions: array(type({\n transaction: ConfirmedTransactionAccountsModeResult,\n meta: nullable(ParsedConfirmedTransactionMetaResult),\n version: optional(TransactionVersionStruct)\n })),\n rewards: optional(array(RewardsResult)),\n blockTime: nullable(number()),\n blockHeight: nullable(number())\n})));\n\n/**\n * Expected parsed JSON RPC response for the \"getBlock\" message when `transactionDetails` is `none`\n */\nconst GetParsedNoneModeBlockRpcResult = jsonRpcResult(nullable(type({\n blockhash: string(),\n previousBlockhash: string(),\n parentSlot: number(),\n rewards: optional(array(RewardsResult)),\n blockTime: nullable(number()),\n blockHeight: nullable(number())\n})));\n\n/**\n * Expected JSON RPC response for the \"getConfirmedBlock\" message\n *\n * @deprecated Deprecated since Solana v1.8.0. Please use {@link GetBlockRpcResult} instead.\n */\nconst GetConfirmedBlockRpcResult = jsonRpcResult(nullable(type({\n blockhash: string(),\n previousBlockhash: string(),\n parentSlot: number(),\n transactions: array(type({\n transaction: ConfirmedTransactionResult,\n meta: nullable(ConfirmedTransactionMetaResult)\n })),\n rewards: optional(array(RewardsResult)),\n blockTime: nullable(number())\n})));\n\n/**\n * Expected JSON RPC response for the \"getBlock\" message\n */\nconst GetBlockSignaturesRpcResult = jsonRpcResult(nullable(type({\n blockhash: string(),\n previousBlockhash: string(),\n parentSlot: number(),\n signatures: array(string()),\n blockTime: nullable(number())\n})));\n\n/**\n * Expected JSON RPC response for the \"getTransaction\" message\n */\nconst GetTransactionRpcResult = jsonRpcResult(nullable(type({\n slot: number(),\n meta: nullable(ConfirmedTransactionMetaResult),\n blockTime: optional(nullable(number())),\n transaction: ConfirmedTransactionResult,\n version: optional(TransactionVersionStruct)\n})));\n\n/**\n * Expected parsed JSON RPC response for the \"getTransaction\" message\n */\nconst GetParsedTransactionRpcResult = jsonRpcResult(nullable(type({\n slot: number(),\n transaction: ParsedConfirmedTransactionResult,\n meta: nullable(ParsedConfirmedTransactionMetaResult),\n blockTime: optional(nullable(number())),\n version: optional(TransactionVersionStruct)\n})));\n\n/**\n * Expected JSON RPC response for the \"getRecentBlockhash\" message\n *\n * @deprecated Deprecated since Solana v1.8.0. Please use {@link GetLatestBlockhashRpcResult} instead.\n */\nconst GetRecentBlockhashAndContextRpcResult = jsonRpcResultAndContext(type({\n blockhash: string(),\n feeCalculator: type({\n lamportsPerSignature: number()\n })\n}));\n\n/**\n * Expected JSON RPC response for the \"getLatestBlockhash\" message\n */\nconst GetLatestBlockhashRpcResult = jsonRpcResultAndContext(type({\n blockhash: string(),\n lastValidBlockHeight: number()\n}));\n\n/**\n * Expected JSON RPC response for the \"isBlockhashValid\" message\n */\nconst IsBlockhashValidRpcResult = jsonRpcResultAndContext(boolean());\nconst PerfSampleResult = type({\n slot: number(),\n numTransactions: number(),\n numSlots: number(),\n samplePeriodSecs: number()\n});\n\n/*\n * Expected JSON RPC response for \"getRecentPerformanceSamples\" message\n */\nconst GetRecentPerformanceSamplesRpcResult = jsonRpcResult(array(PerfSampleResult));\n\n/**\n * Expected JSON RPC response for the \"getFeeCalculatorForBlockhash\" message\n */\nconst GetFeeCalculatorRpcResult = jsonRpcResultAndContext(nullable(type({\n feeCalculator: type({\n lamportsPerSignature: number()\n })\n})));\n\n/**\n * Expected JSON RPC response for the \"requestAirdrop\" message\n */\nconst RequestAirdropRpcResult = jsonRpcResult(string());\n\n/**\n * Expected JSON RPC response for the \"sendTransaction\" message\n */\nconst SendTransactionRpcResult = jsonRpcResult(string());\n\n/**\n * Information about the latest slot being processed by a node\n */\n\n/**\n * Parsed account data\n */\n\n/**\n * Stake Activation data\n */\n\n/**\n * Data slice argument for getProgramAccounts\n */\n\n/**\n * Memory comparison filter for getProgramAccounts\n */\n\n/**\n * Data size comparison filter for getProgramAccounts\n */\n\n/**\n * A filter object for getProgramAccounts\n */\n\n/**\n * Configuration object for getProgramAccounts requests\n */\n\n/**\n * Configuration object for getParsedProgramAccounts\n */\n\n/**\n * Configuration object for getMultipleAccounts\n */\n\n/**\n * Configuration object for `getStakeActivation`\n */\n\n/**\n * Configuration object for `getStakeActivation`\n */\n\n/**\n * Configuration object for `getStakeActivation`\n */\n\n/**\n * Configuration object for `getNonce`\n */\n\n/**\n * Configuration object for `getNonceAndContext`\n */\n\n/**\n * Information describing an account\n */\n\n/**\n * Account information identified by pubkey\n */\n\n/**\n * Callback function for account change notifications\n */\n\n/**\n * Callback function for program account change notifications\n */\n\n/**\n * Callback function for slot change notifications\n */\n\n/**\n * Callback function for slot update notifications\n */\n\n/**\n * Callback function for signature status notifications\n */\n\n/**\n * Signature status notification with transaction result\n */\n\n/**\n * Signature received notification\n */\n\n/**\n * Callback function for signature notifications\n */\n\n/**\n * Signature subscription options\n */\n\n/**\n * Callback function for root change notifications\n */\n\n/**\n * @internal\n */\nconst LogsResult = type({\n err: TransactionErrorResult,\n logs: array(string()),\n signature: string()\n});\n\n/**\n * Logs result.\n */\n\n/**\n * Expected JSON RPC response for the \"logsNotification\" message.\n */\nconst LogsNotificationResult = type({\n result: notificationResultAndContext(LogsResult),\n subscription: number()\n});\n\n/**\n * Filter for log subscriptions.\n */\n\n/**\n * Callback function for log notifications.\n */\n\n/**\n * Signature result\n */\n\n/**\n * Transaction error\n */\n\n/**\n * Transaction confirmation status\n *
\n *   'processed': Transaction landed in a block which has reached 1 confirmation by the connected node\n *   'confirmed': Transaction landed in a block which has reached 1 confirmation by the cluster\n *   'finalized': Transaction landed in a block which has been finalized by the cluster\n * 
\n */\n\n/**\n * Signature status\n */\n\n/**\n * A confirmed signature with its status\n */\n\n/**\n * An object defining headers to be passed to the RPC server\n */\n\n/**\n * The type of the JavaScript `fetch()` API\n */\n\n/**\n * A callback used to augment the outgoing HTTP request\n */\n\n/**\n * Configuration for instantiating a Connection\n */\n\n/** @internal */\nconst COMMON_HTTP_HEADERS = {\n 'solana-client': `js/${\"0.0.0-development\" }`\n};\n\n/**\n * A connection to a fullnode JSON RPC endpoint\n */\nclass Connection {\n /**\n * Establish a JSON RPC connection\n *\n * @param endpoint URL to the fullnode JSON RPC endpoint\n * @param commitmentOrConfig optional default commitment level or optional ConnectionConfig configuration object\n */\n constructor(endpoint, _commitmentOrConfig) {\n /** @internal */\n this._commitment = void 0;\n /** @internal */\n this._confirmTransactionInitialTimeout = void 0;\n /** @internal */\n this._rpcEndpoint = void 0;\n /** @internal */\n this._rpcWsEndpoint = void 0;\n /** @internal */\n this._rpcClient = void 0;\n /** @internal */\n this._rpcRequest = void 0;\n /** @internal */\n this._rpcBatchRequest = void 0;\n /** @internal */\n this._rpcWebSocket = void 0;\n /** @internal */\n this._rpcWebSocketConnected = false;\n /** @internal */\n this._rpcWebSocketHeartbeat = null;\n /** @internal */\n this._rpcWebSocketIdleTimeout = null;\n /** @internal\n * A number that we increment every time an active connection closes.\n * Used to determine whether the same socket connection that was open\n * when an async operation started is the same one that's active when\n * its continuation fires.\n *\n */\n this._rpcWebSocketGeneration = 0;\n /** @internal */\n this._disableBlockhashCaching = false;\n /** @internal */\n this._pollingBlockhash = false;\n /** @internal */\n this._blockhashInfo = {\n latestBlockhash: null,\n lastFetch: 0,\n transactionSignatures: [],\n simulatedSignatures: []\n };\n /** @internal */\n this._nextClientSubscriptionId = 0;\n /** @internal */\n this._subscriptionDisposeFunctionsByClientSubscriptionId = {};\n /** @internal */\n this._subscriptionHashByClientSubscriptionId = {};\n /** @internal */\n this._subscriptionStateChangeCallbacksByHash = {};\n /** @internal */\n this._subscriptionCallbacksByServerSubscriptionId = {};\n /** @internal */\n this._subscriptionsByHash = {};\n /**\n * Special case.\n * After a signature is processed, RPCs automatically dispose of the\n * subscription on the server side. We need to track which of these\n * subscriptions have been disposed in such a way, so that we know\n * whether the client is dealing with a not-yet-processed signature\n * (in which case we must tear down the server subscription) or an\n * already-processed signature (in which case the client can simply\n * clear out the subscription locally without telling the server).\n *\n * NOTE: There is a proposal to eliminate this special case, here:\n * https://github.com/solana-labs/solana/issues/18892\n */\n /** @internal */\n this._subscriptionsAutoDisposedByRpc = new Set();\n /*\n * Returns the current block height of the node\n */\n this.getBlockHeight = (() => {\n const requestPromises = {};\n return async commitmentOrConfig => {\n const {\n commitment,\n config\n } = extractCommitmentFromConfig(commitmentOrConfig);\n const args = this._buildArgs([], commitment, undefined /* encoding */, config);\n const requestHash = fastStableStringify$1(args);\n requestPromises[requestHash] = requestPromises[requestHash] ?? (async () => {\n try {\n const unsafeRes = await this._rpcRequest('getBlockHeight', args);\n const res = create(unsafeRes, jsonRpcResult(number()));\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get block height information');\n }\n return res.result;\n } finally {\n delete requestPromises[requestHash];\n }\n })();\n return await requestPromises[requestHash];\n };\n })();\n let wsEndpoint;\n let httpHeaders;\n let fetch;\n let fetchMiddleware;\n let disableRetryOnRateLimit;\n let httpAgent;\n if (_commitmentOrConfig && typeof _commitmentOrConfig === 'string') {\n this._commitment = _commitmentOrConfig;\n } else if (_commitmentOrConfig) {\n this._commitment = _commitmentOrConfig.commitment;\n this._confirmTransactionInitialTimeout = _commitmentOrConfig.confirmTransactionInitialTimeout;\n wsEndpoint = _commitmentOrConfig.wsEndpoint;\n httpHeaders = _commitmentOrConfig.httpHeaders;\n fetch = _commitmentOrConfig.fetch;\n fetchMiddleware = _commitmentOrConfig.fetchMiddleware;\n disableRetryOnRateLimit = _commitmentOrConfig.disableRetryOnRateLimit;\n httpAgent = _commitmentOrConfig.httpAgent;\n }\n this._rpcEndpoint = assertEndpointUrl(endpoint);\n this._rpcWsEndpoint = wsEndpoint || makeWebsocketUrl(endpoint);\n this._rpcClient = createRpcClient(endpoint, httpHeaders, fetch, fetchMiddleware, disableRetryOnRateLimit, httpAgent);\n this._rpcRequest = createRpcRequest(this._rpcClient);\n this._rpcBatchRequest = createRpcBatchRequest(this._rpcClient);\n this._rpcWebSocket = new RpcWebSocketClient(this._rpcWsEndpoint, {\n autoconnect: false,\n max_reconnects: Infinity\n });\n this._rpcWebSocket.on('open', this._wsOnOpen.bind(this));\n this._rpcWebSocket.on('error', this._wsOnError.bind(this));\n this._rpcWebSocket.on('close', this._wsOnClose.bind(this));\n this._rpcWebSocket.on('accountNotification', this._wsOnAccountNotification.bind(this));\n this._rpcWebSocket.on('programNotification', this._wsOnProgramAccountNotification.bind(this));\n this._rpcWebSocket.on('slotNotification', this._wsOnSlotNotification.bind(this));\n this._rpcWebSocket.on('slotsUpdatesNotification', this._wsOnSlotUpdatesNotification.bind(this));\n this._rpcWebSocket.on('signatureNotification', this._wsOnSignatureNotification.bind(this));\n this._rpcWebSocket.on('rootNotification', this._wsOnRootNotification.bind(this));\n this._rpcWebSocket.on('logsNotification', this._wsOnLogsNotification.bind(this));\n }\n\n /**\n * The default commitment used for requests\n */\n get commitment() {\n return this._commitment;\n }\n\n /**\n * The RPC endpoint\n */\n get rpcEndpoint() {\n return this._rpcEndpoint;\n }\n\n /**\n * Fetch the balance for the specified public key, return with context\n */\n async getBalanceAndContext(publicKey, commitmentOrConfig) {\n /** @internal */\n const {\n commitment,\n config\n } = extractCommitmentFromConfig(commitmentOrConfig);\n const args = this._buildArgs([publicKey.toBase58()], commitment, undefined /* encoding */, config);\n const unsafeRes = await this._rpcRequest('getBalance', args);\n const res = create(unsafeRes, jsonRpcResultAndContext(number()));\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, `failed to get balance for ${publicKey.toBase58()}`);\n }\n return res.result;\n }\n\n /**\n * Fetch the balance for the specified public key\n */\n async getBalance(publicKey, commitmentOrConfig) {\n return await this.getBalanceAndContext(publicKey, commitmentOrConfig).then(x => x.value).catch(e => {\n throw new Error('failed to get balance of account ' + publicKey.toBase58() + ': ' + e);\n });\n }\n\n /**\n * Fetch the estimated production time of a block\n */\n async getBlockTime(slot) {\n const unsafeRes = await this._rpcRequest('getBlockTime', [slot]);\n const res = create(unsafeRes, jsonRpcResult(nullable(number())));\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, `failed to get block time for slot ${slot}`);\n }\n return res.result;\n }\n\n /**\n * Fetch the lowest slot that the node has information about in its ledger.\n * This value may increase over time if the node is configured to purge older ledger data\n */\n async getMinimumLedgerSlot() {\n const unsafeRes = await this._rpcRequest('minimumLedgerSlot', []);\n const res = create(unsafeRes, jsonRpcResult(number()));\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get minimum ledger slot');\n }\n return res.result;\n }\n\n /**\n * Fetch the slot of the lowest confirmed block that has not been purged from the ledger\n */\n async getFirstAvailableBlock() {\n const unsafeRes = await this._rpcRequest('getFirstAvailableBlock', []);\n const res = create(unsafeRes, SlotRpcResult);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get first available block');\n }\n return res.result;\n }\n\n /**\n * Fetch information about the current supply\n */\n async getSupply(config) {\n let configArg = {};\n if (typeof config === 'string') {\n configArg = {\n commitment: config\n };\n } else if (config) {\n configArg = {\n ...config,\n commitment: config && config.commitment || this.commitment\n };\n } else {\n configArg = {\n commitment: this.commitment\n };\n }\n const unsafeRes = await this._rpcRequest('getSupply', [configArg]);\n const res = create(unsafeRes, GetSupplyRpcResult);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get supply');\n }\n return res.result;\n }\n\n /**\n * Fetch the current supply of a token mint\n */\n async getTokenSupply(tokenMintAddress, commitment) {\n const args = this._buildArgs([tokenMintAddress.toBase58()], commitment);\n const unsafeRes = await this._rpcRequest('getTokenSupply', args);\n const res = create(unsafeRes, jsonRpcResultAndContext(TokenAmountResult));\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get token supply');\n }\n return res.result;\n }\n\n /**\n * Fetch the current balance of a token account\n */\n async getTokenAccountBalance(tokenAddress, commitment) {\n const args = this._buildArgs([tokenAddress.toBase58()], commitment);\n const unsafeRes = await this._rpcRequest('getTokenAccountBalance', args);\n const res = create(unsafeRes, jsonRpcResultAndContext(TokenAmountResult));\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get token account balance');\n }\n return res.result;\n }\n\n /**\n * Fetch all the token accounts owned by the specified account\n *\n * @return {Promise}\n */\n async getTokenAccountsByOwner(ownerAddress, filter, commitmentOrConfig) {\n const {\n commitment,\n config\n } = extractCommitmentFromConfig(commitmentOrConfig);\n let _args = [ownerAddress.toBase58()];\n if ('mint' in filter) {\n _args.push({\n mint: filter.mint.toBase58()\n });\n } else {\n _args.push({\n programId: filter.programId.toBase58()\n });\n }\n const args = this._buildArgs(_args, commitment, 'base64', config);\n const unsafeRes = await this._rpcRequest('getTokenAccountsByOwner', args);\n const res = create(unsafeRes, GetTokenAccountsByOwner);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, `failed to get token accounts owned by account ${ownerAddress.toBase58()}`);\n }\n return res.result;\n }\n\n /**\n * Fetch parsed token accounts owned by the specified account\n *\n * @return {Promise}>>>}\n */\n async getParsedTokenAccountsByOwner(ownerAddress, filter, commitment) {\n let _args = [ownerAddress.toBase58()];\n if ('mint' in filter) {\n _args.push({\n mint: filter.mint.toBase58()\n });\n } else {\n _args.push({\n programId: filter.programId.toBase58()\n });\n }\n const args = this._buildArgs(_args, commitment, 'jsonParsed');\n const unsafeRes = await this._rpcRequest('getTokenAccountsByOwner', args);\n const res = create(unsafeRes, GetParsedTokenAccountsByOwner);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, `failed to get token accounts owned by account ${ownerAddress.toBase58()}`);\n }\n return res.result;\n }\n\n /**\n * Fetch the 20 largest accounts with their current balances\n */\n async getLargestAccounts(config) {\n const arg = {\n ...config,\n commitment: config && config.commitment || this.commitment\n };\n const args = arg.filter || arg.commitment ? [arg] : [];\n const unsafeRes = await this._rpcRequest('getLargestAccounts', args);\n const res = create(unsafeRes, GetLargestAccountsRpcResult);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get largest accounts');\n }\n return res.result;\n }\n\n /**\n * Fetch the 20 largest token accounts with their current balances\n * for a given mint.\n */\n async getTokenLargestAccounts(mintAddress, commitment) {\n const args = this._buildArgs([mintAddress.toBase58()], commitment);\n const unsafeRes = await this._rpcRequest('getTokenLargestAccounts', args);\n const res = create(unsafeRes, GetTokenLargestAccountsResult);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get token largest accounts');\n }\n return res.result;\n }\n\n /**\n * Fetch all the account info for the specified public key, return with context\n */\n async getAccountInfoAndContext(publicKey, commitmentOrConfig) {\n const {\n commitment,\n config\n } = extractCommitmentFromConfig(commitmentOrConfig);\n const args = this._buildArgs([publicKey.toBase58()], commitment, 'base64', config);\n const unsafeRes = await this._rpcRequest('getAccountInfo', args);\n const res = create(unsafeRes, jsonRpcResultAndContext(nullable(AccountInfoResult)));\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, `failed to get info about account ${publicKey.toBase58()}`);\n }\n return res.result;\n }\n\n /**\n * Fetch parsed account info for the specified public key\n */\n async getParsedAccountInfo(publicKey, commitmentOrConfig) {\n const {\n commitment,\n config\n } = extractCommitmentFromConfig(commitmentOrConfig);\n const args = this._buildArgs([publicKey.toBase58()], commitment, 'jsonParsed', config);\n const unsafeRes = await this._rpcRequest('getAccountInfo', args);\n const res = create(unsafeRes, jsonRpcResultAndContext(nullable(ParsedAccountInfoResult)));\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, `failed to get info about account ${publicKey.toBase58()}`);\n }\n return res.result;\n }\n\n /**\n * Fetch all the account info for the specified public key\n */\n async getAccountInfo(publicKey, commitmentOrConfig) {\n try {\n const res = await this.getAccountInfoAndContext(publicKey, commitmentOrConfig);\n return res.value;\n } catch (e) {\n throw new Error('failed to get info about account ' + publicKey.toBase58() + ': ' + e);\n }\n }\n\n /**\n * Fetch all the account info for multiple accounts specified by an array of public keys, return with context\n */\n async getMultipleParsedAccounts(publicKeys, rawConfig) {\n const {\n commitment,\n config\n } = extractCommitmentFromConfig(rawConfig);\n const keys = publicKeys.map(key => key.toBase58());\n const args = this._buildArgs([keys], commitment, 'jsonParsed', config);\n const unsafeRes = await this._rpcRequest('getMultipleAccounts', args);\n const res = create(unsafeRes, jsonRpcResultAndContext(array(nullable(ParsedAccountInfoResult))));\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, `failed to get info for accounts ${keys}`);\n }\n return res.result;\n }\n\n /**\n * Fetch all the account info for multiple accounts specified by an array of public keys, return with context\n */\n async getMultipleAccountsInfoAndContext(publicKeys, commitmentOrConfig) {\n const {\n commitment,\n config\n } = extractCommitmentFromConfig(commitmentOrConfig);\n const keys = publicKeys.map(key => key.toBase58());\n const args = this._buildArgs([keys], commitment, 'base64', config);\n const unsafeRes = await this._rpcRequest('getMultipleAccounts', args);\n const res = create(unsafeRes, jsonRpcResultAndContext(array(nullable(AccountInfoResult))));\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, `failed to get info for accounts ${keys}`);\n }\n return res.result;\n }\n\n /**\n * Fetch all the account info for multiple accounts specified by an array of public keys\n */\n async getMultipleAccountsInfo(publicKeys, commitmentOrConfig) {\n const res = await this.getMultipleAccountsInfoAndContext(publicKeys, commitmentOrConfig);\n return res.value;\n }\n\n /**\n * Returns epoch activation information for a stake account that has been delegated\n */\n async getStakeActivation(publicKey, commitmentOrConfig, epoch) {\n const {\n commitment,\n config\n } = extractCommitmentFromConfig(commitmentOrConfig);\n const args = this._buildArgs([publicKey.toBase58()], commitment, undefined /* encoding */, {\n ...config,\n epoch: epoch != null ? epoch : config?.epoch\n });\n const unsafeRes = await this._rpcRequest('getStakeActivation', args);\n const res = create(unsafeRes, jsonRpcResult(StakeActivationResult));\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, `failed to get Stake Activation ${publicKey.toBase58()}`);\n }\n return res.result;\n }\n\n /**\n * Fetch all the accounts owned by the specified program id\n *\n * @return {Promise}>>}\n */\n\n // eslint-disable-next-line no-dupe-class-members\n\n // eslint-disable-next-line no-dupe-class-members\n async getProgramAccounts(programId, configOrCommitment) {\n const {\n commitment,\n config\n } = extractCommitmentFromConfig(configOrCommitment);\n const {\n encoding,\n ...configWithoutEncoding\n } = config || {};\n const args = this._buildArgs([programId.toBase58()], commitment, encoding || 'base64', configWithoutEncoding);\n const unsafeRes = await this._rpcRequest('getProgramAccounts', args);\n const baseSchema = array(KeyedAccountInfoResult);\n const res = configWithoutEncoding.withContext === true ? create(unsafeRes, jsonRpcResultAndContext(baseSchema)) : create(unsafeRes, jsonRpcResult(baseSchema));\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, `failed to get accounts owned by program ${programId.toBase58()}`);\n }\n return res.result;\n }\n\n /**\n * Fetch and parse all the accounts owned by the specified program id\n *\n * @return {Promise}>>}\n */\n async getParsedProgramAccounts(programId, configOrCommitment) {\n const {\n commitment,\n config\n } = extractCommitmentFromConfig(configOrCommitment);\n const args = this._buildArgs([programId.toBase58()], commitment, 'jsonParsed', config);\n const unsafeRes = await this._rpcRequest('getProgramAccounts', args);\n const res = create(unsafeRes, jsonRpcResult(array(KeyedParsedAccountInfoResult)));\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, `failed to get accounts owned by program ${programId.toBase58()}`);\n }\n return res.result;\n }\n\n /** @deprecated Instead, call `confirmTransaction` and pass in {@link TransactionConfirmationStrategy} */\n // eslint-disable-next-line no-dupe-class-members\n\n // eslint-disable-next-line no-dupe-class-members\n async confirmTransaction(strategy, commitment) {\n let rawSignature;\n if (typeof strategy == 'string') {\n rawSignature = strategy;\n } else {\n const config = strategy;\n if (config.abortSignal?.aborted) {\n return Promise.reject(config.abortSignal.reason);\n }\n rawSignature = config.signature;\n }\n let decodedSignature;\n try {\n decodedSignature = bs58.decode(rawSignature);\n } catch (err) {\n throw new Error('signature must be base58 encoded: ' + rawSignature);\n }\n assert(decodedSignature.length === 64, 'signature has invalid length');\n if (typeof strategy === 'string') {\n return await this.confirmTransactionUsingLegacyTimeoutStrategy({\n commitment: commitment || this.commitment,\n signature: rawSignature\n });\n } else if ('lastValidBlockHeight' in strategy) {\n return await this.confirmTransactionUsingBlockHeightExceedanceStrategy({\n commitment: commitment || this.commitment,\n strategy\n });\n } else {\n return await this.confirmTransactionUsingDurableNonceStrategy({\n commitment: commitment || this.commitment,\n strategy\n });\n }\n }\n getCancellationPromise(signal) {\n return new Promise((_, reject) => {\n if (signal == null) {\n return;\n }\n if (signal.aborted) {\n reject(signal.reason);\n } else {\n signal.addEventListener('abort', () => {\n reject(signal.reason);\n });\n }\n });\n }\n getTransactionConfirmationPromise({\n commitment,\n signature\n }) {\n let signatureSubscriptionId;\n let disposeSignatureSubscriptionStateChangeObserver;\n let done = false;\n const confirmationPromise = new Promise((resolve, reject) => {\n try {\n signatureSubscriptionId = this.onSignature(signature, (result, context) => {\n signatureSubscriptionId = undefined;\n const response = {\n context,\n value: result\n };\n resolve({\n __type: TransactionStatus.PROCESSED,\n response\n });\n }, commitment);\n const subscriptionSetupPromise = new Promise(resolveSubscriptionSetup => {\n if (signatureSubscriptionId == null) {\n resolveSubscriptionSetup();\n } else {\n disposeSignatureSubscriptionStateChangeObserver = this._onSubscriptionStateChange(signatureSubscriptionId, nextState => {\n if (nextState === 'subscribed') {\n resolveSubscriptionSetup();\n }\n });\n }\n });\n (async () => {\n await subscriptionSetupPromise;\n if (done) return;\n const response = await this.getSignatureStatus(signature);\n if (done) return;\n if (response == null) {\n return;\n }\n const {\n context,\n value\n } = response;\n if (value == null) {\n return;\n }\n if (value?.err) {\n reject(value.err);\n } else {\n switch (commitment) {\n case 'confirmed':\n case 'single':\n case 'singleGossip':\n {\n if (value.confirmationStatus === 'processed') {\n return;\n }\n break;\n }\n case 'finalized':\n case 'max':\n case 'root':\n {\n if (value.confirmationStatus === 'processed' || value.confirmationStatus === 'confirmed') {\n return;\n }\n break;\n }\n // exhaust enums to ensure full coverage\n case 'processed':\n case 'recent':\n }\n done = true;\n resolve({\n __type: TransactionStatus.PROCESSED,\n response: {\n context,\n value\n }\n });\n }\n })();\n } catch (err) {\n reject(err);\n }\n });\n const abortConfirmation = () => {\n if (disposeSignatureSubscriptionStateChangeObserver) {\n disposeSignatureSubscriptionStateChangeObserver();\n disposeSignatureSubscriptionStateChangeObserver = undefined;\n }\n if (signatureSubscriptionId != null) {\n this.removeSignatureListener(signatureSubscriptionId);\n signatureSubscriptionId = undefined;\n }\n };\n return {\n abortConfirmation,\n confirmationPromise\n };\n }\n async confirmTransactionUsingBlockHeightExceedanceStrategy({\n commitment,\n strategy: {\n abortSignal,\n lastValidBlockHeight,\n signature\n }\n }) {\n let done = false;\n const expiryPromise = new Promise(resolve => {\n const checkBlockHeight = async () => {\n try {\n const blockHeight = await this.getBlockHeight(commitment);\n return blockHeight;\n } catch (_e) {\n return -1;\n }\n };\n (async () => {\n let currentBlockHeight = await checkBlockHeight();\n if (done) return;\n while (currentBlockHeight <= lastValidBlockHeight) {\n await sleep(1000);\n if (done) return;\n currentBlockHeight = await checkBlockHeight();\n if (done) return;\n }\n resolve({\n __type: TransactionStatus.BLOCKHEIGHT_EXCEEDED\n });\n })();\n });\n const {\n abortConfirmation,\n confirmationPromise\n } = this.getTransactionConfirmationPromise({\n commitment,\n signature\n });\n const cancellationPromise = this.getCancellationPromise(abortSignal);\n let result;\n try {\n const outcome = await Promise.race([cancellationPromise, confirmationPromise, expiryPromise]);\n if (outcome.__type === TransactionStatus.PROCESSED) {\n result = outcome.response;\n } else {\n throw new TransactionExpiredBlockheightExceededError(signature);\n }\n } finally {\n done = true;\n abortConfirmation();\n }\n return result;\n }\n async confirmTransactionUsingDurableNonceStrategy({\n commitment,\n strategy: {\n abortSignal,\n minContextSlot,\n nonceAccountPubkey,\n nonceValue,\n signature\n }\n }) {\n let done = false;\n const expiryPromise = new Promise(resolve => {\n let currentNonceValue = nonceValue;\n let lastCheckedSlot = null;\n const getCurrentNonceValue = async () => {\n try {\n const {\n context,\n value: nonceAccount\n } = await this.getNonceAndContext(nonceAccountPubkey, {\n commitment,\n minContextSlot\n });\n lastCheckedSlot = context.slot;\n return nonceAccount?.nonce;\n } catch (e) {\n // If for whatever reason we can't reach/read the nonce\n // account, just keep using the last-known value.\n return currentNonceValue;\n }\n };\n (async () => {\n currentNonceValue = await getCurrentNonceValue();\n if (done) return;\n while (true // eslint-disable-line no-constant-condition\n ) {\n if (nonceValue !== currentNonceValue) {\n resolve({\n __type: TransactionStatus.NONCE_INVALID,\n slotInWhichNonceDidAdvance: lastCheckedSlot\n });\n return;\n }\n await sleep(2000);\n if (done) return;\n currentNonceValue = await getCurrentNonceValue();\n if (done) return;\n }\n })();\n });\n const {\n abortConfirmation,\n confirmationPromise\n } = this.getTransactionConfirmationPromise({\n commitment,\n signature\n });\n const cancellationPromise = this.getCancellationPromise(abortSignal);\n let result;\n try {\n const outcome = await Promise.race([cancellationPromise, confirmationPromise, expiryPromise]);\n if (outcome.__type === TransactionStatus.PROCESSED) {\n result = outcome.response;\n } else {\n // Double check that the transaction is indeed unconfirmed.\n let signatureStatus;\n while (true // eslint-disable-line no-constant-condition\n ) {\n const status = await this.getSignatureStatus(signature);\n if (status == null) {\n break;\n }\n if (status.context.slot < (outcome.slotInWhichNonceDidAdvance ?? minContextSlot)) {\n await sleep(400);\n continue;\n }\n signatureStatus = status;\n break;\n }\n if (signatureStatus?.value) {\n const commitmentForStatus = commitment || 'finalized';\n const {\n confirmationStatus\n } = signatureStatus.value;\n switch (commitmentForStatus) {\n case 'processed':\n case 'recent':\n if (confirmationStatus !== 'processed' && confirmationStatus !== 'confirmed' && confirmationStatus !== 'finalized') {\n throw new TransactionExpiredNonceInvalidError(signature);\n }\n break;\n case 'confirmed':\n case 'single':\n case 'singleGossip':\n if (confirmationStatus !== 'confirmed' && confirmationStatus !== 'finalized') {\n throw new TransactionExpiredNonceInvalidError(signature);\n }\n break;\n case 'finalized':\n case 'max':\n case 'root':\n if (confirmationStatus !== 'finalized') {\n throw new TransactionExpiredNonceInvalidError(signature);\n }\n break;\n default:\n // Exhaustive switch.\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n (_ => {})(commitmentForStatus);\n }\n result = {\n context: signatureStatus.context,\n value: {\n err: signatureStatus.value.err\n }\n };\n } else {\n throw new TransactionExpiredNonceInvalidError(signature);\n }\n }\n } finally {\n done = true;\n abortConfirmation();\n }\n return result;\n }\n async confirmTransactionUsingLegacyTimeoutStrategy({\n commitment,\n signature\n }) {\n let timeoutId;\n const expiryPromise = new Promise(resolve => {\n let timeoutMs = this._confirmTransactionInitialTimeout || 60 * 1000;\n switch (commitment) {\n case 'processed':\n case 'recent':\n case 'single':\n case 'confirmed':\n case 'singleGossip':\n {\n timeoutMs = this._confirmTransactionInitialTimeout || 30 * 1000;\n break;\n }\n }\n timeoutId = setTimeout(() => resolve({\n __type: TransactionStatus.TIMED_OUT,\n timeoutMs\n }), timeoutMs);\n });\n const {\n abortConfirmation,\n confirmationPromise\n } = this.getTransactionConfirmationPromise({\n commitment,\n signature\n });\n let result;\n try {\n const outcome = await Promise.race([confirmationPromise, expiryPromise]);\n if (outcome.__type === TransactionStatus.PROCESSED) {\n result = outcome.response;\n } else {\n throw new TransactionExpiredTimeoutError(signature, outcome.timeoutMs / 1000);\n }\n } finally {\n clearTimeout(timeoutId);\n abortConfirmation();\n }\n return result;\n }\n\n /**\n * Return the list of nodes that are currently participating in the cluster\n */\n async getClusterNodes() {\n const unsafeRes = await this._rpcRequest('getClusterNodes', []);\n const res = create(unsafeRes, jsonRpcResult(array(ContactInfoResult)));\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get cluster nodes');\n }\n return res.result;\n }\n\n /**\n * Return the list of nodes that are currently participating in the cluster\n */\n async getVoteAccounts(commitment) {\n const args = this._buildArgs([], commitment);\n const unsafeRes = await this._rpcRequest('getVoteAccounts', args);\n const res = create(unsafeRes, GetVoteAccounts);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get vote accounts');\n }\n return res.result;\n }\n\n /**\n * Fetch the current slot that the node is processing\n */\n async getSlot(commitmentOrConfig) {\n const {\n commitment,\n config\n } = extractCommitmentFromConfig(commitmentOrConfig);\n const args = this._buildArgs([], commitment, undefined /* encoding */, config);\n const unsafeRes = await this._rpcRequest('getSlot', args);\n const res = create(unsafeRes, jsonRpcResult(number()));\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get slot');\n }\n return res.result;\n }\n\n /**\n * Fetch the current slot leader of the cluster\n */\n async getSlotLeader(commitmentOrConfig) {\n const {\n commitment,\n config\n } = extractCommitmentFromConfig(commitmentOrConfig);\n const args = this._buildArgs([], commitment, undefined /* encoding */, config);\n const unsafeRes = await this._rpcRequest('getSlotLeader', args);\n const res = create(unsafeRes, jsonRpcResult(string()));\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get slot leader');\n }\n return res.result;\n }\n\n /**\n * Fetch `limit` number of slot leaders starting from `startSlot`\n *\n * @param startSlot fetch slot leaders starting from this slot\n * @param limit number of slot leaders to return\n */\n async getSlotLeaders(startSlot, limit) {\n const args = [startSlot, limit];\n const unsafeRes = await this._rpcRequest('getSlotLeaders', args);\n const res = create(unsafeRes, jsonRpcResult(array(PublicKeyFromString)));\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get slot leaders');\n }\n return res.result;\n }\n\n /**\n * Fetch the current status of a signature\n */\n async getSignatureStatus(signature, config) {\n const {\n context,\n value: values\n } = await this.getSignatureStatuses([signature], config);\n assert(values.length === 1);\n const value = values[0];\n return {\n context,\n value\n };\n }\n\n /**\n * Fetch the current statuses of a batch of signatures\n */\n async getSignatureStatuses(signatures, config) {\n const params = [signatures];\n if (config) {\n params.push(config);\n }\n const unsafeRes = await this._rpcRequest('getSignatureStatuses', params);\n const res = create(unsafeRes, GetSignatureStatusesRpcResult);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get signature status');\n }\n return res.result;\n }\n\n /**\n * Fetch the current transaction count of the cluster\n */\n async getTransactionCount(commitmentOrConfig) {\n const {\n commitment,\n config\n } = extractCommitmentFromConfig(commitmentOrConfig);\n const args = this._buildArgs([], commitment, undefined /* encoding */, config);\n const unsafeRes = await this._rpcRequest('getTransactionCount', args);\n const res = create(unsafeRes, jsonRpcResult(number()));\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get transaction count');\n }\n return res.result;\n }\n\n /**\n * Fetch the current total currency supply of the cluster in lamports\n *\n * @deprecated Deprecated since v1.2.8. Please use {@link getSupply} instead.\n */\n async getTotalSupply(commitment) {\n const result = await this.getSupply({\n commitment,\n excludeNonCirculatingAccountsList: true\n });\n return result.value.total;\n }\n\n /**\n * Fetch the cluster InflationGovernor parameters\n */\n async getInflationGovernor(commitment) {\n const args = this._buildArgs([], commitment);\n const unsafeRes = await this._rpcRequest('getInflationGovernor', args);\n const res = create(unsafeRes, GetInflationGovernorRpcResult);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get inflation');\n }\n return res.result;\n }\n\n /**\n * Fetch the inflation reward for a list of addresses for an epoch\n */\n async getInflationReward(addresses, epoch, commitmentOrConfig) {\n const {\n commitment,\n config\n } = extractCommitmentFromConfig(commitmentOrConfig);\n const args = this._buildArgs([addresses.map(pubkey => pubkey.toBase58())], commitment, undefined /* encoding */, {\n ...config,\n epoch: epoch != null ? epoch : config?.epoch\n });\n const unsafeRes = await this._rpcRequest('getInflationReward', args);\n const res = create(unsafeRes, GetInflationRewardResult);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get inflation reward');\n }\n return res.result;\n }\n\n /**\n * Fetch the specific inflation values for the current epoch\n */\n async getInflationRate() {\n const unsafeRes = await this._rpcRequest('getInflationRate', []);\n const res = create(unsafeRes, GetInflationRateRpcResult);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get inflation rate');\n }\n return res.result;\n }\n\n /**\n * Fetch the Epoch Info parameters\n */\n async getEpochInfo(commitmentOrConfig) {\n const {\n commitment,\n config\n } = extractCommitmentFromConfig(commitmentOrConfig);\n const args = this._buildArgs([], commitment, undefined /* encoding */, config);\n const unsafeRes = await this._rpcRequest('getEpochInfo', args);\n const res = create(unsafeRes, GetEpochInfoRpcResult);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get epoch info');\n }\n return res.result;\n }\n\n /**\n * Fetch the Epoch Schedule parameters\n */\n async getEpochSchedule() {\n const unsafeRes = await this._rpcRequest('getEpochSchedule', []);\n const res = create(unsafeRes, GetEpochScheduleRpcResult);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get epoch schedule');\n }\n const epochSchedule = res.result;\n return new EpochSchedule(epochSchedule.slotsPerEpoch, epochSchedule.leaderScheduleSlotOffset, epochSchedule.warmup, epochSchedule.firstNormalEpoch, epochSchedule.firstNormalSlot);\n }\n\n /**\n * Fetch the leader schedule for the current epoch\n * @return {Promise>}\n */\n async getLeaderSchedule() {\n const unsafeRes = await this._rpcRequest('getLeaderSchedule', []);\n const res = create(unsafeRes, GetLeaderScheduleRpcResult);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get leader schedule');\n }\n return res.result;\n }\n\n /**\n * Fetch the minimum balance needed to exempt an account of `dataLength`\n * size from rent\n */\n async getMinimumBalanceForRentExemption(dataLength, commitment) {\n const args = this._buildArgs([dataLength], commitment);\n const unsafeRes = await this._rpcRequest('getMinimumBalanceForRentExemption', args);\n const res = create(unsafeRes, GetMinimumBalanceForRentExemptionRpcResult);\n if ('error' in res) {\n console.warn('Unable to fetch minimum balance for rent exemption');\n return 0;\n }\n return res.result;\n }\n\n /**\n * Fetch a recent blockhash from the cluster, return with context\n * @return {Promise>}\n *\n * @deprecated Deprecated since Solana v1.8.0. Please use {@link getLatestBlockhash} instead.\n */\n async getRecentBlockhashAndContext(commitment) {\n const args = this._buildArgs([], commitment);\n const unsafeRes = await this._rpcRequest('getRecentBlockhash', args);\n const res = create(unsafeRes, GetRecentBlockhashAndContextRpcResult);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get recent blockhash');\n }\n return res.result;\n }\n\n /**\n * Fetch recent performance samples\n * @return {Promise>}\n */\n async getRecentPerformanceSamples(limit) {\n const unsafeRes = await this._rpcRequest('getRecentPerformanceSamples', limit ? [limit] : []);\n const res = create(unsafeRes, GetRecentPerformanceSamplesRpcResult);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get recent performance samples');\n }\n return res.result;\n }\n\n /**\n * Fetch the fee calculator for a recent blockhash from the cluster, return with context\n *\n * @deprecated Deprecated since Solana v1.8.0. Please use {@link getFeeForMessage} instead.\n */\n async getFeeCalculatorForBlockhash(blockhash, commitment) {\n const args = this._buildArgs([blockhash], commitment);\n const unsafeRes = await this._rpcRequest('getFeeCalculatorForBlockhash', args);\n const res = create(unsafeRes, GetFeeCalculatorRpcResult);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get fee calculator');\n }\n const {\n context,\n value\n } = res.result;\n return {\n context,\n value: value !== null ? value.feeCalculator : null\n };\n }\n\n /**\n * Fetch the fee for a message from the cluster, return with context\n */\n async getFeeForMessage(message, commitment) {\n const wireMessage = toBuffer(message.serialize()).toString('base64');\n const args = this._buildArgs([wireMessage], commitment);\n const unsafeRes = await this._rpcRequest('getFeeForMessage', args);\n const res = create(unsafeRes, jsonRpcResultAndContext(nullable(number())));\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get fee for message');\n }\n if (res.result === null) {\n throw new Error('invalid blockhash');\n }\n return res.result;\n }\n\n /**\n * Fetch a list of prioritization fees from recent blocks.\n */\n async getRecentPrioritizationFees(config) {\n const accounts = config?.lockedWritableAccounts?.map(key => key.toBase58());\n const args = accounts?.length ? [accounts] : [];\n const unsafeRes = await this._rpcRequest('getRecentPrioritizationFees', args);\n const res = create(unsafeRes, GetRecentPrioritizationFeesRpcResult);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get recent prioritization fees');\n }\n return res.result;\n }\n /**\n * Fetch a recent blockhash from the cluster\n * @return {Promise<{blockhash: Blockhash, feeCalculator: FeeCalculator}>}\n *\n * @deprecated Deprecated since Solana v1.8.0. Please use {@link getLatestBlockhash} instead.\n */\n async getRecentBlockhash(commitment) {\n try {\n const res = await this.getRecentBlockhashAndContext(commitment);\n return res.value;\n } catch (e) {\n throw new Error('failed to get recent blockhash: ' + e);\n }\n }\n\n /**\n * Fetch the latest blockhash from the cluster\n * @return {Promise}\n */\n async getLatestBlockhash(commitmentOrConfig) {\n try {\n const res = await this.getLatestBlockhashAndContext(commitmentOrConfig);\n return res.value;\n } catch (e) {\n throw new Error('failed to get recent blockhash: ' + e);\n }\n }\n\n /**\n * Fetch the latest blockhash from the cluster\n * @return {Promise}\n */\n async getLatestBlockhashAndContext(commitmentOrConfig) {\n const {\n commitment,\n config\n } = extractCommitmentFromConfig(commitmentOrConfig);\n const args = this._buildArgs([], commitment, undefined /* encoding */, config);\n const unsafeRes = await this._rpcRequest('getLatestBlockhash', args);\n const res = create(unsafeRes, GetLatestBlockhashRpcResult);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get latest blockhash');\n }\n return res.result;\n }\n\n /**\n * Returns whether a blockhash is still valid or not\n */\n async isBlockhashValid(blockhash, rawConfig) {\n const {\n commitment,\n config\n } = extractCommitmentFromConfig(rawConfig);\n const args = this._buildArgs([blockhash], commitment, undefined /* encoding */, config);\n const unsafeRes = await this._rpcRequest('isBlockhashValid', args);\n const res = create(unsafeRes, IsBlockhashValidRpcResult);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to determine if the blockhash `' + blockhash + '`is valid');\n }\n return res.result;\n }\n\n /**\n * Fetch the node version\n */\n async getVersion() {\n const unsafeRes = await this._rpcRequest('getVersion', []);\n const res = create(unsafeRes, jsonRpcResult(VersionResult));\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get version');\n }\n return res.result;\n }\n\n /**\n * Fetch the genesis hash\n */\n async getGenesisHash() {\n const unsafeRes = await this._rpcRequest('getGenesisHash', []);\n const res = create(unsafeRes, jsonRpcResult(string()));\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get genesis hash');\n }\n return res.result;\n }\n\n /**\n * Fetch a processed block from the cluster.\n *\n * @deprecated Instead, call `getBlock` using a `GetVersionedBlockConfig` by\n * setting the `maxSupportedTransactionVersion` property.\n */\n\n /**\n * @deprecated Instead, call `getBlock` using a `GetVersionedBlockConfig` by\n * setting the `maxSupportedTransactionVersion` property.\n */\n // eslint-disable-next-line no-dupe-class-members\n\n /**\n * @deprecated Instead, call `getBlock` using a `GetVersionedBlockConfig` by\n * setting the `maxSupportedTransactionVersion` property.\n */\n // eslint-disable-next-line no-dupe-class-members\n\n /**\n * Fetch a processed block from the cluster.\n */\n // eslint-disable-next-line no-dupe-class-members\n\n // eslint-disable-next-line no-dupe-class-members\n\n // eslint-disable-next-line no-dupe-class-members\n\n /**\n * Fetch a processed block from the cluster.\n */\n // eslint-disable-next-line no-dupe-class-members\n async getBlock(slot, rawConfig) {\n const {\n commitment,\n config\n } = extractCommitmentFromConfig(rawConfig);\n const args = this._buildArgsAtLeastConfirmed([slot], commitment, undefined /* encoding */, config);\n const unsafeRes = await this._rpcRequest('getBlock', args);\n try {\n switch (config?.transactionDetails) {\n case 'accounts':\n {\n const res = create(unsafeRes, GetAccountsModeBlockRpcResult);\n if ('error' in res) {\n throw res.error;\n }\n return res.result;\n }\n case 'none':\n {\n const res = create(unsafeRes, GetNoneModeBlockRpcResult);\n if ('error' in res) {\n throw res.error;\n }\n return res.result;\n }\n default:\n {\n const res = create(unsafeRes, GetBlockRpcResult);\n if ('error' in res) {\n throw res.error;\n }\n const {\n result\n } = res;\n return result ? {\n ...result,\n transactions: result.transactions.map(({\n transaction,\n meta,\n version\n }) => ({\n meta,\n transaction: {\n ...transaction,\n message: versionedMessageFromResponse(version, transaction.message)\n },\n version\n }))\n } : null;\n }\n }\n } catch (e) {\n throw new SolanaJSONRPCError(e, 'failed to get confirmed block');\n }\n }\n\n /**\n * Fetch parsed transaction details for a confirmed or finalized block\n */\n\n // eslint-disable-next-line no-dupe-class-members\n\n // eslint-disable-next-line no-dupe-class-members\n\n // eslint-disable-next-line no-dupe-class-members\n async getParsedBlock(slot, rawConfig) {\n const {\n commitment,\n config\n } = extractCommitmentFromConfig(rawConfig);\n const args = this._buildArgsAtLeastConfirmed([slot], commitment, 'jsonParsed', config);\n const unsafeRes = await this._rpcRequest('getBlock', args);\n try {\n switch (config?.transactionDetails) {\n case 'accounts':\n {\n const res = create(unsafeRes, GetParsedAccountsModeBlockRpcResult);\n if ('error' in res) {\n throw res.error;\n }\n return res.result;\n }\n case 'none':\n {\n const res = create(unsafeRes, GetParsedNoneModeBlockRpcResult);\n if ('error' in res) {\n throw res.error;\n }\n return res.result;\n }\n default:\n {\n const res = create(unsafeRes, GetParsedBlockRpcResult);\n if ('error' in res) {\n throw res.error;\n }\n return res.result;\n }\n }\n } catch (e) {\n throw new SolanaJSONRPCError(e, 'failed to get block');\n }\n }\n /*\n * Returns recent block production information from the current or previous epoch\n */\n async getBlockProduction(configOrCommitment) {\n let extra;\n let commitment;\n if (typeof configOrCommitment === 'string') {\n commitment = configOrCommitment;\n } else if (configOrCommitment) {\n const {\n commitment: c,\n ...rest\n } = configOrCommitment;\n commitment = c;\n extra = rest;\n }\n const args = this._buildArgs([], commitment, 'base64', extra);\n const unsafeRes = await this._rpcRequest('getBlockProduction', args);\n const res = create(unsafeRes, BlockProductionResponseStruct);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get block production information');\n }\n return res.result;\n }\n\n /**\n * Fetch a confirmed or finalized transaction from the cluster.\n *\n * @deprecated Instead, call `getTransaction` using a\n * `GetVersionedTransactionConfig` by setting the\n * `maxSupportedTransactionVersion` property.\n */\n\n /**\n * Fetch a confirmed or finalized transaction from the cluster.\n */\n // eslint-disable-next-line no-dupe-class-members\n\n /**\n * Fetch a confirmed or finalized transaction from the cluster.\n */\n // eslint-disable-next-line no-dupe-class-members\n async getTransaction(signature, rawConfig) {\n const {\n commitment,\n config\n } = extractCommitmentFromConfig(rawConfig);\n const args = this._buildArgsAtLeastConfirmed([signature], commitment, undefined /* encoding */, config);\n const unsafeRes = await this._rpcRequest('getTransaction', args);\n const res = create(unsafeRes, GetTransactionRpcResult);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get transaction');\n }\n const result = res.result;\n if (!result) return result;\n return {\n ...result,\n transaction: {\n ...result.transaction,\n message: versionedMessageFromResponse(result.version, result.transaction.message)\n }\n };\n }\n\n /**\n * Fetch parsed transaction details for a confirmed or finalized transaction\n */\n async getParsedTransaction(signature, commitmentOrConfig) {\n const {\n commitment,\n config\n } = extractCommitmentFromConfig(commitmentOrConfig);\n const args = this._buildArgsAtLeastConfirmed([signature], commitment, 'jsonParsed', config);\n const unsafeRes = await this._rpcRequest('getTransaction', args);\n const res = create(unsafeRes, GetParsedTransactionRpcResult);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get transaction');\n }\n return res.result;\n }\n\n /**\n * Fetch parsed transaction details for a batch of confirmed transactions\n */\n async getParsedTransactions(signatures, commitmentOrConfig) {\n const {\n commitment,\n config\n } = extractCommitmentFromConfig(commitmentOrConfig);\n const batch = signatures.map(signature => {\n const args = this._buildArgsAtLeastConfirmed([signature], commitment, 'jsonParsed', config);\n return {\n methodName: 'getTransaction',\n args\n };\n });\n const unsafeRes = await this._rpcBatchRequest(batch);\n const res = unsafeRes.map(unsafeRes => {\n const res = create(unsafeRes, GetParsedTransactionRpcResult);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get transactions');\n }\n return res.result;\n });\n return res;\n }\n\n /**\n * Fetch transaction details for a batch of confirmed transactions.\n * Similar to {@link getParsedTransactions} but returns a {@link TransactionResponse}.\n *\n * @deprecated Instead, call `getTransactions` using a\n * `GetVersionedTransactionConfig` by setting the\n * `maxSupportedTransactionVersion` property.\n */\n\n /**\n * Fetch transaction details for a batch of confirmed transactions.\n * Similar to {@link getParsedTransactions} but returns a {@link\n * VersionedTransactionResponse}.\n */\n // eslint-disable-next-line no-dupe-class-members\n\n /**\n * Fetch transaction details for a batch of confirmed transactions.\n * Similar to {@link getParsedTransactions} but returns a {@link\n * VersionedTransactionResponse}.\n */\n // eslint-disable-next-line no-dupe-class-members\n async getTransactions(signatures, commitmentOrConfig) {\n const {\n commitment,\n config\n } = extractCommitmentFromConfig(commitmentOrConfig);\n const batch = signatures.map(signature => {\n const args = this._buildArgsAtLeastConfirmed([signature], commitment, undefined /* encoding */, config);\n return {\n methodName: 'getTransaction',\n args\n };\n });\n const unsafeRes = await this._rpcBatchRequest(batch);\n const res = unsafeRes.map(unsafeRes => {\n const res = create(unsafeRes, GetTransactionRpcResult);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get transactions');\n }\n const result = res.result;\n if (!result) return result;\n return {\n ...result,\n transaction: {\n ...result.transaction,\n message: versionedMessageFromResponse(result.version, result.transaction.message)\n }\n };\n });\n return res;\n }\n\n /**\n * Fetch a list of Transactions and transaction statuses from the cluster\n * for a confirmed block.\n *\n * @deprecated Deprecated since v1.13.0. Please use {@link getBlock} instead.\n */\n async getConfirmedBlock(slot, commitment) {\n const args = this._buildArgsAtLeastConfirmed([slot], commitment);\n const unsafeRes = await this._rpcRequest('getConfirmedBlock', args);\n const res = create(unsafeRes, GetConfirmedBlockRpcResult);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get confirmed block');\n }\n const result = res.result;\n if (!result) {\n throw new Error('Confirmed block ' + slot + ' not found');\n }\n const block = {\n ...result,\n transactions: result.transactions.map(({\n transaction,\n meta\n }) => {\n const message = new Message(transaction.message);\n return {\n meta,\n transaction: {\n ...transaction,\n message\n }\n };\n })\n };\n return {\n ...block,\n transactions: block.transactions.map(({\n transaction,\n meta\n }) => {\n return {\n meta,\n transaction: Transaction.populate(transaction.message, transaction.signatures)\n };\n })\n };\n }\n\n /**\n * Fetch confirmed blocks between two slots\n */\n async getBlocks(startSlot, endSlot, commitment) {\n const args = this._buildArgsAtLeastConfirmed(endSlot !== undefined ? [startSlot, endSlot] : [startSlot], commitment);\n const unsafeRes = await this._rpcRequest('getBlocks', args);\n const res = create(unsafeRes, jsonRpcResult(array(number())));\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get blocks');\n }\n return res.result;\n }\n\n /**\n * Fetch a list of Signatures from the cluster for a block, excluding rewards\n */\n async getBlockSignatures(slot, commitment) {\n const args = this._buildArgsAtLeastConfirmed([slot], commitment, undefined, {\n transactionDetails: 'signatures',\n rewards: false\n });\n const unsafeRes = await this._rpcRequest('getBlock', args);\n const res = create(unsafeRes, GetBlockSignaturesRpcResult);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get block');\n }\n const result = res.result;\n if (!result) {\n throw new Error('Block ' + slot + ' not found');\n }\n return result;\n }\n\n /**\n * Fetch a list of Signatures from the cluster for a confirmed block, excluding rewards\n *\n * @deprecated Deprecated since Solana v1.8.0. Please use {@link getBlockSignatures} instead.\n */\n async getConfirmedBlockSignatures(slot, commitment) {\n const args = this._buildArgsAtLeastConfirmed([slot], commitment, undefined, {\n transactionDetails: 'signatures',\n rewards: false\n });\n const unsafeRes = await this._rpcRequest('getConfirmedBlock', args);\n const res = create(unsafeRes, GetBlockSignaturesRpcResult);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get confirmed block');\n }\n const result = res.result;\n if (!result) {\n throw new Error('Confirmed block ' + slot + ' not found');\n }\n return result;\n }\n\n /**\n * Fetch a transaction details for a confirmed transaction\n *\n * @deprecated Deprecated since Solana v1.8.0. Please use {@link getTransaction} instead.\n */\n async getConfirmedTransaction(signature, commitment) {\n const args = this._buildArgsAtLeastConfirmed([signature], commitment);\n const unsafeRes = await this._rpcRequest('getConfirmedTransaction', args);\n const res = create(unsafeRes, GetTransactionRpcResult);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get transaction');\n }\n const result = res.result;\n if (!result) return result;\n const message = new Message(result.transaction.message);\n const signatures = result.transaction.signatures;\n return {\n ...result,\n transaction: Transaction.populate(message, signatures)\n };\n }\n\n /**\n * Fetch parsed transaction details for a confirmed transaction\n *\n * @deprecated Deprecated since Solana v1.8.0. Please use {@link getParsedTransaction} instead.\n */\n async getParsedConfirmedTransaction(signature, commitment) {\n const args = this._buildArgsAtLeastConfirmed([signature], commitment, 'jsonParsed');\n const unsafeRes = await this._rpcRequest('getConfirmedTransaction', args);\n const res = create(unsafeRes, GetParsedTransactionRpcResult);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get confirmed transaction');\n }\n return res.result;\n }\n\n /**\n * Fetch parsed transaction details for a batch of confirmed transactions\n *\n * @deprecated Deprecated since Solana v1.8.0. Please use {@link getParsedTransactions} instead.\n */\n async getParsedConfirmedTransactions(signatures, commitment) {\n const batch = signatures.map(signature => {\n const args = this._buildArgsAtLeastConfirmed([signature], commitment, 'jsonParsed');\n return {\n methodName: 'getConfirmedTransaction',\n args\n };\n });\n const unsafeRes = await this._rpcBatchRequest(batch);\n const res = unsafeRes.map(unsafeRes => {\n const res = create(unsafeRes, GetParsedTransactionRpcResult);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get confirmed transactions');\n }\n return res.result;\n });\n return res;\n }\n\n /**\n * Fetch a list of all the confirmed signatures for transactions involving an address\n * within a specified slot range. Max range allowed is 10,000 slots.\n *\n * @deprecated Deprecated since v1.3. Please use {@link getConfirmedSignaturesForAddress2} instead.\n *\n * @param address queried address\n * @param startSlot start slot, inclusive\n * @param endSlot end slot, inclusive\n */\n async getConfirmedSignaturesForAddress(address, startSlot, endSlot) {\n let options = {};\n let firstAvailableBlock = await this.getFirstAvailableBlock();\n while (!('until' in options)) {\n startSlot--;\n if (startSlot <= 0 || startSlot < firstAvailableBlock) {\n break;\n }\n try {\n const block = await this.getConfirmedBlockSignatures(startSlot, 'finalized');\n if (block.signatures.length > 0) {\n options.until = block.signatures[block.signatures.length - 1].toString();\n }\n } catch (err) {\n if (err instanceof Error && err.message.includes('skipped')) {\n continue;\n } else {\n throw err;\n }\n }\n }\n let highestConfirmedRoot = await this.getSlot('finalized');\n while (!('before' in options)) {\n endSlot++;\n if (endSlot > highestConfirmedRoot) {\n break;\n }\n try {\n const block = await this.getConfirmedBlockSignatures(endSlot);\n if (block.signatures.length > 0) {\n options.before = block.signatures[block.signatures.length - 1].toString();\n }\n } catch (err) {\n if (err instanceof Error && err.message.includes('skipped')) {\n continue;\n } else {\n throw err;\n }\n }\n }\n const confirmedSignatureInfo = await this.getConfirmedSignaturesForAddress2(address, options);\n return confirmedSignatureInfo.map(info => info.signature);\n }\n\n /**\n * Returns confirmed signatures for transactions involving an\n * address backwards in time from the provided signature or most recent confirmed block\n *\n *\n * @param address queried address\n * @param options\n */\n async getConfirmedSignaturesForAddress2(address, options, commitment) {\n const args = this._buildArgsAtLeastConfirmed([address.toBase58()], commitment, undefined, options);\n const unsafeRes = await this._rpcRequest('getConfirmedSignaturesForAddress2', args);\n const res = create(unsafeRes, GetConfirmedSignaturesForAddress2RpcResult);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get confirmed signatures for address');\n }\n return res.result;\n }\n\n /**\n * Returns confirmed signatures for transactions involving an\n * address backwards in time from the provided signature or most recent confirmed block\n *\n *\n * @param address queried address\n * @param options\n */\n async getSignaturesForAddress(address, options, commitment) {\n const args = this._buildArgsAtLeastConfirmed([address.toBase58()], commitment, undefined, options);\n const unsafeRes = await this._rpcRequest('getSignaturesForAddress', args);\n const res = create(unsafeRes, GetSignaturesForAddressRpcResult);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, 'failed to get signatures for address');\n }\n return res.result;\n }\n async getAddressLookupTable(accountKey, config) {\n const {\n context,\n value: accountInfo\n } = await this.getAccountInfoAndContext(accountKey, config);\n let value = null;\n if (accountInfo !== null) {\n value = new AddressLookupTableAccount({\n key: accountKey,\n state: AddressLookupTableAccount.deserialize(accountInfo.data)\n });\n }\n return {\n context,\n value\n };\n }\n\n /**\n * Fetch the contents of a Nonce account from the cluster, return with context\n */\n async getNonceAndContext(nonceAccount, commitmentOrConfig) {\n const {\n context,\n value: accountInfo\n } = await this.getAccountInfoAndContext(nonceAccount, commitmentOrConfig);\n let value = null;\n if (accountInfo !== null) {\n value = NonceAccount.fromAccountData(accountInfo.data);\n }\n return {\n context,\n value\n };\n }\n\n /**\n * Fetch the contents of a Nonce account from the cluster\n */\n async getNonce(nonceAccount, commitmentOrConfig) {\n return await this.getNonceAndContext(nonceAccount, commitmentOrConfig).then(x => x.value).catch(e => {\n throw new Error('failed to get nonce for account ' + nonceAccount.toBase58() + ': ' + e);\n });\n }\n\n /**\n * Request an allocation of lamports to the specified address\n *\n * ```typescript\n * import { Connection, PublicKey, LAMPORTS_PER_SOL } from \"@solana/web3.js\";\n *\n * (async () => {\n * const connection = new Connection(\"https://api.testnet.solana.com\", \"confirmed\");\n * const myAddress = new PublicKey(\"2nr1bHFT86W9tGnyvmYW4vcHKsQB3sVQfnddasz4kExM\");\n * const signature = await connection.requestAirdrop(myAddress, LAMPORTS_PER_SOL);\n * await connection.confirmTransaction(signature);\n * })();\n * ```\n */\n async requestAirdrop(to, lamports) {\n const unsafeRes = await this._rpcRequest('requestAirdrop', [to.toBase58(), lamports]);\n const res = create(unsafeRes, RequestAirdropRpcResult);\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, `airdrop to ${to.toBase58()} failed`);\n }\n return res.result;\n }\n\n /**\n * @internal\n */\n async _blockhashWithExpiryBlockHeight(disableCache) {\n if (!disableCache) {\n // Wait for polling to finish\n while (this._pollingBlockhash) {\n await sleep(100);\n }\n const timeSinceFetch = Date.now() - this._blockhashInfo.lastFetch;\n const expired = timeSinceFetch >= BLOCKHASH_CACHE_TIMEOUT_MS;\n if (this._blockhashInfo.latestBlockhash !== null && !expired) {\n return this._blockhashInfo.latestBlockhash;\n }\n }\n return await this._pollNewBlockhash();\n }\n\n /**\n * @internal\n */\n async _pollNewBlockhash() {\n this._pollingBlockhash = true;\n try {\n const startTime = Date.now();\n const cachedLatestBlockhash = this._blockhashInfo.latestBlockhash;\n const cachedBlockhash = cachedLatestBlockhash ? cachedLatestBlockhash.blockhash : null;\n for (let i = 0; i < 50; i++) {\n const latestBlockhash = await this.getLatestBlockhash('finalized');\n if (cachedBlockhash !== latestBlockhash.blockhash) {\n this._blockhashInfo = {\n latestBlockhash,\n lastFetch: Date.now(),\n transactionSignatures: [],\n simulatedSignatures: []\n };\n return latestBlockhash;\n }\n\n // Sleep for approximately half a slot\n await sleep(MS_PER_SLOT / 2);\n }\n throw new Error(`Unable to obtain a new blockhash after ${Date.now() - startTime}ms`);\n } finally {\n this._pollingBlockhash = false;\n }\n }\n\n /**\n * get the stake minimum delegation\n */\n async getStakeMinimumDelegation(config) {\n const {\n commitment,\n config: configArg\n } = extractCommitmentFromConfig(config);\n const args = this._buildArgs([], commitment, 'base64', configArg);\n const unsafeRes = await this._rpcRequest('getStakeMinimumDelegation', args);\n const res = create(unsafeRes, jsonRpcResultAndContext(number()));\n if ('error' in res) {\n throw new SolanaJSONRPCError(res.error, `failed to get stake minimum delegation`);\n }\n return res.result;\n }\n\n /**\n * Simulate a transaction\n *\n * @deprecated Instead, call {@link simulateTransaction} with {@link\n * VersionedTransaction} and {@link SimulateTransactionConfig} parameters\n */\n\n /**\n * Simulate a transaction\n */\n // eslint-disable-next-line no-dupe-class-members\n\n /**\n * Simulate a transaction\n */\n // eslint-disable-next-line no-dupe-class-members\n async simulateTransaction(transactionOrMessage, configOrSigners, includeAccounts) {\n if ('message' in transactionOrMessage) {\n const versionedTx = transactionOrMessage;\n const wireTransaction = versionedTx.serialize();\n const encodedTransaction = Buffer.from(wireTransaction).toString('base64');\n if (Array.isArray(configOrSigners) || includeAccounts !== undefined) {\n throw new Error('Invalid arguments');\n }\n const config = configOrSigners || {};\n config.encoding = 'base64';\n if (!('commitment' in config)) {\n config.commitment = this.commitment;\n }\n const args = [encodedTransaction, config];\n const unsafeRes = await this._rpcRequest('simulateTransaction', args);\n const res = create(unsafeRes, SimulatedTransactionResponseStruct);\n if ('error' in res) {\n throw new Error('failed to simulate transaction: ' + res.error.message);\n }\n return res.result;\n }\n let transaction;\n if (transactionOrMessage instanceof Transaction) {\n let originalTx = transactionOrMessage;\n transaction = new Transaction();\n transaction.feePayer = originalTx.feePayer;\n transaction.instructions = transactionOrMessage.instructions;\n transaction.nonceInfo = originalTx.nonceInfo;\n transaction.signatures = originalTx.signatures;\n } else {\n transaction = Transaction.populate(transactionOrMessage);\n // HACK: this function relies on mutating the populated transaction\n transaction._message = transaction._json = undefined;\n }\n if (configOrSigners !== undefined && !Array.isArray(configOrSigners)) {\n throw new Error('Invalid arguments');\n }\n const signers = configOrSigners;\n if (transaction.nonceInfo && signers) {\n transaction.sign(...signers);\n } else {\n let disableCache = this._disableBlockhashCaching;\n for (;;) {\n const latestBlockhash = await this._blockhashWithExpiryBlockHeight(disableCache);\n transaction.lastValidBlockHeight = latestBlockhash.lastValidBlockHeight;\n transaction.recentBlockhash = latestBlockhash.blockhash;\n if (!signers) break;\n transaction.sign(...signers);\n if (!transaction.signature) {\n throw new Error('!signature'); // should never happen\n }\n const signature = transaction.signature.toString('base64');\n if (!this._blockhashInfo.simulatedSignatures.includes(signature) && !this._blockhashInfo.transactionSignatures.includes(signature)) {\n // The signature of this transaction has not been seen before with the\n // current recentBlockhash, all done. Let's break\n this._blockhashInfo.simulatedSignatures.push(signature);\n break;\n } else {\n // This transaction would be treated as duplicate (its derived signature\n // matched to one of already recorded signatures).\n // So, we must fetch a new blockhash for a different signature by disabling\n // our cache not to wait for the cache expiration (BLOCKHASH_CACHE_TIMEOUT_MS).\n disableCache = true;\n }\n }\n }\n const message = transaction._compile();\n const signData = message.serialize();\n const wireTransaction = transaction._serialize(signData);\n const encodedTransaction = wireTransaction.toString('base64');\n const config = {\n encoding: 'base64',\n commitment: this.commitment\n };\n if (includeAccounts) {\n const addresses = (Array.isArray(includeAccounts) ? includeAccounts : message.nonProgramIds()).map(key => key.toBase58());\n config['accounts'] = {\n encoding: 'base64',\n addresses\n };\n }\n if (signers) {\n config.sigVerify = true;\n }\n const args = [encodedTransaction, config];\n const unsafeRes = await this._rpcRequest('simulateTransaction', args);\n const res = create(unsafeRes, SimulatedTransactionResponseStruct);\n if ('error' in res) {\n let logs;\n if ('data' in res.error) {\n logs = res.error.data.logs;\n if (logs && Array.isArray(logs)) {\n const traceIndent = '\\n ';\n const logTrace = traceIndent + logs.join(traceIndent);\n console.error(res.error.message, logTrace);\n }\n }\n throw new SendTransactionError('failed to simulate transaction: ' + res.error.message, logs);\n }\n return res.result;\n }\n\n /**\n * Sign and send a transaction\n *\n * @deprecated Instead, call {@link sendTransaction} with a {@link\n * VersionedTransaction}\n */\n\n /**\n * Send a signed transaction\n */\n // eslint-disable-next-line no-dupe-class-members\n\n /**\n * Sign and send a transaction\n */\n // eslint-disable-next-line no-dupe-class-members\n async sendTransaction(transaction, signersOrOptions, options) {\n if ('version' in transaction) {\n if (signersOrOptions && Array.isArray(signersOrOptions)) {\n throw new Error('Invalid arguments');\n }\n const wireTransaction = transaction.serialize();\n return await this.sendRawTransaction(wireTransaction, signersOrOptions);\n }\n if (signersOrOptions === undefined || !Array.isArray(signersOrOptions)) {\n throw new Error('Invalid arguments');\n }\n const signers = signersOrOptions;\n if (transaction.nonceInfo) {\n transaction.sign(...signers);\n } else {\n let disableCache = this._disableBlockhashCaching;\n for (;;) {\n const latestBlockhash = await this._blockhashWithExpiryBlockHeight(disableCache);\n transaction.lastValidBlockHeight = latestBlockhash.lastValidBlockHeight;\n transaction.recentBlockhash = latestBlockhash.blockhash;\n transaction.sign(...signers);\n if (!transaction.signature) {\n throw new Error('!signature'); // should never happen\n }\n const signature = transaction.signature.toString('base64');\n if (!this._blockhashInfo.transactionSignatures.includes(signature)) {\n // The signature of this transaction has not been seen before with the\n // current recentBlockhash, all done. Let's break\n this._blockhashInfo.transactionSignatures.push(signature);\n break;\n } else {\n // This transaction would be treated as duplicate (its derived signature\n // matched to one of already recorded signatures).\n // So, we must fetch a new blockhash for a different signature by disabling\n // our cache not to wait for the cache expiration (BLOCKHASH_CACHE_TIMEOUT_MS).\n disableCache = true;\n }\n }\n }\n const wireTransaction = transaction.serialize();\n return await this.sendRawTransaction(wireTransaction, options);\n }\n\n /**\n * Send a transaction that has already been signed and serialized into the\n * wire format\n */\n async sendRawTransaction(rawTransaction, options) {\n const encodedTransaction = toBuffer(rawTransaction).toString('base64');\n const result = await this.sendEncodedTransaction(encodedTransaction, options);\n return result;\n }\n\n /**\n * Send a transaction that has already been signed, serialized into the\n * wire format, and encoded as a base64 string\n */\n async sendEncodedTransaction(encodedTransaction, options) {\n const config = {\n encoding: 'base64'\n };\n const skipPreflight = options && options.skipPreflight;\n const preflightCommitment = skipPreflight === true ? 'processed' // FIXME Remove when https://github.com/anza-xyz/agave/pull/483 is deployed.\n : options && options.preflightCommitment || this.commitment;\n if (options && options.maxRetries != null) {\n config.maxRetries = options.maxRetries;\n }\n if (options && options.minContextSlot != null) {\n config.minContextSlot = options.minContextSlot;\n }\n if (skipPreflight) {\n config.skipPreflight = skipPreflight;\n }\n if (preflightCommitment) {\n config.preflightCommitment = preflightCommitment;\n }\n const args = [encodedTransaction, config];\n const unsafeRes = await this._rpcRequest('sendTransaction', args);\n const res = create(unsafeRes, SendTransactionRpcResult);\n if ('error' in res) {\n let logs;\n if ('data' in res.error) {\n logs = res.error.data.logs;\n }\n throw new SendTransactionError('failed to send transaction: ' + res.error.message, logs);\n }\n return res.result;\n }\n\n /**\n * @internal\n */\n _wsOnOpen() {\n this._rpcWebSocketConnected = true;\n this._rpcWebSocketHeartbeat = setInterval(() => {\n // Ping server every 5s to prevent idle timeouts\n (async () => {\n try {\n await this._rpcWebSocket.notify('ping');\n // eslint-disable-next-line no-empty\n } catch {}\n })();\n }, 5000);\n this._updateSubscriptions();\n }\n\n /**\n * @internal\n */\n _wsOnError(err) {\n this._rpcWebSocketConnected = false;\n console.error('ws error:', err.message);\n }\n\n /**\n * @internal\n */\n _wsOnClose(code) {\n this._rpcWebSocketConnected = false;\n this._rpcWebSocketGeneration = (this._rpcWebSocketGeneration + 1) % Number.MAX_SAFE_INTEGER;\n if (this._rpcWebSocketIdleTimeout) {\n clearTimeout(this._rpcWebSocketIdleTimeout);\n this._rpcWebSocketIdleTimeout = null;\n }\n if (this._rpcWebSocketHeartbeat) {\n clearInterval(this._rpcWebSocketHeartbeat);\n this._rpcWebSocketHeartbeat = null;\n }\n if (code === 1000) {\n // explicit close, check if any subscriptions have been made since close\n this._updateSubscriptions();\n return;\n }\n\n // implicit close, prepare subscriptions for auto-reconnect\n this._subscriptionCallbacksByServerSubscriptionId = {};\n Object.entries(this._subscriptionsByHash).forEach(([hash, subscription]) => {\n this._setSubscription(hash, {\n ...subscription,\n state: 'pending'\n });\n });\n }\n\n /**\n * @internal\n */\n _setSubscription(hash, nextSubscription) {\n const prevState = this._subscriptionsByHash[hash]?.state;\n this._subscriptionsByHash[hash] = nextSubscription;\n if (prevState !== nextSubscription.state) {\n const stateChangeCallbacks = this._subscriptionStateChangeCallbacksByHash[hash];\n if (stateChangeCallbacks) {\n stateChangeCallbacks.forEach(cb => {\n try {\n cb(nextSubscription.state);\n // eslint-disable-next-line no-empty\n } catch {}\n });\n }\n }\n }\n\n /**\n * @internal\n */\n _onSubscriptionStateChange(clientSubscriptionId, callback) {\n const hash = this._subscriptionHashByClientSubscriptionId[clientSubscriptionId];\n if (hash == null) {\n return () => {};\n }\n const stateChangeCallbacks = this._subscriptionStateChangeCallbacksByHash[hash] ||= new Set();\n stateChangeCallbacks.add(callback);\n return () => {\n stateChangeCallbacks.delete(callback);\n if (stateChangeCallbacks.size === 0) {\n delete this._subscriptionStateChangeCallbacksByHash[hash];\n }\n };\n }\n\n /**\n * @internal\n */\n async _updateSubscriptions() {\n if (Object.keys(this._subscriptionsByHash).length === 0) {\n if (this._rpcWebSocketConnected) {\n this._rpcWebSocketConnected = false;\n this._rpcWebSocketIdleTimeout = setTimeout(() => {\n this._rpcWebSocketIdleTimeout = null;\n try {\n this._rpcWebSocket.close();\n } catch (err) {\n // swallow error if socket has already been closed.\n if (err instanceof Error) {\n console.log(`Error when closing socket connection: ${err.message}`);\n }\n }\n }, 500);\n }\n return;\n }\n if (this._rpcWebSocketIdleTimeout !== null) {\n clearTimeout(this._rpcWebSocketIdleTimeout);\n this._rpcWebSocketIdleTimeout = null;\n this._rpcWebSocketConnected = true;\n }\n if (!this._rpcWebSocketConnected) {\n this._rpcWebSocket.connect();\n return;\n }\n const activeWebSocketGeneration = this._rpcWebSocketGeneration;\n const isCurrentConnectionStillActive = () => {\n return activeWebSocketGeneration === this._rpcWebSocketGeneration;\n };\n await Promise.all(\n // Don't be tempted to change this to `Object.entries`. We call\n // `_updateSubscriptions` recursively when processing the state,\n // so it's important that we look up the *current* version of\n // each subscription, every time we process a hash.\n Object.keys(this._subscriptionsByHash).map(async hash => {\n const subscription = this._subscriptionsByHash[hash];\n if (subscription === undefined) {\n // This entry has since been deleted. Skip.\n return;\n }\n switch (subscription.state) {\n case 'pending':\n case 'unsubscribed':\n if (subscription.callbacks.size === 0) {\n /**\n * You can end up here when:\n *\n * - a subscription has recently unsubscribed\n * without having new callbacks added to it\n * while the unsubscribe was in flight, or\n * - when a pending subscription has its\n * listeners removed before a request was\n * sent to the server.\n *\n * Being that nobody is interested in this\n * subscription any longer, delete it.\n */\n delete this._subscriptionsByHash[hash];\n if (subscription.state === 'unsubscribed') {\n delete this._subscriptionCallbacksByServerSubscriptionId[subscription.serverSubscriptionId];\n }\n await this._updateSubscriptions();\n return;\n }\n await (async () => {\n const {\n args,\n method\n } = subscription;\n try {\n this._setSubscription(hash, {\n ...subscription,\n state: 'subscribing'\n });\n const serverSubscriptionId = await this._rpcWebSocket.call(method, args);\n this._setSubscription(hash, {\n ...subscription,\n serverSubscriptionId,\n state: 'subscribed'\n });\n this._subscriptionCallbacksByServerSubscriptionId[serverSubscriptionId] = subscription.callbacks;\n await this._updateSubscriptions();\n } catch (e) {\n if (e instanceof Error) {\n console.error(`${method} error for argument`, args, e.message);\n }\n if (!isCurrentConnectionStillActive()) {\n return;\n }\n // TODO: Maybe add an 'errored' state or a retry limit?\n this._setSubscription(hash, {\n ...subscription,\n state: 'pending'\n });\n await this._updateSubscriptions();\n }\n })();\n break;\n case 'subscribed':\n if (subscription.callbacks.size === 0) {\n // By the time we successfully set up a subscription\n // with the server, the client stopped caring about it.\n // Tear it down now.\n await (async () => {\n const {\n serverSubscriptionId,\n unsubscribeMethod\n } = subscription;\n if (this._subscriptionsAutoDisposedByRpc.has(serverSubscriptionId)) {\n /**\n * Special case.\n * If we're dealing with a subscription that has been auto-\n * disposed by the RPC, then we can skip the RPC call to\n * tear down the subscription here.\n *\n * NOTE: There is a proposal to eliminate this special case, here:\n * https://github.com/solana-labs/solana/issues/18892\n */\n this._subscriptionsAutoDisposedByRpc.delete(serverSubscriptionId);\n } else {\n this._setSubscription(hash, {\n ...subscription,\n state: 'unsubscribing'\n });\n this._setSubscription(hash, {\n ...subscription,\n state: 'unsubscribing'\n });\n try {\n await this._rpcWebSocket.call(unsubscribeMethod, [serverSubscriptionId]);\n } catch (e) {\n if (e instanceof Error) {\n console.error(`${unsubscribeMethod} error:`, e.message);\n }\n if (!isCurrentConnectionStillActive()) {\n return;\n }\n // TODO: Maybe add an 'errored' state or a retry limit?\n this._setSubscription(hash, {\n ...subscription,\n state: 'subscribed'\n });\n await this._updateSubscriptions();\n return;\n }\n }\n this._setSubscription(hash, {\n ...subscription,\n state: 'unsubscribed'\n });\n await this._updateSubscriptions();\n })();\n }\n break;\n }\n }));\n }\n\n /**\n * @internal\n */\n _handleServerNotification(serverSubscriptionId, callbackArgs) {\n const callbacks = this._subscriptionCallbacksByServerSubscriptionId[serverSubscriptionId];\n if (callbacks === undefined) {\n return;\n }\n callbacks.forEach(cb => {\n try {\n cb(\n // I failed to find a way to convince TypeScript that `cb` is of type\n // `TCallback` which is certainly compatible with `Parameters`.\n // See https://github.com/microsoft/TypeScript/issues/47615\n // @ts-ignore\n ...callbackArgs);\n } catch (e) {\n console.error(e);\n }\n });\n }\n\n /**\n * @internal\n */\n _wsOnAccountNotification(notification) {\n const {\n result,\n subscription\n } = create(notification, AccountNotificationResult);\n this._handleServerNotification(subscription, [result.value, result.context]);\n }\n\n /**\n * @internal\n */\n _makeSubscription(subscriptionConfig,\n /**\n * When preparing `args` for a call to `_makeSubscription`, be sure\n * to carefully apply a default `commitment` property, if necessary.\n *\n * - If the user supplied a `commitment` use that.\n * - Otherwise, if the `Connection::commitment` is set, use that.\n * - Otherwise, set it to the RPC server default: `finalized`.\n *\n * This is extremely important to ensure that these two fundamentally\n * identical subscriptions produce the same identifying hash:\n *\n * - A subscription made without specifying a commitment.\n * - A subscription made where the commitment specified is the same\n * as the default applied to the subscription above.\n *\n * Example; these two subscriptions must produce the same hash:\n *\n * - An `accountSubscribe` subscription for `'PUBKEY'`\n * - An `accountSubscribe` subscription for `'PUBKEY'` with commitment\n * `'finalized'`.\n *\n * See the 'making a subscription with defaulted params omitted' test\n * in `connection-subscriptions.ts` for more.\n */\n args) {\n const clientSubscriptionId = this._nextClientSubscriptionId++;\n const hash = fastStableStringify$1([subscriptionConfig.method, args]);\n const existingSubscription = this._subscriptionsByHash[hash];\n if (existingSubscription === undefined) {\n this._subscriptionsByHash[hash] = {\n ...subscriptionConfig,\n args,\n callbacks: new Set([subscriptionConfig.callback]),\n state: 'pending'\n };\n } else {\n existingSubscription.callbacks.add(subscriptionConfig.callback);\n }\n this._subscriptionHashByClientSubscriptionId[clientSubscriptionId] = hash;\n this._subscriptionDisposeFunctionsByClientSubscriptionId[clientSubscriptionId] = async () => {\n delete this._subscriptionDisposeFunctionsByClientSubscriptionId[clientSubscriptionId];\n delete this._subscriptionHashByClientSubscriptionId[clientSubscriptionId];\n const subscription = this._subscriptionsByHash[hash];\n assert(subscription !== undefined, `Could not find a \\`Subscription\\` when tearing down client subscription #${clientSubscriptionId}`);\n subscription.callbacks.delete(subscriptionConfig.callback);\n await this._updateSubscriptions();\n };\n this._updateSubscriptions();\n return clientSubscriptionId;\n }\n\n /**\n * Register a callback to be invoked whenever the specified account changes\n *\n * @param publicKey Public key of the account to monitor\n * @param callback Function to invoke whenever the account is changed\n * @param commitment Specify the commitment level account changes must reach before notification\n * @return subscription id\n */\n onAccountChange(publicKey, callback, commitment) {\n const args = this._buildArgs([publicKey.toBase58()], commitment || this._commitment || 'finalized',\n // Apply connection/server default.\n 'base64');\n return this._makeSubscription({\n callback,\n method: 'accountSubscribe',\n unsubscribeMethod: 'accountUnsubscribe'\n }, args);\n }\n\n /**\n * Deregister an account notification callback\n *\n * @param clientSubscriptionId client subscription id to deregister\n */\n async removeAccountChangeListener(clientSubscriptionId) {\n await this._unsubscribeClientSubscription(clientSubscriptionId, 'account change');\n }\n\n /**\n * @internal\n */\n _wsOnProgramAccountNotification(notification) {\n const {\n result,\n subscription\n } = create(notification, ProgramAccountNotificationResult);\n this._handleServerNotification(subscription, [{\n accountId: result.value.pubkey,\n accountInfo: result.value.account\n }, result.context]);\n }\n\n /**\n * Register a callback to be invoked whenever accounts owned by the\n * specified program change\n *\n * @param programId Public key of the program to monitor\n * @param callback Function to invoke whenever the account is changed\n * @param commitment Specify the commitment level account changes must reach before notification\n * @param filters The program account filters to pass into the RPC method\n * @return subscription id\n */\n onProgramAccountChange(programId, callback, commitment, filters) {\n const args = this._buildArgs([programId.toBase58()], commitment || this._commitment || 'finalized',\n // Apply connection/server default.\n 'base64' /* encoding */, filters ? {\n filters: filters\n } : undefined /* extra */);\n return this._makeSubscription({\n callback,\n method: 'programSubscribe',\n unsubscribeMethod: 'programUnsubscribe'\n }, args);\n }\n\n /**\n * Deregister an account notification callback\n *\n * @param clientSubscriptionId client subscription id to deregister\n */\n async removeProgramAccountChangeListener(clientSubscriptionId) {\n await this._unsubscribeClientSubscription(clientSubscriptionId, 'program account change');\n }\n\n /**\n * Registers a callback to be invoked whenever logs are emitted.\n */\n onLogs(filter, callback, commitment) {\n const args = this._buildArgs([typeof filter === 'object' ? {\n mentions: [filter.toString()]\n } : filter], commitment || this._commitment || 'finalized' // Apply connection/server default.\n );\n return this._makeSubscription({\n callback,\n method: 'logsSubscribe',\n unsubscribeMethod: 'logsUnsubscribe'\n }, args);\n }\n\n /**\n * Deregister a logs callback.\n *\n * @param clientSubscriptionId client subscription id to deregister.\n */\n async removeOnLogsListener(clientSubscriptionId) {\n await this._unsubscribeClientSubscription(clientSubscriptionId, 'logs');\n }\n\n /**\n * @internal\n */\n _wsOnLogsNotification(notification) {\n const {\n result,\n subscription\n } = create(notification, LogsNotificationResult);\n this._handleServerNotification(subscription, [result.value, result.context]);\n }\n\n /**\n * @internal\n */\n _wsOnSlotNotification(notification) {\n const {\n result,\n subscription\n } = create(notification, SlotNotificationResult);\n this._handleServerNotification(subscription, [result]);\n }\n\n /**\n * Register a callback to be invoked upon slot changes\n *\n * @param callback Function to invoke whenever the slot changes\n * @return subscription id\n */\n onSlotChange(callback) {\n return this._makeSubscription({\n callback,\n method: 'slotSubscribe',\n unsubscribeMethod: 'slotUnsubscribe'\n }, [] /* args */);\n }\n\n /**\n * Deregister a slot notification callback\n *\n * @param clientSubscriptionId client subscription id to deregister\n */\n async removeSlotChangeListener(clientSubscriptionId) {\n await this._unsubscribeClientSubscription(clientSubscriptionId, 'slot change');\n }\n\n /**\n * @internal\n */\n _wsOnSlotUpdatesNotification(notification) {\n const {\n result,\n subscription\n } = create(notification, SlotUpdateNotificationResult);\n this._handleServerNotification(subscription, [result]);\n }\n\n /**\n * Register a callback to be invoked upon slot updates. {@link SlotUpdate}'s\n * may be useful to track live progress of a cluster.\n *\n * @param callback Function to invoke whenever the slot updates\n * @return subscription id\n */\n onSlotUpdate(callback) {\n return this._makeSubscription({\n callback,\n method: 'slotsUpdatesSubscribe',\n unsubscribeMethod: 'slotsUpdatesUnsubscribe'\n }, [] /* args */);\n }\n\n /**\n * Deregister a slot update notification callback\n *\n * @param clientSubscriptionId client subscription id to deregister\n */\n async removeSlotUpdateListener(clientSubscriptionId) {\n await this._unsubscribeClientSubscription(clientSubscriptionId, 'slot update');\n }\n\n /**\n * @internal\n */\n\n async _unsubscribeClientSubscription(clientSubscriptionId, subscriptionName) {\n const dispose = this._subscriptionDisposeFunctionsByClientSubscriptionId[clientSubscriptionId];\n if (dispose) {\n await dispose();\n } else {\n console.warn('Ignored unsubscribe request because an active subscription with id ' + `\\`${clientSubscriptionId}\\` for '${subscriptionName}' events ` + 'could not be found.');\n }\n }\n _buildArgs(args, override, encoding, extra) {\n const commitment = override || this._commitment;\n if (commitment || encoding || extra) {\n let options = {};\n if (encoding) {\n options.encoding = encoding;\n }\n if (commitment) {\n options.commitment = commitment;\n }\n if (extra) {\n options = Object.assign(options, extra);\n }\n args.push(options);\n }\n return args;\n }\n\n /**\n * @internal\n */\n _buildArgsAtLeastConfirmed(args, override, encoding, extra) {\n const commitment = override || this._commitment;\n if (commitment && !['confirmed', 'finalized'].includes(commitment)) {\n throw new Error('Using Connection with default commitment: `' + this._commitment + '`, but method requires at least `confirmed`');\n }\n return this._buildArgs(args, override, encoding, extra);\n }\n\n /**\n * @internal\n */\n _wsOnSignatureNotification(notification) {\n const {\n result,\n subscription\n } = create(notification, SignatureNotificationResult);\n if (result.value !== 'receivedSignature') {\n /**\n * Special case.\n * After a signature is processed, RPCs automatically dispose of the\n * subscription on the server side. We need to track which of these\n * subscriptions have been disposed in such a way, so that we know\n * whether the client is dealing with a not-yet-processed signature\n * (in which case we must tear down the server subscription) or an\n * already-processed signature (in which case the client can simply\n * clear out the subscription locally without telling the server).\n *\n * NOTE: There is a proposal to eliminate this special case, here:\n * https://github.com/solana-labs/solana/issues/18892\n */\n this._subscriptionsAutoDisposedByRpc.add(subscription);\n }\n this._handleServerNotification(subscription, result.value === 'receivedSignature' ? [{\n type: 'received'\n }, result.context] : [{\n type: 'status',\n result: result.value\n }, result.context]);\n }\n\n /**\n * Register a callback to be invoked upon signature updates\n *\n * @param signature Transaction signature string in base 58\n * @param callback Function to invoke on signature notifications\n * @param commitment Specify the commitment level signature must reach before notification\n * @return subscription id\n */\n onSignature(signature, callback, commitment) {\n const args = this._buildArgs([signature], commitment || this._commitment || 'finalized' // Apply connection/server default.\n );\n const clientSubscriptionId = this._makeSubscription({\n callback: (notification, context) => {\n if (notification.type === 'status') {\n callback(notification.result, context);\n // Signatures subscriptions are auto-removed by the RPC service\n // so no need to explicitly send an unsubscribe message.\n try {\n this.removeSignatureListener(clientSubscriptionId);\n // eslint-disable-next-line no-empty\n } catch (_err) {\n // Already removed.\n }\n }\n },\n method: 'signatureSubscribe',\n unsubscribeMethod: 'signatureUnsubscribe'\n }, args);\n return clientSubscriptionId;\n }\n\n /**\n * Register a callback to be invoked when a transaction is\n * received and/or processed.\n *\n * @param signature Transaction signature string in base 58\n * @param callback Function to invoke on signature notifications\n * @param options Enable received notifications and set the commitment\n * level that signature must reach before notification\n * @return subscription id\n */\n onSignatureWithOptions(signature, callback, options) {\n const {\n commitment,\n ...extra\n } = {\n ...options,\n commitment: options && options.commitment || this._commitment || 'finalized' // Apply connection/server default.\n };\n const args = this._buildArgs([signature], commitment, undefined /* encoding */, extra);\n const clientSubscriptionId = this._makeSubscription({\n callback: (notification, context) => {\n callback(notification, context);\n // Signatures subscriptions are auto-removed by the RPC service\n // so no need to explicitly send an unsubscribe message.\n try {\n this.removeSignatureListener(clientSubscriptionId);\n // eslint-disable-next-line no-empty\n } catch (_err) {\n // Already removed.\n }\n },\n method: 'signatureSubscribe',\n unsubscribeMethod: 'signatureUnsubscribe'\n }, args);\n return clientSubscriptionId;\n }\n\n /**\n * Deregister a signature notification callback\n *\n * @param clientSubscriptionId client subscription id to deregister\n */\n async removeSignatureListener(clientSubscriptionId) {\n await this._unsubscribeClientSubscription(clientSubscriptionId, 'signature result');\n }\n\n /**\n * @internal\n */\n _wsOnRootNotification(notification) {\n const {\n result,\n subscription\n } = create(notification, RootNotificationResult);\n this._handleServerNotification(subscription, [result]);\n }\n\n /**\n * Register a callback to be invoked upon root changes\n *\n * @param callback Function to invoke whenever the root changes\n * @return subscription id\n */\n onRootChange(callback) {\n return this._makeSubscription({\n callback,\n method: 'rootSubscribe',\n unsubscribeMethod: 'rootUnsubscribe'\n }, [] /* args */);\n }\n\n /**\n * Deregister a root notification callback\n *\n * @param clientSubscriptionId client subscription id to deregister\n */\n async removeRootChangeListener(clientSubscriptionId) {\n await this._unsubscribeClientSubscription(clientSubscriptionId, 'root change');\n }\n}\n\n/**\n * Keypair signer interface\n */\n\n/**\n * An account keypair used for signing transactions.\n */\nclass Keypair {\n /**\n * Create a new keypair instance.\n * Generate random keypair if no {@link Ed25519Keypair} is provided.\n *\n * @param {Ed25519Keypair} keypair ed25519 keypair\n */\n constructor(keypair) {\n this._keypair = void 0;\n this._keypair = keypair ?? generateKeypair();\n }\n\n /**\n * Generate a new random keypair\n *\n * @returns {Keypair} Keypair\n */\n static generate() {\n return new Keypair(generateKeypair());\n }\n\n /**\n * Create a keypair from a raw secret key byte array.\n *\n * This method should only be used to recreate a keypair from a previously\n * generated secret key. Generating keypairs from a random seed should be done\n * with the {@link Keypair.fromSeed} method.\n *\n * @throws error if the provided secret key is invalid and validation is not skipped.\n *\n * @param secretKey secret key byte array\n * @param options skip secret key validation\n *\n * @returns {Keypair} Keypair\n */\n static fromSecretKey(secretKey, options) {\n if (secretKey.byteLength !== 64) {\n throw new Error('bad secret key size');\n }\n const publicKey = secretKey.slice(32, 64);\n if (!options || !options.skipValidation) {\n const privateScalar = secretKey.slice(0, 32);\n const computedPublicKey = getPublicKey(privateScalar);\n for (let ii = 0; ii < 32; ii++) {\n if (publicKey[ii] !== computedPublicKey[ii]) {\n throw new Error('provided secretKey is invalid');\n }\n }\n }\n return new Keypair({\n publicKey,\n secretKey\n });\n }\n\n /**\n * Generate a keypair from a 32 byte seed.\n *\n * @param seed seed byte array\n *\n * @returns {Keypair} Keypair\n */\n static fromSeed(seed) {\n const publicKey = getPublicKey(seed);\n const secretKey = new Uint8Array(64);\n secretKey.set(seed);\n secretKey.set(publicKey, 32);\n return new Keypair({\n publicKey,\n secretKey\n });\n }\n\n /**\n * The public key for this keypair\n *\n * @returns {PublicKey} PublicKey\n */\n get publicKey() {\n return new PublicKey(this._keypair.publicKey);\n }\n\n /**\n * The raw secret key for this keypair\n * @returns {Uint8Array} Secret key in an array of Uint8 bytes\n */\n get secretKey() {\n return new Uint8Array(this._keypair.secretKey);\n }\n}\n\n/**\n * An enumeration of valid LookupTableInstructionType's\n */\n\n/**\n * An enumeration of valid address lookup table InstructionType's\n * @internal\n */\nconst LOOKUP_TABLE_INSTRUCTION_LAYOUTS = Object.freeze({\n CreateLookupTable: {\n index: 0,\n layout: BufferLayout.struct([BufferLayout.u32('instruction'), u64('recentSlot'), BufferLayout.u8('bumpSeed')])\n },\n FreezeLookupTable: {\n index: 1,\n layout: BufferLayout.struct([BufferLayout.u32('instruction')])\n },\n ExtendLookupTable: {\n index: 2,\n layout: BufferLayout.struct([BufferLayout.u32('instruction'), u64(), BufferLayout.seq(publicKey(), BufferLayout.offset(BufferLayout.u32(), -8), 'addresses')])\n },\n DeactivateLookupTable: {\n index: 3,\n layout: BufferLayout.struct([BufferLayout.u32('instruction')])\n },\n CloseLookupTable: {\n index: 4,\n layout: BufferLayout.struct([BufferLayout.u32('instruction')])\n }\n});\nclass AddressLookupTableInstruction {\n /**\n * @internal\n */\n constructor() {}\n static decodeInstructionType(instruction) {\n this.checkProgramId(instruction.programId);\n const instructionTypeLayout = BufferLayout.u32('instruction');\n const index = instructionTypeLayout.decode(instruction.data);\n let type;\n for (const [layoutType, layout] of Object.entries(LOOKUP_TABLE_INSTRUCTION_LAYOUTS)) {\n if (layout.index == index) {\n type = layoutType;\n break;\n }\n }\n if (!type) {\n throw new Error('Invalid Instruction. Should be a LookupTable Instruction');\n }\n return type;\n }\n static decodeCreateLookupTable(instruction) {\n this.checkProgramId(instruction.programId);\n this.checkKeysLength(instruction.keys, 4);\n const {\n recentSlot\n } = decodeData$1(LOOKUP_TABLE_INSTRUCTION_LAYOUTS.CreateLookupTable, instruction.data);\n return {\n authority: instruction.keys[1].pubkey,\n payer: instruction.keys[2].pubkey,\n recentSlot: Number(recentSlot)\n };\n }\n static decodeExtendLookupTable(instruction) {\n this.checkProgramId(instruction.programId);\n if (instruction.keys.length < 2) {\n throw new Error(`invalid instruction; found ${instruction.keys.length} keys, expected at least 2`);\n }\n const {\n addresses\n } = decodeData$1(LOOKUP_TABLE_INSTRUCTION_LAYOUTS.ExtendLookupTable, instruction.data);\n return {\n lookupTable: instruction.keys[0].pubkey,\n authority: instruction.keys[1].pubkey,\n payer: instruction.keys.length > 2 ? instruction.keys[2].pubkey : undefined,\n addresses: addresses.map(buffer => new PublicKey(buffer))\n };\n }\n static decodeCloseLookupTable(instruction) {\n this.checkProgramId(instruction.programId);\n this.checkKeysLength(instruction.keys, 3);\n return {\n lookupTable: instruction.keys[0].pubkey,\n authority: instruction.keys[1].pubkey,\n recipient: instruction.keys[2].pubkey\n };\n }\n static decodeFreezeLookupTable(instruction) {\n this.checkProgramId(instruction.programId);\n this.checkKeysLength(instruction.keys, 2);\n return {\n lookupTable: instruction.keys[0].pubkey,\n authority: instruction.keys[1].pubkey\n };\n }\n static decodeDeactivateLookupTable(instruction) {\n this.checkProgramId(instruction.programId);\n this.checkKeysLength(instruction.keys, 2);\n return {\n lookupTable: instruction.keys[0].pubkey,\n authority: instruction.keys[1].pubkey\n };\n }\n\n /**\n * @internal\n */\n static checkProgramId(programId) {\n if (!programId.equals(AddressLookupTableProgram.programId)) {\n throw new Error('invalid instruction; programId is not AddressLookupTable Program');\n }\n }\n /**\n * @internal\n */\n static checkKeysLength(keys, expectedLength) {\n if (keys.length < expectedLength) {\n throw new Error(`invalid instruction; found ${keys.length} keys, expected at least ${expectedLength}`);\n }\n }\n}\nclass AddressLookupTableProgram {\n /**\n * @internal\n */\n constructor() {}\n static createLookupTable(params) {\n const [lookupTableAddress, bumpSeed] = PublicKey.findProgramAddressSync([params.authority.toBuffer(), toBufferLE(BigInt(params.recentSlot), 8)], this.programId);\n const type = LOOKUP_TABLE_INSTRUCTION_LAYOUTS.CreateLookupTable;\n const data = encodeData(type, {\n recentSlot: BigInt(params.recentSlot),\n bumpSeed: bumpSeed\n });\n const keys = [{\n pubkey: lookupTableAddress,\n isSigner: false,\n isWritable: true\n }, {\n pubkey: params.authority,\n isSigner: true,\n isWritable: false\n }, {\n pubkey: params.payer,\n isSigner: true,\n isWritable: true\n }, {\n pubkey: SystemProgram.programId,\n isSigner: false,\n isWritable: false\n }];\n return [new TransactionInstruction({\n programId: this.programId,\n keys: keys,\n data: data\n }), lookupTableAddress];\n }\n static freezeLookupTable(params) {\n const type = LOOKUP_TABLE_INSTRUCTION_LAYOUTS.FreezeLookupTable;\n const data = encodeData(type);\n const keys = [{\n pubkey: params.lookupTable,\n isSigner: false,\n isWritable: true\n }, {\n pubkey: params.authority,\n isSigner: true,\n isWritable: false\n }];\n return new TransactionInstruction({\n programId: this.programId,\n keys: keys,\n data: data\n });\n }\n static extendLookupTable(params) {\n const type = LOOKUP_TABLE_INSTRUCTION_LAYOUTS.ExtendLookupTable;\n const data = encodeData(type, {\n addresses: params.addresses.map(addr => addr.toBytes())\n });\n const keys = [{\n pubkey: params.lookupTable,\n isSigner: false,\n isWritable: true\n }, {\n pubkey: params.authority,\n isSigner: true,\n isWritable: false\n }];\n if (params.payer) {\n keys.push({\n pubkey: params.payer,\n isSigner: true,\n isWritable: true\n }, {\n pubkey: SystemProgram.programId,\n isSigner: false,\n isWritable: false\n });\n }\n return new TransactionInstruction({\n programId: this.programId,\n keys: keys,\n data: data\n });\n }\n static deactivateLookupTable(params) {\n const type = LOOKUP_TABLE_INSTRUCTION_LAYOUTS.DeactivateLookupTable;\n const data = encodeData(type);\n const keys = [{\n pubkey: params.lookupTable,\n isSigner: false,\n isWritable: true\n }, {\n pubkey: params.authority,\n isSigner: true,\n isWritable: false\n }];\n return new TransactionInstruction({\n programId: this.programId,\n keys: keys,\n data: data\n });\n }\n static closeLookupTable(params) {\n const type = LOOKUP_TABLE_INSTRUCTION_LAYOUTS.CloseLookupTable;\n const data = encodeData(type);\n const keys = [{\n pubkey: params.lookupTable,\n isSigner: false,\n isWritable: true\n }, {\n pubkey: params.authority,\n isSigner: true,\n isWritable: false\n }, {\n pubkey: params.recipient,\n isSigner: false,\n isWritable: true\n }];\n return new TransactionInstruction({\n programId: this.programId,\n keys: keys,\n data: data\n });\n }\n}\nAddressLookupTableProgram.programId = new PublicKey('AddressLookupTab1e1111111111111111111111111');\n\n/**\n * Compute Budget Instruction class\n */\nclass ComputeBudgetInstruction {\n /**\n * @internal\n */\n constructor() {}\n\n /**\n * Decode a compute budget instruction and retrieve the instruction type.\n */\n static decodeInstructionType(instruction) {\n this.checkProgramId(instruction.programId);\n const instructionTypeLayout = BufferLayout.u8('instruction');\n const typeIndex = instructionTypeLayout.decode(instruction.data);\n let type;\n for (const [ixType, layout] of Object.entries(COMPUTE_BUDGET_INSTRUCTION_LAYOUTS)) {\n if (layout.index == typeIndex) {\n type = ixType;\n break;\n }\n }\n if (!type) {\n throw new Error('Instruction type incorrect; not a ComputeBudgetInstruction');\n }\n return type;\n }\n\n /**\n * Decode request units compute budget instruction and retrieve the instruction params.\n */\n static decodeRequestUnits(instruction) {\n this.checkProgramId(instruction.programId);\n const {\n units,\n additionalFee\n } = decodeData$1(COMPUTE_BUDGET_INSTRUCTION_LAYOUTS.RequestUnits, instruction.data);\n return {\n units,\n additionalFee\n };\n }\n\n /**\n * Decode request heap frame compute budget instruction and retrieve the instruction params.\n */\n static decodeRequestHeapFrame(instruction) {\n this.checkProgramId(instruction.programId);\n const {\n bytes\n } = decodeData$1(COMPUTE_BUDGET_INSTRUCTION_LAYOUTS.RequestHeapFrame, instruction.data);\n return {\n bytes\n };\n }\n\n /**\n * Decode set compute unit limit compute budget instruction and retrieve the instruction params.\n */\n static decodeSetComputeUnitLimit(instruction) {\n this.checkProgramId(instruction.programId);\n const {\n units\n } = decodeData$1(COMPUTE_BUDGET_INSTRUCTION_LAYOUTS.SetComputeUnitLimit, instruction.data);\n return {\n units\n };\n }\n\n /**\n * Decode set compute unit price compute budget instruction and retrieve the instruction params.\n */\n static decodeSetComputeUnitPrice(instruction) {\n this.checkProgramId(instruction.programId);\n const {\n microLamports\n } = decodeData$1(COMPUTE_BUDGET_INSTRUCTION_LAYOUTS.SetComputeUnitPrice, instruction.data);\n return {\n microLamports\n };\n }\n\n /**\n * @internal\n */\n static checkProgramId(programId) {\n if (!programId.equals(ComputeBudgetProgram.programId)) {\n throw new Error('invalid instruction; programId is not ComputeBudgetProgram');\n }\n }\n}\n\n/**\n * An enumeration of valid ComputeBudgetInstructionType's\n */\n\n/**\n * Request units instruction params\n */\n\n/**\n * Request heap frame instruction params\n */\n\n/**\n * Set compute unit limit instruction params\n */\n\n/**\n * Set compute unit price instruction params\n */\n\n/**\n * An enumeration of valid ComputeBudget InstructionType's\n * @internal\n */\nconst COMPUTE_BUDGET_INSTRUCTION_LAYOUTS = Object.freeze({\n RequestUnits: {\n index: 0,\n layout: BufferLayout.struct([BufferLayout.u8('instruction'), BufferLayout.u32('units'), BufferLayout.u32('additionalFee')])\n },\n RequestHeapFrame: {\n index: 1,\n layout: BufferLayout.struct([BufferLayout.u8('instruction'), BufferLayout.u32('bytes')])\n },\n SetComputeUnitLimit: {\n index: 2,\n layout: BufferLayout.struct([BufferLayout.u8('instruction'), BufferLayout.u32('units')])\n },\n SetComputeUnitPrice: {\n index: 3,\n layout: BufferLayout.struct([BufferLayout.u8('instruction'), u64('microLamports')])\n }\n});\n\n/**\n * Factory class for transaction instructions to interact with the Compute Budget program\n */\nclass ComputeBudgetProgram {\n /**\n * @internal\n */\n constructor() {}\n\n /**\n * Public key that identifies the Compute Budget program\n */\n\n /**\n * @deprecated Instead, call {@link setComputeUnitLimit} and/or {@link setComputeUnitPrice}\n */\n static requestUnits(params) {\n const type = COMPUTE_BUDGET_INSTRUCTION_LAYOUTS.RequestUnits;\n const data = encodeData(type, params);\n return new TransactionInstruction({\n keys: [],\n programId: this.programId,\n data\n });\n }\n static requestHeapFrame(params) {\n const type = COMPUTE_BUDGET_INSTRUCTION_LAYOUTS.RequestHeapFrame;\n const data = encodeData(type, params);\n return new TransactionInstruction({\n keys: [],\n programId: this.programId,\n data\n });\n }\n static setComputeUnitLimit(params) {\n const type = COMPUTE_BUDGET_INSTRUCTION_LAYOUTS.SetComputeUnitLimit;\n const data = encodeData(type, params);\n return new TransactionInstruction({\n keys: [],\n programId: this.programId,\n data\n });\n }\n static setComputeUnitPrice(params) {\n const type = COMPUTE_BUDGET_INSTRUCTION_LAYOUTS.SetComputeUnitPrice;\n const data = encodeData(type, {\n microLamports: BigInt(params.microLamports)\n });\n return new TransactionInstruction({\n keys: [],\n programId: this.programId,\n data\n });\n }\n}\nComputeBudgetProgram.programId = new PublicKey('ComputeBudget111111111111111111111111111111');\n\nconst PRIVATE_KEY_BYTES$1 = 64;\nconst PUBLIC_KEY_BYTES$1 = 32;\nconst SIGNATURE_BYTES = 64;\n\n/**\n * Params for creating an ed25519 instruction using a public key\n */\n\n/**\n * Params for creating an ed25519 instruction using a private key\n */\n\nconst ED25519_INSTRUCTION_LAYOUT = BufferLayout.struct([BufferLayout.u8('numSignatures'), BufferLayout.u8('padding'), BufferLayout.u16('signatureOffset'), BufferLayout.u16('signatureInstructionIndex'), BufferLayout.u16('publicKeyOffset'), BufferLayout.u16('publicKeyInstructionIndex'), BufferLayout.u16('messageDataOffset'), BufferLayout.u16('messageDataSize'), BufferLayout.u16('messageInstructionIndex')]);\nclass Ed25519Program {\n /**\n * @internal\n */\n constructor() {}\n\n /**\n * Public key that identifies the ed25519 program\n */\n\n /**\n * Create an ed25519 instruction with a public key and signature. The\n * public key must be a buffer that is 32 bytes long, and the signature\n * must be a buffer of 64 bytes.\n */\n static createInstructionWithPublicKey(params) {\n const {\n publicKey,\n message,\n signature,\n instructionIndex\n } = params;\n assert(publicKey.length === PUBLIC_KEY_BYTES$1, `Public Key must be ${PUBLIC_KEY_BYTES$1} bytes but received ${publicKey.length} bytes`);\n assert(signature.length === SIGNATURE_BYTES, `Signature must be ${SIGNATURE_BYTES} bytes but received ${signature.length} bytes`);\n const publicKeyOffset = ED25519_INSTRUCTION_LAYOUT.span;\n const signatureOffset = publicKeyOffset + publicKey.length;\n const messageDataOffset = signatureOffset + signature.length;\n const numSignatures = 1;\n const instructionData = Buffer.alloc(messageDataOffset + message.length);\n const index = instructionIndex == null ? 0xffff // An index of `u16::MAX` makes it default to the current instruction.\n : instructionIndex;\n ED25519_INSTRUCTION_LAYOUT.encode({\n numSignatures,\n padding: 0,\n signatureOffset,\n signatureInstructionIndex: index,\n publicKeyOffset,\n publicKeyInstructionIndex: index,\n messageDataOffset,\n messageDataSize: message.length,\n messageInstructionIndex: index\n }, instructionData);\n instructionData.fill(publicKey, publicKeyOffset);\n instructionData.fill(signature, signatureOffset);\n instructionData.fill(message, messageDataOffset);\n return new TransactionInstruction({\n keys: [],\n programId: Ed25519Program.programId,\n data: instructionData\n });\n }\n\n /**\n * Create an ed25519 instruction with a private key. The private key\n * must be a buffer that is 64 bytes long.\n */\n static createInstructionWithPrivateKey(params) {\n const {\n privateKey,\n message,\n instructionIndex\n } = params;\n assert(privateKey.length === PRIVATE_KEY_BYTES$1, `Private key must be ${PRIVATE_KEY_BYTES$1} bytes but received ${privateKey.length} bytes`);\n try {\n const keypair = Keypair.fromSecretKey(privateKey);\n const publicKey = keypair.publicKey.toBytes();\n const signature = sign(message, keypair.secretKey);\n return this.createInstructionWithPublicKey({\n publicKey,\n message,\n signature,\n instructionIndex\n });\n } catch (error) {\n throw new Error(`Error creating instruction; ${error}`);\n }\n }\n}\nEd25519Program.programId = new PublicKey('Ed25519SigVerify111111111111111111111111111');\n\nconst ecdsaSign = (msgHash, privKey) => {\n const signature = secp256k1.sign(msgHash, privKey);\n return [signature.toCompactRawBytes(), signature.recovery];\n};\nsecp256k1.utils.isValidPrivateKey;\nconst publicKeyCreate = secp256k1.getPublicKey;\n\nconst PRIVATE_KEY_BYTES = 32;\nconst ETHEREUM_ADDRESS_BYTES = 20;\nconst PUBLIC_KEY_BYTES = 64;\nconst SIGNATURE_OFFSETS_SERIALIZED_SIZE = 11;\n\n/**\n * Params for creating an secp256k1 instruction using a public key\n */\n\n/**\n * Params for creating an secp256k1 instruction using an Ethereum address\n */\n\n/**\n * Params for creating an secp256k1 instruction using a private key\n */\n\nconst SECP256K1_INSTRUCTION_LAYOUT = BufferLayout.struct([BufferLayout.u8('numSignatures'), BufferLayout.u16('signatureOffset'), BufferLayout.u8('signatureInstructionIndex'), BufferLayout.u16('ethAddressOffset'), BufferLayout.u8('ethAddressInstructionIndex'), BufferLayout.u16('messageDataOffset'), BufferLayout.u16('messageDataSize'), BufferLayout.u8('messageInstructionIndex'), BufferLayout.blob(20, 'ethAddress'), BufferLayout.blob(64, 'signature'), BufferLayout.u8('recoveryId')]);\nclass Secp256k1Program {\n /**\n * @internal\n */\n constructor() {}\n\n /**\n * Public key that identifies the secp256k1 program\n */\n\n /**\n * Construct an Ethereum address from a secp256k1 public key buffer.\n * @param {Buffer} publicKey a 64 byte secp256k1 public key buffer\n */\n static publicKeyToEthAddress(publicKey) {\n assert(publicKey.length === PUBLIC_KEY_BYTES, `Public key must be ${PUBLIC_KEY_BYTES} bytes but received ${publicKey.length} bytes`);\n try {\n return Buffer.from(keccak_256(toBuffer(publicKey))).slice(-ETHEREUM_ADDRESS_BYTES);\n } catch (error) {\n throw new Error(`Error constructing Ethereum address: ${error}`);\n }\n }\n\n /**\n * Create an secp256k1 instruction with a public key. The public key\n * must be a buffer that is 64 bytes long.\n */\n static createInstructionWithPublicKey(params) {\n const {\n publicKey,\n message,\n signature,\n recoveryId,\n instructionIndex\n } = params;\n return Secp256k1Program.createInstructionWithEthAddress({\n ethAddress: Secp256k1Program.publicKeyToEthAddress(publicKey),\n message,\n signature,\n recoveryId,\n instructionIndex\n });\n }\n\n /**\n * Create an secp256k1 instruction with an Ethereum address. The address\n * must be a hex string or a buffer that is 20 bytes long.\n */\n static createInstructionWithEthAddress(params) {\n const {\n ethAddress: rawAddress,\n message,\n signature,\n recoveryId,\n instructionIndex = 0\n } = params;\n let ethAddress;\n if (typeof rawAddress === 'string') {\n if (rawAddress.startsWith('0x')) {\n ethAddress = Buffer.from(rawAddress.substr(2), 'hex');\n } else {\n ethAddress = Buffer.from(rawAddress, 'hex');\n }\n } else {\n ethAddress = rawAddress;\n }\n assert(ethAddress.length === ETHEREUM_ADDRESS_BYTES, `Address must be ${ETHEREUM_ADDRESS_BYTES} bytes but received ${ethAddress.length} bytes`);\n const dataStart = 1 + SIGNATURE_OFFSETS_SERIALIZED_SIZE;\n const ethAddressOffset = dataStart;\n const signatureOffset = dataStart + ethAddress.length;\n const messageDataOffset = signatureOffset + signature.length + 1;\n const numSignatures = 1;\n const instructionData = Buffer.alloc(SECP256K1_INSTRUCTION_LAYOUT.span + message.length);\n SECP256K1_INSTRUCTION_LAYOUT.encode({\n numSignatures,\n signatureOffset,\n signatureInstructionIndex: instructionIndex,\n ethAddressOffset,\n ethAddressInstructionIndex: instructionIndex,\n messageDataOffset,\n messageDataSize: message.length,\n messageInstructionIndex: instructionIndex,\n signature: toBuffer(signature),\n ethAddress: toBuffer(ethAddress),\n recoveryId\n }, instructionData);\n instructionData.fill(toBuffer(message), SECP256K1_INSTRUCTION_LAYOUT.span);\n return new TransactionInstruction({\n keys: [],\n programId: Secp256k1Program.programId,\n data: instructionData\n });\n }\n\n /**\n * Create an secp256k1 instruction with a private key. The private key\n * must be a buffer that is 32 bytes long.\n */\n static createInstructionWithPrivateKey(params) {\n const {\n privateKey: pkey,\n message,\n instructionIndex\n } = params;\n assert(pkey.length === PRIVATE_KEY_BYTES, `Private key must be ${PRIVATE_KEY_BYTES} bytes but received ${pkey.length} bytes`);\n try {\n const privateKey = toBuffer(pkey);\n const publicKey = publicKeyCreate(privateKey, false /* isCompressed */).slice(1); // throw away leading byte\n const messageHash = Buffer.from(keccak_256(toBuffer(message)));\n const [signature, recoveryId] = ecdsaSign(messageHash, privateKey);\n return this.createInstructionWithPublicKey({\n publicKey,\n message,\n signature,\n recoveryId,\n instructionIndex\n });\n } catch (error) {\n throw new Error(`Error creating instruction; ${error}`);\n }\n }\n}\nSecp256k1Program.programId = new PublicKey('KeccakSecp256k11111111111111111111111111111');\n\nvar _class2;\n\n/**\n * Address of the stake config account which configures the rate\n * of stake warmup and cooldown as well as the slashing penalty.\n */\nconst STAKE_CONFIG_ID = new PublicKey('StakeConfig11111111111111111111111111111111');\n\n/**\n * Stake account authority info\n */\nclass Authorized {\n /**\n * Create a new Authorized object\n * @param staker the stake authority\n * @param withdrawer the withdraw authority\n */\n constructor(staker, withdrawer) {\n /** stake authority */\n this.staker = void 0;\n /** withdraw authority */\n this.withdrawer = void 0;\n this.staker = staker;\n this.withdrawer = withdrawer;\n }\n}\n/**\n * Stake account lockup info\n */\nclass Lockup {\n /**\n * Create a new Lockup object\n */\n constructor(unixTimestamp, epoch, custodian) {\n /** Unix timestamp of lockup expiration */\n this.unixTimestamp = void 0;\n /** Epoch of lockup expiration */\n this.epoch = void 0;\n /** Lockup custodian authority */\n this.custodian = void 0;\n this.unixTimestamp = unixTimestamp;\n this.epoch = epoch;\n this.custodian = custodian;\n }\n\n /**\n * Default, inactive Lockup value\n */\n}\n_class2 = Lockup;\nLockup.default = new _class2(0, 0, PublicKey.default);\n/**\n * Create stake account transaction params\n */\n/**\n * Create stake account with seed transaction params\n */\n/**\n * Initialize stake instruction params\n */\n/**\n * Delegate stake instruction params\n */\n/**\n * Authorize stake instruction params\n */\n/**\n * Authorize stake instruction params using a derived key\n */\n/**\n * Split stake instruction params\n */\n/**\n * Split with seed transaction params\n */\n/**\n * Withdraw stake instruction params\n */\n/**\n * Deactivate stake instruction params\n */\n/**\n * Merge stake instruction params\n */\n/**\n * Stake Instruction class\n */\nclass StakeInstruction {\n /**\n * @internal\n */\n constructor() {}\n\n /**\n * Decode a stake instruction and retrieve the instruction type.\n */\n static decodeInstructionType(instruction) {\n this.checkProgramId(instruction.programId);\n const instructionTypeLayout = BufferLayout.u32('instruction');\n const typeIndex = instructionTypeLayout.decode(instruction.data);\n let type;\n for (const [ixType, layout] of Object.entries(STAKE_INSTRUCTION_LAYOUTS)) {\n if (layout.index == typeIndex) {\n type = ixType;\n break;\n }\n }\n if (!type) {\n throw new Error('Instruction type incorrect; not a StakeInstruction');\n }\n return type;\n }\n\n /**\n * Decode a initialize stake instruction and retrieve the instruction params.\n */\n static decodeInitialize(instruction) {\n this.checkProgramId(instruction.programId);\n this.checkKeyLength(instruction.keys, 2);\n const {\n authorized,\n lockup\n } = decodeData$1(STAKE_INSTRUCTION_LAYOUTS.Initialize, instruction.data);\n return {\n stakePubkey: instruction.keys[0].pubkey,\n authorized: new Authorized(new PublicKey(authorized.staker), new PublicKey(authorized.withdrawer)),\n lockup: new Lockup(lockup.unixTimestamp, lockup.epoch, new PublicKey(lockup.custodian))\n };\n }\n\n /**\n * Decode a delegate stake instruction and retrieve the instruction params.\n */\n static decodeDelegate(instruction) {\n this.checkProgramId(instruction.programId);\n this.checkKeyLength(instruction.keys, 6);\n decodeData$1(STAKE_INSTRUCTION_LAYOUTS.Delegate, instruction.data);\n return {\n stakePubkey: instruction.keys[0].pubkey,\n votePubkey: instruction.keys[1].pubkey,\n authorizedPubkey: instruction.keys[5].pubkey\n };\n }\n\n /**\n * Decode an authorize stake instruction and retrieve the instruction params.\n */\n static decodeAuthorize(instruction) {\n this.checkProgramId(instruction.programId);\n this.checkKeyLength(instruction.keys, 3);\n const {\n newAuthorized,\n stakeAuthorizationType\n } = decodeData$1(STAKE_INSTRUCTION_LAYOUTS.Authorize, instruction.data);\n const o = {\n stakePubkey: instruction.keys[0].pubkey,\n authorizedPubkey: instruction.keys[2].pubkey,\n newAuthorizedPubkey: new PublicKey(newAuthorized),\n stakeAuthorizationType: {\n index: stakeAuthorizationType\n }\n };\n if (instruction.keys.length > 3) {\n o.custodianPubkey = instruction.keys[3].pubkey;\n }\n return o;\n }\n\n /**\n * Decode an authorize-with-seed stake instruction and retrieve the instruction params.\n */\n static decodeAuthorizeWithSeed(instruction) {\n this.checkProgramId(instruction.programId);\n this.checkKeyLength(instruction.keys, 2);\n const {\n newAuthorized,\n stakeAuthorizationType,\n authoritySeed,\n authorityOwner\n } = decodeData$1(STAKE_INSTRUCTION_LAYOUTS.AuthorizeWithSeed, instruction.data);\n const o = {\n stakePubkey: instruction.keys[0].pubkey,\n authorityBase: instruction.keys[1].pubkey,\n authoritySeed: authoritySeed,\n authorityOwner: new PublicKey(authorityOwner),\n newAuthorizedPubkey: new PublicKey(newAuthorized),\n stakeAuthorizationType: {\n index: stakeAuthorizationType\n }\n };\n if (instruction.keys.length > 3) {\n o.custodianPubkey = instruction.keys[3].pubkey;\n }\n return o;\n }\n\n /**\n * Decode a split stake instruction and retrieve the instruction params.\n */\n static decodeSplit(instruction) {\n this.checkProgramId(instruction.programId);\n this.checkKeyLength(instruction.keys, 3);\n const {\n lamports\n } = decodeData$1(STAKE_INSTRUCTION_LAYOUTS.Split, instruction.data);\n return {\n stakePubkey: instruction.keys[0].pubkey,\n splitStakePubkey: instruction.keys[1].pubkey,\n authorizedPubkey: instruction.keys[2].pubkey,\n lamports\n };\n }\n\n /**\n * Decode a merge stake instruction and retrieve the instruction params.\n */\n static decodeMerge(instruction) {\n this.checkProgramId(instruction.programId);\n this.checkKeyLength(instruction.keys, 3);\n decodeData$1(STAKE_INSTRUCTION_LAYOUTS.Merge, instruction.data);\n return {\n stakePubkey: instruction.keys[0].pubkey,\n sourceStakePubKey: instruction.keys[1].pubkey,\n authorizedPubkey: instruction.keys[4].pubkey\n };\n }\n\n /**\n * Decode a withdraw stake instruction and retrieve the instruction params.\n */\n static decodeWithdraw(instruction) {\n this.checkProgramId(instruction.programId);\n this.checkKeyLength(instruction.keys, 5);\n const {\n lamports\n } = decodeData$1(STAKE_INSTRUCTION_LAYOUTS.Withdraw, instruction.data);\n const o = {\n stakePubkey: instruction.keys[0].pubkey,\n toPubkey: instruction.keys[1].pubkey,\n authorizedPubkey: instruction.keys[4].pubkey,\n lamports\n };\n if (instruction.keys.length > 5) {\n o.custodianPubkey = instruction.keys[5].pubkey;\n }\n return o;\n }\n\n /**\n * Decode a deactivate stake instruction and retrieve the instruction params.\n */\n static decodeDeactivate(instruction) {\n this.checkProgramId(instruction.programId);\n this.checkKeyLength(instruction.keys, 3);\n decodeData$1(STAKE_INSTRUCTION_LAYOUTS.Deactivate, instruction.data);\n return {\n stakePubkey: instruction.keys[0].pubkey,\n authorizedPubkey: instruction.keys[2].pubkey\n };\n }\n\n /**\n * @internal\n */\n static checkProgramId(programId) {\n if (!programId.equals(StakeProgram.programId)) {\n throw new Error('invalid instruction; programId is not StakeProgram');\n }\n }\n\n /**\n * @internal\n */\n static checkKeyLength(keys, expectedLength) {\n if (keys.length < expectedLength) {\n throw new Error(`invalid instruction; found ${keys.length} keys, expected at least ${expectedLength}`);\n }\n }\n}\n\n/**\n * An enumeration of valid StakeInstructionType's\n */\n\n/**\n * An enumeration of valid stake InstructionType's\n * @internal\n */\nconst STAKE_INSTRUCTION_LAYOUTS = Object.freeze({\n Initialize: {\n index: 0,\n layout: BufferLayout.struct([BufferLayout.u32('instruction'), authorized(), lockup()])\n },\n Authorize: {\n index: 1,\n layout: BufferLayout.struct([BufferLayout.u32('instruction'), publicKey('newAuthorized'), BufferLayout.u32('stakeAuthorizationType')])\n },\n Delegate: {\n index: 2,\n layout: BufferLayout.struct([BufferLayout.u32('instruction')])\n },\n Split: {\n index: 3,\n layout: BufferLayout.struct([BufferLayout.u32('instruction'), BufferLayout.ns64('lamports')])\n },\n Withdraw: {\n index: 4,\n layout: BufferLayout.struct([BufferLayout.u32('instruction'), BufferLayout.ns64('lamports')])\n },\n Deactivate: {\n index: 5,\n layout: BufferLayout.struct([BufferLayout.u32('instruction')])\n },\n Merge: {\n index: 7,\n layout: BufferLayout.struct([BufferLayout.u32('instruction')])\n },\n AuthorizeWithSeed: {\n index: 8,\n layout: BufferLayout.struct([BufferLayout.u32('instruction'), publicKey('newAuthorized'), BufferLayout.u32('stakeAuthorizationType'), rustString('authoritySeed'), publicKey('authorityOwner')])\n }\n});\n\n/**\n * Stake authorization type\n */\n\n/**\n * An enumeration of valid StakeAuthorizationLayout's\n */\nconst StakeAuthorizationLayout = Object.freeze({\n Staker: {\n index: 0\n },\n Withdrawer: {\n index: 1\n }\n});\n\n/**\n * Factory class for transactions to interact with the Stake program\n */\nclass StakeProgram {\n /**\n * @internal\n */\n constructor() {}\n\n /**\n * Public key that identifies the Stake program\n */\n\n /**\n * Generate an Initialize instruction to add to a Stake Create transaction\n */\n static initialize(params) {\n const {\n stakePubkey,\n authorized,\n lockup: maybeLockup\n } = params;\n const lockup = maybeLockup || Lockup.default;\n const type = STAKE_INSTRUCTION_LAYOUTS.Initialize;\n const data = encodeData(type, {\n authorized: {\n staker: toBuffer(authorized.staker.toBuffer()),\n withdrawer: toBuffer(authorized.withdrawer.toBuffer())\n },\n lockup: {\n unixTimestamp: lockup.unixTimestamp,\n epoch: lockup.epoch,\n custodian: toBuffer(lockup.custodian.toBuffer())\n }\n });\n const instructionData = {\n keys: [{\n pubkey: stakePubkey,\n isSigner: false,\n isWritable: true\n }, {\n pubkey: SYSVAR_RENT_PUBKEY,\n isSigner: false,\n isWritable: false\n }],\n programId: this.programId,\n data\n };\n return new TransactionInstruction(instructionData);\n }\n\n /**\n * Generate a Transaction that creates a new Stake account at\n * an address generated with `from`, a seed, and the Stake programId\n */\n static createAccountWithSeed(params) {\n const transaction = new Transaction();\n transaction.add(SystemProgram.createAccountWithSeed({\n fromPubkey: params.fromPubkey,\n newAccountPubkey: params.stakePubkey,\n basePubkey: params.basePubkey,\n seed: params.seed,\n lamports: params.lamports,\n space: this.space,\n programId: this.programId\n }));\n const {\n stakePubkey,\n authorized,\n lockup\n } = params;\n return transaction.add(this.initialize({\n stakePubkey,\n authorized,\n lockup\n }));\n }\n\n /**\n * Generate a Transaction that creates a new Stake account\n */\n static createAccount(params) {\n const transaction = new Transaction();\n transaction.add(SystemProgram.createAccount({\n fromPubkey: params.fromPubkey,\n newAccountPubkey: params.stakePubkey,\n lamports: params.lamports,\n space: this.space,\n programId: this.programId\n }));\n const {\n stakePubkey,\n authorized,\n lockup\n } = params;\n return transaction.add(this.initialize({\n stakePubkey,\n authorized,\n lockup\n }));\n }\n\n /**\n * Generate a Transaction that delegates Stake tokens to a validator\n * Vote PublicKey. This transaction can also be used to redelegate Stake\n * to a new validator Vote PublicKey.\n */\n static delegate(params) {\n const {\n stakePubkey,\n authorizedPubkey,\n votePubkey\n } = params;\n const type = STAKE_INSTRUCTION_LAYOUTS.Delegate;\n const data = encodeData(type);\n return new Transaction().add({\n keys: [{\n pubkey: stakePubkey,\n isSigner: false,\n isWritable: true\n }, {\n pubkey: votePubkey,\n isSigner: false,\n isWritable: false\n }, {\n pubkey: SYSVAR_CLOCK_PUBKEY,\n isSigner: false,\n isWritable: false\n }, {\n pubkey: SYSVAR_STAKE_HISTORY_PUBKEY,\n isSigner: false,\n isWritable: false\n }, {\n pubkey: STAKE_CONFIG_ID,\n isSigner: false,\n isWritable: false\n }, {\n pubkey: authorizedPubkey,\n isSigner: true,\n isWritable: false\n }],\n programId: this.programId,\n data\n });\n }\n\n /**\n * Generate a Transaction that authorizes a new PublicKey as Staker\n * or Withdrawer on the Stake account.\n */\n static authorize(params) {\n const {\n stakePubkey,\n authorizedPubkey,\n newAuthorizedPubkey,\n stakeAuthorizationType,\n custodianPubkey\n } = params;\n const type = STAKE_INSTRUCTION_LAYOUTS.Authorize;\n const data = encodeData(type, {\n newAuthorized: toBuffer(newAuthorizedPubkey.toBuffer()),\n stakeAuthorizationType: stakeAuthorizationType.index\n });\n const keys = [{\n pubkey: stakePubkey,\n isSigner: false,\n isWritable: true\n }, {\n pubkey: SYSVAR_CLOCK_PUBKEY,\n isSigner: false,\n isWritable: true\n }, {\n pubkey: authorizedPubkey,\n isSigner: true,\n isWritable: false\n }];\n if (custodianPubkey) {\n keys.push({\n pubkey: custodianPubkey,\n isSigner: true,\n isWritable: false\n });\n }\n return new Transaction().add({\n keys,\n programId: this.programId,\n data\n });\n }\n\n /**\n * Generate a Transaction that authorizes a new PublicKey as Staker\n * or Withdrawer on the Stake account.\n */\n static authorizeWithSeed(params) {\n const {\n stakePubkey,\n authorityBase,\n authoritySeed,\n authorityOwner,\n newAuthorizedPubkey,\n stakeAuthorizationType,\n custodianPubkey\n } = params;\n const type = STAKE_INSTRUCTION_LAYOUTS.AuthorizeWithSeed;\n const data = encodeData(type, {\n newAuthorized: toBuffer(newAuthorizedPubkey.toBuffer()),\n stakeAuthorizationType: stakeAuthorizationType.index,\n authoritySeed: authoritySeed,\n authorityOwner: toBuffer(authorityOwner.toBuffer())\n });\n const keys = [{\n pubkey: stakePubkey,\n isSigner: false,\n isWritable: true\n }, {\n pubkey: authorityBase,\n isSigner: true,\n isWritable: false\n }, {\n pubkey: SYSVAR_CLOCK_PUBKEY,\n isSigner: false,\n isWritable: false\n }];\n if (custodianPubkey) {\n keys.push({\n pubkey: custodianPubkey,\n isSigner: true,\n isWritable: false\n });\n }\n return new Transaction().add({\n keys,\n programId: this.programId,\n data\n });\n }\n\n /**\n * @internal\n */\n static splitInstruction(params) {\n const {\n stakePubkey,\n authorizedPubkey,\n splitStakePubkey,\n lamports\n } = params;\n const type = STAKE_INSTRUCTION_LAYOUTS.Split;\n const data = encodeData(type, {\n lamports\n });\n return new TransactionInstruction({\n keys: [{\n pubkey: stakePubkey,\n isSigner: false,\n isWritable: true\n }, {\n pubkey: splitStakePubkey,\n isSigner: false,\n isWritable: true\n }, {\n pubkey: authorizedPubkey,\n isSigner: true,\n isWritable: false\n }],\n programId: this.programId,\n data\n });\n }\n\n /**\n * Generate a Transaction that splits Stake tokens into another stake account\n */\n static split(params,\n // Compute the cost of allocating the new stake account in lamports\n rentExemptReserve) {\n const transaction = new Transaction();\n transaction.add(SystemProgram.createAccount({\n fromPubkey: params.authorizedPubkey,\n newAccountPubkey: params.splitStakePubkey,\n lamports: rentExemptReserve,\n space: this.space,\n programId: this.programId\n }));\n return transaction.add(this.splitInstruction(params));\n }\n\n /**\n * Generate a Transaction that splits Stake tokens into another account\n * derived from a base public key and seed\n */\n static splitWithSeed(params,\n // If this stake account is new, compute the cost of allocating it in lamports\n rentExemptReserve) {\n const {\n stakePubkey,\n authorizedPubkey,\n splitStakePubkey,\n basePubkey,\n seed,\n lamports\n } = params;\n const transaction = new Transaction();\n transaction.add(SystemProgram.allocate({\n accountPubkey: splitStakePubkey,\n basePubkey,\n seed,\n space: this.space,\n programId: this.programId\n }));\n if (rentExemptReserve && rentExemptReserve > 0) {\n transaction.add(SystemProgram.transfer({\n fromPubkey: params.authorizedPubkey,\n toPubkey: splitStakePubkey,\n lamports: rentExemptReserve\n }));\n }\n return transaction.add(this.splitInstruction({\n stakePubkey,\n authorizedPubkey,\n splitStakePubkey,\n lamports\n }));\n }\n\n /**\n * Generate a Transaction that merges Stake accounts.\n */\n static merge(params) {\n const {\n stakePubkey,\n sourceStakePubKey,\n authorizedPubkey\n } = params;\n const type = STAKE_INSTRUCTION_LAYOUTS.Merge;\n const data = encodeData(type);\n return new Transaction().add({\n keys: [{\n pubkey: stakePubkey,\n isSigner: false,\n isWritable: true\n }, {\n pubkey: sourceStakePubKey,\n isSigner: false,\n isWritable: true\n }, {\n pubkey: SYSVAR_CLOCK_PUBKEY,\n isSigner: false,\n isWritable: false\n }, {\n pubkey: SYSVAR_STAKE_HISTORY_PUBKEY,\n isSigner: false,\n isWritable: false\n }, {\n pubkey: authorizedPubkey,\n isSigner: true,\n isWritable: false\n }],\n programId: this.programId,\n data\n });\n }\n\n /**\n * Generate a Transaction that withdraws deactivated Stake tokens.\n */\n static withdraw(params) {\n const {\n stakePubkey,\n authorizedPubkey,\n toPubkey,\n lamports,\n custodianPubkey\n } = params;\n const type = STAKE_INSTRUCTION_LAYOUTS.Withdraw;\n const data = encodeData(type, {\n lamports\n });\n const keys = [{\n pubkey: stakePubkey,\n isSigner: false,\n isWritable: true\n }, {\n pubkey: toPubkey,\n isSigner: false,\n isWritable: true\n }, {\n pubkey: SYSVAR_CLOCK_PUBKEY,\n isSigner: false,\n isWritable: false\n }, {\n pubkey: SYSVAR_STAKE_HISTORY_PUBKEY,\n isSigner: false,\n isWritable: false\n }, {\n pubkey: authorizedPubkey,\n isSigner: true,\n isWritable: false\n }];\n if (custodianPubkey) {\n keys.push({\n pubkey: custodianPubkey,\n isSigner: true,\n isWritable: false\n });\n }\n return new Transaction().add({\n keys,\n programId: this.programId,\n data\n });\n }\n\n /**\n * Generate a Transaction that deactivates Stake tokens.\n */\n static deactivate(params) {\n const {\n stakePubkey,\n authorizedPubkey\n } = params;\n const type = STAKE_INSTRUCTION_LAYOUTS.Deactivate;\n const data = encodeData(type);\n return new Transaction().add({\n keys: [{\n pubkey: stakePubkey,\n isSigner: false,\n isWritable: true\n }, {\n pubkey: SYSVAR_CLOCK_PUBKEY,\n isSigner: false,\n isWritable: false\n }, {\n pubkey: authorizedPubkey,\n isSigner: true,\n isWritable: false\n }],\n programId: this.programId,\n data\n });\n }\n}\nStakeProgram.programId = new PublicKey('Stake11111111111111111111111111111111111111');\n/**\n * Max space of a Stake account\n *\n * This is generated from the solana-stake-program StakeState struct as\n * `StakeStateV2::size_of()`:\n * https://docs.rs/solana-stake-program/latest/solana_stake_program/stake_state/enum.StakeStateV2.html\n */\nStakeProgram.space = 200;\n\n/**\n * Vote account info\n */\nclass VoteInit {\n /** [0, 100] */\n\n constructor(nodePubkey, authorizedVoter, authorizedWithdrawer, commission) {\n this.nodePubkey = void 0;\n this.authorizedVoter = void 0;\n this.authorizedWithdrawer = void 0;\n this.commission = void 0;\n this.nodePubkey = nodePubkey;\n this.authorizedVoter = authorizedVoter;\n this.authorizedWithdrawer = authorizedWithdrawer;\n this.commission = commission;\n }\n}\n\n/**\n * Create vote account transaction params\n */\n\n/**\n * InitializeAccount instruction params\n */\n\n/**\n * Authorize instruction params\n */\n\n/**\n * AuthorizeWithSeed instruction params\n */\n\n/**\n * Withdraw from vote account transaction params\n */\n\n/**\n * Update validator identity (node pubkey) vote account instruction params.\n */\n\n/**\n * Vote Instruction class\n */\nclass VoteInstruction {\n /**\n * @internal\n */\n constructor() {}\n\n /**\n * Decode a vote instruction and retrieve the instruction type.\n */\n static decodeInstructionType(instruction) {\n this.checkProgramId(instruction.programId);\n const instructionTypeLayout = BufferLayout.u32('instruction');\n const typeIndex = instructionTypeLayout.decode(instruction.data);\n let type;\n for (const [ixType, layout] of Object.entries(VOTE_INSTRUCTION_LAYOUTS)) {\n if (layout.index == typeIndex) {\n type = ixType;\n break;\n }\n }\n if (!type) {\n throw new Error('Instruction type incorrect; not a VoteInstruction');\n }\n return type;\n }\n\n /**\n * Decode an initialize vote instruction and retrieve the instruction params.\n */\n static decodeInitializeAccount(instruction) {\n this.checkProgramId(instruction.programId);\n this.checkKeyLength(instruction.keys, 4);\n const {\n voteInit\n } = decodeData$1(VOTE_INSTRUCTION_LAYOUTS.InitializeAccount, instruction.data);\n return {\n votePubkey: instruction.keys[0].pubkey,\n nodePubkey: instruction.keys[3].pubkey,\n voteInit: new VoteInit(new PublicKey(voteInit.nodePubkey), new PublicKey(voteInit.authorizedVoter), new PublicKey(voteInit.authorizedWithdrawer), voteInit.commission)\n };\n }\n\n /**\n * Decode an authorize instruction and retrieve the instruction params.\n */\n static decodeAuthorize(instruction) {\n this.checkProgramId(instruction.programId);\n this.checkKeyLength(instruction.keys, 3);\n const {\n newAuthorized,\n voteAuthorizationType\n } = decodeData$1(VOTE_INSTRUCTION_LAYOUTS.Authorize, instruction.data);\n return {\n votePubkey: instruction.keys[0].pubkey,\n authorizedPubkey: instruction.keys[2].pubkey,\n newAuthorizedPubkey: new PublicKey(newAuthorized),\n voteAuthorizationType: {\n index: voteAuthorizationType\n }\n };\n }\n\n /**\n * Decode an authorize instruction and retrieve the instruction params.\n */\n static decodeAuthorizeWithSeed(instruction) {\n this.checkProgramId(instruction.programId);\n this.checkKeyLength(instruction.keys, 3);\n const {\n voteAuthorizeWithSeedArgs: {\n currentAuthorityDerivedKeyOwnerPubkey,\n currentAuthorityDerivedKeySeed,\n newAuthorized,\n voteAuthorizationType\n }\n } = decodeData$1(VOTE_INSTRUCTION_LAYOUTS.AuthorizeWithSeed, instruction.data);\n return {\n currentAuthorityDerivedKeyBasePubkey: instruction.keys[2].pubkey,\n currentAuthorityDerivedKeyOwnerPubkey: new PublicKey(currentAuthorityDerivedKeyOwnerPubkey),\n currentAuthorityDerivedKeySeed: currentAuthorityDerivedKeySeed,\n newAuthorizedPubkey: new PublicKey(newAuthorized),\n voteAuthorizationType: {\n index: voteAuthorizationType\n },\n votePubkey: instruction.keys[0].pubkey\n };\n }\n\n /**\n * Decode a withdraw instruction and retrieve the instruction params.\n */\n static decodeWithdraw(instruction) {\n this.checkProgramId(instruction.programId);\n this.checkKeyLength(instruction.keys, 3);\n const {\n lamports\n } = decodeData$1(VOTE_INSTRUCTION_LAYOUTS.Withdraw, instruction.data);\n return {\n votePubkey: instruction.keys[0].pubkey,\n authorizedWithdrawerPubkey: instruction.keys[2].pubkey,\n lamports,\n toPubkey: instruction.keys[1].pubkey\n };\n }\n\n /**\n * @internal\n */\n static checkProgramId(programId) {\n if (!programId.equals(VoteProgram.programId)) {\n throw new Error('invalid instruction; programId is not VoteProgram');\n }\n }\n\n /**\n * @internal\n */\n static checkKeyLength(keys, expectedLength) {\n if (keys.length < expectedLength) {\n throw new Error(`invalid instruction; found ${keys.length} keys, expected at least ${expectedLength}`);\n }\n }\n}\n\n/**\n * An enumeration of valid VoteInstructionType's\n */\n\n/** @internal */\n\nconst VOTE_INSTRUCTION_LAYOUTS = Object.freeze({\n InitializeAccount: {\n index: 0,\n layout: BufferLayout.struct([BufferLayout.u32('instruction'), voteInit()])\n },\n Authorize: {\n index: 1,\n layout: BufferLayout.struct([BufferLayout.u32('instruction'), publicKey('newAuthorized'), BufferLayout.u32('voteAuthorizationType')])\n },\n Withdraw: {\n index: 3,\n layout: BufferLayout.struct([BufferLayout.u32('instruction'), BufferLayout.ns64('lamports')])\n },\n UpdateValidatorIdentity: {\n index: 4,\n layout: BufferLayout.struct([BufferLayout.u32('instruction')])\n },\n AuthorizeWithSeed: {\n index: 10,\n layout: BufferLayout.struct([BufferLayout.u32('instruction'), voteAuthorizeWithSeedArgs()])\n }\n});\n\n/**\n * VoteAuthorize type\n */\n\n/**\n * An enumeration of valid VoteAuthorization layouts.\n */\nconst VoteAuthorizationLayout = Object.freeze({\n Voter: {\n index: 0\n },\n Withdrawer: {\n index: 1\n }\n});\n\n/**\n * Factory class for transactions to interact with the Vote program\n */\nclass VoteProgram {\n /**\n * @internal\n */\n constructor() {}\n\n /**\n * Public key that identifies the Vote program\n */\n\n /**\n * Generate an Initialize instruction.\n */\n static initializeAccount(params) {\n const {\n votePubkey,\n nodePubkey,\n voteInit\n } = params;\n const type = VOTE_INSTRUCTION_LAYOUTS.InitializeAccount;\n const data = encodeData(type, {\n voteInit: {\n nodePubkey: toBuffer(voteInit.nodePubkey.toBuffer()),\n authorizedVoter: toBuffer(voteInit.authorizedVoter.toBuffer()),\n authorizedWithdrawer: toBuffer(voteInit.authorizedWithdrawer.toBuffer()),\n commission: voteInit.commission\n }\n });\n const instructionData = {\n keys: [{\n pubkey: votePubkey,\n isSigner: false,\n isWritable: true\n }, {\n pubkey: SYSVAR_RENT_PUBKEY,\n isSigner: false,\n isWritable: false\n }, {\n pubkey: SYSVAR_CLOCK_PUBKEY,\n isSigner: false,\n isWritable: false\n }, {\n pubkey: nodePubkey,\n isSigner: true,\n isWritable: false\n }],\n programId: this.programId,\n data\n };\n return new TransactionInstruction(instructionData);\n }\n\n /**\n * Generate a transaction that creates a new Vote account.\n */\n static createAccount(params) {\n const transaction = new Transaction();\n transaction.add(SystemProgram.createAccount({\n fromPubkey: params.fromPubkey,\n newAccountPubkey: params.votePubkey,\n lamports: params.lamports,\n space: this.space,\n programId: this.programId\n }));\n return transaction.add(this.initializeAccount({\n votePubkey: params.votePubkey,\n nodePubkey: params.voteInit.nodePubkey,\n voteInit: params.voteInit\n }));\n }\n\n /**\n * Generate a transaction that authorizes a new Voter or Withdrawer on the Vote account.\n */\n static authorize(params) {\n const {\n votePubkey,\n authorizedPubkey,\n newAuthorizedPubkey,\n voteAuthorizationType\n } = params;\n const type = VOTE_INSTRUCTION_LAYOUTS.Authorize;\n const data = encodeData(type, {\n newAuthorized: toBuffer(newAuthorizedPubkey.toBuffer()),\n voteAuthorizationType: voteAuthorizationType.index\n });\n const keys = [{\n pubkey: votePubkey,\n isSigner: false,\n isWritable: true\n }, {\n pubkey: SYSVAR_CLOCK_PUBKEY,\n isSigner: false,\n isWritable: false\n }, {\n pubkey: authorizedPubkey,\n isSigner: true,\n isWritable: false\n }];\n return new Transaction().add({\n keys,\n programId: this.programId,\n data\n });\n }\n\n /**\n * Generate a transaction that authorizes a new Voter or Withdrawer on the Vote account\n * where the current Voter or Withdrawer authority is a derived key.\n */\n static authorizeWithSeed(params) {\n const {\n currentAuthorityDerivedKeyBasePubkey,\n currentAuthorityDerivedKeyOwnerPubkey,\n currentAuthorityDerivedKeySeed,\n newAuthorizedPubkey,\n voteAuthorizationType,\n votePubkey\n } = params;\n const type = VOTE_INSTRUCTION_LAYOUTS.AuthorizeWithSeed;\n const data = encodeData(type, {\n voteAuthorizeWithSeedArgs: {\n currentAuthorityDerivedKeyOwnerPubkey: toBuffer(currentAuthorityDerivedKeyOwnerPubkey.toBuffer()),\n currentAuthorityDerivedKeySeed: currentAuthorityDerivedKeySeed,\n newAuthorized: toBuffer(newAuthorizedPubkey.toBuffer()),\n voteAuthorizationType: voteAuthorizationType.index\n }\n });\n const keys = [{\n pubkey: votePubkey,\n isSigner: false,\n isWritable: true\n }, {\n pubkey: SYSVAR_CLOCK_PUBKEY,\n isSigner: false,\n isWritable: false\n }, {\n pubkey: currentAuthorityDerivedKeyBasePubkey,\n isSigner: true,\n isWritable: false\n }];\n return new Transaction().add({\n keys,\n programId: this.programId,\n data\n });\n }\n\n /**\n * Generate a transaction to withdraw from a Vote account.\n */\n static withdraw(params) {\n const {\n votePubkey,\n authorizedWithdrawerPubkey,\n lamports,\n toPubkey\n } = params;\n const type = VOTE_INSTRUCTION_LAYOUTS.Withdraw;\n const data = encodeData(type, {\n lamports\n });\n const keys = [{\n pubkey: votePubkey,\n isSigner: false,\n isWritable: true\n }, {\n pubkey: toPubkey,\n isSigner: false,\n isWritable: true\n }, {\n pubkey: authorizedWithdrawerPubkey,\n isSigner: true,\n isWritable: false\n }];\n return new Transaction().add({\n keys,\n programId: this.programId,\n data\n });\n }\n\n /**\n * Generate a transaction to withdraw safely from a Vote account.\n *\n * This function was created as a safeguard for vote accounts running validators, `safeWithdraw`\n * checks that the withdraw amount will not exceed the specified balance while leaving enough left\n * to cover rent. If you wish to close the vote account by withdrawing the full amount, call the\n * `withdraw` method directly.\n */\n static safeWithdraw(params, currentVoteAccountBalance, rentExemptMinimum) {\n if (params.lamports > currentVoteAccountBalance - rentExemptMinimum) {\n throw new Error('Withdraw will leave vote account with insufficient funds.');\n }\n return VoteProgram.withdraw(params);\n }\n\n /**\n * Generate a transaction to update the validator identity (node pubkey) of a Vote account.\n */\n static updateValidatorIdentity(params) {\n const {\n votePubkey,\n authorizedWithdrawerPubkey,\n nodePubkey\n } = params;\n const type = VOTE_INSTRUCTION_LAYOUTS.UpdateValidatorIdentity;\n const data = encodeData(type);\n const keys = [{\n pubkey: votePubkey,\n isSigner: false,\n isWritable: true\n }, {\n pubkey: nodePubkey,\n isSigner: true,\n isWritable: false\n }, {\n pubkey: authorizedWithdrawerPubkey,\n isSigner: true,\n isWritable: false\n }];\n return new Transaction().add({\n keys,\n programId: this.programId,\n data\n });\n }\n}\nVoteProgram.programId = new PublicKey('Vote111111111111111111111111111111111111111');\n/**\n * Max space of a Vote account\n *\n * This is generated from the solana-vote-program VoteState struct as\n * `VoteState::size_of()`:\n * https://docs.rs/solana-vote-program/1.9.5/solana_vote_program/vote_state/struct.VoteState.html#method.size_of\n *\n * KEEP IN SYNC WITH `VoteState::size_of()` in https://github.com/solana-labs/solana/blob/a474cb24b9238f5edcc982f65c0b37d4a1046f7e/sdk/program/src/vote/state/mod.rs#L340-L342\n */\nVoteProgram.space = 3762;\n\nconst VALIDATOR_INFO_KEY = new PublicKey('Va1idator1nfo111111111111111111111111111111');\n\n/**\n * @internal\n */\n\n/**\n * Info used to identity validators.\n */\n\nconst InfoString = type({\n name: string(),\n website: optional(string()),\n details: optional(string()),\n keybaseUsername: optional(string())\n});\n\n/**\n * ValidatorInfo class\n */\nclass ValidatorInfo {\n /**\n * Construct a valid ValidatorInfo\n *\n * @param key validator public key\n * @param info validator information\n */\n constructor(key, info) {\n /**\n * validator public key\n */\n this.key = void 0;\n /**\n * validator information\n */\n this.info = void 0;\n this.key = key;\n this.info = info;\n }\n\n /**\n * Deserialize ValidatorInfo from the config account data. Exactly two config\n * keys are required in the data.\n *\n * @param buffer config account data\n * @return null if info was not found\n */\n static fromConfigData(buffer) {\n let byteArray = [...buffer];\n const configKeyCount = decodeLength(byteArray);\n if (configKeyCount !== 2) return null;\n const configKeys = [];\n for (let i = 0; i < 2; i++) {\n const publicKey = new PublicKey(guardedSplice(byteArray, 0, PUBLIC_KEY_LENGTH));\n const isSigner = guardedShift(byteArray) === 1;\n configKeys.push({\n publicKey,\n isSigner\n });\n }\n if (configKeys[0].publicKey.equals(VALIDATOR_INFO_KEY)) {\n if (configKeys[1].isSigner) {\n const rawInfo = rustString().decode(Buffer.from(byteArray));\n const info = JSON.parse(rawInfo);\n assert$1(info, InfoString);\n return new ValidatorInfo(configKeys[1].publicKey, info);\n }\n }\n return null;\n }\n}\n\nconst VOTE_PROGRAM_ID = new PublicKey('Vote111111111111111111111111111111111111111');\n\n/**\n * History of how many credits earned by the end of each epoch\n */\n\n/**\n * See https://github.com/solana-labs/solana/blob/8a12ed029cfa38d4a45400916c2463fb82bbec8c/programs/vote_api/src/vote_state.rs#L68-L88\n *\n * @internal\n */\nconst VoteAccountLayout = BufferLayout.struct([publicKey('nodePubkey'), publicKey('authorizedWithdrawer'), BufferLayout.u8('commission'), BufferLayout.nu64(),\n// votes.length\nBufferLayout.seq(BufferLayout.struct([BufferLayout.nu64('slot'), BufferLayout.u32('confirmationCount')]), BufferLayout.offset(BufferLayout.u32(), -8), 'votes'), BufferLayout.u8('rootSlotValid'), BufferLayout.nu64('rootSlot'), BufferLayout.nu64(),\n// authorizedVoters.length\nBufferLayout.seq(BufferLayout.struct([BufferLayout.nu64('epoch'), publicKey('authorizedVoter')]), BufferLayout.offset(BufferLayout.u32(), -8), 'authorizedVoters'), BufferLayout.struct([BufferLayout.seq(BufferLayout.struct([publicKey('authorizedPubkey'), BufferLayout.nu64('epochOfLastAuthorizedSwitch'), BufferLayout.nu64('targetEpoch')]), 32, 'buf'), BufferLayout.nu64('idx'), BufferLayout.u8('isEmpty')], 'priorVoters'), BufferLayout.nu64(),\n// epochCredits.length\nBufferLayout.seq(BufferLayout.struct([BufferLayout.nu64('epoch'), BufferLayout.nu64('credits'), BufferLayout.nu64('prevCredits')]), BufferLayout.offset(BufferLayout.u32(), -8), 'epochCredits'), BufferLayout.struct([BufferLayout.nu64('slot'), BufferLayout.nu64('timestamp')], 'lastTimestamp')]);\n/**\n * VoteAccount class\n */\nclass VoteAccount {\n /**\n * @internal\n */\n constructor(args) {\n this.nodePubkey = void 0;\n this.authorizedWithdrawer = void 0;\n this.commission = void 0;\n this.rootSlot = void 0;\n this.votes = void 0;\n this.authorizedVoters = void 0;\n this.priorVoters = void 0;\n this.epochCredits = void 0;\n this.lastTimestamp = void 0;\n this.nodePubkey = args.nodePubkey;\n this.authorizedWithdrawer = args.authorizedWithdrawer;\n this.commission = args.commission;\n this.rootSlot = args.rootSlot;\n this.votes = args.votes;\n this.authorizedVoters = args.authorizedVoters;\n this.priorVoters = args.priorVoters;\n this.epochCredits = args.epochCredits;\n this.lastTimestamp = args.lastTimestamp;\n }\n\n /**\n * Deserialize VoteAccount from the account data.\n *\n * @param buffer account data\n * @return VoteAccount\n */\n static fromAccountData(buffer) {\n const versionOffset = 4;\n const va = VoteAccountLayout.decode(toBuffer(buffer), versionOffset);\n let rootSlot = va.rootSlot;\n if (!va.rootSlotValid) {\n rootSlot = null;\n }\n return new VoteAccount({\n nodePubkey: new PublicKey(va.nodePubkey),\n authorizedWithdrawer: new PublicKey(va.authorizedWithdrawer),\n commission: va.commission,\n votes: va.votes,\n rootSlot,\n authorizedVoters: va.authorizedVoters.map(parseAuthorizedVoter),\n priorVoters: getPriorVoters(va.priorVoters),\n epochCredits: va.epochCredits,\n lastTimestamp: va.lastTimestamp\n });\n }\n}\nfunction parseAuthorizedVoter({\n authorizedVoter,\n epoch\n}) {\n return {\n epoch,\n authorizedVoter: new PublicKey(authorizedVoter)\n };\n}\nfunction parsePriorVoters({\n authorizedPubkey,\n epochOfLastAuthorizedSwitch,\n targetEpoch\n}) {\n return {\n authorizedPubkey: new PublicKey(authorizedPubkey),\n epochOfLastAuthorizedSwitch,\n targetEpoch\n };\n}\nfunction getPriorVoters({\n buf,\n idx,\n isEmpty\n}) {\n if (isEmpty) {\n return [];\n }\n return [...buf.slice(idx + 1).map(parsePriorVoters), ...buf.slice(0, idx).map(parsePriorVoters)];\n}\n\nconst endpoint = {\n http: {\n devnet: 'http://api.devnet.solana.com',\n testnet: 'http://api.testnet.solana.com',\n 'mainnet-beta': 'http://api.mainnet-beta.solana.com/'\n },\n https: {\n devnet: 'https://api.devnet.solana.com',\n testnet: 'https://api.testnet.solana.com',\n 'mainnet-beta': 'https://api.mainnet-beta.solana.com/'\n }\n};\n/**\n * Retrieves the RPC API URL for the specified cluster\n * @param {Cluster} [cluster=\"devnet\"] - The cluster name of the RPC API URL to use. Possible options: 'devnet' | 'testnet' | 'mainnet-beta'\n * @param {boolean} [tls=\"http\"] - Use TLS when connecting to cluster.\n *\n * @returns {string} URL string of the RPC endpoint\n */\nfunction clusterApiUrl(cluster, tls) {\n const key = tls === false ? 'http' : 'https';\n if (!cluster) {\n return endpoint[key]['devnet'];\n }\n const url = endpoint[key][cluster];\n if (!url) {\n throw new Error(`Unknown ${key} cluster: ${cluster}`);\n }\n return url;\n}\n\n/**\n * Send and confirm a raw transaction\n *\n * If `commitment` option is not specified, defaults to 'max' commitment.\n *\n * @param {Connection} connection\n * @param {Buffer} rawTransaction\n * @param {TransactionConfirmationStrategy} confirmationStrategy\n * @param {ConfirmOptions} [options]\n * @returns {Promise}\n */\n\n/**\n * @deprecated Calling `sendAndConfirmRawTransaction()` without a `confirmationStrategy`\n * is no longer supported and will be removed in a future version.\n */\n// eslint-disable-next-line no-redeclare\n\n// eslint-disable-next-line no-redeclare\nasync function sendAndConfirmRawTransaction(connection, rawTransaction, confirmationStrategyOrConfirmOptions, maybeConfirmOptions) {\n let confirmationStrategy;\n let options;\n if (confirmationStrategyOrConfirmOptions && Object.prototype.hasOwnProperty.call(confirmationStrategyOrConfirmOptions, 'lastValidBlockHeight')) {\n confirmationStrategy = confirmationStrategyOrConfirmOptions;\n options = maybeConfirmOptions;\n } else if (confirmationStrategyOrConfirmOptions && Object.prototype.hasOwnProperty.call(confirmationStrategyOrConfirmOptions, 'nonceValue')) {\n confirmationStrategy = confirmationStrategyOrConfirmOptions;\n options = maybeConfirmOptions;\n } else {\n options = confirmationStrategyOrConfirmOptions;\n }\n const sendOptions = options && {\n skipPreflight: options.skipPreflight,\n preflightCommitment: options.preflightCommitment || options.commitment,\n minContextSlot: options.minContextSlot\n };\n const signature = await connection.sendRawTransaction(rawTransaction, sendOptions);\n const commitment = options && options.commitment;\n const confirmationPromise = confirmationStrategy ? connection.confirmTransaction(confirmationStrategy, commitment) : connection.confirmTransaction(signature, commitment);\n const status = (await confirmationPromise).value;\n if (status.err) {\n throw new Error(`Raw transaction ${signature} failed (${JSON.stringify(status)})`);\n }\n return signature;\n}\n\n/**\n * There are 1-billion lamports in one SOL\n */\nconst LAMPORTS_PER_SOL = 1000000000;\n\nexport { Account, AddressLookupTableAccount, AddressLookupTableInstruction, AddressLookupTableProgram, Authorized, BLOCKHASH_CACHE_TIMEOUT_MS, BPF_LOADER_DEPRECATED_PROGRAM_ID, BPF_LOADER_PROGRAM_ID, BpfLoader, COMPUTE_BUDGET_INSTRUCTION_LAYOUTS, ComputeBudgetInstruction, ComputeBudgetProgram, Connection, Ed25519Program, Enum, EpochSchedule, FeeCalculatorLayout, Keypair, LAMPORTS_PER_SOL, LOOKUP_TABLE_INSTRUCTION_LAYOUTS, Loader, Lockup, MAX_SEED_LENGTH, Message, MessageAccountKeys, MessageV0, NONCE_ACCOUNT_LENGTH, NonceAccount, PACKET_DATA_SIZE, PUBLIC_KEY_LENGTH, PublicKey, SIGNATURE_LENGTH_IN_BYTES, SOLANA_SCHEMA, STAKE_CONFIG_ID, STAKE_INSTRUCTION_LAYOUTS, SYSTEM_INSTRUCTION_LAYOUTS, SYSVAR_CLOCK_PUBKEY, SYSVAR_EPOCH_SCHEDULE_PUBKEY, SYSVAR_INSTRUCTIONS_PUBKEY, SYSVAR_RECENT_BLOCKHASHES_PUBKEY, SYSVAR_RENT_PUBKEY, SYSVAR_REWARDS_PUBKEY, SYSVAR_SLOT_HASHES_PUBKEY, SYSVAR_SLOT_HISTORY_PUBKEY, SYSVAR_STAKE_HISTORY_PUBKEY, Secp256k1Program, SendTransactionError, SolanaJSONRPCError, SolanaJSONRPCErrorCode, StakeAuthorizationLayout, StakeInstruction, StakeProgram, Struct, SystemInstruction, SystemProgram, Transaction, TransactionExpiredBlockheightExceededError, TransactionExpiredNonceInvalidError, TransactionExpiredTimeoutError, TransactionInstruction, TransactionMessage, TransactionStatus, VALIDATOR_INFO_KEY, VERSION_PREFIX_MASK, VOTE_PROGRAM_ID, ValidatorInfo, VersionedMessage, VersionedTransaction, VoteAccount, VoteAuthorizationLayout, VoteInit, VoteInstruction, VoteProgram, clusterApiUrl, sendAndConfirmRawTransaction, sendAndConfirmTransaction };\n//# sourceMappingURL=index.browser.esm.js.map\n"],"names":["_Symbol$toStringTag","TransactionStatus","x","_noble_curves_ed25519__WEBPACK_IMPORTED_MODULE_9__","UN","utils","randomPrivateKey","generateKeypair","privateScalar","publicKey","getPublicKey","secretKey","Uint8Array","set","isOnCurve","ExtendedPoint","fromHex","sign","message","slice","verify","toBuffer","arr","Buffer","isBuffer","buffer__WEBPACK_IMPORTED_MODULE_0__","from","buffer","byteOffset","byteLength","Struct","constructor","properties","Object","assign","encode","borsh__WEBPACK_IMPORTED_MODULE_3__","serialize","SOLANA_SCHEMA","decode","data","deserialize","decodeUnchecked","deserializeUnchecked","Map","uniquePublicKeyCounter","Symbol","toStringTag","PublicKey","value","_bn","undefined","decoded","bs58__WEBPACK_IMPORTED_MODULE_2___default","length","bn_js__WEBPACK_IMPORTED_MODULE_1___default","unique","key","equals","eq","toBase58","toBytes","toJSON","buf","b","toArrayLike","zeroPad","alloc","copy","toString","createWithSeed","fromPublicKey","seed","programId","concat","_noble_hashes_sha256__WEBPACK_IMPORTED_MODULE_10__","J","createProgramAddressSync","seeds","forEach","publicKeyBytes","createProgramAddress","findProgramAddressSync","address","nonce","seedsWithNonce","err","TypeError","findProgramAddress","pubkeyData","pubkey","default","kind","fields","SIGNATURE_LENGTH_IN_BYTES","TransactionExpiredBlockheightExceededError","Error","signature","defineProperty","prototype","TransactionExpiredTimeoutError","timeoutSeconds","toFixed","TransactionExpiredNonceInvalidError","MessageAccountKeys","staticAccountKeys","accountKeysFromLookups","keySegments","push","writable","readonly","get","index","keySegment","flat","compileInstructions","instructions","U8_MAX","keyIndexMap","findKeyIndex","keyIndex","map","instruction","programIdIndex","accountKeyIndexes","keys","meta","property","_solana_buffer_layout__WEBPACK_IMPORTED_MODULE_4__","Ik","rustString","rsl","n_","Jq","cv","_decode","bind","_encode","rslShim","offset","str","chars","span","decodeLength","bytes","len","size","elem","shift","encodeLength","rem_len","assert","condition","CompiledKeys","payer","keyMetaMap","compile","getOrInsertDefault","keyMeta","isSigner","isWritable","isInvoked","payerKeyMeta","ix","accountMeta","getMessageComponents","mapEntries","entries","writableSigners","filter","readonlySigners","writableNonSigners","readonlyNonSigners","header","numRequiredSignatures","numReadonlySignedAccounts","numReadonlyUnsignedAccounts","payerAddress","extractTableLookup","lookupTable","writableIndexes","drainedWritableKeys","drainKeysFoundInLookupTable","state","addresses","readonlyIndexes","drainedReadonlyKeys","accountKey","lookupTableEntries","keyMetaFilter","lookupTableIndexes","drainedKeys","lookupTableIndex","findIndex","entry","delete","END_OF_BUFFER_ERROR_MESSAGE","guardedShift","byteArray","guardedSplice","args","start","splice","Message","accountKeys","recentBlockhash","indexToProgramIds","account","version","compiledInstructions","accounts","addressTableLookups","getAccountKeys","compiledKeys","payerKey","isAccountSigner","isAccountWritable","numSignedAccounts","numWritableUnsignedAccounts","numUnsignedAccounts","unsignedAccountIndex","isProgramId","has","programIds","values","nonProgramIds","_","numKeys","keyCount","Array","keyIndicesCount","dataCount","keyIndices","dataLength","instructionCount","instructionBuffer","instructionBufferLength","instructionLayout","u8","A9","signDataLayout","transaction","signData","accountCount","i","dataSlice","MessageV0","numAccountKeysFromLookups","count","lookup","addressLookupTableAccounts","resolveAddressTableLookups","numStaticAccountKeys","lookupAccountKeysIndex","reduce","tableLookup","tableAccount","find","extractResult","addressTableLookup","encodedStaticAccountKeysLength","serializedInstructions","serializeInstructions","encodedInstructionsLength","serializedAddressTableLookups","serializeAddressTableLookups","encodedAddressTableLookupsLength","messageLayout","serializedMessage","serializedMessageLength","prefix","staticAccountKeysLength","instructionsLength","addressTableLookupsLength","serializedLength","encodedAccountKeyIndexesLength","encodedDataLength","encodedWritableIndexesLength","encodedReadonlyIndexesLength","addressTableLookupLayout","maskedPrefix","accountKeyIndexesLength","addressTableLookupsCount","writableIndexesLength","readonlyIndexesLength","VersionedMessage","deserializeMessageVersion","DEFAULT_SIGNATURE","fill","TransactionInstruction","opts","Transaction","signatures","feePayer","lastValidBlockHeight","nonceInfo","minNonceContextSlot","_message","_json","hasOwnProperty","call","minContextSlot","blockhash","nonceInstruction","signers","add","items","item","compileMessage","JSON","stringify","console","warn","accountMetas","includes","uniqueMetas","pubkeyString","uniqueIndex","sort","y","localeCompare","localeMatcher","usage","sensitivity","ignorePunctuation","numeric","caseFirst","feePayerIndex","payerMeta","unshift","signedKeys","unsignedKeys","indexOf","_compile","every","pair","serializeMessage","getEstimatedFee","connection","getFeeForMessage","setSigners","seen","Set","uniqueSigners","signer","_partialSign","partialSign","_addSignature","addSignature","sigpair","verifySignatures","requireAllSignatures","_getMessageSignednessErrors","errors","missing","invalid","config","sigErrors","errorMessage","p","join","_serialize","signatureCount","transactionLength","wireTransaction","keyObj","populate","sigPubkeyPair","some","VersionedTransaction","defaultSignatures","encodedSignaturesLength","transactionLayout","serializedTransaction","serializedTransactionLength","signaturesLength","messageData","signerPubkeys","signerIndex","SYSVAR_CLOCK_PUBKEY","SYSVAR_RECENT_BLOCKHASHES_PUBKEY","SYSVAR_RENT_PUBKEY","SYSVAR_STAKE_HISTORY_PUBKEY","sendAndConfirmTransaction","options","status","sendOptions","skipPreflight","preflightCommitment","commitment","maxRetries","sendTransaction","confirmTransaction","abortSignal","nonceAccountPubkey","nonceValue","sleep","ms","Promise","resolve","setTimeout","encodeData","type","allocLength","layout","getAlloc","getItemAlloc","field","isArray","elementLayout","layoutFields","FeeCalculatorLayout","_O","NonceAccountLayout","NONCE_ACCOUNT_LENGTH","NonceAccount","authorizedPubkey","feeCalculator","fromAccountData","nonceAccount","encodeDecode","u64","bigIntLayout","src","bigint_buffer__WEBPACK_IMPORTED_MODULE_5__","oU","bigInt","k$","SYSTEM_INSTRUCTION_LAYOUTS","freeze","Create","gM","Assign","Transfer","CreateWithSeed","AdvanceNonceAccount","WithdrawNonceAccount","InitializeNonceAccount","AuthorizeNonceAccount","Allocate","AllocateWithSeed","AssignWithSeed","TransferWithSeed","UpgradeNonceAccount","SystemProgram","createAccount","params","lamports","space","fromPubkey","newAccountPubkey","transfer","BigInt","basePubkey","toPubkey","base","accountPubkey","createAccountWithSeed","createNonceAccount","noncePubkey","initParams","nonceInitialize","authorized","nonceAdvance","nonceWithdraw","nonceAuthorize","newAuthorizedPubkey","allocate","Loader","getMinNumSignatures","Math","ceil","chunkSize","load","program","balanceNeeded","getMinimumBalanceForRentExemption","programInfo","getAccountInfo","executable","error","owner","dataLayout","array","transactions","bytesLength","bytesLengthPadding","_rpcEndpoint","all","deployCommitment","finalizeSignature","context","currentSlot","getSlot","slot","round","MS_PER_SLOT","PACKET_DATA_SIZE","objToString","objKeys","obj","name","fastStableStringify$1","val","returnVal","isArrayProp","max","propVal","toStr","isFinite","__esModule","trailingZeros","n","EpochSchedule","slotsPerEpoch","leaderScheduleSlotOffset","warmup","firstNormalEpoch","firstNormalSlot","getEpoch","getEpochAndSlotIndex","epoch","epochLen","getSlotsInEpoch","normalSlotIndex","normalEpochIndex","floor","getFirstSlotInEpoch","pow","getLastSlotInEpoch","SendTransactionError","logs","SolanaJSONRPCError","code","customMessage","fetchImpl","globalThis","fetch","RpcWebSocketClient","rpc_websockets_dist_lib_client__WEBPACK_IMPORTED_MODULE_7__","Z","generate_request_id","url","rpc","rpc_websockets_dist_lib_client_websocket_browser__WEBPACK_IMPORTED_MODULE_8__","autoconnect","max_reconnects","reconnect","reconnect_interval","underlyingSocket","socket","readyState","reject","notify","AddressLookupTableAccount","isActive","U64_MAX","deactivationSlot","accountData","decodeData","typeIndex","LookupTableMetaLayout","serializedAddressesLen","lastExtendedSlot","lastExtendedSlotStartIndex","lastExtendedStartIndex","authority","URL_RE","PublicKeyFromString","superstruct__WEBPACK_IMPORTED_MODULE_11__","oQ","eE","Z_","RawAccountDataResult","bc","i0","BufferFromRawAccountData","extractCommitmentFromConfig","commitmentOrConfig","specifiedCommitment","specifiedConfig","createRpcResult","result","G0","dt","jsonrpc","id","_4","jt","Yj","UnknownRpcResult","jsonRpcResult","schema","Ue","jsonRpcResultAndContext","Rx","notificationResultAndContext","versionedMessageFromResponse","response","GetInflationGovernorResult","foundation","foundationTerm","initial","taper","terminal","GetInflationRewardResult","IX","AG","effectiveSlot","amount","postBalance","commission","GetRecentPrioritizationFeesResult","prioritizationFee","GetInflationRateResult","total","validator","GetEpochInfoResult","slotIndex","slotsInEpoch","absoluteSlot","blockHeight","transactionCount","GetEpochScheduleResult","O7","GetLeaderScheduleResult","IM","TransactionErrorResult","SignatureStatusResult","SignatureReceivedResult","VersionResult","SimulatedTransactionResponseStruct","rentEpoch","unitsConsumed","returnData","BlockProductionResponseStruct","byIdentity","range","firstSlot","lastSlot","GetInflationGovernorRpcResult","GetInflationRateRpcResult","GetRecentPrioritizationFeesRpcResult","GetEpochInfoRpcResult","GetEpochScheduleRpcResult","GetLeaderScheduleRpcResult","SlotRpcResult","GetSupplyRpcResult","circulating","nonCirculating","nonCirculatingAccounts","TokenAmountResult","uiAmount","decimals","uiAmountString","GetTokenLargestAccountsResult","GetTokenAccountsByOwner","ParsedAccountDataResult","parsed","GetParsedTokenAccountsByOwner","GetLargestAccountsRpcResult","AccountInfoResult","KeyedAccountInfoResult","ParsedOrRawAccountData","ParsedAccountInfoResult","KeyedParsedAccountInfoResult","StakeActivationResult","active","inactive","GetConfirmedSignaturesForAddress2RpcResult","memo","blockTime","GetSignaturesForAddressRpcResult","AccountNotificationResult","subscription","ProgramAccountInfoResult","ProgramAccountNotificationResult","SlotInfoResult","parent","root","SlotNotificationResult","SlotUpdateResult","timestamp","stats","numTransactionEntries","numSuccessfulTransactions","numFailedTransactions","maxTransactionsPerEntry","SlotUpdateNotificationResult","SignatureNotificationResult","RootNotificationResult","ContactInfoResult","gossip","tpu","VoteAccountInfoResult","votePubkey","nodePubkey","activatedStake","epochVoteAccount","epochCredits","lastVote","rootSlot","GetVoteAccounts","current","delinquent","ConfirmationStatus","SignatureStatusResponse","confirmations","confirmationStatus","GetSignatureStatusesRpcResult","GetMinimumBalanceForRentExemptionRpcResult","AddressTableLookupStruct","ConfirmedTransactionResult","AnnotatedAccountKey","source","ConfirmedTransactionAccountsModeResult","ParsedInstructionResult","RawInstructionResult","InstructionResult","UnknownInstructionResult","ParsedOrRawInstruction","ParsedConfirmedTransactionResult","TokenBalanceResult","accountIndex","mint","uiTokenAmount","LoadedAddressesResult","ConfirmedTransactionMetaResult","fee","innerInstructions","preBalances","postBalances","logMessages","preTokenBalances","postTokenBalances","loadedAddresses","computeUnitsConsumed","ParsedConfirmedTransactionMetaResult","TransactionVersionStruct","RewardsResult","rewardType","GetBlockRpcResult","previousBlockhash","parentSlot","rewards","GetNoneModeBlockRpcResult","GetAccountsModeBlockRpcResult","GetParsedBlockRpcResult","GetParsedAccountsModeBlockRpcResult","GetParsedNoneModeBlockRpcResult","GetConfirmedBlockRpcResult","GetBlockSignaturesRpcResult","GetTransactionRpcResult","GetParsedTransactionRpcResult","GetRecentBlockhashAndContextRpcResult","lamportsPerSignature","GetLatestBlockhashRpcResult","IsBlockhashValidRpcResult","PerfSampleResult","numTransactions","numSlots","samplePeriodSecs","GetRecentPerformanceSamplesRpcResult","GetFeeCalculatorRpcResult","RequestAirdropRpcResult","SendTransactionRpcResult","LogsResult","LogsNotificationResult","COMMON_HTTP_HEADERS","Connection","endpoint","_commitmentOrConfig","client","wsEndpoint","httpHeaders","fetchMiddleware","disableRetryOnRateLimit","httpAgent","_commitment","_confirmTransactionInitialTimeout","_rpcWsEndpoint","_rpcClient","_rpcRequest","_rpcBatchRequest","_rpcWebSocket","_rpcWebSocketConnected","_rpcWebSocketHeartbeat","_rpcWebSocketIdleTimeout","_rpcWebSocketGeneration","_disableBlockhashCaching","_pollingBlockhash","_blockhashInfo","latestBlockhash","lastFetch","transactionSignatures","simulatedSignatures","_nextClientSubscriptionId","_subscriptionDisposeFunctionsByClientSubscriptionId","_subscriptionHashByClientSubscriptionId","_subscriptionStateChangeCallbacksByHash","_subscriptionCallbacksByServerSubscriptionId","_subscriptionsByHash","_subscriptionsAutoDisposedByRpc","getBlockHeight","requestPromises","_buildArgs","requestHash","unsafeRes","res","confirmTransactionInitialTimeout","assertEndpointUrl","putativeUrl","test","makeWebsocketUrl","matches","match","hostish","portWithColon","rest","protocol","startsWith","startPort","parseInt","websocketPort","createRpcClient","customFetch","agent","fetchWithMiddleware","info","init","modifiedFetchArgs","modifiedInfo","modifiedInit","jayson_lib_client_browser__WEBPACK_IMPORTED_MODULE_6___default","request","callback","method","body","headers","too_many_requests_retries","waitTime","statusText","text","ok","requests","batch","methodName","Infinity","on","_wsOnOpen","_wsOnError","_wsOnClose","_wsOnAccountNotification","_wsOnProgramAccountNotification","_wsOnSlotNotification","_wsOnSlotUpdatesNotification","_wsOnSignatureNotification","_wsOnRootNotification","_wsOnLogsNotification","rpcEndpoint","getBalanceAndContext","getBalance","then","catch","e","getBlockTime","getMinimumLedgerSlot","getFirstAvailableBlock","getSupply","configArg","getTokenSupply","tokenMintAddress","getTokenAccountBalance","tokenAddress","getTokenAccountsByOwner","ownerAddress","_args","getParsedTokenAccountsByOwner","getLargestAccounts","arg","getTokenLargestAccounts","mintAddress","getAccountInfoAndContext","getParsedAccountInfo","getMultipleParsedAccounts","publicKeys","rawConfig","getMultipleAccountsInfoAndContext","getMultipleAccountsInfo","getStakeActivation","getProgramAccounts","configOrCommitment","encoding","configWithoutEncoding","baseSchema","withContext","getParsedProgramAccounts","strategy","rawSignature","decodedSignature","aborted","reason","confirmTransactionUsingLegacyTimeoutStrategy","confirmTransactionUsingBlockHeightExceedanceStrategy","confirmTransactionUsingDurableNonceStrategy","getCancellationPromise","signal","addEventListener","getTransactionConfirmationPromise","signatureSubscriptionId","disposeSignatureSubscriptionStateChangeObserver","done","abortConfirmation","removeSignatureListener","confirmationPromise","onSignature","__type","PROCESSED","subscriptionSetupPromise","resolveSubscriptionSetup","_onSubscriptionStateChange","nextState","getSignatureStatus","expiryPromise","checkBlockHeight","_e","currentBlockHeight","BLOCKHEIGHT_EXCEEDED","cancellationPromise","outcome","race","currentNonceValue","lastCheckedSlot","getCurrentNonceValue","getNonceAndContext","NONCE_INVALID","slotInWhichNonceDidAdvance","signatureStatus","commitmentForStatus","timeoutId","timeoutMs","TIMED_OUT","clearTimeout","getClusterNodes","getVoteAccounts","getSlotLeader","getSlotLeaders","startSlot","limit","getSignatureStatuses","getTransactionCount","getTotalSupply","excludeNonCirculatingAccountsList","getInflationGovernor","getInflationReward","getInflationRate","getEpochInfo","getEpochSchedule","epochSchedule","getLeaderSchedule","getRecentBlockhashAndContext","getRecentPerformanceSamples","getFeeCalculatorForBlockhash","wireMessage","getRecentPrioritizationFees","lockedWritableAccounts","getRecentBlockhash","getLatestBlockhash","getLatestBlockhashAndContext","isBlockhashValid","getVersion","getGenesisHash","getBlock","_buildArgsAtLeastConfirmed","transactionDetails","getParsedBlock","getBlockProduction","extra","c","getTransaction","getParsedTransaction","getParsedTransactions","getTransactions","getConfirmedBlock","block","getBlocks","endSlot","getBlockSignatures","getConfirmedBlockSignatures","getConfirmedTransaction","getParsedConfirmedTransaction","getParsedConfirmedTransactions","getConfirmedSignaturesForAddress","firstAvailableBlock","until","highestConfirmedRoot","before","confirmedSignatureInfo","getConfirmedSignaturesForAddress2","getSignaturesForAddress","getAddressLookupTable","accountInfo","getNonce","requestAirdrop","to","_blockhashWithExpiryBlockHeight","disableCache","timeSinceFetch","Date","now","_pollNewBlockhash","startTime","cachedLatestBlockhash","cachedBlockhash","getStakeMinimumDelegation","simulateTransaction","transactionOrMessage","configOrSigners","includeAccounts","versionedTx","encodedTransaction","originalTx","sigVerify","traceIndent","logTrace","signersOrOptions","sendRawTransaction","rawTransaction","sendEncodedTransaction","setInterval","_updateSubscriptions","Number","MAX_SAFE_INTEGER","clearInterval","hash","_setSubscription","nextSubscription","prevState","stateChangeCallbacks","cb","clientSubscriptionId","close","log","connect","activeWebSocketGeneration","isCurrentConnectionStillActive","callbacks","serverSubscriptionId","unsubscribeMethod","_handleServerNotification","callbackArgs","notification","_makeSubscription","subscriptionConfig","existingSubscription","onAccountChange","removeAccountChangeListener","_unsubscribeClientSubscription","accountId","onProgramAccountChange","filters","removeProgramAccountChangeListener","onLogs","mentions","removeOnLogsListener","onSlotChange","removeSlotChangeListener","onSlotUpdate","removeSlotUpdateListener","subscriptionName","dispose","override","_err","onSignatureWithOptions","onRootChange","removeRootChangeListener","Keypair","keypair","_keypair","generate","fromSecretKey","skipValidation","computedPublicKey","ii","fromSeed","LOOKUP_TABLE_INSTRUCTION_LAYOUTS","CreateLookupTable","FreezeLookupTable","ExtendLookupTable","DeactivateLookupTable","CloseLookupTable","AddressLookupTableProgram","createLookupTable","lookupTableAddress","bumpSeed","recentSlot","freezeLookupTable","extendLookupTable","addr","deactivateLookupTable","closeLookupTable","recipient","COMPUTE_BUDGET_INSTRUCTION_LAYOUTS","RequestUnits","RequestHeapFrame","SetComputeUnitLimit","SetComputeUnitPrice","ComputeBudgetProgram","requestUnits","requestHeapFrame","setComputeUnitLimit","setComputeUnitPrice","microLamports","ED25519_INSTRUCTION_LAYOUT","KB","Ed25519Program","createInstructionWithPublicKey","instructionIndex","publicKeyOffset","signatureOffset","messageDataOffset","instructionData","numSignatures","padding","signatureInstructionIndex","publicKeyInstructionIndex","messageDataSize","messageInstructionIndex","createInstructionWithPrivateKey","privateKey","ecdsaSign","msgHash","privKey","_noble_curves_secp256k1__WEBPACK_IMPORTED_MODULE_12__","kA","toCompactRawBytes","recovery","isValidPrivateKey","publicKeyCreate","SECP256K1_INSTRUCTION_LAYOUT","Secp256k1Program","publicKeyToEthAddress","_noble_hashes_sha3__WEBPACK_IMPORTED_MODULE_13__","fr","recoveryId","createInstructionWithEthAddress","ethAddress","rawAddress","substr","dataStart","ethAddressOffset","ethAddressInstructionIndex","pkey","messageHash","STAKE_CONFIG_ID","Lockup","unixTimestamp","custodian","STAKE_INSTRUCTION_LAYOUTS","Initialize","lockup","Authorize","Delegate","Split","Withdraw","Deactivate","Merge","AuthorizeWithSeed","Staker","Withdrawer","StakeProgram","initialize","stakePubkey","maybeLockup","staker","withdrawer","delegate","authorize","stakeAuthorizationType","custodianPubkey","newAuthorized","authorizeWithSeed","authorityBase","authoritySeed","authorityOwner","splitInstruction","splitStakePubkey","split","rentExemptReserve","splitWithSeed","merge","sourceStakePubKey","withdraw","deactivate","VOTE_INSTRUCTION_LAYOUTS","InitializeAccount","voteInit","UpdateValidatorIdentity","voteAuthorizeWithSeedArgs","Voter","VoteProgram","initializeAccount","authorizedVoter","authorizedWithdrawer","voteAuthorizationType","currentAuthorityDerivedKeyBasePubkey","currentAuthorityDerivedKeyOwnerPubkey","currentAuthorityDerivedKeySeed","authorizedWithdrawerPubkey","safeWithdraw","currentVoteAccountBalance","rentExemptMinimum","updateValidatorIdentity","website","details","keybaseUsername","http","devnet","testnet","https","clusterApiUrl","cluster","tls"],"sourceRoot":""}