@solana/kit
v8.3.0 (2026-09-09)
Minor Changes
-
[
@solana/addresses,@solana/transaction-messages] #20257a14614Thanks @lorisleiva! - Add a newHasAddresstype representing any object exposing a Solana address through anaddressproperty — e.g. aTransactionSigner, anAccountMetaor a framework's address wrapper class. The fee payer of a transaction message is now typed usingHasAddress(a structurally identical change). -
[
@solana/codecs-core] #2030a5267b3Thanks @lorisleiva! - Addtapcodec helpers for observing values and bytes without modifying them. The value family (tapEncoder/tapDecoder/tapCodec) observes the input value before encoding and the decoded value after decoding, whilst the bytes family (tapEncoderBytes/tapDecoderBytes/tapCodecBytes) observes the raw bytes after encoding and before decoding. Any tap may throw to abort the operation, making these helpers ideal for adding validation guards to existing codecs without an identitytransformEncoder. For example,tapDecoderBytes(getBooleanDecoder(), (bytes, offset) => { if (bytes[offset] > 1) throw new Error('Expected a 0 or a 1 for booleans'); }). -
[
@solana/codecs-data-structures] #2042cd2776eThanks @lorisleiva! - Add arequireSizePrefixoption to the array, map and set codecs. By default, decoding an exhausted byte array yields an empty collection so that collections can be appended to existing data layouts; withrequireSizePrefix: true, a missing size prefix throws instead. -
[
@solana/codecs-numbers] #20293206678Thanks @lorisleiva! - Addu256andi256number codecs (getU256Codec/getU256Encoder/getU256DecoderandgetI256Codec/getI256Encoder/getI256Decoder), extending the number codecs beyond 128-bit integers. Both support little- and big-endian serialization via theendianoption and, as with the other large-integer codecs, always decode to abigint. -
[
@solana/codecs-strings,@solana/errors] #2041cae725cThanks @lorisleiva! - Addfatal,ignoreBOMandremoveNullCharactersoptions to the UTF-8 codec. Withfatal, lone surrogates when encoding and malformed byte sequences when decoding throw aSolanaErrorinstead of being replaced withU+FFFD. WithignoreBOM: true, a leading byte order mark is preserved instead of being stripped. WithremoveNullCharacters: false, null characters are preserved in decoded strings instead of being stripped as padding. On React Native, a leading byte order mark is now stripped by default, consistent with other platforms. -
[
@solana/errors,@solana/program-client-core] #20257a14614Thanks @lorisleiva! - Widen the accepted inputs of instruction accounts in generated program clients. The newInstructionAccountInputtype accepts anAddress, any address-bearing object (HasAddress) — including framework wrapper classes — aProgramDerivedAddressor anAccountNonSignerMetaused to override the role declared by the program's IDL. Similarly, the newInstructionSignerInputtype accepts aTransactionSigneror anAccountSignerMetarole override. In addition,ResolvedInstructionAccountnow carries an optionalisSignerflag describing the IDL's signer requirement: when set tofalse,TransactionSignervalues act as plain address carriers instead of being upgraded to signers, and when set totrue, a missing signer throws a helpful error pointing atcreateNoopSigner. Finally, newResolvedInstructionAccountMetaandInstructionAccountInputAddresstype helpers mirror this runtime logic at the type level so that generated instruction builders can accurately type the account metas they return. -
[
@solana/instructions] #20257a14614Thanks @lorisleiva! - Add a newAccountNonSignerMetatype representing anAccountMetawhose role is guaranteed not to be a signer role — i.e.ReadonlyAccount | WritableAccount. It is the counterpart of theAccountSignerMetatype from@solana/signers. Additionally, therolemember ofWritableAccount,ReadonlySignerAccountandWritableSignerAccountis now markedreadonly, consistently withReadonlyAccountandAccountMeta. Note that code mutating theroleof these types will now fail to compile — which was already contrary toAccountMeta's contract and would throw at runtime on frozen account metas. -
[
@solana/rpc-api,@solana/rpc-transport-http] #20161dd83c6Thanks @mcintyre94! - Added support for thegetAgGenesisCertRPC method, which returns the Alpenglow genesis certificate from nodes that have one -
[
@solana/signers] #20318af3229Thanks @lorisleiva! - AddcreateLazyKeyPairSignerFromBytes, a synchronous counterpart tocreateKeyPairSignerFromBytes. It derives the signer's address directly from the public key half of the 64-byte secret key and defers the asynchronousCryptoKeyimport until the first message or transaction is signed (memoising the result). This is useful when a signer must be created in a synchronous context whilst signing can remain asynchronous. Because the key import is deferred, the returned signer implements bothMessagePartialSignerandTransactionPartialSignerbut does not expose akeyPairproperty, and the cryptographic validation of the secret key happens on the first signing attempt rather than at creation time. The internal copy of the secret key is zeroed once the import succeeds, and a failed import is not cached so signing can be retried.
Patch Changes
- [
@solana/rpc-transport-http] #20161dd83c6Thanks @mcintyre94! - Fixed a bug where responses togetTransactionsForAddressrequests were parsed withoutbigintsupport, risking precision loss on large integer values