{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/swarm-tips/json-schema/swarm-tips-attestation-response-schema.json",
  "title": "AttestationResponse",
  "description": "VOW v1 — VOW — Verifiable On-chain Work wire format (see\n`swarm-tips-repo/docs/specs/vow-v1.md`).\n\nReturned by `GET /tasks/{id}/attestation`. A portable, structured\nattestation that off-chain verifiers (the `@swarm-tips/client/vow`\nTypeScript and Python reference implementations) consume to confirm an agent\ncompleted a task and earned a composite score, without trusting this\norchestrator. The on-chain account (referenced by `account` +\n`account_kind` + `network`) is the source of truth — the verifier\nre-reads it to confirm. Numbers that can exceed 2^53-1 (`task_id`,\n`composite_score`, `score_max`) are emitted as decimal STRINGS.",
  "x-generated": "2026-11-25",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/swarm-tips-openapi.json#/components/schemas/AttestationResponse",
  "properties": {
    "account": {
      "description": "Base58 address of the on-chain account holding the verification result\n(v1 — renamed from `task_pda`). The verifier re-reads it from `network`.",
      "type": "string"
    },
    "account_kind": {
      "description": "Anchor account discriminator name (v1). `\"Task\"` for Shillbot.",
      "type": "string"
    },
    "agent": {
      "type": "string"
    },
    "client": {
      "type": "string"
    },
    "composite_score": {
      "description": "Decimal string of the fixed-point composite score (v1 — string).",
      "type": "string"
    },
    "content_hash": {
      "description": "Hex-encoded (lowercase) sha256 of the off-chain campaign brief.",
      "type": "string"
    },
    "content_id_hash": {
      "description": "Hex-encoded (lowercase) sha256 of the submitted content_id.",
      "type": "string"
    },
    "extensions": {
      "description": "Protocol-specific extension envelope (v1). Verifiers tolerate unknown\nkeys; empty object by default. Always emitted."
    },
    "network": {
      "description": "Solana cluster the on-chain account lives on (`\"mainnet\"` / `\"devnet\"`).",
      "type": "string"
    },
    "oracle_feed": {
      "description": "Base58 pubkey of the oracle feed account, or `null` if verification does\nnot depend on a separate oracle-feed account (v1 — renamed from\n`switchboard_feed`, now nullable). Always emitted.",
      "type": [
        "string",
        "null"
      ]
    },
    "platform": {
      "description": "Platform discriminant (PlatformType). 0 = YouTube, 3 = X, etc.",
      "format": "int32",
      "minimum": 0,
      "type": "integer"
    },
    "program_id": {
      "description": "Shillbot program ID — re-reading the account requires this to verify\nownership.",
      "type": "string"
    },
    "score_max": {
      "description": "Decimal string of the score's maximum value (v1 — string).",
      "type": "string"
    },
    "state": {
      "description": "Lower-case state name; only `\"verified\"` is valid in v1.",
      "type": "string"
    },
    "task_id": {
      "description": "Decimal string of the on-chain u64 (v1 — string, not number, to avoid\nJS precision loss above 2^53-1).",
      "type": "string"
    },
    "verification_hash": {
      "description": "Hex-encoded (lowercase) sha256 binding task_id to composite_score.",
      "type": "string"
    },
    "verified_at": {
      "description": "RFC 3339 timestamp from on-chain `verified_at`, no fractional seconds.",
      "type": "string"
    },
    "verifier_instructions": {
      "description": "Plain-English instructions for a human reading the JSON. Verifiers MUST\nNOT base verification on this field (v1 — optional).",
      "type": [
        "string",
        "null"
      ]
    },
    "version": {
      "description": "Wire-format version. `\"vow/v1\"`.",
      "type": "string"
    }
  },
  "required": [
    "version",
    "network",
    "program_id",
    "account",
    "account_kind",
    "task_id",
    "client",
    "agent",
    "state",
    "platform",
    "composite_score",
    "score_max",
    "verified_at",
    "verification_hash",
    "content_hash",
    "content_id_hash",
    "extensions"
  ],
  "type": "object"
}