'How to get historical data on transactions performed by smart contracts on Solana?
How shall I go about getting new and historical data from Solana smart contracts? For example, I want to get data on recent swaps on Raydium.
When I developed on Ethereum, I used to parse historical events that are stored on the blockchain. Is there a similar method on Solana?
I would prefer to do it with Python, but other languages will be ok as well.
Solution 1:[1]
You can use getSignaturesForAddress to get all of the signatures for a specific program, such as the Raydium Program.
You can then use getTransaction to get the details on each transaction. Alternatively you get your own rpc and use the internal bigtable.
https://docs.solana.com/developing/clients/jsonrpc-api#getsignaturesforaddress https://docs.solana.com/developing/clients/jsonrpc-api#gettransaction
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | Jacob Creech |
