DIA oracle ported to Midnight in Compact
Midnight is not an EVM chain: it uses Compact, its own smart contract language, and a distinct operator and SDK model, so DIA's existing oracle could not be redeployed as-is. Protofire partnered with DIA to stand up a shared oracle stack on Midnight: DIA's oracle contract logic re-expressed in Compact, automated feeders on the MidnightJS SDK aggregating market data from multiple independent sources, a containerized deployment, and health and price-consistency monitoring. The oracle Protofire built and operated served 25 asset price feeds with 5-30 second update cycles, live end to end in 61 days.
“DIA's oracle contracts and feeder infrastructure, proven on other networks, could not be redeployed as-is on a non-EVM chain.”
Why Midnight needed an oracle layer before DeFi could ship
Midnight is a data-protection blockchain in the Cardano and Input Output (IOG) ecosystem, built to let applications handle sensitive data with cryptographic guarantees. Its developer ecosystem was growing, but it had no standardized oracle interface and no shared on-chain market-data layer.
Without one, each team building a DEX or a lending market would have to source, deploy, and operate its own price feeds, duplicating effort, spreading inconsistent data standards, and multiplying the security and maintenance surface. For a chain trying to attract financial applications, that gap was a direct constraint on adoption. The task was to stand up oracle infrastructure every team could use through one interface.
The barrier: DIA's oracle stack does not run on Midnight unchanged
DIA's oracle contracts and feeder infrastructure, proven on other networks, could not be redeployed as-is on a non-EVM chain. The contract logic had to be re-expressed in Compact, and the off-chain feeders that push prices on-chain rebuilt against the MidnightJS SDK rather than an EVM client.
An oracle also holds live production responsibility from day one: if a feeder stalls or a source diverges, downstream protocols price against stale data. So the work was not only a port, but one that had to be observable and operable in production.
How Protofire deployed DIA oracle infrastructure on Midnight
Protofire delivered the oracle as a full stack, not just contracts. The team re-expressed DIA's oracle contract logic in Compact and rebuilt the off-chain feeders on the MidnightJS SDK, pulling market data from multiple independent sources, including DIA and Lumina, so no single provider is a single point of failure.
The deployment was containerized so additional independent operators can run the same feeder image. Monitoring covers feeder health, update frequency, and price consistency across sources, so an operator sees a stalled or diverging feed before a downstream protocol does. Deployment scripts and documentation let operators and developers use the oracle through a standardized interface.
Protofire builds on and operates the DIA (diadata) platform across new chains. Its public forks in the Protofire GitHub org include chain-specific deployments the team built and runs, such as diadata-stacks (Stacks), diadata-alephium (Alephium), and diadata-hydration-bifrost. These are analogous prior deployments on other networks, not the Midnight work itself, but they show the repeatable pattern: take DIA's platform, build the chain-specific scrapers and feeders, and operate them. Midnight applies it in Compact and MidnightJS.
Results
On the DIA-based oracle Protofire built and operated on Midnight:
These figures describe what Protofire built and operated on Midnight. The architecture is designed to scale to 100+ assets without a redesign; that 100+ figure is a design target, not a delivered count. See the proof pack for the public artifacts behind Protofire's DIA oracle engineering.
| Metric | Value |
|---|---|
| Asset price feeds live | 25 |
| Time to deploy end to end | 61 days |
| Oracle update cycle | 5-30 seconds |
| Data sources aggregated | Multiple independent sources (including DIA and Lumina) |
Proof pack
Public forks in the Protofire GitHub org, where Protofire builds on and operates the DIA (diadata) platform:
These repositories evidence Protofire's oracle-porting and feeder engineering on the DIA platform and on other chains, the same pattern applied to Midnight. The Compact contracts and the Midnight feeders are not in a public repository; the Midnight feed count, the 61-day timeline, and the update cycles come from the oracle Protofire built and operated on Midnight.