How to Setup and Navigate TrueBlocks Unchained Index

Aug 30, 2022 | Blockchain

TrueBlocks is a powerful tool designed to enhance the way we access blockchain data, particularly for Ethereum mainnet and EVM-compatible chains. In this guide, we will walk you through the installation process, navigating the command line, utilizing the Unchained Index, and troubleshooting common issues.

Introduction

TrueBlocks aims to simplify the retrieval of blockchain data with features such as:

  • Commands like chifra init and chifra scrape to create an index of address appearances.
  • An optional binary cache for significantly accelerated queries to the RPC.
  • Advanced command-line options enabling easy extraction of logs from smart contracts or viewing ERC-20 holdings.
  • Tools for generating reconciled bank statements and accounting exports.

Installing TrueBlocks

To get started, refer to the installation instructions on our website. It’s an essential step if you’re starting from scratch or updating an existing installation.

Searching Account Histories

To leverage the capabilities of the Unchained Index for searching account histories, follow the steps to get the index.

Command Line Usage

The command-line tool, chifra, serves as your gateway to access various functionalities. You can check all available commands by typing:

chifra --help

Chifra Serve

For those looking to run a simple API for single user environments, use the command:

chifra serve

Keep in mind, this tool is optimized for single-user environments and is not suitable for multi-user cloud setups.

Getting Data

To check your installation status, run the command:

chifra status

If successful, you can run commands like:

chifra blocks 0-100000:10

This command displays every 10th block from the first to the 100,000th.

The Unchained Index

This index allows for rapid access to transaction histories tied to specific addresses. You can build the entire index from scratch or download a pre-constructed snapshot as described in the Indexing Addresses article.

Docker Version

If you prefer using Docker, check out the official Docker version in a separate repository.

Documentation and Linting

Need more detailed documentation? Visit our documentation repository. Moreover, to ensure your code is tidy, install GoLang linters by running:

curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v1.53.3

Troubleshooting

If you encounter issues such as:

Warning: A request to your Ethereum node (http://localhost:8545) resulted in the following error [Could not connect to server].

Make sure you specify a valid rpcProvider by editing your trueblocks.toml file. You can find solutions on our FAQ page. For more insights, updates, or to collaborate on AI development projects, stay connected with fxis.ai.

Conclusion

At fxis.ai, we believe that such advancements are crucial for the future of AI, as they enable more comprehensive and effective solutions. Our team is continually exploring new methodologies to push the envelope in artificial intelligence, ensuring that our clients benefit from the latest technological innovations.

Stay Informed with the Newest F(x) Insights and Blogs

Tech News and Blog Highlights, Straight to Your Inbox