Commonly asked questions when using Alchemy's Transaction History API for on-chain data
What data types can does my query return?
Txn History API supports 3 main types of on-chain data:
1. External transactions
These are top level transactions that occur with a from
address being an external address. This data type includes all the response fields that you can expect to see from an eth_getTransactionReceipt, allowing you to hydrate and populate details about each transaction.
Examples:
- Alice sends 1 ETH to Bob
- Bob writes an on-chain message
2. Token transfers / contract event logs
Transaction History API will automatically look for the target address
emitted as part of token transfer events or other common event ABIs and return all associated logs.
NOTE:
At the moment, the Transaction History API will only return the specific logs that pertain to the the target
address
. We limit the API to this functionality for the time being to reduce the amount of data that developers need to ingest and to help handle airdrops / spam transctions.
Examples:
- Alice user sends ERC-20 token to Bob
- Alice interacts with a DEX to borrow/lend ERC-20 tokens
3. Non-zero value internal transactions
Non-zero value internal transactions are transfers that occur where the fromAddress
is an internal (smart contract) address (eg: a smart contract calling another smart contract or smart contract calling another external address).
Examples:
- A DEX smart contract receives 1 WETH (wrapped Ethereum) and then sends it to the WETH smart contract to be converted to ETH
NOTE on Internal Transactions:
For efficiency, we do not return internal transfers with 0 value as they don't provide useful information without digging deeper into the internal transaction itself. If you are interested in these type of events see our Debug API.
What chains are supported?
Chains | Support |
---|---|
Ethereum Mainnet | ✅ |
Base Mainnet | Coming soon! |
Arbitrum Mainnet | ~End of Q1 |
Optimism Mainnet | ~End of Q1 |
Worldchain Mainnet | ~End of Q1 |
Unichain Mainnet | ~End of Q1 |
BNB Mainnet | ~End of Q1 |
Avalanche Mainnet | ~End of Q1 |
Sei Mainnet | ~End of Q1 |
ZkSync Mainnet | ~End of Q1 |
Sonieum Mainnet | ~End of Q1 |
Solana Mainnet | ~End of Q2 |
How is Transaction History API different from Transfers API?
Transfers API enables developers to retrieve token transfer events and external transactions. Transaction History API extends this functionality, offering comprehensive coverage of all event types a wallet may generate—including deposits, swaps, mints, lending, borrowing, and more (beyond just transfers!) Additionally, it supports non-zero value internal transactions across all supported networks, providing a complete view of on-chain activity.
Under the hood, Transaction History API is powered by a completely different tech stack, designed for faster chain integrations, lightning-fast queries, and enhanced reliability.
How are transactions ordered?
By default, the Transaction History API returns transactions in ascending order (from to newest). At this time, we we do not allow for other orders.
Pricing
Transaction History API Method | CUs |
---|---|
by-address | 120 CUs |
Pagination
There are two cases in which pagination is required:
- If you want a specific number of responses in the API payload
- To specify the exact number of items in the API response, use the
limit
parameter in your request to lock-in the number of responses you wish to receive
- To specify the exact number of items in the API response, use the
- If you receive a response with more than 100 results
- If there are more results than specified in
totalCount
, you will receive a value forafter
in your result which you can then use to fetch the next response load by putting the returnedafter
value in the parameter of your next request. To get all the tansactions for a given address, continue to repeat this process until aafter
is no longer returned (meaning you've fetched all the results 😃)
- If there are more results than specified in
Feature Requests
See something that we don't have? Want to see more filters/sorts, have a need for off-chain data sources 👀 or have a chain request that isn't listed? Grab some time with the product team!