NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
npm · #4918 most downloaded on npm
Core types and helpers for encoding and decoding byte arrays on Solana
Last release 2 days ago
25 Sep 2026
Ships fairly regularly
a new release about every 8 days
Nearly every release is documented
notes for 38 of 38 stable releases
1 version withdrawn
withdrawn after publishing
3 years old
2265 releases · first in 2023
Nothing published for this version
Nothing published for this version
Nothing published for this version
One column per month.
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
[@solana/kit, @solana/signers, @solana/transaction-messages] #1321 `2d3296f` Thanks @mcintyre94! - Fix a bug in the type of TransactionMessageWithSign
[@solana/kit, @solana/signers, @solana/transaction-messages] #1321 2d3296f Thanks @mcintyre94! - Fix a bug in the type of TransactionMessageWithSigners
[@solana/transaction-messages] #1318 a8a57ce Thanks @mcintyre94! - Fix bugs in types of setTransactionMessageLifetimeUsingBlockhash and setTransactionMessageLifetimeUsingDurableNonce
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
[@solana/instruction-plans] #1311 `91cdb71` Thanks @lorisleiva! - Remove deprecated function getAllSingleTransactionPlans
[@solana/instruction-plans] #1302 5f12df2 Thanks @lorisleiva! - The executeTransactionMessage callback in createTransactionPlanExecutor now receives a mutable context object as its first argument. This context can be incrementally populated during execution (e.g. with the latest transaction message, the compiled transaction, or custom properties) and is preserved in the resulting SingleTransactionPlanResult regardless of the outcome. If an error is thrown at any point in the callback, any attributes already saved to the context will still be available in the FailedSingleTransactionPlanResult, which is useful for debugging failures or building recovery plans.
The callback must now return either a Signature or a full Transaction object directly, instead of wrapping the result in an object.
BREAKING CHANGES
executeTransactionMessage callback signature changed. The callback now receives (context, message, config) instead of (message, config) and returns Signature | Transaction instead of { transaction: Transaction } | { signature: Signature }.
const executor = createTransactionPlanExecutor({
- executeTransactionMessage: async (message, { abortSignal }) => {
+ executeTransactionMessage: async (context, message, { abortSignal }) => {
const transaction = await signTransactionMessageWithSigners(message);
+ context.transaction = transaction;
await sendAndConfirmTransaction(transaction, { commitment: 'confirmed' });
- return { transaction };
+ return transaction;
}
});
Custom context is now set via mutation instead of being returned. Previously, custom context was returned as part of the result object. Now, it must be set directly on the mutable context argument.
const executor = createTransactionPlanExecutor({
- executeTransactionMessage: async (message) => {
- const transaction = await signAndSend(message);
- return { transaction, context: { custom: 'value' } };
+ executeTransactionMessage: async (context, message) => {
+ context.custom = 'value';
+ const transaction = await signAndSend(message);
+ return transaction;
}
});
[@solana/instruction-plans] #1293 5c810ac Thanks @lorisleiva! - Reshape the successful SingleTransactionPlanResult factory functions. The successfulSingleTransactionPlanResult helper now accepts a context object (which must include a signature property) instead of a separate signature argument. A new successfulSingleTransactionPlanResultFromTransaction helper is introduced for the common case of creating a successful result from a full Transaction object.
BREAKING CHANGES
successfulSingleTransactionPlanResult renamed to successfulSingleTransactionPlanResultFromTransaction. If you were creating a successful result from a Transaction, update the function name.
- successfulSingleTransactionPlanResult(message, transaction)
+ successfulSingleTransactionPlanResultFromTransaction(message, transaction)
successfulSingleTransactionPlanResultFromSignature renamed to successfulSingleTransactionPlanResult with a new signature. The signature is no longer a separate argument — it must be included in the context object.
- successfulSingleTransactionPlanResultFromSignature(message, signature)
+ successfulSingleTransactionPlanResult(message, { signature })
- successfulSingleTransactionPlanResultFromSignature(message, signature, context)
+ successfulSingleTransactionPlanResult(message, { ...context, signature })
[@solana/instruction-plans] #1309 bd3d5f1 Thanks @lorisleiva! - Add a new planType property to all InstructionPlan, TransactionPlan, and TransactionPlanResult types to distinguish them from each other at runtime. This property is a string literal with the value 'instructionPlan', 'transactionPlan', or 'transactionPlanResult' respectively. It also adds new type guard functions that make use of that new property: isInstructionPlan, isTransactionPlan, and isTransactionPlanResult.
BREAKING CHANGES
InstructionPlan, TransactionPlan, and TransactionPlanResult type guards updated. All factories have been updated to add the new planType property but any custom instantiation of these types must be updated to include it as well.
const myInstructionPlan: InstructionPlan = {
kind: 'parallel',
plans: [/* ... */],
+ planType: 'instructionPlan',
};
const myTransactionPlan: TransactionPlan = {
kind: 'parallel',
plans: [/* ... */],
+ planType: 'transactionPlan',
};
const myTransactionPlanResult: TransactionPlanResult = {
kind: 'parallel',
plans: [/* ... */],
+ planType: 'transactionPlanResult',
};
[@solana/instruction-plans] #1311 91cdb71 Thanks @lorisleiva! - Remove deprecated function getAllSingleTransactionPlans
BREAKING CHANGES
getAllSingleTransactionPlans removed. Use flattenTransactionPlan instead.
- const singlePlans = getAllSingleTransactionPlans(transactionPlan);
+ const singlePlans = flattenTransactionPlan(transactionPlan);
[@solana/instruction-plans] #1276 2fbad6a Thanks @lorisleiva! - Reshape SingleTransactionPlanResult from a single object type with a status discriminated union into three distinct types: SuccessfulSingleTransactionPlanResult, FailedSingleTransactionPlanResult, and CanceledSingleTransactionPlanResult. This flattens the result structure so that status is now a string literal ('successful', 'failed', or 'canceled') and properties like context, error, and plannedMessage live at the top level of each variant.
Other changes include:
message property to plannedMessage on all single transaction plan result types. This makes it clearer that this original planned message from the TransactionPlan, not the final message that was sent to the network.context object from inside the status field to the top level of each result variant. All variants now carry a context — not just successful ones.context attribute to optionally include message, signature, and transaction properties. These properties are meant to hold the actual TransactionMessage, Signature, and Transaction used when the transaction was sent to the network — which may differ from the originally plannedMessage.TransactionPlanResultStatus type.failedSingleTransactionPlanResult and canceledSingleTransactionPlanResult now accept an optional context parameter too.BREAKING CHANGES
Accessing the status kind. Replace result.status.kind with result.status.
- if (result.status.kind === 'successful') { /* ... */ }
+ if (result.status === 'successful') { /* ... */ }
Accessing the signature. The signature has moved from result.status.signature to result.context.signature.
- const sig = result.status.signature;
+ const sig = result.context.signature;
Accessing the transaction. The transaction has moved from result.status.transaction to result.context.transaction.
- const tx = result.status.transaction;
+ const tx = result.context.transaction;
Accessing the error. The error has moved from result.status.error to result.error.
- const err = result.status.error;
+ const err = result.error;
Accessing the context. The context has moved from result.status.context to result.context.
- const ctx = result.status.context;
+ const ctx = result.context;
Accessing the message. The message property has been renamed to plannedMessage.
- const msg = result.message;
+ const msg = result.plannedMessage;
TransactionPlanResultStatus removed. Code that references this type must be updated to use the individual result variant types (SuccessfulSingleTransactionPlanResult, FailedSingleTransactionPlanResult, CanceledSingleTransactionPlanResult) or the SingleTransactionPlanResult union directly.
[@solana/transaction-messages] #1289 b82df4c Thanks @mcintyre94! - Remove the export of BaseTransactionMessage, which was previously deprecated. Use TransactionMessage instead.
@solana/instruction-plans] #1275 f8ef83e Thanks @lorisleiva! - Add missing TContext, TTransactionMessage and/or TSingle type parameters to TransactionPlanResult types and helper functions to better preserve type information through narrowing operations.[@solana/transaction-messages] #1287 f80b6de Thanks @mcintyre94! - Refactor compressTransactionMessageUsingAddressLookupTables to not use BaseTransactionMessage
[@solana/transaction-messages] #1288 986a09c Thanks @mcintyre94! - Refactor transaction-messages package to stop using BaseTransactionMessage
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
[@solana/errors, @solana/instruction-plans] #1264 `d957526` Thanks @lorisleiva! - Exports missing helpers in errors and instruction-plans
@solana/errors, @solana/instruction-plans] #1264 d957526 Thanks @lorisleiva! - Exports missing helpers in errors and instruction-plansNothing published for this version
Nothing published for this version
[@solana/errors] #1260 `08c9062` Thanks @mcintyre94! - Mark the cause deprecated for SOLANA_ERROR__INSTRUCTION_PLANS__FAILED_TO_EXECUTE_TRANSACTION_PL…
[@solana/errors, @solana/instruction-plans] #1253 b4f5897 Thanks @lorisleiva! - Add isX and assertIsX type guard helpers for instruction plans, transaction plans, and transaction plan results
[@solana/errors] #1260 08c9062 Thanks @mcintyre94! - Mark the cause deprecated for SOLANA_ERROR__INSTRUCTION_PLANS__FAILED_TO_EXECUTE_TRANSACTION_PLAN error
[@solana/errors, @solana/instruction-plans] #1254 ba3f186 Thanks @lorisleiva! - Add SuccessfulTransactionPlanResult type with isSuccessfulTransactionPlanResult and assertIsSuccessfulTransactionPlanResult type guards
[@solana/errors, @solana/instruction-plans] #1236 1cc0a31 Thanks @mcintyre94! - Add getFirstFailedSingleTransactionPlanResult, which you can use to get the first failed transaction plan result from a transaction plan result, or throw if none failed
[@solana/errors] #1230 6af7c15 Thanks @mcintyre94! - Add a function unwrapSimulationError, which will return the cause of an error if it is a simulation error. Otherwise it is returned unchanged.
[@solana/instruction-plans] #1245 f731129 Thanks @mcintyre94! - Add flattenInstructionPlan and flattenTransactionPlan functions, that can be used to remove the sequential/parallel structure from these plans. Deprecate getAllSingleTransactionPlans which is superseded by flattenTransactionPlan.
[@solana/instruction-plans] #1233 b174ed5 Thanks @lorisleiva! - Add everyInstructionPlan, everyTransactionPlan and everyTransactionPlanResult functions that can be used to ensure a given predicate holds for all nodes inside their respective plan structures.
[@solana/instruction-plans] #1247 ea97d43 Thanks @mcintyre94! - Add a new function appendTransactionMessageInstructionPlan that can be used to add the instructions from an instruction plan to a transaction message
[@solana/instruction-plans] #1243 60e8c45 Thanks @lorisleiva! - Add transformInstructionPlan, transformTransactionPlan and transformTransactionPlanResult helpers for bottom-up transformation of instruction plan trees.
[@solana/instruction-plans] #1235 a47e441 Thanks @lorisleiva! - Add passthroughFailedTransactionPlanExecution helper function that wraps a transaction plan execution promise to return a TransactionPlanResult even on execution failure. This allows handling execution results in a unified way without try/catch.
[@solana/instruction-plans] #1232 589d761 Thanks @mcintyre94! - Add findInstructionPlan, findTransactionPlan and findTransactionPlanResult functions that can be used to find the plan matching a given predicate
[@solana/instruction-plans] #1256 cccea6f Thanks @mcintyre94! - Fix a bug where a message packer that requires multiple iterations is not correctly added when forced to fit in a single transaction, even if it can fit
[@solana/kit] #1234 7e0377b Thanks @mcintyre94! - Fix a race condition in sendAndConfirmDurableNonceTransactionFactory
[@solana/react] #1210 56433e9 Thanks @rajgoesout! - Return immediately when passing empty array of transactions to useSignTransactions and useSignAndSendTransactions
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Your coding agent can read these notes before it upgrades. Set up the MCP server →