Skip to content
EN

← Return to Guides

Developer data confidenceTrail HeatAI agents

Agent Data Confidence: How FarmDash Labels Trail Heat, Mock Data, and API Limits

A practical guide to FarmDash data_quality, scoring_methodology, mock mode, and structured error contracts for agent-safe DeFi research.

By FarmDash Pioneers · Published 2026-05-26 · Updated 2026-11-20

TLDR: Agent APIs should not pretend every answer has the same certainty. FarmDash now exposes data_quality, scoring_methodology, structured errors, and a public status endpoint so agents can tell the difference between live data, catalog-derived data, masked Scout previews, and deterministic mock fixtures.

Capability Canonical status
spot.USER_SIGNED operational
spot.BOUNDED_AUTONOMOUS operational
futures.USER_SIGNED operational
futures.BOUNDED_AUTONOMOUS operational
solana.USER_SIGNED operational
solana.BOUNDED_AUTONOMOUS operational
ERC4337_SERVER_SUBMISSION operational
GENERIC_SERVER_INTENT_EXECUTION operational
MEE operational
ACP deployment_prerequisite

Read canonical readiness and live deployment/request gates before execution. These rows are conditional capability contracts, not funded-production proof. USER_SIGNED requires fresh human authorization. Bounded execution requires a separate revocable domain policy and customer-agent-local signature per action, plus exact identity, scope, validity, simulation/research, risk/budget and replay checks. Commercial access cannot supply signing authority; FarmDash never receives the customer key.

Why Agents Need Confidence Labels

Human users can often spot uncertainty in a dashboard. Agents cannot. They need the API to say plainly:

  • this field is live
  • this field is catalog-derived
  • this field is masked by tier
  • this field is a mock fixture
  • this method is heuristic, not statistically validated
  • this endpoint is unavailable or missing dependencies

Without that contract, agents may overstate confidence, fabricate missing fields, or pass weak research into an execution tool.

FarmDash solves this by putting confidence metadata directly into agent-facing responses.

The Core Fields

data_quality

data_quality describes where the data came from and how much trust the agent should place in it.

Common confidence levels:

Confidence Meaning Agent posture
high live upstream data is present safe to summarize, still disclose risks
medium useful but catalog-derived or partially derived present as directional
low important upstream fields are missing caveat heavily and avoid strong recommendations
demo deterministic mock data never use for production recommendations

Example:

{
  "data_quality": {
    "confidence": "medium",
    "mode": "catalog",
    "sources": ["FarmDash curated protocol catalog"],
    "caveats": [
      "This record is catalog-derived.",
      "Trail Heat is a heuristic ranking signal and should be paired with risk, liquidity, and user-fit checks."
    ]
  }
}

scoring_methodology

scoring_methodology tells the agent how a score was generated.

Trail Heat responses identify whether they are:

  • static-catalog-v1
  • live-defillama-v1
  • masked for Scout tier
  • heuristic and not statistically validated

That last point matters. Trail Heat is a ranking signal, not a guaranteed yield model or allocation instruction.

developer_sandbox

developer_sandbox tells agent builders when a non-live mock mode exists.

FarmDash mock mode can be enabled with:

?mock=true
?mode=mock
X-FarmDash-Mock: true
Authorization: Bearer fd_sandbox_mock

The important constraint: mock mode is for compatible read-only development endpoints. It is not a trading simulator and must not be used for production recommendations.

How Trail Heat Responses Differ by Tier

Scout

Scout access is route-specific. The October 5, 2026 /api/v1/agent/protocols response was a truncated catalog preview: tier=scout, status=limited, count=3, masked_for_tier=true, and data_quality identifying catalog_preview, with encrypted numerical fields. It is not the full unmasked dataset or live quantitative Trail Heat. Eligible free routes still use the published quota; qualifying paid access follows each route policy.

Agent behavior:

  • tell the user it is a preview
  • do not invent masked values
  • offer upgrade, x402 unlock, or a lower-scope answer

Pioneer and Syndicate

Paid tiers receive the full unencrypted dataset where the endpoint allows it.

Agent behavior:

  • preserve asOf or timestamp context when available
  • quote confidence labels in summaries
  • keep Trail Heat separate from final execution decisions

Mock mode

Mock mode returns deterministic fixtures with confidence: "demo".

Agent behavior:

  • use for SDK tests, onboarding, and integration flows
  • never use for live DeFi recommendations
  • never hand mock output to execution tools

The Public Status Endpoint

FarmDash exposes a public feature contract at:

/api/v1/agent/status
/api/v1/agent/feature-status

This endpoint gives agents:

  • feature readiness
  • tier gates
  • structured error expectations
  • data confidence rules
  • scoring methodology versions
  • mock-mode instructions

Agents should call this during setup, not after a failure.

Structured Errors Beat Guesswork

FarmDash agent errors use machine-readable fields so the caller can distinguish retryable transport/provider failures from policy, capability, quota, and payment states:

{
  "ok": false,
  "error": "rate_limit",
  "code": "rate_limit_exceeded",
  "message": "Scout daily limit exceeded.",
  "instruction": "STOP_RETRYING",
  "retry_same_request": false,
  "retryable": false,
  "request_id": "req_...",
  "rate_limit": {
    "tier": "scout",
    "used": 30,
    "limit": 30,
    "remaining": 0
  }
}

This lets SDKs and agents handle failures safely:

  • retry only when retryable is true and the operation itself is safe to replay
  • obey STOP_RETRYING and retry_same_request: false on exhausted unpaid access
  • show request_id for support and correlation
  • downgrade to mock mode only for development on routes that explicitly support it
  • preserve stale/cached age instead of silently calling old data live
  • avoid fabricating when a feature, provider, verifier, or authority prerequisite is not ready

Recommended Agent Rules

Use these rules in every FarmDash integration:

  1. If confidence is demo, do not recommend or execute.
  2. If confidence is low, ask for confirmation or gather more evidence.
  3. If a field is masked, say it is masked.
  4. If scoring is heuristic, do not describe it as a forecast.
  5. If a 402 response appears, present wait, x402, and upgrade choices.
  6. If the next step changes wallet state, hand off to the correct capability and require the authorization model published by live status: a fresh signature for supervised routes or an already-approved bounded session/delegation where that route explicitly supports it.
  7. Never infer execution from tool discovery, preparation state, a submitted hash, or payment success.
  8. Preserve request IDs, timestamps, provider identity, and evidence provenance when handing work between agents.

Why This Improves the Product

Data confidence is not just a compliance layer. It makes FarmDash more useful.

For users, it creates honest recommendations. For agents, it prevents brittle tool chains. For developers, it gives testable contracts. For FarmDash, it makes every API and MCP surface easier to monetize without overclaiming what the data can prove.

Freshness Policies & Timestamp Separation

Modern agent pipelines fail when an API collapses response time, cache-retrieval time, and upstream observation time into a single timestamp—or treats an HTTP 200 stale cache hit as execution-grade market data. FarmDash separates these explicitly across live-intelligence routes:

Field / Policy Meaning Agent Decision Rule
generatedAt Timestamp when FarmDash constructed the HTTP response Never treat as proof of fresh market state.
retrievedAt Timestamp when FarmDash actually fetched the upstream dataset Use with cacheAgeMs to evaluate freshness.
observedAt / asOf Upstream provider's market observation timestamp (null when upstream omits it) Never invent a provider timestamp when null.
Supply Master freshness.executionAdmissible true inside 5m hot TTL; false during 5m–30m bounded stale fallback (stale=true, degraded=true); HTTP 503 past 30m Permit stale pools for research/comparison only; block execution decisions on stale yields.
OnChainOracle & Risk Sentinel outage Returns null (never synthetic 0% depeg); DeFiLlama fallback cache is hard-bounded to 256 FIFO entries / 15s TTL Treat null or gasUnknown as blocking uncertainty, never as "safe."
Hedge Warden liveIntelligenceSummary Separates generatedAt, retrievedAt, fundingObservedAt: null, and optionsSkewAsOf; returns null carry when funding is unavailable Never render unavailable funding carry as $0.

Frequently Asked Questions

What is the difference between confidence: "demo" and confidence: "low"?

demo indicates deterministic sandbox mock fixtures returned when mock mode is enabled; agents must never use demo responses for live recommendations or execution. low indicates a real response where critical upstream fields are missing, degraded, or masked—requiring explicit caveats and additional verification before acting.

Why does Supply Master return HTTP 200 with stale: true instead of always returning 503?

Between 5 minutes and 30 minutes after the last successful DeFiLlama yields fetch, Supply Master serves bounded stale pools for research and comparison while marking stale: true, degraded: true, and freshness.executionAdmissible: false with the original retrievedAt timestamp. Past 30 minutes or on a cold cache, it fails closed with HTTP 503.

Does FarmDash fabricate upstream timestamps when a provider does not return one?

No. When an upstream endpoint (such as DeFiLlama's bulk /protocols or /pools endpoints or Hyperliquid's metaAndAssetCtxs) omits observation timestamps, FarmDash reports observedAt: null or fundingObservedAt: null alongside the actual FarmDash retrievedAt timestamp.

How should an agent behave when Scout tier masks Trail Heat fields?

Report explicitly that the response is a limited Scout catalog preview (masked_for_tier: true), never invent or interpolate hidden numeric scores, and offer the user the documented options: wait, upgrade to Pioneer/Syndicate, or authorize a one-off x402 unlock where supported.

Primary Sources & Related FarmDash Docs

Continue researching