The Graph Builders Newsletter - 24

šŸ—ļø Subscribe to The Graph Builders Newsletter šŸ—ļø

gm web3 builders,

Welcome to The Graph Builders Newsletter #24 review of Dec 2024! šŸ—ļø

Happy New Years!

This year has been a year of growth for The Graph! From a successful Sunrise of The Graph Network to many new features that were released supporting the builder experience!

Here’s just a few of the builder-focused releases and updates that came out in 2024:

  • 43 (!) new supported networks (mainnet and testnets) added to The Graph
  • Declarative eth_calls allows faster parallel execution of eth_calls
  • hasCode() Ā easily detects contracts vs. EOAs in the mappings
  • Topic Filters / Indexed Argument Filters allows for more precise filtering
  • Publish Subgraphs directly from the CLI
  • Networks Registry allows for quick adding of chains to graph-node through a PR
  • Subgraph Pruning with indexerHints (improved query speed)
  • getBalance() easily gathers real-time wallet balances in the mappings
  • Timeseries + Aggregations easily perform automated computations
  • Substreams as Subgraph Triggers
  • Substreams-powered Subgraph easy deployment with codegen
  • graph-cli redesign as seen in v0.93.3 (see below! ā¬‡ļø)

Cheers to 2024 and let’s welcome 2025 with better building!

GraphCLI Update v0.93.3

graph-cli has had a redesign šŸ‘€ Update your cli and check it out!

yarn global add @graphprotocol/graph-cli

npm i -g @graphprotocol/graph-cli/@latest

New features:

1. Add chains easily with new Networks Registry. No more waiting for a cli update to add a chain!

2. FullTextSearch chains when spinning up a new subgraph

3. Many small experience improvements

Read the full changelog for more details.

Learn How to Index Factory Pattern Smart Contracts

Factory pattern smart contracts are a fundamental part of crypto. Learn how to index these smart contracts with a tutorial on Data Source Templates from Hudson Headley of Perpetual Organization Architect!

New Subgraph Best Practices Released

Optimize your indexing, querying, and developer experience with two new Subgraph Best Practices!

Best Practice 5: Timeseries & Aggregations

Use timeseries entities and aggregations for faster queries and simplified mapping logic.

# Example: Timeseries entity
type Data @entity(timeseries: true) {
id: Int8!
timestamp: Timestamp!
price: BigDecimal!
}
# Example: Aggregation entity
type Stats @aggregation(intervals: ["hour", "day"], source: "Data") {
id: Int8!
totalPrice: BigDecimal! @aggregate(fn: "sum", arg: "price")
}
schema.graphql

Best Practice 6: Grafting for Hotfixes

Deploy a new subgraph that can start indexing from another ā€˜base’ subgraph’s database.

features:
- grafting
graft:
base: QmBaseDeploymentID
block: 12345677
subgraph.yaml

Implement all six Subgraph Best Practices with all of your subgraphs to optimize your subgraph and developer experience:

ā©https://thegraph.com/docs/en/cookbook/pruning/

ā©https://thegraph.com/docs/en/cookbook/derivedfrom/

ā©https://thegraph.com/docs/en/cookbook/immutable-entities-bytes-as-ids/

ā©https://thegraph.com/docs/en/cookbook/avoid-eth-calls/

ā©https://thegraph.com/docs/en/subgraphs/cookbook/timeseries/

ā©https://thegraph.com/docs/en/subgraphs/cookbook/grafting-hotfix/

Substreams + Solana Indexing Feature Updates

New features for @Solana developers who are utilizing Substreams from @graphprotocol to enhance their dev experience!

  1. Real-time and Historical Account Changes.

Simply hit our new endpoint to stream account changes block by block, unlocking insights and enabling more robust application logic.

  1. Anchor IDL Integration

Create Substreams projects directly from an Anchor IDL in JSON format within the Dev Container.

More details in StreamingFast’s latest blog.

ETHIndia 2024 Hackathon Winners

The Graph was out in force for ETHIndia 2024! Check out the winners that built on The Graph!

šŸ† 1st Prize: ZK-OS

A Web3 terminal interface unifying subgraph deployment, monitoring, and decentralized storage with zero-knowledge proofs.

🄈 2nd Prize: Meme Agent

Revolutionizing memecoin creation, trading, and sniping with AI-powered precision.

šŸŽ‰ Pool Prizes:

šŸŽ¶ Fanbase

A ticketing protocol redefining fairness with Spotify OAuth and transparent resale royalties.

šŸ“… Second Saturday

A blockchain-powered Monopoly-like game launching new challenges every month.

šŸ’Ŗ StakeFit

Bet on your fitness goals with on-chain progress tracking and staking rewards.

šŸ’° FOMOWallet

An AI-assisted crypto prediction wallet leveraging blockchain and zkEVM technology.

The Graph Developer Survey

Building The Graph Network is a collaborative effort, and the core devs would love to hear your feedback!


Thank you for reading and happy new years! Let’s start 2025 with the right foot forward! šŸ’Œ

Marcus Rein

Developer Relations

Edge & Node, working on The Graph

About The Graph

The Graph Ā is the leading indexing and query protocol powering the decentralized internet. Since launching in 2018, it has empowered tens of thousands of developers to effortlessly buildĀ  Subgraphs Ā and leverageĀ  Substreams Ā across countless blockchains, including Ethereum, Solana, Arbitrum, Optimism, Base, Polygon, Celo, Soneium, and Avalanche. With powerful tools like Substreams and Token API, The Graph delivers high-performance, real-time access to onchain data. From low-latency indexing to rapid token data, it serves as the premier solution for building composable, data drive dapps.

Discover more about how The Graph is shaping the future of decentralized physical infrastructure networks (DePIN) and stay connected with the community. Follow The Graph onĀ  X,Ā  LinkedIn,Ā  Instagram,Ā  Facebook,Ā  Reddit,Ā  Farcaster Ā andĀ  Medium. Join the community on The Graph’sĀ  Telegram, join technical discussions on The Graph’sĀ  Discord.

The Graph Foundation Ā oversees The Graph Network.Ā  Edge & Node,Ā  StreamingFast,Ā  Semiotic Labs,Ā  GraphOps andĀ  Pinax Ā are five of the many organizations within The Graph ecosystem.


Category
Developer Corner
Published
January 7, 2025

Marcus Rein

View all blog postsā