This function returns all transaction details based on the provided filter.
This uses Subgraph
Input parameters
interface ITransactionsFilter {
chainId: ChainId; // List of chain IDs to query.
fromAddress?: string; // (Optional) The address from which transactions are sent.
toAddress?: string; // (Optional) The address to which transactions are sent.
startDate?: Date; // (Optional) The start date to filter transactions (inclusive).
endDate?: Date; // (Optional) The end date to filter transactions (inclusive).
startBlock?: number; // (Optional) The start block number to filter transactions (inclusive).
endBlock?: number; // (Optional) The end block number to filter transactions (inclusive).
first?: number; // (Optional) Number of transactions per page. Default is 10.
skip?: number; // (Optional) Number of transactions to skip. Default is 0.
orderDirection?: OrderDirection; // (Optional) Order of the results. Default is DESC.
}
type ITransaction = {
block: number;
txHash: string;
from: string;
to: string;
timestamp: number;
value: string;
method: string;
};