Inspiration
I felt that there was a lack of alternative block explorers for the HGTP ecosystem and missed some features in the official explorer, which is why I decided to create dagscan. I took inspiration of the existing dagexplorer and added several new features to it.
Some features (wallet richlist and reward tracker) were already built by me previously on https://constellation.nebula-tech.io/, so I was already familiar with the network APIs, but I wanted to have a more unified block explorer that incorporates everything in one app and makes it easier to onboard new metagraphs. I completely rebuilt the indexing engine from scratch to make it more reliable, extendable, opensource and deployable through container apps.
What it does
Explore and visualize on-chain data from HGTP and Metagraphs. The main additional features are:
- Enhanced network statistics
- Wallet richlist
- Cross Metagraph reward explorer
- Snapshot data viewer
- Node explorer that includes on-chain uptime statistics. This can be useful for people that want to delegate DAG and helps them in choosing a reliable node.
How we built it
The web interface is built using nextjs 14 and shadcn UI component library. The backend is built using the .NET 8 framework and runs as container apps. All resources are deployed in the Microsoft Azure cloud environment and are deployed using github actions.
Challenges we ran into
I needed to use a combination of the block explorer API and the hypergraph nodes API to retrieve the data I need to index it into my own data store. Not all history is present through the nodes API, so I couldn't use the existing snapshot streaming process to build out my own (historic complete) datastore that way (as it could only start indexing data from a certain ordinal), which might have simplified things. But that also would have required a lot of time to look into, so might be something for a future hackathon :-)
So currently, I'm using a mixture of the existing block explorer and my own datastore (for reward tracking, wallet balances, node uptime tracking and statistics). I'll need to do further load tests and see if a relational SQL datastore is the optimal solution for this app.
Accomplishments that we're proud of
The on-chain node uptime tracking and cross-metagraph reward explorer are the features that I'm proud of the most. More things can be done around this, like creating a ranking for nodes with most uptime and alerting systems when nodes go offline.
What we learned
This is my first web application written in react nextjs 14. I didn't have much experience with any javascript frameworks, so figured the hackathon was a great way to expand my knowledge in that field.
I also learned about the CQRS pattern in the backend for the indexer and use a transactional pipeline for every database transaction to ensure consistency of data.
What's next for DAG Scan
Further enhancing the site and validating the integrity of the data. I also plan on building additional tools around it, like forking it into a more simplified standalone app for metagraphs (so they can use it as a starting point for a custom metagraph explorer/indexer) and creating tools for node operators (like a telegram bot where operators can subscribe to monitor their node and get alerts if it goes offline)

Log in or sign up for Devpost to join the conversation.