Fairseal APIv0.2

Provably fair randomness & verifiable AI execution infrastructure

Base URL

https://api.fairseal.io

Public Endpoints NO AUTH REQUIRED

GET/health
Health check — returns service status, database, VDF engine state
GET/api/v1/entropy
Get current VDF entropy — returns verified random value from latest epoch
GET/api/v1/games
List available games — Sic Bo and Dice with bet types and house edges
GET/api/v1/recent
Recent games — last 20 resolved games with outcomes
GET/api/v1/verify/:gameId
Verify a game — returns full proof, replay steps, and verification status
POST/api/v1/games/sicbo/bet
Place a Sic Bo bet — bet types: big, small, odd, even, total, single, double, triple, anyTriple, combo
POST/api/v1/games/dice/bet
Place a Dice bet — bet types: exact, over7, under7, odd, even

Example: Place a Bet

curl -X POST https://api.fairseal.io/api/v1/games/sicbo/bet \
  -H "Content-Type: application/json" \
  -d {bet_type: big, amount: 10}

Response (instant, pool-served)

{
  "status": "resolved",
  "game_id": "7f0a6f6e...",
  "result": {
    "outcome": { "die1": 4, "die2": 5, "die3": 2, "total": 11 },
    "won": true,
    "payout": "10.00"
  },
  "pool_served": true
}

Example: Verify a Game

curl https://api.fairseal.io/api/v1/verify/7f0a6f6e...

Response

{
  "game_id": "7f0a6f6e...",
  "verified": true,
  "proof": {
    "vdfEpoch": 42,
    "rngValue": "e358...",
    "derivation": "HMAC-SHA256(vdf_output, game_id || player_seed)"
  },
  "replay_steps": [
    { "step": 1, "action": "bet_committed", ... },
    { "step": 2, "action": "vdf_epoch_published", ... },
    { "step": 3, "action": "randomness_derived", ... },
    { "step": 4, "action": "dice_rolled", ... },
    { "step": 5, "action": "bet_evaluated", ... }
  ]
}

SDK

npm install @fairseal/core @fairseal/auto
import OpenAI from openai;
import { auto } from @fairseal/auto;

const client = auto(new OpenAI());
// Every AI call now emits a Verifiable Execution Object

VEO-2 Standard

The VEO-2 RFC defines the Verifiable Execution Object standard — a format for recording, proving, and explaining AI decisions.

Fairseal — Open infrastructure for verifiable AI execution · GitHub · MIT License