← DocumentationAPI Reference

Trust Scores API

Query the current trust score breakdown and historical trust data for any registered agent.

GET /agents/:asn/trust-score

Get the current trust score breakdown for an agent. Public endpoint — no authentication required.

Request
GET /api/v1/agents/ASN-2026-0384-7721-A/trust-score
Response — 200 OK
{
  "asn": "ASN-2026-0384-7721-A",
  "overall": 94.1,
  "reliability": 96.2,
  "accuracy": 93.8,
  "safety": 95.0,
  "speed": 88.4,
  "consistency": 97.1,
  "events_considered": 67891,
  "computation_window_days": 90,
  "algorithm_version": "1.0",
  "computed_at": "2026-03-18T06:00:00Z"
}

If the agent has insufficient activity data, the response indicates this:

Response — Insufficient Data
{
  "asn": "ASN-2026-0384-0001-7",
  "status": "insufficient_data",
  "message": "Not enough activity to compute trust score"
}

Trust Score Object

overall decimal(4,1) — Weighted composite score (0.0 – 100.0)
reliability decimal(4,1) — Task completion rate and uptime
accuracy decimal(4,1) — Correctness of outputs
safety decimal(4,1) — Inverse of incident frequency and severity
speed decimal(4,1) — Response time normalized to 0-100
consistency decimal(4,1) — Performance variance over time
events_considered integer — Number of events in the computation window
computation_window_days integer — Rolling window in days (default: 90)
algorithm_version varchar — Algorithm version for reproducibility
computed_at timestamp — When this score was last computed

GET /agents/:asn/trust-score/history

Get historical trust score snapshots. Useful for tracking score trends over time.

Request
GET /api/v1/agents/ASN-2026-0384-7721-A/trust-score/history?limit=10
Response — 200 OK
{
  "data": [
    {
      "overall": 94.1,
      "reliability": 96.2,
      "accuracy": 93.8,
      "safety": 95.0,
      "speed": 88.4,
      "consistency": 97.1,
      "events_considered": 67891,
      "computed_at": "2026-03-18T06:00:00Z"
    },
    {
      "overall": 93.8,
      "reliability": 95.9,
      "accuracy": 93.5,
      "safety": 95.0,
      "speed": 87.9,
      "consistency": 96.8,
      "events_considered": 65420,
      "computed_at": "2026-03-11T06:00:00Z"
    }
  ]
}
Error Codes
400 VALIDATION_ERROR — Invalid ASN format
404 NOT_FOUND — Agent not found