feat: handle `loadedAddresses` field in tx meta responses (#27065)
feat: handle loadedAddresses field in tx meta responses
This commit is contained in:
parent
ceb8f099f2
commit
369b6b1828
|
@ -804,6 +804,14 @@ export type TokenBalance = {
|
||||||
*/
|
*/
|
||||||
export type ParsedConfirmedTransactionMeta = ParsedTransactionMeta;
|
export type ParsedConfirmedTransactionMeta = ParsedTransactionMeta;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Collection of addresses loaded by a transaction using address table lookups
|
||||||
|
*/
|
||||||
|
export type LoadedAddresses = {
|
||||||
|
writable: Array<PublicKey>;
|
||||||
|
readonly: Array<PublicKey>;
|
||||||
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Metadata for a parsed transaction on the ledger
|
* Metadata for a parsed transaction on the ledger
|
||||||
*/
|
*/
|
||||||
|
@ -824,6 +832,8 @@ export type ParsedTransactionMeta = {
|
||||||
postTokenBalances?: Array<TokenBalance> | null;
|
postTokenBalances?: Array<TokenBalance> | null;
|
||||||
/** The error result of transaction processing */
|
/** The error result of transaction processing */
|
||||||
err: TransactionError | null;
|
err: TransactionError | null;
|
||||||
|
/** The collection of addresses loaded using address lookup tables */
|
||||||
|
loadedAddresses?: LoadedAddresses;
|
||||||
};
|
};
|
||||||
|
|
||||||
export type CompiledInnerInstruction = {
|
export type CompiledInnerInstruction = {
|
||||||
|
@ -1794,6 +1804,11 @@ const TokenBalanceResult = pick({
|
||||||
uiTokenAmount: TokenAmountResult,
|
uiTokenAmount: TokenAmountResult,
|
||||||
});
|
});
|
||||||
|
|
||||||
|
const LoadedAddressesResult = pick({
|
||||||
|
writable: array(PublicKeyFromString),
|
||||||
|
readonly: array(PublicKeyFromString),
|
||||||
|
});
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @internal
|
* @internal
|
||||||
*/
|
*/
|
||||||
|
@ -1821,6 +1836,7 @@ const ConfirmedTransactionMetaResult = pick({
|
||||||
logMessages: optional(nullable(array(string()))),
|
logMessages: optional(nullable(array(string()))),
|
||||||
preTokenBalances: optional(nullable(array(TokenBalanceResult))),
|
preTokenBalances: optional(nullable(array(TokenBalanceResult))),
|
||||||
postTokenBalances: optional(nullable(array(TokenBalanceResult))),
|
postTokenBalances: optional(nullable(array(TokenBalanceResult))),
|
||||||
|
loadedAddresses: optional(LoadedAddressesResult),
|
||||||
});
|
});
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -1844,6 +1860,7 @@ const ParsedConfirmedTransactionMetaResult = pick({
|
||||||
logMessages: optional(nullable(array(string()))),
|
logMessages: optional(nullable(array(string()))),
|
||||||
preTokenBalances: optional(nullable(array(TokenBalanceResult))),
|
preTokenBalances: optional(nullable(array(TokenBalanceResult))),
|
||||||
postTokenBalances: optional(nullable(array(TokenBalanceResult))),
|
postTokenBalances: optional(nullable(array(TokenBalanceResult))),
|
||||||
|
loadedAddresses: optional(LoadedAddressesResult),
|
||||||
});
|
});
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in New Issue