Trading workflow · Free reference examples

Two Market Data Feeds Disagree: Which Should You Refresh?

Refresh only Feed B. In this synthetic case both feeds cover the same asset and metric. Feed A is 10 seconds old, Feed B is 8 minutes old, and the freshness limit is 90 seconds. Keep Feed A and refresh B before comparing values.

Replay: refresh both feeds or only Feed B?

Use the same fixed snapshots in both approaches. A full refresh plans two calls; the timestamp check plans one call, to Feed B.

Download the free replay script, then run node replay.mjs with Node.js 18 or newer. The script checks its output against the expected result offline. It uses no API key or wallet, makes no actual feed calls, and does not measure latency or fees.

Inspect the standalone source, input, and expected output on GitHub.

Use the source observed_at field to measure age. When it is missing, an HTTP response receipt time cannot prove the quote was observed at that time.

Find the market data check for your situation

Each question links to its own free synthetic input and result. No wallet or account is needed.

Two market data feeds disagree: which source should I refresh?

Refresh only Feed B. Both feeds describe the same asset and metric. Feed A is 10 seconds old; Feed B is 8 minutes old and exceeds the 90-second limit.

Read this case (free JSON)

Market data timestamp missing: can I still use the quote?

Do not substitute the HTTP response time for the quote's observation time. In this example, requery Feed B only and hold its quote if its observation time is still unknown.

Read this case (free JSON)

Same token symbol on different chains: can I compare prices?

Hold the comparison. A shared symbol and fresh timestamps do not establish that two feeds refer to the same asset. Resolve the chain and asset identifiers first.

Read this case (free JSON)

Looking up liquidity, an interrupted order, or an on-chain status instead? Find the right source in the trading bot search map.

Choosing an API or checking a lost paid response? Check what is still unconfirmed before buying or retrying.

After fetching data, before using it.

Keep this check local. Use it when a new snapshot arrives or when the last one expires under your policy. If a prior result is still fresh and the inputs and policy are unchanged, reuse it.

To identify exactly which market data source to refresh, first match chain_id, asset_id, quote_unit, and metric. Then compare decision_time - observed_at with max_age_seconds for each matching feed. Refresh only the feeds with missing, invalid, future, or stale observation times; never substitute HTTP receipt time.

This guide runs only fixed synthetic inputs. It does not verify quotes, accept your snapshots, or recommend or execute trades. Freshness is not correctness.

If both fresh quotes still disagree, first inspect the ambiguous feed's local schema or source documentation: does price mean a last trade, a bid/ask midpoint, or another metric? If you cannot establish comparable definitions and observation conditions, hold the comparison instead of fetching another price.

See where four agents paused in the fresh quote case.

Two feeds with the same upstream venue do not independently confirm one another. If the feeds describe different chains or assets, resolve their identities before comparing.

Free local guidance. Free remote branch decisions.

Use a remote decision only when the local check does not settle your question.

Free: use the workflow locally

Compare the fixed cases and use the rule in your own routine. No account or payment is needed.

Read the free JSON examples

Optional free: Mission Gate

If a separate reversible investigation keeps repeating, local limits do not settle the choice, and new evidence might justify one more step, get an external recommendation and decision receipt. 0 USDC, no wallet or required feedback. It does not validate market data.

See when to use Mission Gate · Try its examples free