Consuming the OracleConsuming the Feeds

Consuming the Feeds

Every five minutes Mecone signs each of its eight public indices into a signed official round — the one source of truth, an immutable record you can verify offline against one pinned public key. The signed round is transport-neutral: every rail below carries that same round, and none of them can create or alter one.

Choosing your integration path

You are…Read thisWhat you get
A venue settling perps, or anyone who must not trust the transportSigned official rounds — HTTPS pull + offline verificationThe signed round itself: exact value, official timestamps, verifiable end-to-end. Fresh rounds need a partner token; 24h-delayed rounds and all verification material are open.
An EVM venue that already reads oracles on-chainA. On-chain (below)All eight published feeds live on Arbitrum Sepolia for testnet wiring. At mainnet onboarding the publisher carries verified signed rounds on-chain at their official effective time, so your contract reads the signed round itself.
A dashboard, terminal, or anything displaying a live priceB. REST (below)The continuous live index (the v1 snapshot value; legacy index_now) — more granular than official rounds, for display. Settle against official rounds, not this.

All paths serve the same eight production indices. Fresh signed rounds are a licensed pull (partner token, metered per read); rounds older than 24 hours and everything verification needs — anchor, keysets, registry, verifier kit — stay open, because the signed round is a portable artifact and verification uses public material only.

A. On-chain (EVM venues)

Reading a Mecone index on-chain is a single call against the oracle contract:

  • Feed id = keccak256("MECON_<symbol>"): the encoded asset id is the keccak hash of the plaintext symbol.
  • Call getTemporalNumericValueV1(bytes32 id) on the oracle contract; it returns { uint64 timestampNs, int192 quantizedValue }.
  • Values are quantized ×10¹⁸ (divide by 1e18 to de-quantize).
  • Dollar valuations are published in billions of USD so they quantize in line with the macro percentages: MOAI reading ~921 means $921B. Macro percentage feeds read directly (2.13 = 2.13%).
  • The $ unit differs by transport. The Mecone API returns valuations in raw dollars while the on-chain rail carries them in billions — API 921000000000 and on-chain 921e18 are the same $921B. % and $/hr feeds are not rescaled between transports.
struct TemporalNumericValue { uint64 timestampNs; int192 quantizedValue; }
interface IOracleFeed {
    function getTemporalNumericValueV1(bytes32 id) external view returns (TemporalNumericValue memory);
}
 
// Read US GDP:
bytes32 id = keccak256("MECON_MGDP");
TemporalNumericValue memory v = IOracleFeed(ORACLE).getTemporalNumericValueV1(id);
int256 gdp = int256(v.quantizedValue); // 1e18-scaled -> 2.13% = 2.13e18

We ship a reference consumer (MeconeStorkConsumer) that maps a short market key to its feed id and adds a tight staleness window on top of the oracle’s, plus a minimal reference perp that settles against it, both live on testnet (quickstart).

Testnet today, signed rounds on-chain at mainnet

The eight published feeds are live on Arbitrum Sepolia for wiring and integration testing. At mainnet onboarding we provision a dedicated publisher key and deploy the publisher that carries signed official rounds on-chain — pulling each feed’s latest round, verifying it against the pinned root anchor with the same kit partners use, and publishing it on-chain at the round’s official effective time — so the value your contract reads is the signed round itself. For settlement-grade values today, pull them from the signed-rounds service.

The on-chain rail is a pull oracle

The on-chain value for a feed updates when someone submits the signed payload (updateTemporalNumericValuesV1, fee via getUpdateFeeV1). Venues either run the open-source chain pusher, or submit the signed update atomically in the transaction that consumes it. For pilots we run the pusher for you.

Feed ids (same on mainnet and testnet)

SymbolAsset idFeed id (bytes32)
MGDPMECON_MGDP0xc1b9ff58ed9bcf48022dd2c866207d7d4300802f6b4582b3b096817be2f233f0
MCPIMECON_MCPI0x09e722e06a32236b1653a32d00d58f38d9d52156cce4e510edcf6c0be3dc2e22
MUNEMPMECON_MUNEMP0xc960b63f8aa14945c9c86e08309fe2686b415058c1dd3677bf8538c19f593cda
MOAIMECON_MOAI0xc0be26c2318039c5bd6715deae6f49f873ba7e5226529659119338c137f2a192
MANTHMECON_MANTH0x9b9da9435546ad30be4a18c1afd6fdfd202c1d57088bfb21bd1dc2d9f9ca7e80
MH100MECON_MH1000xf9c19de6bf85ab849b0c6474707ddbf45c392ce1905e5ead5d33f6cd02ca480d
MH200MECON_MH2000xc6de3d7f8dd73811950a285630988490e97335189e63fff663406305eeaf68a3
MB200MECON_MB2000x0b7e68829242d67d1973f738f82851c7f65827d774d20d3922e4960dfee55745

Oracle contract addresses per chain: docs.stork.network/resources/contract-addresses/evm.

B. Off-chain feed

If you post your own oracle price (an internal oracle, or a HIP-3 style deployer feeding an L1), pull the value from the versioned Mecone API and post it:

curl https://api.mecone.trade/api/v1/indices/us-gdp/snapshots/latest
# -> { "data": { "scope": "live_indicative", "value": { "decimal": "2.12…", "unit": "%", … }, … } }

value is the index level in its natural unit, with a wire-stable decimal string beside the JSON number; a snapshot is explicitly live_indicative, so settle against rounds/latest or the signed rounds, not against it. The legacy curl https://api.mecone.trade/api/markets/us-gdp (index_now) contract remains unchanged for existing pilots. Full field reference: API.

C. Signed official rounds (verifiable)

For settlement, audit, or any integration where you must not trust the transport: every five minutes each index becomes a cryptographically signed official round — the round id is the EIP-712 digest of the signed body, the signer is authorized by a keyset attested by Mecone’s pinned root key, and a self-contained ~250-line verifier is served by the endpoint itself. One public value to pin, three commands to verify a live production round: Signed Official Rounds.