Unlocking TRUF.Network’s Data Powering Your Next Big Idea
Understanding data types powering the TRUF.Network and what you can build with it
The TRUF.Network is your gateway to a vast ecosystem of economic data, delivered through our Truthful Data Oracle system. Whether you’re a developer crafting cutting-edge tools or an innovator exploring financial insights, our data streams offer the raw materials to bring your vision to life. Let’s dive into what makes our data tick, what you can build with it, and how to get started.
Data Streams: Primitive or Composed
At the heart of TRUF.Network lie two core data types: Primitive Streams and Composed Streams.
- Primitive Streams are the unrefined building blocks—raw, granular feeds pulled straight from decentralized sources. Think of them as the foundational data points, like daily commodity prices or housing trends, untouched and ready for your use.
- Composed Streams, conversely, are the refined output—custom calculations processed on-chain using our trustless compute layer. These are aggregates or transformations of Primitive Streams, such as a real-time inflation index or a tokenized asset metric.
Primitive Streams offer flexibility for raw analysis, while Composed Streams deliver pre-processed insights, saving you computation time if you need ready-made metrics. Both data types are rooted in the same decentralized, verifiable data pipeline, ensuring transparency and integrity. You can browse through all deployed data streams on our Explorer platform.
Building with TRUF Data
TRUF.Network’s data isn’t just numbers—it’s fuel for innovation. Here are some of the use cases you can use our data with:
- Inflation-Proof Stablecoins: Anchor a flatcoin to real-time inflation metrics, like Nuon does on Truflation.com, to hedge against purchasing power erosion in volatile markets.
- Diversified Indexes: Craft investment baskets—like those on the Index.fun—tracking equities, bonds, or even a Pelosi Index, blending TRUF’s economic feeds for user-friendly exposure.
- Prediction Markets: Build platforms that forecast commodity prices or economic shifts, leveraging sub-second updates for high-stakes accuracy.
- Tokenized Real-World Assets (RWAs): Use housing or commodity streams to create synthetic markets, bridging DeFi with tangible value.
- Lending Protocols: Enhance risk models with real-time economic indicators, boosting transparency for borrowers and lenders alike.
From powering DeFi tools to enabling data-driven trading strategies, TRUF data opens doors to applications that demand precision and trust. What’s your next move?
Consuming TRUF Data
import { TrufClient } from "@trufnetwork/sdk"
async function getStreamData(streamId: string) {
const client = new TrufClient({ network: "mainnet" })
const data = await client.streamRegistry.fetchStream(streamId)
console.log("Fetched Stream:", data)
return data
}
// Pull a sample stream
getStreamData("COMMODITY_GOLD_DAILY")
This is a simple example that connects to the TRUF.Network and queries a primitive stream by its unique ID. Check out the full SDK implementation and setup guides at docs.truf.network.
Let’s Build the Future Together
TRUF.Network hands you the tools to turn economic data into actionable innovation. Whether you’re prototyping a niche index or scaling a DeFi powerhouse, our streams are here to back you up. Join the growing community of builders on Discord and let us know, what will you create with TRUF.Network.